@ojiepermana/angular 22.1.10 → 22.1.12

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 (340) hide show
  1. package/README.md +32 -26
  2. package/chart/README.md +272 -0
  3. package/component/README.md +89 -0
  4. package/component/accordion/README.md +195 -0
  5. package/component/alert/README.md +184 -0
  6. package/component/alert-dialog/README.md +255 -0
  7. package/component/aspect-ratio/README.md +116 -0
  8. package/component/avatar/README.md +182 -0
  9. package/component/badge/README.md +143 -0
  10. package/component/breadcrumb/README.md +223 -0
  11. package/component/button/README.md +141 -0
  12. package/component/button-group/README.md +214 -0
  13. package/component/calendar/README.md +137 -0
  14. package/component/card/README.md +232 -0
  15. package/component/carousel/README.md +276 -0
  16. package/component/checkbox/README.md +153 -0
  17. package/component/collapsible/README.md +216 -0
  18. package/component/combobox/README.md +202 -0
  19. package/component/command/README.md +287 -0
  20. package/component/composer/README.md +241 -0
  21. package/component/context-menu/README.md +268 -0
  22. package/component/date-picker/README.md +202 -0
  23. package/component/dialog/README.md +276 -0
  24. package/component/drawer/README.md +147 -0
  25. package/component/dropdown-menu/README.md +336 -0
  26. package/component/editor/README.md +152 -0
  27. package/component/empty/README.md +193 -0
  28. package/component/form/README.md +216 -0
  29. package/component/hover-card/README.md +150 -0
  30. package/component/icon/README.md +25 -0
  31. package/component/input/README.md +160 -0
  32. package/component/input-group/README.md +245 -0
  33. package/component/input-otp/README.md +331 -0
  34. package/component/item/README.md +254 -0
  35. package/component/kanban/README.md +81 -0
  36. package/component/kbd/README.md +141 -0
  37. package/component/label/README.md +137 -0
  38. package/component/menubar/README.md +270 -0
  39. package/component/native-select/README.md +176 -0
  40. package/component/navigation-menu/README.md +165 -0
  41. package/component/pagination/README.md +151 -0
  42. package/component/pillbox/README.md +68 -0
  43. package/component/popover/README.md +54 -0
  44. package/component/progress/README.md +160 -0
  45. package/component/radio/README.md +212 -0
  46. package/component/resizable/README.md +178 -0
  47. package/component/scroll-area/README.md +150 -0
  48. package/component/select/README.md +228 -0
  49. package/component/separator/README.md +175 -0
  50. package/component/sheet/README.md +190 -0
  51. package/component/skeleton/README.md +158 -0
  52. package/component/slider/README.md +207 -0
  53. package/component/spinner/README.md +160 -0
  54. package/component/switch/README.md +170 -0
  55. package/component/table/README.md +292 -0
  56. package/component/tabs/README.md +220 -0
  57. package/component/textarea/README.md +169 -0
  58. package/component/timeline/README.md +94 -0
  59. package/component/toast/README.md +173 -0
  60. package/component/toggle/README.md +133 -0
  61. package/component/toggle-group/README.md +234 -0
  62. package/component/tooltip/README.md +230 -0
  63. package/fesm2022/ojiepermana-angular-chart-area.mjs +289 -3
  64. package/fesm2022/ojiepermana-angular-chart-bar.mjs +722 -3
  65. package/fesm2022/ojiepermana-angular-chart-core.mjs +1482 -3
  66. package/fesm2022/ojiepermana-angular-chart-line.mjs +294 -3
  67. package/fesm2022/ojiepermana-angular-chart-pie.mjs +291 -3
  68. package/fesm2022/ojiepermana-angular-chart-primitives.mjs +1301 -3
  69. package/fesm2022/ojiepermana-angular-chart-radar.mjs +421 -3
  70. package/fesm2022/ojiepermana-angular-chart-radial.mjs +295 -3
  71. package/fesm2022/ojiepermana-angular-chart-scatter.mjs +306 -3
  72. package/fesm2022/ojiepermana-angular-chart.mjs +12 -3
  73. package/fesm2022/ojiepermana-angular-component-accordion.mjs +267 -3
  74. package/fesm2022/ojiepermana-angular-component-alert-dialog.mjs +359 -3
  75. package/fesm2022/ojiepermana-angular-component-alert.mjs +101 -3
  76. package/fesm2022/ojiepermana-angular-component-aspect-ratio.mjs +31 -3
  77. package/fesm2022/ojiepermana-angular-component-avatar.mjs +139 -3
  78. package/fesm2022/ojiepermana-angular-component-badge.mjs +57 -3
  79. package/fesm2022/ojiepermana-angular-component-breadcrumb.mjs +192 -3
  80. package/fesm2022/ojiepermana-angular-component-button-group.mjs +95 -3
  81. package/fesm2022/ojiepermana-angular-component-button.mjs +73 -3
  82. package/fesm2022/ojiepermana-angular-component-calendar.mjs +718 -3
  83. package/fesm2022/ojiepermana-angular-component-card.mjs +167 -3
  84. package/fesm2022/ojiepermana-angular-component-carousel.mjs +326 -3
  85. package/fesm2022/ojiepermana-angular-component-checkbox.mjs +190 -3
  86. package/fesm2022/ojiepermana-angular-component-collapsible.mjs +117 -3
  87. package/fesm2022/ojiepermana-angular-component-combobox.mjs +327 -3
  88. package/fesm2022/ojiepermana-angular-component-command.mjs +351 -3
  89. package/fesm2022/ojiepermana-angular-component-composer.mjs +359 -3
  90. package/fesm2022/ojiepermana-angular-component-context-menu.mjs +158 -3
  91. package/fesm2022/ojiepermana-angular-component-date-picker.mjs +482 -3
  92. package/fesm2022/ojiepermana-angular-component-dialog.mjs +400 -3
  93. package/fesm2022/ojiepermana-angular-component-drawer.mjs +1 -3
  94. package/fesm2022/ojiepermana-angular-component-dropdown-menu.mjs +689 -3
  95. package/fesm2022/ojiepermana-angular-component-editor.mjs +511 -3
  96. package/fesm2022/ojiepermana-angular-component-empty.mjs +134 -3
  97. package/fesm2022/ojiepermana-angular-component-form.mjs +438 -3
  98. package/fesm2022/ojiepermana-angular-component-hover-card.mjs +273 -3
  99. package/fesm2022/ojiepermana-angular-component-icon.mjs +139 -3
  100. package/fesm2022/ojiepermana-angular-component-input-group.mjs +176 -3
  101. package/fesm2022/ojiepermana-angular-component-input-otp.mjs +550 -3
  102. package/fesm2022/ojiepermana-angular-component-input.mjs +52 -3
  103. package/fesm2022/ojiepermana-angular-component-item.mjs +264 -3
  104. package/fesm2022/ojiepermana-angular-component-kanban.mjs +310 -3
  105. package/fesm2022/ojiepermana-angular-component-kbd.mjs +48 -3
  106. package/fesm2022/ojiepermana-angular-component-label.mjs +27 -3
  107. package/fesm2022/ojiepermana-angular-component-menubar.mjs +327 -3
  108. package/fesm2022/ojiepermana-angular-component-native-select.mjs +62 -3
  109. package/fesm2022/ojiepermana-angular-component-navigation-menu.mjs +378 -3
  110. package/fesm2022/ojiepermana-angular-component-pagination.mjs +238 -3
  111. package/fesm2022/ojiepermana-angular-component-pillbox.mjs +999 -3
  112. package/fesm2022/ojiepermana-angular-component-popover.mjs +201 -3
  113. package/fesm2022/ojiepermana-angular-component-progress.mjs +57 -3
  114. package/fesm2022/ojiepermana-angular-component-radio.mjs +180 -3
  115. package/fesm2022/ojiepermana-angular-component-resizable.mjs +493 -3
  116. package/fesm2022/ojiepermana-angular-component-scroll-area.mjs +51 -3
  117. package/fesm2022/ojiepermana-angular-component-segmented-control.mjs +227 -3
  118. package/fesm2022/ojiepermana-angular-component-select.mjs +609 -3
  119. package/fesm2022/ojiepermana-angular-component-separator.mjs +31 -3
  120. package/fesm2022/ojiepermana-angular-component-sheet.mjs +407 -3
  121. package/fesm2022/ojiepermana-angular-component-skeleton.mjs +25 -3
  122. package/fesm2022/ojiepermana-angular-component-slider.mjs +456 -3
  123. package/fesm2022/ojiepermana-angular-component-spinner.mjs +56 -3
  124. package/fesm2022/ojiepermana-angular-component-switch.mjs +145 -3
  125. package/fesm2022/ojiepermana-angular-component-table.mjs +155 -3
  126. package/fesm2022/ojiepermana-angular-component-tabs.mjs +315 -3
  127. package/fesm2022/ojiepermana-angular-component-textarea.mjs +46 -3
  128. package/fesm2022/ojiepermana-angular-component-timeline.mjs +237 -3
  129. package/fesm2022/ojiepermana-angular-component-toast.mjs +241 -3
  130. package/fesm2022/ojiepermana-angular-component-toggle-group.mjs +290 -3
  131. package/fesm2022/ojiepermana-angular-component-toggle.mjs +76 -3
  132. package/fesm2022/ojiepermana-angular-component-tooltip.mjs +519 -3
  133. package/fesm2022/ojiepermana-angular-component-utils-core.mjs +310 -3
  134. package/fesm2022/ojiepermana-angular-component-utils-overlay.mjs +62 -3
  135. package/fesm2022/ojiepermana-angular-component-utils-scale.mjs +34 -3
  136. package/fesm2022/ojiepermana-angular-component-utils.mjs +3 -2
  137. package/fesm2022/ojiepermana-angular-component.mjs +4 -4
  138. package/fesm2022/ojiepermana-angular-navigation-core.mjs +21 -3
  139. package/fesm2022/ojiepermana-angular-navigation-icon.mjs +20 -3
  140. package/fesm2022/ojiepermana-angular-navigation-navigation-badge-count.component-CDBxQ8rk.mjs +91 -0
  141. package/fesm2022/ojiepermana-angular-navigation-navigation-dockbar-menu.component-DBQHdvGa.mjs +512 -0
  142. package/fesm2022/ojiepermana-angular-navigation-navigation-entry-grid.component-Cd-jh6tg.mjs +623 -0
  143. package/fesm2022/ojiepermana-angular-navigation-navigation-flyout-menu.component-BCGvhoYj.mjs +404 -0
  144. package/fesm2022/ojiepermana-angular-navigation-navigation-horizontal.component-Dk_03e-6.mjs +466 -0
  145. package/fesm2022/ojiepermana-angular-navigation-ojiepermana-angular-navigation-DNKU6viC.mjs +2642 -0
  146. package/fesm2022/ojiepermana-angular-navigation-service.mjs +725 -3
  147. package/fesm2022/ojiepermana-angular-navigation-types.mjs +65 -4
  148. package/fesm2022/ojiepermana-angular-navigation.mjs +4 -10
  149. package/fesm2022/ojiepermana-angular-sdk.mjs +204 -4
  150. package/fesm2022/ojiepermana-angular-theme-component-settings.mjs +1387 -3
  151. package/fesm2022/ojiepermana-angular-theme-layout-services.mjs +331 -3
  152. package/fesm2022/ojiepermana-angular-theme-layout-types.mjs +45 -4
  153. package/fesm2022/ojiepermana-angular-theme-layout-wrapper.mjs +1044 -3
  154. package/fesm2022/ojiepermana-angular-theme-layout.mjs +729 -3
  155. package/fesm2022/ojiepermana-angular-theme-page-core.mjs +381 -3
  156. package/fesm2022/ojiepermana-angular-theme-page-filter.mjs +267 -3
  157. package/fesm2022/ojiepermana-angular-theme-page-root.mjs +361 -3
  158. package/fesm2022/ojiepermana-angular-theme-page-side.mjs +198 -3
  159. package/fesm2022/ojiepermana-angular-theme-page-slots.mjs +110 -3
  160. package/fesm2022/ojiepermana-angular-theme-page.mjs +7 -2
  161. package/fesm2022/ojiepermana-angular-theme-shell-services.mjs +338 -3
  162. package/fesm2022/ojiepermana-angular-theme-shell-types.mjs +160 -4
  163. package/fesm2022/ojiepermana-angular-theme-shell.mjs +811 -3
  164. package/fesm2022/ojiepermana-angular-theme-styles.mjs +783 -3
  165. package/fesm2022/ojiepermana-angular-theme.mjs +4 -4
  166. package/fesm2022/ojiepermana-angular.mjs +6 -11
  167. package/navigation/README.md +374 -0
  168. package/package.json +81 -20
  169. package/sdk/README.md +212 -0
  170. package/sdk/schematics/collection.json +20 -0
  171. package/sdk/schematics/init/index.js +83 -0
  172. package/sdk/schematics/init/schema.json +19 -0
  173. package/sdk/schematics/ng-add/index.js +147 -0
  174. package/sdk/schematics/ng-add/schema.json +14 -0
  175. package/sdk/schematics/package.json +3 -0
  176. package/sdk/schematics/sdk/index.js +175 -0
  177. package/sdk/schematics/sdk/schema.json +19 -0
  178. package/sdk/sdk.config.example.json +24 -0
  179. package/sdk/src/config/loader.js +43 -0
  180. package/sdk/src/config/schema.js +59 -0
  181. package/sdk/src/emit/client.js +251 -0
  182. package/sdk/src/emit/metadata.js +310 -0
  183. package/sdk/src/emit/models.js +104 -0
  184. package/sdk/src/emit/navigation.js +56 -0
  185. package/sdk/src/emit/operations.js +118 -0
  186. package/sdk/src/emit/public-api.js +54 -0
  187. package/sdk/src/emit/services.js +110 -0
  188. package/sdk/src/engine.js +67 -0
  189. package/sdk/src/layout/per-domain.js +360 -0
  190. package/sdk/src/package.json +3 -0
  191. package/sdk/src/parser/bundle.js +25 -0
  192. package/sdk/src/parser/ir.js +429 -0
  193. package/sdk/src/parser/types.js +7 -0
  194. package/sdk/src/render/template.js +152 -0
  195. package/sdk/src/writer/index.js +286 -0
  196. package/theme/README.md +126 -0
  197. package/theme/component/settings/README.md +135 -0
  198. package/theme/layout/README.md +539 -0
  199. package/theme/page/README.md +453 -0
  200. package/theme/shell/README.md +340 -0
  201. package/theme/styles/README.md +178 -0
  202. package/theme/styles/css/base/components.css +553 -0
  203. package/theme/styles/css/base/index.css +14 -0
  204. package/theme/styles/css/base/package.css +9 -0
  205. package/theme/styles/css/base/prefers-dark.css +86 -0
  206. package/theme/styles/css/base/print.css +62 -0
  207. package/theme/styles/css/base/status.css +38 -0
  208. package/theme/styles/css/base/tailwind.css +165 -0
  209. package/theme/styles/css/base/theme.css +373 -0
  210. package/theme/styles/css/base/tokens.css +361 -0
  211. package/theme/styles/css/color/amber.css +72 -0
  212. package/theme/styles/css/color/blue.css +72 -0
  213. package/theme/styles/css/color/brand.css +38 -0
  214. package/theme/styles/css/color/cyan.css +72 -0
  215. package/theme/styles/css/color/emerald.css +72 -0
  216. package/theme/styles/css/color/fuchsia.css +72 -0
  217. package/theme/styles/css/color/green.css +72 -0
  218. package/theme/styles/css/color/index.css +19 -0
  219. package/theme/styles/css/color/indigo.css +72 -0
  220. package/theme/styles/css/color/lime.css +72 -0
  221. package/theme/styles/css/color/orange.css +72 -0
  222. package/theme/styles/css/color/pink.css +72 -0
  223. package/theme/styles/css/color/purple.css +72 -0
  224. package/theme/styles/css/color/red.css +72 -0
  225. package/theme/styles/css/color/rose.css +72 -0
  226. package/theme/styles/css/color/sky.css +72 -0
  227. package/theme/styles/css/color/teal.css +72 -0
  228. package/theme/styles/css/color/violet.css +72 -0
  229. package/theme/styles/css/color/yellow.css +72 -0
  230. package/theme/styles/css/index.css +18 -0
  231. package/theme/styles/css/neutral/gray.css +63 -0
  232. package/theme/styles/css/neutral/index.css +11 -0
  233. package/theme/styles/css/neutral/mauve.css +63 -0
  234. package/theme/styles/css/neutral/mist.css +63 -0
  235. package/theme/styles/css/neutral/neutral.css +63 -0
  236. package/theme/styles/css/neutral/olive.css +63 -0
  237. package/theme/styles/css/neutral/slate.css +63 -0
  238. package/theme/styles/css/neutral/stone.css +63 -0
  239. package/theme/styles/css/neutral/taupe.css +63 -0
  240. package/theme/styles/css/neutral/zinc.css +63 -0
  241. package/theme/styles/css/radius/index.css +30 -0
  242. package/theme/styles/css/space/index.css +20 -0
  243. package/types/ojiepermana-angular-chart-area.d.ts +76 -1
  244. package/types/ojiepermana-angular-chart-bar.d.ts +201 -1
  245. package/types/ojiepermana-angular-chart-core.d.ts +811 -1
  246. package/types/ojiepermana-angular-chart-line.d.ts +75 -1
  247. package/types/ojiepermana-angular-chart-pie.d.ts +131 -1
  248. package/types/ojiepermana-angular-chart-primitives.d.ts +291 -1
  249. package/types/ojiepermana-angular-chart-radar.d.ts +116 -1
  250. package/types/ojiepermana-angular-chart-radial.d.ts +116 -1
  251. package/types/ojiepermana-angular-chart-scatter.d.ts +125 -1
  252. package/types/ojiepermana-angular-chart.d.ts +2 -1
  253. package/types/ojiepermana-angular-component-accordion.d.ts +85 -1
  254. package/types/ojiepermana-angular-component-alert-dialog.d.ts +140 -1
  255. package/types/ojiepermana-angular-component-alert.d.ts +42 -1
  256. package/types/ojiepermana-angular-component-aspect-ratio.d.ts +12 -1
  257. package/types/ojiepermana-angular-component-avatar.d.ts +56 -1
  258. package/types/ojiepermana-angular-component-badge.d.ts +24 -1
  259. package/types/ojiepermana-angular-component-breadcrumb.d.ts +46 -1
  260. package/types/ojiepermana-angular-component-button-group.d.ts +26 -1
  261. package/types/ojiepermana-angular-component-button.d.ts +27 -1
  262. package/types/ojiepermana-angular-component-calendar.d.ts +111 -1
  263. package/types/ojiepermana-angular-component-card.d.ts +69 -1
  264. package/types/ojiepermana-angular-component-carousel.d.ts +86 -1
  265. package/types/ojiepermana-angular-component-checkbox.d.ts +42 -1
  266. package/types/ojiepermana-angular-component-collapsible.d.ts +42 -1
  267. package/types/ojiepermana-angular-component-combobox.d.ts +60 -1
  268. package/types/ojiepermana-angular-component-command.d.ts +130 -1
  269. package/types/ojiepermana-angular-component-composer.d.ts +90 -1
  270. package/types/ojiepermana-angular-component-context-menu.d.ts +54 -1
  271. package/types/ojiepermana-angular-component-date-picker.d.ts +109 -1
  272. package/types/ojiepermana-angular-component-dialog.d.ts +136 -1
  273. package/types/ojiepermana-angular-component-drawer.d.ts +1 -1
  274. package/types/ojiepermana-angular-component-dropdown-menu.d.ts +248 -1
  275. package/types/ojiepermana-angular-component-editor.d.ts +135 -1
  276. package/types/ojiepermana-angular-component-empty.d.ts +50 -1
  277. package/types/ojiepermana-angular-component-form.d.ts +159 -1
  278. package/types/ojiepermana-angular-component-hover-card.d.ts +75 -1
  279. package/types/ojiepermana-angular-component-icon.d.ts +89 -1
  280. package/types/ojiepermana-angular-component-input-group.d.ts +51 -1
  281. package/types/ojiepermana-angular-component-input-otp.d.ts +155 -1
  282. package/types/ojiepermana-angular-component-input.d.ts +21 -1
  283. package/types/ojiepermana-angular-component-item.d.ts +93 -1
  284. package/types/ojiepermana-angular-component-kanban.d.ts +70 -1
  285. package/types/ojiepermana-angular-component-kbd.d.ts +16 -1
  286. package/types/ojiepermana-angular-component-label.d.ts +11 -1
  287. package/types/ojiepermana-angular-component-menubar.d.ts +93 -1
  288. package/types/ojiepermana-angular-component-native-select.d.ts +26 -1
  289. package/types/ojiepermana-angular-component-navigation-menu.d.ts +104 -1
  290. package/types/ojiepermana-angular-component-pagination.d.ts +33 -1
  291. package/types/ojiepermana-angular-component-pillbox.d.ts +222 -1
  292. package/types/ojiepermana-angular-component-popover.d.ts +66 -1
  293. package/types/ojiepermana-angular-component-progress.d.ts +17 -1
  294. package/types/ojiepermana-angular-component-radio.d.ts +60 -1
  295. package/types/ojiepermana-angular-component-resizable.d.ts +117 -1
  296. package/types/ojiepermana-angular-component-scroll-area.d.ts +19 -1
  297. package/types/ojiepermana-angular-component-segmented-control.d.ts +58 -1
  298. package/types/ojiepermana-angular-component-select.d.ts +122 -1
  299. package/types/ojiepermana-angular-component-separator.d.ts +14 -1
  300. package/types/ojiepermana-angular-component-sheet.d.ts +130 -1
  301. package/types/ojiepermana-angular-component-skeleton.d.ts +10 -1
  302. package/types/ojiepermana-angular-component-slider.d.ts +83 -1
  303. package/types/ojiepermana-angular-component-spinner.d.ts +13 -1
  304. package/types/ojiepermana-angular-component-switch.d.ts +44 -1
  305. package/types/ojiepermana-angular-component-table.d.ts +57 -1
  306. package/types/ojiepermana-angular-component-tabs.d.ts +124 -1
  307. package/types/ojiepermana-angular-component-textarea.d.ts +17 -1
  308. package/types/ojiepermana-angular-component-timeline.d.ts +64 -1
  309. package/types/ojiepermana-angular-component-toast.d.ts +64 -1
  310. package/types/ojiepermana-angular-component-toggle-group.d.ts +90 -1
  311. package/types/ojiepermana-angular-component-toggle.d.ts +25 -1
  312. package/types/ojiepermana-angular-component-tooltip.d.ts +143 -1
  313. package/types/ojiepermana-angular-component-utils-core.d.ts +184 -1
  314. package/types/ojiepermana-angular-component-utils-overlay.d.ts +21 -1
  315. package/types/ojiepermana-angular-component-utils-scale.d.ts +19 -1
  316. package/types/ojiepermana-angular-component-utils.d.ts +2 -1
  317. package/types/ojiepermana-angular-component.d.ts +2 -1
  318. package/types/ojiepermana-angular-navigation-core.d.ts +59 -1
  319. package/types/ojiepermana-angular-navigation-icon.d.ts +12 -1
  320. package/types/ojiepermana-angular-navigation-service.d.ts +116 -1
  321. package/types/ojiepermana-angular-navigation-types.d.ts +144 -1
  322. package/types/ojiepermana-angular-navigation.d.ts +507 -1
  323. package/types/ojiepermana-angular-sdk.d.ts +89 -1
  324. package/types/ojiepermana-angular-theme-component-settings.d.ts +154 -1
  325. package/types/ojiepermana-angular-theme-layout-services.d.ts +147 -1
  326. package/types/ojiepermana-angular-theme-layout-types.d.ts +40 -1
  327. package/types/ojiepermana-angular-theme-layout-wrapper.d.ts +299 -1
  328. package/types/ojiepermana-angular-theme-layout.d.ts +129 -1
  329. package/types/ojiepermana-angular-theme-page-core.d.ts +157 -1
  330. package/types/ojiepermana-angular-theme-page-filter.d.ts +77 -1
  331. package/types/ojiepermana-angular-theme-page-root.d.ts +88 -1
  332. package/types/ojiepermana-angular-theme-page-side.d.ts +50 -1
  333. package/types/ojiepermana-angular-theme-page-slots.d.ts +40 -1
  334. package/types/ojiepermana-angular-theme-page.d.ts +5 -1
  335. package/types/ojiepermana-angular-theme-shell-services.d.ts +193 -1
  336. package/types/ojiepermana-angular-theme-shell-types.d.ts +105 -1
  337. package/types/ojiepermana-angular-theme-shell.d.ts +100 -1
  338. package/types/ojiepermana-angular-theme-styles.d.ts +319 -1
  339. package/types/ojiepermana-angular-theme.d.ts +2 -1
  340. package/types/ojiepermana-angular.d.ts +5 -5
