@krizaka/ui 3.2.0 → 3.4.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 (498) hide show
  1. package/dist/activity-feed.d.ts +199 -0
  2. package/dist/activity-feed.js +155 -0
  3. package/dist/activity-feed.js.map +1 -0
  4. package/dist/argument-card.js +3 -3
  5. package/dist/{chunk-I5RVM5CW.js → chunk-2FRWNSRO.js} +2 -6
  6. package/dist/chunk-2FRWNSRO.js.map +1 -0
  7. package/dist/chunk-7Z4KHPFC.js +42 -0
  8. package/dist/chunk-7Z4KHPFC.js.map +1 -0
  9. package/dist/chunk-BTMFZ66D.js +135 -0
  10. package/dist/chunk-BTMFZ66D.js.map +1 -0
  11. package/dist/chunk-C2BRIFJG.js +13 -0
  12. package/dist/chunk-C2BRIFJG.js.map +1 -0
  13. package/dist/chunk-KDXRYUD3.js +39 -0
  14. package/dist/chunk-KDXRYUD3.js.map +1 -0
  15. package/dist/{chunk-2PUDI7JS.js → chunk-ZKVQGXLD.js} +5 -3
  16. package/dist/{chunk-2PUDI7JS.js.map → chunk-ZKVQGXLD.js.map} +1 -1
  17. package/dist/command.js +1 -1
  18. package/dist/confirm-button.js +1 -1
  19. package/dist/data-table.js +101 -133
  20. package/dist/data-table.js.map +1 -1
  21. package/dist/date-picker.d.ts +3 -1
  22. package/dist/date-picker.js +13 -13
  23. package/dist/date-picker.js.map +1 -1
  24. package/dist/description-list.d.ts +105 -0
  25. package/dist/description-list.js +49 -0
  26. package/dist/description-list.js.map +1 -0
  27. package/dist/dropdown-menu.js +1 -1
  28. package/dist/filter-bar.js +3 -2
  29. package/dist/form.d.ts +23 -12
  30. package/dist/form.js +11 -47
  31. package/dist/form.js.map +1 -1
  32. package/dist/glow-card.js +1 -1
  33. package/dist/image-cropper.js +3 -1
  34. package/dist/image-cropper.js.map +1 -1
  35. package/dist/index.js +13 -66
  36. package/dist/index.js.map +1 -1
  37. package/dist/kanban.d.ts +132 -0
  38. package/dist/kanban.js +187 -0
  39. package/dist/kanban.js.map +1 -0
  40. package/dist/list.d.ts +153 -0
  41. package/dist/list.js +130 -0
  42. package/dist/list.js.map +1 -0
  43. package/dist/map.d.ts +463 -0
  44. package/dist/map.js +952 -0
  45. package/dist/map.js.map +1 -0
  46. package/dist/marquee.js +1 -1
  47. package/dist/motion.css +12 -1
  48. package/dist/native/form.d.ts +60 -15
  49. package/dist/native/form.js +103 -42
  50. package/dist/native/form.js.map +1 -1
  51. package/dist/native/map.d.ts +200 -0
  52. package/dist/native/map.js +673 -0
  53. package/dist/native/map.js.map +1 -0
  54. package/dist/native/media-picker.d.ts +58 -0
  55. package/dist/native/media-picker.js +63 -0
  56. package/dist/native/media-picker.js.map +1 -0
  57. package/dist/native.d.ts +772 -6
  58. package/dist/native.js +2493 -741
  59. package/dist/native.js.map +1 -1
  60. package/dist/nav-bar.js +1 -1
  61. package/dist/page-hero.js +3 -3
  62. package/dist/popover.js +1 -1
  63. package/dist/radio-group.d.ts +66 -32
  64. package/dist/radio-group.js +54 -10
  65. package/dist/radio-group.js.map +1 -1
  66. package/dist/slider.d.ts +96 -35
  67. package/dist/slider.js +67 -13
  68. package/dist/slider.js.map +1 -1
  69. package/dist/stat.d.ts +31 -2
  70. package/dist/stat.js +21 -4
  71. package/dist/stat.js.map +1 -1
  72. package/dist/terminal-replay.js +34 -60
  73. package/dist/terminal-replay.js.map +1 -1
  74. package/dist/toast.js +1 -1
  75. package/dist/tooltip.js +1 -1
  76. package/dist/tree-view.d.ts +111 -0
  77. package/dist/tree-view.js +154 -0
  78. package/dist/tree-view.js.map +1 -0
  79. package/dist/video-player.js +3 -1
  80. package/dist/video-player.js.map +1 -1
  81. package/package.json +148 -11
  82. package/registry/achievement.json +1 -1
  83. package/registry/action-bar.json +1 -1
  84. package/registry/action-sheet.json +121 -0
  85. package/registry/activity-feed.json +468 -0
  86. package/registry/alert.json +1 -1
  87. package/registry/app-shell.json +1 -1
  88. package/registry/argument-card.json +1 -1
  89. package/registry/audio-player.json +1 -1
  90. package/registry/auth-layout.json +1 -1
  91. package/registry/avatar.json +58 -3
  92. package/registry/badge.json +1 -1
  93. package/registry/button.json +1 -1
  94. package/registry/card-grid.json +1 -1
  95. package/registry/card.json +1 -1
  96. package/registry/catalogue-page.json +1 -1
  97. package/registry/changelog-page.json +1 -1
  98. package/registry/checkbox.json +1 -1
  99. package/registry/chip-link.json +1 -1
  100. package/registry/chip.json +1 -1
  101. package/registry/choice-grid.json +1 -1
  102. package/registry/code-block.json +1 -1
  103. package/registry/combobox.json +226 -4
  104. package/registry/command.json +1 -1
  105. package/registry/component-page.json +1 -1
  106. package/registry/confirm-button.json +1 -1
  107. package/registry/contact-page.json +1 -1
  108. package/registry/continue-prompt.json +1 -1
  109. package/registry/countdown.json +1 -1
  110. package/registry/cta-panel.json +1 -1
  111. package/registry/dashboard-layout.json +1 -1
  112. package/registry/data-table.json +1 -1
  113. package/registry/date-picker.json +18 -4
  114. package/registry/decision-list.json +1 -1
  115. package/registry/description-list.json +232 -0
  116. package/registry/detail-layout.json +1 -1
  117. package/registry/dialog.json +75 -4
  118. package/registry/docs-article-page.json +1 -1
  119. package/registry/docs-hub-page.json +1 -1
  120. package/registry/docs-layout.json +1 -1
  121. package/registry/dropdown-menu.json +1 -1
  122. package/registry/empty-state.json +1 -1
  123. package/registry/error-page.json +1 -1
  124. package/registry/examples/action-sheet/native/video-actions.d.ts +4 -0
  125. package/registry/examples/action-sheet/native/video-actions.dark.png +0 -0
  126. package/registry/examples/action-sheet/native/video-actions.js +30 -0
  127. package/registry/examples/action-sheet/native/video-actions.light.png +0 -0
  128. package/registry/examples/action-sheet/native/video-actions.tsx +24 -0
  129. package/registry/examples/activity-feed/job-activity.d.ts +4 -0
  130. package/registry/examples/activity-feed/job-activity.js +21 -0
  131. package/registry/examples/activity-feed/job-activity.tsx +17 -0
  132. package/registry/examples/activity-feed/live.d.ts +4 -0
  133. package/registry/examples/activity-feed/live.js +23 -0
  134. package/registry/examples/activity-feed/live.tsx +24 -0
  135. package/registry/examples/activity-feed/native/notifications.d.ts +4 -0
  136. package/registry/examples/activity-feed/native/notifications.dark.png +0 -0
  137. package/registry/examples/activity-feed/native/notifications.js +18 -0
  138. package/registry/examples/activity-feed/native/notifications.light.png +0 -0
  139. package/registry/examples/activity-feed/native/notifications.tsx +18 -0
  140. package/registry/examples/activity-feed/timeline.d.ts +4 -0
  141. package/registry/examples/activity-feed/timeline.js +25 -0
  142. package/registry/examples/activity-feed/timeline.tsx +19 -0
  143. package/registry/examples/avatar/native/presence.d.ts +4 -0
  144. package/registry/examples/avatar/native/presence.dark.png +0 -0
  145. package/registry/examples/avatar/native/presence.js +18 -0
  146. package/registry/examples/avatar/native/presence.light.png +0 -0
  147. package/registry/examples/avatar/native/presence.tsx +15 -0
  148. package/registry/examples/combobox/native/multiple.d.ts +4 -0
  149. package/registry/examples/combobox/native/multiple.dark.png +0 -0
  150. package/registry/examples/combobox/native/multiple.js +15 -0
  151. package/registry/examples/combobox/native/multiple.light.png +0 -0
  152. package/registry/examples/combobox/native/multiple.tsx +15 -0
  153. package/registry/examples/combobox/native/search.d.ts +4 -0
  154. package/registry/examples/combobox/native/search.dark.png +0 -0
  155. package/registry/examples/combobox/native/search.js +15 -0
  156. package/registry/examples/combobox/native/search.light.png +0 -0
  157. package/registry/examples/combobox/native/search.tsx +15 -0
  158. package/registry/examples/description-list/job-details.d.ts +4 -0
  159. package/registry/examples/description-list/job-details.js +23 -0
  160. package/registry/examples/description-list/job-details.tsx +17 -0
  161. package/registry/examples/description-list/key-value-grid.d.ts +4 -0
  162. package/registry/examples/description-list/key-value-grid.js +22 -0
  163. package/registry/examples/description-list/key-value-grid.tsx +16 -0
  164. package/registry/examples/description-list/native/job-details.d.ts +4 -0
  165. package/registry/examples/description-list/native/job-details.dark.png +0 -0
  166. package/registry/examples/description-list/native/job-details.js +33 -0
  167. package/registry/examples/description-list/native/job-details.light.png +0 -0
  168. package/registry/examples/description-list/native/job-details.tsx +24 -0
  169. package/registry/examples/description-list/receipt.d.ts +4 -0
  170. package/registry/examples/description-list/receipt.js +23 -0
  171. package/registry/examples/description-list/receipt.tsx +17 -0
  172. package/registry/examples/dialog/native/sheet.d.ts +4 -0
  173. package/registry/examples/dialog/native/sheet.dark.png +0 -0
  174. package/registry/examples/dialog/native/sheet.js +21 -0
  175. package/registry/examples/dialog/native/sheet.light.png +0 -0
  176. package/registry/examples/dialog/native/sheet.tsx +18 -0
  177. package/registry/examples/fab/native/extended.d.ts +4 -0
  178. package/registry/examples/fab/native/extended.dark.png +0 -0
  179. package/registry/examples/fab/native/extended.js +18 -0
  180. package/registry/examples/fab/native/extended.light.png +0 -0
  181. package/registry/examples/fab/native/extended.tsx +23 -0
  182. package/registry/examples/field/native/select.d.ts +4 -0
  183. package/registry/examples/field/native/select.dark.png +0 -0
  184. package/registry/examples/field/native/select.js +29 -0
  185. package/registry/examples/field/native/select.light.png +0 -0
  186. package/registry/examples/field/native/select.tsx +25 -0
  187. package/registry/examples/form/native/audience.dark.png +0 -0
  188. package/registry/examples/form/native/audience.light.png +0 -0
  189. package/registry/examples/form/native/profile.dark.png +0 -0
  190. package/registry/examples/form/native/profile.light.png +0 -0
  191. package/registry/examples/form/native/settings.dark.png +0 -0
  192. package/registry/examples/form/native/settings.light.png +0 -0
  193. package/registry/examples/form/native/sign-up.dark.png +0 -0
  194. package/registry/examples/form/native/sign-up.light.png +0 -0
  195. package/registry/examples/form/native/upload.dark.png +0 -0
  196. package/registry/examples/form/native/upload.light.png +0 -0
  197. package/registry/examples/header/native/large-title.d.ts +4 -0
  198. package/registry/examples/header/native/large-title.dark.png +0 -0
  199. package/registry/examples/header/native/large-title.js +23 -0
  200. package/registry/examples/header/native/large-title.light.png +0 -0
  201. package/registry/examples/header/native/large-title.tsx +31 -0
  202. package/registry/examples/image-viewer/native/gallery.d.ts +4 -0
  203. package/registry/examples/image-viewer/native/gallery.dark.png +0 -0
  204. package/registry/examples/image-viewer/native/gallery.js +22 -0
  205. package/registry/examples/image-viewer/native/gallery.light.png +0 -0
  206. package/registry/examples/image-viewer/native/gallery.tsx +21 -0
  207. package/registry/examples/kanban/moderation.d.ts +4 -0
  208. package/registry/examples/kanban/moderation.js +35 -0
  209. package/registry/examples/kanban/moderation.tsx +37 -0
  210. package/registry/examples/list/jobs.d.ts +4 -0
  211. package/registry/examples/list/jobs.js +35 -0
  212. package/registry/examples/list/jobs.tsx +33 -0
  213. package/registry/examples/list/selectable.d.ts +4 -0
  214. package/registry/examples/list/selectable.js +33 -0
  215. package/registry/examples/list/selectable.tsx +30 -0
  216. package/registry/examples/list/virtualized.d.ts +4 -0
  217. package/registry/examples/list/virtualized.js +22 -0
  218. package/registry/examples/list/virtualized.tsx +17 -0
  219. package/registry/examples/loader/native/block.d.ts +4 -0
  220. package/registry/examples/loader/native/block.dark.png +0 -0
  221. package/registry/examples/loader/native/block.js +12 -0
  222. package/registry/examples/loader/native/block.light.png +0 -0
  223. package/registry/examples/loader/native/block.tsx +11 -0
  224. package/registry/examples/loader/native/job-wait.d.ts +4 -0
  225. package/registry/examples/loader/native/job-wait.dark.png +0 -0
  226. package/registry/examples/loader/native/job-wait.js +17 -0
  227. package/registry/examples/loader/native/job-wait.light.png +0 -0
  228. package/registry/examples/loader/native/job-wait.tsx +14 -0
  229. package/registry/examples/map/cluster.d.ts +4 -0
  230. package/registry/examples/map/cluster.js +16 -0
  231. package/registry/examples/map/cluster.tsx +18 -0
  232. package/registry/examples/map/location-picker.d.ts +4 -0
  233. package/registry/examples/map/location-picker.js +24 -0
  234. package/registry/examples/map/location-picker.tsx +22 -0
  235. package/registry/examples/map/native/location-picker.d.ts +4 -0
  236. package/registry/examples/map/native/location-picker.dark.png +0 -0
  237. package/registry/examples/map/native/location-picker.js +14 -0
  238. package/registry/examples/map/native/location-picker.light.png +0 -0
  239. package/registry/examples/map/native/location-picker.tsx +13 -0
  240. package/registry/examples/map/native/places.d.ts +4 -0
  241. package/registry/examples/map/native/places.dark.png +0 -0
  242. package/registry/examples/map/native/places.js +25 -0
  243. package/registry/examples/map/native/places.light.png +0 -0
  244. package/registry/examples/map/native/places.tsx +27 -0
  245. package/registry/examples/map/places.d.ts +4 -0
  246. package/registry/examples/map/places.js +28 -0
  247. package/registry/examples/map/places.tsx +28 -0
  248. package/registry/examples/map/static.d.ts +4 -0
  249. package/registry/examples/map/static.js +22 -0
  250. package/registry/examples/map/static.tsx +18 -0
  251. package/registry/examples/media-picker/native/story.d.ts +4 -0
  252. package/registry/examples/media-picker/native/story.dark.png +0 -0
  253. package/registry/examples/media-picker/native/story.js +30 -0
  254. package/registry/examples/media-picker/native/story.light.png +0 -0
  255. package/registry/examples/media-picker/native/story.tsx +26 -0
  256. package/registry/examples/meter/native/credits.d.ts +4 -0
  257. package/registry/examples/meter/native/credits.dark.png +0 -0
  258. package/registry/examples/meter/native/credits.js +15 -0
  259. package/registry/examples/meter/native/credits.light.png +0 -0
  260. package/registry/examples/meter/native/credits.tsx +12 -0
  261. package/registry/examples/meter/native/split-ring.d.ts +4 -0
  262. package/registry/examples/meter/native/split-ring.dark.png +0 -0
  263. package/registry/examples/meter/native/split-ring.js +24 -0
  264. package/registry/examples/meter/native/split-ring.light.png +0 -0
  265. package/registry/examples/meter/native/split-ring.tsx +19 -0
  266. package/registry/examples/number-ticker/native/balance.d.ts +4 -0
  267. package/registry/examples/number-ticker/native/balance.dark.png +0 -0
  268. package/registry/examples/number-ticker/native/balance.js +18 -0
  269. package/registry/examples/number-ticker/native/balance.light.png +0 -0
  270. package/registry/examples/number-ticker/native/balance.tsx +17 -0
  271. package/registry/examples/onboarding/native/first-launch.d.ts +4 -0
  272. package/registry/examples/onboarding/native/first-launch.dark.png +0 -0
  273. package/registry/examples/onboarding/native/first-launch.js +23 -0
  274. package/registry/examples/onboarding/native/first-launch.light.png +0 -0
  275. package/registry/examples/onboarding/native/first-launch.tsx +19 -0
  276. package/registry/examples/otp-input/native/invalid.d.ts +4 -0
  277. package/registry/examples/otp-input/native/invalid.dark.png +0 -0
  278. package/registry/examples/otp-input/native/invalid.js +15 -0
  279. package/registry/examples/otp-input/native/invalid.light.png +0 -0
  280. package/registry/examples/otp-input/native/invalid.tsx +14 -0
  281. package/registry/examples/otp-input/native/verify.d.ts +4 -0
  282. package/registry/examples/otp-input/native/verify.dark.png +0 -0
  283. package/registry/examples/otp-input/native/verify.js +17 -0
  284. package/registry/examples/otp-input/native/verify.light.png +0 -0
  285. package/registry/examples/otp-input/native/verify.tsx +14 -0
  286. package/registry/examples/permission-prompt/native/blocked.d.ts +4 -0
  287. package/registry/examples/permission-prompt/native/blocked.dark.png +0 -0
  288. package/registry/examples/permission-prompt/native/blocked.js +25 -0
  289. package/registry/examples/permission-prompt/native/blocked.light.png +0 -0
  290. package/registry/examples/permission-prompt/native/blocked.tsx +21 -0
  291. package/registry/examples/permission-prompt/native/camera.d.ts +4 -0
  292. package/registry/examples/permission-prompt/native/camera.dark.png +0 -0
  293. package/registry/examples/permission-prompt/native/camera.js +25 -0
  294. package/registry/examples/permission-prompt/native/camera.light.png +0 -0
  295. package/registry/examples/permission-prompt/native/camera.tsx +21 -0
  296. package/registry/examples/pull-to-refresh/native/feed.d.ts +4 -0
  297. package/registry/examples/pull-to-refresh/native/feed.dark.png +0 -0
  298. package/registry/examples/pull-to-refresh/native/feed.js +14 -0
  299. package/registry/examples/pull-to-refresh/native/feed.light.png +0 -0
  300. package/registry/examples/pull-to-refresh/native/feed.tsx +19 -0
  301. package/registry/examples/radio-group/buttons.d.ts +4 -0
  302. package/registry/examples/radio-group/buttons.js +17 -0
  303. package/registry/examples/radio-group/buttons.tsx +21 -0
  304. package/registry/examples/radio-group/cards.js +1 -1
  305. package/registry/examples/radio-group/cards.tsx +2 -2
  306. package/registry/examples/radio-group/native/buttons.d.ts +4 -0
  307. package/registry/examples/radio-group/native/buttons.dark.png +0 -0
  308. package/registry/examples/radio-group/native/buttons.js +25 -0
  309. package/registry/examples/radio-group/native/buttons.light.png +0 -0
  310. package/registry/examples/radio-group/native/buttons.tsx +21 -0
  311. package/registry/examples/radio-group/native/cards.d.ts +4 -0
  312. package/registry/examples/radio-group/native/cards.dark.png +0 -0
  313. package/registry/examples/radio-group/native/cards.js +23 -0
  314. package/registry/examples/radio-group/native/cards.light.png +0 -0
  315. package/registry/examples/radio-group/native/cards.tsx +19 -0
  316. package/registry/examples/radio-group/native/list.d.ts +4 -0
  317. package/registry/examples/radio-group/native/list.dark.png +0 -0
  318. package/registry/examples/radio-group/native/list.js +24 -0
  319. package/registry/examples/radio-group/native/list.light.png +0 -0
  320. package/registry/examples/radio-group/native/list.tsx +20 -0
  321. package/registry/examples/radio-group/native/segmented.d.ts +4 -0
  322. package/registry/examples/radio-group/native/segmented.dark.png +0 -0
  323. package/registry/examples/radio-group/native/segmented.js +24 -0
  324. package/registry/examples/radio-group/native/segmented.light.png +0 -0
  325. package/registry/examples/radio-group/native/segmented.tsx +20 -0
  326. package/registry/examples/radio-group/segmented.d.ts +4 -0
  327. package/registry/examples/radio-group/segmented.js +15 -0
  328. package/registry/examples/radio-group/segmented.tsx +12 -0
  329. package/registry/examples/search-field/native/cancel.d.ts +4 -0
  330. package/registry/examples/search-field/native/cancel.dark.png +0 -0
  331. package/registry/examples/search-field/native/cancel.js +14 -0
  332. package/registry/examples/search-field/native/cancel.light.png +0 -0
  333. package/registry/examples/search-field/native/cancel.tsx +13 -0
  334. package/registry/examples/slider/floating.d.ts +4 -0
  335. package/registry/examples/slider/floating.js +11 -0
  336. package/registry/examples/slider/floating.tsx +12 -0
  337. package/registry/examples/slider/native/default.d.ts +4 -0
  338. package/registry/examples/slider/native/default.dark.png +0 -0
  339. package/registry/examples/slider/native/default.js +14 -0
  340. package/registry/examples/slider/native/default.light.png +0 -0
  341. package/registry/examples/slider/native/default.tsx +13 -0
  342. package/registry/examples/slider/native/range.d.ts +4 -0
  343. package/registry/examples/slider/native/range.dark.png +0 -0
  344. package/registry/examples/slider/native/range.js +12 -0
  345. package/registry/examples/slider/native/range.light.png +0 -0
  346. package/registry/examples/slider/native/range.tsx +11 -0
  347. package/registry/examples/slider/native/stepped.d.ts +4 -0
  348. package/registry/examples/slider/native/stepped.dark.png +0 -0
  349. package/registry/examples/slider/native/stepped.js +28 -0
  350. package/registry/examples/slider/native/stepped.light.png +0 -0
  351. package/registry/examples/slider/native/stepped.tsx +24 -0
  352. package/registry/examples/slider/native/vertical.d.ts +4 -0
  353. package/registry/examples/slider/native/vertical.dark.png +0 -0
  354. package/registry/examples/slider/native/vertical.js +16 -0
  355. package/registry/examples/slider/native/vertical.light.png +0 -0
  356. package/registry/examples/slider/native/vertical.tsx +13 -0
  357. package/registry/examples/slider/price-range.d.ts +4 -0
  358. package/registry/examples/slider/price-range.js +29 -0
  359. package/registry/examples/slider/price-range.tsx +27 -0
  360. package/registry/examples/slider/stepped.d.ts +4 -0
  361. package/registry/examples/slider/stepped.js +28 -0
  362. package/registry/examples/slider/stepped.tsx +24 -0
  363. package/registry/examples/slider/vertical.d.ts +4 -0
  364. package/registry/examples/slider/vertical.js +15 -0
  365. package/registry/examples/slider/vertical.tsx +14 -0
  366. package/registry/examples/stat/grid.d.ts +4 -0
  367. package/registry/examples/stat/grid.js +17 -0
  368. package/registry/examples/stat/grid.tsx +14 -0
  369. package/registry/examples/stepper/native/run.d.ts +4 -0
  370. package/registry/examples/stepper/native/run.dark.png +0 -0
  371. package/registry/examples/stepper/native/run.js +24 -0
  372. package/registry/examples/stepper/native/run.light.png +0 -0
  373. package/registry/examples/stepper/native/run.tsx +20 -0
  374. package/registry/examples/swipeable-row/native/conversation.d.ts +4 -0
  375. package/registry/examples/swipeable-row/native/conversation.dark.png +0 -0
  376. package/registry/examples/swipeable-row/native/conversation.js +30 -0
  377. package/registry/examples/swipeable-row/native/conversation.light.png +0 -0
  378. package/registry/examples/swipeable-row/native/conversation.tsx +27 -0
  379. package/registry/examples/switch/native/default.d.ts +4 -0
  380. package/registry/examples/switch/native/default.dark.png +0 -0
  381. package/registry/examples/switch/native/default.js +16 -0
  382. package/registry/examples/switch/native/default.light.png +0 -0
  383. package/registry/examples/switch/native/default.tsx +13 -0
  384. package/registry/examples/switch/native/settings.d.ts +4 -0
  385. package/registry/examples/switch/native/settings.dark.png +0 -0
  386. package/registry/examples/switch/native/settings.js +20 -0
  387. package/registry/examples/switch/native/settings.light.png +0 -0
  388. package/registry/examples/switch/native/settings.tsx +17 -0
  389. package/registry/examples/tab-bar/native/main-sections.d.ts +4 -0
  390. package/registry/examples/tab-bar/native/main-sections.dark.png +0 -0
  391. package/registry/examples/tab-bar/native/main-sections.js +29 -0
  392. package/registry/examples/tab-bar/native/main-sections.light.png +0 -0
  393. package/registry/examples/tab-bar/native/main-sections.tsx +30 -0
  394. package/registry/examples/tabs/native/sections.d.ts +4 -0
  395. package/registry/examples/tabs/native/sections.dark.png +0 -0
  396. package/registry/examples/tabs/native/sections.js +23 -0
  397. package/registry/examples/tabs/native/sections.light.png +0 -0
  398. package/registry/examples/tabs/native/sections.tsx +19 -0
  399. package/registry/examples/tabs/native/segmented.d.ts +4 -0
  400. package/registry/examples/tabs/native/segmented.dark.png +0 -0
  401. package/registry/examples/tabs/native/segmented.js +22 -0
  402. package/registry/examples/tabs/native/segmented.light.png +0 -0
  403. package/registry/examples/tabs/native/segmented.tsx +18 -0
  404. package/registry/examples/toast/native/snackbar.d.ts +4 -0
  405. package/registry/examples/toast/native/snackbar.dark.png +0 -0
  406. package/registry/examples/toast/native/snackbar.js +23 -0
  407. package/registry/examples/toast/native/snackbar.light.png +0 -0
  408. package/registry/examples/toast/native/snackbar.tsx +21 -0
  409. package/registry/examples/tree-view/docs.d.ts +4 -0
  410. package/registry/examples/tree-view/docs.js +24 -0
  411. package/registry/examples/tree-view/docs.tsx +22 -0
  412. package/registry/examples/tree-view/lazy.d.ts +4 -0
  413. package/registry/examples/tree-view/lazy.js +21 -0
  414. package/registry/examples/tree-view/lazy.tsx +19 -0
  415. package/registry/fab.json +122 -0
  416. package/registry/field.json +16 -4
  417. package/registry/file-upload.json +2 -2
  418. package/registry/filter-bar.json +1 -1
  419. package/registry/form.json +252 -44
  420. package/registry/gallery-page.json +1 -1
  421. package/registry/glow-card.json +1 -1
  422. package/registry/goal-gauge.json +1 -1
  423. package/registry/header.json +137 -0
  424. package/registry/how-it-works-page.json +1 -1
  425. package/registry/image-cropper.json +1 -1
  426. package/registry/image-viewer.json +107 -0
  427. package/registry/index.json +322 -44
  428. package/registry/iso.json +1 -1
  429. package/registry/kanban.json +253 -0
  430. package/registry/kbd.json +1 -1
  431. package/registry/landing-page.json +1 -1
  432. package/registry/landscape.json +1 -1
  433. package/registry/legal-page.json +1 -1
  434. package/registry/link-card.json +1 -1
  435. package/registry/list.json +367 -30
  436. package/registry/loader.json +157 -4
  437. package/registry/longform-page.json +1 -1
  438. package/registry/map.json +1368 -0
  439. package/registry/marketing-layout.json +1 -1
  440. package/registry/marquee.json +1 -1
  441. package/registry/mascot-quote.json +1 -1
  442. package/registry/mascot-state.json +1 -1
  443. package/registry/mascots.json +1 -1
  444. package/registry/media-capture.json +1 -1
  445. package/registry/media-picker.json +129 -0
  446. package/registry/meter.json +136 -4
  447. package/registry/nav-bar.json +1 -1
  448. package/registry/number-ticker.json +96 -4
  449. package/registry/onboarding.json +95 -0
  450. package/registry/otp-input.json +150 -0
  451. package/registry/page-header.json +1 -1
  452. package/registry/page-hero.json +1 -1
  453. package/registry/page.json +1 -1
  454. package/registry/pagination.json +1 -1
  455. package/registry/permission-prompt.json +172 -0
  456. package/registry/pointer-light.json +1 -1
  457. package/registry/popover.json +1 -1
  458. package/registry/pricing-page.json +1 -1
  459. package/registry/product-page.json +1 -1
  460. package/registry/profile-card.json +1 -1
  461. package/registry/progress.json +2 -2
  462. package/registry/promise-card.json +1 -1
  463. package/registry/pull-to-refresh.json +74 -0
  464. package/registry/radio-group.json +228 -16
  465. package/registry/scroll-stage.json +1 -1
  466. package/registry/search-field.json +30 -3
  467. package/registry/section-backdrop.json +1 -1
  468. package/registry/separator.json +1 -1
  469. package/registry/settings-layout.json +1 -1
  470. package/registry/skeleton.json +1 -1
  471. package/registry/slider.json +315 -14
  472. package/registry/slot.json +1 -1
  473. package/registry/spinner.json +1 -1
  474. package/registry/split-view.json +1 -1
  475. package/registry/stage-banner.json +1 -1
  476. package/registry/stat.json +68 -5
  477. package/registry/status-page.json +1 -1
  478. package/registry/stepper.json +75 -4
  479. package/registry/swipeable-row.json +124 -0
  480. package/registry/switch.json +116 -4
  481. package/registry/tab-bar.json +115 -0
  482. package/registry/tabs.json +96 -6
  483. package/registry/tag-input.json +1 -1
  484. package/registry/terminal-replay.json +1 -1
  485. package/registry/theme.json +8 -1
  486. package/registry/toast.json +17 -3
  487. package/registry/toc.json +1 -1
  488. package/registry/tooltip.json +1 -1
  489. package/registry/tree-view.json +291 -0
  490. package/registry/video-player.json +1 -1
  491. package/registry/video-trimmer.json +1 -1
  492. package/registry/virtual.json +1 -1
  493. package/skills/choice-controls/SKILL.md +39 -0
  494. package/skills/form/SKILL.md +3 -0
  495. package/skills/map/SKILL.md +35 -0
  496. package/dist/chunk-I5RVM5CW.js.map +0 -1
  497. package/dist/chunk-RUPRYJ45.js +0 -82
  498. package/dist/chunk-RUPRYJ45.js.map +0 -1
