@xplor-education/core-stencil-components 3.1.1 → 3.1.3

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 (263) hide show
  1. package/components/index.js +28 -3
  2. package/components/index.js.map +1 -1
  3. package/components/{p-B49oUO_9.js → p-AzuDJugb.js} +3 -3
  4. package/components/{p-B49oUO_9.js.map → p-AzuDJugb.js.map} +1 -1
  5. package/components/{p-D4jVa8dE.js → p-BQ6aLuGP.js} +4 -4
  6. package/components/{p-D4jVa8dE.js.map → p-BQ6aLuGP.js.map} +1 -1
  7. package/components/{p-VIJbFoA4.js → p-BZQ63ULK.js} +3 -3
  8. package/components/{p-VIJbFoA4.js.map → p-BZQ63ULK.js.map} +1 -1
  9. package/components/{p-Bs_ocvfe.js → p-CyGsSa4H.js} +7 -4
  10. package/components/p-CyGsSa4H.js.map +1 -0
  11. package/components/{p-B3zR7peH.js → p-oanCZPh6.js} +4 -4
  12. package/components/{p-B3zR7peH.js.map → p-oanCZPh6.js.map} +1 -1
  13. package/components/xplor-alert-message.js +2 -2
  14. package/components/xplor-avatar-and-name.js +2 -2
  15. package/components/xplor-avatar.js +1 -1
  16. package/components/xplor-badge-active.js +1 -1
  17. package/components/xplor-badge-archived.js +1 -1
  18. package/components/xplor-badge-deleted.js +1 -1
  19. package/components/xplor-badge-expired.js +1 -1
  20. package/components/xplor-badge-inactive.js +1 -1
  21. package/components/xplor-badge-recalled.js +1 -1
  22. package/components/xplor-badge-upcoming.js +1 -1
  23. package/components/xplor-badge-waitlist.js +1 -1
  24. package/components/xplor-badge.js +1 -1
  25. package/components/xplor-btn-back-to-parent.js +1 -1
  26. package/components/xplor-btn-back.js +1 -1
  27. package/components/xplor-btn-icon.js +1 -1
  28. package/components/xplor-btn-toggle-group.js +1 -1
  29. package/components/xplor-btn-toggle-secondary.js +1 -1
  30. package/components/xplor-btn-toggle.js +1 -1
  31. package/components/xplor-btn-tooltip.js +3 -3
  32. package/components/xplor-button.js +1 -1
  33. package/components/xplor-canvas-editor.d.ts +11 -0
  34. package/components/xplor-canvas-editor.js +369 -0
  35. package/components/xplor-canvas-editor.js.map +1 -0
  36. package/components/xplor-chat-widget.js +3 -3
  37. package/components/xplor-checkbox.js +1 -1
  38. package/components/xplor-combobox.js +5 -5
  39. package/components/xplor-datatable.js +2 -2
  40. package/components/xplor-date-picker.js +5 -5
  41. package/components/xplor-drag-and-drop-input.js +26 -5
  42. package/components/xplor-drag-and-drop-input.js.map +1 -1
  43. package/components/xplor-dropdown.js +1 -1
  44. package/components/xplor-expansion-panel.js +4 -4
  45. package/components/xplor-expansion-panels.js +1 -1
  46. package/components/xplor-file-upload.js +2 -2
  47. package/components/xplor-inline-checkbox.js +2 -2
  48. package/components/xplor-inline-date-picker.js +1 -1
  49. package/components/xplor-inline-switch.js +1 -1
  50. package/components/xplor-input-file.js +1 -1
  51. package/components/xplor-input-search.js +2 -2
  52. package/components/xplor-input-select.js +2 -2
  53. package/components/xplor-input-send.js +3 -3
  54. package/components/xplor-input-text-area.js +6 -3
  55. package/components/xplor-input-text-area.js.map +1 -1
  56. package/components/xplor-input-text-secondary.js +2 -2
  57. package/components/xplor-input-text.js +6 -3
  58. package/components/xplor-input-text.js.map +1 -1
  59. package/components/xplor-input-title.js +1 -1
  60. package/components/xplor-links.js +1 -1
  61. package/components/xplor-modal-persistent.js +1 -1
  62. package/components/xplor-nav-tabs.js +2 -2
  63. package/components/xplor-radio-btn.js +2 -2
  64. package/components/xplor-rich-text-editor.d.ts +11 -0
  65. package/components/xplor-rich-text-editor.js +23754 -0
  66. package/components/xplor-rich-text-editor.js.map +1 -0
  67. package/components/xplor-section-card.js +2 -2
  68. package/components/xplor-section-heading.js +2 -2
  69. package/components/xplor-table.js +5 -5
  70. package/components/xplor-text-bubble.js +2 -2
  71. package/components/xplor-text-field.js +2 -2
  72. package/components/xplor-time-picker.js +6 -6
  73. package/components/xplor-tooltip.js +1 -1
  74. package/dist/cjs/{index-BjAapk2n.js → index--_m3aUsf.js} +32 -7
  75. package/dist/cjs/index--_m3aUsf.js.map +1 -0
  76. package/dist/cjs/loader.cjs.js +2 -2
  77. package/dist/cjs/xplor-alert-dialog_60.cjs.entry.js +29457 -0
  78. package/dist/cjs/xplor-alert-dialog_60.cjs.entry.js.map +1 -0
  79. package/dist/cjs/xplor-component-library.cjs.js +2 -2
  80. package/dist/collection/collection-manifest.json +2 -0
  81. package/dist/collection/components/xplor-alert-message/xplor-alert-message.js +2 -2
  82. package/dist/collection/components/xplor-autocomplete/xplor-autocomplete.js +4 -4
  83. package/dist/collection/components/xplor-avatar/xplor-avatar.js +2 -2
  84. package/dist/collection/components/xplor-avatar-and-name/xplor-avatar-and-name.js +1 -1
  85. package/dist/collection/components/xplor-badge/xplor-badge.js +1 -1
  86. package/dist/collection/components/xplor-badge-active/xplor-badge-active.js +1 -1
  87. package/dist/collection/components/xplor-badge-archived/xplor-badge-archived.js +1 -1
  88. package/dist/collection/components/xplor-badge-deleted/xplor-badge-deleted.js +1 -1
  89. package/dist/collection/components/xplor-badge-expired/xplor-badge-expired.js +1 -1
  90. package/dist/collection/components/xplor-badge-inactive/xplor-badge-inactive.js +1 -1
  91. package/dist/collection/components/xplor-badge-recalled/xplor-badge-recalled.js +1 -1
  92. package/dist/collection/components/xplor-badge-session-booking/xplor-badge-session-booking.js +2 -2
  93. package/dist/collection/components/xplor-badge-upcoming/xplor-badge-upcoming.js +1 -1
  94. package/dist/collection/components/xplor-badge-waitlist/xplor-badge-waitlist.js +1 -1
  95. package/dist/collection/components/xplor-btn-back/xplor-btn-back.js +1 -1
  96. package/dist/collection/components/xplor-btn-back-to-parent/xplor-btn-back-to-parent.js +1 -1
  97. package/dist/collection/components/xplor-btn-icon/xplor-btn-icon.js +1 -1
  98. package/dist/collection/components/xplor-btn-menu/xplor-btn-menu.js +2 -2
  99. package/dist/collection/components/xplor-btn-toggle/xplor-btn-toggle.js +1 -1
  100. package/dist/collection/components/xplor-btn-toggle-group/xplor-btn-toggle-group.js +1 -1
  101. package/dist/collection/components/xplor-btn-toggle-secondary/xplor-btn-toggle-secondary.js +1 -1
  102. package/dist/collection/components/xplor-btn-tooltip/xplor-btn-tooltip.js +1 -1
  103. package/dist/collection/components/xplor-button/xplor-button.css +8 -3
  104. package/dist/collection/components/xplor-button/xplor-button.js +23 -1
  105. package/dist/collection/components/xplor-button/xplor-button.js.map +1 -1
  106. package/dist/collection/components/xplor-canvas-editor/xplor-canvas-editor.css +1224 -0
  107. package/dist/collection/components/xplor-canvas-editor/xplor-canvas-editor.js +520 -0
  108. package/dist/collection/components/xplor-canvas-editor/xplor-canvas-editor.js.map +1 -0
  109. package/dist/collection/components/xplor-canvas-editor/xplor-canvas-editor.stories.js +280 -0
  110. package/dist/collection/components/xplor-canvas-editor/xplor-canvas-editor.stories.js.map +1 -0
  111. package/dist/collection/components/xplor-chat-widget/xplor-chat-widget.js +1 -1
  112. package/dist/collection/components/xplor-checkbox/xplor-checkbox.js +1 -1
  113. package/dist/collection/components/xplor-combobox/xplor-combobox.js +7 -7
  114. package/dist/collection/components/xplor-datatable/xplor-datatable.js +5 -5
  115. package/dist/collection/components/xplor-date-picker/xplor-date-picker.js +4 -4
  116. package/dist/collection/components/xplor-drag-and-drop-input/xplor-drag-and-drop-input.css +62 -29
  117. package/dist/collection/components/xplor-drag-and-drop-input/xplor-drag-and-drop-input.js +25 -4
  118. package/dist/collection/components/xplor-drag-and-drop-input/xplor-drag-and-drop-input.js.map +1 -1
  119. package/dist/collection/components/xplor-dropdown/xplor-dropdown.js +1 -1
  120. package/dist/collection/components/xplor-expansion-panel/xplor-expansion-panel.js +4 -4
  121. package/dist/collection/components/xplor-expansion-panels/xplor-expansion-panels.js +1 -1
  122. package/dist/collection/components/xplor-file-upload/xplor-file-upload.js +4 -4
  123. package/dist/collection/components/xplor-inline-checkbox/xplor-inline-checkbox.js +2 -2
  124. package/dist/collection/components/xplor-inline-date-picker/xplor-inline-date-picker.js +1 -1
  125. package/dist/collection/components/xplor-inline-switch/xplor-inline-switch.js +1 -1
  126. package/dist/collection/components/xplor-input-file/xplor-input-file.js +1 -1
  127. package/dist/collection/components/xplor-input-search/xplor-input-search.js +2 -2
  128. package/dist/collection/components/xplor-input-select/xplor-input-select.js +3 -3
  129. package/dist/collection/components/xplor-input-send/xplor-input-send.js +2 -2
  130. package/dist/collection/components/xplor-input-text/xplor-input-text.css +41 -13
  131. package/dist/collection/components/xplor-input-text/xplor-input-text.js +5 -2
  132. package/dist/collection/components/xplor-input-text/xplor-input-text.js.map +1 -1
  133. package/dist/collection/components/xplor-input-text-area/xplor-input-text-area.css +39 -13
  134. package/dist/collection/components/xplor-input-text-area/xplor-input-text-area.js +5 -2
  135. package/dist/collection/components/xplor-input-text-area/xplor-input-text-area.js.map +1 -1
  136. package/dist/collection/components/xplor-input-text-secondary/xplor-input-text-secondary.js +2 -2
  137. package/dist/collection/components/xplor-input-title/xplor-input-title.js +1 -1
  138. package/dist/collection/components/xplor-links/xplor-links.js +1 -1
  139. package/dist/collection/components/xplor-modal-persistent/xplor-modal-persistent.js +1 -1
  140. package/dist/collection/components/xplor-nav-tabs/xplor-nav-tabs.js +3 -3
  141. package/dist/collection/components/xplor-radio-btn/xplor-radio-btn.js +2 -2
  142. package/dist/collection/components/xplor-rich-text-editor/xplor-rich-text-editor.css +1445 -0
  143. package/dist/collection/components/xplor-rich-text-editor/xplor-rich-text-editor.js +800 -0
  144. package/dist/collection/components/xplor-rich-text-editor/xplor-rich-text-editor.js.map +1 -0
  145. package/dist/collection/components/xplor-rich-text-editor/xplor-rich-text-editor.stories.js +260 -0
  146. package/dist/collection/components/xplor-rich-text-editor/xplor-rich-text-editor.stories.js.map +1 -0
  147. package/dist/collection/components/xplor-section-card/xplor-section-card.js +2 -2
  148. package/dist/collection/components/xplor-section-heading/xplor-section-heading.js +2 -2
  149. package/dist/collection/components/xplor-table/xplor-table.js +5 -5
  150. package/dist/collection/components/xplor-text-bubble/xplor-text-bubble.js +2 -2
  151. package/dist/collection/components/xplor-text-field/xplor-text-field.js +2 -2
  152. package/dist/collection/components/xplor-time-picker/xplor-time-picker.js +6 -6
  153. package/dist/collection/components/xplor-tooltip/xplor-tooltip.js +4 -4
  154. package/dist/collection/utils/slate-legacy-converter.js +223 -0
  155. package/dist/collection/utils/slate-legacy-converter.js.map +1 -0
  156. package/dist/components/index.js +28 -3
  157. package/dist/components/index.js.map +1 -1
  158. package/dist/components/{p--zhT6rvJ.js → p-DGaHlr-k.js} +4 -4
  159. package/dist/components/{p--zhT6rvJ.js.map → p-DGaHlr-k.js.map} +1 -1
  160. package/dist/components/{p-B5rS_jjI.js → p-DWaTb2EJ.js} +7 -4
  161. package/dist/components/p-DWaTb2EJ.js.map +1 -0
  162. package/dist/components/{p-J41B2nOt.js → p-DroQBoSo.js} +3 -3
  163. package/dist/components/{p-J41B2nOt.js.map → p-DroQBoSo.js.map} +1 -1
  164. package/dist/components/{p-DQ8MCJFX.js → p-TfYzqGwr.js} +3 -3
  165. package/dist/components/{p-DQ8MCJFX.js.map → p-TfYzqGwr.js.map} +1 -1
  166. package/dist/components/{p-DbQ6ZNvh.js → p-vl-J3tKJ.js} +4 -4
  167. package/dist/components/{p-DbQ6ZNvh.js.map → p-vl-J3tKJ.js.map} +1 -1
  168. package/dist/components/xplor-alert-message.js +2 -2
  169. package/dist/components/xplor-avatar-and-name.js +2 -2
  170. package/dist/components/xplor-avatar.js +1 -1
  171. package/dist/components/xplor-badge-active.js +1 -1
  172. package/dist/components/xplor-badge-archived.js +1 -1
  173. package/dist/components/xplor-badge-deleted.js +1 -1
  174. package/dist/components/xplor-badge-expired.js +1 -1
  175. package/dist/components/xplor-badge-inactive.js +1 -1
  176. package/dist/components/xplor-badge-recalled.js +1 -1
  177. package/dist/components/xplor-badge-upcoming.js +1 -1
  178. package/dist/components/xplor-badge-waitlist.js +1 -1
  179. package/dist/components/xplor-badge.js +1 -1
  180. package/dist/components/xplor-btn-back-to-parent.js +1 -1
  181. package/dist/components/xplor-btn-back.js +1 -1
  182. package/dist/components/xplor-btn-icon.js +1 -1
  183. package/dist/components/xplor-btn-toggle-group.js +1 -1
  184. package/dist/components/xplor-btn-toggle-secondary.js +1 -1
  185. package/dist/components/xplor-btn-toggle.js +1 -1
  186. package/dist/components/xplor-btn-tooltip.js +3 -3
  187. package/dist/components/xplor-button.js +1 -1
  188. package/dist/components/xplor-canvas-editor.d.ts +11 -0
  189. package/dist/components/xplor-canvas-editor.js +370 -0
  190. package/dist/components/xplor-canvas-editor.js.map +1 -0
  191. package/dist/components/xplor-chat-widget.js +3 -3
  192. package/dist/components/xplor-checkbox.js +1 -1
  193. package/dist/components/xplor-combobox.js +5 -5
  194. package/dist/components/xplor-datatable.js +2 -2
  195. package/dist/components/xplor-date-picker.js +5 -5
  196. package/dist/components/xplor-drag-and-drop-input.js +26 -5
  197. package/dist/components/xplor-drag-and-drop-input.js.map +1 -1
  198. package/dist/components/xplor-dropdown.js +1 -1
  199. package/dist/components/xplor-expansion-panel.js +4 -4
  200. package/dist/components/xplor-expansion-panels.js +1 -1
  201. package/dist/components/xplor-file-upload.js +2 -2
  202. package/dist/components/xplor-inline-checkbox.js +2 -2
  203. package/dist/components/xplor-inline-date-picker.js +1 -1
  204. package/dist/components/xplor-inline-switch.js +1 -1
  205. package/dist/components/xplor-input-file.js +1 -1
  206. package/dist/components/xplor-input-search.js +2 -2
  207. package/dist/components/xplor-input-select.js +2 -2
  208. package/dist/components/xplor-input-send.js +3 -3
  209. package/dist/components/xplor-input-text-area.js +6 -3
  210. package/dist/components/xplor-input-text-area.js.map +1 -1
  211. package/dist/components/xplor-input-text-secondary.js +2 -2
  212. package/dist/components/xplor-input-text.js +6 -3
  213. package/dist/components/xplor-input-text.js.map +1 -1
  214. package/dist/components/xplor-input-title.js +1 -1
  215. package/dist/components/xplor-links.js +1 -1
  216. package/dist/components/xplor-modal-persistent.js +1 -1
  217. package/dist/components/xplor-nav-tabs.js +2 -2
  218. package/dist/components/xplor-radio-btn.js +2 -2
  219. package/dist/components/xplor-rich-text-editor.d.ts +11 -0
  220. package/dist/components/xplor-rich-text-editor.js +23755 -0
  221. package/dist/components/xplor-rich-text-editor.js.map +1 -0
  222. package/dist/components/xplor-section-card.js +2 -2
  223. package/dist/components/xplor-section-heading.js +2 -2
  224. package/dist/components/xplor-table.js +5 -5
  225. package/dist/components/xplor-text-bubble.js +2 -2
  226. package/dist/components/xplor-text-field.js +2 -2
  227. package/dist/components/xplor-time-picker.js +6 -6
  228. package/dist/components/xplor-tooltip.js +1 -1
  229. package/dist/esm/{index-KRfMjDC2.js → index-QwDfQUbw.js} +32 -7
  230. package/dist/esm/index-QwDfQUbw.js.map +1 -0
  231. package/dist/esm/loader.js +3 -3
  232. package/dist/esm/xplor-alert-dialog_60.entry.js +29396 -0
  233. package/dist/esm/xplor-alert-dialog_60.entry.js.map +1 -0
  234. package/dist/esm/xplor-component-library.js +3 -3
  235. package/dist/hydrate/index.js +24238 -97
  236. package/dist/hydrate/index.mjs +24238 -97
  237. package/dist/types/components/xplor-button/xplor-button.d.ts +2 -0
  238. package/dist/types/components/xplor-canvas-editor/xplor-canvas-editor.d.ts +63 -0
  239. package/dist/types/components/xplor-canvas-editor/xplor-canvas-editor.stories.d.ts +84 -0
  240. package/dist/types/components/xplor-drag-and-drop-input/xplor-drag-and-drop-input.d.ts +6 -0
  241. package/dist/types/components/xplor-rich-text-editor/xplor-rich-text-editor.d.ts +129 -0
  242. package/dist/types/components/xplor-rich-text-editor/xplor-rich-text-editor.stories.d.ts +105 -0
  243. package/dist/types/components.d.ts +290 -0
  244. package/dist/types/utils/slate-legacy-converter.d.ts +83 -0
  245. package/dist/xplor-component-library/p-QwDfQUbw.js +3 -0
  246. package/dist/xplor-component-library/p-QwDfQUbw.js.map +1 -0
  247. package/dist/xplor-component-library/p-df68ccde.entry.js +2 -0
  248. package/dist/xplor-component-library/p-df68ccde.entry.js.map +1 -0
  249. package/dist/xplor-component-library/xplor-component-library.css +1 -1
  250. package/dist/xplor-component-library/xplor-component-library.esm.js +1 -1
  251. package/package.json +7 -1
  252. package/components/p-Bs_ocvfe.js.map +0 -1
  253. package/dist/cjs/index-BjAapk2n.js.map +0 -1
  254. package/dist/cjs/xplor-alert-dialog_58.cjs.entry.js +0 -5389
  255. package/dist/cjs/xplor-alert-dialog_58.cjs.entry.js.map +0 -1
  256. package/dist/components/p-B5rS_jjI.js.map +0 -1
  257. package/dist/esm/index-KRfMjDC2.js.map +0 -1
  258. package/dist/esm/xplor-alert-dialog_58.entry.js +0 -5330
  259. package/dist/esm/xplor-alert-dialog_58.entry.js.map +0 -1
  260. package/dist/xplor-component-library/p-5b0cee73.entry.js +0 -2
  261. package/dist/xplor-component-library/p-5b0cee73.entry.js.map +0 -1
  262. package/dist/xplor-component-library/p-KRfMjDC2.js +0 -3
  263. package/dist/xplor-component-library/p-KRfMjDC2.js.map +0 -1
