snice 7.2.0 → 7.3.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 (200) hide show
  1. package/.agents/skills/snice/SKILL.md +40 -13
  2. package/README.md +6 -5
  3. package/adapters/react/SniceProvider.js +1 -1
  4. package/adapters/react/SniceRouter.d.ts +2 -0
  5. package/adapters/react/SniceRouter.js +3 -2
  6. package/adapters/react/SniceRouter.js.map +1 -1
  7. package/adapters/react/matchRoute.d.ts +4 -1
  8. package/adapters/react/matchRoute.js +13 -3
  9. package/adapters/react/matchRoute.js.map +1 -1
  10. package/adapters/react/useRequestHandler.js +1 -1
  11. package/bin/analyzer-contracts.js +2 -1
  12. package/bin/project-analyzer.js +302 -14
  13. package/bin/templates/AI_GUIDANCE.md +6 -1
  14. package/bin/templates/default/README.md +1 -1
  15. package/bin/templates/default/src/components/app-header.ts +11 -16
  16. package/bin/templates/default/src/components/notification-badge.ts +5 -14
  17. package/bin/templates/default/src/components/search-bar.ts +21 -65
  18. package/bin/templates/default/src/pages/dashboard.ts +15 -11
  19. package/bin/templates/default/src/pages/data.ts +10 -13
  20. package/bin/templates/default/src/pages/notifications.ts +4 -9
  21. package/bin/templates/default/src/pages/profile.ts +2 -8
  22. package/bin/templates/default/src/pages/settings.ts +16 -16
  23. package/dist/cdn/accordion/snice-accordion.js +1 -1
  24. package/dist/cdn/action-bar/snice-action-bar.js +1 -1
  25. package/dist/cdn/activity-feed/snice-activity-feed.js +1 -1
  26. package/dist/cdn/alert/snice-alert.js +1 -1
  27. package/dist/cdn/app-tiles/snice-app-tiles.js +1 -1
  28. package/dist/cdn/approval-flow/snice-approval-flow.js +1 -1
  29. package/dist/cdn/audio-recorder/snice-audio-recorder.js +1 -1
  30. package/dist/cdn/availability/snice-availability.js +1 -1
  31. package/dist/cdn/avatar/snice-avatar.js +1 -1
  32. package/dist/cdn/avatar-group/snice-avatar-group.js +1 -1
  33. package/dist/cdn/badge/snice-badge.js +1 -1
  34. package/dist/cdn/banner/snice-banner.js +1 -1
  35. package/dist/cdn/binpack/snice-binpack.js +1 -1
  36. package/dist/cdn/book/snice-book.js +1 -1
  37. package/dist/cdn/booking/snice-booking.js +1 -1
  38. package/dist/cdn/breadcrumbs/snice-breadcrumbs.js +1 -1
  39. package/dist/cdn/button/snice-button.js +1 -1
  40. package/dist/cdn/calendar/snice-calendar.js +1 -1
  41. package/dist/cdn/camera/snice-camera.js +1 -1
  42. package/dist/cdn/camera-annotate/snice-camera-annotate.js +1 -1
  43. package/dist/cdn/candlestick/snice-candlestick.js +1 -1
  44. package/dist/cdn/card/snice-card.js +1 -1
  45. package/dist/cdn/carousel/snice-carousel.js +1 -1
  46. package/dist/cdn/cart/snice-cart.js +1 -1
  47. package/dist/cdn/chart/snice-chart.js +1 -1
  48. package/dist/cdn/chat/snice-chat.js +1 -1
  49. package/dist/cdn/checkbox/snice-checkbox.js +1 -1
  50. package/dist/cdn/chip/snice-chip.js +1 -1
  51. package/dist/cdn/code-block/snice-code-block.js +1 -1
  52. package/dist/cdn/color-display/snice-color-display.js +1 -1
  53. package/dist/cdn/color-picker/snice-color-picker.js +1 -1
  54. package/dist/cdn/command-palette/snice-command-palette.js +1 -1
  55. package/dist/cdn/comments/snice-comments.js +1 -1
  56. package/dist/cdn/countdown/snice-countdown.js +1 -1
  57. package/dist/cdn/cropper/snice-cropper.js +1 -1
  58. package/dist/cdn/data-card/snice-data-card.js +1 -1
  59. package/dist/cdn/date-picker/snice-date-picker.js +1 -1
  60. package/dist/cdn/date-range-picker/snice-date-range-picker.js +1 -1
  61. package/dist/cdn/date-time-picker/snice-date-time-picker.js +1 -1
  62. package/dist/cdn/diff/snice-diff.js +1 -1
  63. package/dist/cdn/divider/snice-divider.js +1 -1
  64. package/dist/cdn/doc/snice-doc.js +1 -1
  65. package/dist/cdn/draw/snice-draw.js +1 -1
  66. package/dist/cdn/drawer/snice-drawer.js +1 -1
  67. package/dist/cdn/empty-state/snice-empty-state.js +1 -1
  68. package/dist/cdn/estimate/snice-estimate.js +1 -1
  69. package/dist/cdn/file-gallery/snice-file-gallery.js +1 -1
  70. package/dist/cdn/file-upload/snice-file-upload.js +1 -1
  71. package/dist/cdn/flip-card/snice-flip-card.js +1 -1
  72. package/dist/cdn/flow/snice-flow.js +1 -1
  73. package/dist/cdn/form-layout/snice-form-layout.js +1 -1
  74. package/dist/cdn/funnel/snice-funnel.js +1 -1
  75. package/dist/cdn/gantt/snice-gantt.js +1 -1
  76. package/dist/cdn/gauge/snice-gauge.js +1 -1
  77. package/dist/cdn/grid/snice-grid.js +1 -1
  78. package/dist/cdn/heatmap/snice-heatmap.js +1 -1
  79. package/dist/cdn/image/snice-image.js +1 -1
  80. package/dist/cdn/input/snice-input.js +1 -1
  81. package/dist/cdn/invoice/snice-invoice.js +1 -1
  82. package/dist/cdn/kanban/snice-kanban.js +1 -1
  83. package/dist/cdn/key-value/snice-key-value.js +1 -1
  84. package/dist/cdn/kpi/snice-kpi.js +1 -1
  85. package/dist/cdn/layout/snice-layout.js +1 -1
  86. package/dist/cdn/leaderboard/snice-leaderboard.js +1 -1
  87. package/dist/cdn/link/snice-link.js +1 -1
  88. package/dist/cdn/link-preview/snice-link-preview.js +1 -1
  89. package/dist/cdn/list/snice-list.js +1 -1
  90. package/dist/cdn/location/snice-location.js +1 -1
  91. package/dist/cdn/login/snice-login.js +1 -1
  92. package/dist/cdn/map/snice-map.js +1 -1
  93. package/dist/cdn/markdown/snice-markdown.js +1 -1
  94. package/dist/cdn/masonry/snice-masonry.js +1 -1
  95. package/dist/cdn/menu/snice-menu.js +1 -1
  96. package/dist/cdn/message-strip/snice-message-strip.js +1 -1
  97. package/dist/cdn/modal/snice-modal.js +1 -1
  98. package/dist/cdn/music-player/snice-music-player.js +1 -1
  99. package/dist/cdn/nav/snice-nav.js +1 -1
  100. package/dist/cdn/network-graph/snice-network-graph.js +1 -1
  101. package/dist/cdn/notification-center/snice-notification-center.js +1 -1
  102. package/dist/cdn/order-tracker/snice-order-tracker.js +1 -1
  103. package/dist/cdn/org-chart/snice-org-chart.js +1 -1
  104. package/dist/cdn/pagination/snice-pagination.js +1 -1
  105. package/dist/cdn/paint/snice-paint.js +1 -1
  106. package/dist/cdn/pdf-viewer/snice-pdf-viewer.js +1 -1
  107. package/dist/cdn/permission-matrix/snice-permission-matrix.js +1 -1
  108. package/dist/cdn/podcast-player/snice-podcast-player.js +1 -1
  109. package/dist/cdn/popover/snice-popover.js +1 -1
  110. package/dist/cdn/pricing-table/snice-pricing-table.js +1 -1
  111. package/dist/cdn/product-card/snice-product-card.js +1 -1
  112. package/dist/cdn/progress/snice-progress.js +1 -1
  113. package/dist/cdn/progress-ring/snice-progress-ring.js +1 -1
  114. package/dist/cdn/qr-code/snice-qr-code.js +1 -1
  115. package/dist/cdn/qr-reader/snice-qr-reader.js +1 -1
  116. package/dist/cdn/radio/snice-radio.js +1 -1
  117. package/dist/cdn/range-slider/snice-range-slider.js +1 -1
  118. package/dist/cdn/rating/snice-rating.js +1 -1
  119. package/dist/cdn/receipt/snice-receipt.js +1 -1
  120. package/dist/cdn/recipe/snice-recipe.js +1 -1
  121. package/dist/cdn/runtime/README.md +2 -2
  122. package/dist/cdn/runtime/snice-runtime.esm.js +28 -8
  123. package/dist/cdn/runtime/snice-runtime.esm.js.map +1 -1
  124. package/dist/cdn/runtime/snice-runtime.esm.min.js +1 -1
  125. package/dist/cdn/runtime/snice-runtime.esm.min.js.map +1 -1
  126. package/dist/cdn/runtime/snice-runtime.js +28 -8
  127. package/dist/cdn/runtime/snice-runtime.js.map +1 -1
  128. package/dist/cdn/runtime/snice-runtime.min.js +1 -1
  129. package/dist/cdn/runtime/snice-runtime.min.js.map +1 -1
  130. package/dist/cdn/sankey/snice-sankey.js +1 -1
  131. package/dist/cdn/segmented-control/snice-segmented-control.js +1 -1
  132. package/dist/cdn/select/snice-select.js +1 -1
  133. package/dist/cdn/skeleton/snice-skeleton.js +1 -1
  134. package/dist/cdn/slider/snice-slider.js +1 -1
  135. package/dist/cdn/sortable/snice-sortable.js +1 -1
  136. package/dist/cdn/sparkline/snice-sparkline.js +1 -1
  137. package/dist/cdn/spinner/snice-spinner.js +1 -1
  138. package/dist/cdn/split-button/snice-split-button.js +1 -1
  139. package/dist/cdn/split-pane/snice-split-pane.js +1 -1
  140. package/dist/cdn/spotlight/snice-spotlight.js +1 -1
  141. package/dist/cdn/stat-group/snice-stat-group.js +1 -1
  142. package/dist/cdn/step-input/snice-step-input.js +1 -1
  143. package/dist/cdn/stepper/snice-stepper.js +1 -1
  144. package/dist/cdn/switch/snice-switch.js +1 -1
  145. package/dist/cdn/table/snice-table.esm.js +1 -1
  146. package/dist/cdn/table/snice-table.js +1 -1
  147. package/dist/cdn/tabs/snice-tabs.js +1 -1
  148. package/dist/cdn/tag/snice-tag.js +1 -1
  149. package/dist/cdn/tag-input/snice-tag-input.js +1 -1
  150. package/dist/cdn/terminal/snice-terminal.js +1 -1
  151. package/dist/cdn/testimonial/snice-testimonial.js +1 -1
  152. package/dist/cdn/textarea/snice-textarea.js +1 -1
  153. package/dist/cdn/time-picker/snice-time-picker.js +1 -1
  154. package/dist/cdn/time-range-picker/snice-time-range-picker.js +1 -1
  155. package/dist/cdn/timeline/snice-timeline.js +1 -1
  156. package/dist/cdn/timer/snice-timer.js +1 -1
  157. package/dist/cdn/toast/snice-toast.js +1 -1
  158. package/dist/cdn/tooltip/snice-tooltip.js +1 -1
  159. package/dist/cdn/tree/snice-tree.js +1 -1
  160. package/dist/cdn/treemap/snice-treemap.js +1 -1
  161. package/dist/cdn/user-card/snice-user-card.js +1 -1
  162. package/dist/cdn/video-player/snice-video-player.js +1 -1
  163. package/dist/cdn/virtual-scroller/snice-virtual-scroller.js +1 -1
  164. package/dist/cdn/waterfall/snice-waterfall.js +1 -1
  165. package/dist/cdn/weather/snice-weather.js +1 -1
  166. package/dist/cdn/work-order/snice-work-order.js +1 -1
  167. package/dist/index.cjs +25 -5
  168. package/dist/index.cjs.map +1 -1
  169. package/dist/index.esm.js +25 -5
  170. package/dist/index.esm.js.map +1 -1
  171. package/dist/index.iife.js +25 -5
  172. package/dist/index.iife.js.map +1 -1
  173. package/dist/react/SniceProvider.js +1 -1
  174. package/dist/react/SniceRouter.d.ts +2 -0
  175. package/dist/react/SniceRouter.js +3 -2
  176. package/dist/react/SniceRouter.js.map +1 -1
  177. package/dist/react/index.js +1 -1
  178. package/dist/react/matchRoute.d.ts +4 -1
  179. package/dist/react/matchRoute.js +13 -3
  180. package/dist/react/matchRoute.js.map +1 -1
  181. package/dist/react/useRequestHandler.js +1 -1
  182. package/dist/symbols.cjs +1 -1
  183. package/dist/symbols.esm.js +1 -1
  184. package/dist/transitions.cjs +1 -1
  185. package/dist/transitions.esm.js +1 -1
  186. package/dist/types/page-options.d.ts +15 -1
  187. package/dist/types/router-instance.d.ts +2 -1
  188. package/docs/ai/README.md +6 -4
  189. package/docs/ai/api.md +1 -1
  190. package/docs/ai/architecture.md +21 -8
  191. package/docs/ai/cli.md +4 -1
  192. package/docs/ai/controllers.md +11 -1
  193. package/docs/ai/decorators.md +1 -1
  194. package/docs/ai/react-integration.md +1 -0
  195. package/docs/ai/routing.md +25 -3
  196. package/docs/cli.md +4 -2
  197. package/docs/controllers.md +16 -4
  198. package/docs/react-integration.md +1 -0
  199. package/docs/routing.md +29 -2
  200. package/package.json +1 -1
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * snice v7.2.0
2
+ * snice v7.3.0
3
3
  * A decorator-driven web component library with routing, controllers, daemons, and 130+ UI components. For better coding-agent results, run npx snice init-ai.
