Răsfoiți Sursa

feat:新增状态选项卡配置

2505287290@qq.com 1 lună în urmă
părinte
comite
d3e16e8cce
1 a modificat fișierele cu 112 adăugiri și 0 ștergeri
  1. 112 0
      src/services/defaults.ts

+ 112 - 0
src/services/defaults.ts

@@ -3946,6 +3946,118 @@ context.meta2d.translate(
           },
         },
       },
+      {
+        name: '状态选项卡',
+        icon: 'l-xuanxiangka',
+        data: {
+          name: 'tab',
+          width: 440,
+          height: 48,
+          direction: 'horizontal',
+          selectedKey: '1',
+          btnHeight: 32,
+          btnWidth: 100,
+          gap:8,
+          disableInput: true,
+          data: [
+            { text: '场景一', key: '0', isForbidden: true },
+            { text: '场景二', key: '1' },
+            { text: '场景三', key: '2' },
+            { text: '场景四', key: '3' },
+          ],
+          props: {
+            custom: [
+              {
+                key: 'data',
+                label: '数据',
+                type: 'code',
+              },
+              {
+                key: 'direction',
+                label: '方向',
+                type: 'select',
+                options: [
+                  { label: '水平', value: 'horizontal' },
+                  { label: '垂直', value: 'vertical' },
+                ],
+              },
+              {
+                key: 'gap',
+                label: '间隔',
+                type: 'number',
+                min:1
+              },
+              {
+                key: 'btnWidth',
+                label: '按钮宽度',
+                type: 'number',
+                min:1
+              },
+              {
+                key: 'btnHeight',
+                label: '按钮高度',
+                type: 'number',
+                min:1
+              },
+              {
+                key: 'activeBackground',
+                label: '选中背景',
+                type: 'color',
+              },
+              {
+                key: 'activeColor',
+                label: '选中边框',
+                type: 'color',
+              },
+              {
+                key: 'activeTextColor',
+                label: '选中文字',
+                type: 'color',
+              }, 
+              {
+                key: 'activeBgImage',
+                label: '选中背景图片',
+                type: 'string',
+              },
+              {
+                key: 'background',
+                label: '(未选中)背景',
+                type: 'color',
+              },
+              {
+                key: 'color',
+                label: '(未选中)边框',
+                type: 'color',
+              },
+              {
+                key: 'textColor',
+                label: '(未选中)文字',
+                type: 'color',
+              },
+              {
+                key: 'bgImage',
+                label: '(未选中)背景图片',
+                type: 'string',
+              },
+              {
+                key: 'iconFamily',
+                label: '字体',
+                type: 'string',
+              },
+              {
+                key:'statuses',
+                label: '状态',
+                type:'code',
+              },
+              {
+                key:'iconSize',
+                label: '状态图标大小',
+                type:'number',
+              }
+            ],
+          },
+        },
+      },
     ],
   },
   {