@@ -0,0 +1,280 @@
1
+ export default {
2
+ title: 'Components/Canvas Editor',
3
+ tags: ['autodocs'],
4
+ parameters: {
5
+ actions: {
6
+ handles: ['xplorShapeAdd', 'xplorShapeRemove', 'xplorShapeChange'],
7
+ },
8
+ docs: {
9
+ description: {
10
+ component: `
11
+ An SVG-based canvas editor for drawing and managing shapes. Fully accessible (WCAG 2.1 AA),
12
+ framework-agnostic, and compatible with Vue, React, and Angular.
13
+
14
+ ## Features
15
+ - Draw rectangles, ellipses, and lines by clicking and dragging
16
+ - Select and delete shapes with mouse or keyboard (Del / Backspace)
17
+ - Resize selected shapes using 8 directional handles
18
+ - Toolbar with tool selection, delete, and clear-all actions
19
+ - Full keyboard and screen reader support
20
+
21
+ ## Usage
22
+ \`\`\`html
23
+ <xplor-canvas-editor
24
+ width="800"
25
+ height="500"
26
+ tool="select"
27
+ ></xplor-canvas-editor>
28
+ \`\`\`
29
+
30
+ ## Events
31
+ | Event | Payload | Description |
32
+ |---|---|---|
33
+ | \`xplorShapeAdd\` | \`Shape\` | Emitted when a new shape is drawn |
34
+ | \`xplorShapeRemove\` | \`string\` (id) | Emitted when a shape is deleted |
35
+ | \`xplorShapeChange\` | \`Shape\` | Emitted when a shape is resized |
36
+
37
+ ## Public Methods
38
+ | Method | Returns | Description |
39
+ |---|---|---|
40
+ | \`getShapes()\` | \`Promise<Shape[]>\` | Returns all current shapes |
41
+ | \`clearAll()\` | \`Promise<void>\` | Removes all shapes |
42
+
43
+ ## CSS Custom Properties
44
+ | Property | Default | Description |
45
+ |---|---|---|
46
+ | \`--canvas-bg\` | \`#ffffff\` | Canvas background colour |
47
+ | \`--canvas-border\` | \`#e5e7eb\` | Border colour |
48
+ | \`--selection-color\` | \`#2196f3\` | Selection outline / handle accent colour |
49
+ | \`--handle-size\` | \`5\` | Resize handle radius (SVG units) |
50
+ | \`--handle-fill\` | \`#ffffff\` | Resize handle fill |
51
+ | \`--handle-stroke\` | \`#2196f3\` | Resize handle stroke |
52
+ `,
53
+ },
54
+ },
55
+ },
56
+ argTypes: {
57
+ width: {
58
+ control: { type: 'number', min: 200, max: 1600, step: 50 },
59
+ description: 'Canvas width in pixels',
60
+ },
61
+ height: {
62
+ control: { type: 'number', min: 100, max: 1000, step: 50 },
63
+ description: 'Canvas height in pixels',
64
+ },
65
+ tool: {
66
+ control: { type: 'select' },
67
+ options: ['select', 'rect', 'circle', 'line'],
68
+ description: 'Initially active drawing tool',
69
+ },
70
+ },
71
+ };
72
+ // ---------------------------------------------------------------------------
73
+ // Template helper
74
+ // ---------------------------------------------------------------------------
75
+ const Template = (args) => {
76
+ const attrs = Object.entries(args)
77
+ .filter(([, v]) => v !== undefined && v !== '' && v !== false)
78
+ .map(([k, v]) => {
79
+ const attr = k.replace(/([A-Z])/g, '-$1').toLowerCase();
80
+ if (typeof v === 'boolean')
81
+ return v ? attr : '';
82
+ return `${attr}="${v}"`;
83
+ })
84
+ .filter(Boolean)
85
+ .join(' ');
86
+ return `<xplor-canvas-editor ${attrs}></xplor-canvas-editor>`;
87
+ };
88
+ // ---------------------------------------------------------------------------
89
+ // Default — select tool, standard size
90
+ // ---------------------------------------------------------------------------
91
+ export const Default = Template.bind({});
92
+ Default.args = {
93
+ width: 800,
94
+ height: 500,
95
+ tool: 'select',
96
+ };
97
+ Default.storyName = 'Default (select tool)';
98
+ Default.parameters = {
99
+ docs: {
100
+ description: {
101
+ story: 'The default state. Switch to a drawing tool in the toolbar, then click and drag on the canvas to create shapes.',
102
+ },
103
+ },
104
+ };
105
+ // ---------------------------------------------------------------------------
106
+ // Draw Mode — starts with rect tool active
107
+ // ---------------------------------------------------------------------------
108
+ export const DrawMode = Template.bind({});
109
+ DrawMode.args = {
110
+ width: 800,
111
+ height: 500,
112
+ tool: 'rect',
113
+ };
114
+ DrawMode.storyName = 'Draw Mode (rect)';
115
+ DrawMode.parameters = {
116
+ docs: {
117
+ description: {
118
+ story: 'Opens with the Rectangle tool already active. Click and drag on the canvas to draw rectangles immediately.',
119
+ },
120
+ },
121
+ };
122
+ // ---------------------------------------------------------------------------
123
+ // Circle / Ellipse tool
124
+ // ---------------------------------------------------------------------------
125
+ export const CircleTool = Template.bind({});
126
+ CircleTool.args = {
127
+ width: 800,
128
+ height: 500,
129
+ tool: 'circle',
130
+ };
131
+ CircleTool.storyName = 'Circle / Ellipse tool';
132
+ CircleTool.parameters = {
133
+ docs: {
134
+ description: {
135
+ story: 'Opens with the Circle/Ellipse tool active. Drag to define the bounding box of the ellipse.',
136
+ },
137
+ },
138
+ };
139
+ // ---------------------------------------------------------------------------
140
+ // Line tool
141
+ // ---------------------------------------------------------------------------
142
+ export const LineTool = Template.bind({});
143
+ LineTool.args = {
144
+ width: 800,
145
+ height: 500,
146
+ tool: 'line',
147
+ };
148
+ LineTool.storyName = 'Line tool';
149
+ LineTool.parameters = {
150
+ docs: {
151
+ description: {
152
+ story: 'Opens with the Line tool active. Click the start point and drag to the end point.',
153
+ },
154
+ },
155
+ };
156
+ // ---------------------------------------------------------------------------
157
+ // Small canvas
158
+ // ---------------------------------------------------------------------------
159
+ export const SmallCanvas = Template.bind({});
160
+ SmallCanvas.args = {
161
+ width: 400,
162
+ height: 300,
163
+ tool: 'select',
164
+ };
165
+ SmallCanvas.storyName = 'Small canvas (400×300)';
166
+ SmallCanvas.parameters = {
167
+ docs: {
168
+ description: {
169
+ story: 'Demonstrates a compact canvas size.',
170
+ },
171
+ },
172
+ };
173
+ // ---------------------------------------------------------------------------
174
+ // Wide canvas
175
+ // ---------------------------------------------------------------------------
176
+ export const WideCanvas = Template.bind({});
177
+ WideCanvas.args = {
178
+ width: 1200,
179
+ height: 500,
180
+ tool: 'select',
181
+ };
182
+ WideCanvas.storyName = 'Wide canvas (1200×500)';
183
+ WideCanvas.parameters = {
184
+ docs: {
185
+ description: {
186
+ story: 'A wider canvas. The SVG wrapper scrolls horizontally if the canvas exceeds the viewport.',
187
+ },
188
+ },
189
+ };
190
+ // ---------------------------------------------------------------------------
191
+ // Pre-loaded shapes (via JS injection — showcases shape rendering)
192
+ // ---------------------------------------------------------------------------
193
+ export const PreloadedShapes = () => `
194
+ <div style="display:inline-block;">
195
+ <xplor-canvas-editor
196
+ id="preloaded-canvas"
197
+ width="800"
198
+ height="500"
199
+ tool="select"
200
+ ></xplor-canvas-editor>
201
+ </div>
202
+ <script>
203
+ (function () {
204
+ var el = document.getElementById('preloaded-canvas');
205
+ // Wait for Stencil hydration
206
+ customElements.whenDefined('xplor-canvas-editor').then(function () {
207
+ // Directly set internal state via a workaround — for demo purposes only.
208
+ // In real integrations, shapes should be drawn by the user or managed via getShapes()/clearAll().
209
+ var preloaded = [
210
+ { id: 'pre-1', type: 'rect', x: 40, y: 40, width: 160, height: 100, fill: 'rgba(33,150,243,0.25)', stroke: '#1976d2' },
211
+ { id: 'pre-2', type: 'circle', x: 260, y: 60, width: 140, height: 120, fill: 'rgba(76,175,80,0.25)', stroke: '#388e3c' },
212
+ { id: 'pre-3', type: 'line', x: 50, y: 220, width: 300, height: 200, fill: 'none', stroke: '#f44336' },
213
+ { id: 'pre-4', type: 'rect', x: 430, y: 80, width: 180, height: 130, fill: 'rgba(156,39,176,0.25)', stroke: '#7b1fa2' },
214
+ ];
215
+ if (el && el.__stencilInstance) {
216
+ el.__stencilInstance.shapes = preloaded;
217
+ }
218
+ });
219
+ })();
220
+ </script>
221
+ `;
222
+ PreloadedShapes.storyName = 'Pre-loaded shapes';
223
+ PreloadedShapes.parameters = {
224
+ docs: {
225
+ description: {
226
+ story: 'Demonstrates how all three shape types (rect, ellipse, line) are rendered. Use the Select tool and click a shape to see resize handles.',
227
+ },
228
+ },
229
+ };
230
+ // ---------------------------------------------------------------------------
231
+ // Dark mode
232
+ // ---------------------------------------------------------------------------
233
+ export const DarkMode = () => `
234
+ <div class="dark" style="background:#1e1e2e; padding:2rem; border-radius:0.5rem; display:inline-block;">
235
+ <xplor-canvas-editor
236
+ class="dark"
237
+ width="800"
238
+ height="500"
239
+ tool="select"
240
+ ></xplor-canvas-editor>
241
+ </div>
242
+ `;
243
+ DarkMode.storyName = 'Dark mode';
244
+ DarkMode.parameters = {
245
+ backgrounds: { default: 'dark' },
246
+ docs: {
247
+ description: {
248
+ story: 'Apply the `.dark` CSS class to the host element or an ancestor to activate dark mode colour tokens.',
249
+ },
250
+ },
251
+ };
252
+ // ---------------------------------------------------------------------------
253
+ // Custom CSS tokens
254
+ // ---------------------------------------------------------------------------
255
+ export const CustomTokens = () => `
256
+ <xplor-canvas-editor
257
+ width="800"
258
+ height="500"
259
+ tool="rect"
260
+ style="
261
+ --canvas-bg: #fdf6ec;
262
+ --canvas-border: #f5c68a;
263
+ --selection-color: #f57c00;
264
+ --handle-stroke: #f57c00;
265
+ --canvas-toolbar-bg: #fff8f0;
266
+ --canvas-toolbar-border: #f5c68a;
267
+ --canvas-btn-active-bg: rgba(245,124,0,0.1);
268
+ --canvas-btn-active-color: #f57c00;
269
+ "
270
+ ></xplor-canvas-editor>
271
+ `;
272
+ CustomTokens.storyName = 'Custom CSS tokens (orange theme)';
273
+ CustomTokens.parameters = {
274
+ docs: {
275
+ description: {
276
+ story: 'Override CSS custom properties to match any design system. This example applies an orange warm theme.',
277
+ },
278
+ },
279
+ };
280
+ //# sourceMappingURL=xplor-canvas-editor.stories.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"xplor-canvas-editor.stories.js","sourceRoot":"","sources":["../../../src/components/xplor-canvas-editor/xplor-canvas-editor.stories.ts"],"names":[],"mappings":"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","sourcesContent":["export default {\n title: 'Components/Canvas Editor',\n tags: ['autodocs'],\n parameters: {\n actions: {\n handles: ['xplorShapeAdd', 'xplorShapeRemove', 'xplorShapeChange'],\n },\n docs: {\n description: {\n component: `\nAn SVG-based canvas editor for drawing and managing shapes. Fully accessible (WCAG 2.1 AA),\nframework-agnostic, and compatible with Vue, React, and Angular.\n\n## Features\n- Draw rectangles, ellipses, and lines by clicking and dragging\n- Select and delete shapes with mouse or keyboard (Del / Backspace)\n- Resize selected shapes using 8 directional handles\n- Toolbar with tool selection, delete, and clear-all actions\n- Full keyboard and screen reader support\n\n## Usage\n\\`\\`\\`html\n<xplor-canvas-editor\n width=\"800\"\n height=\"500\"\n tool=\"select\"\n></xplor-canvas-editor>\n\\`\\`\\`\n\n## Events\n| Event | Payload | Description |\n|---|---|---|\n| \\`xplorShapeAdd\\` | \\`Shape\\` | Emitted when a new shape is drawn |\n| \\`xplorShapeRemove\\` | \\`string\\` (id) | Emitted when a shape is deleted |\n| \\`xplorShapeChange\\` | \\`Shape\\` | Emitted when a shape is resized |\n\n## Public Methods\n| Method | Returns | Description |\n|---|---|---|\n| \\`getShapes()\\` | \\`Promise<Shape[]>\\` | Returns all current shapes |\n| \\`clearAll()\\` | \\`Promise<void>\\` | Removes all shapes |\n\n## CSS Custom Properties\n| Property | Default | Description |\n|---|---|---|\n| \\`--canvas-bg\\` | \\`#ffffff\\` | Canvas background colour |\n| \\`--canvas-border\\` | \\`#e5e7eb\\` | Border colour |\n| \\`--selection-color\\` | \\`#2196f3\\` | Selection outline / handle accent colour |\n| \\`--handle-size\\` | \\`5\\` | Resize handle radius (SVG units) |\n| \\`--handle-fill\\` | \\`#ffffff\\` | Resize handle fill |\n| \\`--handle-stroke\\` | \\`#2196f3\\` | Resize handle stroke |\n `,\n },\n },\n },\n argTypes: {\n width: {\n control: { type: 'number', min: 200, max: 1600, step: 50 },\n description: 'Canvas width in pixels',\n },\n height: {\n control: { type: 'number', min: 100, max: 1000, step: 50 },\n description: 'Canvas height in pixels',\n },\n tool: {\n control: { type: 'select' },\n options: ['select', 'rect', 'circle', 'line'],\n description: 'Initially active drawing tool',\n },\n },\n};\n\n// ---------------------------------------------------------------------------\n// Template helper\n// ---------------------------------------------------------------------------\n\nconst Template = (args) => {\n const attrs = Object.entries(args)\n .filter(([, v]) => v !== undefined && v !== '' && v !== false)\n .map(([k, v]) => {\n const attr = k.replace(/([A-Z])/g, '-$1').toLowerCase();\n if (typeof v === 'boolean') return v ? attr : '';\n return `${attr}=\"${v}\"`;\n })\n .filter(Boolean)\n .join(' ');\n\n return `<xplor-canvas-editor ${attrs}></xplor-canvas-editor>`;\n};\n\n// ---------------------------------------------------------------------------\n// Default — select tool, standard size\n// ---------------------------------------------------------------------------\n\nexport const Default = Template.bind({});\nDefault.args = {\n width: 800,\n height: 500,\n tool: 'select',\n};\nDefault.storyName = 'Default (select tool)';\nDefault.parameters = {\n docs: {\n description: {\n story:\n 'The default state. Switch to a drawing tool in the toolbar, then click and drag on the canvas to create shapes.',\n },\n },\n};\n\n// ---------------------------------------------------------------------------\n// Draw Mode — starts with rect tool active\n// ---------------------------------------------------------------------------\n\nexport const DrawMode = Template.bind({});\nDrawMode.args = {\n width: 800,\n height: 500,\n tool: 'rect',\n};\nDrawMode.storyName = 'Draw Mode (rect)';\nDrawMode.parameters = {\n docs: {\n description: {\n story:\n 'Opens with the Rectangle tool already active. Click and drag on the canvas to draw rectangles immediately.',\n },\n },\n};\n\n// ---------------------------------------------------------------------------\n// Circle / Ellipse tool\n// ---------------------------------------------------------------------------\n\nexport const CircleTool = Template.bind({});\nCircleTool.args = {\n width: 800,\n height: 500,\n tool: 'circle',\n};\nCircleTool.storyName = 'Circle / Ellipse tool';\nCircleTool.parameters = {\n docs: {\n description: {\n story:\n 'Opens with the Circle/Ellipse tool active. Drag to define the bounding box of the ellipse.',\n },\n },\n};\n\n// ---------------------------------------------------------------------------\n// Line tool\n// ---------------------------------------------------------------------------\n\nexport const LineTool = Template.bind({});\nLineTool.args = {\n width: 800,\n height: 500,\n tool: 'line',\n};\nLineTool.storyName = 'Line tool';\nLineTool.parameters = {\n docs: {\n description: {\n story:\n 'Opens with the Line tool active. Click the start point and drag to the end point.',\n },\n },\n};\n\n// ---------------------------------------------------------------------------\n// Small canvas\n// ---------------------------------------------------------------------------\n\nexport const SmallCanvas = Template.bind({});\nSmallCanvas.args = {\n width: 400,\n height: 300,\n tool: 'select',\n};\nSmallCanvas.storyName = 'Small canvas (400×300)';\nSmallCanvas.parameters = {\n docs: {\n description: {\n story: 'Demonstrates a compact canvas size.',\n },\n },\n};\n\n// ---------------------------------------------------------------------------\n// Wide canvas\n// ---------------------------------------------------------------------------\n\nexport const WideCanvas = Template.bind({});\nWideCanvas.args = {\n width: 1200,\n height: 500,\n tool: 'select',\n};\nWideCanvas.storyName = 'Wide canvas (1200×500)';\nWideCanvas.parameters = {\n docs: {\n description: {\n story:\n 'A wider canvas. The SVG wrapper scrolls horizontally if the canvas exceeds the viewport.',\n },\n },\n};\n\n// ---------------------------------------------------------------------------\n// Pre-loaded shapes (via JS injection — showcases shape rendering)\n// ---------------------------------------------------------------------------\n\nexport const PreloadedShapes = () => `\n<div style=\"display:inline-block;\">\n <xplor-canvas-editor\n id=\"preloaded-canvas\"\n width=\"800\"\n height=\"500\"\n tool=\"select\"\n ></xplor-canvas-editor>\n</div>\n<script>\n (function () {\n var el = document.getElementById('preloaded-canvas');\n // Wait for Stencil hydration\n customElements.whenDefined('xplor-canvas-editor').then(function () {\n // Directly set internal state via a workaround — for demo purposes only.\n // In real integrations, shapes should be drawn by the user or managed via getShapes()/clearAll().\n var preloaded = [\n { id: 'pre-1', type: 'rect', x: 40, y: 40, width: 160, height: 100, fill: 'rgba(33,150,243,0.25)', stroke: '#1976d2' },\n { id: 'pre-2', type: 'circle', x: 260, y: 60, width: 140, height: 120, fill: 'rgba(76,175,80,0.25)', stroke: '#388e3c' },\n { id: 'pre-3', type: 'line', x: 50, y: 220, width: 300, height: 200, fill: 'none', stroke: '#f44336' },\n { id: 'pre-4', type: 'rect', x: 430, y: 80, width: 180, height: 130, fill: 'rgba(156,39,176,0.25)', stroke: '#7b1fa2' },\n ];\n if (el && el.__stencilInstance) {\n el.__stencilInstance.shapes = preloaded;\n }\n });\n })();\n</script>\n`;\nPreloadedShapes.storyName = 'Pre-loaded shapes';\nPreloadedShapes.parameters = {\n docs: {\n description: {\n story:\n 'Demonstrates how all three shape types (rect, ellipse, line) are rendered. Use the Select tool and click a shape to see resize handles.',\n },\n },\n};\n\n// ---------------------------------------------------------------------------\n// Dark mode\n// ---------------------------------------------------------------------------\n\nexport const DarkMode = () => `\n<div class=\"dark\" style=\"background:#1e1e2e; padding:2rem; border-radius:0.5rem; display:inline-block;\">\n <xplor-canvas-editor\n class=\"dark\"\n width=\"800\"\n height=\"500\"\n tool=\"select\"\n ></xplor-canvas-editor>\n</div>\n`;\nDarkMode.storyName = 'Dark mode';\nDarkMode.parameters = {\n backgrounds: { default: 'dark' },\n docs: {\n description: {\n story:\n 'Apply the `.dark` CSS class to the host element or an ancestor to activate dark mode colour tokens.',\n },\n },\n};\n\n// ---------------------------------------------------------------------------\n// Custom CSS tokens\n// ---------------------------------------------------------------------------\n\nexport const CustomTokens = () => `\n<xplor-canvas-editor\n width=\"800\"\n height=\"500\"\n tool=\"rect\"\n style=\"\n --canvas-bg: #fdf6ec;\n --canvas-border: #f5c68a;\n --selection-color: #f57c00;\n --handle-stroke: #f57c00;\n --canvas-toolbar-bg: #fff8f0;\n --canvas-toolbar-border: #f5c68a;\n --canvas-btn-active-bg: rgba(245,124,0,0.1);\n --canvas-btn-active-color: #f57c00;\n \"\n></xplor-canvas-editor>\n`;\nCustomTokens.storyName = 'Custom CSS tokens (orange theme)';\nCustomTokens.parameters = {\n docs: {\n description: {\n story:\n 'Override CSS custom properties to match any design system. This example applies an orange warm theme.',\n },\n },\n};\n"]}
@@ -52,7 +52,7 @@ export class XplorChatWidget {
52
52
  }
