@keenthemes/ktui 1.0.28 → 1.1.0

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 (288) hide show
  1. package/README.md +27 -0
  2. package/dist/ktui.js +8780 -6199
  3. package/dist/ktui.min.js +1 -1
  4. package/dist/ktui.min.js.map +1 -1
  5. package/dist/styles.css +2744 -1367
  6. package/lib/cjs/components/alert/alert.js +1025 -0
  7. package/lib/cjs/components/alert/alert.js.map +1 -0
  8. package/lib/cjs/components/alert/index.js +20 -0
  9. package/lib/cjs/components/alert/index.js.map +1 -0
  10. package/lib/cjs/components/alert/templates.js +120 -0
  11. package/lib/cjs/components/alert/templates.js.map +1 -0
  12. package/lib/cjs/components/alert/types.js +7 -0
  13. package/lib/cjs/components/alert/types.js.map +1 -0
  14. package/lib/cjs/components/datepicker/config/config.js +42 -0
  15. package/lib/cjs/components/datepicker/config/config.js.map +1 -0
  16. package/lib/cjs/components/datepicker/config/index.js +24 -0
  17. package/lib/cjs/components/datepicker/config/index.js.map +1 -0
  18. package/lib/cjs/components/datepicker/config/interfaces.js +7 -0
  19. package/lib/cjs/components/datepicker/config/interfaces.js.map +1 -0
  20. package/lib/cjs/components/datepicker/config/types.js +7 -0
  21. package/lib/cjs/components/datepicker/config/types.js.map +1 -0
  22. package/lib/cjs/components/datepicker/core/event-manager.js +135 -0
  23. package/lib/cjs/components/datepicker/core/event-manager.js.map +1 -0
  24. package/lib/cjs/components/datepicker/core/focus-manager.js +167 -0
  25. package/lib/cjs/components/datepicker/core/focus-manager.js.map +1 -0
  26. package/lib/cjs/components/datepicker/core/helpers.js +219 -0
  27. package/lib/cjs/components/datepicker/core/helpers.js.map +1 -0
  28. package/lib/cjs/components/datepicker/core/index.js +25 -0
  29. package/lib/cjs/components/datepicker/core/index.js.map +1 -0
  30. package/lib/cjs/components/datepicker/core/unified-state-manager.js +394 -0
  31. package/lib/cjs/components/datepicker/core/unified-state-manager.js.map +1 -0
  32. package/lib/cjs/components/datepicker/datepicker.js +2066 -763
  33. package/lib/cjs/components/datepicker/datepicker.js.map +1 -1
  34. package/lib/cjs/components/datepicker/index.js +19 -8
  35. package/lib/cjs/components/datepicker/index.js.map +1 -1
  36. package/lib/cjs/components/datepicker/ui/index.js +23 -0
  37. package/lib/cjs/components/datepicker/ui/index.js.map +1 -0
  38. package/lib/cjs/components/datepicker/ui/input/dropdown.js +489 -0
  39. package/lib/cjs/components/datepicker/ui/input/dropdown.js.map +1 -0
  40. package/lib/cjs/components/datepicker/ui/input/index.js +23 -0
  41. package/lib/cjs/components/datepicker/ui/input/index.js.map +1 -0
  42. package/lib/cjs/components/datepicker/ui/input/segmented-input.js +640 -0
  43. package/lib/cjs/components/datepicker/ui/input/segmented-input.js.map +1 -0
  44. package/lib/cjs/components/datepicker/ui/renderers/calendar.js +446 -0
  45. package/lib/cjs/components/datepicker/ui/renderers/calendar.js.map +1 -0
  46. package/lib/cjs/components/datepicker/ui/renderers/footer.js +42 -0
  47. package/lib/cjs/components/datepicker/ui/renderers/footer.js.map +1 -0
  48. package/lib/cjs/components/datepicker/ui/renderers/header.js +32 -0
  49. package/lib/cjs/components/datepicker/ui/renderers/header.js.map +1 -0
  50. package/lib/cjs/components/datepicker/ui/renderers/index.js +25 -0
  51. package/lib/cjs/components/datepicker/ui/renderers/index.js.map +1 -0
  52. package/lib/cjs/components/datepicker/ui/renderers/time-picker.js +384 -0
  53. package/lib/cjs/components/datepicker/ui/renderers/time-picker.js.map +1 -0
  54. package/lib/cjs/components/datepicker/ui/templates/index.js +22 -0
  55. package/lib/cjs/components/datepicker/ui/templates/index.js.map +1 -0
  56. package/lib/cjs/components/datepicker/ui/templates/templates.js +253 -0
  57. package/lib/cjs/components/datepicker/ui/templates/templates.js.map +1 -0
  58. package/lib/cjs/components/datepicker/utils/date-formatters.js +88 -0
  59. package/lib/cjs/components/datepicker/utils/date-formatters.js.map +1 -0
  60. package/lib/cjs/components/datepicker/utils/date-utils.js +194 -0
  61. package/lib/cjs/components/datepicker/utils/date-utils.js.map +1 -0
  62. package/lib/cjs/components/datepicker/utils/index.js +24 -0
  63. package/lib/cjs/components/datepicker/utils/index.js.map +1 -0
  64. package/lib/cjs/components/datepicker/utils/time-utils.js +213 -0
  65. package/lib/cjs/components/datepicker/utils/time-utils.js.map +1 -0
  66. package/lib/cjs/index.js +6 -1
  67. package/lib/cjs/index.js.map +1 -1
  68. package/lib/esm/components/alert/alert.js +1022 -0
  69. package/lib/esm/components/alert/alert.js.map +1 -0
  70. package/lib/esm/components/alert/index.js +4 -0
  71. package/lib/esm/components/alert/index.js.map +1 -0
  72. package/lib/esm/components/alert/templates.js +112 -0
  73. package/lib/esm/components/alert/templates.js.map +1 -0
  74. package/lib/esm/components/alert/types.js +6 -0
  75. package/lib/esm/components/alert/types.js.map +1 -0
  76. package/lib/esm/components/datepicker/config/config.js +39 -0
  77. package/lib/esm/components/datepicker/config/config.js.map +1 -0
  78. package/lib/esm/components/datepicker/config/index.js +8 -0
  79. package/lib/esm/components/datepicker/config/index.js.map +1 -0
  80. package/lib/esm/components/datepicker/config/interfaces.js +6 -0
  81. package/lib/esm/components/datepicker/config/interfaces.js.map +1 -0
  82. package/lib/esm/components/datepicker/config/types.js +6 -0
  83. package/lib/esm/components/datepicker/config/types.js.map +1 -0
  84. package/lib/esm/components/datepicker/core/event-manager.js +133 -0
  85. package/lib/esm/components/datepicker/core/event-manager.js.map +1 -0
  86. package/lib/esm/components/datepicker/core/focus-manager.js +164 -0
  87. package/lib/esm/components/datepicker/core/focus-manager.js.map +1 -0
  88. package/lib/esm/components/datepicker/core/helpers.js +211 -0
  89. package/lib/esm/components/datepicker/core/helpers.js.map +1 -0
  90. package/lib/esm/components/datepicker/core/index.js +9 -0
  91. package/lib/esm/components/datepicker/core/index.js.map +1 -0
  92. package/lib/esm/components/datepicker/core/unified-state-manager.js +391 -0
  93. package/lib/esm/components/datepicker/core/unified-state-manager.js.map +1 -0
  94. package/lib/esm/components/datepicker/datepicker.js +2065 -763
  95. package/lib/esm/components/datepicker/datepicker.js.map +1 -1
  96. package/lib/esm/components/datepicker/index.js +6 -8
  97. package/lib/esm/components/datepicker/index.js.map +1 -1
  98. package/lib/esm/components/datepicker/ui/index.js +7 -0
  99. package/lib/esm/components/datepicker/ui/index.js.map +1 -0
  100. package/lib/esm/components/datepicker/ui/input/dropdown.js +486 -0
  101. package/lib/esm/components/datepicker/ui/input/dropdown.js.map +1 -0
  102. package/lib/esm/components/datepicker/ui/input/index.js +7 -0
  103. package/lib/esm/components/datepicker/ui/input/index.js.map +1 -0
  104. package/lib/esm/components/datepicker/ui/input/segmented-input.js +637 -0
  105. package/lib/esm/components/datepicker/ui/input/segmented-input.js.map +1 -0
  106. package/lib/esm/components/datepicker/ui/renderers/calendar.js +443 -0
  107. package/lib/esm/components/datepicker/ui/renderers/calendar.js.map +1 -0
  108. package/lib/esm/components/datepicker/ui/renderers/footer.js +39 -0
  109. package/lib/esm/components/datepicker/ui/renderers/footer.js.map +1 -0
  110. package/lib/esm/components/datepicker/ui/renderers/header.js +29 -0
  111. package/lib/esm/components/datepicker/ui/renderers/header.js.map +1 -0
  112. package/lib/esm/components/datepicker/ui/renderers/index.js +9 -0
  113. package/lib/esm/components/datepicker/ui/renderers/index.js.map +1 -0
  114. package/lib/esm/components/datepicker/ui/renderers/time-picker.js +381 -0
  115. package/lib/esm/components/datepicker/ui/renderers/time-picker.js.map +1 -0
  116. package/lib/esm/components/datepicker/ui/templates/index.js +6 -0
  117. package/lib/esm/components/datepicker/ui/templates/index.js.map +1 -0
  118. package/lib/esm/components/datepicker/ui/templates/templates.js +242 -0
  119. package/lib/esm/components/datepicker/ui/templates/templates.js.map +1 -0
  120. package/lib/esm/components/datepicker/utils/date-formatters.js +83 -0
  121. package/lib/esm/components/datepicker/utils/date-formatters.js.map +1 -0
  122. package/lib/esm/components/datepicker/utils/date-utils.js +184 -0
  123. package/lib/esm/components/datepicker/utils/date-utils.js.map +1 -0
  124. package/lib/esm/components/datepicker/utils/index.js +8 -0
  125. package/lib/esm/components/datepicker/utils/index.js.map +1 -0
  126. package/lib/esm/components/datepicker/utils/time-utils.js +201 -0
  127. package/lib/esm/components/datepicker/utils/time-utils.js.map +1 -0
  128. package/lib/esm/index.js +4 -0
  129. package/lib/esm/index.js.map +1 -1
  130. package/package.json +22 -3
  131. package/src/components/alert/alert.css +429 -188
  132. package/src/components/alert/alert.ts +990 -0
  133. package/src/components/alert/index.ts +4 -0
  134. package/src/components/alert/templates.ts +110 -0
  135. package/src/components/alert/tests/accessibility/aria-roles.test.ts +19 -0
  136. package/src/components/alert/tests/accessibility/focus-management.test.ts +19 -0
  137. package/src/components/alert/tests/accessibility/keyboard-nav.test.ts +22 -0
  138. package/src/components/alert/tests/actions/confirm-cancel.test.ts +122 -0
  139. package/src/components/alert/tests/actions/input-field.test.ts +180 -0
  140. package/src/components/alert/tests/alert.basic.test.ts +126 -0
  141. package/src/components/alert/tests/alert.config.test.ts +75 -0
  142. package/src/components/alert/tests/alert.templates.test.ts +17 -0
  143. package/src/components/alert/tests/config/attribute-config.test.ts +94 -0
  144. package/src/components/alert/tests/config/json-config.test.ts +119 -0
  145. package/src/components/alert/tests/config/merging.test.ts +89 -0
  146. package/src/components/alert/tests/dismissal/auto-dismiss.test.ts +96 -0
  147. package/src/components/alert/tests/dismissal/escape-key-dismiss.test.ts +105 -0
  148. package/src/components/alert/tests/dismissal/manual-dismiss.test.ts +90 -0
  149. package/src/components/alert/tests/dismissal/outside-click-dismiss.test.ts +91 -0
  150. package/src/components/alert/tests/edge-cases/invalid-config.test.ts +19 -0
  151. package/src/components/alert/tests/edge-cases/multiple-alerts.test.ts +19 -0
  152. package/src/components/alert/tests/rendering/custom-content.test.ts +81 -0
  153. package/src/components/alert/tests/rendering/info-alert.test.ts +84 -0
  154. package/src/components/alert/tests/rendering/success-alert.test.ts +100 -0
  155. package/src/components/alert/tests/templates/default-templates.test.ts +16 -0
  156. package/src/components/alert/tests/templates/user-templates.test.ts +16 -0
  157. package/src/components/alert/types.ts +145 -0
  158. package/src/components/datepicker/__tests__/datepicker-events.test.ts +356 -0
  159. package/src/components/datepicker/__tests__/datepicker-init.test.ts +343 -0
  160. package/src/components/datepicker/__tests__/datepicker-integration.test.ts +435 -0
  161. package/src/components/datepicker/__tests__/datepicker-timezone.test.ts +220 -0
  162. package/src/components/datepicker/__tests__/segmented-input-focus.test.ts +380 -0
  163. package/src/components/datepicker/__tests__/selective-state-updates.test.ts +400 -0
  164. package/src/components/datepicker/__tests__/state-manager.test.ts +421 -0
  165. package/src/components/datepicker/__tests__/time-preservation.test.ts +387 -0
  166. package/src/components/datepicker/config/config.ts +40 -0
  167. package/src/components/datepicker/config/index.ts +8 -0
  168. package/src/components/datepicker/config/interfaces.ts +82 -0
  169. package/src/components/datepicker/config/types.ts +188 -0
  170. package/src/components/datepicker/core/event-manager.ts +159 -0
  171. package/src/components/datepicker/core/focus-manager.ts +201 -0
  172. package/src/components/datepicker/core/helpers.ts +231 -0
  173. package/src/components/datepicker/core/index.ts +9 -0
  174. package/src/components/datepicker/core/unified-state-manager.ts +459 -0
  175. package/src/components/datepicker/datepicker.css +429 -1
  176. package/src/components/datepicker/datepicker.ts +2538 -1277
  177. package/src/components/datepicker/index.ts +6 -8
  178. package/src/components/datepicker/ui/index.ts +7 -0
  179. package/src/components/datepicker/ui/input/dropdown.ts +552 -0
  180. package/src/components/datepicker/ui/input/index.ts +7 -0
  181. package/src/components/datepicker/ui/input/segmented-input.ts +638 -0
  182. package/src/components/datepicker/ui/renderers/__tests__/calendar-optimizations.test.ts +611 -0
  183. package/src/components/datepicker/ui/renderers/calendar.ts +530 -0
  184. package/src/components/datepicker/ui/renderers/footer.ts +43 -0
  185. package/src/components/datepicker/ui/renderers/header.ts +33 -0
  186. package/src/components/datepicker/ui/renderers/index.ts +9 -0
  187. package/src/components/datepicker/ui/renderers/time-picker.ts +438 -0
  188. package/src/components/datepicker/ui/templates/index.ts +6 -0
  189. package/src/components/datepicker/ui/templates/templates.ts +306 -0
  190. package/src/components/datepicker/utils/__tests__/date-formatters.test.ts +160 -0
  191. package/src/components/datepicker/utils/__tests__/date-utils-keys.test.ts +86 -0
  192. package/src/components/datepicker/utils/__tests__/date-utils-timezone.test.ts +215 -0
  193. package/src/components/datepicker/utils/date-formatters.ts +85 -0
  194. package/src/components/datepicker/utils/date-utils.ts +172 -0
  195. package/src/components/datepicker/utils/index.ts +8 -0
  196. package/src/components/datepicker/utils/time-utils.ts +221 -0
  197. package/src/index.ts +7 -1
  198. package/CONTRIBUTING.md +0 -101
  199. package/examples/datatable/checkbox-events-test.html +0 -400
  200. package/examples/datatable/credentials-test.html +0 -423
  201. package/examples/datatable/remote-checkbox-test.html +0 -365
  202. package/examples/datatable/sorting-test.html +0 -258
  203. package/examples/image-input/file-upload-example.html +0 -189
  204. package/examples/modal/persistent.html +0 -205
  205. package/examples/modal/remote-select-dropdown.html +0 -166
  206. package/examples/modal/select-dropdown-container.html +0 -129
  207. package/examples/select/avatar.html +0 -47
  208. package/examples/select/basic-usage.html +0 -39
  209. package/examples/select/country.html +0 -43
  210. package/examples/select/dark-mode.html +0 -93
  211. package/examples/select/description.html +0 -53
  212. package/examples/select/disable-option.html +0 -37
  213. package/examples/select/disable-select.html +0 -35
  214. package/examples/select/dropdowncontainer.html +0 -111
  215. package/examples/select/dynamic-methods.html +0 -273
  216. package/examples/select/formdata-remote.html +0 -161
  217. package/examples/select/global-config.html +0 -81
  218. package/examples/select/icon-multiple.html +0 -50
  219. package/examples/select/icon.html +0 -48
  220. package/examples/select/max-selection.html +0 -38
  221. package/examples/select/modal-container.html +0 -128
  222. package/examples/select/modal-positioning-test.html +0 -338
  223. package/examples/select/modal.html +0 -80
  224. package/examples/select/multiple.html +0 -40
  225. package/examples/select/native-selected.html +0 -64
  226. package/examples/select/placeholder.html +0 -40
  227. package/examples/select/remote-data-preselected.html +0 -283
  228. package/examples/select/remote-data.html +0 -38
  229. package/examples/select/search.html +0 -57
  230. package/examples/select/sizes.html +0 -94
  231. package/examples/select/tags-enhanced.html +0 -86
  232. package/examples/select/tags-icons.html +0 -57
  233. package/examples/select/template-customization.html +0 -61
  234. package/examples/sticky/README.md +0 -158
  235. package/examples/sticky/debug-sticky.html +0 -144
  236. package/examples/sticky/test-runner.html +0 -175
  237. package/examples/sticky/test-sticky-logic.js +0 -369
  238. package/examples/sticky/test-sticky-positioning.html +0 -386
  239. package/examples/toast/example.html +0 -479
  240. package/lib/cjs/components/datepicker/calendar.js +0 -1061
  241. package/lib/cjs/components/datepicker/calendar.js.map +0 -1
  242. package/lib/cjs/components/datepicker/config.js +0 -332
  243. package/lib/cjs/components/datepicker/config.js.map +0 -1
  244. package/lib/cjs/components/datepicker/dropdown.js +0 -635
  245. package/lib/cjs/components/datepicker/dropdown.js.map +0 -1
  246. package/lib/cjs/components/datepicker/events.js +0 -129
  247. package/lib/cjs/components/datepicker/events.js.map +0 -1
  248. package/lib/cjs/components/datepicker/keyboard.js +0 -536
  249. package/lib/cjs/components/datepicker/keyboard.js.map +0 -1
  250. package/lib/cjs/components/datepicker/locales.js +0 -78
  251. package/lib/cjs/components/datepicker/locales.js.map +0 -1
  252. package/lib/cjs/components/datepicker/templates.js +0 -403
  253. package/lib/cjs/components/datepicker/templates.js.map +0 -1
  254. package/lib/cjs/components/datepicker/types.js +0 -23
  255. package/lib/cjs/components/datepicker/types.js.map +0 -1
  256. package/lib/cjs/components/datepicker/utils.js +0 -524
  257. package/lib/cjs/components/datepicker/utils.js.map +0 -1
  258. package/lib/esm/components/datepicker/calendar.js +0 -1058
  259. package/lib/esm/components/datepicker/calendar.js.map +0 -1
  260. package/lib/esm/components/datepicker/config.js +0 -329
  261. package/lib/esm/components/datepicker/config.js.map +0 -1
  262. package/lib/esm/components/datepicker/dropdown.js +0 -632
  263. package/lib/esm/components/datepicker/dropdown.js.map +0 -1
  264. package/lib/esm/components/datepicker/events.js +0 -126
  265. package/lib/esm/components/datepicker/events.js.map +0 -1
  266. package/lib/esm/components/datepicker/keyboard.js +0 -533
  267. package/lib/esm/components/datepicker/keyboard.js.map +0 -1
  268. package/lib/esm/components/datepicker/locales.js +0 -74
  269. package/lib/esm/components/datepicker/locales.js.map +0 -1
  270. package/lib/esm/components/datepicker/templates.js +0 -390
  271. package/lib/esm/components/datepicker/templates.js.map +0 -1
  272. package/lib/esm/components/datepicker/types.js +0 -20
  273. package/lib/esm/components/datepicker/types.js.map +0 -1
  274. package/lib/esm/components/datepicker/utils.js +0 -508
  275. package/lib/esm/components/datepicker/utils.js.map +0 -1
  276. package/prettier.config.js +0 -9
  277. package/src/components/datepicker/calendar.ts +0 -1397
  278. package/src/components/datepicker/config.ts +0 -368
  279. package/src/components/datepicker/dropdown.ts +0 -757
  280. package/src/components/datepicker/events.ts +0 -149
  281. package/src/components/datepicker/keyboard.ts +0 -646
  282. package/src/components/datepicker/locales.ts +0 -80
  283. package/src/components/datepicker/templates.ts +0 -792
  284. package/src/components/datepicker/types.ts +0 -154
  285. package/src/components/datepicker/utils.ts +0 -631
  286. package/src/components/select/variants.css +0 -4
  287. package/tsconfig.json +0 -17
  288. package/webpack.config.js +0 -118