@@ -0,0 +1,673 @@
1
+ // src/native/map.tsx
2
+ import { Txt, useTheme } from "@krizaka/ui/native";
3
+ import {
4
+ Camera,
5
+ GeoJSONSource,
6
+ Layer,
7
+ LocationManager,
8
+ Map as MapView,
9
+ Marker as MapMarker
10
+ } from "@maplibre/maplibre-react-native";
11
+ import * as React from "react";
12
+ import { Animated, Pressable, StyleSheet, Text, View } from "react-native";
13
+ import Svg, { Circle, Path } from "react-native-svg";
14
+
15
+ // src/map/assets.ts
16
+ var CDN = "https://krizaka-assets.b-cdn.net/maps/v1";
17
+ var MAP_TILES = {
18
+ world: `${CDN}/tiles/world-20261012.pmtiles`,
19
+ quebec: `${CDN}/tiles/quebec-20261012.pmtiles`
20
+ };
21
+ var MAP_GLYPHS = `${CDN}/fonts/{fontstack}/{range}.pbf`;
22
+ var MAP_ATTRIBUTION = { osm: "\xA9 OpenStreetMap contributors", osmUrl: "https://www.openstreetmap.org/copyright", protomaps: "Protomaps", protomapsUrl: "https://protomaps.com" };
23
+ var base = null;
24
+ function mapAssets() {
25
+ const at = (u) => base ? u.replace(CDN, base) : u;
26
+ return { tiles: { world: at(MAP_TILES.world), quebec: at(MAP_TILES.quebec) }, glyphs: at(MAP_GLYPHS) };
27
+ }
28
+
29
+ // src/map/geo.ts
30
+ var R = 63710088e-1;
31
+ var rad = (d) => d * Math.PI / 180;
32
+ function distanceMeters(a, b) {
33
+ const dLat = rad(b[1] - a[1]);
34
+ const dLng = rad(b[0] - a[0]);
35
+ const h = Math.sin(dLat / 2) ** 2 + Math.cos(rad(a[1])) * Math.cos(rad(b[1])) * Math.sin(dLng / 2) ** 2;
36
+ return 2 * R * Math.asin(Math.min(1, Math.sqrt(h)));
37
+ }
38
+ function circlePolygon(center, radius, steps = 64) {
39
+ const [lng, lat] = center;
40
+ const d = radius / R;
41
+ const ring = [];
42
+ for (let i = 0; i <= steps; i++) {
43
+ const brg = 2 * Math.PI * i / steps;
44
+ const lat2 = Math.asin(Math.sin(rad(lat)) * Math.cos(d) + Math.cos(rad(lat)) * Math.sin(d) * Math.cos(brg));
45
+ const lng2 = rad(lng) + Math.atan2(Math.sin(brg) * Math.sin(d) * Math.cos(rad(lat)), Math.cos(d) - Math.sin(rad(lat)) * Math.sin(lat2));
46
+ ring.push([lng2 * 180 / Math.PI, lat2 * 180 / Math.PI]);
47
+ }
48
+ return { type: "Feature", properties: {}, geometry: { type: "Polygon", coordinates: [ring] } };
49
+ }
50
+ function formatDistance(meters, locale) {
51
+ if (meters < 1e3) return new Intl.NumberFormat(locale, { style: "unit", unit: "meter", maximumFractionDigits: 0 }).format(Math.round(meters / 10) * 10);
52
+ return new Intl.NumberFormat(locale, { style: "unit", unit: "kilometer", maximumFractionDigits: meters < 1e4 ? 1 : 0 }).format(meters / 1e3);
53
+ }
54
+
55
+ // ../tokens/dist/native.js
56
+ var themes = /* @__PURE__ */ Object.freeze({ dark: /* @__PURE__ */ Object.freeze({
57
+ "surface0": "#0c0c0e",
58
+ "surface1": "#161618",
59
+ "surface2": "#1f1f23",
60
+ "surface3": "#2a2a2d",
61
+ "media": "#1b1b1d",
62
+ "borderSubtle": "rgba(255,255,255,0.06)",
63
+ "borderDefault": "rgba(255,255,255,0.1)",
64
+ "borderStrong": "rgba(255,255,255,0.16)",
65
+ "textPrimary": "#f5f5f5",
66
+ "textSecondary": "#a0a0a7",
67
+ "textMuted": "#73737d",
68
+ "textOnMedia": "#ffffff",
69
+ "accent": "#196df5",
70
+ "accentHover": "#0e5bd8",
71
+ "accentSoft": "rgba(25,109,245,0.1)",
72
+ "accentText": "#629cf8",
73
+ "accent2": "#196df5",
74
+ "onAccent": "#ffffff",
75
+ "ring": "#196df5",
76
+ "brandGradientFrom": "#0e1525",
77
+ "brandGradientVia": "#0e0f16",
78
+ "brandGradientTo": "#0c0c0e",
79
+ "success": "#10b77f",
80
+ "successText": "#36d399",
81
+ "successSoft": "rgba(16,183,127,0.14)",
82
+ "warning": "#f59f0a",
83
+ "warningText": "#f6a823",
84
+ "warningSoft": "rgba(245,159,10,0.14)",
85
+ "danger": "#ef4343",
86
+ "dangerText": "#f87272",
87
+ "dangerSoft": "rgba(239,67,67,0.14)",
88
+ "info": "#196df5",
89
+ "infoText": "#629cf8",
90
+ "scrim": "rgba(0,0,0,0.6)",
91
+ "scrimStrong": "rgba(0,0,0,0.8)",
92
+ "overlay": "rgba(0,0,0,0.7)",
93
+ "surfaceSheen": "rgba(255,255,255,0.045)",
94
+ "fillShade": "rgba(0,0,0,0.12)",
95
+ "edgeLight": "rgba(255,255,255,0.07)",
96
+ "edgeOnFill": "rgba(255,255,255,0.22)",
97
+ "edgeWell": "rgba(4,4,7,0.5)",
98
+ "glassBg": "rgba(29,29,32,0.88)",
99
+ "glassBorder": "rgba(255,255,255,0.1)"
100
+ }), light: /* @__PURE__ */ Object.freeze({
101
+ "surface0": "#fafafa",
102
+ "surface1": "#ffffff",
103
+ "surface2": "#f1f1f3",
104
+ "surface3": "#e4e4e7",
105
+ "media": "#e9e9ec",
106
+ "borderSubtle": "rgba(0,0,0,0.06)",
107
+ "borderDefault": "rgba(0,0,0,0.1)",
108
+ "borderStrong": "rgba(0,0,0,0.16)",
109
+ "textPrimary": "#18181b",
110
+ "textSecondary": "#64646d",
111
+ "textMuted": "#808089",
112
+ "textOnMedia": "#ffffff",
113
+ "accent": "#0a64f5",
114
+ "accentHover": "#0d55c9",
115
+ "accentSoft": "rgba(10,100,245,0.08)",
116
+ "accentText": "#0954ce",
117
+ "accent2": "#0a64f5",
118
+ "onAccent": "#ffffff",
119
+ "ring": "#0a64f5",
120
+ "brandGradientFrom": "#dcebfe",
121
+ "brandGradientVia": "#f3f6fc",
122
+ "brandGradientTo": "#fafafa",
123
+ "success": "#10b77f",
124
+ "successText": "#0a714e",
125
+ "successSoft": "rgba(16,183,127,0.1)",
126
+ "warning": "#f59f0a",
127
+ "warningText": "#955104",
128
+ "warningSoft": "rgba(245,159,10,0.12)",
129
+ "danger": "#ef4343",
130
+ "dangerText": "#af1d1d",
131
+ "dangerSoft": "rgba(239,67,67,0.1)",
132
+ "info": "#0a64f5",
133
+ "infoText": "#0954ce",
134
+ "scrim": "rgba(0,0,0,0.6)",
135
+ "scrimStrong": "rgba(0,0,0,0.8)",
136
+ "overlay": "rgba(0,0,0,0.7)",
137
+ "surfaceSheen": "rgba(255,255,255,0.7)",
138
+ "fillShade": "rgba(0,0,0,0.12)",
139
+ "edgeLight": "rgba(255,255,255,0.9)",
140
+ "edgeOnFill": "rgba(255,255,255,0.22)",
141
+ "edgeWell": "rgba(48,52,80,0.08)",
142
+ "glassBg": "rgba(255,255,255,0.88)",
143
+ "glassBorder": "rgba(0,0,0,0.08)"
144
+ }) });
145
+ var brands = /* @__PURE__ */ Object.freeze({
146
+ "krizaka": {
147
+ "dark": {
148
+ "accent": "#196df5",
149
+ "accentHover": "#0e5bd8",
150
+ "accentSoft": "rgba(25,109,245,0.1)",
151
+ "accentText": "#629cf8",
152
+ "accent2": "#196df5",
153
+ "onAccent": "#ffffff",
154
+ "ring": "#196df5",
155
+ "info": "#196df5",
156
+ "infoText": "#629cf8",
157
+ "brandGradientFrom": "#0e1525",
158
+ "brandGradientVia": "#0e0f16",
159
+ "brandGradientTo": "#0c0c0e"
160
+ },
161
+ "light": {
162
+ "accent": "#0a64f5",
163
+ "accentHover": "#0d55c9",
164
+ "accentSoft": "rgba(10,100,245,0.08)",
165
+ "accentText": "#0954ce",
166
+ "accent2": "#0a64f5",
167
+ "onAccent": "#ffffff",
168
+ "ring": "#0a64f5",
169
+ "info": "#0a64f5",
170
+ "infoText": "#0954ce",
171
+ "brandGradientFrom": "#dcebfe",
172
+ "brandGradientVia": "#f3f6fc",
173
+ "brandGradientTo": "#fafafa"
174
+ }
175
+ },
176
+ "orazaka": {
177
+ "dark": {
178
+ "accent": "#f67e23",
179
+ "accentHover": "#f79245",
180
+ "accentSoft": "rgba(246,126,35,0.12)",
181
+ "accentText": "#f78c3b",
182
+ "accent2": "#f59e0b",
183
+ "onAccent": "#0c0c0e",
184
+ "ring": "#f67e23",
185
+ "info": "#3b83f7",
186
+ "infoText": "#629cf8",
187
+ "brandGradientFrom": "#28170b",
188
+ "brandGradientVia": "#17130c",
189
+ "brandGradientTo": "#0c0c0e"
190
+ },
191
+ "light": {
192
+ "accent": "#b45309",
193
+ "accentHover": "#964608",
194
+ "accentSoft": "rgba(180,83,9,0.08)",
195
+ "accentText": "#9b4808",
196
+ "accent2": "#a45904",
197
+ "onAccent": "#ffffff",
198
+ "ring": "#b45309",
199
+ "info": "#0a64f5",
200
+ "infoText": "#0954ce",
201
+ "brandGradientFrom": "#ffebd6",
202
+ "brandGradientVia": "#fdf7ed",
203
+ "brandGradientTo": "#fafafa"
204
+ }
205
+ },
206
+ "orochia": {
207
+ "dark": {
208
+ "accent": "#7c3aed",
209
+ "accentHover": "#6d28d9",
210
+ "accentSoft": "rgba(139,92,246,0.12)",
211
+ "accentText": "#a78bfa",
212
+ "accent2": "#db2777",
213
+ "onAccent": "#ffffff",
214
+ "ring": "#a78bfa",
215
+ "info": "#7c3aed",
216
+ "infoText": "#a78bfa",
217
+ "brandGradientFrom": "#1a0e2a",
218
+ "brandGradientVia": "#1c0d17",
219
+ "brandGradientTo": "#0c0c0e"
220
+ },
221
+ "light": {
222
+ "accent": "#7c3aed",
223
+ "accentHover": "#6d28d9",
224
+ "accentSoft": "rgba(124,58,237,0.08)",
225
+ "accentText": "#6d28d9",
226
+ "accent2": "#db2777",
227
+ "onAccent": "#ffffff",
228
+ "ring": "#7c3aed",
229
+ "info": "#7c3aed",
230
+ "infoText": "#6d28d9",
231
+ "brandGradientFrom": "#efe7fe",
232
+ "brandGradientVia": "#fdedf5",
233
+ "brandGradientTo": "#fafafa"
234
+ }
235
+ },
236
+ "yazakia": {
237
+ "dark": {
238
+ "accent": "#24dbc9",
239
+ "accentHover": "#47e1d2",
240
+ "accentSoft": "rgba(36,219,201,0.12)",
241
+ "accentText": "#3ee0cf",
242
+ "accent2": "#22c378",
243
+ "onAccent": "#0c0c0e",
244
+ "ring": "#24dbc9",
245
+ "info": "#3b83f7",
246
+ "infoText": "#629cf8",
247
+ "brandGradientFrom": "#0a241e",
248
+ "brandGradientVia": "#0c1818",
249
+ "brandGradientTo": "#0c0c0e"
250
+ },
251
+ "light": {
252
+ "accent": "#097169",
253
+ "accentHover": "#085e57",
254
+ "accentSoft": "rgba(9,113,105,0.08)",
255
+ "accentText": "#096d64",
256
+ "accent2": "#107546",
257
+ "onAccent": "#ffffff",
258
+ "ring": "#097169",
259
+ "info": "#0a64f5",
260
+ "infoText": "#0954ce",
261
+ "brandGradientFrom": "#e1faf1",
262
+ "brandGradientVia": "#e9fbfa",
263
+ "brandGradientTo": "#fafafa"
264
+ }
265
+ },
266
+ "yororis": {
267
+ "dark": {
268
+ "accent": "#98b587",
269
+ "accentHover": "#adc69f",
270
+ "accentSoft": "rgba(152,181,135,0.12)",
271
+ "accentText": "#a7c497",
272
+ "accent2": "#c3a579",
273
+ "onAccent": "#0c0c0e",
274
+ "ring": "#98b587",
275
+ "info": "#3b83f7",
276
+ "infoText": "#629cf8",
277
+ "brandGradientFrom": "#1c1812",
278
+ "brandGradientVia": "#11140f",
279
+ "brandGradientTo": "#0c0c0e"
280
+ },
281
+ "light": {
282
+ "accent": "#456237",
283
+ "accentHover": "#39532d",
284
+ "accentSoft": "rgba(69,98,55,0.08)",
285
+ "accentText": "#415b33",
286
+ "accent2": "#745834",
287
+ "onAccent": "#ffffff",
288
+ "ring": "#456237",
289
+ "info": "#0a64f5",
290
+ "infoText": "#0954ce",
291
+ "brandGradientFrom": "#f5efe5",
292
+ "brandGradientVia": "#f1f6ee",
293
+ "brandGradientTo": "#fafafa"
294
+ }
295
+ }
296
+ });
297
+
298
+ // src/map/style.ts
299
+ import { layers, namedFlavor } from "@protomaps/basemaps";
300
+ function mix(a, b, t) {
301
+ const p = (h) => [1, 3, 5].map((i) => parseInt(h.slice(i, i + 2), 16));
302
+ const [x, y] = [p(a), p(b)];
303
+ return `#${x.map((v, i) => Math.round(v + (y[i] - v) * t).toString(16).padStart(2, "0")).join("")}`;
304
+ }
305
+ function mapPalette(scheme, brand = "krizaka") {
306
+ const t = { ...themes[scheme], ...brands[brand]?.[scheme] };
307
+ const dark = scheme === "dark";
308
+ const land = dark ? t.surface1 : t.surface0;
309
+ return {
310
+ land,
311
+ background: dark ? t.surface0 : t.surface2,
312
+ water: mix(land, t.accent, dark ? 0.18 : 0.14),
313
+ park: mix(land, t.success, dark ? 0.1 : 0.12),
314
+ road: dark ? mix(land, t.textPrimary, 0.12) : "#ffffff",
315
+ roadMajor: dark ? mix(land, t.textPrimary, 0.2) : mix(land, t.textPrimary, 0.06),
316
+ casing: mix(land, t.textPrimary, dark ? 0.05 : 0.12),
317
+ building: mix(land, t.textPrimary, dark ? 0.06 : 0.07),
318
+ boundary: mix(land, t.textPrimary, 0.3),
319
+ label: t.textSecondary,
320
+ labelStrong: t.textPrimary,
321
+ halo: land,
322
+ accent: t.accent,
323
+ onAccent: t.onAccent
324
+ };
325
+ }
326
+ function mapFlavor(scheme, brand) {
327
+ const c = mapPalette(scheme, brand);
328
+ const base2 = namedFlavor(scheme);
329
+ return {
330
+ ...base2,
331
+ background: c.background,
332
+ earth: c.land,
333
+ park_a: c.park,
334
+ park_b: c.park,
335
+ wood_a: c.park,
336
+ wood_b: c.park,
337
+ scrub_a: c.park,
338
+ scrub_b: c.park,
339
+ glacier: c.land,
340
+ sand: c.land,
341
+ beach: c.land,
342
+ zoo: c.park,
343
+ hospital: c.land,
344
+ industrial: c.land,
345
+ school: c.land,
346
+ military: c.land,
347
+ aerodrome: c.land,
348
+ pedestrian: c.land,
349
+ runway: c.building,
350
+ water: c.water,
351
+ buildings: c.building,
352
+ pier: c.building,
353
+ boundaries: c.boundary,
354
+ railway: c.casing,
355
+ other: c.road,
356
+ minor_service: c.road,
357
+ minor_a: c.road,
358
+ minor_b: c.road,
359
+ link: c.road,
360
+ major: c.roadMajor,
361
+ highway: c.roadMajor,
362
+ bridges_other: c.road,
363
+ bridges_minor: c.road,
364
+ bridges_link: c.road,
365
+ bridges_major: c.roadMajor,
366
+ bridges_highway: c.roadMajor,
367
+ tunnel_other: c.road,
368
+ tunnel_minor: c.road,
369
+ tunnel_link: c.road,
370
+ tunnel_major: c.roadMajor,
371
+ tunnel_highway: c.roadMajor,
372
+ minor_service_casing: c.casing,
373
+ minor_casing: c.casing,
374
+ link_casing: c.casing,
375
+ major_casing_late: c.casing,
376
+ major_casing_early: c.casing,
377
+ highway_casing_late: c.casing,
378
+ highway_casing_early: c.casing,
379
+ bridges_other_casing: c.casing,
380
+ bridges_minor_casing: c.casing,
381
+ bridges_link_casing: c.casing,
382
+ bridges_major_casing: c.casing,
383
+ bridges_highway_casing: c.casing,
384
+ tunnel_other_casing: c.casing,
385
+ tunnel_minor_casing: c.casing,
386
+ tunnel_link_casing: c.casing,
387
+ tunnel_major_casing: c.casing,
388
+ tunnel_highway_casing: c.casing,
389
+ roads_label_minor: c.label,
390
+ roads_label_minor_halo: c.halo,
391
+ roads_label_major: c.label,
392
+ roads_label_major_halo: c.halo,
393
+ ocean_label: c.label,
394
+ subplace_label: c.label,
395
+ subplace_label_halo: c.halo,
396
+ city_label: c.labelStrong,
397
+ city_label_halo: c.halo,
398
+ state_label: c.label,
399
+ state_label_halo: c.halo,
400
+ country_label: c.label,
401
+ address_label: c.label,
402
+ address_label_halo: c.halo,
403
+ regular: "Noto Sans Regular",
404
+ bold: "Noto Sans Medium",
405
+ italic: "Noto Sans Italic",
406
+ // No point-of-interest icons (no sprite to host): the app's own markers carry the places that matter.
407
+ pois: void 0,
408
+ landcover: void 0
409
+ };
410
+ }
411
+ var REGION_FROM_ZOOM = 6.5;
412
+ function mapStyle({ scheme, brand, lang = "en", world = { url: mapAssets().tiles.world, maxzoom: 6 }, region = { url: mapAssets().tiles.quebec, maxzoom: 14 }, glyphs = mapAssets().glyphs }) {
413
+ const flavor = mapFlavor(scheme, brand);
414
+ const attribution = `<a href="${MAP_ATTRIBUTION.protomapsUrl}">${MAP_ATTRIBUTION.protomaps}</a> \xB7 <a href="${MAP_ATTRIBUTION.osmUrl}">${MAP_ATTRIBUTION.osm}</a>`;
415
+ const sources = {};
416
+ const all = [];
417
+ if (world) {
418
+ sources.world = { type: "vector", url: `pmtiles://${world.url}`, attribution };
419
+ for (const l of layers("world", flavor, { lang })) {
420
+ if (l.id === "background") all.push(l);
421
+ else all.push({ ...l, id: `world-${l.id}`, maxzoom: region ? Math.min(l.maxzoom ?? 24, REGION_FROM_ZOOM) : l.maxzoom });
422
+ }
423
+ }
424
+ if (region) {
425
+ sources.region = { type: "vector", url: `pmtiles://${region.url}`, attribution };
426
+ for (const l of layers("region", flavor, { lang })) {
427
+ if (l.id === "background") {
428
+ if (!world) all.push(l);
429
+ continue;
430
+ }
431
+ all.push({ ...l, id: `region-${l.id}`, minzoom: world ? Math.max(l.minzoom ?? 0, REGION_FROM_ZOOM) : l.minzoom });
432
+ }
433
+ }
434
+ const drawn = all.filter((l) => !l.layout?.["icon-image"]);
435
+ return { version: 8, glyphs, sources, layers: drawn.map((l) => l.maxzoom === void 0 ? withoutKey(l, "maxzoom") : l) };
436
+ }
437
+ var withoutKey = (o, key) => Object.fromEntries(Object.entries(o).filter(([k]) => k !== key));
438
+
439
+ // src/native/map.tsx
440
+ import { Fragment, jsx, jsxs } from "react/jsx-runtime";
441
+ var MapContext = React.createContext(null);
442
+ var useMapContext = () => {
443
+ const ctx = React.useContext(MapContext);
444
+ if (!ctx) throw new Error("inside a <Map> only");
445
+ return ctx;
446
+ };
447
+ function Map({ label, center, zoom = 12, brand, lang, region, world, interactive = true, onMoveEnd, onPress, children, style }) {
448
+ const { scheme, theme, radius, motion } = useTheme();
449
+ const reduce = motion.duration.base === 0;
450
+ const camera = React.useRef(null);
451
+ const [places, setPlaces] = React.useState({});
452
+ const registry = React.useMemo(
453
+ () => ({
454
+ add: (id, text) => setPlaces((p) => p[id] === text ? p : { ...p, [id]: text }),
455
+ remove: (id) => setPlaces((p) => {
456
+ const { [id]: _gone, ...rest } = p;
457
+ return rest;
458
+ })
459
+ }),
460
+ []
461
+ );
462
+ const styleJson = React.useMemo(() => mapStyle({ scheme, brand, lang, ...region !== void 0 ? { region } : {}, ...world !== void 0 ? { world } : {} }), [scheme, brand, lang, region, world]);
463
+ const palette = React.useMemo(() => mapPalette(scheme, brand), [scheme, brand]);
464
+ const listed = Object.values(places);
465
+ const ctx = React.useMemo(() => ({ palette, reduce, places: registry }), [palette, reduce, registry]);
466
+ return /* @__PURE__ */ jsx(MapContext.Provider, { value: ctx, children: /* @__PURE__ */ jsxs(View, { style: [styles.root, { borderRadius: radius.xl, borderColor: theme.borderDefault, backgroundColor: theme.surface2 }, style], children: [
467
+ /* @__PURE__ */ jsxs(
468
+ MapView,
469
+ {
470
+ style: StyleSheet.absoluteFill,
471
+ mapStyle: styleJson,
472
+ "aria-label": listed.length ? `${label}: ${listed.join(", ")}` : label,
473
+ dragPan: interactive,
474
+ touchZoom: interactive,
475
+ doubleTapZoom: interactive,
476
+ touchRotate: false,
477
+ touchPitch: false,
478
+ attribution: false,
479
+ logo: false,
480
+ compass: false,
481
+ onRegionDidChange: (e) => onMoveEnd?.({ center: e.nativeEvent.center, zoom: e.nativeEvent.zoom }),
482
+ onPress: (e) => {
483
+ const coords = e.nativeEvent.lngLat;
484
+ if (coords) onPress?.(coords);
485
+ },
486
+ children: [
487
+ /* @__PURE__ */ jsx(Camera, { ref: camera, center: [...center], zoom, duration: reduce ? 0 : 600, easing: reduce ? void 0 : "ease" }),
488
+ children
489
+ ]
490
+ }
491
+ ),
492
+ /* @__PURE__ */ jsx(View, { style: [styles.attribution, { backgroundColor: theme.surface1, borderRadius: radius.sm }], children: /* @__PURE__ */ jsxs(Text, { style: [styles.attributionText, { color: theme.textSecondary }], children: [
493
+ MAP_ATTRIBUTION.protomaps,
494
+ " \xB7 ",
495
+ MAP_ATTRIBUTION.osm
496
+ ] }) })
497
+ ] }) });
498
+ }
499
+ function usePlace(label) {
500
+ const { places } = useMapContext();
501
+ const id = React.useId();
502
+ React.useEffect(() => {
503
+ places.add(id, label);
504
+ return () => places.remove(id);
505
+ }, [id, label, places]);
506
+ return id;
507
+ }
508
+ function Marker({ position, label, onPress, selected, children }) {
509
+ const { palette } = useMapContext();
510
+ const { theme, radius, haptic } = useTheme();
511
+ const id = usePlace(label);
512
+ return /* @__PURE__ */ jsx(MapMarker, { id, lngLat: [...position], anchor: "center", selected, children: /* @__PURE__ */ jsxs(
513
+ Pressable,
514
+ {
515
+ role: onPress ? "button" : void 0,
516
+ "aria-label": label,
517
+ disabled: !onPress,
518
+ hitSlop: 12,
519
+ onPress: () => {
520
+ haptic("selection");
521
+ onPress?.();
522
+ },
523
+ style: styles.markerSlot,
524
+ children: [
525
+ selected ? /* @__PURE__ */ jsx(View, { style: [styles.markerLabel, { backgroundColor: theme.surface1, borderColor: theme.borderDefault, borderRadius: radius.md }], children: /* @__PURE__ */ jsx(Txt, { variant: "label", children: label }) }) : null,
526
+ children ?? /* @__PURE__ */ jsx(View, { style: [styles.dot, { backgroundColor: palette.accent, borderColor: palette.onAccent, transform: [{ scale: selected ? 1.3 : 1 }] }] })
527
+ ]
528
+ }
529
+ ) });
530
+ }
531
+ function UserPosition({ position, label, accuracy }) {
532
+ const { palette, reduce } = useMapContext();
533
+ const id = usePlace(label);
534
+ const [pulse] = React.useState(() => new Animated.Value(0));
535
+ React.useEffect(() => {
536
+ if (reduce) return;
537
+ const loop = Animated.loop(Animated.timing(pulse, { toValue: 1, duration: 2e3, useNativeDriver: true }));
538
+ loop.start();
539
+ return () => loop.stop();
540
+ }, [pulse, reduce]);
541
+ return /* @__PURE__ */ jsxs(Fragment, { children: [
542
+ accuracy ? /* @__PURE__ */ jsx(RadiusCircle, { center: position, radius: accuracy, tone: "soft" }) : null,
543
+ /* @__PURE__ */ jsx(MapMarker, { id, lngLat: [...position], anchor: "center", children: /* @__PURE__ */ jsxs(View, { role: "img", "aria-label": label, accessible: true, style: styles.userSlot, children: [
544
+ /* @__PURE__ */ jsx(Animated.View, { style: [styles.userHalo, { backgroundColor: palette.accent, opacity: pulse.interpolate({ inputRange: [0, 1], outputRange: [0.4, 0] }), transform: [{ scale: pulse.interpolate({ inputRange: [0, 1], outputRange: [1, 3] }) }] }] }),
545
+ /* @__PURE__ */ jsx(View, { style: [styles.user, { backgroundColor: palette.accent, borderColor: palette.halo }] })
546
+ ] }) })
547
+ ] });
548
+ }
549
+ function RadiusCircle({ center, radius, tone = "accent" }) {
550
+ const { palette } = useMapContext();
551
+ const id = `kz-circle-${React.useId().replace(/[^a-zA-Z0-9]/g, "")}`;
552
+ const data = React.useMemo(() => circlePolygon(center, radius), [center, radius]);
553
+ return /* @__PURE__ */ jsxs(GeoJSONSource, { id, data, children: [
554
+ /* @__PURE__ */ jsx(Layer, { type: "fill", id: `${id}-fill`, paint: { "fill-color": palette.accent, "fill-opacity": tone === "soft" ? 0.1 : 0.14 } }),
555
+ /* @__PURE__ */ jsx(Layer, { type: "line", id: `${id}-line`, paint: { "line-color": palette.accent, "line-width": tone === "soft" ? 1 : 2, "line-opacity": tone === "soft" ? 0.4 : 0.9 } })
556
+ ] });
557
+ }
558
+ function Cluster({ points, onPointPress, radius = 48 }) {
559
+ const { palette, places } = useMapContext();
560
+ const id = `kz-cluster-${React.useId().replace(/[^a-zA-Z0-9]/g, "")}`;
561
+ React.useEffect(() => {
562
+ for (const p of points) places.add(`${id}-${p.id}`, p.label);
563
+ return () => points.forEach((p) => places.remove(`${id}-${p.id}`));
564
+ }, [points, places, id]);
565
+ const data = React.useMemo(
566
+ () => ({ type: "FeatureCollection", features: points.map((p) => ({ type: "Feature", properties: { id: p.id, label: p.label }, geometry: { type: "Point", coordinates: [...p.position] } })) }),
567
+ [points]
568
+ );
569
+ return /* @__PURE__ */ jsxs(
570
+ GeoJSONSource,
571
+ {
572
+ id,
573
+ data,
574
+ cluster: true,
575
+ clusterRadius: radius,
576
+ clusterMaxZoom: 15,
577
+ onPress: (e) => {
578
+ const feature = e.nativeEvent?.features?.[0];
579
+ const pid = feature?.properties?.id;
580
+ const point = points.find((p) => p.id === pid);
581
+ if (point) onPointPress?.(point);
582
+ },
583
+ children: [
584
+ /* @__PURE__ */ jsx(Layer, { type: "circle", id: `${id}-groups`, filter: ["has", "point_count"], paint: { "circle-color": palette.accent, "circle-radius": ["step", ["get", "point_count"], 16, 10, 20, 50, 26], "circle-stroke-width": 3, "circle-stroke-color": palette.halo } }),
585
+ /* @__PURE__ */ jsx(Layer, { type: "symbol", id: `${id}-count`, filter: ["has", "point_count"], layout: { "text-field": ["get", "point_count_abbreviated"], "text-font": ["Noto Sans Medium"], "text-size": 13 }, paint: { "text-color": palette.onAccent } }),
586
+ /* @__PURE__ */ jsx(Layer, { type: "circle", id: `${id}-points`, filter: ["!", ["has", "point_count"]], paint: { "circle-color": palette.accent, "circle-radius": 7, "circle-stroke-width": 2.5, "circle-stroke-color": palette.halo } })
587
+ ]
588
+ }
589
+ );
590
+ }
591
+ var pickerLabels = {
592
+ nearMe: "Near me",
593
+ locating: "Finding you\u2026",
594
+ denied: "Location is off for this app. Move the map instead.",
595
+ unavailable: "We could not find you. Move the map instead.",
596
+ you: "You are here",
597
+ distance: (d) => `${d} from you`
598
+ };
599
+ function LocationPicker({ label, value, onValueChange, locale, zoom = 14, radius: zone, origin: originProp = null, labels: given, style, ...map }) {
600
+ const labels = { ...pickerLabels, ...given };
601
+ const { theme, radius, haptic } = useTheme();
602
+ const [origin, setOrigin] = React.useState(originProp);
603
+ const [camera, setCamera] = React.useState(value);
604
+ const [status, setStatus] = React.useState("idle");
605
+ const nearMe = async () => {
606
+ setStatus("locating");
607
+ try {
608
+ if (!await LocationManager.requestPermissions()) return setStatus("denied");
609
+ const p = await LocationManager.getCurrentPosition();
610
+ if (!p) return setStatus("unavailable");
611
+ const here = [p.coords.longitude, p.coords.latitude];
612
+ haptic("success");
613
+ setOrigin(here);
614
+ setCamera(here);
615
+ onValueChange(here);
616
+ setStatus("idle");
617
+ } catch {
618
+ setStatus("unavailable");
619
+ }
620
+ };
621
+ const message = status === "locating" ? labels.locating : status === "denied" ? labels.denied : status === "unavailable" ? labels.unavailable : null;
622
+ return /* @__PURE__ */ jsxs(View, { role: "group", "aria-label": label, style: [styles.picker, style], children: [
623
+ /* @__PURE__ */ jsxs(View, { style: styles.pickerFrame, children: [
624
+ /* @__PURE__ */ jsxs(Map, { ...map, label, center: camera, zoom, onMoveEnd: (v) => onValueChange(v.center), style: StyleSheet.absoluteFill, children: [
625
+ zone ? /* @__PURE__ */ jsx(RadiusCircle, { center: value, radius: zone }) : null,
626
+ origin ? /* @__PURE__ */ jsx(UserPosition, { position: origin, label: labels.you }) : null
627
+ ] }),
628
+ /* @__PURE__ */ jsx(View, { pointerEvents: "none", style: styles.pin, children: /* @__PURE__ */ jsxs(Svg, { width: 30, height: 40, viewBox: "0 0 24 32", "aria-hidden": true, children: [
629
+ /* @__PURE__ */ jsx(Path, { d: "M12 0C5.4 0 0 5.2 0 11.7 0 20.4 12 32 12 32s12-11.6 12-20.3C24 5.2 18.6 0 12 0Z", fill: theme.accent }),
630
+ /* @__PURE__ */ jsx(Circle, { cx: 12, cy: 11.5, r: 4.5, fill: theme.onAccent })
631
+ ] }) }),
632
+ /* @__PURE__ */ jsxs(View, { style: styles.bar, pointerEvents: "box-none", children: [
633
+ origin ? /* @__PURE__ */ jsx(View, { style: [styles.chip, { backgroundColor: theme.surface1, borderColor: theme.borderDefault, borderRadius: radius.full }], children: /* @__PURE__ */ jsx(Txt, { variant: "label", "aria-live": "polite", children: labels.distance(formatDistance(distanceMeters(origin, value), locale)) }) }) : /* @__PURE__ */ jsx(View, {}),
634
+ /* @__PURE__ */ jsx(Pressable, { role: "button", "aria-label": labels.nearMe, disabled: status === "locating", onPress: () => void nearMe(), style: [styles.near, { backgroundColor: theme.surface1, borderColor: theme.borderDefault, borderRadius: radius.full }], children: /* @__PURE__ */ jsx(Txt, { variant: "label", children: status === "locating" ? labels.locating : labels.nearMe }) })
635
+ ] })
636
+ ] }),
637
+ message && status !== "locating" ? /* @__PURE__ */ jsx(Txt, { variant: "caption", tone: "danger", role: "alert", children: message }) : null
638
+ ] });
639
+ }
640
+ var styles = StyleSheet.create({
641
+ root: { height: 280, overflow: "hidden", borderWidth: StyleSheet.hairlineWidth, alignSelf: "stretch" },
642
+ attribution: { position: "absolute", right: 6, bottom: 6, paddingHorizontal: 6, paddingVertical: 2, opacity: 0.9 },
643
+ attributionText: { fontSize: 10 },
644
+ markerSlot: { alignItems: "center", justifyContent: "center", minWidth: 44, minHeight: 44 },
645
+ markerLabel: { position: "absolute", bottom: 40, paddingHorizontal: 8, paddingVertical: 4, borderWidth: StyleSheet.hairlineWidth },
646
+ dot: { width: 18, height: 18, borderRadius: 9, borderWidth: 2.5 },
647
+ userSlot: { width: 44, height: 44, alignItems: "center", justifyContent: "center" },
648
+ userHalo: { position: "absolute", width: 16, height: 16, borderRadius: 8 },
649
+ user: { width: 16, height: 16, borderRadius: 8, borderWidth: 3 },
650
+ picker: { gap: 6, alignSelf: "stretch" },
651
+ pickerFrame: { height: 320 },
652
+ pin: { position: "absolute", left: "50%", top: "50%", marginLeft: -15, marginTop: -40 },
653
+ bar: { position: "absolute", left: 12, right: 12, bottom: 28, flexDirection: "row", justifyContent: "space-between", alignItems: "center", gap: 8 },
654
+ chip: { paddingHorizontal: 12, paddingVertical: 6, borderWidth: StyleSheet.hairlineWidth },
655
+ near: { minHeight: 44, paddingHorizontal: 16, justifyContent: "center", borderWidth: StyleSheet.hairlineWidth }
656
+ });
657
+ export {
658
+ Cluster,
659
+ LocationPicker,
660
+ MAP_ATTRIBUTION,
661
+ MAP_GLYPHS,
662
+ MAP_TILES,
663
+ Map,
664
+ Marker,
665
+ RadiusCircle,
666
+ UserPosition,
667
+ circlePolygon,
668
+ distanceMeters,
669
+ formatDistance,
670
+ mapPalette,
671
+ mapStyle
672
+ };
673
+ //# sourceMappingURL=map.js.map