4
4
  * (c) 2024
5
5
  * Released under the MIT License.
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * snice v7.2.0
2
+ * snice v7.3.0
3
3
  * A decorator-driven web component library with routing, controllers, daemons, and 130+ UI components. For better coding-agent results, run npx snice init-ai.
4
4
  * (c) 2024
5
5
  * Released under the MIT License.
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * snice v7.2.0
2
+ * snice v7.3.0
3
3
  * A decorator-driven web component library with routing, controllers, daemons, and 130+ UI components. For better coding-agent results, run npx snice init-ai.
4
4
  * (c) 2024
5
5
  * Released under the MIT License.
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * snice v7.2.0
2
+ * snice v7.3.0
3
3
  * A decorator-driven web component library with routing, controllers, daemons, and 130+ UI components. For better coding-agent results, run npx snice init-ai.
4
4
  * (c) 2024
5
5
  * Released under the MIT License.
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * snice v7.2.0
2
+ * snice v7.3.0
3
3
  * A decorator-driven web component library with routing, controllers, daemons, and 130+ UI components. For better coding-agent results, run npx snice init-ai.
4
4
  * (c) 2024
5
5
  * Released under the MIT License.
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * snice v7.2.0
2
+ * snice v7.3.0
3
3
  * A decorator-driven web component library with routing, controllers, daemons, and 130+ UI components. For better coding-agent results, run npx snice init-ai.