53
53
  }
54
54
  render() {
55
- return (h(Host, { key: '19fe2c1cbe9c2f82779a3e9e6966db8e22988002' }, h("div", { key: 'b2d611ff824b3e4c9eff2c7eac45716219de2b96', id: "ai-text" }, this.textValue), h("div", { key: '96ca4702ebd751d3b6ab95a23ca1b762ef1be270', class: "container" }, h("xplor-dropdown", { key: '74a7468be12b73d97cf473cd7bb9bae99e62fa1b', options: this.languageOptions, selected: this.selectedLanguage, handleChange: this.handleChange }), h("xplor-button", { key: '4177a337e0295507422bee77f90a26ea6ed3b12b', text: "translate", mode: "pg", type: "primary", onClick: this.handleClick }))));
55
+ return (h(Host, { key: '5d2dcc41806f640f3dce9dea7aefe60877115b6c' }, h("div", { key: '3624422b51c11f58fa35249e91ab3a5a4ae70cd1', id: "ai-text" }, this.textValue), h("div", { key: 'ba23a8071db26f0695fbfc75a740b9e816c72eac', class: "container" }, h("xplor-dropdown", { key: 'b944f0a90ac707f98bc3ed75736823572d0f77e5', options: this.languageOptions, selected: this.selectedLanguage, handleChange: this.handleChange }), h("xplor-button", { key: 'e9d9b16969b7da1cb1160a7f6c9c77b932da8834', text: "translate", mode: "pg", type: "primary", onClick: this.handleClick }))));
56
56
  }