@@ -1,7 +1,486 @@
1
- export * from '@ojiepermana/angular-component/date-picker';
1
+ import { Overlay } from '@angular/cdk/overlay';
2
+ import { TemplatePortal } from '@angular/cdk/portal';
3
+ import { DOCUMENT } from '@angular/common';
4
+ import * as i0 from '@angular/core';
5
+ import { inject, DestroyRef, Injector, ViewContainerRef, model, input, booleanAttribute, signal, linkedSignal, untracked, viewChild, computed, effect, afterNextRender, forwardRef, Component } from '@angular/core';
6
+ import { takeUntilDestroyed } from '@angular/core/rxjs-interop';
7
+ import { NG_VALUE_ACCESSOR, NG_VALIDATORS } from '@angular/forms';
8
+ import { formatIsoDate, parseIsoDate, startOfDay, CalendarComponent } from '@ojiepermana/angular/component/calendar';
9
+ import { injectUniqueId, cn } from '@ojiepermana/angular/component/utils/core';
10
+ import { overlayDismissals } from '@ojiepermana/angular/component/utils/overlay';
2
11
 
3
- // Generated by scripts/gen-umbrella-entrypoints.mjs — do not edit by hand.
12
+ class DatePickerComponent {
13
+ overlay = inject(Overlay);
14
+ documentRef = inject(DOCUMENT);
15
+ destroyRef = inject(DestroyRef);
16
+ injector = inject(Injector);
17
+ viewContainerRef = inject(ViewContainerRef);
18
+ instanceId = injectUniqueId('DatePicker');
19
+ value = model(null, /* @ts-ignore */
20
+ ...(ngDevMode ? [{ debugName: "value" }] : /* istanbul ignore next */ []));
21
+ id = input(null, /* @ts-ignore */
22
+ ...(ngDevMode ? [{ debugName: "id" }] : /* istanbul ignore next */ []));
23
+ placeholder = input('Pick a date', /* @ts-ignore */
24
+ ...(ngDevMode ? [{ debugName: "placeholder" }] : /* istanbul ignore next */ []));
25
+ required = input(false, { ...(ngDevMode ? { debugName: "required" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
26
+ min = input(null, /* @ts-ignore */
27
+ ...(ngDevMode ? [{ debugName: "min" }] : /* istanbul ignore next */ []));
28
+ max = input(null, /* @ts-ignore */
29
+ ...(ngDevMode ? [{ debugName: "max" }] : /* istanbul ignore next */ []));
30
+ startAt = input(null, /* @ts-ignore */
31
+ ...(ngDevMode ? [{ debugName: "startAt" }] : /* istanbul ignore next */ []));
32
+ startView = input('month', /* @ts-ignore */
33
+ ...(ngDevMode ? [{ debugName: "startView" }] : /* istanbul ignore next */ []));
34
+ touchUi = input(false, { ...(ngDevMode ? { debugName: "touchUi" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
35
+ dateFilter = input(null, /* @ts-ignore */
36
+ ...(ngDevMode ? [{ debugName: "dateFilter" }] : /* istanbul ignore next */ []));
37
+ panelClass = input('datepicker-panel', /* @ts-ignore */
38
+ ...(ngDevMode ? [{ debugName: "panelClass" }] : /* istanbul ignore next */ []));
39
+ panelAriaLabel = input('Choose a date', /* @ts-ignore */
40
+ ...(ngDevMode ? [{ debugName: "panelAriaLabel" }] : /* istanbul ignore next */ []));
41
+ invalidFormatMessage = input('Enter a valid date in YYYY-MM-DD format.', /* @ts-ignore */
42
+ ...(ngDevMode ? [{ debugName: "invalidFormatMessage" }] : /* istanbul ignore next */ []));
43
+ ariaLabel = input(null, { ...(ngDevMode ? { debugName: "ariaLabel" } : /* istanbul ignore next */ {}), alias: 'aria-label' });
44
+ ariaLabelledby = input(null, { ...(ngDevMode ? { debugName: "ariaLabelledby" } : /* istanbul ignore next */ {}), alias: 'aria-labelledby' });
45
+ ariaDescribedby = input(null, { ...(ngDevMode ? { debugName: "ariaDescribedby" } : /* istanbul ignore next */ {}), alias: 'aria-describedby' });
46
+ disabled = input(false, { ...(ngDevMode ? { debugName: "disabled" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
47
+ class = input('', /* @ts-ignore */
48
+ ...(ngDevMode ? [{ debugName: "class" }] : /* istanbul ignore next */ []));
49
+ isEditing = signal(false, /* @ts-ignore */
50
+ ...(ngDevMode ? [{ debugName: "isEditing" }] : /* istanbul ignore next */ []));
51
+ isOpen = signal(false, /* @ts-ignore */
52
+ ...(ngDevMode ? [{ debugName: "isOpen" }] : /* istanbul ignore next */ []));
53
+ /**
54
+ * The text the field shows. Re-seeds from `value`, but a draft the user is
55
+ * still editing -- or one already refused -- outlives an incoming binding
56
+ * change, so their typing is never swapped out from under them.
57
+ */
58
+ inputValue = linkedSignal({ ...(ngDevMode ? { debugName: "inputValue" } : /* istanbul ignore next */ {}), source: () => this.value(),
59
+ computation: (value, previous) => previous && untracked(() => this.isEditing() || !!this.draftError())
60
+ ? previous.value
61
+ : value
62
+ ? formatIsoDate(value)
63
+ : '' });
64
+ panelId = `${this.instanceId}-panel`;
65
+ errorId = `${this.instanceId}-error`;
66
+ draftError = signal(null, /* @ts-ignore */
67
+ ...(ngDevMode ? [{ debugName: "draftError" }] : /* istanbul ignore next */ []));
68
+ cvaDisabled = signal(false, /* @ts-ignore */
69
+ ...(ngDevMode ? [{ debugName: "cvaDisabled" }] : /* istanbul ignore next */ []));
70
+ overlayRef = null;
71
+ restoreFocusElement = null;
72
+ validatorNotified = false;
73
+ onChangeFn = () => { };
74
+ onTouchedFn = () => { };
75
+ onValidatorChangeFn = () => { };
76
+ origin = viewChild.required('origin', /* @ts-ignore */
77
+ ...(ngDevMode ? [{ debugName: "origin" }] : /* istanbul ignore next */ []));
78
+ input = viewChild.required('input', /* @ts-ignore */
79
+ ...(ngDevMode ? [{ debugName: "input" }] : /* istanbul ignore next */ []));
80
+ panel = viewChild.required('panel', /* @ts-ignore */
81
+ ...(ngDevMode ? [{ debugName: "panel" }] : /* istanbul ignore next */ []));
82
+ calendar = viewChild('calendar', /* @ts-ignore */
83
+ ...(ngDevMode ? [{ debugName: "calendar" }] : /* istanbul ignore next */ []));
84
+ classes = computed(() => cn('date-picker block w-full', this.class()), /* @ts-ignore */
85
+ ...(ngDevMode ? [{ debugName: "classes" }] : /* istanbul ignore next */ []));
86
+ inputClasses = computed(() => cn('date-picker-input w-full', this.isDisabled() ? 'opacity-60' : ''), /* @ts-ignore */
87
+ ...(ngDevMode ? [{ debugName: "inputClasses" }] : /* istanbul ignore next */ []));
88
+ resolvedId = computed(() => this.id() ?? this.instanceId, /* @ts-ignore */
89
+ ...(ngDevMode ? [{ debugName: "resolvedId" }] : /* istanbul ignore next */ []));
90
+ isDisabled = computed(() => this.disabled() || this.cvaDisabled(), /* @ts-ignore */
91
+ ...(ngDevMode ? [{ debugName: "isDisabled" }] : /* istanbul ignore next */ []));
92
+ /**
93
+ * What a bound control is told. A refused draft is reported here as well as
94
+ * painted on the field, so the form cannot call itself valid while the input
95
+ * is showing an error the user has to fix.
96
+ */
97
+ validationErrors = computed(() => {
98
+ const draft = this.draftError();
99
+ if (draft) {
100
+ return draft;
101
+ }
102
+ const value = this.value();
103
+ return value ? this.rangeError(value) : null;
104
+ }, /* @ts-ignore */
105
+ ...(ngDevMode ? [{ debugName: "validationErrors" }] : /* istanbul ignore next */ []));
106
+ validationError = computed(() => this.validationErrors() ? this.invalidFormatMessage() : null, /* @ts-ignore */
107
+ ...(ngDevMode ? [{ debugName: "validationError" }] : /* istanbul ignore next */ []));
108
+ resolvedAriaDescribedby = computed(() => [this.ariaDescribedby(), this.validationError() ? this.errorId : null]
109
+ .filter((value) => !!value)
110
+ .join(' ') || null, /* @ts-ignore */
111
+ ...(ngDevMode ? [{ debugName: "resolvedAriaDescribedby" }] : /* istanbul ignore next */ []));
112
+ constructor() {
113
+ this.destroyRef.onDestroy(() => {
114
+ // Nothing survives the teardown to hand focus back to, so drop the target
115
+ // before closing: the overlay still has to be disposed of.
116
+ this.restoreFocusElement = null;
117
+ this.close();
118
+ });
119
+ effect(() => {
120
+ this.validationErrors();
121
+ untracked(() => this.notifyValidatorChange());
122
+ });
123
+ effect(() => {
124
+ if (this.isDisabled() && this.isOpen()) {
125
+ this.close();
126
+ }
127
+ });
128
+ }
129
+ open(restoreFocusElement) {
130
+ if (this.isDisabled() || this.isOpen()) {
131
+ return;
132
+ }
133
+ const originEl = this.origin().nativeElement;
134
+ this.restoreFocusElement =
135
+ restoreFocusElement ??
136
+ (this.documentRef.activeElement instanceof HTMLElement
137
+ ? this.documentRef.activeElement
138
+ : this.input().nativeElement);
139
+ this.overlayRef = this.overlay.create({
140
+ positionStrategy: this.overlay
141
+ .position()
142
+ .flexibleConnectedTo(originEl)
143
+ .withPositions([
144
+ { originX: 'start', originY: 'bottom', overlayX: 'start', overlayY: 'top', offsetY: 8 },
145
+ { originX: 'start', originY: 'top', overlayX: 'start', overlayY: 'bottom', offsetY: -8 },
146
+ ])
147
+ .withPush(true)
148
+ .withViewportMargin(8),
149
+ scrollStrategy: this.overlay.scrollStrategies.reposition(),
150
+ hasBackdrop: true,
151
+ backdropClass: 'cdk-overlay-transparent-backdrop',
152
+ panelClass: this.panelClass(),
153
+ });
154
+ const portal = new TemplatePortal(this.panel(), this.viewContainerRef);
155
+ const overlayRef = this.overlayRef;
156
+ if (!overlayRef) {
157
+ return;
158
+ }
159
+ overlayRef.attach(portal);
160
+ overlayDismissals(overlayRef, originEl)
161
+ .pipe(takeUntilDestroyed(this.destroyRef))
162
+ .subscribe(() => this.close());
163
+ this.isOpen.set(true);
164
+ afterNextRender({ read: () => this.calendar()?.focusActiveCell() }, { injector: this.injector });
165
+ }
166
+ close() {
167
+ if (!this.isOpen()) {
168
+ return;
169
+ }
170
+ this.overlayRef?.dispose();
171
+ this.overlayRef = null;
172
+ this.isOpen.set(false);
173
+ const restoreFocusElement = this.restoreFocusElement;
174
+ this.restoreFocusElement = null;
175
+ this.restoreFocusAfterOverlayTeardown(restoreFocusElement);
176
+ }
177
+ toggle(event) {
178
+ if (this.isOpen()) {
179
+ this.close();
180
+ }
181
+ else {
182
+ this.open(event?.currentTarget instanceof HTMLElement ? event.currentTarget : null);
183
+ }
184
+ }
185
+ onInput(event) {
186
+ const text = event.target.value;
187
+ this.isEditing.set(true);
188
+ this.inputValue.set(text);
189
+ const parsed = parseIsoDate(text);
190
+ if (parsed && this.isSelectable(parsed)) {
191
+ this.setValue(parsed, true);
192
+ }
193
+ else {
194
+ this.draftError.set(null);
195
+ }
196
+ }
197
+ onBlur() {
198
+ this.isEditing.set(false);
199
+ this.commitInput();
200
+ this.onTouchedFn();
201
+ }
202
+ onEnter(event) {
203
+ event.preventDefault();
204
+ this.commitInput();
205
+ }
206
+ onCalendarSelect(date) {
207
+ this.setValue(date, true);
208
+ this.close();
209
+ }
210
+ writeValue(value) {
211
+ this.setValue(value, false);
212
+ }
213
+ registerOnChange(fn) {
214
+ this.onChangeFn = fn;
215
+ }
216
+ registerOnTouched(fn) {
217
+ this.onTouchedFn = fn;
218
+ }
219
+ setDisabledState(state) {
220
+ this.cvaDisabled.set(state);
221
+ }
222
+ validate() {
223
+ return this.validationErrors();
224
+ }
225
+ registerOnValidatorChange(fn) {
226
+ this.onValidatorChangeFn = fn;
227
+ }
228
+ commitInput() {
229
+ const draft = this.inputValue().trim();
230
+ if (!draft && !this.required()) {
231
+ this.setValue(null, true);
232
+ return;
233
+ }
234
+ const parsed = parseIsoDate(draft);
235
+ if (!parsed) {
236
+ this.draftError.set({ dateParse: { text: draft } });
237
+ return;
238
+ }
239
+ const rangeError = this.rangeError(parsed);
240
+ if (rangeError) {
241
+ this.draftError.set(rangeError);
242
+ return;
243
+ }
244
+ this.setValue(parsed, true);
245
+ }
246
+ setValue(value, emit) {
247
+ const next = value ? new Date(value.getTime()) : null;
248
+ this.value.set(next);
249
+ this.inputValue.set(next ? formatIsoDate(next) : '');
250
+ this.draftError.set(null);
251
+ if (emit) {
252
+ this.onChangeFn(next);
253
+ }
254
+ }
255
+ /**
256
+ * A refused draft never reaches the control, so nothing else would tell the
257
+ * forms API to ask again. The first flush is the initial computation, which
258
+ * the control's own set-up validation already covers.
259
+ */
260
+ notifyValidatorChange() {
261
+ if (!this.validatorNotified) {
262
+ this.validatorNotified = true;
263
+ return;
264
+ }
265
+ this.onValidatorChangeFn();
266
+ }
267
+ isSelectable(date) {
268
+ return !this.rangeError(date);
269
+ }
270
+ /**
271
+ * The same question the calendar answers, answered the same way, and named.
272
+ *
273
+ * This used to compare raw `Date` values while the calendar normalised to the
274
+ * start of the day, so a `min` or `max` carrying a time component split the
275
+ * two apart: a boundary date typed into the field was rejected, while the very
276
+ * same date clicked in the popup was accepted. One rule, one helper, one
277
+ * answer -- and the answer now says which constraint refused the date, so a
278
+ * bound control can report it.
279
+ */
280
+ rangeError(date) {
281
+ const day = startOfDay(date).getTime();
282
+ const min = this.min();
283
+ if (min && day < startOfDay(min).getTime()) {
284
+ return { dateMin: { min, actual: date } };
285
+ }
286
+ const max = this.max();
287
+ if (max && day > startOfDay(max).getTime()) {
288
+ return { dateMax: { max, actual: date } };
289
+ }
290
+ const filter = this.dateFilter();
291
+ return filter && !filter(date) ? { dateFilter: { actual: date } } : null;
292
+ }
293
+ /**
294
+ * CDK disposes its overlay during the current event turn. Restoring focus in
295
+ * that same turn works in Chromium but WebKit may move it back to the body
296
+ * while it removes the pane. Defer until the post-disposal frame so every
297
+ * browser receives a stable focus restoration.
298
+ */
299
+ restoreFocusAfterOverlayTeardown(element) {
300
+ if (!element?.isConnected || this.isDisabled()) {
301
+ return;
302
+ }
303
+ const view = this.documentRef.defaultView;
304
+ if (!view) {
305
+ queueMicrotask(() => {
306
+ if (element.isConnected && !this.isDisabled()) {
307
+ element.focus();
308
+ }
309
+ });
310
+ return;
311
+ }
312
+ view.requestAnimationFrame(() => {
313
+ if (element.isConnected && !this.isDisabled()) {
314
+ element.focus();
315
+ }
316
+ });
317
+ }
318
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.4", ngImport: i0, type: DatePickerComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
319
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.4", type: DatePickerComponent, isStandalone: true, selector: "DatePicker", inputs: { value: { classPropertyName: "value", publicName: "value", isSignal: true, isRequired: false, transformFunction: null }, id: { classPropertyName: "id", publicName: "id", isSignal: true, isRequired: false, transformFunction: null }, placeholder: { classPropertyName: "placeholder", publicName: "placeholder", isSignal: true, isRequired: false, transformFunction: null }, required: { classPropertyName: "required", publicName: "required", isSignal: true, isRequired: false, transformFunction: null }, min: { classPropertyName: "min", publicName: "min", isSignal: true, isRequired: false, transformFunction: null }, max: { classPropertyName: "max", publicName: "max", isSignal: true, isRequired: false, transformFunction: null }, startAt: { classPropertyName: "startAt", publicName: "startAt", isSignal: true, isRequired: false, transformFunction: null }, startView: { classPropertyName: "startView", publicName: "startView", isSignal: true, isRequired: false, transformFunction: null }, touchUi: { classPropertyName: "touchUi", publicName: "touchUi", isSignal: true, isRequired: false, transformFunction: null }, dateFilter: { classPropertyName: "dateFilter", publicName: "dateFilter", isSignal: true, isRequired: false, transformFunction: null }, panelClass: { classPropertyName: "panelClass", publicName: "panelClass", isSignal: true, isRequired: false, transformFunction: null }, panelAriaLabel: { classPropertyName: "panelAriaLabel", publicName: "panelAriaLabel", isSignal: true, isRequired: false, transformFunction: null }, invalidFormatMessage: { classPropertyName: "invalidFormatMessage", publicName: "invalidFormatMessage", isSignal: true, isRequired: false, transformFunction: null }, ariaLabel: { classPropertyName: "ariaLabel", publicName: "aria-label", isSignal: true, isRequired: false, transformFunction: null }, ariaLabelledby: { classPropertyName: "ariaLabelledby", publicName: "aria-labelledby", isSignal: true, isRequired: false, transformFunction: null }, ariaDescribedby: { classPropertyName: "ariaDescribedby", publicName: "aria-describedby", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, class: { classPropertyName: "class", publicName: "class", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { value: "valueChange" }, host: { properties: { "class": "classes()" } }, providers: [
320
+ { provide: NG_VALUE_ACCESSOR, useExisting: forwardRef(() => DatePickerComponent), multi: true },
321
+ { provide: NG_VALIDATORS, useExisting: forwardRef(() => DatePickerComponent), multi: true },
322
+ ], viewQueries: [{ propertyName: "origin", first: true, predicate: ["origin"], descendants: true, isSignal: true }, { propertyName: "input", first: true, predicate: ["input"], descendants: true, isSignal: true }, { propertyName: "panel", first: true, predicate: ["panel"], descendants: true, isSignal: true }, { propertyName: "calendar", first: true, predicate: ["calendar"], descendants: true, isSignal: true }], ngImport: i0, template: `
323
+ <div #origin class="date-picker-shell">
324
+ <input
325
+ #input
326
+ type="text"
327
+ [id]="resolvedId()"
328
+ [class]="inputClasses()"
329
+ [attr.aria-label]="ariaLabel()"
330
+ [attr.aria-labelledby]="ariaLabelledby()"
331
+ [attr.aria-describedby]="resolvedAriaDescribedby()"
332
+ [attr.aria-invalid]="validationError() ? 'true' : null"
333
+ [attr.placeholder]="placeholder()"
334
+ [required]="required()"
335
+ [disabled]="isDisabled()"
336
+ [value]="inputValue()"
337
+ (input)="onInput($any($event))"
338
+ (blur)="onBlur()"
339
+ (keydown.enter)="onEnter($any($event))"
340
+ />
341
+
342
+ <button
343
+ type="button"
344
+ class="date-picker-toggle"
345
+ [attr.aria-label]="isOpen() ? 'Close calendar' : 'Open calendar'"
346
+ [attr.aria-controls]="panelId"
347
+ [attr.aria-expanded]="isOpen()"
348
+ aria-haspopup="dialog"
349
+ [disabled]="isDisabled()"
350
+ (click)="toggle($event)"
351
+ >
352
+ <svg
353
+ aria-hidden="true"
354
+ viewBox="0 0 24 24"
355
+ width="18"
356
+ height="18"
357
+ fill="none"
358
+ stroke="currentColor"
359
+ stroke-width="2"
360
+ stroke-linecap="round"
361
+ stroke-linejoin="round"
362
+ >
363
+ <rect x="3" y="5" width="18" height="16" rx="2" />
364
+ <path d="M8 3v4" />
365
+ <path d="M16 3v4" />
366
+ <path d="M3 11h18" />
367
+ </svg>
368
+ </button>
369
+ </div>
370
+
371
+ @if (validationError(); as error) {
372
+ <p [id]="errorId" class="date-picker-error" role="status">{{ error }}</p>
373
+ }
374
+
375
+ <ng-template #panel>
376
+ <div
377
+ [id]="panelId"
378
+ class="date-picker-panel"
379
+ role="dialog"
380
+ aria-modal="false"
381
+ [attr.aria-label]="panelAriaLabel()"
382
+ [attr.data-touch-ui]="touchUi() ? 'true' : null"
383
+ >
384
+ <Calendar
385
+ #calendar
386
+ [value]="value()"
387
+ [min]="min()"
388
+ [max]="max()"
389
+ [startAt]="startAt()"
390
+ [startView]="startView()"
391
+ [dateFilter]="dateFilter()"
392
+ [disabled]="isDisabled()"
393
+ (valueChange)="onCalendarSelect($event)"
394
+ />
395
+ </div>
396
+ </ng-template>
397
+ `, isInline: true, styles: [":host{display:block;min-width:0}.date-picker-shell{position:relative;width:100%}.date-picker-input{display:block;width:100%;height:var(--control-height-md);min-width:0;border:1px solid hsl(var(--input));border-radius:var(--radius);background:transparent;padding:calc(var(--spacing-base) * 2) calc(var(--spacing-base) * 11) calc(var(--spacing-base) * 2) calc(var(--spacing-base) * 3);color:hsl(var(--foreground));font-family:var(--font-sans);font-size:var(--text-sm);line-height:var(--text-sm--line-height);box-shadow:var(--shadow-sm, 0 1px 2px hsl(var(--foreground) / .05));transition:border-color .15s ease,box-shadow .15s ease}.date-picker-input::placeholder{color:hsl(var(--muted-foreground))}.date-picker-input:hover:not(:disabled){border-color:hsl(var(--foreground) / .45)}.date-picker-input:focus-visible{outline:none;border-color:hsl(var(--ring));box-shadow:0 0 0 1px hsl(var(--ring))}.date-picker-input:disabled{cursor:not-allowed;background:hsl(var(--muted) / .45)}.date-picker-toggle{position:absolute;inset-block-start:50%;inset-inline-end:var(--spacing-base);display:inline-flex;width:calc(var(--spacing-base) * 7);height:calc(var(--spacing-base) * 7);transform:translateY(-50%);align-items:center;justify-content:center;border:0;border-radius:calc(var(--radius) - .125rem);background:transparent;color:hsl(var(--muted-foreground));cursor:pointer;transition:background-color .15s ease,color .15s ease}.date-picker-toggle:hover:not(:disabled){background:hsl(var(--accent));color:hsl(var(--accent-foreground))}.date-picker-toggle:focus-visible{outline:2px solid hsl(var(--ring));outline-offset:2px}.date-picker-toggle:disabled{cursor:not-allowed;opacity:.5}.date-picker-panel{width:fit-content;border:1px solid hsl(var(--border));border-radius:var(--radius);background:hsl(var(--popover));color:hsl(var(--popover-foreground));box-shadow:var(--shadow-md, 0 12px 24px -16px hsl(var(--foreground) / .35))}.date-picker-panel Calendar{border:0;border-radius:inherit;background:transparent}.date-picker-panel[data-touch-ui=true]{max-width:min(100vw - calc(var(--spacing-base) * 8),calc(var(--spacing-base) * 88))}.date-picker-error{margin:calc(var(--spacing-base) * 1.5) 0 0;color:hsl(var(--destructive));font-size:var(--text-sm);line-height:var(--text-sm--line-height)}\n"], dependencies: [{ kind: "component", type: CalendarComponent, selector: "Calendar", inputs: ["value", "min", "max", "startAt", "startView", "dateFilter", "disabled", "class"], outputs: ["valueChange"] }] });
398
+ }
399
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.4", ngImport: i0, type: DatePickerComponent, decorators: [{
400
+ type: Component,
401
+ args: [{ selector: 'DatePicker', imports: [CalendarComponent], providers: [
402
+ { provide: NG_VALUE_ACCESSOR, useExisting: forwardRef(() => DatePickerComponent), multi: true },
403
+ { provide: NG_VALIDATORS, useExisting: forwardRef(() => DatePickerComponent), multi: true },
404
+ ], host: { '[class]': 'classes()' }, template: `
405
+ <div #origin class="date-picker-shell">
406
+ <input
407
+ #input
408
+ type="text"
409
+ [id]="resolvedId()"
410
+ [class]="inputClasses()"
411
+ [attr.aria-label]="ariaLabel()"
412
+ [attr.aria-labelledby]="ariaLabelledby()"
413
+ [attr.aria-describedby]="resolvedAriaDescribedby()"
414
+ [attr.aria-invalid]="validationError() ? 'true' : null"
415
+ [attr.placeholder]="placeholder()"
416
+ [required]="required()"
417
+ [disabled]="isDisabled()"
418
+ [value]="inputValue()"
419
+ (input)="onInput($any($event))"
420
+ (blur)="onBlur()"
421
+ (keydown.enter)="onEnter($any($event))"
422
+ />
423
+
424
+ <button
425
+ type="button"
426
+ class="date-picker-toggle"
427
+ [attr.aria-label]="isOpen() ? 'Close calendar' : 'Open calendar'"
428
+ [attr.aria-controls]="panelId"
429
+ [attr.aria-expanded]="isOpen()"
430
+ aria-haspopup="dialog"
431
+ [disabled]="isDisabled()"
432
+ (click)="toggle($event)"
433
+ >
434
+ <svg
435
+ aria-hidden="true"
436
+ viewBox="0 0 24 24"
437
+ width="18"
438
+ height="18"
439
+ fill="none"
440
+ stroke="currentColor"
441
+ stroke-width="2"
442
+ stroke-linecap="round"
443
+ stroke-linejoin="round"
444
+ >
445
+ <rect x="3" y="5" width="18" height="16" rx="2" />
446
+ <path d="M8 3v4" />
447
+ <path d="M16 3v4" />
448
+ <path d="M3 11h18" />
449
+ </svg>
450
+ </button>
451
+ </div>
452
+
453
+ @if (validationError(); as error) {
454
+ <p [id]="errorId" class="date-picker-error" role="status">{{ error }}</p>
455
+ }
456
+
457
+ <ng-template #panel>
458
+ <div
459
+ [id]="panelId"
460
+ class="date-picker-panel"
461
+ role="dialog"
462
+ aria-modal="false"
463
+ [attr.aria-label]="panelAriaLabel()"
464
+ [attr.data-touch-ui]="touchUi() ? 'true' : null"
465
+ >
466
+ <Calendar
467
+ #calendar
468
+ [value]="value()"
469
+ [min]="min()"
470
+ [max]="max()"
471
+ [startAt]="startAt()"
472
+ [startView]="startView()"
473
+ [dateFilter]="dateFilter()"
474
+ [disabled]="isDisabled()"
475
+ (valueChange)="onCalendarSelect($event)"
476
+ />
477
+ </div>
478
+ </ng-template>
479
+ `, styles: [":host{display:block;min-width:0}.date-picker-shell{position:relative;width:100%}.date-picker-input{display:block;width:100%;height:var(--control-height-md);min-width:0;border:1px solid hsl(var(--input));border-radius:var(--radius);background:transparent;padding:calc(var(--spacing-base) * 2) calc(var(--spacing-base) * 11) calc(var(--spacing-base) * 2) calc(var(--spacing-base) * 3);color:hsl(var(--foreground));font-family:var(--font-sans);font-size:var(--text-sm);line-height:var(--text-sm--line-height);box-shadow:var(--shadow-sm, 0 1px 2px hsl(var(--foreground) / .05));transition:border-color .15s ease,box-shadow .15s ease}.date-picker-input::placeholder{color:hsl(var(--muted-foreground))}.date-picker-input:hover:not(:disabled){border-color:hsl(var(--foreground) / .45)}.date-picker-input:focus-visible{outline:none;border-color:hsl(var(--ring));box-shadow:0 0 0 1px hsl(var(--ring))}.date-picker-input:disabled{cursor:not-allowed;background:hsl(var(--muted) / .45)}.date-picker-toggle{position:absolute;inset-block-start:50%;inset-inline-end:var(--spacing-base);display:inline-flex;width:calc(var(--spacing-base) * 7);height:calc(var(--spacing-base) * 7);transform:translateY(-50%);align-items:center;justify-content:center;border:0;border-radius:calc(var(--radius) - .125rem);background:transparent;color:hsl(var(--muted-foreground));cursor:pointer;transition:background-color .15s ease,color .15s ease}.date-picker-toggle:hover:not(:disabled){background:hsl(var(--accent));color:hsl(var(--accent-foreground))}.date-picker-toggle:focus-visible{outline:2px solid hsl(var(--ring));outline-offset:2px}.date-picker-toggle:disabled{cursor:not-allowed;opacity:.5}.date-picker-panel{width:fit-content;border:1px solid hsl(var(--border));border-radius:var(--radius);background:hsl(var(--popover));color:hsl(var(--popover-foreground));box-shadow:var(--shadow-md, 0 12px 24px -16px hsl(var(--foreground) / .35))}.date-picker-panel Calendar{border:0;border-radius:inherit;background:transparent}.date-picker-panel[data-touch-ui=true]{max-width:min(100vw - calc(var(--spacing-base) * 8),calc(var(--spacing-base) * 88))}.date-picker-error{margin:calc(var(--spacing-base) * 1.5) 0 0;color:hsl(var(--destructive));font-size:var(--text-sm);line-height:var(--text-sm--line-height)}\n"] }]
480
+ }], ctorParameters: () => [], propDecorators: { value: [{ type: i0.Input, args: [{ isSignal: true, alias: "value", required: false }] }, { type: i0.Output, args: ["valueChange"] }], id: [{ type: i0.Input, args: [{ isSignal: true, alias: "id", required: false }] }], placeholder: [{ type: i0.Input, args: [{ isSignal: true, alias: "placeholder", required: false }] }], required: [{ type: i0.Input, args: [{ isSignal: true, alias: "required", required: false }] }], min: [{ type: i0.Input, args: [{ isSignal: true, alias: "min", required: false }] }], max: [{ type: i0.Input, args: [{ isSignal: true, alias: "max", required: false }] }], startAt: [{ type: i0.Input, args: [{ isSignal: true, alias: "startAt", required: false }] }], startView: [{ type: i0.Input, args: [{ isSignal: true, alias: "startView", required: false }] }], touchUi: [{ type: i0.Input, args: [{ isSignal: true, alias: "touchUi", required: false }] }], dateFilter: [{ type: i0.Input, args: [{ isSignal: true, alias: "dateFilter", required: false }] }], panelClass: [{ type: i0.Input, args: [{ isSignal: true, alias: "panelClass", required: false }] }], panelAriaLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "panelAriaLabel", required: false }] }], invalidFormatMessage: [{ type: i0.Input, args: [{ isSignal: true, alias: "invalidFormatMessage", required: false }] }], ariaLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "aria-label", required: false }] }], ariaLabelledby: [{ type: i0.Input, args: [{ isSignal: true, alias: "aria-labelledby", required: false }] }], ariaDescribedby: [{ type: i0.Input, args: [{ isSignal: true, alias: "aria-describedby", required: false }] }], disabled: [{ type: i0.Input, args: [{ isSignal: true, alias: "disabled", required: false }] }], class: [{ type: i0.Input, args: [{ isSignal: true, alias: "class", required: false }] }], origin: [{ type: i0.ViewChild, args: ['origin', { isSignal: true }] }], input: [{ type: i0.ViewChild, args: ['input', { isSignal: true }] }], panel: [{ type: i0.ViewChild, args: ['panel', { isSignal: true }] }], calendar: [{ type: i0.ViewChild, args: ['calendar', { isSignal: true }] }] } });
4
481
 
5
482
  /**
6
483
  * Generated bundle index. Do not edit.
7
- */
484
+ */
485
+
486
+ export { DatePickerComponent };