4
4
  * (c) 2024
5
5
  * Released under the MIT License.
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * snice v7.2.0
2
+ * snice v7.3.0
3
3
  * A decorator-driven web component library with routing, controllers, daemons, and 130+ UI components. For better coding-agent results, run npx snice init-ai.
4
4
  * (c) 2024
5
5
  * Released under the MIT License.
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * snice v7.2.0
2
+ * snice v7.3.0
3
3
  * A decorator-driven web component library with routing, controllers, daemons, and 130+ UI components. For better coding-agent results, run npx snice init-ai.
4
4
  * (c) 2024
5
5
  * Released under the MIT License.
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * snice v7.2.0
2
+ * snice v7.3.0
3
3
  * A decorator-driven web component library with routing, controllers, daemons, and 130+ UI components. For better coding-agent results, run npx snice init-ai.
4
4
  * (c) 2024
5
5
  * Released under the MIT License.
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * snice v7.2.0
2
+ * snice v7.3.0
3
3
  * A decorator-driven web component library with routing, controllers, daemons, and 130+ UI components. For better coding-agent results, run npx snice init-ai.
4
4
  * (c) 2024
5
5
  * Released under the MIT License.
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * snice v7.2.0
2
+ * snice v7.3.0
3
3
  * A decorator-driven web component library with routing, controllers, daemons, and 130+ UI components. For better coding-agent results, run npx snice init-ai.
