configure.js 1.0 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253
  1. import { basicInputConfigureOptions } from '../../input-configure-options'
  2. export default {
  3. ...basicInputConfigureOptions(),
  4. controlsPosition: {
  5. label: '控制按钮位置',
  6. type: 'select',
  7. options: [{
  8. value: 'right', label: '右侧'
  9. }, {
  10. value: '', label: '默认'
  11. }],
  12. defaultValue: 'right'
  13. },
  14. min: {
  15. type: 'number',
  16. label: '最小值',
  17. controlsPosition: 'right'
  18. },
  19. max: {
  20. type: 'number',
  21. label: '最大值',
  22. controlsPosition: 'right'
  23. },
  24. step: {
  25. type: 'number',
  26. label: '步长',
  27. controlsPosition: 'right',
  28. dependOn: ['precision'],
  29. min: 0,
  30. changeConfig: (config, { precision }) => {
  31. config.precision = precision
  32. return config
  33. }
  34. },
  35. precision: {
  36. type: 'number',
  37. label: '精度',
  38. min: 0,
  39. max: 10
  40. },
  41. placeholder: {
  42. type: 'input',
  43. label: '占位符',
  44. limit: 50
  45. },
  46. defaultValue: {
  47. type: 'number',
  48. controlsPosition: 'right'
  49. },
  50. required: { },
  51. requiredErrorMessage: { }
  52. }