From 74eeaaf48df9b04062a4701cc5efe3e56b3b5245 Mon Sep 17 00:00:00 2001 From: ZhangXianQiang <1135831638@qq.com> Date: 星期一, 18 三月 2024 14:34:20 +0800 Subject: [PATCH] refactor:抽离标题组件 --- src/views/screen/components/screen-detection/index.vue | 29 ++++++----------------------- 1 files changed, 6 insertions(+), 23 deletions(-) diff --git a/src/views/screen/components/screen-detection/index.vue b/src/views/screen/components/screen-detection/index.vue index 714358d..923c948 100644 --- a/src/views/screen/components/screen-detection/index.vue +++ b/src/views/screen/components/screen-detection/index.vue @@ -1,8 +1,7 @@ <template> <div class="detection-container"> - <div class="title-container"> - <span class="title">杩愯鐩戞帶鏁版嵁</span> - </div> + <wrapper-title :title="'杩愯鐩戞帶鏁版嵁'"></wrapper-title> + <div class="detection-content"> <div class="water-item"> <dv-water-level-pond :config="config1" style="width:100px;height:100px" /> @@ -29,7 +28,11 @@ </template> <script> +import WrapperTitle from '../wrapper-title/index' export default { + components: { + WrapperTitle + }, data() { return { config1: { @@ -58,26 +61,6 @@ </script> <style lang="scss" scoped> -.title-container { - background-image: url("../../../../assets/images/screen/title_bg.png"); - background-size: 231px 100%; - background-repeat: no-repeat; - height: 38px; - width: 100%; - position: relative; - display: flex; - align-items: center; - margin-bottom: 10px; - - .title { - margin-left: 20px; - margin-top: -2px; - color: #fff; - letter-spacing: 2px; - font-size: 20px; - font-style: italic; - } -} .detection-content { width: 100%; -- Gitblit v1.8.0