@@ -0,0 +1,486 @@
1
+ /*
2
+ * dropdown.ts - Datepicker dropdown management
3
+ * Provides dropdown functionality for KTDatepicker following select component patterns.
4
+ * Handles positioning, transitions, and event management.
5
+ */
6
+ var __extends = (this && this.__extends) || (function () {
7
+ var extendStatics = function (d, b) {
8
+ extendStatics = Object.setPrototypeOf ||
9
+ ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
10
+ function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
11
+ return extendStatics(d, b);
12
+ };
13
+ return function (d, b) {
14
+ if (typeof b !== "function" && b !== null)
15
+ throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
16
+ extendStatics(d, b);
17
+ function __() { this.constructor = d; }
18
+ d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
19
+ };
20
+ })();
21
+ import { createPopper, } from '@popperjs/core';
22
+ import KTDom from '../../../../helpers/dom';
23
+ import KTComponent from '../../../component';
24
+ import { EventManager } from '../../core/event-manager';
25
+ /**
26
+ * KTDatepickerDropdown
27
+ *
28
+ * A specialized dropdown implementation for the KTDatepicker component.
29
+ * This module handles the dropdown functionality for the datepicker component,
30
+ * including positioning and showing/hiding.
31
+ */
32
+ var KTDatepickerDropdown = /** @class */ (function (_super) {
33
+ __extends(KTDatepickerDropdown, _super);
34
+ /**
35
+ * Constructor
36
+ * @param element The parent element (datepicker wrapper)
37
+ * @param toggleElement The element that triggers the dropdown
38
+ * @param dropdownElement The dropdown content element
39
+ * @param config The configuration options
40
+ */
41
+ function KTDatepickerDropdown(element, toggleElement, dropdownElement, config) {
42
+ var _this = _super.call(this) || this;
43
+ _this._name = 'datepicker-dropdown';
44
+ // State (will be managed by unified state manager)
45
+ _this._isOpen = false;
46
+ _this._isTransitioning = false;
47
+ _this._popperInstance = null;
48
+ // Unified state manager reference
49
+ _this._unifiedStateManager = null;
50
+ _this._element = element;
51
+ _this._toggleElement = toggleElement;
52
+ _this._dropdownElement = dropdownElement;
53
+ _this._config = config;
54
+ var container = _this._resolveDropdownContainer();
55
+ if (container) {
56
+ if (container !== _this._dropdownElement.parentElement) {
57
+ container.appendChild(_this._dropdownElement);
58
+ }
59
+ }
60
+ _this._eventManager = new EventManager();
61
+ _this._setupEventListeners();
62
+ return _this;
63
+ }
64
+ /**
65
+ * Set up event listeners for the dropdown
66
+ */
67
+ KTDatepickerDropdown.prototype._setupEventListeners = function () {
68
+ // Event listeners are managed by the main datepicker class
69
+ };
70
+ /**
71
+ * StateObserver implementation
72
+ */
73
+ KTDatepickerDropdown.prototype.onStateChange = function (newState, oldState) {
74
+ // React to dropdown state changes from unified state manager
75
+ if (newState.dropdownState.isOpen !== oldState.dropdownState.isOpen) {
76
+ if (newState.dropdownState.isOpen) {
77
+ this._handleOpenFromState();
78
+ }
79
+ else {
80
+ this._handleCloseFromState();
81
+ }
82
+ }
83
+ if (newState.dropdownState.isTransitioning !== oldState.dropdownState.isTransitioning) {
84
+ this._isTransitioning = newState.dropdownState.isTransitioning;
85
+ }
86
+ };
87
+ KTDatepickerDropdown.prototype.getUpdatePriority = function () {
88
+ return 10; // Medium priority for dropdown updates
89
+ };
90
+ /**
91
+ * Set unified state manager reference
92
+ */
93
+ KTDatepickerDropdown.prototype.setUnifiedStateManager = function (stateManager) {
94
+ this._unifiedStateManager = stateManager;
95
+ };
96
+ /**
97
+ * Handle open state change from unified state manager
98
+ */
99
+ KTDatepickerDropdown.prototype._handleOpenFromState = function () {
100
+ this._isOpen = true;
101
+ this._performOpenTransition();
102
+ };
103
+ /**
104
+ * Handle close state change from unified state manager
105
+ */
106
+ KTDatepickerDropdown.prototype._handleCloseFromState = function () {
107
+ this._performCloseTransition();
108
+ };
109
+ /**
110
+ * Perform the actual open transition
111
+ */
112
+ KTDatepickerDropdown.prototype._performOpenTransition = function () {
113
+ var _this = this;
114
+ if (this._isTransitioning)
115
+ return;
116
+ // Begin opening transition
117
+ this._isTransitioning = true;
118
+ // Set initial styles
119
+ this._dropdownElement.classList.remove('hidden');
120
+ this._dropdownElement.style.opacity = '0';
121
+ // Set dropdown width
122
+ this._setDropdownWidth();
123
+ // Reflow
124
+ KTDom.reflow(this._dropdownElement);
125
+ // Apply z-index
126
+ var zIndexToApply = null;
127
+ if (this._config.dropdownZindex) {
128
+ zIndexToApply = this._config.dropdownZindex;
129
+ }
130
+ // Consider the dropdown's current z-index if it's already set and higher
131
+ var currentDropdownZIndexStr = KTDom.getCssProp(this._dropdownElement, 'z-index');
132
+ if (currentDropdownZIndexStr && currentDropdownZIndexStr !== 'auto') {
133
+ var currentDropdownZIndex = parseInt(currentDropdownZIndexStr);
134
+ if (!isNaN(currentDropdownZIndex) && currentDropdownZIndex > (zIndexToApply || 0)) {
135
+ zIndexToApply = currentDropdownZIndex;
136
+ }
137
+ }
138
+ // Ensure dropdown is above elements within its original toggle's parent context
139
+ var toggleParentContextZindex = KTDom.getHighestZindex(this._element);
140
+ if (toggleParentContextZindex !== null && toggleParentContextZindex >= (zIndexToApply || 0)) {
141
+ zIndexToApply = toggleParentContextZindex + 1;
142
+ }
143
+ if (zIndexToApply !== null) {
144
+ this._dropdownElement.style.zIndex = zIndexToApply.toString();
145
+ }
146
+ // Initialize popper
147
+ this._initPopper();
148
+ // Add active classes for visual state
149
+ this._dropdownElement.classList.add('open');
150
+ this._toggleElement.classList.add('active');
151
+ // Start transition
152
+ this._dropdownElement.style.opacity = '1';
153
+ // Handle transition end
154
+ KTDom.transitionEnd(this._dropdownElement, function () {
155
+ _this._isTransitioning = false;
156
+ // Notify unified state manager that transition is complete
157
+ if (_this._unifiedStateManager) {
158
+ _this._unifiedStateManager.setDropdownTransitioning(false, 'dropdown-transition-complete');
159
+ }
160
+ });
161
+ };
162
+ /**
163
+ * Perform the actual close transition
164
+ */
165
+ KTDatepickerDropdown.prototype._performCloseTransition = function () {
166
+ var _this = this;
167
+ if (this._isTransitioning)
168
+ return;
169
+ this._isTransitioning = true;
170
+ this._dropdownElement.style.opacity = '0';
171
+ var transitionComplete = false;
172
+ var fallbackTimer = setTimeout(function () {
173
+ if (!transitionComplete) {
174
+ transitionComplete = true;
175
+ _this._completeCloseTransition();
176
+ }
177
+ }, 300); // Fallback timeout
178
+ var completeTransition = function () {
179
+ if (!transitionComplete) {
180
+ transitionComplete = true;
181
+ clearTimeout(fallbackTimer);
182
+ _this._completeCloseTransition();
183
+ }
184
+ };
185
+ KTDom.transitionEnd(this._dropdownElement, completeTransition);
186
+ };
187
+ /**
188
+ * Complete the close transition
189
+ */
190
+ KTDatepickerDropdown.prototype._completeCloseTransition = function () {
191
+ this._isTransitioning = false;
192
+ this._isOpen = false;
193
+ // Remove active classes
194
+ this._dropdownElement.classList.remove('open');
195
+ this._toggleElement.classList.remove('active');
196
+ // Hide dropdown
197
+ this._dropdownElement.classList.add('hidden');
198
+ // Clean up popper
199
+ this._destroyPopper();
200
+ // Notify unified state manager that transition is complete
201
+ if (this._unifiedStateManager) {
202
+ this._unifiedStateManager.setDropdownTransitioning(false, 'dropdown-transition-complete');
203
+ }
204
+ };
205
+ /**
206
+ * Set dropdown width to match input wrapper element (matching ktselect behavior)
207
+ * Dynamically calculates width based on visibleMonths for multi-month view
208
+ */
209
+ KTDatepickerDropdown.prototype._setDropdownWidth = function () {
210
+ var _a;
211
+ if (!this._dropdownElement || !this._element)
212
+ return;
213
+ // Find the input wrapper element to match its width
214
+ var inputWrapper = this._element.querySelector('[data-kt-datepicker-input-wrapper]');
215
+ if (!inputWrapper)
216
+ return;
217
+ // Get visible months count
218
+ var visibleMonths = (_a = this._config.visibleMonths) !== null && _a !== void 0 ? _a : 1;
219
+ // Check if width is configured
220
+ if (this._config.dropdownWidth) {
221
+ // If custom width is set, use that
222
+ if (this._config.dropdownWidth === 'auto') {
223
+ // Try to measure the actual content width first (if already rendered)
224
+ var multiMonthContainer = this._dropdownElement.querySelector('[data-kt-datepicker-multimonth-container]');
225
+ if (multiMonthContainer && visibleMonths > 1) {
226
+ // Content is already rendered, measure it
227
+ // Force a reflow to ensure accurate measurement
228
+ KTDom.reflow(multiMonthContainer);
229
+ // Measure content width including gaps
230
+ var contentWidth = multiMonthContainer.scrollWidth;
231
+ // Add dropdown padding (px-3 = 12px on each side = 24px total)
232
+ var padding = 24;
233
+ var totalWidth = contentWidth + padding;
234
+ this._dropdownElement.style.width = "".concat(totalWidth, "px");
235
+ this._dropdownElement.style.minWidth = "".concat(totalWidth, "px");
236
+ }
237
+ else if (visibleMonths > 1) {
238
+ // Content not yet rendered, calculate expected width
239
+ // Base month width: 20rem (320px) per month
240
+ // Gap between months: 1rem (16px) per gap (gap-4)
241
+ // Padding: 0.75rem (12px) on each side = 1.5rem (24px) total
242
+ var monthWidth = 320; // 20rem = 320px
243
+ var gapWidth = 16; // 1rem = 16px (gap-4)
244
+ var paddingWidth = 24; // 1.5rem = 24px (px-3 on each side)
245
+ // Calculate total width: (n months * 320px) + ((n-1) gaps * 16px) + padding
246
+ var totalWidth = (visibleMonths * monthWidth) + ((visibleMonths - 1) * gapWidth) + paddingWidth;
247
+ this._dropdownElement.style.width = "".concat(totalWidth, "px");
248
+ this._dropdownElement.style.minWidth = "".concat(totalWidth, "px");
249
+ }
250
+ else {
251
+ // Single month: use auto (CSS default applies)
252
+ this._dropdownElement.style.width = 'auto';
253
+ this._dropdownElement.style.minWidth = 'auto';
254
+ }
255
+ }
256
+ else if (typeof this._config.dropdownWidth === 'string') {
257
+ this._dropdownElement.style.width = this._config.dropdownWidth;
258
+ // Clear min-width when custom width is set
259
+ this._dropdownElement.style.minWidth = '';
260
+ }
261
+ }
262
+ else {
263
+ // Otherwise, match input wrapper width for a cleaner appearance (like ktselect)
264
+ var inputWrapperWidth = inputWrapper.offsetWidth;
265
+ this._dropdownElement.style.width = "".concat(inputWrapperWidth, "px");
266
+ // Clear min-width to ensure input wrapper width takes precedence
267
+ this._dropdownElement.style.minWidth = '';
268
+ }
269
+ };
270
+ /**
271
+ * Detect if the datepicker is inside a modal container
272
+ * @returns The modal element if found, null otherwise
273
+ */
274
+ KTDatepickerDropdown.prototype._getModalContainer = function () {
275
+ return this._element.closest('[data-kt-modal], .kt-modal, .kt-modal-center');
276
+ };
277
+ /**
278
+ * Get the appropriate boundary element for Popper positioning
279
+ * For centered modals, use .kt-modal-content to avoid transform calculation issues
280
+ * @returns The boundary element, or null if no modal found
281
+ */
282
+ KTDatepickerDropdown.prototype._getModalBoundary = function () {
283
+ var modalParent = this._getModalContainer();
284
+ if (!modalParent) {
285
+ return null;
286
+ }
287
+ // For centered modals, use .kt-modal-content as boundary to avoid transform issues
288
+ if (modalParent.classList.contains('kt-modal-center')) {
289
+ var modalContent = modalParent.querySelector('.kt-modal-content');
290
+ return modalContent || modalParent;
291
+ }
292
+ // For non-centered modals, use the modal element itself
293
+ return modalParent;
294
+ };
295
+ /**
296
+ * Get the appropriate positioning strategy based on context
297
+ * @returns 'fixed' if inside non-centered modal, 'absolute' for centered modals or no modal
298
+ */
299
+ KTDatepickerDropdown.prototype._getPositioningStrategy = function () {
300
+ // Check if config explicitly sets strategy
301
+ if (this._config.dropdownStrategy) {
302
+ return this._config.dropdownStrategy;
303
+ }
304
+ // For centered modals, use absolute positioning to avoid transform calculation issues
305
+ // For non-centered modals, use fixed positioning
306
+ var modalParent = this._getModalContainer();
307
+ if (modalParent && modalParent.classList.contains('kt-modal-center')) {
308
+ return 'absolute';
309
+ }
310
+ // Use fixed positioning for non-centered modals
311
+ return modalParent ? 'fixed' : 'absolute';
312
+ };
313
+ /**
314
+ * Get the reference element for Popper positioning (calendar button/icon)
315
+ */
316
+ KTDatepickerDropdown.prototype._getPopperReferenceElement = function () {
317
+ // Use calendar button (toggle element) for positioning - dropdown sticks under the icon
318
+ return this._toggleElement;
319
+ };
320
+ /**
321
+ * Initialize Popper.js for positioning
322
+ */
323
+ KTDatepickerDropdown.prototype._initPopper = function () {
324
+ var _this = this;
325
+ if (this._popperInstance) {
326
+ this._popperInstance.destroy();
327
+ }
328
+ // Default offset - matching ktselect
329
+ var offsetValue = this._config.dropdownOffset || '0, 5';
330
+ // Get configuration options
331
+ var placement = this._config.dropdownPlacement || 'bottom-start';
332
+ var strategy = this._getPositioningStrategy();
333
+ var preventOverflow = this._config.dropdownPreventOverflow !== false;
334
+ var flip = this._config.dropdownFlip !== false;
335
+ // Get appropriate boundary element for modal context
336
+ var boundary = this._getModalBoundary() || this._config.dropdownBoundary || 'clippingParents';
337
+ // Get reference element for positioning (input wrapper, not the calendar button)
338
+ var referenceElement = this._getPopperReferenceElement();
339
+ // Create new popper instance
340
+ this._popperInstance = createPopper(referenceElement, this._dropdownElement, {
341
+ placement: placement,
342
+ strategy: strategy,
343
+ modifiers: [
344
+ {
345
+ name: 'offset',
346
+ options: {
347
+ offset: this._parseOffset(offsetValue),
348
+ },
349
+ },
350
+ {
351
+ name: 'preventOverflow',
352
+ options: {
353
+ boundary: boundary,
354
+ altAxis: preventOverflow,
355
+ },
356
+ },
357
+ {
358
+ name: 'flip',
359
+ options: {
360
+ enabled: flip,
361
+ fallbackPlacements: ['top-start', 'bottom-end', 'top-end'],
362
+ },
363
+ },
364
+ {
365
+ name: 'sameWidth',
366
+ enabled: !this._config.dropdownWidth, // Enable when dropdownWidth is null/undefined (matching ktselect)
367
+ phase: 'beforeWrite',
368
+ requires: ['computeStyles'],
369
+ fn: function (_a) {
370
+ var state = _a.state;
371
+ // Use input wrapper width instead of toggle element width
372
+ var inputWrapper = _this._element.querySelector('[data-kt-datepicker-input-wrapper]');
373
+ if (inputWrapper) {
374
+ state.styles.popper.width = "".concat(inputWrapper.offsetWidth, "px");
375
+ }
376
+ else {
377
+ // Fallback to reference width if input wrapper not found
378
+ state.styles.popper.width = "".concat(state.rects.reference.width, "px");
379
+ }
380
+ },
381
+ effect: function (_a) {
382
+ var state = _a.state;
383
+ // Use input wrapper width instead of toggle element width
384
+ var inputWrapper = _this._element.querySelector('[data-kt-datepicker-input-wrapper]');
385
+ if (inputWrapper && 'offsetWidth' in inputWrapper) {
386
+ state.elements.popper.style.width = "".concat(inputWrapper.offsetWidth, "px");
387
+ }
388
+ else {
389
+ // Fallback to reference width if input wrapper not found
390
+ var reference = state.elements.reference;
391
+ if (reference && 'offsetWidth' in reference) {
392
+ state.elements.popper.style.width = "".concat(reference.offsetWidth, "px");
393
+ }
394
+ }
395
+ },
396
+ },
397
+ ],
398
+ });
399
+ };
400
+ /**
401
+ * Parse offset string to array
402
+ */
403
+ KTDatepickerDropdown.prototype._parseOffset = function (offset) {
404
+ return offset.split(',').map(function (val) { return parseInt(val.trim(), 10); });
405
+ };
406
+ /**
407
+ * Destroy Popper instance
408
+ */
409
+ KTDatepickerDropdown.prototype._destroyPopper = function () {
410
+ if (this._popperInstance) {
411
+ this._popperInstance.destroy();
412
+ this._popperInstance = null;
413
+ }
414
+ };
415
+ /**
416
+ * Update dropdown position
417
+ */
418
+ KTDatepickerDropdown.prototype.updatePosition = function () {
419
+ if (this._popperInstance) {
420
+ this._popperInstance.update();
421
+ }
422
+ };
423
+ /**
424
+ * Update dropdown width (useful after content is rendered)
425
+ */
426
+ KTDatepickerDropdown.prototype.updateWidth = function () {
427
+ this._setDropdownWidth();
428
+ // Also update popper position after width change
429
+ if (this._popperInstance) {
430
+ this._popperInstance.update();
431
+ }
432
+ };
433
+ /**
434
+ * Open the dropdown (legacy method - now handled by observer pattern)
435
+ */
436
+ KTDatepickerDropdown.prototype.open = function () {
437
+ // This method is now deprecated - use unified state manager instead
438
+ if (this._unifiedStateManager) {
439
+ this._unifiedStateManager.setDropdownOpen(true, 'legacy-open-method');
440
+ }
441
+ };
442
+ /**
443
+ * Close the dropdown (legacy method - now handled by observer pattern)
444
+ */
445
+ KTDatepickerDropdown.prototype.close = function () {
446
+ // This method is now deprecated - use unified state manager instead
447
+ if (this._unifiedStateManager) {
448
+ this._unifiedStateManager.setDropdownOpen(false, 'legacy-close-method');
449
+ }
450
+ };
451
+ /**
452
+ * Check if dropdown is open
453
+ */
454
+ KTDatepickerDropdown.prototype.isOpen = function () {
455
+ return this._isOpen;
456
+ };
457
+ /**
458
+ * Dispose of the dropdown
459
+ */
460
+ KTDatepickerDropdown.prototype.dispose = function () {
461
+ // Clean up event listeners
462
+ this._eventManager.removeAllListeners(document);
463
+ this._destroyPopper();
464
+ // Remove dropdown from DOM
465
+ if (this._dropdownElement && this._dropdownElement.parentElement) {
466
+ this._dropdownElement.parentElement.removeChild(this._dropdownElement);
467
+ }
468
+ };
469
+ /**
470
+ * Resolve the container for the dropdown
471
+ */
472
+ KTDatepickerDropdown.prototype._resolveDropdownContainer = function () {
473
+ // Check if dropdown should be rendered in a specific container
474
+ if (this._config.dropdownContainer) {
475
+ var container = document.querySelector(this._config.dropdownContainer);
476
+ if (container instanceof HTMLElement) {
477
+ return container;
478
+ }
479
+ }
480
+ // Default to body for better positioning
481
+ return document.body;
482
+ };
483
+ return KTDatepickerDropdown;
484
+ }(KTComponent));
485
+ export { KTDatepickerDropdown };
486
+ //# sourceMappingURL=dropdown.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"dropdown.js","sourceRoot":"","sources":["../../../../../../src/components/datepicker/ui/input/dropdown.ts"],"names":[],"mappings":"AAAA;;;;GAIG;;;;;;;;;;;;;;;;AAEH,OAAO,EAEL,YAAY,GAEb,MAAM,gBAAgB,CAAC;AACxB,OAAO,KAAK,MAAM,yBAAyB,CAAC;AAE5C,OAAO,WAAW,MAAM,oBAAoB,CAAC;AAE7C,OAAO,EAAE,YAAY,EAAE,MAAM,0BAA0B,CAAC;AAIxD;;;;;;GAMG;AACH;IAA0C,wCAAW;IAkBnD;;;;;;OAMG;IACH,8BACE,OAAoB,EACpB,aAA0B,EAC1B,eAA4B,EAC5B,MAA0B;QAE1B,YAAA,MAAK,WAAE,SAAC;QA9BkB,WAAK,GAAW,qBAAqB,CAAC;QAQlE,mDAAmD;QAC3C,aAAO,GAAY,KAAK,CAAC;QACzB,sBAAgB,GAAY,KAAK,CAAC;QAClC,qBAAe,GAA0B,IAAI,CAAC;QAGtD,kCAAkC;QAC1B,0BAAoB,GAA2C,IAAI,CAAC;QAiB1E,KAAI,CAAC,QAAQ,GAAG,OAAO,CAAC;QACxB,KAAI,CAAC,cAAc,GAAG,aAAa,CAAC;QACpC,KAAI,CAAC,gBAAgB,GAAG,eAAe,CAAC;QACxC,KAAI,CAAC,OAAO,GAAG,MAAM,CAAC;QAEtB,IAAM,SAAS,GAAG,KAAI,CAAC,yBAAyB,EAAE,CAAC;QACnD,IAAI,SAAS,EAAE,CAAC;YACd,IAAI,SAAS,KAAK,KAAI,CAAC,gBAAgB,CAAC,aAAa,EAAE,CAAC;gBACtD,SAAS,CAAC,WAAW,CAAC,KAAI,CAAC,gBAAgB,CAAC,CAAC;YAC/C,CAAC;QACH,CAAC;QAED,KAAI,CAAC,aAAa,GAAG,IAAI,YAAY,EAAE,CAAC;QACxC,KAAI,CAAC,oBAAoB,EAAE,CAAC;;IAC9B,CAAC;IAED;;OAEG;IACK,mDAAoB,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B,CAAC;IACH,2BAAC;AAAD,CAAC,AA7gBD,CAA0C,WAAW,GA6gBpD"}
@@ -0,0 +1,7 @@
1
+ /*
2
+ * ui/input/index.ts - Input module exports
3
+ * Provides input-related components for KTDatepicker
4
+ */
5
+ export * from './segmented-input';
6
+ export * from './dropdown';
7
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../../src/components/datepicker/ui/input/index.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,cAAc,mBAAmB,CAAC;AAClC,cAAc,YAAY,CAAC"}