index.vue 1.9 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798
  1. <template>
  2. <div
  3. style="width: 100%;height: 100%"
  4. class="bs-design-wrap"
  5. >
  6. <dv-decoration-6
  7. :key="updateKey"
  8. :color="color"
  9. />
  10. </div>
  11. </template>
  12. <script>
  13. import DvDecoration6 from '@jiaminghi/data-view/lib/components/decoration6/src/main.vue'
  14. import { refreshComponentMixin } from 'data-room-ui/js/mixins/refreshComponent'
  15. export default {
  16. name: 'Decoration6',
  17. components: {
  18. DvDecoration6
  19. },
  20. mixins: [refreshComponentMixin],
  21. props: {
  22. // 卡片的属性
  23. config: {
  24. type: Object,
  25. default: () => ({})
  26. }
  27. },
  28. data () {
  29. return {}
  30. },
  31. computed: {
  32. color () {
  33. return this.config.customize.decorationColor1 ||
  34. this.config.customize.decorationColor2
  35. ? [
  36. this.config.customize.decorationColor1,
  37. this.config.customize.decorationColor2
  38. ]
  39. : null
  40. }
  41. },
  42. watch: {},
  43. mounted () {},
  44. methods: {}
  45. }
  46. </script>
  47. <style lang="scss" scoped>
  48. .bs-design-wrap {
  49. position: relative;
  50. width: 100%;
  51. height: 100%;
  52. background-color: transparent;
  53. border-radius: 4px;
  54. box-shadow: 0px 0px 4px rgba(0, 0, 0, 0.1);
  55. box-sizing: border-box;
  56. }
  57. .title-box {
  58. height: 40px;
  59. padding: 10px 10px 0 0;
  60. box-sizing: border-box;
  61. .title {
  62. font-size: 14px;
  63. color: #333;
  64. font-weight: bold;
  65. border-left: 3px solid var(--bs-el-color-primary);
  66. padding-left: 16px;
  67. }
  68. .target-value {
  69. overflow-y: auto;
  70. height: 60px;
  71. font-weight: bold;
  72. width: 100%;
  73. font-size: 20px;
  74. color: #333;
  75. padding: 16px 0 0 22px;
  76. box-sizing: border-box;
  77. }
  78. }
  79. .el-icon-warning {
  80. color: #ffd600;
  81. }
  82. .title-hover {
  83. &:hover {
  84. cursor: move;
  85. }
  86. }
  87. /*滚动条样式*/
  88. ::v-deep ::-webkit-scrollbar {
  89. width: 4px;
  90. border-radius: 4px;
  91. height: 4px;
  92. }
  93. ::v-deep ::-webkit-scrollbar-thumb {
  94. background: #dddddd !important;
  95. border-radius: 10px;
  96. }
  97. </style>