初始化
This commit is contained in:
@@ -0,0 +1,30 @@
|
||||
<template>
|
||||
<div class="content">
|
||||
<dv-decoration-4
|
||||
:reverse="true"
|
||||
style="width:90px;height:5px;"
|
||||
/>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import DvDecoration4 from '@jiaminghi/data-view/lib/components/decoration4/src/main.vue'
|
||||
export default {
|
||||
name: 'Decoration4',
|
||||
components: {
|
||||
DvDecoration4
|
||||
},
|
||||
data () {
|
||||
return {}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
<style lang="scss" scoped>
|
||||
.content {
|
||||
width: 221px;
|
||||
height: 100px;
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
}
|
||||
</style>
|
||||
100
frontend/packages/Decorations/Decoration4Reverse/index.vue
Normal file
100
frontend/packages/Decorations/Decoration4Reverse/index.vue
Normal file
@@ -0,0 +1,100 @@
|
||||
<template>
|
||||
<div
|
||||
style="width: 100%;height: 100%"
|
||||
class="bs-design-wrap"
|
||||
>
|
||||
<dv-decoration-4
|
||||
:key="updateKey"
|
||||
:reverse="true"
|
||||
:color="color"
|
||||
:dur="config.customize.dur"
|
||||
/>
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
import DvDecoration4 from '@jiaminghi/data-view/lib/components/decoration4/src/main.vue'
|
||||
import { refreshComponentMixin } from 'data-room-ui/js/mixins/refreshComponent'
|
||||
export default {
|
||||
name: 'Decoration4',
|
||||
components: {
|
||||
DvDecoration4
|
||||
},
|
||||
mixins: [refreshComponentMixin],
|
||||
props: {
|
||||
// 卡片的属性
|
||||
config: {
|
||||
type: Object,
|
||||
default: () => ({})
|
||||
}
|
||||
},
|
||||
data () {
|
||||
return {}
|
||||
},
|
||||
computed: {
|
||||
color () {
|
||||
return this.config.customize.decorationColor1 ||
|
||||
this.config.customize.decorationColor2
|
||||
? [
|
||||
this.config.customize.decorationColor1,
|
||||
this.config.customize.decorationColor2
|
||||
]
|
||||
: null
|
||||
}
|
||||
},
|
||||
watch: {},
|
||||
mounted () {},
|
||||
methods: {}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.bs-design-wrap {
|
||||
position: relative;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
background-color: transparent;
|
||||
border-radius: 4px;
|
||||
box-shadow: 0px 0px 4px rgba(0, 0, 0, 0.1);
|
||||
box-sizing: border-box;
|
||||
}
|
||||
.title-box {
|
||||
height: 40px;
|
||||
padding: 10px 10px 0 0;
|
||||
box-sizing: border-box;
|
||||
.title {
|
||||
font-size: 14px;
|
||||
color: #333;
|
||||
font-weight: bold;
|
||||
border-left: 3px solid var(--bs-el-color-primary);
|
||||
padding-left: 16px;
|
||||
}
|
||||
.target-value {
|
||||
overflow-y: auto;
|
||||
height: 60px;
|
||||
font-weight: bold;
|
||||
width: 100%;
|
||||
font-size: 20px;
|
||||
color: #333;
|
||||
padding: 16px 0 0 22px;
|
||||
box-sizing: border-box;
|
||||
}
|
||||
}
|
||||
.el-icon-warning {
|
||||
color: #ffd600;
|
||||
}
|
||||
.title-hover {
|
||||
&:hover {
|
||||
cursor: move;
|
||||
}
|
||||
}
|
||||
/*滚动条样式*/
|
||||
::v-deep ::-webkit-scrollbar {
|
||||
width: 4px;
|
||||
border-radius: 4px;
|
||||
height: 4px;
|
||||
}
|
||||
::v-deep ::-webkit-scrollbar-thumb {
|
||||
background: #dddddd !important;
|
||||
border-radius: 10px;
|
||||
}
|
||||
</style>
|
||||
103
frontend/packages/Decorations/Decoration4Reverse/setting.vue
Normal file
103
frontend/packages/Decorations/Decoration4Reverse/setting.vue
Normal file
@@ -0,0 +1,103 @@
|
||||
<template>
|
||||
<div class="bs-setting-wrap">
|
||||
<el-form
|
||||
ref="form"
|
||||
:model="config"
|
||||
label-width="90px"
|
||||
label-position="left"
|
||||
class="setting-body bs-el-form"
|
||||
>
|
||||
<el-form
|
||||
:model="config.customize"
|
||||
label-position="left"
|
||||
class="setting-body bs-el-form"
|
||||
label-width="90px"
|
||||
>
|
||||
<SettingTitle>标题</SettingTitle>
|
||||
<el-form-item label="装饰名称" class="lc-field-body">
|
||||
<el-input
|
||||
v-model="config.title"
|
||||
clearable
|
||||
/>
|
||||
</el-form-item>
|
||||
<SettingTitle>位置</SettingTitle>
|
||||
<div class="lc-field-body">
|
||||
<PosWhSetting :config="config" />
|
||||
</div>
|
||||
<SettingTitle>旋转</SettingTitle>
|
||||
<div class="lc-field-body">
|
||||
<RotateSetting
|
||||
:config="config"
|
||||
/>
|
||||
</div>
|
||||
<SettingTitle>基础</SettingTitle>
|
||||
<div class="lc-field-body">
|
||||
<el-form-item label="装饰主颜色">
|
||||
<ColorPicker
|
||||
v-model="config.customize.decorationColor1"
|
||||
:predefine="predefineThemeColors"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="装饰副颜色">
|
||||
<ColorPicker
|
||||
v-model="config.customize.decorationColor2"
|
||||
:predefine="predefineThemeColors"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="单次动画时长">
|
||||
<el-input-number
|
||||
v-model="config.customize.dur"
|
||||
class="bs-el-input-number"
|
||||
:precision="0"
|
||||
label="请输入时长(s)"
|
||||
/>
|
||||
</el-form-item>
|
||||
</div>
|
||||
</el-form>
|
||||
</el-form>
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
import ColorPicker from 'data-room-ui/ColorPicker/index.vue'
|
||||
import PosWhSetting from 'data-room-ui/BigScreenDesign/RightSetting/PosWhSetting.vue'
|
||||
import RotateSetting from 'data-room-ui/BigScreenDesign/RightSetting/RotateSetting.vue'
|
||||
import SettingTitle from 'data-room-ui/SettingTitle/index.vue'
|
||||
import {predefineColors} from "data-room-ui/js/utils/colorList";
|
||||
export default {
|
||||
name: 'BarSetting',
|
||||
components: {
|
||||
ColorPicker,
|
||||
PosWhSetting,
|
||||
RotateSetting,
|
||||
SettingTitle
|
||||
},
|
||||
data () {
|
||||
return {
|
||||
// 预设主题色
|
||||
predefineThemeColors: predefineColors
|
||||
}
|
||||
},
|
||||
computed: {
|
||||
config: {
|
||||
get () {
|
||||
return this.$store.state.bigScreen.activeItemConfig
|
||||
},
|
||||
set (val) {
|
||||
this.$store.state.bigScreen.activeItemConfig = val
|
||||
}
|
||||
}
|
||||
},
|
||||
watch: {},
|
||||
mounted () {
|
||||
},
|
||||
methods: {
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
@import "../../assets/style/borderAndDecoraSetting.scss";
|
||||
.lc-field-body {
|
||||
padding: 12px 16px;
|
||||
}
|
||||
</style>
|
||||
@@ -0,0 +1,43 @@
|
||||
import { commonConfig } from '../../js/config'
|
||||
|
||||
export const settingConfig = {
|
||||
padding: [30, 30, 30, 60],
|
||||
legend: false,
|
||||
isGroup: true,
|
||||
data: [],
|
||||
// 设置面板属性的显隐
|
||||
displayOption: {
|
||||
dataAllocation: {
|
||||
// 是否存在数据配置
|
||||
enable: false
|
||||
}
|
||||
}
|
||||
}
|
||||
const customConfig = {
|
||||
type: 'decoration4Reverse',
|
||||
root: {
|
||||
version: '2023071001',
|
||||
contribution: false,
|
||||
// 绕x轴旋转角度
|
||||
rotateX: 0,
|
||||
// 绕y轴旋转角度
|
||||
rotateY: 0,
|
||||
// 绕z轴旋转角度
|
||||
rotateZ: 0,
|
||||
// 透视距离
|
||||
perspective: 0,
|
||||
skewX: 0,
|
||||
skewY: 0
|
||||
},
|
||||
customize: {
|
||||
decorationColor1: 'rgba(255, 255, 255, 0.3)',
|
||||
decorationColor2: 'rgba(255, 255, 255, 0.3)',
|
||||
reverse: false,
|
||||
dur: 3,
|
||||
scanDur: 3,
|
||||
haloDur: 2
|
||||
}
|
||||
}
|
||||
export const dataConfig = {
|
||||
...commonConfig(customConfig)
|
||||
}
|
||||
Reference in New Issue
Block a user