57
57
  static get is() { return "xplor-chat-widget"; }
58
58
  static get encapsulation() { return "shadow"; }
@@ -74,7 +74,7 @@ export class XplorCheckbox {
74
74
  this.indeterminate = this.initialIndeterminate;
75
75
  }
76
76
  render() {
77
- return (h("div", { key: '02d3efb24ac53caa742721720ec6d212eb159a55', class: "checkbox-wrapper" }, h("div", { key: '1d1024d0dfb9328d607919dad86bfa25def7bf35', class: this.getCheckboxClass(), onClick: this.handleClick, onMouseEnter: () => this.isHovered = true, onMouseLeave: () => this.isHovered = false, onMouseDown: () => this.isPressed = true, onMouseUp: () => this.isPressed = false, onFocus: () => this.isFocused = true, onBlur: () => this.isFocused = false, onKeyDown: this.handleKeyDown, onKeyUp: this.handleKeyUp, tabIndex: this.disabled ? -1 : 0, role: "checkbox", "aria-checked": this.indeterminate ? 'mixed' : this.checked.toString(), "aria-disabled": this.disabled.toString(), "aria-labelledby": this.label ? this.labelId : undefined }, this.checked && (h("svg", { key: 'e5bd243560546d47bfc77d753df3020fb1abb417', class: "check-icon", viewBox: "0 0 16 16", fill: "none" }, h("path", { key: '19da038d854b218177b668da5b8e8c3489dd377d', d: "M13.3334 4L6.00002 11.3333L2.66669 8", stroke: "currentColor", "stroke-width": "2", "stroke-linecap": "round", "stroke-linejoin": "round" }))), this.indeterminate && (h("svg", { key: '069ce072241705fabb0a740271d7b6e6192e35a8', class: "indeterminate-icon", viewBox: "0 0 16 16", fill: "none" }, h("path", { key: 'afc9851ff1e2ecb32cb7f0037c72844e8ae1a625', d: "M3.33331 8H12.6666", stroke: "currentColor", "stroke-width": "2", "stroke-linecap": "round" })))), this.label && h("span", { key: '4fbc5b3bbf78fd53aa0ee5a65e1a3b1b76cbb114', class: "label", id: this.labelId }, this.label)));
77
+ return (h("div", { key: '1fe78163ff3fc8d337731e9765628f2dd48bbbb5', class: "checkbox-wrapper" }, h("div", { key: '0ed33fa8c645b4ddce726b991f40da8712758a71', class: this.getCheckboxClass(), onClick: this.handleClick, onMouseEnter: () => this.isHovered = true, onMouseLeave: () => this.isHovered = false, onMouseDown: () => this.isPressed = true, onMouseUp: () => this.isPressed = false, onFocus: () => this.isFocused = true, onBlur: () => this.isFocused = false, onKeyDown: this.handleKeyDown, onKeyUp: this.handleKeyUp, tabIndex: this.disabled ? -1 : 0, role: "checkbox", "aria-checked": this.indeterminate ? 'mixed' : this.checked.toString(), "aria-disabled": this.disabled.toString(), "aria-labelledby": this.label ? this.labelId : undefined }, this.checked && (h("svg", { key: '75bd98168be72bf08998da1058aefe6fe9c46947', class: "check-icon", viewBox: "0 0 16 16", fill: "none" }, h("path", { key: 'ddfb568863af95b55ca70df1ba3dd8be5a3d30cb', d: "M13.3334 4L6.00002 11.3333L2.66669 8", stroke: "currentColor", "stroke-width": "2", "stroke-linecap": "round", "stroke-linejoin": "round" }))), this.indeterminate && (h("svg", { key: '1eadbf511badc60a60a5419c010c0c9b09014e22', class: "indeterminate-icon", viewBox: "0 0 16 16", fill: "none" }, h("path", { key: 'b654b703226b817484375a9b7d008feb44c8f592', d: "M3.33331 8H12.6666", stroke: "currentColor", "stroke-width": "2", "stroke-linecap": "round" })))), this.label && h("span", { key: '1e53eb3e690f18f983d1cdded64fe9e8b557e5c8', class: "label", id: this.labelId }, this.label)));
78
78
  }