4
4
  * (c) 2024
5
5
  * Released under the MIT License.
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * snice v7.2.0
2
+ * snice v7.3.0
3
3
  * A decorator-driven web component library with routing, controllers, daemons, and 130+ UI components. For better coding-agent results, run npx snice init-ai.
4
4
  * (c) 2024
5
5
  * Released under the MIT License.
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * snice v7.2.0
2
+ * snice v7.3.0
3
3
  * A decorator-driven web component library with routing, controllers, daemons, and 130+ UI components. For better coding-agent results, run npx snice init-ai.
4
4
  * (c) 2024
5
5
  * Released under the MIT License.
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * snice v7.2.0
2
+ * snice v7.3.0
3
3
  * A decorator-driven web component library with routing, controllers, daemons, and 130+ UI components. For better coding-agent results, run npx snice init-ai.
4
4
  * (c) 2024
5
5
  * Released under the MIT License.
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * snice v7.2.0
2
+ * snice v7.3.0
3
3
  * A decorator-driven web component library with routing, controllers, daemons, and 130+ UI components. For better coding-agent results, run npx snice init-ai.
4
4
  * (c) 2024
5
5
  * Released under the MIT License.
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * snice v7.2.0
2
+ * snice v7.3.0
3
3
  * A decorator-driven web component library with routing, controllers, daemons, and 130+ UI components. For better coding-agent results, run npx snice init-ai.
