@lssm/lib.ui-kit 1.11.1 → 1.41.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 (244) hide show
  1. package/README.md +5 -0
  2. package/dist/-core/src/utils.js +10 -0
  3. package/dist/_virtual/rolldown_runtime.js +33 -0
  4. package/dist/node_modules/@hookform/resolvers/dist/resolvers.js +34 -0
  5. package/dist/node_modules/@hookform/resolvers/zod/dist/zod.js +118 -0
  6. package/dist/node_modules/@swc/helpers/cjs/_interop_require_default.js +14 -0
  7. package/dist/node_modules/@swc/helpers/cjs/_interop_require_wildcard.js +35 -0
  8. package/dist/node_modules/lucide-react/dist/esm/Icon.js +25 -0
  9. package/dist/node_modules/lucide-react/dist/esm/createLucideIcon.js +24 -0
  10. package/dist/node_modules/lucide-react/dist/esm/defaultAttributes.js +21 -0
  11. package/dist/node_modules/lucide-react/dist/esm/icons/chevron-down.js +17 -0
  12. package/dist/node_modules/lucide-react/dist/esm/icons/chevron-left.js +17 -0
  13. package/dist/node_modules/lucide-react/dist/esm/icons/chevron-right.js +17 -0
  14. package/dist/node_modules/lucide-react/dist/esm/icons/chevron-up.js +17 -0
  15. package/dist/node_modules/lucide-react/dist/esm/icons/chevrons-left.js +20 -0
  16. package/dist/node_modules/lucide-react/dist/esm/icons/chevrons-right.js +20 -0
  17. package/dist/node_modules/lucide-react/dist/esm/icons/ellipsis.js +33 -0
  18. package/dist/node_modules/lucide-react/dist/esm/icons/funnel.js +17 -0
  19. package/dist/node_modules/lucide-react/dist/esm/icons/house.js +20 -0
  20. package/dist/node_modules/lucide-react/dist/esm/icons/loader-circle.js +17 -0
  21. package/dist/node_modules/lucide-react/dist/esm/icons/plus.js +20 -0
  22. package/dist/node_modules/lucide-react/dist/esm/icons/refresh-ccw.js +31 -0
  23. package/dist/node_modules/lucide-react/dist/esm/icons/refresh-cw.js +31 -0
  24. package/dist/node_modules/lucide-react/dist/esm/icons/search.js +22 -0
  25. package/dist/node_modules/lucide-react/dist/esm/icons/triangle-alert.js +27 -0
  26. package/dist/node_modules/lucide-react/dist/esm/icons/x.js +20 -0
  27. package/dist/node_modules/lucide-react/dist/esm/shared/src/utils.js +22 -0
  28. package/dist/node_modules/next/dist/client/add-base-path.js +30 -0
  29. package/dist/node_modules/next/dist/client/add-locale.js +29 -0
  30. package/dist/node_modules/next/dist/client/detect-domain-locale.js +26 -0
  31. package/dist/node_modules/next/dist/client/get-domain-locale.js +41 -0
  32. package/dist/node_modules/next/dist/client/has-base-path.js +28 -0
  33. package/dist/node_modules/next/dist/client/link.js +311 -0
  34. package/dist/node_modules/next/dist/client/normalize-locale-path.js +30 -0
  35. package/dist/node_modules/next/dist/client/normalize-trailing-slash.js +34 -0
  36. package/dist/node_modules/next/dist/client/request-idle-callback.js +44 -0
  37. package/dist/node_modules/next/dist/client/resolve-href.js +86 -0
  38. package/dist/node_modules/next/dist/client/use-intersection.js +104 -0
  39. package/dist/node_modules/next/dist/client/use-merged-ref.js +56 -0
  40. package/dist/node_modules/next/dist/compiled/path-to-regexp/index.js +372 -0
  41. package/dist/node_modules/next/dist/lib/constants.js +316 -0
  42. package/dist/node_modules/next/dist/lib/route-pattern-normalizer.js +69 -0
  43. package/dist/node_modules/next/dist/shared/lib/escape-regexp.js +23 -0
  44. package/dist/node_modules/next/dist/shared/lib/i18n/detect-domain-locale.js +22 -0
  45. package/dist/node_modules/next/dist/shared/lib/i18n/normalize-locale-path.js +42 -0
  46. package/dist/node_modules/next/dist/shared/lib/invariant-error.js +23 -0
  47. package/dist/node_modules/next/dist/shared/lib/page-path/ensure-leading-slash.js +23 -0
  48. package/dist/node_modules/next/dist/shared/lib/router/utils/add-locale.js +30 -0
  49. package/dist/node_modules/next/dist/shared/lib/router/utils/add-path-prefix.js +24 -0
  50. package/dist/node_modules/next/dist/shared/lib/router/utils/app-paths.js +41 -0
  51. package/dist/node_modules/next/dist/shared/lib/router/utils/format-url.js +78 -0
  52. package/dist/node_modules/next/dist/shared/lib/router/utils/get-dynamic-param.js +151 -0
  53. package/dist/node_modules/next/dist/shared/lib/router/utils/get-segment-param.js +77 -0
  54. package/dist/node_modules/next/dist/shared/lib/router/utils/index.js +32 -0
  55. package/dist/node_modules/next/dist/shared/lib/router/utils/interception-routes.js +92 -0
  56. package/dist/node_modules/next/dist/shared/lib/router/utils/interpolate-as.js +41 -0
  57. package/dist/node_modules/next/dist/shared/lib/router/utils/is-dynamic.js +26 -0
  58. package/dist/node_modules/next/dist/shared/lib/router/utils/is-local-url.js +31 -0
  59. package/dist/node_modules/next/dist/shared/lib/router/utils/omit.js +24 -0
  60. package/dist/node_modules/next/dist/shared/lib/router/utils/parse-loader-tree.js +33 -0
  61. package/dist/node_modules/next/dist/shared/lib/router/utils/parse-path.js +36 -0
  62. package/dist/node_modules/next/dist/shared/lib/router/utils/path-has-prefix.js +24 -0
  63. package/dist/node_modules/next/dist/shared/lib/router/utils/querystring.js +56 -0
  64. package/dist/node_modules/next/dist/shared/lib/router/utils/remove-trailing-slash.js +26 -0
  65. package/dist/node_modules/next/dist/shared/lib/router/utils/route-match-utils.js +94 -0
  66. package/dist/node_modules/next/dist/shared/lib/router/utils/route-matcher.js +46 -0
  67. package/dist/node_modules/next/dist/shared/lib/router/utils/route-regex.js +203 -0
  68. package/dist/node_modules/next/dist/shared/lib/router/utils/sorted-routes.js +167 -0
  69. package/dist/node_modules/next/dist/shared/lib/router-context.shared-runtime.js +20 -0
  70. package/dist/node_modules/next/dist/shared/lib/segment.js +80 -0
  71. package/dist/node_modules/next/dist/shared/lib/utils/error-once.js +25 -0
  72. package/dist/node_modules/next/dist/shared/lib/utils.js +172 -0
  73. package/dist/node_modules/next/link.js +12 -0
  74. package/dist/node_modules/react-hook-form/dist/index.esm.js +2074 -0
  75. package/dist/node_modules/zod/v4/classic/errors.js +29 -0
  76. package/dist/node_modules/zod/v4/classic/iso.js +37 -0
  77. package/dist/node_modules/zod/v4/classic/parse.js +19 -0
  78. package/dist/node_modules/zod/v4/classic/schemas.js +418 -0
  79. package/dist/node_modules/zod/v4/core/api.js +404 -0
  80. package/dist/node_modules/zod/v4/core/checks.js +225 -0
  81. package/dist/node_modules/zod/v4/core/core.js +61 -0
  82. package/dist/node_modules/zod/v4/core/errors.js +62 -0
  83. package/dist/node_modules/zod/v4/core/json-schema-processors.js +148 -0
  84. package/dist/node_modules/zod/v4/core/parse.js +109 -0
  85. package/dist/node_modules/zod/v4/core/regexes.js +57 -0
  86. package/dist/node_modules/zod/v4/core/registries.js +52 -0
  87. package/dist/node_modules/zod/v4/core/schemas.js +744 -0
  88. package/dist/node_modules/zod/v4/core/to-json-schema.js +260 -0
  89. package/dist/node_modules/zod/v4/core/util.js +155 -0
  90. package/dist/node_modules/zod/v4/core/versions.js +9 -0
  91. package/dist/tsconfig.tsbuildinfo +1 -1
  92. package/dist/ui/accordion.js +1 -1
  93. package/dist/ui/alert-dialog.js +1 -1
  94. package/dist/ui/alert.js +1 -1
  95. package/dist/ui/atoms/LoadingSpinner/LoadingSpinner.js +3 -3
  96. package/dist/ui/atoms/Pagination/Pagination.js +4 -1
  97. package/dist/ui/atoms/SearchInput/SearchInput.js +2 -1
  98. package/dist/ui/avatar.js +1 -1
  99. package/dist/ui/badge.js +1 -1
  100. package/dist/ui/breadcrumb.js +4 -3
  101. package/dist/ui/button.js +1 -1
  102. package/dist/ui/card.js +1 -1
  103. package/dist/ui/checkbox.js +1 -1
  104. package/dist/ui/context-menu.js +1 -1
  105. package/dist/ui/date-picker.js +1 -1
  106. package/dist/ui/date-range-picker.js +1 -1
  107. package/dist/ui/dialog.js +1 -1
  108. package/dist/ui/dropdown-menu.js +1 -1
  109. package/dist/ui/empty-state.js +1 -1
  110. package/dist/ui/empty.js +1 -1
  111. package/dist/ui/fab.js +1 -1
  112. package/dist/ui/field.js +1 -1
  113. package/dist/ui/form.js +1 -1
  114. package/dist/ui/hover-card.js +1 -1
  115. package/dist/ui/input.js +1 -1
  116. package/dist/ui/label.js +1 -1
  117. package/dist/ui/link.js +1 -1
  118. package/dist/ui/marketing/Hero.js +1 -1
  119. package/dist/ui/marketing/PricingTable.js +1 -1
  120. package/dist/ui/menubar.js +1 -1
  121. package/dist/ui/molecules/SearchAndFilter/SearchAndFilter.js +4 -2
  122. package/dist/ui/nativewind-env.d.js +0 -0
  123. package/dist/ui/navigation-menu.js +1 -1
  124. package/dist/ui/organisms/ErrorBoundary/ErrorBoundary.js +5 -3
  125. package/dist/ui/organisms/ListPage/ListPage.js +12 -7
  126. package/dist/ui/page-header.js +1 -1
  127. package/dist/ui/popover.js +1 -1
  128. package/dist/ui/progress.js +1 -1
  129. package/dist/ui/radio-group.js +1 -1
  130. package/dist/ui/select.js +1 -1
  131. package/dist/ui/separator.js +1 -1
  132. package/dist/ui/skeleton.js +1 -1
  133. package/dist/ui/stack.js +1 -1
  134. package/dist/ui/stepper.js +1 -1
  135. package/dist/ui/switch.js +1 -1
  136. package/dist/ui/table.js +1 -1
  137. package/dist/ui/tabs.js +1 -1
  138. package/dist/ui/text.js +1 -1
  139. package/dist/ui/textarea.js +1 -1
  140. package/dist/ui/time-picker.js +1 -1
  141. package/dist/ui/toggle-group.js +1 -1
  142. package/dist/ui/toggle.js +1 -1
  143. package/dist/ui/tooltip.js +1 -1
  144. package/dist/ui/typography.js +1 -1
  145. package/package.json +204 -114
  146. package/dist/index.d.ts +0 -4
  147. package/dist/ui/accordion.d.ts +0 -35
  148. package/dist/ui/alert-dialog.d.ts +0 -71
  149. package/dist/ui/alert.d.ts +0 -36
  150. package/dist/ui/aspect-ratio.d.ts +0 -11
  151. package/dist/ui/atoms/FilterSelect/FilterSelect.d.ts +0 -7
  152. package/dist/ui/atoms/FilterSelect/index.d.ts +0 -3
  153. package/dist/ui/atoms/FilterSelect/types.d.ts +0 -18
  154. package/dist/ui/atoms/LoadingSpinner/LoadingSpinner.d.ts +0 -22
  155. package/dist/ui/atoms/LoadingSpinner/index.d.ts +0 -2
  156. package/dist/ui/atoms/Pagination/Pagination.d.ts +0 -7
  157. package/dist/ui/atoms/Pagination/index.d.ts +0 -3
  158. package/dist/ui/atoms/Pagination/types.d.ts +0 -15
  159. package/dist/ui/atoms/SearchInput/SearchInput.d.ts +0 -7
  160. package/dist/ui/atoms/SearchInput/index.d.ts +0 -3
  161. package/dist/ui/atoms/SearchInput/types.d.ts +0 -12
  162. package/dist/ui/avatar.d.ts +0 -27
  163. package/dist/ui/badge.d.ts +0 -21
  164. package/dist/ui/breadcrumb.d.ts +0 -38
  165. package/dist/ui/button.d.ts +0 -25
  166. package/dist/ui/card.d.ts +0 -43
  167. package/dist/ui/carousel.d.ts +0 -4
  168. package/dist/ui/checkbox.d.ts +0 -16
  169. package/dist/ui/collapsible.d.ts +0 -24
  170. package/dist/ui/command.d.ts +0 -4
  171. package/dist/ui/context-menu.d.ts +0 -109
  172. package/dist/ui/date-picker.d.ts +0 -23
  173. package/dist/ui/date-range-picker.d.ts +0 -30
  174. package/dist/ui/datetime-picker.d.ts +0 -27
  175. package/dist/ui/dialog.d.ts +0 -68
  176. package/dist/ui/dropdown-menu.d.ts +0 -111
  177. package/dist/ui/empty-state.d.ts +0 -28
  178. package/dist/ui/empty.d.ts +0 -36
  179. package/dist/ui/fab.d.ts +0 -35
  180. package/dist/ui/field.d.ts +0 -66
  181. package/dist/ui/form.d.ts +0 -49
  182. package/dist/ui/hover-card.d.ts +0 -29
  183. package/dist/ui/icons/Check.d.ts +0 -2
  184. package/dist/ui/icons/ChevronDown.d.ts +0 -2
  185. package/dist/ui/icons/ChevronRight.d.ts +0 -2
  186. package/dist/ui/icons/ChevronUp.d.ts +0 -2
  187. package/dist/ui/icons/CircleUser.d.ts +0 -2
  188. package/dist/ui/icons/Info.d.ts +0 -2
  189. package/dist/ui/icons/Key.d.ts +0 -2
  190. package/dist/ui/icons/MoonStar.d.ts +0 -2
  191. package/dist/ui/icons/Sun.d.ts +0 -2
  192. package/dist/ui/icons/X.d.ts +0 -2
  193. package/dist/ui/icons/iconWithClassName.d.ts +0 -6
  194. package/dist/ui/input.d.ts +0 -14
  195. package/dist/ui/label.d.ts +0 -15
  196. package/dist/ui/link.d.ts +0 -13
  197. package/dist/ui/loading-button.d.ts +0 -19
  198. package/dist/ui/loading-overlay.d.ts +0 -15
  199. package/dist/ui/loading-screen.d.ts +0 -13
  200. package/dist/ui/marketing/FeatureGrid.d.ts +0 -20
  201. package/dist/ui/marketing/Hero.d.ts +0 -27
  202. package/dist/ui/marketing/PricingTable.d.ts +0 -24
  203. package/dist/ui/marketing/index.d.ts +0 -4
  204. package/dist/ui/menubar.d.ts +0 -114
  205. package/dist/ui/molecules/Autocomplete/index.d.ts +0 -4
  206. package/dist/ui/molecules/SearchAndFilter/SearchAndFilter.d.ts +0 -7
  207. package/dist/ui/molecules/SearchAndFilter/index.d.ts +0 -3
  208. package/dist/ui/molecules/SearchAndFilter/types.d.ts +0 -24
  209. package/dist/ui/molecules/SkeletonList.d.ts +0 -15
  210. package/dist/ui/nativewind-env.d.ts +0 -1
  211. package/dist/ui/navigation-menu.d.ts +0 -67
  212. package/dist/ui/organisms/ErrorBoundary/ErrorBoundary.d.ts +0 -29
  213. package/dist/ui/organisms/ErrorBoundary/index.d.ts +0 -2
  214. package/dist/ui/organisms/ListPage/ListPage.d.ts +0 -28
  215. package/dist/ui/organisms/ListPage/index.d.ts +0 -3
  216. package/dist/ui/organisms/ListPage/types.d.ts +0 -41
  217. package/dist/ui/page-header.d.ts +0 -26
  218. package/dist/ui/password-strength.d.ts +0 -20
  219. package/dist/ui/popover.d.ts +0 -29
  220. package/dist/ui/progress.d.ts +0 -16
  221. package/dist/ui/radio-group.d.ts +0 -14
  222. package/dist/ui/select.d.ts +0 -83
  223. package/dist/ui/separator.d.ts +0 -15
  224. package/dist/ui/sheet.d.ts +0 -4
  225. package/dist/ui/sidebar.d.ts +0 -4
  226. package/dist/ui/skeleton.d.ts +0 -11
  227. package/dist/ui/stack.d.ts +0 -76
  228. package/dist/ui/stepper.d.ts +0 -22
  229. package/dist/ui/switch.d.ts +0 -14
  230. package/dist/ui/table.d.ts +0 -50
  231. package/dist/ui/tabs.d.ts +0 -32
  232. package/dist/ui/text.d.ts +0 -20
  233. package/dist/ui/textarea.d.ts +0 -9
  234. package/dist/ui/time-picker.d.ts +0 -21
  235. package/dist/ui/toggle-group.d.ts +0 -35
  236. package/dist/ui/toggle.d.ts +0 -33
  237. package/dist/ui/tooltip.d.ts +0 -31
  238. package/dist/ui/typography.d.ts +0 -64
  239. package/dist/ui/useColorScheme.d.ts +0 -11
  240. package/dist/ui/useListState.d.ts +0 -33
  241. package/dist/ui/usecases/UseCaseCard.d.ts +0 -18
  242. package/dist/ui/usecases/UserStoryCard.d.ts +0 -14
  243. package/dist/ui/usecases/index.d.ts +0 -3
  244. package/dist/ui/utils.d.ts +0 -6