79
79
  static get is() { return "xplor-checkbox"; }
80
80
  static get encapsulation() { return "shadow"; }
@@ -210,15 +210,15 @@ export class XplorCombobox {
210
210
  const listboxId = 'combobox-listbox';
211
211
  const labelId = 'combobox-label';
212
212
  const activeDescendantId = this.highlightedIndex >= 0 ? `combobox-option-${this.highlightedIndex}` : undefined;
213
- return (h(Host, { key: '5c3fb39153fe1a83d72b4ad3aa60d4602014916c' }, h("div", { key: 'ed9f80ab76d19c842e9da6a016040fdf68395332', class: {
213
+ return (h(Host, { key: '30d75fafd92568e91b4f695fa48d06fe2c433c40' }, h("div", { key: 'b8c6278923ff28cd85adaf793d8a9c36bc812370', class: {
214
214
  'combobox': true,
215
215
  'combobox--disabled': this.disabled,
216
216
  'combobox--readonly': this.readonly,
217
217
  'combobox--open': this.isOpen,
218
- } }, this.label && (h("label", { key: 'a5837bdc2fe30046a56a659a942c82c6612e5eed', class: "combobox__label", id: labelId }, this.label)), h("div", { key: '84022a8390a2024ef29d7dbdb5bd3b34c1da2305', class: "combobox__input-wrapper" }, this.multiple && this.selectedItems.length > 0 && (h("div", { key: '7df2befc1d6104e8b5472c800fe30eda0ecac550', class: "combobox__chips" }, this.selectedItems.map(value => {
218
+ } }, this.label && (h("label", { key: 'b8c250d88bf3fefc0b83232e3f93123034e43149', class: "combobox__label", id: labelId }, this.label)), h("div", { key: 'b0c00a90810d030afc86f815b4f90bc259841885', class: "combobox__input-wrapper" }, this.multiple && this.selectedItems.length > 0 && (h("div", { key: '50d4ea9a7798b65d6bc52466b458f022358d881a', class: "combobox__chips" }, this.selectedItems.map(value => {
219
219
  const chipLabel = this.getSelectedItemLabel(value);
220
220
  return (h("div", { class: "combobox__chip" }, h("span", { class: "combobox__chip-label" }, chipLabel), h("button", { type: "button", class: "combobox__chip-remove", onClick: () => this.removeItem(value), disabled: this.disabled || this.readonly, "aria-label": `Remove ${chipLabel}` }, "\u00D7")));
221
- }))), h("input", { key: '4b01ffb37bfe750c24081ec839fcd6b70f87bde0', ref: (el) => (this.inputEl = el), type: "text", class: "combobox__input", placeholder: this.placeholder, value: this.searchQuery, onFocus: this.handleInputFocus, onInput: this.handleInputChange, onKeyDown: this.handleInputKeyDown, disabled: this.disabled, readonly: this.readonly, autocomplete: "off", role: "combobox", "aria-expanded": this.isOpen ? 'true' : 'false', "aria-haspopup": "listbox", "aria-controls": this.isOpen ? listboxId : undefined, "aria-activedescendant": activeDescendantId, "aria-labelledby": this.label ? labelId : undefined, "aria-label": !this.label ? (this.ariaLabel || this.placeholder) : undefined, "aria-autocomplete": "list" }), h("div", { key: 'f1fa0b56edeb6c5e25eebd34a9d143a0ecca1173', class: "combobox__actions" }, this.clearable && hasValue && !this.disabled && !this.readonly && (h("button", { key: '5179310582b9aef4739985dbeefd35bda1bb86bb', type: "button", class: "combobox__clear", onClick: this.handleClear, "aria-label": "Clear selection" }, "\u00D7")), h("span", { key: '93c5431addfcaf88e51d38907304a4e289c3183d', class: "combobox__icon", "aria-hidden": "true" }, "\u25BC"))), this.isOpen && (this.filteredItems.length > 0 || showCreateOption) && (h("div", { key: '9fba0e29de90f8bdcdd4861fbb0fb06a20fa980b', class: "combobox__dropdown", ref: (el) => (this.dropdownEl = el), role: "listbox", id: listboxId, "aria-label": this.label || this.ariaLabel || 'Options' }, this.filteredItems.map((item, index) => {
221
+ }))), h("input", { key: '5fb92aa47a90ce22bc6538b267ab5ebc228ef38c', ref: (el) => (this.inputEl = el), type: "text", class: "combobox__input", placeholder: this.placeholder, value: this.searchQuery, onFocus: this.handleInputFocus, onInput: this.handleInputChange, onKeyDown: this.handleInputKeyDown, disabled: this.disabled, readonly: this.readonly, autocomplete: "off", role: "combobox", "aria-expanded": this.isOpen ? 'true' : 'false', "aria-haspopup": "listbox", "aria-controls": this.isOpen ? listboxId : undefined, "aria-activedescendant": activeDescendantId, "aria-labelledby": this.label ? labelId : undefined, "aria-label": !this.label ? (this.ariaLabel || this.placeholder) : undefined, "aria-autocomplete": "list" }), h("div", { key: '4ade4fece05a81bc1ac4a0a289beecd6a2068f8c', class: "combobox__actions" }, this.clearable && hasValue && !this.disabled && !this.readonly && (h("button", { key: '8ee876b5e4a35fd0b0af71544bbc2e98a29148fd', type: "button", class: "combobox__clear", onClick: this.handleClear, "aria-label": "Clear selection" }, "\u00D7")), h("span", { key: 'ca1e3180e381b5fe1ace789b0af66092cd9dfeee', class: "combobox__icon", "aria-hidden": "true" }, "\u25BC"))), this.isOpen && (this.filteredItems.length > 0 || showCreateOption) && (h("div", { key: 'cb5501119e5aa39e161de50b1ac6b310dc1edaa3', class: "combobox__dropdown", ref: (el) => (this.dropdownEl = el), role: "listbox", id: listboxId, "aria-label": this.label || this.ariaLabel || 'Options' }, this.filteredItems.map((item, index) => {
222
222
  const isSelected = this.multiple
223
223
  ? this.selectedItems.includes(item.value)
224
224
  : this.value === item.value;
@@ -228,11 +228,11 @@ export class XplorCombobox {
228
228
  'combobox__item--selected': isSelected,
229
229
  'combobox__item--disabled': item.disabled,
230
230
  }, onClick: () => this.selectItem(item) }, item.label));
231
- }), showCreateOption && (h("div", { key: '880bc30bc32c87dfb9ecf9b706162299e80fd1c5', id: `combobox-option-${this.filteredItems.length}`, "data-index": this.filteredItems.length, role: "option", "aria-selected": "false", class: {
231
+ }), showCreateOption && (h("div", { key: 'dddf029e093efa939b5f40b63101c548e11eb654', id: `combobox-option-${this.filteredItems.length}`, "data-index": this.filteredItems.length, role: "option", "aria-selected": "false", class: {
232
232
  'combobox__item': true,
233
233
  'combobox__item--create': true,
234
234
  'combobox__item--highlighted': this.highlightedIndex === this.filteredItems.length,
235
- }, onClick: () => this.createNewItem() }, h("span", { key: 'd0ff5841add7495a79a1e9453b87706971cf8907', class: "combobox__create-label" }, this.createMessage, ":"), ' ', h("strong", { key: 'e1b1e94a5afce2ab3f5a714a7c593e59d9d22ff0' }, "\"", this.searchQuery, "\""))))), this.isOpen && this.filteredItems.length === 0 && !showCreateOption && (h("div", { key: '0a95426511036f918cd42999cd1543fc26efbff2', class: "combobox__dropdown", role: "listbox", id: listboxId }, h("div", { key: '551dc3ad968c049c5bbf2a9da71d45e203e15df7', class: "combobox__no-results", role: "option", "aria-disabled": "true" }, "No results found"))))));
235
+ }, onClick: () => this.createNewItem() }, h("span", { key: '478d841838f5b2249f868d5852982bede08fe3de', class: "combobox__create-label" }, this.createMessage, ":"), ' ', h("strong", { key: '05c284c7d27f7107dfc717c5c2376077c627d4c7' }, "\"", this.searchQuery, "\""))))), this.isOpen && this.filteredItems.length === 0 && !showCreateOption && (h("div", { key: 'c333a2909fef4d33e8b1655043340ba4f27d898e', class: "combobox__dropdown", role: "listbox", id: listboxId }, h("div", { key: '1ba3213f34a8f281143e6ead11fc0c90844475fc', class: "combobox__no-results", role: "option", "aria-disabled": "true" }, "No results found"))))));
236
236
  }