4
4
  * (c) 2024
5
5
  * Released under the MIT License.
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * snice v7.2.0
2
+ * snice v7.3.0
3
3
  * A decorator-driven web component library with routing, controllers, daemons, and 130+ UI components. For better coding-agent results, run npx snice init-ai.
4
4
  * (c) 2024
5
5
  * Released under the MIT License.
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * snice v7.2.0
2
+ * snice v7.3.0
3
3
  * A decorator-driven web component library with routing, controllers, daemons, and 130+ UI components. For better coding-agent results, run npx snice init-ai.
4
4
  * (c) 2024
5
5
  * Released under the MIT License.
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * snice v7.2.0
2
+ * snice v7.3.0
3
3
  * A decorator-driven web component library with routing, controllers, daemons, and 130+ UI components. For better coding-agent results, run npx snice init-ai.
4
4
  * (c) 2024
5
5
  * Released under the MIT License.
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * snice v7.2.0
2
+ * snice v7.3.0
3
3
  * A decorator-driven web component library with routing, controllers, daemons, and 130+ UI components. For better coding-agent results, run npx snice init-ai.
4
4
  * (c) 2024
5
5
  * Released under the MIT License.
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * snice v7.2.0
2
+ * snice v7.3.0
3
3
  * A decorator-driven web component library with routing, controllers, daemons, and 130+ UI components. For better coding-agent results, run npx snice init-ai.
4
4
  * (c) 2024
5
5
  * Released under the MIT License.
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * snice v7.2.0
2
+ * snice v7.3.0
3
3
  * A decorator-driven web component library with routing, controllers, daemons, and 130+ UI components. For better coding-agent results, run npx snice init-ai.
4
4
  * (c) 2024
5
5
  * Released under the MIT License.
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * snice v7.2.0
2
+ * snice v7.3.0
3
3
  * A decorator-driven web component library with routing, controllers, daemons, and 130+ UI components. For better coding-agent results, run npx snice init-ai.
4
4
  * (c) 2024
5
5
  * Released under the MIT License.
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * snice v7.2.0
2
+ * snice v7.3.0
3
3
  * A decorator-driven web component library with routing, controllers, daemons, and 130+ UI components. For better coding-agent results, run npx snice init-ai.
4
4
  * (c) 2024
5
5
  * Released under the MIT License.
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * snice v7.2.0
2
+ * snice v7.3.0
3
3
  * A decorator-driven web component library with routing, controllers, daemons, and 130+ UI components. For better coding-agent results, run npx snice init-ai.
4
4
  * (c) 2024
