steps.mjs 1.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172
  1. import { CHANGE_EVENT } from "../../../constants/event.mjs";
  2. import { isNumber } from "../../../utils/types.mjs";
  3. import { buildProps } from "../../../utils/vue/props/runtime.mjs";
  4. //#region ../../packages/components/steps/src/steps.ts
  5. /**
  6. * @deprecated Removed after 3.0.0, Use `StepsProps` instead.
  7. */
  8. const stepsProps = buildProps({
  9. /**
  10. * @description the spacing of each step, will be responsive if omitted. Supports percentage.
  11. */
  12. space: {
  13. type: [Number, String],
  14. default: ""
  15. },
  16. /**
  17. * @description current activation step
  18. */
  19. active: {
  20. type: Number,
  21. default: 0
  22. },
  23. /**
  24. * @description display direction
  25. */
  26. direction: {
  27. type: String,
  28. default: "horizontal",
  29. values: ["horizontal", "vertical"]
  30. },
  31. /**
  32. * @description center title and description
  33. */
  34. alignCenter: { type: Boolean },
  35. /**
  36. * @description whether to apply simple theme
  37. */
  38. simple: { type: Boolean },
  39. /**
  40. * @description status of end step
  41. */
  42. finishStatus: {
  43. type: String,
  44. values: [
  45. "wait",
  46. "process",
  47. "finish",
  48. "error",
  49. "success"
  50. ],
  51. default: "finish"
  52. },
  53. /**
  54. * @description status of current step
  55. */
  56. processStatus: {
  57. type: String,
  58. values: [
  59. "wait",
  60. "process",
  61. "finish",
  62. "error",
  63. "success"
  64. ],
  65. default: "process"
  66. }
  67. });
  68. const stepsEmits = { [CHANGE_EVENT]: (newVal, oldVal) => [newVal, oldVal].every(isNumber) };
  69. //#endregion
  70. export { stepsEmits, stepsProps };
  71. //# sourceMappingURL=steps.mjs.map