index.js 613 B

1234567891011121314151617181920212223242526
  1. 'use strict';
  2. Object.defineProperty(exports, '__esModule', { value: true });
  3. var component_1 = require('../common/component');
  4. var relation_1 = require('../common/relation');
  5. component_1.VantComponent({
  6. field: true,
  7. relation: relation_1.useChildren('radio'),
  8. props: {
  9. value: {
  10. type: null,
  11. observer: 'updateChildren',
  12. },
  13. direction: String,
  14. disabled: {
  15. type: Boolean,
  16. observer: 'updateChildren',
  17. },
  18. },
  19. methods: {
  20. updateChildren: function () {
  21. this.children.forEach(function (child) {
  22. return child.updateFromParent();
  23. });
  24. },
  25. },
  26. });