@@ -0,0 +1,404 @@
1
+ import { issue, normalizeParams, slugify } from "./util.js";
2
+ import { $ZodCheck, $ZodCheckEndsWith, $ZodCheckIncludes, $ZodCheckLengthEquals, $ZodCheckLowerCase, $ZodCheckMaxLength, $ZodCheckMinLength, $ZodCheckOverwrite, $ZodCheckRegex, $ZodCheckStartsWith, $ZodCheckUpperCase } from "./checks.js";
3
+ import { globalRegistry } from "./registries.js";
4
+
5
+ //#region ../../../node_modules/zod/v4/core/api.js
6
+ function _string(Class, params) {
7
+ return new Class({
8
+ type: "string",
9
+ ...normalizeParams(params)
10
+ });
11
+ }
12
+ function _email(Class, params) {
13
+ return new Class({
14
+ type: "string",
15
+ format: "email",
16
+ check: "string_format",
17
+ abort: false,
18
+ ...normalizeParams(params)
19
+ });
20
+ }
21
+ function _guid(Class, params) {
22
+ return new Class({
23
+ type: "string",
24
+ format: "guid",
25
+ check: "string_format",
26
+ abort: false,
27
+ ...normalizeParams(params)
28
+ });
29
+ }
30
+ function _uuid(Class, params) {
31
+ return new Class({
32
+ type: "string",
33
+ format: "uuid",
34
+ check: "string_format",
35
+ abort: false,
36
+ ...normalizeParams(params)
37
+ });
38
+ }
39
+ function _uuidv4(Class, params) {
40
+ return new Class({
41
+ type: "string",
42
+ format: "uuid",
43
+ check: "string_format",
44
+ abort: false,
45
+ version: "v4",
46
+ ...normalizeParams(params)
47
+ });
48
+ }
49
+ function _uuidv6(Class, params) {
50
+ return new Class({
51
+ type: "string",
52
+ format: "uuid",
53
+ check: "string_format",
54
+ abort: false,
55
+ version: "v6",
56
+ ...normalizeParams(params)
57
+ });
58
+ }
59
+ function _uuidv7(Class, params) {
60
+ return new Class({
61
+ type: "string",
62
+ format: "uuid",
63
+ check: "string_format",
64
+ abort: false,
65
+ version: "v7",
66
+ ...normalizeParams(params)
67
+ });
68
+ }
69
+ function _url(Class, params) {
70
+ return new Class({
71
+ type: "string",
72
+ format: "url",
73
+ check: "string_format",
74
+ abort: false,
75
+ ...normalizeParams(params)
76
+ });
77
+ }
78
+ function _emoji(Class, params) {
79
+ return new Class({
80
+ type: "string",
81
+ format: "emoji",
82
+ check: "string_format",
83
+ abort: false,
84
+ ...normalizeParams(params)
85
+ });
86
+ }
87
+ function _nanoid(Class, params) {
88
+ return new Class({
89
+ type: "string",
90
+ format: "nanoid",
91
+ check: "string_format",
92
+ abort: false,
93
+ ...normalizeParams(params)
94
+ });
95
+ }
96
+ function _cuid(Class, params) {
97
+ return new Class({
98
+ type: "string",
99
+ format: "cuid",
100
+ check: "string_format",
101
+ abort: false,
102
+ ...normalizeParams(params)
103
+ });
104
+ }
105
+ function _cuid2(Class, params) {
106
+ return new Class({
107
+ type: "string",
108
+ format: "cuid2",
109
+ check: "string_format",
110
+ abort: false,
111
+ ...normalizeParams(params)
112
+ });
113
+ }
114
+ function _ulid(Class, params) {
115
+ return new Class({
116
+ type: "string",
117
+ format: "ulid",
118
+ check: "string_format",
119
+ abort: false,
120
+ ...normalizeParams(params)
121
+ });
122
+ }
123
+ function _xid(Class, params) {
124
+ return new Class({
125
+ type: "string",
126
+ format: "xid",
127
+ check: "string_format",
128
+ abort: false,
129
+ ...normalizeParams(params)
130
+ });
131
+ }
132
+ function _ksuid(Class, params) {
133
+ return new Class({
134
+ type: "string",
135
+ format: "ksuid",
136
+ check: "string_format",
137
+ abort: false,
138
+ ...normalizeParams(params)
139
+ });
140
+ }
141
+ function _ipv4(Class, params) {
142
+ return new Class({
143
+ type: "string",
144
+ format: "ipv4",
145
+ check: "string_format",
146
+ abort: false,
147
+ ...normalizeParams(params)
148
+ });
149
+ }
150
+ function _ipv6(Class, params) {
151
+ return new Class({
152
+ type: "string",
153
+ format: "ipv6",
154
+ check: "string_format",
155
+ abort: false,
156
+ ...normalizeParams(params)
157
+ });
158
+ }
159
+ function _cidrv4(Class, params) {
160
+ return new Class({
161
+ type: "string",
162
+ format: "cidrv4",
163
+ check: "string_format",
164
+ abort: false,
165
+ ...normalizeParams(params)
166
+ });
167
+ }
168
+ function _cidrv6(Class, params) {
169
+ return new Class({
170
+ type: "string",
171
+ format: "cidrv6",
172
+ check: "string_format",
173
+ abort: false,
174
+ ...normalizeParams(params)
175
+ });
176
+ }
177
+ function _base64(Class, params) {
178
+ return new Class({
179
+ type: "string",
180
+ format: "base64",
181
+ check: "string_format",
182
+ abort: false,
183
+ ...normalizeParams(params)
184
+ });
185
+ }
186
+ function _base64url(Class, params) {
187
+ return new Class({
188
+ type: "string",
189
+ format: "base64url",
190
+ check: "string_format",
191
+ abort: false,
192
+ ...normalizeParams(params)
193
+ });
194
+ }
195
+ function _e164(Class, params) {
196
+ return new Class({
197
+ type: "string",
198
+ format: "e164",
199
+ check: "string_format",
200
+ abort: false,
201
+ ...normalizeParams(params)
202
+ });
203
+ }
204
+ function _jwt(Class, params) {
205
+ return new Class({
206
+ type: "string",
207
+ format: "jwt",
208
+ check: "string_format",
209
+ abort: false,
210
+ ...normalizeParams(params)
211
+ });
212
+ }
213
+ function _isoDateTime(Class, params) {
214
+ return new Class({
215
+ type: "string",
216
+ format: "datetime",
217
+ check: "string_format",
218
+ offset: false,
219
+ local: false,
220
+ precision: null,
221
+ ...normalizeParams(params)
222
+ });
223
+ }
224
+ function _isoDate(Class, params) {
225
+ return new Class({
226
+ type: "string",
227
+ format: "date",
228
+ check: "string_format",
229
+ ...normalizeParams(params)
230
+ });
231
+ }
232
+ function _isoTime(Class, params) {
233
+ return new Class({
234
+ type: "string",
235
+ format: "time",
236
+ check: "string_format",
237
+ precision: null,
238
+ ...normalizeParams(params)
239
+ });
240
+ }
241
+ function _isoDuration(Class, params) {
242
+ return new Class({
243
+ type: "string",
244
+ format: "duration",
245
+ check: "string_format",
246
+ ...normalizeParams(params)
247
+ });
248
+ }
249
+ function _maxLength(maximum, params) {
250
+ return new $ZodCheckMaxLength({
251
+ check: "max_length",
252
+ ...normalizeParams(params),
253
+ maximum
254
+ });
255
+ }
256
+ function _minLength(minimum, params) {
257
+ return new $ZodCheckMinLength({
258
+ check: "min_length",
259
+ ...normalizeParams(params),
260
+ minimum
261
+ });
262
+ }
263
+ function _length(length, params) {
264
+ return new $ZodCheckLengthEquals({
265
+ check: "length_equals",
266
+ ...normalizeParams(params),
267
+ length
268
+ });
269
+ }
270
+ function _regex(pattern, params) {
271
+ return new $ZodCheckRegex({
272
+ check: "string_format",
273
+ format: "regex",
274
+ ...normalizeParams(params),
275
+ pattern
276
+ });
277
+ }
278
+ function _lowercase(params) {
279
+ return new $ZodCheckLowerCase({
280
+ check: "string_format",
281
+ format: "lowercase",
282
+ ...normalizeParams(params)
283
+ });
284
+ }
285
+ function _uppercase(params) {
286
+ return new $ZodCheckUpperCase({
287
+ check: "string_format",
288
+ format: "uppercase",
289
+ ...normalizeParams(params)
290
+ });
291
+ }
292
+ function _includes(includes, params) {
293
+ return new $ZodCheckIncludes({
294
+ check: "string_format",
295
+ format: "includes",
296
+ ...normalizeParams(params),
297
+ includes
298
+ });
299
+ }
300
+ function _startsWith(prefix, params) {
301
+ return new $ZodCheckStartsWith({
302
+ check: "string_format",
303
+ format: "starts_with",
304
+ ...normalizeParams(params),
305
+ prefix
306
+ });
307
+ }
308
+ function _endsWith(suffix, params) {
309
+ return new $ZodCheckEndsWith({
310
+ check: "string_format",
311
+ format: "ends_with",
312
+ ...normalizeParams(params),
313
+ suffix
314
+ });
315
+ }
316
+ function _overwrite(tx) {
317
+ return new $ZodCheckOverwrite({
318
+ check: "overwrite",
319
+ tx
320
+ });
321
+ }
322
+ function _normalize(form) {
323
+ return _overwrite((input) => input.normalize(form));
324
+ }
325
+ function _trim() {
326
+ return _overwrite((input) => input.trim());
327
+ }
328
+ function _toLowerCase() {
329
+ return _overwrite((input) => input.toLowerCase());
330
+ }
331
+ function _toUpperCase() {
332
+ return _overwrite((input) => input.toUpperCase());
333
+ }
334
+ function _slugify() {
335
+ return _overwrite((input) => slugify(input));
336
+ }
337
+ function _array(Class, element, params) {
338
+ return new Class({
339
+ type: "array",
340
+ element,
341
+ ...normalizeParams(params)
342
+ });
343
+ }
344
+ function _refine(Class, fn, _params) {
345
+ return new Class({
346
+ type: "custom",
347
+ check: "custom",
348
+ fn,
349
+ ...normalizeParams(_params)
350
+ });
351
+ }
352
+ function _superRefine(fn) {
353
+ const ch = _check((payload) => {
354
+ payload.addIssue = (issue$1) => {
355
+ if (typeof issue$1 === "string") payload.issues.push(issue(issue$1, payload.value, ch._zod.def));
356
+ else {
357
+ const _issue = issue$1;
358
+ if (_issue.fatal) _issue.continue = false;
359
+ _issue.code ?? (_issue.code = "custom");
360
+ _issue.input ?? (_issue.input = payload.value);
361
+ _issue.inst ?? (_issue.inst = ch);
362
+ _issue.continue ?? (_issue.continue = !ch._zod.def.abort);
363
+ payload.issues.push(issue(_issue));
364
+ }
365
+ };
366
+ return fn(payload.value, payload);
367
+ });
368
+ return ch;
369
+ }
370
+ function _check(fn, params) {
371
+ const ch = new $ZodCheck({
372
+ check: "custom",
373
+ ...normalizeParams(params)
374
+ });
375
+ ch._zod.check = fn;
376
+ return ch;
377
+ }
378
+ function describe(description) {
379
+ const ch = new $ZodCheck({ check: "describe" });
380
+ ch._zod.onattach = [(inst) => {
381
+ const existing = globalRegistry.get(inst) ?? {};
382
+ globalRegistry.add(inst, {
383
+ ...existing,
384
+ description
385
+ });
386
+ }];
387
+ ch._zod.check = () => {};
388
+ return ch;
389
+ }
390
+ function meta(metadata) {
391
+ const ch = new $ZodCheck({ check: "meta" });
392
+ ch._zod.onattach = [(inst) => {
393
+ const existing = globalRegistry.get(inst) ?? {};
394
+ globalRegistry.add(inst, {
395
+ ...existing,
396
+ ...metadata
397
+ });
398
+ }];
399
+ ch._zod.check = () => {};
400
+ return ch;
401
+ }
402
+
403
+ //#endregion
404
+ export { _array, _base64, _base64url, _cidrv4, _cidrv6, _cuid, _cuid2, _e164, _email, _emoji, _endsWith, _guid, _includes, _ipv4, _ipv6, _isoDate, _isoDateTime, _isoDuration, _isoTime, _jwt, _ksuid, _length, _lowercase, _maxLength, _minLength, _nanoid, _normalize, _overwrite, _refine, _regex, _slugify, _startsWith, _string, _superRefine, _toLowerCase, _toUpperCase, _trim, _ulid, _uppercase, _url, _uuid, _uuidv4, _uuidv6, _uuidv7, _xid, describe, meta };
@@ -0,0 +1,225 @@
1
+ import { $constructor } from "./core.js";
2
+ import { escapeRegex, getLengthableOrigin, nullish } from "./util.js";
3
+ import { lowercase, uppercase } from "./regexes.js";
4
+
5
+ //#region ../../../node_modules/zod/v4/core/checks.js
6
+ const $ZodCheck = /* @__PURE__ */ $constructor("$ZodCheck", (inst, def) => {
7
+ var _a;
8
+ inst._zod ?? (inst._zod = {});
9
+ inst._zod.def = def;
10
+ (_a = inst._zod).onattach ?? (_a.onattach = []);
11
+ });
12
+ const $ZodCheckMaxLength = /* @__PURE__ */ $constructor("$ZodCheckMaxLength", (inst, def) => {
13
+ var _a;
14
+ $ZodCheck.init(inst, def);
15
+ (_a = inst._zod.def).when ?? (_a.when = (payload) => {
16
+ const val = payload.value;
17
+ return !nullish(val) && val.length !== void 0;
18
+ });
19
+ inst._zod.onattach.push((inst$1) => {
20
+ const curr = inst$1._zod.bag.maximum ?? Number.POSITIVE_INFINITY;
21
+ if (def.maximum < curr) inst$1._zod.bag.maximum = def.maximum;
22
+ });
23
+ inst._zod.check = (payload) => {
24
+ const input = payload.value;
25
+ if (input.length <= def.maximum) return;
26
+ const origin = getLengthableOrigin(input);
27
+ payload.issues.push({
28
+ origin,
29
+ code: "too_big",
30
+ maximum: def.maximum,
31
+ inclusive: true,
32
+ input,
33
+ inst,
34
+ continue: !def.abort
35
+ });
36
+ };
37
+ });
38
+ const $ZodCheckMinLength = /* @__PURE__ */ $constructor("$ZodCheckMinLength", (inst, def) => {
39
+ var _a;
40
+ $ZodCheck.init(inst, def);
41
+ (_a = inst._zod.def).when ?? (_a.when = (payload) => {
42
+ const val = payload.value;
43
+ return !nullish(val) && val.length !== void 0;
44
+ });
45
+ inst._zod.onattach.push((inst$1) => {
46
+ const curr = inst$1._zod.bag.minimum ?? Number.NEGATIVE_INFINITY;
47
+ if (def.minimum > curr) inst$1._zod.bag.minimum = def.minimum;
48
+ });
49
+ inst._zod.check = (payload) => {
50
+ const input = payload.value;
51
+ if (input.length >= def.minimum) return;
52
+ const origin = getLengthableOrigin(input);
53
+ payload.issues.push({
54
+ origin,
55
+ code: "too_small",
56
+ minimum: def.minimum,
57
+ inclusive: true,
58
+ input,
59
+ inst,
60
+ continue: !def.abort
61
+ });
62
+ };
63
+ });
64
+ const $ZodCheckLengthEquals = /* @__PURE__ */ $constructor("$ZodCheckLengthEquals", (inst, def) => {
65
+ var _a;
66
+ $ZodCheck.init(inst, def);
67
+ (_a = inst._zod.def).when ?? (_a.when = (payload) => {
68
+ const val = payload.value;
69
+ return !nullish(val) && val.length !== void 0;
70
+ });
71
+ inst._zod.onattach.push((inst$1) => {
72
+ const bag = inst$1._zod.bag;
73
+ bag.minimum = def.length;
74
+ bag.maximum = def.length;
75
+ bag.length = def.length;
76
+ });
77
+ inst._zod.check = (payload) => {
78
+ const input = payload.value;
79
+ const length = input.length;
80
+ if (length === def.length) return;
81
+ const origin = getLengthableOrigin(input);
82
+ const tooBig = length > def.length;
83
+ payload.issues.push({
84
+ origin,
85
+ ...tooBig ? {
86
+ code: "too_big",
87
+ maximum: def.length
88
+ } : {
89
+ code: "too_small",
90
+ minimum: def.length
91
+ },
92
+ inclusive: true,
93
+ exact: true,
94
+ input: payload.value,
95
+ inst,
96
+ continue: !def.abort
97
+ });
98
+ };
99
+ });
100
+ const $ZodCheckStringFormat = /* @__PURE__ */ $constructor("$ZodCheckStringFormat", (inst, def) => {
101
+ var _a, _b;
102
+ $ZodCheck.init(inst, def);
103
+ inst._zod.onattach.push((inst$1) => {
104
+ const bag = inst$1._zod.bag;
105
+ bag.format = def.format;
106
+ if (def.pattern) {
107
+ bag.patterns ?? (bag.patterns = /* @__PURE__ */ new Set());
108
+ bag.patterns.add(def.pattern);
109
+ }
110
+ });
111
+ if (def.pattern) (_a = inst._zod).check ?? (_a.check = (payload) => {
112
+ def.pattern.lastIndex = 0;
113
+ if (def.pattern.test(payload.value)) return;
114
+ payload.issues.push({
115
+ origin: "string",
116
+ code: "invalid_format",
117
+ format: def.format,
118
+ input: payload.value,
119
+ ...def.pattern ? { pattern: def.pattern.toString() } : {},
120
+ inst,
121
+ continue: !def.abort
122
+ });
123
+ });
124
+ else (_b = inst._zod).check ?? (_b.check = () => {});
125
+ });
126
+ const $ZodCheckRegex = /* @__PURE__ */ $constructor("$ZodCheckRegex", (inst, def) => {
127
+ $ZodCheckStringFormat.init(inst, def);
128
+ inst._zod.check = (payload) => {
129
+ def.pattern.lastIndex = 0;
130
+ if (def.pattern.test(payload.value)) return;
131
+ payload.issues.push({
132
+ origin: "string",
133
+ code: "invalid_format",
134
+ format: "regex",
135
+ input: payload.value,
136
+ pattern: def.pattern.toString(),
137
+ inst,
138
+ continue: !def.abort
139
+ });
140
+ };
141
+ });
142
+ const $ZodCheckLowerCase = /* @__PURE__ */ $constructor("$ZodCheckLowerCase", (inst, def) => {
143
+ def.pattern ?? (def.pattern = lowercase);
144
+ $ZodCheckStringFormat.init(inst, def);
145
+ });
146
+ const $ZodCheckUpperCase = /* @__PURE__ */ $constructor("$ZodCheckUpperCase", (inst, def) => {
147
+ def.pattern ?? (def.pattern = uppercase);
148
+ $ZodCheckStringFormat.init(inst, def);
149
+ });
150
+ const $ZodCheckIncludes = /* @__PURE__ */ $constructor("$ZodCheckIncludes", (inst, def) => {
151
+ $ZodCheck.init(inst, def);
152
+ const escapedRegex = escapeRegex(def.includes);
153
+ const pattern = new RegExp(typeof def.position === "number" ? `^.{${def.position}}${escapedRegex}` : escapedRegex);
154
+ def.pattern = pattern;
155
+ inst._zod.onattach.push((inst$1) => {
156
+ const bag = inst$1._zod.bag;
157
+ bag.patterns ?? (bag.patterns = /* @__PURE__ */ new Set());
158
+ bag.patterns.add(pattern);
159
+ });
160
+ inst._zod.check = (payload) => {
161
+ if (payload.value.includes(def.includes, def.position)) return;
162
+ payload.issues.push({
163
+ origin: "string",
164
+ code: "invalid_format",
165
+ format: "includes",
166
+ includes: def.includes,
167
+ input: payload.value,
168
+ inst,
169
+ continue: !def.abort
170
+ });
171
+ };
172
+ });
173
+ const $ZodCheckStartsWith = /* @__PURE__ */ $constructor("$ZodCheckStartsWith", (inst, def) => {
174
+ $ZodCheck.init(inst, def);
175
+ const pattern = /* @__PURE__ */ new RegExp(`^${escapeRegex(def.prefix)}.*`);
176
+ def.pattern ?? (def.pattern = pattern);
177
+ inst._zod.onattach.push((inst$1) => {
178
+ const bag = inst$1._zod.bag;
179
+ bag.patterns ?? (bag.patterns = /* @__PURE__ */ new Set());
180
+ bag.patterns.add(pattern);
181
+ });
182
+ inst._zod.check = (payload) => {
183
+ if (payload.value.startsWith(def.prefix)) return;
184
+ payload.issues.push({
185
+ origin: "string",
186
+ code: "invalid_format",
187
+ format: "starts_with",
188
+ prefix: def.prefix,
189
+ input: payload.value,
190
+ inst,
191
+ continue: !def.abort
192
+ });
193
+ };
194
+ });
195
+ const $ZodCheckEndsWith = /* @__PURE__ */ $constructor("$ZodCheckEndsWith", (inst, def) => {
196
+ $ZodCheck.init(inst, def);
197
+ const pattern = /* @__PURE__ */ new RegExp(`.*${escapeRegex(def.suffix)}$`);
198
+ def.pattern ?? (def.pattern = pattern);
199
+ inst._zod.onattach.push((inst$1) => {
200
+ const bag = inst$1._zod.bag;
201
+ bag.patterns ?? (bag.patterns = /* @__PURE__ */ new Set());
202
+ bag.patterns.add(pattern);
203
+ });
204
+ inst._zod.check = (payload) => {
205
+ if (payload.value.endsWith(def.suffix)) return;
206
+ payload.issues.push({
207
+ origin: "string",
208
+ code: "invalid_format",
209
+ format: "ends_with",
210
+ suffix: def.suffix,
211
+ input: payload.value,
212
+ inst,
213
+ continue: !def.abort
214
+ });
215
+ };
216
+ });
217
+ const $ZodCheckOverwrite = /* @__PURE__ */ $constructor("$ZodCheckOverwrite", (inst, def) => {
218
+ $ZodCheck.init(inst, def);
219
+ inst._zod.check = (payload) => {
220
+ payload.value = def.tx(payload.value);
221
+ };
222
+ });
223
+
224
+ //#endregion
225
+ export { $ZodCheck, $ZodCheckEndsWith, $ZodCheckIncludes, $ZodCheckLengthEquals, $ZodCheckLowerCase, $ZodCheckMaxLength, $ZodCheckMinLength, $ZodCheckOverwrite, $ZodCheckRegex, $ZodCheckStartsWith, $ZodCheckStringFormat, $ZodCheckUpperCase };
@@ -0,0 +1,61 @@
1
+ //#region ../../../node_modules/zod/v4/core/core.js
2
+ /** A special constant with type `never` */
3
+ const NEVER = Object.freeze({ status: "aborted" });
4
+ function $constructor(name, initializer, params) {
5
+ function init(inst, def) {
6
+ if (!inst._zod) Object.defineProperty(inst, "_zod", {
7
+ value: {
8
+ def,
9
+ constr: _,
10
+ traits: /* @__PURE__ */ new Set()
11
+ },
12
+ enumerable: false
13
+ });
14
+ if (inst._zod.traits.has(name)) return;
15
+ inst._zod.traits.add(name);
16
+ initializer(inst, def);
17
+ const proto = _.prototype;
18
+ const keys = Object.keys(proto);
19
+ for (let i = 0; i < keys.length; i++) {
20
+ const k = keys[i];
21
+ if (!(k in inst)) inst[k] = proto[k].bind(inst);
22
+ }
23
+ }
24
+ const Parent = params?.Parent ?? Object;
25
+ class Definition extends Parent {}
26
+ Object.defineProperty(Definition, "name", { value: name });
27
+ function _(def) {
28
+ var _a;
29
+ const inst = params?.Parent ? new Definition() : this;
30
+ init(inst, def);
31
+ (_a = inst._zod).deferred ?? (_a.deferred = []);
32
+ for (const fn of inst._zod.deferred) fn();
33
+ return inst;
34
+ }
35
+ Object.defineProperty(_, "init", { value: init });
36
+ Object.defineProperty(_, Symbol.hasInstance, { value: (inst) => {
37
+ if (params?.Parent && inst instanceof params.Parent) return true;
38
+ return inst?._zod?.traits?.has(name);
39
+ } });
40
+ Object.defineProperty(_, "name", { value: name });
41
+ return _;
42
+ }
43
+ var $ZodAsyncError = class extends Error {
44
+ constructor() {
45
+ super(`Encountered Promise during synchronous parse. Use .parseAsync() instead.`);
46
+ }
47
+ };
48
+ var $ZodEncodeError = class extends Error {
49
+ constructor(name) {
50
+ super(`Encountered unidirectional transform during encode: ${name}`);
51
+ this.name = "ZodEncodeError";
52
+ }
53
+ };
54
+ const globalConfig = {};
55
+ function config(newConfig) {
56
+ if (newConfig) Object.assign(globalConfig, newConfig);
57
+ return globalConfig;
58
+ }
59
+
60
+ //#endregion
61
+ export { $ZodAsyncError, $ZodEncodeError, $constructor, config };