index.js 708 B

12345678910111213141516171819202122232425262728293031323334353637
  1. "use strict";
  2. var _component = require("../common/component");
  3. var _color = require("../common/color");
  4. (0, _component.VantComponent)({
  5. classes: ["desc-class"],
  6. props: {
  7. icon: String,
  8. steps: Array,
  9. active: Number,
  10. direction: {
  11. type: String,
  12. value: "horizontal"
  13. },
  14. activeColor: {
  15. type: String,
  16. value: _color.GREEN
  17. },
  18. inactiveColor: {
  19. type: String,
  20. value: _color.GRAY_DARK
  21. },
  22. activeIcon: {
  23. type: String,
  24. value: "checked"
  25. },
  26. inactiveIcon: String
  27. },
  28. methods: {
  29. onClick: function onClick(event) {
  30. var index = event.currentTarget.dataset.index;
  31. this.$emit("click-step", index);
  32. }
  33. }
  34. });