@3t-transform/threeteeui 1.9.56 → 1.9.57

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 (273) hide show
  1. package/dist/cjs/{index-992a9fb3.js → index-ec367fa3.js} +28 -2
  2. package/dist/cjs/loader.cjs.js +2 -2
  3. package/dist/cjs/{tttx-action-dropdown_1_9_56.cjs.entry.js → tttx-action-dropdown_1_9_57.cjs.entry.js} +3 -3
  4. package/dist/cjs/{tttx-button_1_9_56.cjs.entry.js → tttx-button_1_9_57.cjs.entry.js} +3 -3
  5. package/dist/cjs/{tttx-checkbox-group-caption_1_9_56.cjs.entry.js → tttx-checkbox-group-caption_1_9_57.cjs.entry.js} +2 -2
  6. package/dist/cjs/{tttx-checkbox-group-heading_1_9_56.cjs.entry.js → tttx-checkbox-group-heading_1_9_57.cjs.entry.js} +2 -2
  7. package/dist/cjs/{tttx-checkbox-group_1_9_56.cjs.entry.js → tttx-checkbox-group_1_9_57.cjs.entry.js} +2 -2
  8. package/dist/cjs/{tttx-checkbox_1_9_56.cjs.entry.js → tttx-checkbox_1_9_57.cjs.entry.js} +3 -3
  9. package/dist/cjs/{tttx-comments_1_9_56.cjs.entry.js → tttx-comments_1_9_57.cjs.entry.js} +3 -3
  10. package/dist/cjs/{tttx-data-pattern_1_9_56.cjs.entry.js → tttx-data-pattern_1_9_57.cjs.entry.js} +6 -6
  11. package/dist/cjs/{tttx-datacard_1_9_56.cjs.entry.js → tttx-datacard_1_9_57.cjs.entry.js} +5 -5
  12. package/dist/cjs/tttx-date-range-picker.cjs.entry.js +2 -2
  13. package/dist/cjs/{tttx-dialog-box_1_9_56.cjs.entry.js → tttx-dialog-box_1_9_57.cjs.entry.js} +4 -4
  14. package/dist/cjs/{tttx-dialog_1_9_56.cjs.entry.js → tttx-dialog_1_9_57.cjs.entry.js} +3 -3
  15. package/dist/cjs/{tttx-expander_1_9_56.cjs.entry.js → tttx-expander_1_9_57.cjs.entry.js} +3 -3
  16. package/dist/cjs/{tttx-filter_1_9_56_4.cjs.entry.js → tttx-filter_1_9_57_4.cjs.entry.js} +10 -10
  17. package/dist/cjs/{tttx-form_1_9_56.cjs.entry.js → tttx-form_1_9_57.cjs.entry.js} +3 -3
  18. package/dist/cjs/{tttx-graph_1_9_56.cjs.entry.js → tttx-graph_1_9_57.cjs.entry.js} +2 -2
  19. package/dist/cjs/{tttx-icon_1_9_56.cjs.entry.js → tttx-icon_1_9_57.cjs.entry.js} +2 -2
  20. package/dist/cjs/{tttx-keyvalue-block_1_9_56.cjs.entry.js → tttx-keyvalue-block_1_9_57.cjs.entry.js} +2 -2
  21. package/dist/cjs/{tttx-loading-spinner_1_9_56_3.cjs.entry.js → tttx-loading-spinner_1_9_57_3.cjs.entry.js} +7 -7
  22. package/dist/cjs/{tttx-multiselect-box_1_9_56.cjs.entry.js → tttx-multiselect-box_1_9_57.cjs.entry.js} +8 -8
  23. package/dist/cjs/{tttx-percentage-bar_1_9_56.cjs.entry.js → tttx-percentage-bar_1_9_57.cjs.entry.js} +3 -3
  24. package/dist/cjs/{tttx-qrcode_1_9_56.cjs.entry.js → tttx-qrcode_1_9_57.cjs.entry.js} +2 -2
  25. package/dist/cjs/{tttx-select-box_1_9_56.cjs.entry.js → tttx-select-box_1_9_57.cjs.entry.js} +7 -7
  26. package/dist/cjs/{tttx-skeleton_loader_1_9_56.cjs.entry.js → tttx-skeleton_loader_1_9_57.cjs.entry.js} +2 -2
  27. package/dist/cjs/{tttx-table_1_9_56.cjs.entry.js → tttx-table_1_9_57.cjs.entry.js} +2 -2
  28. package/dist/cjs/{tttx-tabs_1_9_56.cjs.entry.js → tttx-tabs_1_9_57.cjs.entry.js} +5 -5
  29. package/dist/cjs/{tttx-textarea_1_9_56.cjs.entry.js → tttx-textarea_1_9_57.cjs.entry.js} +3 -3
  30. package/dist/cjs/{tttx-toggle_1_9_56.cjs.entry.js → tttx-toggle_1_9_57.cjs.entry.js} +2 -2
  31. package/dist/cjs/{tttx-tree-view_1_9_56.cjs.entry.js → tttx-tree-view_1_9_57.cjs.entry.js} +93 -19
  32. package/dist/cjs/tttx.cjs.js +2 -2
  33. package/dist/collection/assets/img/drag-icon.svg +3 -0
  34. package/dist/collection/components/assets/drag-icon.svg +3 -0
  35. package/dist/collection/components/atoms/tttx-button/tttx-button.js +2 -2
  36. package/dist/collection/components/atoms/tttx-button/tttx-button.stories.js +24 -24
  37. package/dist/collection/components/atoms/tttx-checkbox/tttx-checkbox.js +2 -2
  38. package/dist/collection/components/atoms/tttx-checkbox/tttx-checkbox.stories.js +1 -1
  39. package/dist/collection/components/atoms/tttx-datacard/tttx-datacard.js +4 -4
  40. package/dist/collection/components/atoms/tttx-datacard/tttx-datacard.stories.js +10 -10
  41. package/dist/collection/components/atoms/tttx-icon/tttx-icon.js +1 -1
  42. package/dist/collection/components/atoms/tttx-icon/tttx-icon.stories.js +1 -1
  43. package/dist/collection/components/atoms/tttx-keyvalue-block/tttx-keyvalue-block.js +1 -1
  44. package/dist/collection/components/atoms/tttx-keyvalue-block/tttx-keyvalue-block.stories.js +6 -6
  45. package/dist/collection/components/atoms/tttx-loading-spinner/tttx-loading-spinner.js +1 -1
  46. package/dist/collection/components/atoms/tttx-loading-spinner/tttx-loading-spinner.stories.js +2 -2
  47. package/dist/collection/components/atoms/tttx-percentage-bar/tttx-percentage-bar.js +1 -1
  48. package/dist/collection/components/atoms/tttx-percentage-bar/tttx-percentage-bar.stories.js +5 -5
  49. package/dist/collection/components/atoms/tttx-qrcode/tttx-qrcode.js +1 -1
  50. package/dist/collection/components/atoms/tttx-qrcode/tttx-qrcode.stories.js +1 -1
  51. package/dist/collection/components/atoms/tttx-skeleton-loader/tttx-skeleton-loader.js +1 -1
  52. package/dist/collection/components/atoms/tttx-tag/tttx-tag.js +2 -2
  53. package/dist/collection/components/atoms/tttx-tag/tttx-tag.stories.js +6 -6
  54. package/dist/collection/components/atoms/tttx-toggle/tttx-toggle.js +1 -1
  55. package/dist/collection/components/atoms/tttx-toggle/tttx-toggle.stories.js +2 -2
  56. package/dist/collection/components/domsanitiser.options.js +14 -0
  57. package/dist/collection/components/molecules/tttx-action-dropdown/tttx-action-dropdown.js +2 -2
  58. package/dist/collection/components/molecules/tttx-action-dropdown/tttx-action-dropdown.stories.js +1 -1
  59. package/dist/collection/components/molecules/tttx-checkbox-group/components/tttx-checkbox-group-caption.js +1 -1
  60. package/dist/collection/components/molecules/tttx-checkbox-group/components/tttx-checkbox-group-heading.js +1 -1
  61. package/dist/collection/components/molecules/tttx-checkbox-group/tttx-checkbox-group.js +1 -1
  62. package/dist/collection/components/molecules/tttx-checkbox-group/tttx-checkbox-group.stories.js +10 -10
  63. package/dist/collection/components/molecules/tttx-comments/tttx-comments.js +2 -2
  64. package/dist/collection/components/molecules/tttx-comments/tttx-comments.stories.js +2 -2
  65. package/dist/collection/components/molecules/tttx-date-range-picker/tttx-date-range-picker.js +1 -1
  66. package/dist/collection/components/molecules/tttx-dialog/tttx-dialog.js +2 -2
  67. package/dist/collection/components/molecules/tttx-dialog/tttx-dialog.stories.js +6 -6
  68. package/dist/collection/components/molecules/tttx-dialog-box/tttx-dialog-box.js +3 -3
  69. package/dist/collection/components/molecules/tttx-dialog-box/tttx-dialog-box.stories.js +24 -24
  70. package/dist/collection/components/molecules/tttx-expander/tttx-expander.js +2 -2
  71. package/dist/collection/components/molecules/tttx-expander/tttx-expander.stories.js +9 -9
  72. package/dist/collection/components/molecules/tttx-filter/tttx-filter.js +3 -3
  73. package/dist/collection/components/molecules/tttx-filter/tttx-filter.stories.js +2 -2
  74. package/dist/collection/components/molecules/tttx-form/tttx-form.js +2 -2
  75. package/dist/collection/components/molecules/tttx-form/tttx-form.stories.js +8 -8
  76. package/dist/collection/components/molecules/tttx-graph/tttx-graph.js +1 -1
  77. package/dist/collection/components/molecules/tttx-graph/tttx-graph.stories.js +1 -1
  78. package/dist/collection/components/molecules/tttx-list/tttx-list.js +3 -3
  79. package/dist/collection/components/molecules/tttx-list/tttx-list.stories.js +47 -47
  80. package/dist/collection/components/molecules/tttx-multiselect-box/tttx-multiselect-box.js +7 -7
  81. package/dist/collection/components/molecules/tttx-multiselect-box/tttx-multiselect-box.stories.js +37 -37
  82. package/dist/collection/components/molecules/tttx-select-box/tttx-select-box.js +6 -6
  83. package/dist/collection/components/molecules/tttx-select-box/tttx-select-box.stories.js +22 -22
  84. package/dist/collection/components/molecules/tttx-sorter/tttx-sorter.js +2 -2
  85. package/dist/collection/components/molecules/tttx-sorter/tttx-sorter.stories.js +1 -1
  86. package/dist/collection/components/molecules/tttx-standalone-input/tttx-standalone-input.js +4 -4
  87. package/dist/collection/components/molecules/tttx-standalone-input/tttx-standalone-input.stories.js +1 -1
  88. package/dist/collection/components/molecules/tttx-table/tttx-table.js +1 -1
  89. package/dist/collection/components/molecules/tttx-table/tttx-table.stories.js +6 -6
  90. package/dist/collection/components/molecules/tttx-tabs/tttx-tabs.js +3 -3
  91. package/dist/collection/components/molecules/tttx-tabs/tttx-tabs.stories.js +4 -4
  92. package/dist/collection/components/molecules/tttx-textarea/tttx-textarea.js +3 -3
  93. package/dist/collection/components/molecules/tttx-textarea/tttx-textarea.stories.js +1 -1
  94. package/dist/collection/components/molecules/tttx-toolbar/tttx-toolbar.js +1 -1
  95. package/dist/collection/components/molecules/tttx-toolbar/tttx-toolbar.stories.js +37 -37
  96. package/dist/collection/components/molecules/tttx-tree-view/tttx-tree-view.css +9 -0
  97. package/dist/collection/components/molecules/tttx-tree-view/tttx-tree-view.js +111 -18
  98. package/dist/collection/components/molecules/tttx-tree-view/tttx-tree-view.stories.js +35 -532
  99. package/dist/collection/components/organisms/tttx-data-pattern/tttx-data-pattern.js +5 -5
  100. package/dist/collection/components/organisms/tttx-data-pattern/tttx-data-pattern.stories.js +5 -5
  101. package/dist/components/index.d.ts +33 -33
  102. package/dist/components/index.js +33 -33
  103. package/dist/components/tttx-action-dropdown_1_9_57.d.ts +11 -0
  104. package/dist/components/{tttx-action-dropdown_1_9_56.js → tttx-action-dropdown_1_9_57.js} +7 -7
  105. package/dist/components/tttx-button.js +5 -5
  106. package/dist/components/{tttx-dialog_1_9_56.d.ts → tttx-button_1_9_57.d.ts} +4 -4
  107. package/dist/components/{tttx-button_1_9_56.js → tttx-button_1_9_57.js} +2 -2
  108. package/dist/components/tttx-checkbox-group-caption_1_9_57.d.ts +11 -0
  109. package/dist/components/{tttx-checkbox-group-caption_1_9_56.js → tttx-checkbox-group-caption_1_9_57.js} +5 -5
  110. package/dist/components/tttx-checkbox-group-heading_1_9_57.d.ts +11 -0
  111. package/dist/components/{tttx-checkbox-group-heading_1_9_56.js → tttx-checkbox-group-heading_1_9_57.js} +5 -5
  112. package/dist/components/tttx-checkbox-group_1_9_57.d.ts +11 -0
  113. package/dist/components/{tttx-checkbox-group_1_9_56.js → tttx-checkbox-group_1_9_57.js} +5 -5
  114. package/dist/components/{tttx-comments_1_9_56.d.ts → tttx-checkbox_1_9_57.d.ts} +4 -4
  115. package/dist/components/{tttx-checkbox_1_9_56.js → tttx-checkbox_1_9_57.js} +7 -7
  116. package/dist/components/{tttx-datacard_1_9_56.d.ts → tttx-comments_1_9_57.d.ts} +4 -4
  117. package/dist/components/{tttx-comments_1_9_56.js → tttx-comments_1_9_57.js} +7 -7
  118. package/dist/components/tttx-data-pattern_1_9_57.d.ts +11 -0
  119. package/dist/components/{tttx-data-pattern_1_9_56.js → tttx-data-pattern_1_9_57.js} +16 -16
  120. package/dist/components/{tttx-checkbox_1_9_56.d.ts → tttx-datacard_1_9_57.d.ts} +4 -4
  121. package/dist/components/{tttx-datacard_1_9_56.js → tttx-datacard_1_9_57.js} +10 -10
  122. package/dist/components/tttx-date-range-picker.js +3 -3
  123. package/dist/components/tttx-dialog-box_1_9_57.d.ts +11 -0
  124. package/dist/components/{tttx-dialog-box_1_9_56.js → tttx-dialog-box_1_9_57.js} +9 -9
  125. package/dist/components/{tttx-button_1_9_56.d.ts → tttx-dialog_1_9_57.d.ts} +4 -4
  126. package/dist/components/{tttx-dialog_1_9_56.js → tttx-dialog_1_9_57.js} +8 -8
  127. package/dist/components/tttx-expander_1_9_57.d.ts +11 -0
  128. package/dist/components/{tttx-expander_1_9_56.js → tttx-expander_1_9_57.js} +7 -7
  129. package/dist/components/tttx-filter.js +6 -6
  130. package/dist/components/{tttx-filter_1_9_56.d.ts → tttx-filter_1_9_57.d.ts} +4 -4
  131. package/dist/components/{tttx-filter_1_9_56.js → tttx-filter_1_9_57.js} +2 -2
  132. package/dist/components/{tttx-tabs_1_9_56.d.ts → tttx-form_1_9_57.d.ts} +4 -4
  133. package/dist/components/{tttx-form_1_9_56.js → tttx-form_1_9_57.js} +11 -11
  134. package/dist/components/tttx-graph.js +3 -3
  135. package/dist/components/{tttx-graph_1_9_56.d.ts → tttx-graph_1_9_57.d.ts} +4 -4
  136. package/dist/components/{tttx-graph_1_9_56.js → tttx-graph_1_9_57.js} +2 -2
  137. package/dist/components/tttx-icon.js +3 -3
  138. package/dist/components/{tttx-icon_1_9_56.d.ts → tttx-icon_1_9_57.d.ts} +4 -4
  139. package/dist/components/{tttx-icon_1_9_56.js → tttx-icon_1_9_57.js} +2 -2
  140. package/dist/components/tttx-keyvalue-block_1_9_57.d.ts +11 -0
  141. package/dist/components/{tttx-keyvalue-block_1_9_56.js → tttx-keyvalue-block_1_9_57.js} +5 -5
  142. package/dist/components/tttx-list.js +6 -6
  143. package/dist/components/{tttx-list_1_9_56.d.ts → tttx-list_1_9_57.d.ts} +4 -4
  144. package/dist/components/{tttx-list_1_9_56.js → tttx-list_1_9_57.js} +2 -2
  145. package/dist/components/tttx-loading-spinner.js +3 -3
  146. package/dist/components/tttx-loading-spinner_1_9_57.d.ts +11 -0
  147. package/dist/components/{tttx-loading-spinner_1_9_56.js → tttx-loading-spinner_1_9_57.js} +2 -2
  148. package/dist/components/tttx-multiselect-box_1_9_57.d.ts +11 -0
  149. package/dist/components/{tttx-multiselect-box_1_9_56.js → tttx-multiselect-box_1_9_57.js} +16 -16
  150. package/dist/components/tttx-percentage-bar_1_9_57.d.ts +11 -0
  151. package/dist/components/{tttx-percentage-bar_1_9_56.js → tttx-percentage-bar_1_9_57.js} +6 -6
  152. package/dist/components/{tttx-qrcode_1_9_56.d.ts → tttx-qrcode_1_9_57.d.ts} +4 -4
  153. package/dist/components/{tttx-qrcode_1_9_56.js → tttx-qrcode_1_9_57.js} +5 -5
  154. package/dist/components/tttx-select-box.js +12 -12
  155. package/dist/components/tttx-select-box_1_9_57.d.ts +11 -0
  156. package/dist/components/{tttx-select-box_1_9_56.js → tttx-select-box_1_9_57.js} +2 -2
  157. package/dist/components/tttx-skeleton_loader_1_9_57.d.ts +11 -0
  158. package/dist/components/{tttx-skeleton_loader_1_9_56.js → tttx-skeleton_loader_1_9_57.js} +5 -5
  159. package/dist/components/tttx-sorter.js +5 -5
  160. package/dist/components/tttx-sorter_1_9_57.d.ts +11 -0
  161. package/dist/components/{tttx-sorter_1_9_56.js → tttx-sorter_1_9_57.js} +2 -2
  162. package/dist/components/tttx-standalone-input.js +6 -6
  163. package/dist/components/tttx-standalone-input_1_9_57.d.ts +11 -0
  164. package/dist/components/{tttx-standalone-input_1_9_56.js → tttx-standalone-input_1_9_57.js} +2 -2
  165. package/dist/components/{tttx-table_1_9_56.d.ts → tttx-table_1_9_57.d.ts} +4 -4
  166. package/dist/components/{tttx-table_1_9_56.js → tttx-table_1_9_57.js} +5 -5
  167. package/dist/components/{tttx-form_1_9_56.d.ts → tttx-tabs_1_9_57.d.ts} +4 -4
  168. package/dist/components/{tttx-tabs_1_9_56.js → tttx-tabs_1_9_57.js} +9 -9
  169. package/dist/components/tttx-tag.js +5 -5
  170. package/dist/components/{tttx-tag_1_9_56.d.ts → tttx-tag_1_9_57.d.ts} +4 -4
  171. package/dist/components/{tttx-tag_1_9_56.js → tttx-tag_1_9_57.js} +2 -2
  172. package/dist/components/tttx-textarea_1_9_57.d.ts +11 -0
  173. package/dist/components/{tttx-textarea_1_9_56.js → tttx-textarea_1_9_57.js} +6 -6
  174. package/dist/components/tttx-toggle_1_9_57.d.ts +11 -0
  175. package/dist/components/{tttx-toggle_1_9_56.js → tttx-toggle_1_9_57.js} +5 -5
  176. package/dist/components/tttx-toolbar.js +3 -3
  177. package/dist/components/tttx-toolbar_1_9_57.d.ts +11 -0
  178. package/dist/components/{tttx-toolbar_1_9_56.js → tttx-toolbar_1_9_57.js} +2 -2
  179. package/dist/components/tttx-tree-view_1_9_57.d.ts +11 -0
  180. package/dist/components/{tttx-tree-view_1_9_56.js → tttx-tree-view_1_9_57.js} +99 -25
  181. package/dist/esm/{index-b11965d8.js → index-3d473f8b.js} +28 -3
  182. package/dist/esm/loader.js +3 -3
  183. package/dist/esm/{tttx-action-dropdown_1_9_56.entry.js → tttx-action-dropdown_1_9_57.entry.js} +3 -3
  184. package/dist/esm/{tttx-button_1_9_56.entry.js → tttx-button_1_9_57.entry.js} +3 -3
  185. package/dist/esm/{tttx-checkbox-group-caption_1_9_56.entry.js → tttx-checkbox-group-caption_1_9_57.entry.js} +2 -2
  186. package/dist/esm/{tttx-checkbox-group-heading_1_9_56.entry.js → tttx-checkbox-group-heading_1_9_57.entry.js} +2 -2
  187. package/dist/esm/{tttx-checkbox-group_1_9_56.entry.js → tttx-checkbox-group_1_9_57.entry.js} +2 -2
  188. package/dist/esm/{tttx-checkbox_1_9_56.entry.js → tttx-checkbox_1_9_57.entry.js} +3 -3
  189. package/dist/esm/{tttx-comments_1_9_56.entry.js → tttx-comments_1_9_57.entry.js} +3 -3
  190. package/dist/esm/{tttx-data-pattern_1_9_56.entry.js → tttx-data-pattern_1_9_57.entry.js} +6 -6
  191. package/dist/esm/{tttx-datacard_1_9_56.entry.js → tttx-datacard_1_9_57.entry.js} +5 -5
  192. package/dist/esm/tttx-date-range-picker.entry.js +2 -2
  193. package/dist/esm/{tttx-dialog-box_1_9_56.entry.js → tttx-dialog-box_1_9_57.entry.js} +4 -4
  194. package/dist/esm/{tttx-dialog_1_9_56.entry.js → tttx-dialog_1_9_57.entry.js} +3 -3
  195. package/dist/esm/{tttx-expander_1_9_56.entry.js → tttx-expander_1_9_57.entry.js} +3 -3
  196. package/dist/esm/{tttx-filter_1_9_56_4.entry.js → tttx-filter_1_9_57_4.entry.js} +7 -7
  197. package/dist/esm/{tttx-form_1_9_56.entry.js → tttx-form_1_9_57.entry.js} +3 -3
  198. package/dist/esm/{tttx-graph_1_9_56.entry.js → tttx-graph_1_9_57.entry.js} +2 -2
  199. package/dist/esm/{tttx-icon_1_9_56.entry.js → tttx-icon_1_9_57.entry.js} +2 -2
  200. package/dist/esm/{tttx-keyvalue-block_1_9_56.entry.js → tttx-keyvalue-block_1_9_57.entry.js} +2 -2
  201. package/dist/esm/{tttx-loading-spinner_1_9_56_3.entry.js → tttx-loading-spinner_1_9_57_3.entry.js} +5 -5
  202. package/dist/esm/{tttx-multiselect-box_1_9_56.entry.js → tttx-multiselect-box_1_9_57.entry.js} +8 -8
  203. package/dist/esm/{tttx-percentage-bar_1_9_56.entry.js → tttx-percentage-bar_1_9_57.entry.js} +3 -3
  204. package/dist/esm/{tttx-qrcode_1_9_56.entry.js → tttx-qrcode_1_9_57.entry.js} +2 -2
  205. package/dist/esm/{tttx-select-box_1_9_56.entry.js → tttx-select-box_1_9_57.entry.js} +7 -7
  206. package/dist/esm/{tttx-skeleton_loader_1_9_56.entry.js → tttx-skeleton_loader_1_9_57.entry.js} +2 -2
  207. package/dist/esm/{tttx-table_1_9_56.entry.js → tttx-table_1_9_57.entry.js} +2 -2
  208. package/dist/esm/{tttx-tabs_1_9_56.entry.js → tttx-tabs_1_9_57.entry.js} +5 -5
  209. package/dist/esm/{tttx-textarea_1_9_56.entry.js → tttx-textarea_1_9_57.entry.js} +3 -3
  210. package/dist/esm/{tttx-toggle_1_9_56.entry.js → tttx-toggle_1_9_57.entry.js} +2 -2
  211. package/dist/esm/tttx-tree-view_1_9_57.entry.js +203 -0
  212. package/dist/esm/tttx.js +3 -3
  213. package/dist/tttx/{p-b077aa45.entry.js → p-079da884.entry.js} +1 -1
  214. package/dist/tttx/{p-e8b9acb8.entry.js → p-13d3d63c.entry.js} +1 -1
  215. package/dist/tttx/{p-e23f0843.entry.js → p-1814eb61.entry.js} +1 -1
  216. package/dist/tttx/{p-80c3103a.entry.js → p-19294325.entry.js} +1 -1
  217. package/dist/tttx/{p-22150380.entry.js → p-218f3309.entry.js} +1 -1
  218. package/dist/tttx/{p-652aaf6c.entry.js → p-24eef142.entry.js} +1 -1
  219. package/dist/tttx/{p-e5f97b02.entry.js → p-2636cba4.entry.js} +1 -1
  220. package/dist/tttx/p-2b0fc913.js +2 -0
  221. package/dist/tttx/{p-222b7f89.entry.js → p-477b66de.entry.js} +1 -1
  222. package/dist/tttx/{p-1d8210d3.entry.js → p-54060e46.entry.js} +1 -1
  223. package/dist/tttx/{p-7ff42357.entry.js → p-5f35edd8.entry.js} +1 -1
  224. package/dist/tttx/{p-49bae603.entry.js → p-61af5028.entry.js} +1 -1
  225. package/dist/tttx/{p-4560cb86.entry.js → p-67f75171.entry.js} +1 -1
  226. package/dist/tttx/{p-e4b36835.entry.js → p-7bfa4e1e.entry.js} +1 -1
  227. package/dist/tttx/p-7c7e8951.entry.js +1 -0
  228. package/dist/tttx/{p-3f2f039d.entry.js → p-972b7449.entry.js} +1 -1
  229. package/dist/tttx/{p-b2a7e078.entry.js → p-a12aff0f.entry.js} +1 -1
  230. package/dist/tttx/{p-21bb99dd.entry.js → p-a1ba99fb.entry.js} +1 -1
  231. package/dist/tttx/{p-61df30c5.entry.js → p-a474dc05.entry.js} +1 -1
  232. package/dist/tttx/{p-98bee16c.entry.js → p-a800aa5d.entry.js} +1 -1
  233. package/dist/tttx/{p-555885cc.entry.js → p-acb9e007.entry.js} +1 -1
  234. package/dist/tttx/{p-9262d276.entry.js → p-b44ddcb7.entry.js} +1 -1
  235. package/dist/tttx/{p-65da8c2a.entry.js → p-b4b5e1e1.entry.js} +1 -1
  236. package/dist/tttx/{p-354fc8d4.entry.js → p-bbecd0d9.entry.js} +2 -2
  237. package/dist/tttx/{p-6343251b.entry.js → p-bc8c1d08.entry.js} +1 -1
  238. package/dist/tttx/{p-9426547c.entry.js → p-cb3b393b.entry.js} +1 -1
  239. package/dist/tttx/{p-c7ff1887.entry.js → p-d62c8ed2.entry.js} +1 -1
  240. package/dist/tttx/{p-8aeb43df.entry.js → p-e84965f0.entry.js} +1 -1
  241. package/dist/tttx/{p-03c3c654.entry.js → p-edf27c73.entry.js} +1 -1
  242. package/dist/tttx/{p-71372d3a.entry.js → p-f1e945ba.entry.js} +1 -1
  243. package/dist/tttx/tttx.esm.js +1 -1
  244. package/dist/types/components/domsanitiser.options.d.ts +10 -0
  245. package/dist/types/components/molecules/tttx-select-box/tttx-select-box.d.ts +1 -1
  246. package/dist/types/components/molecules/tttx-standalone-input/tttx-standalone-input.d.ts +2 -2
  247. package/dist/types/components/molecules/tttx-textarea/tttx-textarea.d.ts +2 -2
  248. package/dist/types/components/molecules/tttx-tree-view/helper/helper.d.ts +1 -0
  249. package/dist/types/components/molecules/tttx-tree-view/tttx-tree-view.d.ts +14 -2
  250. package/dist/types/components.d.ts +395 -394
  251. package/package.json +2 -2
  252. package/dist/components/tttx-action-dropdown_1_9_56.d.ts +0 -11
  253. package/dist/components/tttx-checkbox-group-caption_1_9_56.d.ts +0 -11
  254. package/dist/components/tttx-checkbox-group-heading_1_9_56.d.ts +0 -11
  255. package/dist/components/tttx-checkbox-group_1_9_56.d.ts +0 -11
  256. package/dist/components/tttx-data-pattern_1_9_56.d.ts +0 -11
  257. package/dist/components/tttx-dialog-box_1_9_56.d.ts +0 -11
  258. package/dist/components/tttx-expander_1_9_56.d.ts +0 -11
  259. package/dist/components/tttx-keyvalue-block_1_9_56.d.ts +0 -11
  260. package/dist/components/tttx-loading-spinner_1_9_56.d.ts +0 -11
  261. package/dist/components/tttx-multiselect-box_1_9_56.d.ts +0 -11
  262. package/dist/components/tttx-percentage-bar_1_9_56.d.ts +0 -11
  263. package/dist/components/tttx-select-box_1_9_56.d.ts +0 -11
  264. package/dist/components/tttx-skeleton_loader_1_9_56.d.ts +0 -11
  265. package/dist/components/tttx-sorter_1_9_56.d.ts +0 -11
  266. package/dist/components/tttx-standalone-input_1_9_56.d.ts +0 -11
  267. package/dist/components/tttx-textarea_1_9_56.d.ts +0 -11
  268. package/dist/components/tttx-toggle_1_9_56.d.ts +0 -11
  269. package/dist/components/tttx-toolbar_1_9_56.d.ts +0 -11
  270. package/dist/components/tttx-tree-view_1_9_56.d.ts +0 -11
  271. package/dist/esm/tttx-tree-view_1_9_56.entry.js +0 -129
  272. package/dist/tttx/p-65bb4035.js +0 -2
  273. package/dist/tttx/p-9896a083.entry.js +0 -1