5
5
  * Released under the MIT License.
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * snice v7.2.0
2
+ * snice v7.3.0
3
3
  * A decorator-driven web component library with routing, controllers, daemons, and 130+ UI components. For better coding-agent results, run npx snice init-ai.
4
4
  * (c) 2024
5
5
  * Released under the MIT License.
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * snice v7.2.0
2
+ * snice v7.3.0
3
3
  * A decorator-driven web component library with routing, controllers, daemons, and 130+ UI components. For better coding-agent results, run npx snice init-ai.
4
4
  * (c) 2024
5
5
  * Released under the MIT License.
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * snice v7.2.0
2
+ * snice v7.3.0
3
3
  * A decorator-driven web component library with routing, controllers, daemons, and 130+ UI components. For better coding-agent results, run npx snice init-ai.
4
4
  * (c) 2024
5
5
  * Released under the MIT License.
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * snice v7.2.0
2
+ * snice v7.3.0
3
3
  * A decorator-driven web component library with routing, controllers, daemons, and 130+ UI components. For better coding-agent results, run npx snice init-ai.
4
4
  * (c) 2024
5
5
  * Released under the MIT License.
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * snice v7.2.0
2
+ * snice v7.3.0
3
3
  * A decorator-driven web component library with routing, controllers, daemons, and 130+ UI components. For better coding-agent results, run npx snice init-ai.
4
4
  * (c) 2024
5
5
  * Released under the MIT License.
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * snice v7.2.0
2
+ * snice v7.3.0
3
3
  * A decorator-driven web component library with routing, controllers, daemons, and 130+ UI components. For better coding-agent results, run npx snice init-ai.
4
4
  * (c) 2024
5
5
  * Released under the MIT License.
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * snice v7.2.0
2
+ * snice v7.3.0
3
3
  * A decorator-driven web component library with routing, controllers, daemons, and 130+ UI components. For better coding-agent results, run npx snice init-ai.
4
4
  * (c) 2024
5
5
  * Released under the MIT License.
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * snice v7.2.0
2
+ * snice v7.3.0
3
3
  * A decorator-driven web component library with routing, controllers, daemons, and 130+ UI components. For better coding-agent results, run npx snice init-ai.
4
4
  * (c) 2024
5
5
  * Released under the MIT License.
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * snice v7.2.0
2
+ * snice v7.3.0
3
3
  * A decorator-driven web component library with routing, controllers, daemons, and 130+ UI components. For better coding-agent results, run npx snice init-ai.
4
4
  * (c) 2024
5
5
  * Released under the MIT License.
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * snice v7.2.0
2
+ * snice v7.3.0
3
3
  * A decorator-driven web component library with routing, controllers, daemons, and 130+ UI components. For better coding-agent results, run npx snice init-ai.
4
4
  * (c) 2024
5
5
  * Released under the MIT License.
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * snice v7.2.0
2
+ * snice v7.3.0
3
3
  * A decorator-driven web component library with routing, controllers, daemons, and 130+ UI components. For better coding-agent results, run npx snice init-ai.
4
4
  * (c) 2024
5
5
  * Released under the MIT License.
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * snice v7.2.0
2
+ * snice v7.3.0
3
3
  * A decorator-driven web component library with routing, controllers, daemons, and 130+ UI components. For better coding-agent results, run npx snice init-ai.
4
4
  * (c) 2024
5
5
  * Released under the MIT License.
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * snice v7.2.0
2
+ * snice v7.3.0
3
3
  * A decorator-driven web component library with routing, controllers, daemons, and 130+ UI components. For better coding-agent results, run npx snice init-ai.
4
4
  * (c) 2024
5
5
  * Released under the MIT License.
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * snice v7.2.0
2
+ * snice v7.3.0
3
3
  * A decorator-driven web component library with routing, controllers, daemons, and 130+ UI components. For better coding-agent results, run npx snice init-ai.
4
4
  * (c) 2024
5
5
  * Released under the MIT License.
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * snice v7.2.0
2
+ * snice v7.3.0
3
3
  * A decorator-driven web component library with routing, controllers, daemons, and 130+ UI components. For better coding-agent results, run npx snice init-ai.
4
4
  * (c) 2024
5
5
  * Released under the MIT License.
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * snice v7.2.0
2
+ * snice v7.3.0
3
3
  * A decorator-driven web component library with routing, controllers, daemons, and 130+ UI components. For better coding-agent results, run npx snice init-ai.
