
import { ComponentMetadata, Snippet } from '@alilc/lowcode-types';

const ProNumberSelectorMeta: ComponentMetadata = {
  "componentName": "ProNumberSelector",
  "title": "ProNumberSelector",
  "docUrl": "",
  "screenshot": "",
  "devMode": "proCode",
  "npm": {
    "package": "@pisell/private-materials",
    "version": "1.0.4",
    "exportName": "ProNumberSelector",
    "main": "src/index.ts",
    "destructuring": true,
    "subName": ""
  },
  "configure": {
    props: [

      {
        name: 'value',
        title: { label: '当前值', tip: 'value | 当前值' },
        setter: 'NumberSetter',
        defaultValue: 0,
      },
      {
        name: 'min',
        title: { label: '最小值', tip: 'min | 最小值' },
        setter: 'NumberSetter',
        defaultValue: 0,
      },
      {
        name: 'max',
        title: { label: '最大值', tip: 'max | 最大值' },
        setter: 'NumberSetter',
        defaultValue: 999,
      },
      {
        name: 'step',
        title: { label: '步长设置', tip: 'step | 步长设置' },
        setter: 'NumberSetter',
        defaultValue: 1,
      },
      {
        name: 'disabled',
        title: { label: '是否禁用', tip: 'disabled | 是否禁用' },
        setter: 'BoolSetter',
        defaultValue: false,
      },
      {
        name: 'styleType',
        title: { label: '样式', tip: 'styleType | 样式' },
        setter: {
          componentName: "SelectSetter",
          props: {
            options: [
              { title: "胶囊型", value: "capsule" },
              { title: "分离式", value: "separation" },
            ],
          },
        },
        defaultValue: 'capsule',
      },
      {
        name: 'size',
        title: { label: '尺寸', tip: 'size | 尺寸' },
        setter: {
          componentName: "SelectSetter",
          props: {
            options: [
              { title: "小", value: "small" },
              { title: "中", value: "middle" },
              { title: "大", value: "large" },
            ],
          },
        },
        defaultValue: 'middle',
      },
      {
        name: 'width',
        title: { label: '强制宽度', tip: 'width | 强制宽度' },
        setter: 'StringSetter',
        defaultValue: '112px',
      },
      {
        name: 'enablePriceAdjust',
        title: { label: '是否启用价格调整', tip: 'enablePriceAdjust | 是否启用价格调整' },
        setter: 'BoolSetter',
        defaultValue: true,
      },
      {
        name: 'originValue',
        title: { label: '原始价格', tip: 'originValue | 原始价格' },
        setter: 'NumberSetter',
        defaultValue: 0,
      },
      {
        "title": {
          "label": {
            "type": "i18n",
            "en-US": "onChange",
            "zh-CN": "onChange"
          }
        },
        "name": "onChange",
        "setter": ["JsonSetter", "VariableSetter"],
      },
    ],
    "supports": {
      style: true,
      events: [

      ],
    },
    "component": {}
  }
};
const snippets: Snippet[] = [
  {
    "title": "ProNumberSelector",
    "screenshot": "",
    "schema": {
      "componentName": "ProNumberSelector",
      "props": {
      }
    }
  }
];

export default {
  ...ProNumberSelectorMeta,
  snippets
};
