@type-dom/ui 0.0.8 → 0.0.10

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (222) hide show
  1. package/README.md +44 -44
  2. package/package.json +2 -8
  3. package/src/aria.d.ts +0 -17
  4. package/src/aria.js +0 -18
  5. package/src/components/basic/td-button/td-button.abstract.d.ts +2 -3
  6. package/src/components/basic/td-button/td-button.abstract.js +30 -26
  7. package/src/components/basic/td-button/td-button.interface.d.ts +0 -1
  8. package/src/components/basic/td-button-group/td-button-group.class.d.ts +2 -3
  9. package/src/components/basic/td-button-group/td-button-group.class.js +14 -16
  10. package/src/components/basic/td-container/td-aside/td-aside.class.js +2 -2
  11. package/src/components/basic/td-container/td-container.class.js +5 -5
  12. package/src/components/basic/td-container/td-container.js +1 -1
  13. package/src/components/basic/td-container/td-footer/td-footer.class.js +2 -2
  14. package/src/components/basic/td-container/td-header/td-header.class.js +3 -3
  15. package/src/components/basic/td-container/td-main/td-main.class.js +2 -2
  16. package/src/components/basic/td-icon/td-icon.class.js +20 -20
  17. package/src/components/basic/td-layout/td-col/td-col.class.d.ts +5 -2
  18. package/src/components/basic/td-layout/td-col/td-col.class.js +80 -80
  19. package/src/components/basic/td-layout/td-row/td-row.class.js +13 -13
  20. package/src/components/basic/td-link/td-link.class.d.ts +0 -1
  21. package/src/components/basic/td-link/td-link.class.js +17 -19
  22. package/src/components/basic/td-scrollbar/bar/bar.class.js +3 -3
  23. package/src/components/basic/td-scrollbar/td-scrollbar.class.js +5 -5
  24. package/src/components/basic/td-scrollbar/thumb/thumb.class.js +3 -3
  25. package/src/components/basic/td-space/td-space.class.js +10 -10
  26. package/src/components/basic/td-text/td-text.class.js +12 -9
  27. package/src/components/data/td-avatar/td-avatar.class.js +12 -13
  28. package/src/components/data/td-badge/td-badge.class.js +9 -8
  29. package/src/components/data/td-card/td-card.class.js +7 -7
  30. package/src/components/data/td-check-tag/td-check-tag.class.d.ts +0 -1
  31. package/src/components/data/td-check-tag/td-check-tag.class.js +9 -11
  32. package/src/components/data/td-collapse/td-collapse.class.js +2 -2
  33. package/src/components/data/td-collapse-item/td-collapse-item.class.js +15 -16
  34. package/src/components/data/td-collapse-transition/td-collapse-transition.util.js +14 -14
  35. package/src/components/data/td-count-down/td-count-down.class.js +1 -1
  36. package/src/components/data/td-descriptions/td-descriptions-row.js +2 -2
  37. package/src/components/data/td-descriptions/td-descriptions.class.js +8 -8
  38. package/src/components/data/td-descriptions/td-descritions-cell.js +14 -14
  39. package/src/components/data/td-descriptions-item/td-descriptions-item.class.js +1 -1
  40. package/src/components/data/td-empty/img-empty.class.js +3 -3
  41. package/src/components/data/td-empty/td-empty.class.js +4 -4
  42. package/src/components/data/td-image/td-image.class.js +6 -6
  43. package/src/components/data/td-image-viewer/td-image-viewer.class.d.ts +2 -1
  44. package/src/components/data/td-image-viewer/td-image-viewer.class.js +13 -10
  45. package/src/components/data/td-result/td-result.class.js +3 -3
  46. package/src/components/data/td-segmented/td-segmented.class.js +14 -17
  47. package/src/components/data/td-statistic/td-statistic.abstract.js +2 -2
  48. package/src/components/data/td-tag/td-tag.class.js +9 -9
  49. package/src/components/feedback/index.d.ts +2 -2
  50. package/src/components/feedback/index.js +5 -6
  51. package/src/components/feedback/td-alert/td-alert.class.js +9 -9
  52. package/src/components/feedback/td-dialog/td-dialog.class.js +5 -5
  53. package/src/components/feedback/td-dialog-content/td-dialog-content.class.js +4 -4
  54. package/src/components/feedback/td-drawer/td-drawer.class.js +10 -12
  55. package/src/components/feedback/td-focus-trap/td-focus-trap.class.d.ts +19 -1
  56. package/src/components/feedback/td-focus-trap/td-focus-trap.class.js +223 -48
  57. package/src/components/feedback/td-focus-trap/tokens.d.ts +2 -1
  58. package/src/components/feedback/td-focus-trap/utils.d.ts +1 -1
  59. package/src/components/feedback/td-focus-trap/utils.js +9 -11
  60. package/src/components/feedback/td-loading/td-loading.class.d.ts +2 -0
  61. package/src/components/feedback/td-loading/td-loading.class.js +7 -1
  62. package/src/components/feedback/td-message/td-message.class.d.ts +3 -2
  63. package/src/components/feedback/td-message/td-message.class.js +18 -18
  64. package/src/components/feedback/td-message/td-message.style.js +2 -1
  65. package/src/components/feedback/td-message-box/td-message-box.class.d.ts +5 -3
  66. package/src/components/feedback/td-message-box/td-message-box.class.js +79 -74
  67. package/src/components/feedback/td-message-box/td-message-box.interface.d.ts +2 -1
  68. package/src/components/feedback/td-notification/td-notification.class.d.ts +3 -2
  69. package/src/components/feedback/td-notification/td-notification.class.js +26 -26
  70. package/src/components/feedback/td-notification/td-notification.style.js +6 -6
  71. package/src/components/feedback/td-only-child/td-only-child.class.d.ts +7 -0
  72. package/src/components/feedback/td-only-child/td-only-child.class.js +74 -0
  73. package/src/components/feedback/td-overlay/td-overlay.class.d.ts +1 -1
  74. package/src/components/feedback/td-overlay/td-overlay.class.js +5 -5
  75. package/src/components/feedback/td-popper/arrow/arrow.class.d.ts +6 -0
  76. package/src/components/feedback/td-popper/arrow/arrow.class.js +22 -3
  77. package/src/components/feedback/td-popper/composable/use-focus-trap.d.ts +0 -0
  78. package/src/components/feedback/td-popper/composable/use-focus-trap.js +1 -0
  79. package/src/components/feedback/td-popper/content/content.class.d.ts +1 -0
  80. package/src/components/feedback/td-popper/content/content.class.js +25 -4
  81. package/src/components/feedback/td-popper/content/content.const.d.ts +3 -0
  82. package/src/components/feedback/td-popper/content/content.const.js +29 -0
  83. package/src/components/feedback/td-popper/content/content.interface.d.ts +9 -0
  84. package/src/components/feedback/td-popper/td-popper.class.d.ts +1 -1
  85. package/src/components/feedback/td-popper/td-popper.class.js +35 -2
  86. package/src/components/feedback/td-popper/td-popper.const.d.ts +21 -0
  87. package/src/components/feedback/td-popper/td-popper.const.js +5 -0
  88. package/src/components/feedback/td-popper/trigger/trigger.class.d.ts +11 -0
  89. package/src/components/feedback/td-popper/trigger/trigger.class.js +96 -1
  90. package/src/components/feedback/td-popper/trigger/trigger.const.d.ts +1 -0
  91. package/src/components/feedback/td-popper/trigger/trigger.const.js +12 -0
  92. package/src/components/feedback/td-popper/trigger/trigger.interface.d.ts +1 -0
  93. package/src/components/feedback/td-tooltip/content/content.class.js +1 -1
  94. package/src/components/feedback/td-tooltip/td-tooltip.class.js +1 -1
  95. package/src/components/feedback/td-tooltip/trigger/trigger.class.js +1 -1
  96. package/src/components/form/checkbox-group/checkbox-group.class.js +6 -7
  97. package/src/components/form/checkbox-group/checkbox-option/checkbox-option.class.d.ts +1 -1
  98. package/src/components/form/checkbox-group/checkbox-option/checkbox-option.class.js +4 -4
  99. package/src/components/form/field-item/cascade/field-cascade.abstract.d.ts +1 -1
  100. package/src/components/form/field-item/cascade/field-cascade.abstract.js +8 -8
  101. package/src/components/form/field-item/field-item.abstract.js +3 -3
  102. package/src/components/form/field-item/input/field-input.abstract.d.ts +1 -1
  103. package/src/components/form/field-item/input/field-input.abstract.js +8 -8
  104. package/src/components/form/field-item/options/field-options.abstract.d.ts +1 -3
  105. package/src/components/form/field-item/options/field-options.abstract.js +32 -30
  106. package/src/components/form/field-item/radio/field-radio.abstract.d.ts +1 -1
  107. package/src/components/form/field-item/radio/field-radio.abstract.js +32 -35
  108. package/src/components/form/field-item/select/field-select.abstract.d.ts +1 -1
  109. package/src/components/form/field-item/select/field-select.abstract.js +5 -5
  110. package/src/components/form/field-item/span/field-span.abstract.js +5 -5
  111. package/src/components/form/field-item/textarea/field-textarea.abstract.js +5 -5
  112. package/src/components/form/field-select/field-select.class.d.ts +1 -1
  113. package/src/components/form/field-select/field-select.class.js +7 -8
  114. package/src/components/form/field-select/option/option.class.js +1 -3
  115. package/src/components/form/radio-group/radio-group.class.js +6 -7
  116. package/src/components/form/radio-group/radio-option/radio-option.class.d.ts +0 -1
  117. package/src/components/form/radio-group/radio-option/radio-option.class.js +6 -8
  118. package/src/components/form/select/select.class.d.ts +1 -1
  119. package/src/components/form/select/select.class.js +4 -4
  120. package/src/components/form/td-checkbox/td-checkbox.class.js +3 -3
  121. package/src/components/form/td-checkbox/td-checkbox.style.js +2 -2
  122. package/src/components/form/td-checkbox-button/td-checkbox-button.class.js +3 -3
  123. package/src/components/form/td-checkbox-group/td-checkbox-group.class.js +3 -3
  124. package/src/components/form/td-form/td-form.class.js +5 -3
  125. package/src/components/form/td-form-item/td-form-item.class.js +16 -16
  126. package/src/components/form/td-input/td-input-field.class.js +8 -8
  127. package/src/components/form/td-input/td-input.class.d.ts +0 -1
  128. package/src/components/form/td-input/td-input.class.js +9 -11
  129. package/src/components/form/td-input/widget/prefix.js +1 -1
  130. package/src/components/form/td-input/widget/suffix.js +3 -3
  131. package/src/components/form/td-input/widget/td-input-wrapper.class.js +12 -11
  132. package/src/components/form/td-input/widget/td-textarea-wrapper.js +3 -3
  133. package/src/components/form/td-input/widget/utils.js +8 -8
  134. package/src/components/form/td-option/td-option.class.js +3 -3
  135. package/src/components/form/td-option-group/td-option-group.class.js +3 -3
  136. package/src/components/form/td-radio/td-radio.class.d.ts +0 -1
  137. package/src/components/form/td-radio/td-radio.class.js +50 -53
  138. package/src/components/form/td-radio-button/td-radio-button.class.d.ts +0 -1
  139. package/src/components/form/td-radio-button/td-radio-button.class.js +46 -49
  140. package/src/components/form/td-radio-group/td-radio-group.class.js +3 -4
  141. package/src/components/form/td-select/dropdown/dropdown.class.js +2 -2
  142. package/src/components/form/td-select/td-select.class.js +2 -2
  143. package/src/components/form/td-switch/td-switch.class.d.ts +1 -1
  144. package/src/components/form/td-switch/td-switch.class.js +21 -21
  145. package/src/components/form/td-switch/widget/td-switch-core.js +10 -10
  146. package/src/components/form/td-switch/widget/td-switch-left.js +3 -3
  147. package/src/components/form/td-switch/widget/td-switch-right.js +2 -2
  148. package/src/components/navigation/td-affix/td-affix.class.d.ts +3 -0
  149. package/src/components/navigation/td-affix/td-affix.class.js +22 -20
  150. package/src/components/navigation/td-anchor/td-anchor-link/td-anchor-link.class.js +1 -1
  151. package/src/components/navigation/td-anchor/td-anchor.class.js +10 -10
  152. package/src/components/navigation/td-backtop/td-backtop.class.d.ts +5 -3
  153. package/src/components/navigation/td-backtop/td-backtop.class.js +41 -32
  154. package/src/components/navigation/td-backtop/td-backtop.interface.d.ts +3 -0
  155. package/src/components/navigation/td-backtop/use-backtop.d.ts +7 -0
  156. package/src/components/navigation/td-backtop/use-backtop.js +44 -0
  157. package/src/components/navigation/td-breadcrumb/td-breadcrumb.class.js +4 -4
  158. package/src/components/navigation/td-breadcrumb-item/td-breadcrumb-item.class.js +3 -3
  159. package/src/components/navigation/td-menu/td-menu.class.js +5 -5
  160. package/src/components/navigation/td-menu/td-menu.interface.d.ts +2 -1
  161. package/src/components/navigation/td-tabs/td-tab-bar.class.js +5 -5
  162. package/src/components/navigation/td-tabs/td-tab-nav.class.js +14 -14
  163. package/src/components/navigation/td-tabs/td-tab-pane.class.js +3 -3
  164. package/src/components/navigation/td-tabs/td-tabs.class.js +4 -4
  165. package/src/components/others/collapsible-box/collapsible-box.js +2 -2
  166. package/src/components/others/collapsible-box/contents/contents.js +2 -2
  167. package/src/components/others/collapsible-box/heading/expand-heading.d.ts +1 -1
  168. package/src/components/others/collapsible-box/heading/expand-heading.js +11 -11
  169. package/src/components/others/custom-block/custom-block.js +2 -2
  170. package/src/components/others/example/example-float-control.d.ts +1 -1
  171. package/src/components/others/example/example-float-control.js +8 -8
  172. package/src/components/others/example/example-showcase.js +3 -3
  173. package/src/components/others/example/example-source-wrapper.d.ts +6 -2
  174. package/src/components/others/example/example-source-wrapper.js +3 -3
  175. package/src/components/others/example/example.d.ts +1 -2
  176. package/src/components/others/example/example.js +4 -4
  177. package/src/components/others/example/op-btns.js +9 -10
  178. package/src/components/others/menus/menu.d.ts +10 -5
  179. package/src/components/others/menus/menu.js +35 -33
  180. package/src/components/others/menus/menus.d.ts +6 -1
  181. package/src/components/others/menus/menus.js +46 -24
  182. package/src/components/others/td-divider/td-divider.class.js +8 -8
  183. package/src/hooks/index.d.ts +3 -0
  184. package/src/hooks/index.js +6 -0
  185. package/src/hooks/use-cursor.d.ts +1 -0
  186. package/src/hooks/use-cursor.js +56 -0
  187. package/src/hooks/use-escape-keydown.d.ts +4 -0
  188. package/src/hooks/use-escape-keydown.js +31 -0
  189. package/src/hooks/use-forward-ref.d.ts +13 -0
  190. package/src/hooks/use-forward-ref.js +27 -0
  191. package/src/index.d.ts +1 -0
  192. package/src/index.js +1 -0
  193. package/src/styles/var.d.ts +1 -1
  194. package/src/styles/var.js +2 -2
  195. package/src/ui/ui.abstract.d.ts +1 -1
  196. package/src/ui/ui.abstract.js +2 -2
  197. package/src/components/feedback/dialog/dialog.class.d.ts +0 -7
  198. package/src/components/feedback/dialog/dialog.class.js +0 -21
  199. package/src/components/feedback/dialog/dialog.interface.d.ts +0 -4
  200. package/src/components/feedback/dialog/dialog.interface.js +0 -2
  201. package/src/components/feedback/message-box/message-box.d.ts +0 -9
  202. package/src/components/feedback/message-box/message-box.interface.d.ts +0 -4
  203. package/src/components/feedback/message-box/message-box.interface.js +0 -2
  204. package/src/components/feedback/message-box/message-box.js +0 -33
  205. package/src/components/feedback/overlay/container/body/body.d.ts +0 -7
  206. package/src/components/feedback/overlay/container/body/body.js +0 -17
  207. package/src/components/feedback/overlay/container/container.d.ts +0 -15
  208. package/src/components/feedback/overlay/container/container.js +0 -38
  209. package/src/components/feedback/overlay/container/footer/cancel-button/cancel-button.d.ts +0 -8
  210. package/src/components/feedback/overlay/container/footer/cancel-button/cancel-button.js +0 -32
  211. package/src/components/feedback/overlay/container/footer/confirm-button/confirm-button.d.ts +0 -9
  212. package/src/components/feedback/overlay/container/footer/confirm-button/confirm-button.js +0 -32
  213. package/src/components/feedback/overlay/container/footer/footer.d.ts +0 -10
  214. package/src/components/feedback/overlay/container/footer/footer.js +0 -47
  215. package/src/components/feedback/overlay/container/header/close-button/close-button.d.ts +0 -11
  216. package/src/components/feedback/overlay/container/header/close-button/close-button.js +0 -34
  217. package/src/components/feedback/overlay/container/header/header.d.ts +0 -12
  218. package/src/components/feedback/overlay/container/header/header.js +0 -25
  219. package/src/components/feedback/overlay/container/header/title/title.d.ts +0 -9
  220. package/src/components/feedback/overlay/container/header/title/title.js +0 -19
  221. package/src/components/feedback/overlay/overlay.abstract.d.ts +0 -13
  222. package/src/components/feedback/overlay/overlay.abstract.js +0 -60