@@ -1,9 +1,70 @@
1
1
  // eslint-disable-next-line @typescript-eslint/no-unused-vars
2
- import { h, Fragment } from '@stencil/core';
2
+ import { h, Fragment, getAssetPath } from '@stencil/core';
3
3
  import * as DOMPurify from 'dompurify';
4
4
  import domSanitiserOptions from '../../../shared/domsanitiser.options';
5
5
  export class TttxTreeView {
6
6
  constructor() {
7
+ this.dragIcon = getAssetPath('assets/img/drag-icon.svg');
8
+ this.dragGhost = {
9
+ el: null,
10
+ };
11
+ this.createGhostImage = (label) => {
12
+ const ghost = document.createElement('div');
13
+ ghost.textContent = label;
14
+ Object.assign(ghost.style, {
15
+ position: 'absolute',
16
+ top: '-9999px',
17
+ left: '-9999px',
18
+ padding: '6px 20px',
19
+ background: 'white',
20
+ border: '1px solid #ccc',
21
+ fontSize: '14px',
22
+ pointerEvents: 'none',
23
+ });
24
+ document.body.appendChild(ghost);
25
+ setTimeout(() => document.body.removeChild(ghost), 0);
26
+ return ghost;
27
+ };
28
+ this.handleDragStart = (event, node, index, parentId) => {
29
+ if (!event.dataTransfer)
30
+ return;
31
+ this.draggedNodeParentId = parentId;
32
+ const payload = JSON.stringify({ parentId, index, node });
33
+ event.dataTransfer.setData('text/plain', payload);
34
+ const ghostImg = this.createGhostImage(node.title);
35
+ this.dragGhost.el = ghostImg;
36
+ event.dataTransfer.setDragImage(ghostImg, 0, 0);
37
+ };
38
+ this.handleDragDrop = (event, node, targetIndex, parentId) => {
39
+ var _a;
40
+ event.preventDefault();
41
+ const nodeData = (_a = event.dataTransfer) === null || _a === void 0 ? void 0 : _a.getData('text/plain');
42
+ if (!nodeData)
43
+ return;
44
+ const { parentId: sourceParentId, index: sourceParentIndex, node: sourceNode } = JSON.parse(nodeData);
45
+ if (node.id === sourceNode.id || sourceParentId !== parentId)
46
+ return;
47
+ const updatedTree = [...this.treeData];
48
+ const parent = this.findNodeById(updatedTree, parentId);
49
+ const children = [...parent.child];
50
+ const [moved] = children.splice(sourceParentIndex, 1);
51
+ children.splice(targetIndex, 0, moved);
52
+ parent.child = children;
53
+ this.treeData = updatedTree;
54
+ this.draggedNodeParentId = undefined;
55
+ if (this.dragGhost.el) {
56
+ this.dragGhost.el.remove();
57
+ this.dragGhost.el = null;
58
+ }
59
+ this.moveNode.emit(this.treeData);
60
+ };
61
+ this.handleDragOver = (event, parentId) => {
62
+ event.preventDefault();
63
+ if (!event.dataTransfer)
64
+ return;
65
+ const validDrag = this.draggedNodeParentId === parentId;
66
+ event.dataTransfer.dropEffect = validDrag ? 'move' : 'none';
67
+ };
7
68
  this.data = undefined;
8
69
  this.treeData = undefined;
9
70
  }
@@ -53,25 +114,23 @@ export class TttxTreeView {
53
114
  */
54
115
  updateParentCheckStatus(parent = undefined, children = undefined) {
55
116
  if (parent === undefined) {
56
- this.treeData.map((node) => this.updateParentCheckStatus(node, node.child));
117
+ this.treeData.forEach(node => this.updateParentCheckStatus(node, node.child));
57
118
  return;
58
119
  }
59
120
  let childrenCheckedStatuses = [];
60
121
  // set status relative to children if we have some
61
122
  if (children && children.length > 0) {
62
- childrenCheckedStatuses = children
63
- .map((node) => this.updateParentCheckStatus(node, node.child))
64
- .flat(1);
123
+ childrenCheckedStatuses = children.map(node => this.updateParentCheckStatus(node, node.child)).flat(1);
65
124
  // parent checked if any children are checked
66
- if (childrenCheckedStatuses.some((checked) => checked)) {
125
+ if (childrenCheckedStatuses.some(checked => checked)) {
67
126
  parent.checked = true;
68
127
  }
69
128
  // parent unchecked if all children are unchecked
70
- if (childrenCheckedStatuses.every((checked) => !checked)) {
129
+ if (childrenCheckedStatuses.every(checked => !checked)) {
71
130
  parent.checked = false;
72
131
  }
73
132
  }
74
- // return the gathered checked statuses so nodes above can make check choices
133
+ // return the gathered checked statuses so nodes above can make check choices
75
134
  return [...childrenCheckedStatuses, parent.checked];
76
135
  }
77
136
  treeConfigs(node) {
@@ -89,35 +148,48 @@ export class TttxTreeView {
89
148
  const selectedActive = node.selectable && node.selected ? 'rowSelected' : '';
90
149
  return { checkboxColor, checkboxIcon, rowHoverActive, expanderIcon, selectedActive };
91
150
  }
92
- renderNode(node) {
151
+ findNodeById(nodes, id) {
152
+ for (const node of nodes) {
153
+ if (node.id === id)
154
+ return node;
155
+ if (node.child) {
156
+ const found = this.findNodeById(node.child, id);
157
+ if (found)
158
+ return found;
159
+ }
160
+ }
161
+ return undefined;
162
+ }
163
+ renderNode(node, index, parentId = undefined) {
164
+ var _a, _b;
93
165
  const options = this.treeConfigs(node);
94
166
  if (node.child) {
95
- return (h(Fragment, null, h("li", { class: `inline-tree-item element-row tree-node ${options.rowHoverActive} ${options.selectedActive}`, onClick: event => {
167
+ return (h(Fragment, null, h("li", Object.assign({ "data-id": node.id, draggable: (_a = node.draggable) !== null && _a !== void 0 ? _a : false }, (node.draggable ? { onDragOver: event => this.handleDragOver(event, parentId) } : {}), (node.draggable ? { onDrop: event => this.handleDragDrop(event, node, index, parentId) } : {}), { class: `inline-tree-item element-row tree-node ${options.rowHoverActive} ${options.selectedActive}`, onClick: event => {
96
168
  if (node.hasHover) {
97
169
  this.onClickHandler(event, node);
98
170
  }
99
- } }, h("tttx-button_1_9_56", { class: "toggleNode", design: "borderless-circle", notext: true, icon: options.expanderIcon, color: "black", onClick: event => this.toggleNode(node, event) }), this.htmlcode('treeNode', node, options.checkboxIcon, options.checkboxColor)), node.isOpen ? (h("li", null, h("ul", null, node.child.map(childNode => {
100
- return this.renderNode(childNode);
171
+ } }), h("tttx-button_1_9_57", { class: "toggleNode", design: "borderless-circle", notext: true, icon: options.expanderIcon, color: "black", onClick: event => this.toggleNode(node, event) }), this.htmlcode('treeNode', node, options.checkboxIcon, options.checkboxColor, index, parentId)), node.isOpen ? (h("li", null, h("ul", null, node.child.map((childNode, index) => {
172
+ return this.renderNode(childNode, index, node.id);
101
173
  })))) : null));
102
174
  }
103
175
  else {
104
- return (h("li", { class: `inline-tree-item element-row ${options.rowHoverActive} ${options.selectedActive}`, onClick: event => {
176
+ return (h("li", Object.assign({ "data-id": node.id, draggable: (_b = node.draggable) !== null && _b !== void 0 ? _b : false }, (node.draggable ? { onDragOver: event => this.handleDragOver(event, parentId) } : {}), (node.draggable ? { onDrop: event => this.handleDragDrop(event, node, index, parentId) } : {}), { class: `inline-tree-item element-row ${options.rowHoverActive} ${options.selectedActive}`, onClick: event => {
105
177
  if (node.hasHover) {
106
178
  this.onClickHandler(event, node);
107
179
  }
108
- } }, this.htmlcode('treeLeaf', node, options.checkboxIcon, options.checkboxColor)));
180
+ } }), this.htmlcode('treeLeaf', node, options.checkboxIcon, options.checkboxColor, index, parentId)));
109
181
  }
110
182
  }
111
- htmlcode(type, node, check_box, check_boxColor) {
112
- const htmlcode = (h("div", { class: "inline-tree-item element" }, node.hasCheckbox && (h("tttx-button_1_9_56", { design: "borderless-circle", notext: true, icon: check_box, iconcolor: check_boxColor, class: "padding-icon checkbox", onClick: event => this.handleCheckboxChange(node, event) })), !node.html && node.hasIcon && (h("tttx-icon_1_9_56", { icon: node.icon, color: node.iconColor, class: "padding-icon" })), !node.html && h("div", { class: type }, node.title), node.html && h("div", { class: type, innerHTML: DOMPurify.sanitize(node.html, domSanitiserOptions) })));
183
+ htmlcode(type, node, check_box, check_boxColor, index, parentId = undefined) {
184
+ const htmlcode = (h("div", { class: "inline-tree-item element" }, node.draggable && (h("img", { src: this.dragIcon, alt: "drag", class: "drag-handle", draggable: true, onDragStart: event => this.handleDragStart(event, node, index, parentId) })), node.hasCheckbox && (h("tttx-button_1_9_57", { design: "borderless-circle", notext: true, icon: check_box, iconcolor: check_boxColor, class: "padding-icon checkbox", onClick: event => this.handleCheckboxChange(node, event) })), !node.html && node.hasIcon && (h("tttx-icon_1_9_57", { icon: node.icon, color: node.iconColor, class: "padding-icon" })), !node.html && h("div", { class: type }, node.title), node.html && h("div", { class: type, innerHTML: DOMPurify.sanitize(node.html, domSanitiserOptions) })));
113
185
  return htmlcode;
114
186
  }
115
187
  render() {
116
188
  if (!this.data)
117
189
  return;
118
- return (h("div", { class: "tree-view-element" }, h("ul", null, this.treeData.map((node) => this.renderNode(node)))));
190
+ return (h("div", { class: "tree-view-element" }, h("ul", null, this.treeData.map((node, index) => this.renderNode(node, index)))));
119
191
  }
120
- static get is() { return "tttx-tree-view_1_9_56"; }
192
+ static get is() { return "tttx-tree-view_1_9_57"; }
121
193
  static get encapsulation() { return "shadow"; }
122
194
  static get originalStyleUrls() {
123
195
  return {
@@ -219,6 +291,27 @@ export class TttxTreeView {
219
291
  }
220
292
  }
221
293
  }
294
+ }, {
295
+ "method": "moveNode",
296
+ "name": "moveNode",
297
+ "bubbles": true,
298
+ "cancelable": true,
299
+ "composed": true,
300
+ "docs": {
301
+ "tags": [],
302
+ "text": ""
303
+ },
304
+ "complexType": {
305
+ "original": "TreeViewItem[]",
306
+ "resolved": "TreeViewItem[]",
307
+ "references": {
308
+ "TreeViewItem": {
309
+ "location": "import",
310
+ "path": "./helper/helper"
311
+ }
312
+ }
313
+ }
222
314
  }];
223
315
  }
316
+ static get elementRef() { return "el"; }
224
317
  }