4
4
  * (c) 2024
5
5
  * Released under the MIT License.
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * snice v7.2.0
2
+ * snice v7.3.0
3
3
  * A decorator-driven web component library with routing, controllers, daemons, and 130+ UI components. For better coding-agent results, run npx snice init-ai.
4
4
  * (c) 2024
5
5
  * Released under the MIT License.
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * snice v7.2.0
2
+ * snice v7.3.0
3
3
  * A decorator-driven web component library with routing, controllers, daemons, and 130+ UI components. For better coding-agent results, run npx snice init-ai.
4
4
  * (c) 2024
5
5
  * Released under the MIT License.
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * snice v7.2.0
2
+ * snice v7.3.0
3
3
  * A decorator-driven web component library with routing, controllers, daemons, and 130+ UI components. For better coding-agent results, run npx snice init-ai.
4
4
  * (c) 2024
5
5
  * Released under the MIT License.
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * snice v7.2.0
2
+ * snice v7.3.0
3
3
  * A decorator-driven web component library with routing, controllers, daemons, and 130+ UI components. For better coding-agent results, run npx snice init-ai.
4
4
  * (c) 2024
5
5
  * Released under the MIT License.
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * snice v7.2.0
2
+ * snice v7.3.0
3
3
  * A decorator-driven web component library with routing, controllers, daemons, and 130+ UI components. For better coding-agent results, run npx snice init-ai.
4
4
  * (c) 2024
5
5
  * Released under the MIT License.
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * snice v7.2.0
2
+ * snice v7.3.0
3
3
  * A decorator-driven web component library with routing, controllers, daemons, and 130+ UI components. For better coding-agent results, run npx snice init-ai.
4
4
  * (c) 2024
5
5
  * Released under the MIT License.
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * snice v7.2.0
2
+ * snice v7.3.0
3
3
  * A decorator-driven web component library with routing, controllers, daemons, and 130+ UI components. For better coding-agent results, run npx snice init-ai.
4
4
  * (c) 2024
5
5
  * Released under the MIT License.
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * snice v7.2.0
2
+ * snice v7.3.0
3
3
  * A decorator-driven web component library with routing, controllers, daemons, and 130+ UI components. For better coding-agent results, run npx snice init-ai.
4
4
  * (c) 2024
5
5
  * Released under the MIT License.
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * snice v7.2.0
2
+ * snice v7.3.0
3
3
  * A decorator-driven web component library with routing, controllers, daemons, and 130+ UI components. For better coding-agent results, run npx snice init-ai.
4
4
  * (c) 2024
5
5
  * Released under the MIT License.
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * snice v7.2.0
2
+ * snice v7.3.0
3
3
  * A decorator-driven web component library with routing, controllers, daemons, and 130+ UI components. For better coding-agent results, run npx snice init-ai.
4
4
  * (c) 2024
5
5
  * Released under the MIT License.
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * snice v7.2.0
2
+ * snice v7.3.0
3
3
  * A decorator-driven web component library with routing, controllers, daemons, and 130+ UI components. For better coding-agent results, run npx snice init-ai.
4
4
  * (c) 2024
5
5
  * Released under the MIT License.
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * snice v7.2.0
2
+ * snice v7.3.0
3
3
  * A decorator-driven web component library with routing, controllers, daemons, and 130+ UI components. For better coding-agent results, run npx snice init-ai.
4
4
  * (c) 2024
5
5
  * Released under the MIT License.