@@ -9,8 +9,8 @@ class TdAvatar extends ui_abstract_1.UI {
9
9
  constructor(params = {}) {
10
10
  super(params, 'span');
11
11
  this.className = 'TdAvatar';
12
- this.ctrl.addAttrName('td-avatar');
13
- this.ctrl.addStyleObj({
12
+ this.attr.addName('td-avatar');
13
+ this.style.addObj({
14
14
  display: 'inline-flex',
15
15
  justifyContent: 'center',
16
16
  alignItems: 'center',
@@ -29,7 +29,7 @@ class TdAvatar extends ui_abstract_1.UI {
29
29
  fontSize: td_avatar_style_1.$avatar.textSize
30
30
  });
31
31
  this.hasLoadError = false;
32
- this.props = this.setProps(params);
32
+ this.props = this.useParams(params);
33
33
  }
34
34
  setup() {
35
35
  var _a, _b, _c;
@@ -50,7 +50,7 @@ class TdAvatar extends ui_abstract_1.UI {
50
50
  }
51
51
  else if (props === null || props === void 0 ? void 0 : props.icon) {
52
52
  this.addChild(props.icon);
53
- this.ctrl.addStyleObj({
53
+ this.style.addObj({
54
54
  fontSize: td_avatar_style_1.$avatar.iconSize
55
55
  });
56
56
  }
@@ -60,47 +60,46 @@ class TdAvatar extends ui_abstract_1.UI {
60
60
  }
61
61
  }
62
62
  const fit = (props === null || props === void 0 ? void 0 : props.fit) || 'cover';
63
- (_a = this.img) === null || _a === void 0 ? void 0 : _a.ctrl.addStyleObj({
63
+ (_a = this.img) === null || _a === void 0 ? void 0 : _a.style.addObj({
64
64
  objectFit: fit
65
65
  });
66
66
  const shape = (props === null || props === void 0 ? void 0 : props.shape) || 'circle';
67
- this.ctrl.addStyleObj({
67
+ this.style.addObj({
68
68
  borderRadius: shape === 'circle' ? '50%' : td_avatar_style_1.$avatar.borderRadius
69
69
  });
70
70
  const size = (props === null || props === void 0 ? void 0 : props.size) || 'default';
71
71
  if ((0, utils_1.isNumber)(size)) {
72
- this.ctrl.addStyleObj({
72
+ this.style.addObj({
73
73
  width: (0, utils_1.addUnit)(size),
74
74
  height: (0, utils_1.addUnit)(size)
75
75
  });
76
- (_b = this.img) === null || _b === void 0 ? void 0 : _b.ctrl.addStyleObj({
76
+ (_b = this.img) === null || _b === void 0 ? void 0 : _b.style.addObj({
77
77
  width: (0, utils_1.addUnit)(size),
78
78
  height: (0, utils_1.addUnit)(size)
79
79
  });
80
80
  if ((props === null || props === void 0 ? void 0 : props.slot) instanceof framework_1.TypeElement) {
81
- props.slot.ctrl.addStyleObj({
81
+ props.slot.style.addObj({
82
82
  width: (0, utils_1.addUnit)(size),
83
83
  height: (0, utils_1.addUnit)(size)
84
84
  });
85
85
  }
86
86
  }
87
87
  else {
88
- this.ctrl.addStyleObj({
88
+ this.style.addObj({
89
89
  width: td_avatar_style_1.$avatarSize[size],
90
90
  height: td_avatar_style_1.$avatarSize[size]
91
91
  });
92
- (_c = this.img) === null || _c === void 0 ? void 0 : _c.ctrl.addStyleObj({
92
+ (_c = this.img) === null || _c === void 0 ? void 0 : _c.style.addObj({
93
93
  width: td_avatar_style_1.$avatarSize[size],
94
94
  height: td_avatar_style_1.$avatarSize[size]
95
95
  });
96
96
  if ((props === null || props === void 0 ? void 0 : props.slot) instanceof framework_1.TypeElement) {
97
- props.slot.ctrl.addStyleObj({
97
+ props.slot.style.addObj({
98
98
  width: td_avatar_style_1.$avatarSize[size],
99
99
  height: td_avatar_style_1.$avatarSize[size]
100
100
  });
101
101
  }
102
102
  }
103
- // super.setProps(config);
104
103
  }
105
104
  // todo 监听 src 改变
106
105
  setSrc(src) {
@@ -12,8 +12,8 @@ class TdBadge extends ui_abstract_1.UI {
12
12
  super(params);
13
13
  console.log('TdBadge constructor . ');
14
14
  this.className = 'TdBadge';
15
- this.ctrl.addAttrName('td-badge');
16
- this.ctrl.addStyleObj({
15
+ this.attr.addName('td-badge');
16
+ this.style.addObj({
17
17
  position: 'relative',
18
18
  verticalAlign: 'middle',
19
19
  display: 'inline-block',
@@ -44,12 +44,13 @@ class TdBadge extends ui_abstract_1.UI {
44
44
  marginTop: (0, utils_1.addUnit)((_d = (_c = params === null || params === void 0 ? void 0 : params.offset) === null || _c === void 0 ? void 0 : _c[1]) !== null && _d !== void 0 ? _d : 0)
45
45
  }
46
46
  });
47
+ this.addChild(this.getSlotNode());
47
48
  this.addChild(new framework_1.Transition({
48
49
  name: 'td-badge',
49
50
  parent: this,
50
- childNodes: [this.sup]
51
+ slot: this.sup
51
52
  }));
52
- this.props = this.setProps(params);
53
+ this.props = this.useParams(params);
53
54
  }
54
55
  setup() {
55
56
  console.log('TdBadge setup');
@@ -71,7 +72,7 @@ class TdBadge extends ui_abstract_1.UI {
71
72
  this.sup.getTextNode().setText(content);
72
73
  }
73
74
  if (props === null || props === void 0 ? void 0 : props.slot) {
74
- this.sup.ctrl.addStyleObj({
75
+ this.sup.style.addObj({
75
76
  // 默认样式
76
77
  position: 'absolute',
77
78
  top: '0',
@@ -83,7 +84,7 @@ class TdBadge extends ui_abstract_1.UI {
83
84
  });
84
85
  }
85
86
  if (props === null || props === void 0 ? void 0 : props.isDot) {
86
- this.sup.ctrl.addStyleObj({
87
+ this.sup.style.addObj({
87
88
  height: 8,
88
89
  width: 8,
89
90
  padding: 0,
@@ -92,12 +93,12 @@ class TdBadge extends ui_abstract_1.UI {
92
93
  });
93
94
  }
94
95
  if (props === null || props === void 0 ? void 0 : props.type) {
95
- this.sup.ctrl.addStyleObj({
96
+ this.sup.style.addObj({
96
97
  backgroundColor: var_1.$colors[props.type].base
97
98
  });
98
99
  }
99
100
  if (props === null || props === void 0 ? void 0 : props.dotStyle) {
100
- this.sup.ctrl.addStyleObj(props.dotStyle);
101
+ this.sup.style.addObj(props.dotStyle);
101
102
  }
102
103
  }
103
104
  changeValue(value) {
@@ -10,8 +10,8 @@ class TdCard extends ui_abstract_1.UI {
10
10
  constructor(params = {}) {
11
11
  super(params);
12
12
  this.className = 'TdCard';
13
- this.ctrl.addAttrName('td-card');
14
- this.ctrl.addStyleObj({
13
+ this.attr.addName('td-card');
14
+ this.style.addObj({
15
15
  // border-radius: getCssVar('card', 'border-radius'),
16
16
  borderRadius: td_card_style_1.$card.borderRadius,
17
17
  // border: 1px solid getCssVar('card', 'border-color'),
@@ -33,28 +33,28 @@ class TdCard extends ui_abstract_1.UI {
33
33
  }
34
34
  });
35
35
  if (params === null || params === void 0 ? void 0 : params.bodyStyle) {
36
- this.body.ctrl.addStyleObj(params.bodyStyle);
36
+ this.body.style.addObj(params.bodyStyle);
37
37
  }
38
38
  if (params === null || params === void 0 ? void 0 : params.bodyClass) {
39
- this.body.ctrl.addAttrClass(params.bodyClass);
39
+ this.body.attr.addClass(params.bodyClass);
40
40
  }
41
41
  if (params === null || params === void 0 ? void 0 : params.slot) {
42
42
  this.body.slotChild(params.slot);
43
43
  }
44
44
  this.addChild(this.body);
45
45
  this.addFooter(params);
46
- this.props = this.setProps(params);
46
+ this.props = this.useParams(params);
47
47
  }
48
48
  addShadow(params) {
49
49
  const shadow = (params === null || params === void 0 ? void 0 : params.shadow) || 'always';
50
50
  if (shadow === 'always') {
51
- this.ctrl.addStyleObj({
51
+ this.style.addObj({
52
52
  boxShadow: var_1.$boxShadow.light
53
53
  });
54
54
  }
55
55
  else if (shadow === 'hover') {
56
56
  // todo :hover :focus boxShadow: $boxShadow.light
57
- this.ctrl.addAttrClass('hover-shadow');
57
+ this.attr.addClass('hover-shadow');
58
58
  (0, framework_1.createClass)('hover-shadow:hover', {
59
59
  boxShadow: var_1.$boxShadow.light
60
60
  });
@@ -6,7 +6,6 @@ export declare class TdCheckTag extends UI implements ITdCheckTag {
6
6
  checked?: boolean;
7
7
  private type;
8
8
  constructor(params?: ITdCheckTagConfig);
9
- initEvents(): void;
10
9
  handleChange(): void;
11
10
  setChecked(checked?: boolean): void;
12
11
  }
@@ -9,14 +9,12 @@ class TdCheckTag extends ui_abstract_1.UI {
9
9
  constructor(params = {}) {
10
10
  super(params, 'span');
11
11
  this.className = 'TdCheckTag';
12
- this.ctrl.addAttrName('td-check-tag');
12
+ this.attr.addName('td-check-tag');
13
13
  this.type = (params === null || params === void 0 ? void 0 : params.type) || 'primary';
14
14
  (0, td_check_tag_style_1.useType)();
15
- this.ctrl.addStyleObj(td_check_tag_style_1.$checkTag);
15
+ this.style.addObj(td_check_tag_style_1.$checkTag);
16
16
  this.setChecked(params === null || params === void 0 ? void 0 : params.checked);
17
- this.props = this.setProps(params);
18
- }
19
- initEvents() {
17
+ this.props = this.useParams(params);
20
18
  this.addEvents({
21
19
  click: () => {
22
20
  // if (this.props.emits?.change) {
@@ -27,24 +25,24 @@ class TdCheckTag extends ui_abstract_1.UI {
27
25
  },
28
26
  mouseenter: () => {
29
27
  if (this.checked) {
30
- this.ctrl.setStyleObj({
28
+ this.style.setObj({
31
29
  backgroundColor: var_1.$colors[this.type]['light-7']
32
30
  });
33
31
  }
34
32
  else {
35
- this.ctrl.setStyleObj({
33
+ this.style.setObj({
36
34
  backgroundColor: var_1.$colors.info['light-7']
37
35
  });
38
36
  }
39
37
  },
40
38
  mouseleave: () => {
41
39
  if (this.checked) {
42
- this.ctrl.setStyleObj({
40
+ this.style.setObj({
43
41
  backgroundColor: var_1.$colors[this.type]['light-8']
44
42
  });
45
43
  }
46
44
  else {
47
- this.ctrl.setStyleObj({
45
+ this.style.setObj({
48
46
  backgroundColor: var_1.$colors.info['light-9']
49
47
  });
50
48
  }
@@ -62,10 +60,10 @@ class TdCheckTag extends ui_abstract_1.UI {
62
60
  setChecked(checked) {
63
61
  this.checked = checked;
64
62
  if (checked) {
65
- this.ctrl.setStyleObj(td_check_tag_style_1.$checkTagChecked[this.type]);
63
+ this.style.setObj(td_check_tag_style_1.$checkTagChecked[this.type]);
66
64
  }
67
65
  else {
68
- this.ctrl.setStyleObj({
66
+ this.style.setObj({
69
67
  backgroundColor: var_1.$colors.info['light-9'],
70
68
  color: var_1.$colors.info.base
71
69
  });
@@ -10,7 +10,7 @@ class TdCollapse extends ui_abstract_1.UI {
10
10
  super(params);
11
11
  this.className = 'TdCollapse';
12
12
  this.childNodes = [];
13
- this.ctrl.addStyleObj({
13
+ this.style.addObj({
14
14
  // border-top: 1px solid getCssVar('collapse-border-color');
15
15
  borderTop: '1px solid ' + td_collapse_style_1.$collapse.borderColor,
16
16
  // border-bottom: 1px solid getCssVar('collapse-border-color');
@@ -19,7 +19,7 @@ class TdCollapse extends ui_abstract_1.UI {
19
19
  this.activeNames = (0, utils_1.isArray)(params === null || params === void 0 ? void 0 : params.modelValue)
20
20
  ? params.modelValue
21
21
  : [(_a = params === null || params === void 0 ? void 0 : params.modelValue) !== null && _a !== void 0 ? _a : ''];
22
- this.props = this.setProps(params);
22
+ this.props = this.useParams(params);
23
23
  }
24
24
  mounted() {
25
25
  this.setActiveNames(this.activeNames);
@@ -43,7 +43,7 @@ class TdCollapseItem extends ui_abstract_1.UI {
43
43
  fontSize: td_collapse_style_1.$collapse.headerFontSize,
44
44
  fontWeight: 500,
45
45
  // transition: border-bottom-color getCssVar('transition-duration'),
46
- transition: 'border-bottom-color ' + var_1.$transitionDuration,
46
+ transition: 'border-bottom-color ' + var_1.$transitionDurationDefault,
47
47
  outline: 'none'
48
48
  },
49
49
  events: {
@@ -54,8 +54,7 @@ class TdCollapseItem extends ui_abstract_1.UI {
54
54
  // keydown.space.enter.stop.prevent: () => {
55
55
  // },
56
56
  keydown: (event) => {
57
- if (event.key === 'Enter' ||
58
- event.key === ' ') {
57
+ if ((event === null || event === void 0 ? void 0 : event.key) === 'Enter' || (event === null || event === void 0 ? void 0 : event.key) === ' ') {
59
58
  event === null || event === void 0 ? void 0 : event.preventDefault();
60
59
  event === null || event === void 0 ? void 0 : event.stopPropagation();
61
60
  this.handleEnterClick();
@@ -81,7 +80,7 @@ class TdCollapseItem extends ui_abstract_1.UI {
81
80
  styleObj: {
82
81
  margin: '0 8px 0 auto',
83
82
  // transition: transform getCssVar('transition-duration'),
84
- transition: 'transform ' + var_1.$transitionDuration,
83
+ transition: 'transform ' + var_1.$transitionDurationDefault,
85
84
  fontWeight: 300
86
85
  }
87
86
  });
@@ -122,10 +121,10 @@ class TdCollapseItem extends ui_abstract_1.UI {
122
121
  this.wrapper.addChild(this.content);
123
122
  this.transition = new td_collapse_transition_class_1.TdCollapseTransition({
124
123
  parent: this,
125
- childNodes: [this.wrapper]
124
+ slot: this.wrapper
126
125
  });
127
126
  this.addChild(this.transition);
128
- this.props = this.setProps(params);
127
+ this.props = this.useParams(params);
129
128
  }
130
129
  setActive(active) {
131
130
  if (active) {
@@ -147,10 +146,10 @@ class TdCollapseItem extends ui_abstract_1.UI {
147
146
  // });
148
147
  // });
149
148
  this.transition.showSlot(true);
150
- this.headerBtn.ctrl.setStyleObj({
149
+ this.headerBtn.style.setObj({
151
150
  borderBottomColor: 'transparent'
152
151
  });
153
- this.arrowIcon.ctrl.setStyleObj({
152
+ this.arrowIcon.style.setObj({
154
153
  transform: 'rotate(90deg)'
155
154
  });
156
155
  }
@@ -167,10 +166,10 @@ class TdCollapseItem extends ui_abstract_1.UI {
167
166
  // });
168
167
  // });
169
168
  this.transition.showSlot(false);
170
- this.headerBtn.ctrl.setStyleObj({
171
- transition: 'transform ' + var_1.$transitionDuration
169
+ this.headerBtn.style.setObj({
170
+ transition: 'transform ' + var_1.$transitionDurationDefault,
172
171
  });
173
- this.arrowIcon.ctrl.setStyleObj({
172
+ this.arrowIcon.style.setObj({
174
173
  transform: 'rotate(0deg)'
175
174
  });
176
175
  // todo transition
@@ -179,14 +178,14 @@ class TdCollapseItem extends ui_abstract_1.UI {
179
178
  }
180
179
  setDisable(disabled) {
181
180
  if (disabled) {
182
- this.headerBtn.ctrl.setStyleObj({
181
+ this.headerBtn.style.setObj({
183
182
  // color: getCssVar('text-color-disabled'),
184
183
  color: var_1.$textColor.disabled,
185
184
  cursor: 'not-allowed'
186
185
  });
187
186
  }
188
187
  else {
189
- this.headerBtn.ctrl.setStyleObj({
188
+ this.headerBtn.style.setObj({
190
189
  // color: getCssVar('collapse-header-text-color'),
191
190
  color: td_collapse_style_1.$collapse.headerTextColor,
192
191
  cursor: 'pointer'
@@ -195,11 +194,11 @@ class TdCollapseItem extends ui_abstract_1.UI {
195
194
  }
196
195
  handleFocus() {
197
196
  setTimeout(() => {
198
- if (!this.isClick) {
199
- this.focusing = true;
197
+ if (this.isClick) {
198
+ this.isClick = false;
200
199
  }
201
200
  else {
202
- this.isClick = false;
201
+ this.focusing = true;
203
202
  }
204
203
  }, 50);
205
204
  }
@@ -10,7 +10,7 @@ const reset = (element) => {
10
10
  // el.style.overflow = el.dataset.oldOverflow
11
11
  // el.style.paddingTop = el.dataset.oldPaddingTop
12
12
  // el.style.paddingBottom = el.dataset.oldPaddingBottom
13
- element === null || element === void 0 ? void 0 : element.ctrl.setStyleObj({
13
+ element === null || element === void 0 ? void 0 : element.style.setObj({
14
14
  maxHeight: '',
15
15
  overflow: el.dataset.oldOverflow,
16
16
  paddingTop: el.dataset.oldPaddingTop,
@@ -26,9 +26,9 @@ exports.collapseTransitionConfig = {
26
26
  }
27
27
  if (!el.dataset) {
28
28
  // el.dataset = {};
29
- element.ctrl.setAttribute('dataset', false);
29
+ element.attr.set('dataset', false);
30
30
  }
31
- element.ctrl.setAttrObj({
31
+ element.attr.setObj({
32
32
  dataOldPaddingTop: el.style.paddingTop,
33
33
  dataOldPaddingBottom: el.style.paddingBottom
34
34
  });
@@ -36,14 +36,14 @@ exports.collapseTransitionConfig = {
36
36
  // el.dataset.oldPaddingBottom = el.style.paddingBottom
37
37
  if (el.style.height) {
38
38
  // el.dataset.existsHeight = el.style.height
39
- element.ctrl.setAttrObj({
39
+ element.attr.setObj({
40
40
  dataExistsHeight: el.style.height
41
41
  });
42
42
  }
43
43
  // el.style.maxHeight = 0
44
44
  // el.style.paddingTop = 0
45
45
  // el.style.paddingBottom = 0
46
- element.ctrl.setStyleObj({
46
+ element.style.setObj({
47
47
  maxHeight: 0,
48
48
  paddingTop: 0,
49
49
  paddingBottom: 0,
@@ -57,32 +57,32 @@ exports.collapseTransitionConfig = {
57
57
  throw Error('element is not exist . ');
58
58
  }
59
59
  requestAnimationFrame(() => {
60
- element.ctrl.setAttrObj({
60
+ element.attr.setObj({
61
61
  dataOldOverflow: el.style.overflow
62
62
  });
63
63
  // el.dataset.oldOverflow = el.style.overflow
64
64
  if (el.dataset.existsHeight) {
65
65
  // el.style.maxHeight = el.dataset.existsHeight
66
- element.ctrl.setStyleObj({
66
+ element.style.setObj({
67
67
  maxHeight: el.dataset.existsHeight
68
68
  });
69
69
  }
70
70
  else if (el.scrollHeight !== 0) {
71
71
  // el.style.maxHeight = `${el.scrollHeight}px`
72
- element.ctrl.setStyleObj({
72
+ element.style.setObj({
73
73
  maxHeight: `${el.scrollHeight}px`
74
74
  });
75
75
  }
76
76
  else {
77
77
  // el.style.maxHeight = 0
78
- element.ctrl.setStyleObj({
78
+ element.style.setObj({
79
79
  maxHeight: 0
80
80
  });
81
81
  }
82
82
  // el.style.paddingTop = el.dataset.oldPaddingTop
83
83
  // el.style.paddingBottom = el.dataset.oldPaddingBottom
84
84
  // el.style.overflow = 'hidden'
85
- element.ctrl.setStyleObj({
85
+ element.style.setObj({
86
86
  paddingTop: el.dataset.oldPaddingTop,
87
87
  paddingBottom: el.dataset.oldPaddingBottom,
88
88
  overflow: 'hidden'
@@ -93,7 +93,7 @@ exports.collapseTransitionConfig = {
93
93
  var _a;
94
94
  // el.style.maxHeight = ''
95
95
  // el.style.overflow = el.dataset.oldOverflow
96
- element === null || element === void 0 ? void 0 : element.ctrl.setStyleObj({
96
+ element === null || element === void 0 ? void 0 : element.style.setObj({
97
97
  maxHeight: '',
98
98
  overflow: (_a = element === null || element === void 0 ? void 0 : element.dom) === null || _a === void 0 ? void 0 : _a.dataset.oldOverflow
99
99
  });
@@ -110,14 +110,14 @@ exports.collapseTransitionConfig = {
110
110
  // el.dataset.oldPaddingTop = el.style.paddingTop
111
111
  // el.dataset.oldPaddingBottom = el.style.paddingBottom
112
112
  // el.dataset.oldOverflow = el.style.overflow
113
- element.ctrl.setAttrObj({
113
+ element.attr.setObj({
114
114
  dataOldPaddingTop: el.style.paddingTop,
115
115
  dataOldPaddingBottom: el.style.paddingBottom,
116
116
  dataOldOverflow: el.style.overflow
117
117
  });
118
118
  // el.style.maxHeight = `${el.scrollHeight}px`
119
119
  // el.style.overflow = 'hidden'
120
- element.ctrl.setStyleObj({
120
+ element.style.setObj({
121
121
  maxHeight: `${el.scrollHeight}px`,
122
122
  overflow: 'hidden'
123
123
  });
@@ -131,7 +131,7 @@ exports.collapseTransitionConfig = {
131
131
  // el.style.maxHeight = 0
132
132
  // el.style.paddingTop = 0
133
133
  // el.style.paddingBottom = 0
134
- element.ctrl.setStyleObj({
134
+ element.style.setObj({
135
135
  maxHeight: 0,
136
136
  paddingTop: 0,
137
137
  paddingBottom: 0
@@ -14,7 +14,7 @@ class TdCountDown extends td_statistic_abstract_1.TdStatisticAbstract {
14
14
  this.rawValue = (0, utils_2.getTime)((params === null || params === void 0 ? void 0 : params.value) || 0) - Date.now();
15
15
  this.setNumber(this.rawValue);
16
16
  this.addChild(this.getSlotNode());
17
- this.props = this.setProps(params);
17
+ this.props = this.useParams(params);
18
18
  }
19
19
  mounted() {
20
20
  this.stopTimer();
@@ -13,7 +13,7 @@ class TdDescriptionsRow extends framework_1.TypeFragment {
13
13
  super();
14
14
  this.className = 'TdDescriptionsRow';
15
15
  this.childNodes = [];
16
- this.props = this.setProps(params);
16
+ this.props = this.useParams(params);
17
17
  }
18
18
  created() {
19
19
  var _a;
@@ -74,7 +74,7 @@ class TdDescriptionsRow extends framework_1.TypeFragment {
74
74
  });
75
75
  this.addChild(tr);
76
76
  }
77
- // this.setProps(this.config);
77
+ // this.useParams(this.config);
78
78
  }
79
79
  }
80
80
  exports.TdDescriptionsRow = TdDescriptionsRow;
@@ -10,7 +10,7 @@ class TdDescriptions extends ui_abstract_1.UI {
10
10
  constructor(params) {
11
11
  super(params);
12
12
  this.className = 'TdDescriptions';
13
- this.props = this.setProps(params);
13
+ this.props = this.useParams(params);
14
14
  }
15
15
  created() {
16
16
  var _a, _b, _c, _d;
@@ -85,7 +85,7 @@ class TdDescriptions extends ui_abstract_1.UI {
85
85
  });
86
86
  this.body.addChild(this.bodyTable);
87
87
  this.addChild(this.body);
88
- this.setProps(props); // todo ????
88
+ this.useParams(props); // todo ????
89
89
  }
90
90
  filledNode(node, span, count, isLast = false) {
91
91
  if (!node.props) {
@@ -139,15 +139,15 @@ class TdDescriptions extends ui_abstract_1.UI {
139
139
  this.props.size = size;
140
140
  (0, td_descriptions_style_1.useSize)(this.props);
141
141
  (0, td_descriptions_style_1.useBordered)(this.props);
142
- this.ctrl.setStyleObj(td_descriptions_style_1.$descriptionsStyle);
143
- (_a = this.header) === null || _a === void 0 ? void 0 : _a.ctrl.setStyleObj(td_descriptions_style_1.$descriptionsHeaderStyle);
144
- (_b = this.headerTitle) === null || _b === void 0 ? void 0 : _b.ctrl.setStyleObj(td_descriptions_style_1.$descriptionsHeaderTitleStyle);
145
- (_c = this.body) === null || _c === void 0 ? void 0 : _c.ctrl.setStyleObj(td_descriptions_style_1.$descriptionsBodyStyle);
146
- (_d = this.bodyTable) === null || _d === void 0 ? void 0 : _d.ctrl.setStyleObj(td_descriptions_style_1.$descriptionsBodyTableStyle);
142
+ this.style.setObj(td_descriptions_style_1.$descriptionsStyle);
143
+ (_a = this.header) === null || _a === void 0 ? void 0 : _a.style.setObj(td_descriptions_style_1.$descriptionsHeaderStyle);
144
+ (_b = this.headerTitle) === null || _b === void 0 ? void 0 : _b.style.setObj(td_descriptions_style_1.$descriptionsHeaderTitleStyle);
145
+ (_c = this.body) === null || _c === void 0 ? void 0 : _c.style.setObj(td_descriptions_style_1.$descriptionsBodyStyle);
146
+ (_d = this.bodyTable) === null || _d === void 0 ? void 0 : _d.style.setObj(td_descriptions_style_1.$descriptionsBodyTableStyle);
147
147
  (_e = this.rows) === null || _e === void 0 ? void 0 : _e.forEach((row) => {
148
148
  row.childNodes.forEach((tr) => {
149
149
  tr.childNodes.forEach((td) => {
150
- td.ctrl.setStyleObj(td_descriptions_style_1.$descriptionsBodyTableCellStyle);
150
+ td.style.setObj(td_descriptions_style_1.$descriptionsBodyTableCellStyle);
151
151
  });
152
152
  });
153
153
  });
@@ -8,7 +8,7 @@ class TdDescriptionsCell extends ui_abstract_1.UI {
8
8
  constructor(params = {}) {
9
9
  super(params, (params === null || params === void 0 ? void 0 : params.tag) || 'td');
10
10
  this.className = 'TdDescriptionsCell';
11
- this.props = this.setProps(params);
11
+ this.props = this.useParams(params);
12
12
  }
13
13
  created() {
14
14
  var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u;
@@ -21,34 +21,34 @@ class TdDescriptionsCell extends ui_abstract_1.UI {
21
21
  const isVertical = (descriptionsConfig === null || descriptionsConfig === void 0 ? void 0 : descriptionsConfig.direction) === 'vertical';
22
22
  // useSize(descriptionsConfig);
23
23
  // useBordered(descriptionsConfig);
24
- this.ctrl.addStyleObj(td_descriptions_style_1.$descriptionsBodyTableCellStyle);
24
+ this.style.addObj(td_descriptions_style_1.$descriptionsBodyTableCellStyle);
25
25
  const props = this.props;
26
26
  const span = ((_a = props.cell) === null || _a === void 0 ? void 0 : _a.span) || 1;
27
27
  // console.log('span is ', span);
28
28
  switch (props.type) {
29
29
  case 'label':
30
30
  console.log('label . ');
31
- this.ctrl.addAttrObj({
31
+ this.attr.addObj({
32
32
  colspan: isVertical ? span : 1,
33
33
  // colspan: span * 2 - 1 || 1
34
34
  });
35
- this.ctrl.addStyleObj(td_descriptions_style_1.$descriptionsCellLabelStyle);
35
+ this.style.addObj(td_descriptions_style_1.$descriptionsCellLabelStyle);
36
36
  if ((_c = (_b = props.cell) === null || _b === void 0 ? void 0 : _b.slots) === null || _c === void 0 ? void 0 : _c.label) {
37
37
  this.addChild(props === null || props === void 0 ? void 0 : props.cell.slots.label);
38
38
  }
39
39
  else if ((_d = props.cell) === null || _d === void 0 ? void 0 : _d.label) {
40
40
  this.addChild(new framework_1.TextNode(props.cell.label));
41
41
  if (props.cell.labelStyle) {
42
- this.ctrl.addStyleObj((_e = props.cell) === null || _e === void 0 ? void 0 : _e.labelStyle);
42
+ this.style.addObj((_e = props.cell) === null || _e === void 0 ? void 0 : _e.labelStyle);
43
43
  }
44
44
  }
45
45
  if ((_f = props.cell) === null || _f === void 0 ? void 0 : _f.labelAlign) {
46
- this.ctrl.addStyleObj({
46
+ this.style.addObj({
47
47
  textAlign: props.cell.labelAlign
48
48
  });
49
49
  }
50
50
  if ((_g = props.cell) === null || _g === void 0 ? void 0 : _g.width) {
51
- this.ctrl.addStyleObj({
51
+ this.style.addObj({
52
52
  width: props.cell.width
53
53
  });
54
54
  }
@@ -56,10 +56,10 @@ class TdDescriptionsCell extends ui_abstract_1.UI {
56
56
  case 'content':
57
57
  // debugger;
58
58
  console.log('content . ');
59
- this.ctrl.addAttrObj({
59
+ this.attr.addObj({
60
60
  colspan: span * 2 - 1 || 1
61
61
  });
62
- this.ctrl.addStyleObj(td_descriptions_style_1.$descriptionsCellContentStyle);
62
+ this.style.addObj(td_descriptions_style_1.$descriptionsCellContentStyle);
63
63
  if (typeof ((_h = props.cell) === null || _h === void 0 ? void 0 : _h.text) === 'string') {
64
64
  this.addChild(new framework_1.TextNode(props.cell.text));
65
65
  }
@@ -67,25 +67,25 @@ class TdDescriptionsCell extends ui_abstract_1.UI {
67
67
  this.slotChild(props.cell.slot);
68
68
  }
69
69
  if ((_k = props.cell) === null || _k === void 0 ? void 0 : _k.contentStyle) {
70
- this.ctrl.addStyleObj(props.cell.contentStyle);
70
+ this.style.addObj(props.cell.contentStyle);
71
71
  }
72
72
  if ((_l = props.cell) === null || _l === void 0 ? void 0 : _l.align) {
73
- this.ctrl.addStyleObj({
73
+ this.style.addObj({
74
74
  textAlign: props.cell.align
75
75
  });
76
76
  }
77
77
  if ((_m = props.cell) === null || _m === void 0 ? void 0 : _m.width) {
78
- this.ctrl.addStyleObj({
78
+ this.style.addObj({
79
79
  width: props.cell.width
80
80
  });
81
81
  }
82
82
  break;
83
83
  default:
84
- this.ctrl.addAttrObj({
84
+ this.attr.addObj({
85
85
  colspan: span
86
86
  });
87
87
  if ((_p = (_o = props.cell) === null || _o === void 0 ? void 0 : _o.slots) === null || _p === void 0 ? void 0 : _p.label) {
88
- props.cell.slots.label.ctrl.setStyleObj(td_descriptions_style_1.$descriptionsCellLabelStyle);
88
+ props.cell.slots.label.style.setObj(td_descriptions_style_1.$descriptionsCellLabelStyle);
89
89
  this.addChild((_r = (_q = props.cell) === null || _q === void 0 ? void 0 : _q.slots) === null || _r === void 0 ? void 0 : _r.label);
90
90
  }
91
91
  else if ((_s = props.cell) === null || _s === void 0 ? void 0 : _s.label) {