237
237
  static get is() { return "xplor-combobox"; }
238
238
  static get encapsulation() { return "scoped"; }
@@ -258,7 +258,7 @@ export class XplorCombobox {
258
258
  "references": {
259
259
  "ComboboxItem": {
260
260
  "location": "local",
261
- "path": "/Users/darrynlee-warden/Documents/DEV/xplor/xplor_design_system/apps/core-stencil-components/src/components/xplor-combobox/xplor-combobox.tsx",
261
+ "path": "/Users/darryn.lee-warden/Documents/DEV/xplor_design_system/apps/core-stencil-components/src/components/xplor-combobox/xplor-combobox.tsx",
262
262
  "id": "src/components/xplor-combobox/xplor-combobox.tsx::ComboboxItem"
263
263
  }
264
264
  }
@@ -515,7 +515,7 @@ export class XplorCombobox {
515
515
  "references": {
516
516
  "ComboboxItem": {
517
517
  "location": "local",
518
- "path": "/Users/darrynlee-warden/Documents/DEV/xplor/xplor_design_system/apps/core-stencil-components/src/components/xplor-combobox/xplor-combobox.tsx",
518
+ "path": "/Users/darryn.lee-warden/Documents/DEV/xplor_design_system/apps/core-stencil-components/src/components/xplor-combobox/xplor-combobox.tsx",
519
519
  "id": "src/components/xplor-combobox/xplor-combobox.tsx::ComboboxItem"
520
520
  }
521
521
  }
@@ -163,13 +163,13 @@ export class XplorDatatable {
163
163
  render() {
164
164
  const tableHeight = typeof this.height === 'number' ? `${this.height}px` : this.height;
165
165
  const hasHeight = !!this.height;
166
- return (h(Host, { key: '779f32a211bb2d9d5d70363112970f00d62d9ccf', class: "xplor-datatable" }, h("div", { key: '27995dd2f98074fe0bd223b52ae3b25cc48a8ab6', class: "datatable-container" }, h("div", { key: '379d7b6999df3d94e2fa6618394e14fa9e99d96b', class: {
166
+ return (h(Host, { key: '31026bbaf1331e11115147771e80fb3d59c02104', class: "xplor-datatable" }, h("div", { key: '6b4feed4000f1cc56bf2ed2e7bb6808996662ca9', class: "datatable-container" }, h("div", { key: '2d395becc036e9e19f3b9397fbf154edf07f36e4', class: {
167
167
  'table-wrapper': true,
168
168
  'has-height': hasHeight,
169
169
  'horizontal-lines': this.horizontalLines,
170
170
  'striped': this.striped,
171
171
  'is-empty': this.items.length === 0,
172
- }, style: hasHeight ? { height: tableHeight } : {} }, h("table", { key: '5f46224fe7ecc2fd3781e11d592fee5c8d80e9f2', class: { 'hover': this.hover } }, h("thead", { key: 'd20432aa1d6551dd324a60ed594cd5ebc2c80198' }, h("tr", { key: '62cc50e679f8345caba6f92a7ae117b68728425d' }, this.canSelect && (h("th", { key: 'dfffb0bf421458b192db6eae3538da8a752f5356', class: "select-column" }, h("label", { key: '17cdb037cee9b2d0cce729e0761f03b4bca14354', class: "checkbox-label" }, h("input", { key: '668128d3f8238449b965df2825e164a2e12a4626', type: "checkbox", checked: this.allSelected, indeterminate: this.internalSelected.size > 0 &&
172
+ }, style: hasHeight ? { height: tableHeight } : {} }, h("table", { key: 'fdf0bf570246d6abd84dfa2e2cf5757dde309e6c', class: { 'hover': this.hover } }, h("thead", { key: '634480ba84300e86339dbbf95dce396cde8395c5' }, h("tr", { key: '08e44beee5fb0c703694b38a7bfbc2da3691611e' }, this.canSelect && (h("th", { key: '9587a2bb1e11e5c8b44f5b7c4de3e2d6d4e7bb30', class: "select-column" }, h("label", { key: 'a2cdfaabd4fff5cba3801568de522eb60104a79e', class: "checkbox-label" }, h("input", { key: '3500b6b71893fc242b6ad956cb1190b2533e13de', type: "checkbox", checked: this.allSelected, indeterminate: this.internalSelected.size > 0 &&
173
173
  this.internalSelected.size < this.items.length, onChange: this.handleSelectAll, "aria-label": "Select all rows" })))), this.headers.map(header => (h("th", { class: {
174
174
  sortable: header.sortable !== false,
175
175
  sorted: this.sortBy === header.value,
@@ -213,7 +213,7 @@ export class XplorDatatable {
213
213
  "references": {
214
214
  "DatatableColumn": {
215
215
  "location": "local",
216
- "path": "/Users/darrynlee-warden/Documents/DEV/xplor/xplor_design_system/apps/core-stencil-components/src/components/xplor-datatable/xplor-datatable.tsx",
216
+ "path": "/Users/darryn.lee-warden/Documents/DEV/xplor_design_system/apps/core-stencil-components/src/components/xplor-datatable/xplor-datatable.tsx",
217
217
  "id": "src/components/xplor-datatable/xplor-datatable.tsx::DatatableColumn"
218
218
  }
219
219
  }
@@ -277,7 +277,7 @@ export class XplorDatatable {
277
277
  "references": {
278
278
  "DatatablePagination": {
279
279
  "location": "local",
280
- "path": "/Users/darrynlee-warden/Documents/DEV/xplor/xplor_design_system/apps/core-stencil-components/src/components/xplor-datatable/xplor-datatable.tsx",
280
+ "path": "/Users/darryn.lee-warden/Documents/DEV/xplor_design_system/apps/core-stencil-components/src/components/xplor-datatable/xplor-datatable.tsx",
281
281
  "id": "src/components/xplor-datatable/xplor-datatable.tsx::DatatablePagination"
282
282
  }
283
283
  }
@@ -506,7 +506,7 @@ export class XplorDatatable {
506
506
  "references": {
507
507
  "DatatablePagination": {
508
508
  "location": "local",
509
- "path": "/Users/darrynlee-warden/Documents/DEV/xplor/xplor_design_system/apps/core-stencil-components/src/components/xplor-datatable/xplor-datatable.tsx",
509
+ "path": "/Users/darryn.lee-warden/Documents/DEV/xplor_design_system/apps/core-stencil-components/src/components/xplor-datatable/xplor-datatable.tsx",
510
510
  "id": "src/components/xplor-datatable/xplor-datatable.tsx::DatatablePagination"
511
511
  }
512
512
  }
@@ -197,16 +197,16 @@ export class XplorDatePicker {
197
197
  }
198
198
  render() {
199
199
  const showDetails = this.hideDetails === false || (this.hideDetails === 'auto' && this.error);
200
- const calendarIcon = (h("svg", { key: '8e3f3be13346ec15a3e4e2a9e9ccf3481cf8c87b', class: "date-picker__icon-svg", viewBox: "0 0 24 24", width: "20", height: "20", fill: "none", stroke: "currentColor", "stroke-width": "2", "stroke-linecap": "round", "stroke-linejoin": "round" }, h("rect", { key: '1f5d918d65a44a7b8f9dec0609ef125c96b1ccdf', x: "3", y: "4", width: "18", height: "18", rx: "2", ry: "2" }), h("line", { key: 'd2a5ccfbe2e4afe8ed5d9277c49b09169c6ae651', x1: "16", y1: "2", x2: "16", y2: "6" }), h("line", { key: '8d114a93b8f1c4d8fc65360f34afaecc14148328', x1: "8", y1: "2", x2: "8", y2: "6" }), h("line", { key: '40b3ab407c3872d6eda481a64f8210b505e202cc', x1: "3", y1: "10", x2: "21", y2: "10" })));
201
- return (h(Host, { key: '7c04e985b0a900863965311e69a336d859852e66' }, h("div", { key: '15b17203d293c694130493bf45b8bd6d38c7bd36', class: {
200
+ const calendarIcon = (h("svg", { key: 'd78ff4ab59055d3d19d872651a7e726c0b60cfb5', class: "date-picker__icon-svg", viewBox: "0 0 24 24", width: "20", height: "20", fill: "none", stroke: "currentColor", "stroke-width": "2", "stroke-linecap": "round", "stroke-linejoin": "round" }, h("rect", { key: 'd43dc4e0ca1d8c6b4a55484d0f6ae81f00201954', x: "3", y: "4", width: "18", height: "18", rx: "2", ry: "2" }), h("line", { key: '1f5fe56ffa03cc49409553f0c13184667c0bed62', x1: "16", y1: "2", x2: "16", y2: "6" }), h("line", { key: '18e8c75d559ce76bcd0336241955a4018daaa270', x1: "8", y1: "2", x2: "8", y2: "6" }), h("line", { key: '880167220cb172fc0f5b18b1eb0fabfc3326501b', x1: "3", y1: "10", x2: "21", y2: "10" })));
201
+ return (h(Host, { key: '53584be9a38a833329033b5e547c15671d43b9ea' }, h("div", { key: '32c32b9abd3021718994879c797d15c7c92b200a', class: {
202
202
  'date-picker': true,
203
203
  'date-picker--disabled': this.disabled,
204
204
  'date-picker--error': !!this.error,
205
205
  'date-picker--open': this.isOpen,
206
- } }, this.label && (h("label", { key: 'e9e03dde337f9c2259611f1f1f4748bb92d86cfb', class: "date-picker__label", id: this.labelId, htmlFor: this.inputId }, this.label, this.required && h("span", { key: '4e68d0071f5224c9fc30df8864898a4906f6efba', class: "date-picker__required" }, "*"))), this.display === 'text' ? (h("div", { class: "date-picker__text-display", onClick: this.handleTextClick, "aria-expanded": this.isOpen ? 'true' : 'false', "aria-haspopup": "dialog", role: "button", tabIndex: 0 }, h("span", { class: "date-picker__text-value" }, this.value ? this.formatDateForDisplay(this.value) : this.placeholder), calendarIcon)) : (h("div", { class: "date-picker__field" }, h("input", { id: this.inputId, type: "text", class: "date-picker__input", value: this.inputText, placeholder: this.placeholder, disabled: this.disabled, readonly: this.readonly, onFocus: this.handleInputFocus, onBlur: this.handleInputBlur, onInput: this.handleInputChange, style: { backgroundColor: this.bgColor }, "aria-expanded": this.isOpen ? 'true' : 'false', "aria-haspopup": "dialog", "aria-describedby": this.error ? this.errorId : undefined, "aria-invalid": this.error ? 'true' : undefined, "aria-required": this.required ? 'true' : undefined }), h("div", { class: "date-picker__actions" }, this.clearable && this.value && !this.disabled && !this.readonly && (h("button", { type: "button", class: "date-picker__clear", onClick: this.handleClear, "aria-label": "Clear" }, "\u00D7")), h("button", { type: "button", class: "date-picker__icon-btn", onClick: this.toggleDropdown, disabled: this.disabled, "aria-label": "Open calendar" }, calendarIcon)))), showDetails && (h("div", { key: '4e9fd12626bf5436604e28a236a304d60c452b50', class: "date-picker__details" }, this.error && h("div", { key: 'a40425ac84ee81671f4289f4323db9a9a472d3c7', class: "date-picker__error-message", id: this.errorId }, this.error))), this.isOpen && (h("div", { key: '86c55873b678dcfe74c09475cbde7657f1983799', class: {
206
+ } }, this.label && (h("label", { key: '38f0b77a965ecd259037a521984cf3edc81d83d0', class: "date-picker__label", id: this.labelId, htmlFor: this.inputId }, this.label, this.required && h("span", { key: '7d4967354fe742c08170c80286c97f353fa54d5f', class: "date-picker__required" }, "*"))), this.display === 'text' ? (h("div", { class: "date-picker__text-display", onClick: this.handleTextClick, "aria-expanded": this.isOpen ? 'true' : 'false', "aria-haspopup": "dialog", role: "button", tabIndex: 0 }, h("span", { class: "date-picker__text-value" }, this.value ? this.formatDateForDisplay(this.value) : this.placeholder), calendarIcon)) : (h("div", { class: "date-picker__field" }, h("input", { id: this.inputId, type: "text", class: "date-picker__input", value: this.inputText, placeholder: this.placeholder, disabled: this.disabled, readonly: this.readonly, onFocus: this.handleInputFocus, onBlur: this.handleInputBlur, onInput: this.handleInputChange, style: { backgroundColor: this.bgColor }, "aria-expanded": this.isOpen ? 'true' : 'false', "aria-haspopup": "dialog", "aria-describedby": this.error ? this.errorId : undefined, "aria-invalid": this.error ? 'true' : undefined, "aria-required": this.required ? 'true' : undefined }), h("div", { class: "date-picker__actions" }, this.clearable && this.value && !this.disabled && !this.readonly && (h("button", { type: "button", class: "date-picker__clear", onClick: this.handleClear, "aria-label": "Clear" }, "\u00D7")), h("button", { type: "button", class: "date-picker__icon-btn", onClick: this.toggleDropdown, disabled: this.disabled, "aria-label": "Open calendar" }, calendarIcon)))), showDetails && (h("div", { key: '66ff5c32e4f6ca2db4feac663377afde49476a21', class: "date-picker__details" }, this.error && h("div", { key: '03cfd6ba58a9bb716e24fe008928744403b5d54c', class: "date-picker__error-message", id: this.errorId }, this.error))), this.isOpen && (h("div", { key: '9b3f462b7c80ed5be13090d376d5f74a65563811', class: {
207
207
  'date-picker__dropdown': true,
208
208
  'date-picker__dropdown--top': this.dropdownPosition === 'top',
209
- } }, h("xplor-inline-date-picker", { key: 'bd1636e13522a65ea6377857edea2928a6182282', selectedDate: this.value, min: this.min, max: this.max, readonly: this.readonly, color: this.color, startWeekOnSunday: this.startWeekOnSunday, onDateSelected: this.handleDateSelected }))))));
209
+ } }, h("xplor-inline-date-picker", { key: '214a5858b26b70a77d2ec4e896a5045581167d76', selectedDate: this.value, min: this.min, max: this.max, readonly: this.readonly, color: this.color, startWeekOnSunday: this.startWeekOnSunday, onDateSelected: this.handleDateSelected }))))));
210
210
  }
211
211
  static get is() { return "xplor-date-picker"; }
212
212
  static get encapsulation() { return "scoped"; }
@@ -1059,22 +1059,22 @@ ul.mdc-list li.mdc-list-item {
1059
1059
  }
1060
1060
 
1061
1061
  .drag-drop-card {
1062
- background-color: #f5f5f5;
1063
- border-radius: 8px;
1062
+ background-color: #DFF2F1;
1063
+ border-radius: 16px;
1064
1064
  border: 2px dashed var(--color-secondary);
1065
- min-height: 160px;
1066
- padding: 1.5rem;
1065
+ min-height: 300px;
1066
+ padding: 3rem 2rem;
1067
1067
  text-align: center;
1068
1068
  transition: all 0.2s ease;
1069
1069
  cursor: default;
1070
1070
  }
1071
1071
  .drag-drop-card:hover:not(.drag-drop-card--disabled) {
1072
1072
  border-color: var(--color-secondary);
1073
- background-color: #eeeeee;
1073
+ background-color: var(--color-success-100, #c8e6c9);
1074
1074
  }
1075
1075
  .drag-drop-card--dragover {
1076
1076
  border: 2px dashed var(--color-secondary);
1077
- background-color: #eeeeee;
1077
+ background-color: var(--color-success-100, #c8e6c9);
1078
1078
  }
1079
1079
  .drag-drop-card--disabled {
1080
1080
  opacity: 0.6;
@@ -1085,37 +1085,85 @@ ul.mdc-list li.mdc-list-item {
1085
1085
  display: flex;
1086
1086
  flex-direction: column;
1087
1087
  align-items: center;
1088
- gap: 0.75rem;
1088
+ gap: 0.5rem;
1089
+ }
1090
+
1091
+ .drag-drop-card__body {
1092
+ display: flex;
1093
+ flex-direction: column;
1094
+ align-items: center;
1095
+ gap: 0.5rem;
1096
+ }
1097
+
1098
+ .drag-drop-card__text {
1099
+ display: flex;
1100
+ flex-direction: column;
1101
+ gap: 5px;
1089
1102
  }
1090
1103
 
1091
1104
  .drag-drop-card__icon {
1092
1105
  color: var(--color-secondary);
1093
- width: 40px;
1094
- height: 40px;
1106
+ width: 48px;
1107
+ height: 48px;
1108
+ flex-shrink: 0;
1095
1109
  }
1096
1110
 
1097
1111
  .drag-drop-card__title {
1098
1112
  color: #000000;
1099
1113
  font-family: Inter, sans-serif;
1100
- font-size: 18px;
1114
+ font-size: 24px;
1101
1115
  font-weight: 700;
1102
- line-height: 24px;
1116
+ line-height: 28px;
1103
1117
  letter-spacing: 0;
1104
1118
  margin: 0;
1105
1119
  }
1106
1120
 
1107
- .drag-drop-card__accepts,
1121
+ .drag-drop-card__accepts {
1122
+ color: #000000;
1123
+ font-family: Inter, sans-serif;
1124
+ font-size: 14px;
1125
+ font-weight: 400;
1126
+ line-height: 23px;
1127
+ margin: 0;
1128
+ }
1129
+
1108
1130
  .drag-drop-card__divider {
1109
1131
  color: #000000;
1110
1132
  font-family: Inter, sans-serif;
1111
1133
  font-size: 14px;
1112
1134
  font-weight: 400;
1113
- line-height: 20px;
1135
+ line-height: 23px;
1114
1136
  margin: 0;
1115
1137
  }
1116
1138
 
1117
1139
  .drag-drop-card__action {
1118
- margin-top: 0.25rem;
1140
+ flex-shrink: 0;
1141
+ }
1142
+
1143
+ .drag-drop-zone--horizontal .drag-drop-card {
1144
+ min-height: 210px;
1145
+ padding: 73px 173px;
1146
+ }
1147
+ .drag-drop-zone--horizontal .drag-drop-card__content {
1148
+ flex-direction: row;
1149
+ justify-content: center;
1150
+ align-items: center;
1151
+ gap: 1rem;
1152
+ }
1153
+ .drag-drop-zone--horizontal .drag-drop-card__body {
1154
+ flex-direction: row;
1155
+ align-items: flex-start;
1156
+ gap: 0.5rem;
1157
+ }
1158
+ .drag-drop-zone--horizontal .drag-drop-card__text {
1159
+ text-align: left;
1160
+ max-width: 339px;
1161
+ }
1162
+ .drag-drop-zone--horizontal .drag-drop-card__title {
1163
+ text-align: left;
1164
+ }
1165
+ .drag-drop-zone--horizontal .drag-drop-card__accepts {
1166
+ text-align: left;
1119
1167
  }
1120
1168
 
1121
1169
  .file-info {
@@ -1230,19 +1278,4 @@ ul.mdc-list li.mdc-list-item {
1230
1278
  .file-info__remove:hover {
1231
1279
  background-color: #e0e0e0;
1232
1280
  color: #424242;
1233
- }
1234
-
1235
- @media (max-width: 768px) {
1236
- .drag-drop-card {
1237
- min-height: 140px;
1238
- }
1239
- .drag-drop-card__title {
1240
- font-size: 16px;
1241
- line-height: 22px;
1242
- }
1243
- .drag-drop-card__accepts,
1244
- .drag-drop-card__divider {
1245
- font-size: 13px;
1246
- line-height: 18px;
1247
- }
1248
1281
  }