@@ -17,8 +17,8 @@ Load the runtime once, then load any CDN components:
17
17
  ```
18
18
 
19
19
  ## Size
20
- - Minified: 109.0 KB
21
- - Gzipped: 31.8 KB
20
+ - Minified: 109.2 KB
21
+ - Gzipped: 31.9 KB
22
22
 
23
23
  ## Documentation
24
24
  https://snice.dev
@@ -1,11 +1,11 @@
1
1
  /*!
2
- * snice v7.2.0
2
+ * snice v7.3.0
3
3
  * A decorator-driven web component library with routing, controllers, daemons, and 130+ UI components. For better coding-agent results, run npx snice init-ai.
4
4
  * (c) 2024
5
5
  * Released under the MIT License.
6
6
  */
7
7
  /*!
8
- * snice v7.1.1
8
+ * snice v7.2.0
9
9
  * A decorator-driven web component library with routing, controllers, daemons, and 130+ UI components. For better coding-agent results, run npx snice init-ai.
10
10
  * (c) 2024
11
11
  * Released under the MIT License.
@@ -8686,6 +8686,7 @@ function Router(options) {
8686
8686
  const win = options.window ?? window;
8687
8687
  const doc = options.document ?? document;
8688
8688
  const routes = [];
8689
+ let nextRegistrationOrder = 0;
8689
8690
  let is_sorted = false;
8690
8691
  let placards = []; // Store collected placards
8691
8692
  let _404; // the 404 page
@@ -8776,7 +8777,11 @@ function Router(options) {
8776
8777
  win.customElements.define(pageOptions.tag, constructor);
8777
8778
  }
8778
8779
  // Register the routes with guards, layout, and placard
8779
- pageOptions.routes.forEach(route => register(route, pageOptions.tag, pageOptions.transition, pageOptions.guards, pageOptions.layout, pageOptions.placard));
8780
+ pageOptions.routes.forEach(route => {
8781
+ const path = typeof route === 'string' ? route : route.path;
8782
+ const order = typeof route === 'string' ? undefined : route.order;
8783
+ register(path, pageOptions.tag, pageOptions.transition, pageOptions.guards, pageOptions.layout, pageOptions.placard, order);
8784
+ });
8780
8785
  return constructor;
8781
8786
  };
8782
8787
  }
@@ -8784,11 +8789,24 @@ function Router(options) {
8784
8789
  * Registers a new route with the router.
8785
8790
  * @param {string} route - The route path.
8786
8791
  * @param {string} tag - The custom element tag associated with the route.
8792
+ * @param {number} order - Optional lower-first tie-break after specificity.
8787
8793
  * @example
8788
8794
  * register('/custom-route', 'custom-element');
8789
8795
  */
8790
- function register(route, tag, transition, guards, layout, placard) {
8791
- routes.push({ route: new Route(route), tag, transition, guards, layout, placard });
8796
+ function register(route, tag, transition, guards, layout, placard, order = 0) {
8797
+ if (!Number.isFinite(order)) {
8798
+ throw new TypeError(`Route order for "${route}" must be a finite number.`);
8799
+ }
8800
+ routes.push({
8801
+ route: new Route(route),
8802
+ tag,
8803
+ transition,
8804
+ guards,
8805
+ layout,
8806
+ placard,
8807
+ order,
8808
+ registrationOrder: nextRegistrationOrder++
8809
+ });
8792
8810
  is_sorted = false;
8793
8811
  switch (route) {
8794
8812
  case '/404':
@@ -8849,7 +8867,9 @@ function Router(options) {
8849
8867
  ensureContextProvider(target);
8850
8868
  const needsSorting = !is_sorted;
8851
8869
  if (needsSorting) {
8852
- routes.sort((a, b) => routeSpecificity(b.route.spec) - routeSpecificity(a.route.spec));
8870
+ routes.sort((a, b) => routeSpecificity(b.route.spec) - routeSpecificity(a.route.spec)
8871
+ || a.order - b.order
8872
+ || a.registrationOrder - b.registrationOrder);
8853
8873
  is_sorted = true;
8854
8874
  }
8855
8875
  // Collect placards from registered routes
@@ -9570,7 +9590,7 @@ if (typeof document !== 'undefined') {
9570
9590
  }
9571
9591
 
9572
9592
  /*!
9573
- * snice v7.1.1
9593
+ * snice v7.2.0
9574
9594
  * A decorator-driven web component library with routing, controllers, daemons, and 130+ UI components. For better coding-agent results, run npx snice init-ai.
9575
9595
  * (c) 2024
9576
9596
  * Released under the MIT License.
@@ -9592,7 +9612,7 @@ if (!globalThis.snice) {
9592
9612
  globalThis.snice.pendingControllerAttachments ??= new Map();
9593
9613
 
9594
9614
  /*!
9595
- * snice v7.1.1
9615
+ * snice v7.2.0
9596
9616
  * A decorator-driven web component library with routing, controllers, daemons, and 130+ UI components. For better coding-agent results, run npx snice init-ai.
9597
9617
  * (c) 2024
9598
9618
  * Released under the MIT License.