@tempots/beatui 1.7.4 → 1.9.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 (161) hide show
  1. package/dist/{ar-Wr6gMs-M.cjs → ar-CEzAem0F.cjs} +1 -1
  2. package/dist/{ar-fdUqbCvM.js → ar-CQieaqsq.js} +1 -1
  3. package/dist/auth/index.cjs.js +1 -1
  4. package/dist/auth/index.es.js +1 -1
  5. package/dist/auth-divider-B8yr-E_b.cjs +1 -0
  6. package/dist/{auth-divider-D9KnNeyF.js → auth-divider-Byh5BWLc.js} +91 -88
  7. package/dist/beatui.css +1 -0
  8. package/dist/beatui.tailwind.css +1 -0
  9. package/dist/better-auth/index.cjs.js +1 -1
  10. package/dist/better-auth/index.es.js +27 -26
  11. package/dist/card-BkA7Wvbh.cjs +1 -0
  12. package/dist/card-DX1DwGbL.js +62 -0
  13. package/dist/{colors-C2sgnzFH.js → colors-CyMhfbJi.js} +64 -58
  14. package/dist/{colors-DPCHjRMj.cjs → colors-IXZF9U-s.cjs} +1 -1
  15. package/dist/control-hqEuMzyI.js +343 -0
  16. package/dist/control-muup9GF1.cjs +1 -0
  17. package/dist/custom-validation-BA9iJWl_.cjs +1 -0
  18. package/dist/custom-validation-BOBoUwHY.js +181 -0
  19. package/dist/{de-C5-k5Eov.js → de-CBIwvkAH.js} +1 -1
  20. package/dist/{de-DZqdSEta.cjs → de-DdfxrlT3.cjs} +1 -1
  21. package/dist/deep-merge-8fwp1z4X.js +1346 -0
  22. package/dist/deep-merge-VDGE_HQD.cjs +1 -0
  23. package/dist/duration-input-DmsljXl3.cjs +1 -0
  24. package/dist/{duration-input-D4V_PHIg.js → duration-input-ZQlcqdXU.js} +32 -31
  25. package/dist/{editor-toolbar-group-FpOHrmtx.js → editor-toolbar-group-BNTBMJCe.js} +2 -2
  26. package/dist/{editor-toolbar-group-C_ft_T8D.cjs → editor-toolbar-group-DiMzqYgz.cjs} +1 -1
  27. package/dist/{es-h6jmoF4X.js → es--9HaEj2D.js} +1 -1
  28. package/dist/{es-CJgYfRap.cjs → es-DSdljxFJ.cjs} +1 -1
  29. package/dist/{fa-BuxK837l.js → fa-1Z-akcW7.js} +1 -1
  30. package/dist/{fa-BQ5PzwNY.cjs → fa-BolmeWRT.cjs} +1 -1
  31. package/dist/flyout-CuKFh_T7.js +151 -0
  32. package/dist/flyout-DC_tKaTG.cjs +1 -0
  33. package/dist/{fr-Bv3TG44U.cjs → fr-CODgUuoZ.cjs} +1 -1
  34. package/dist/{fr-BwILQ9G2.js → fr-DhHM9rou.js} +1 -1
  35. package/dist/{he-yC9Sc7JD.js → he-CBamXbGJ.js} +1 -1
  36. package/dist/{he-5LbvgMCC.cjs → he-Juw-dr28.cjs} +1 -1
  37. package/dist/{hi-Da7rcCpP.js → hi-DvvcX-Ra.js} +1 -1
  38. package/dist/{hi-YWhWcG_L.cjs → hi-R749jeg-.cjs} +1 -1
  39. package/dist/{index-CvU9E9wd.js → index-BfQaT5Jy.js} +104 -104
  40. package/dist/{index-XogEKwdt.cjs → index-Dv7nPuwA.cjs} +1 -1
  41. package/dist/index.cjs.js +4 -4
  42. package/dist/index.es.js +6713 -9831
  43. package/dist/{input-container-CyOgiiQD.cjs → input-container-BaWQLWB6.cjs} +1 -1
  44. package/dist/{input-container-8JFB11xN.js → input-container-DCS5oJ4S.js} +4 -4
  45. package/dist/{it-BxOIJE45.cjs → it-DT5oRZDH.cjs} +1 -1
  46. package/dist/{it-Yeklau78.js → it-aV6i8Qxz.js} +1 -1
  47. package/dist/{ja-Dxj9Q5Yd.js → ja-CuLhGnJX.js} +1 -1
  48. package/dist/{ja-CNhjK06P.cjs → ja-CwKaCYLB.cjs} +1 -1
  49. package/dist/json-schema/index.cjs.js +1 -1
  50. package/dist/json-schema/index.es.js +83 -79
  51. package/dist/json-schema-display/index.cjs.js +1 -1
  52. package/dist/json-schema-display/index.es.js +2 -2
  53. package/dist/json-structure/index.cjs.js +1 -1
  54. package/dist/json-structure/index.es.js +74 -72
  55. package/dist/{ko-DgkqcXTs.cjs → ko-Bucro9ID.cjs} +1 -1
  56. package/dist/{ko-gn_MsegK.js → ko-D-66BsEX.js} +1 -1
  57. package/dist/lexical/index.cjs.js +1 -1
  58. package/dist/lexical/index.es.js +5 -5
  59. package/dist/menu-BFLFKceF.cjs +1 -0
  60. package/dist/menu-BO6zqyfq.js +220 -0
  61. package/dist/modal-6Mq3vS5r.js +309 -0
  62. package/dist/modal-d77-TMc4.cjs +1 -0
  63. package/dist/{nl-vHNFtXXb.js → nl-CAny6wvm.js} +1 -1
  64. package/dist/{nl-Dy9lmbBO.cjs → nl-D7vHpehb.cjs} +1 -1
  65. package/dist/notice-BNGx86Yg.js +110 -0
  66. package/dist/notice-iF6zBMq9.cjs +1 -0
  67. package/dist/{oneof-branch-detection-Q_jxvJIA.js → oneof-branch-detection-Bm17RhC2.js} +27 -26
  68. package/dist/oneof-branch-detection-DZ4MrfBp.cjs +1 -0
  69. package/dist/openui/index.cjs.js +9 -0
  70. package/dist/openui/index.es.js +2174 -0
  71. package/dist/password-input-Bipt7Wsu.cjs +1 -0
  72. package/dist/password-input-mkRmrEPq.js +105 -0
  73. package/dist/{pl-BtYbtsmG.cjs → pl-CSiXoOKT.cjs} +1 -1
  74. package/dist/{pl-C0UdHla0.js → pl-rmZLgQ_V.js} +1 -1
  75. package/dist/prosemirror/index.cjs.js +1 -1
  76. package/dist/prosemirror/index.es.js +4 -4
  77. package/dist/{pt-CtNmqQ1X.cjs → pt-CJT-iq4y.cjs} +1 -1
  78. package/dist/{pt-DGKtfN0d.js → pt-DHnajqAi.js} +1 -1
  79. package/dist/{ru-CpXYLt-v.js → ru-C_E8OZNE.js} +1 -1
  80. package/dist/{ru-BaL_NPRU.cjs → ru-G3sr_ctV.cjs} +1 -1
  81. package/dist/slider-input-SLguFA0d.cjs +1 -0
  82. package/dist/slider-input-VYAMm7pE.js +285 -0
  83. package/dist/stepper-24p16Zsv.cjs +1 -0
  84. package/dist/stepper-TlzbfYWa.js +3222 -0
  85. package/dist/tailwind/preset.cjs.js +1 -1
  86. package/dist/tailwind/preset.es.js +38 -40
  87. package/dist/tailwind/vite-plugin.cjs.js +14 -12
  88. package/dist/tailwind/vite-plugin.es.js +317 -246
  89. package/dist/text-area-BdemKQ_w.cjs +1 -0
  90. package/dist/text-area-Br83-_PQ.js +431 -0
  91. package/dist/{text-input-NJypZSnE.js → text-input-ByuxdX8w.js} +5 -5
  92. package/dist/{text-input-DS5zlXb2.cjs → text-input-MjlUC_9u.cjs} +1 -1
  93. package/dist/{toolbar-BF2L6WKC.js → toolbar-CEBTTjHh.js} +1 -1
  94. package/dist/{toolbar-BBwfe8U9.cjs → toolbar-DWawYFFX.cjs} +1 -1
  95. package/dist/{tr-DwOd87oB.cjs → tr-DcxLHHTC.cjs} +1 -1
  96. package/dist/{tr-DIFZDFW_.js → tr-bVXwloKC.js} +1 -1
  97. package/dist/{translations-EwEmHe3v.cjs → translations-D3xqZUTA.cjs} +1 -1
  98. package/dist/{translations-BCMP-h52.js → translations-DU9wTV1y.js} +20 -19
  99. package/dist/{translations-5cXBrENb.js → translations-RT_UN8ny.js} +1 -1
  100. package/dist/{translations-BqWc0ZHz.cjs → translations-qljG2Chq.cjs} +1 -1
  101. package/dist/types/components/navigation/stepper.d.ts +4 -4
  102. package/dist/types/openui/index.d.ts +28 -0
  103. package/dist/types/openui/library/define-component.d.ts +15 -0
  104. package/dist/types/openui/library/library.d.ts +7 -0
  105. package/dist/types/openui/library/prompt-generator.d.ts +5 -0
  106. package/dist/types/openui/library/types.d.ts +33 -0
  107. package/dist/types/openui/parser/parser.d.ts +8 -0
  108. package/dist/types/openui/parser/streaming-parser.d.ts +14 -0
  109. package/dist/types/openui/parser/tokenizer.d.ts +9 -0
  110. package/dist/types/openui/parser/types.d.ts +46 -0
  111. package/dist/types/openui/registry/button.d.ts +148 -0
  112. package/dist/types/openui/registry/data.d.ts +177 -0
  113. package/dist/types/openui/registry/form.d.ts +65 -0
  114. package/dist/types/openui/registry/format.d.ts +67 -0
  115. package/dist/types/openui/registry/index.d.ts +9 -0
  116. package/dist/types/openui/registry/layout.d.ts +45 -0
  117. package/dist/types/openui/registry/navigation.d.ts +149 -0
  118. package/dist/types/openui/registry/overlay.d.ts +56 -0
  119. package/dist/types/openui/registry/typography.d.ts +17 -0
  120. package/dist/types/openui/renderer/action-context.d.ts +24 -0
  121. package/dist/types/openui/renderer/node-resolver.d.ts +9 -0
  122. package/dist/types/openui/renderer/openui-renderer.d.ts +32 -0
  123. package/dist/types/openui/renderer/skeleton.d.ts +2 -0
  124. package/dist/types/openui/streaming/from-fetch.d.ts +7 -0
  125. package/dist/types/openui/streaming/from-sse.d.ts +7 -0
  126. package/dist/types/openui/streaming/from-websocket.d.ts +10 -0
  127. package/dist/types/openui/streaming/types.d.ts +5 -0
  128. package/dist/types/tailwind/preset.d.ts +25 -4
  129. package/dist/types/tailwind/vite-plugin.d.ts +17 -5
  130. package/dist/types/tokens/colors.d.ts +87 -9
  131. package/dist/types/tokens/index.d.ts +7 -6
  132. package/dist/{ur-DBst-TXc.js → ur-Dls2qb4V.js} +1 -1
  133. package/dist/{ur-D9nLchps.cjs → ur-IRQoHh1E.cjs} +1 -1
  134. package/dist/use-form-BZ8vDYOv.cjs +2 -0
  135. package/dist/use-form-DsCzINfm.js +750 -0
  136. package/dist/utils-D3-NApSw.cjs +1 -0
  137. package/dist/utils-Nbh7yQ73.js +105 -0
  138. package/dist/{vi-Dg1aiMr5.cjs → vi-Bi9SvVCP.cjs} +1 -1
  139. package/dist/{vi-DQOJp32U.js → vi-C3mTzj50.js} +1 -1
  140. package/dist/widget-customization-BV6XB2v_.cjs +1 -0
  141. package/dist/widget-customization-Bso45ONQ.js +1198 -0
  142. package/dist/{zh-DPK4HXl2.js → zh-B4JRJBt2.js} +1 -1
  143. package/dist/{zh-tbwSTbmn.cjs → zh-BMU5rYu1.cjs} +1 -1
  144. package/package.json +31 -20
  145. package/dist/auth-divider-CjcrgXmq.cjs +0 -1
  146. package/dist/custom-validation-7por5nJN.js +0 -488
  147. package/dist/custom-validation-CLscGHY4.cjs +0 -1
  148. package/dist/deep-merge-D90SW1Ci.cjs +0 -1
  149. package/dist/deep-merge-DT2H9AGq.js +0 -1765
  150. package/dist/duration-input-4AQnQpyo.cjs +0 -1
  151. package/dist/menu-B60Q9j3-.cjs +0 -1
  152. package/dist/menu-BkqFGcXg.js +0 -366
  153. package/dist/notice-CQGJyZ8o.js +0 -211
  154. package/dist/notice-p2IqXS5-.cjs +0 -1
  155. package/dist/oneof-branch-detection-xDDDdYRk.cjs +0 -1
  156. package/dist/use-form-8NnZ-KHk.js +0 -1090
  157. package/dist/use-form-Dcra7GeE.cjs +0 -2
  158. package/dist/utils-DmEuG3Np.cjs +0 -1
  159. package/dist/utils-vUtP6iPG.js +0 -165
  160. package/dist/widget-customization-BIBva3f-.js +0 -1458
  161. package/dist/widget-customization-pqmtsraC.cjs +0 -1
@@ -0,0 +1,10 @@
1
+ import { Signal } from '@tempots/dom';
2
+ import { StreamOptions } from './types';
3
+ export declare function fromWebSocket(url: string, options?: StreamOptions & {
4
+ protocols?: string[];
5
+ }): {
6
+ response: Signal<string>;
7
+ isStreaming: Signal<boolean>;
8
+ close: () => void;
9
+ send: (data: string) => void;
10
+ };
@@ -0,0 +1,5 @@
1
+ export interface StreamOptions {
2
+ onComplete?: () => void;
3
+ onError?: (error: Error) => void;
4
+ extractContent?: (chunk: unknown) => string;
5
+ }
@@ -7,7 +7,7 @@
7
7
  *
8
8
  * @module
9
9
  */
10
- import { type SemanticColorOverrides } from '../tokens/colors';
10
+ import { type ColorShadeMap, type SemanticColorOverrides } from '../tokens/colors';
11
11
  import type { FontFamilyOverrides, SemanticFontOverrides } from '../tokens/typography';
12
12
  import type { SemanticRadiusOverrides } from '../tokens/radius';
13
13
  import type { SemanticShadowOverrides } from '../tokens/shadows';
@@ -29,11 +29,32 @@ import type { SemanticTextShadowOverrides } from '../tokens/text-shadows';
29
29
  * })
30
30
  * ```
31
31
  */
32
- export interface BeatuiPresetOptions {
32
+ export interface BeatuiPresetOptions<C extends string = never> {
33
+ /**
34
+ * Register custom color palettes. Each key is a color name and the value
35
+ * defines all 11 shades (50–950). Custom color names can be referenced in
36
+ * `semanticColors` and in component `color` props (after type registration).
37
+ *
38
+ * The BeatUI Vite plugin automatically generates a `.d.ts` file that
39
+ * registers these names with the type system. When using the preset directly
40
+ * (without the Vite plugin), augment {@link CustomColorRegistry} manually.
41
+ *
42
+ * @example
43
+ * ```ts
44
+ * createBeatuiPreset({
45
+ * customColors: {
46
+ * rust: { 50: 'oklch(...)', 100: '...', ..., 950: '...' },
47
+ * },
48
+ * semanticColors: { primary: 'rust' },
49
+ * })
50
+ * ```
51
+ */
52
+ customColors?: Record<C, ColorShadeMap>;
33
53
  /**
34
54
  * Override the semantic color mapping BeatUI uses (e.g. map `primary` to `emerald`).
55
+ * When `customColors` is provided, custom color names are also accepted.
35
56
  */
36
- semanticColors?: SemanticColorOverrides;
57
+ semanticColors?: SemanticColorOverrides<C>;
37
58
  /**
38
59
  * Override semantic font aliases (e.g. map `heading` to `var(--font-family-serif)`).
39
60
  */
@@ -160,7 +181,7 @@ interface TailwindPluginConfig {
160
181
  * }
161
182
  * ```
162
183
  */
163
- export declare function createBeatuiPreset(options?: BeatuiPresetOptions): TailwindPreset;
184
+ export declare function createBeatuiPreset<C extends string = never>(options?: BeatuiPresetOptions<C>): TailwindPreset;
164
185
  /**
165
186
  * A ready-to-use BeatUI Tailwind preset with all default options.
166
187
  *
@@ -1,5 +1,5 @@
1
1
  import type { Plugin } from 'vite';
2
- import type { SemanticColorOverrides } from '../tokens/colors';
2
+ import { type ColorShadeMap, type SemanticColorOverrides } from '../tokens/colors';
3
3
  import type { FontFamilyOverrides, SemanticFontOverrides } from '../tokens/typography';
4
4
  import type { SemanticRadiusOverrides } from '../tokens/radius';
5
5
  import type { SemanticShadowOverrides } from '../tokens/shadows';
@@ -7,9 +7,21 @@ import type { SemanticMotionOverrides } from '../tokens/motion';
7
7
  import type { SemanticSpacingOverrides } from '../tokens/spacing';
8
8
  import type { SemanticTextShadowOverrides } from '../tokens/text-shadows';
9
9
  import { type GoogleFontRequest } from './google-fonts';
10
- export interface BeatuiTailwindPluginOptions {
11
- /** Override the semantic color mapping BeatUI uses (e.g. map `primary` to `emerald`). */
12
- semanticColors?: SemanticColorOverrides;
10
+ export interface BeatuiTailwindPluginOptions<C extends string = never> {
11
+ /**
12
+ * Register custom color palettes with 11 shades each (50–950).
13
+ * Custom palette names become valid values for `semanticColors` and can be
14
+ * used in component `color` props after type registration.
15
+ *
16
+ * The plugin automatically emits a `beatui-custom-colors.d.ts` file in the
17
+ * project root that registers these names with the TypeScript type system.
18
+ */
19
+ customColors?: Record<C, ColorShadeMap>;
20
+ /**
21
+ * Override the semantic color mapping BeatUI uses (e.g. map `primary` to `emerald`).
22
+ * When `customColors` is provided, custom color names are also accepted.
23
+ */
24
+ semanticColors?: SemanticColorOverrides<C>;
13
25
  /** Override semantic font aliases (e.g. map `heading` to `var(--font-family-serif)`). */
14
26
  semanticFonts?: SemanticFontOverrides;
15
27
  /** Override semantic radius aliases for controls, surfaces, etc. */
@@ -50,6 +62,6 @@ export interface BeatuiTailwindPluginOptions {
50
62
  /** Request Google Fonts for local hosting. */
51
63
  googleFonts?: GoogleFontRequest | GoogleFontRequest[];
52
64
  }
53
- export declare function beatuiTailwindPlugin(options?: BeatuiTailwindPluginOptions): Plugin;
65
+ export declare function beatuiTailwindPlugin<C extends string = never>(options?: BeatuiTailwindPluginOptions<C>): Plugin;
54
66
  export default beatuiTailwindPlugin;
55
67
  export type { GoogleFontRequest };
@@ -18,6 +18,65 @@ import { colors } from './base-colors';
18
18
  * ```
19
19
  */
20
20
  export type ColorName = keyof typeof colors;
21
+ /**
22
+ * Registry interface for user-defined custom color palettes.
23
+ *
24
+ * Augment this interface via declaration merging to make custom color names
25
+ * available in component `color` props with full type-safety and autocomplete.
26
+ *
27
+ * The BeatUI Vite plugin automatically generates the declaration file when
28
+ * `customColors` is configured, so manual augmentation is typically not needed.
29
+ *
30
+ * @example
31
+ * ```ts
32
+ * // beatui-custom-colors.d.ts (auto-generated by the Vite plugin)
33
+ * declare module '@tempots/beatui' {
34
+ * interface CustomColorRegistry {
35
+ * rust: true
36
+ * ocean: true
37
+ * }
38
+ * }
39
+ * ```
40
+ */
41
+ export interface CustomColorRegistry {
42
+ }
43
+ /**
44
+ * Union type of user-defined custom color names derived from {@link CustomColorRegistry}.
45
+ * Evaluates to `never` when no custom colors are registered.
46
+ */
47
+ export type CustomColorName = keyof CustomColorRegistry & string;
48
+ /**
49
+ * A record mapping each shade (50–950) to a CSS color value.
50
+ * Used to define custom color palettes.
51
+ *
52
+ * @example
53
+ * ```ts
54
+ * const rust: ColorShadeMap = {
55
+ * 50: 'oklch(0.97 0.02 50)',
56
+ * 100: 'oklch(0.93 0.04 48)',
57
+ * // ... all 11 shades
58
+ * 950: 'oklch(0.25 0.08 35)',
59
+ * }
60
+ * ```
61
+ */
62
+ export type ColorShadeMap = Record<ColorShade, string>;
63
+ /**
64
+ * Utility type for registering custom color names from a `customColors` object.
65
+ * Use with declaration merging to keep the registry in sync with your runtime config.
66
+ *
67
+ * @example
68
+ * ```ts
69
+ * import type { RegisterColors, ColorShadeMap } from '@tempots/beatui'
70
+ * import { myColors } from './my-colors'
71
+ *
72
+ * declare module '@tempots/beatui' {
73
+ * interface CustomColorRegistry extends RegisterColors<typeof myColors> {}
74
+ * }
75
+ * ```
76
+ */
77
+ export type RegisterColors<T extends Record<string, ColorShadeMap>> = {
78
+ [K in keyof T]: true;
79
+ };
21
80
  /**
22
81
  * Union type representing the available shade levels in the color scale.
23
82
  * Ranges from 50 (lightest) to 950 (darkest).
@@ -41,9 +100,10 @@ export declare const colorShades: ColorShade[];
41
100
  export type SemanticColorName = 'primary' | 'secondary' | 'base' | 'success' | 'warning' | 'danger' | 'info';
42
101
  /**
43
102
  * Union type of all theme-aware color names, including base colors,
44
- * semantic colors, and the special 'black' and 'white' values.
103
+ * semantic colors, custom colors registered via {@link CustomColorRegistry},
104
+ * and the special 'black' and 'white' values.
45
105
  */
46
- export type ThemeColorName = ColorName | SemanticColorName | 'black' | 'white';
106
+ export type ThemeColorName = ColorName | SemanticColorName | CustomColorName | 'black' | 'white';
47
107
  /**
48
108
  * Tuple of all semantic color names, used for iteration and validation.
49
109
  */
@@ -78,12 +138,18 @@ export declare const semanticColors: Record<SemanticColorName, ColorName>;
78
138
  /**
79
139
  * Partial record for overriding default semantic-to-base color mappings.
80
140
  *
141
+ * The generic parameter `C` allows additional custom color names (inferred from
142
+ * a `customColors` configuration) to be accepted alongside built-in palette names.
143
+ *
81
144
  * @example
82
145
  * ```ts
83
146
  * const overrides: SemanticColorOverrides = { primary: 'indigo', danger: 'rose' }
147
+ *
148
+ * // With custom colors:
149
+ * const overrides: SemanticColorOverrides<'rust'> = { primary: 'rust' }
84
150
  * ```
85
151
  */
86
- export type SemanticColorOverrides = Partial<Record<SemanticColorName, ThemeColorName>>;
152
+ export type SemanticColorOverrides<C extends string = never> = Partial<Record<SemanticColorName, ThemeColorName | C>>;
87
153
  /**
88
154
  * Resolves the full semantic color map by merging defaults with any provided overrides.
89
155
  *
@@ -305,9 +371,10 @@ export declare const backgroundConfig: {
305
371
  };
306
372
  /**
307
373
  * Generates CSS custom property declarations for all core (base) color tokens.
308
- * Includes `--color-white`, `--color-black`, `--color-inherit`, and all
309
- * base palette colors at every shade level.
374
+ * Includes `--color-white`, `--color-black`, `--color-inherit`, all
375
+ * base palette colors at every shade level, and any user-provided custom color palettes.
310
376
  *
377
+ * @param customColors - Optional record of custom color palettes to register
311
378
  * @returns A record mapping CSS variable names to their values
312
379
  *
313
380
  * @example
@@ -315,25 +382,36 @@ export declare const backgroundConfig: {
315
382
  * const vars = generateCoreColorVariables()
316
383
  * // vars['--color-blue-500'] === 'oklch(0.623 0.214 259.815)'
317
384
  * // vars['--color-white'] === 'white'
385
+ *
386
+ * const varsWithCustom = generateCoreColorVariables({
387
+ * rust: { 50: 'oklch(...)', ..., 950: 'oklch(...)' },
388
+ * })
389
+ * // varsWithCustom['--color-rust-500'] === 'oklch(...)'
318
390
  * ```
319
391
  */
320
- export declare function generateCoreColorVariables(): Record<string, string>;
392
+ export declare function generateCoreColorVariables<C extends string = never>(customColors?: Record<C, ColorShadeMap>): Record<string, string>;
321
393
  /**
322
394
  * Generates CSS custom property declarations for semantic colors, background
323
395
  * colors, text colors, border colors, and interactive colors. Semantic colors
324
396
  * reference base color variables so themes can be changed by swapping the
325
397
  * semantic mapping.
326
398
  *
327
- * @param overrides - Optional overrides for semantic color mappings
399
+ * @param overrides - Optional overrides for semantic color mappings.
400
+ * Values may reference built-in palette names, custom color names, or any
401
+ * string matching a `--color-<name>-<shade>` CSS variable.
328
402
  * @returns A record mapping CSS variable names to their values
329
403
  *
330
404
  * @example
331
405
  * ```ts
332
406
  * const vars = generateSemanticColorVariables({ primary: 'indigo' })
333
407
  * // vars['--color-primary-500'] === 'var(--color-indigo-500)'
408
+ *
409
+ * // With custom colors:
410
+ * const vars2 = generateSemanticColorVariables({ primary: 'rust' })
411
+ * // vars2['--color-primary-500'] === 'var(--color-rust-500)'
334
412
  * ```
335
413
  */
336
- export declare function generateSemanticColorVariables(overrides?: SemanticColorOverrides): Record<string, string>;
414
+ export declare function generateSemanticColorVariables<C extends string = never>(overrides?: SemanticColorOverrides<C>): Record<string, string>;
337
415
  /**
338
416
  * Generates the complete set of CSS custom property declarations for all color tokens,
339
417
  * combining both core color variables and semantic color variables.
@@ -346,4 +424,4 @@ export declare function generateSemanticColorVariables(overrides?: SemanticColor
346
424
  * // Contains both base colors and semantic mappings
347
425
  * ```
348
426
  */
349
- export declare function generateColorVariables(): Record<string, string>;
427
+ export declare function generateColorVariables<C extends string = never>(customColors?: Record<C, ColorShadeMap>): Record<string, string>;
@@ -10,16 +10,17 @@ export * from './typography';
10
10
  export * from './z-index';
11
11
  export * from './motion';
12
12
  export * from './text-shadows';
13
- import { SemanticColorOverrides } from './colors';
13
+ import { type ColorShadeMap, type SemanticColorOverrides } from './colors';
14
14
  import { SemanticFontOverrides } from './typography';
15
15
  import { SemanticRadiusOverrides } from './radius';
16
16
  import { SemanticShadowOverrides } from './shadows';
17
17
  import { SemanticTextShadowOverrides } from './text-shadows';
18
18
  import { SemanticMotionOverrides } from './motion';
19
19
  import { SemanticSpacingOverrides } from './spacing';
20
- export declare function generateCoreTokenVariables(): Record<string, string>;
21
- export interface SemanticTokenOverrideOptions {
22
- colors?: SemanticColorOverrides;
20
+ export declare function generateCoreTokenVariables<C extends string = never>(customColors?: Record<C, ColorShadeMap>): Record<string, string>;
21
+ export interface SemanticTokenOverrideOptions<C extends string = never> {
22
+ colors?: SemanticColorOverrides<C>;
23
+ customColors?: Record<C, ColorShadeMap>;
23
24
  fonts?: SemanticFontOverrides;
24
25
  radii?: SemanticRadiusOverrides;
25
26
  shadows?: SemanticShadowOverrides;
@@ -27,6 +28,6 @@ export interface SemanticTokenOverrideOptions {
27
28
  spacing?: SemanticSpacingOverrides;
28
29
  textShadows?: SemanticTextShadowOverrides;
29
30
  }
30
- export declare function generateSemanticTokenVariables(overrides?: SemanticColorOverrides | SemanticTokenOverrideOptions): Record<string, string>;
31
- export declare function generateAllTokenVariables(): Record<string, string>;
31
+ export declare function generateSemanticTokenVariables<C extends string = never>(overrides?: SemanticColorOverrides<C> | SemanticTokenOverrideOptions<C>): Record<string, string>;
32
+ export declare function generateAllTokenVariables<C extends string = never>(customColors?: Record<C, ColorShadeMap>): Record<string, string>;
32
33
  export declare function getTokenValue(tokenName: string, element?: HTMLElement): string;
@@ -1,4 +1,4 @@
1
- import { f as i } from "./translations-BCMP-h52.js";
1
+ import { f as i } from "./translations-DU9wTV1y.js";
2
2
  const s = {
3
3
  loadingExtended: "لوڈ ہو رہا ہے، براہ کرم انتظار کریں",
4
4
  loadingShort: "لوڈ ہو رہا ہے...",
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const i=require("./translations-EwEmHe3v.cjs"),r={loadingExtended:"لوڈ ہو رہا ہے، براہ کرم انتظار کریں",loadingShort:"لوڈ ہو رہا ہے...",locale:"زبان",iconDescription:"آئیکن",loadingIcon:"لوڈنگ آئیکن",failedToLoadIcon:"آئیکن لوڈ کرنے میں ناکام",editLabel:"ترمیم",selectOne:"ایک منتخب کریں",selectNone:"کوئی نہیں",selectMany:"متعدد منتخب کریں",noResults:"کوئی نتیجہ نہیں",passwordPlaceholderText:"خفیہ پاس ورڈ",togglePasswordVisibility:"پاس ورڈ کی مرئیت تبدیل کریں",toggleMenu:"مینو ٹوگل کریں",toggleAside:"سائیڈ پینل ٹوگل کریں",mainNavigation:"بنیادی نیویگیشن",sidebar:"سائیڈ بار",closeDrawer:"دراز بند کریں",closeModal:"ماڈل بند کریں",confirm:"تصدیق",cancel:"منسوخ",addLabel:"شامل کریں",removeItem:"آئٹم ہٹائیں",currentLocale:"اردو",ar:"عربی",de:"جرمن",en:"انگریزی",es:"ہسپانوی",fr:"فرانسیسی",he:"عبرانی",hi:"ہندی",it:"اطالوی",ja:"جاپانی",ko:"کوریائی",nl:"ڈچ",pl:"پولش",pt:"پرتگالی",ru:"روسی",tr:"ترکی",vi:"ویتنامی",zh:"چینی",fa:"فارسی",ur:"اردو",emailPlaceholderText:"اپنا ای میل داخل کریں",incrementValue:"قدر اضافہ کریں",decrementValue:"قدر کم کریں",dropZoneInstructions:e=>e?"منتخب کرنے کے لیے کلک کریں یا فائلیں یہاں گھسیٹیں، یا فائل منتخب کرنے کے لیے Enter یا Space دبائیں":"فائلیں یہاں گھسیٹیں",fileSizeUnits:["بائٹس","KB","MB","GB","TB"],removeFile:"فائل حذف کریں",clearAllFiles:"تمام فائلیں صاف کریں",clearValue:"قدر صاف کریں",dateRangeStart:"Start",dateRangeEnd:"End",dateRangeNoLimit:"No limit",dateRangeSelectDate:"Select date",unknownType:"نامعلوم قسم",filesInputInstructions:(e,t,l)=>{let o=e==null||e>1?"منتخب کرنے کے لیے کلک کریں یا فائلیں یہاں گھسیٹیں":"منتخب کرنے کے لیے کلک کریں یا فائل یہاں گھسیٹیں";if(e||t){const n=[];if(e!=null&&e>1&&n.push(`زیادہ سے زیادہ ${e} فائلیں`),t&&l){const a=i.formatFileSize(t,{units:l});n.push(`ہر ایک زیادہ سے زیادہ ${a}`)}n.length>0&&(o+=` (${n.join("، ")})`)}return o},paginationLabel:"صفحہ بندی",paginationRange:(e,t,l,o)=>o>l?`قطاریں ${e} سے ${t} تک، ${l} میں سے ${o} میں سے`:`قطاریں ${e} سے ${t} تک، ${l} میں سے`,firstPage:"پہلا صفحہ",previousPage:"پچھلا صفحہ",nextPage:"اگلا صفحہ",lastPage:"آخری صفحہ",breadcrumbs:"بریڈ کرمبز",commandPalette:"کمانڈ پیلیٹ",typeACommand:"کمانڈ ٹائپ کریں...",noResultsFound:"کوئی نتیجہ نہیں ملا",noMatchingCommands:"کوئی مماثل کمانڈ نہیں ملی",appearanceSystem:"سسٹم",appearanceLight:"ہلکا",appearanceDark:"گہرا",ok:"OK",changeTypeConfirmation:"قسم تبدیل کرنے سے موجودہ قدر صاف ہو جائے گی۔ جاری رکھیں؟",notifications:"اطلاعات",markAllAsRead:"سب کو پڑھا ہوا نشان زد کریں",noNotifications:"کوئی اطلاع نہیں",schemaConflictsDetected:"اسکیما تنازعات کا پتا چلا",schemaViolationsDetected:"اسکیما خلاف ورزیوں کا پتا چلا",properties:"خصوصیات",uploading:"اپ لوڈ ہو رہا ہے...",dropFilesOrBrowse:"فائلیں یہاں چھوڑیں یا براؤز کرنے کے لیے کلک کریں",acceptedTypes:e=>`قابل قبول اقسام: ${e}`,enterUrlPrompt:"URL درج کریں:",exceeded:"(حد سے تجاوز)",pdfPreview:"PDF پیش نظارہ",lexical:{fontFamily:"فونٹ فیملی",fontSize:"فونٹ سائز",lineHeight:"لائن کی اونچائی",fontColor:"فونٹ رنگ",highlightColor:"ہائی لائٹ رنگ",backgroundColor:"پس منظر رنگ",bold:"بولڈ",italic:"ترچھا",underline:"خط کشیدہ",strikethrough:"کٹا ہوا",code:"کوڈ",clearFormatting:"فارمیٹنگ صاف کریں",normal:"عام",heading:e=>`سرخی ${e}`,bulletList:"بلٹ فہرست",orderedList:"نمبر شدہ فہرست",checkList:"چیک فہرست",indent:"اندر کریں",outdent:"باہر کریں",blockquote:"اقتباس",codeBlock:"کوڈ بلاک",horizontalRule:"افقی لکیر",insertTable:"ٹیبل داخل کریں",link:"لنک",undo:"واپس",redo:"دوبارہ",cut:"کاٹیں",copy:"نقل",paste:"چسپاں",defaultOption:"پہلے سے طے شدہ",slashCommands:"سلیش کمانڈز",noCommandsFound:"کوئی کمانڈ نہیں ملی",changeBlockType:"بلاک کی قسم تبدیل کریں",blockTypes:"بلاک کی اقسام",enterUrl:"URL درج کریں:",tableActions:"Table actions",insertRowAbove:"Insert row above",insertRowBelow:"Insert row below",insertColumnLeft:"Insert column left",insertColumnRight:"Insert column right",deleteRow:"Delete row",deleteColumn:"Delete column",deleteTable:"Delete table"},dataTable:{sortAscending:"صعودی ترتیب",sortDescending:"نزولی ترتیب",clearSort:"ترتیب صاف کریں",filterPlaceholder:"فلٹر...",clearFilter:"فلٹر صاف کریں",selectAll:"سب منتخب کریں",deselectAll:"سب غیر منتخب کریں",selectedCount:e=>`${e} منتخب`,resetAll:"سب ری سیٹ کریں",noResults:"کوئی نتائج نہیں ملے",loading:"لوڈ ہو رہا ہے...",filterPanelAddCondition:"شرط شامل کریں",filterPanelApply:"لاگو کریں",filterPanelClear:"فلٹرز صاف کریں",filterPanelAnd:"اور",filterPanelOr:"یا",filterPanelContains:"شامل ہے",filterPanelNotContains:"شامل نہیں ہے",filterPanelEquals:"برابر ہے",filterPanelNotEquals:"برابر نہیں ہے",filterPanelStartsWith:"سے شروع ہوتا ہے",filterPanelEndsWith:"پر ختم ہوتا ہے",filterPanelIsNull:"خالی ہے",filterPanelIsNotNull:"خالی نہیں ہے",filterPanelGt:"سے بڑا",filterPanelGte:"سے بڑا یا برابر",filterPanelLt:"سے چھوٹا",filterPanelLte:"سے چھوٹا یا برابر",filterPanelBetween:"کے درمیان",filterPanelValuePlaceholder:"قدر...",sortMultiHint:"متعدد کالموں کو ترتیب دینے کے لیے Shift دبائیں",columnVisibility:"کالم",showAllColumns:"سب دکھائیں",menuSortAsc:"صعودی ترتیب",menuSortDesc:"نزولی ترتیب",menuClearSort:"ترتیب ہٹائیں",menuHideColumn:"کالم چھپائیں",menuChooseColumns:"کالم منتخب کریں",menuResetColumns:"کالم ری سیٹ کریں",menuFilter:"فلٹر",rowCount:(e,t)=>`قطاریں: ${e} کل قطاریں: ${t}`,filterTagsPlaceholder:"قدریں منتخب کریں...",groupCount:e=>`${e} آئٹم`,collapseGroup:"گروپ سکیڑیں",expandGroup:"گروپ پھیلائیں",describeFilter:{textContains:(e,t)=>`${e} "${t}" پر مشتمل`,textNotContains:(e,t)=>`${e} "${t}" پر مشتمل نہیں`,textEquals:(e,t)=>`${e} "${t}" کے برابر`,textNotEquals:(e,t)=>`${e} "${t}" کے برابر نہیں`,textStartsWith:(e,t)=>`${e} "${t}" سے شروع ہوتا ہے`,textEndsWith:(e,t)=>`${e} "${t}" پر ختم ہوتا ہے`,compareEq:(e,t)=>`${e} = ${t}`,compareNeq:(e,t)=>`${e} ≠ ${t}`,compareGt:(e,t)=>`${e} > ${t}`,compareGte:(e,t)=>`${e} ≥ ${t}`,compareLt:(e,t)=>`${e} < ${t}`,compareLte:(e,t)=>`${e} ≤ ${t}`,rangeBetween:(e,t,l)=>`${e} ${t} اور ${l} کے درمیان`,rangeGte:(e,t)=>`${e} ≥ ${t}`,rangeLte:(e,t)=>`${e} ≤ ${t}`,setIn:(e,t)=>`${e} [${t}] میں`,setNotIn:(e,t)=>`${e} [${t}] میں نہیں`,booleanIs:(e,t)=>`${e} ${t} ہے`,isNull:e=>`${e} خالی ہے`,isNotNull:e=>`${e} خالی نہیں ہے`,compositeAnd:e=>e.join(" اور "),compositeOr:e=>e.join(" یا ")}},prosemirror:{bold:"Bold",italic:"Italic",code:"Code",link:"Link",removeLink:"Remove Link",heading:e=>`Heading ${e}`,bulletList:"Bullet List",orderedList:"Ordered List",blockquote:"Blockquote",codeBlock:"Code Block",horizontalRule:"Horizontal Rule",linkUrlPlaceholder:"https://example.com"},carousel:{label:"کیروسیل",previousSlide:"پچھلی سلائیڈ",nextSlide:"اگلی سلائیڈ",slideNavigation:"سلائیڈ نیویگیشن",slideOfTotal:(e,t)=>`سلائیڈ ${e} از ${t}`,goToSlide:e=>`سلائیڈ ${e} پر جائیں`},datePicker:{label:"تاریخ منتخب کریں",previousYear:"پچھلا سال",previousMonth:"پچھلا مہینہ",selectMonth:"مہینہ منتخب کریں",selectYear:"سال منتخب کریں",nextMonth:"اگلا مہینہ",nextYear:"اگلا سال",previousYears:e=>`پچھلے ${e} سال`,nextYears:e=>`اگلے ${e} سال`,dateRangePickerLabel:"تاریخ کی حد منتخب کریں",monthNames:["جنوری","فروری","مارچ","اپریل","مئی","جون","جولائی","اگست","ستمبر","اکتوبر","نومبر","دسمبر"],shortMonthNames:["جنو","فرو","مار","اپر","مئی","جون","جول","اگس","ستم","اکت","نوم","دسم"],dayNames:["اتو","پیر","منگ","بدھ","جمع","جمعہ","ہفت"]},timePicker:{label:"وقت منتخب کنندہ",hoursLabel:"HH",minutesLabel:"MM",secondsLabel:"SS",selectHours:"گھنٹے منتخب کریں",selectMinutes:"منٹ منتخب کریں",selectSeconds:"سیکنڈ منتخب کریں",selectPeriod:"AM/PM منتخب کریں",nowLabel:"ابھی"},timeSelectTime:"وقت منتخب کریں",dateTimeSelectDateTime:"تاریخ اور وقت منتخب کریں",colorPicker:{hue:"رنگت",saturation:"سنترپشن",lightness:"چمک",alpha:"الفا",red:"سرخ",green:"سبز",blue:"نیلا",hex:"Hex",whiteness:"سفیدی",blackness:"سیاہی",chroma:"کروما"},spotlight:{placeholder:"تلاش کریں...",noResults:"کوئی نتائج نہیں ملے",recentItems:"حالیہ",close:"بند کریں"},virtualList:{listLabel:"سکرول کے قابل فہرست"},stepper:{step:"مرحلہ",stepOfTotal:(e,t)=>`مرحلہ ${e} از ${t}`,completed:"مکمل",next:"اگلا",previous:"پچھلا",complete:"مکمل کریں"},sortableList:{dragHandle:"ترتیب بدلنے کے لیے گھسیٹیں"},transferList:{available:"دستیاب",selected:"منتخب",moveRight:"منتخب میں منتقل کریں",moveLeft:"دستیاب میں منتقل کریں",moveAllRight:"سب منتخب میں منتقل کریں",moveAllLeft:"سب دستیاب میں منتقل کریں",searchAvailable:"دستیاب آئٹمز تلاش کریں…",searchSelected:"منتخب آئٹمز تلاش کریں…"},copyButton:{copied:"کاپی ہو گیا!",copyToClipboard:"کلپ بورڈ پر کاپی کریں"},numberStepper:{increment:"بڑھائیں",decrement:"گھٹائیں",value:"قدر"},statCard:{trendUp:"بڑھتا رجحان",trendDown:"گرتا رجحان",trendFlat:"کوئی تبدیلی نہیں"},otpInputLabel:"ایک بار کا پاس ورڈ درج کریں",otpDigitLabel:(e,t)=>`ہندسہ ${e} از ${t}`,scrollableGridView:"سکرول ایبل گرڈ ویو",onboardingTour:{label:"رہنمائی ٹور",stepIndicator:(e,t)=>`مرحلہ ${e} از ${t}`,skip:"چھوڑیں",previous:"پچھلا",next:"اگلا",finish:"مکمل"},searchPlaceholder:"تلاش کریں",pdfPageViewer:{loading:"Loading PDF...",loadFailed:"Failed to load PDF",invalidPdf:"Invalid PDF file",pageOutOfRange:(e,t)=>`Page ${e} is out of range (1-${t})`,renderFailed:"Failed to render PDF page"}};exports.default=r;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const i=require("./translations-D3xqZUTA.cjs"),r={loadingExtended:"لوڈ ہو رہا ہے، براہ کرم انتظار کریں",loadingShort:"لوڈ ہو رہا ہے...",locale:"زبان",iconDescription:"آئیکن",loadingIcon:"لوڈنگ آئیکن",failedToLoadIcon:"آئیکن لوڈ کرنے میں ناکام",editLabel:"ترمیم",selectOne:"ایک منتخب کریں",selectNone:"کوئی نہیں",selectMany:"متعدد منتخب کریں",noResults:"کوئی نتیجہ نہیں",passwordPlaceholderText:"خفیہ پاس ورڈ",togglePasswordVisibility:"پاس ورڈ کی مرئیت تبدیل کریں",toggleMenu:"مینو ٹوگل کریں",toggleAside:"سائیڈ پینل ٹوگل کریں",mainNavigation:"بنیادی نیویگیشن",sidebar:"سائیڈ بار",closeDrawer:"دراز بند کریں",closeModal:"ماڈل بند کریں",confirm:"تصدیق",cancel:"منسوخ",addLabel:"شامل کریں",removeItem:"آئٹم ہٹائیں",currentLocale:"اردو",ar:"عربی",de:"جرمن",en:"انگریزی",es:"ہسپانوی",fr:"فرانسیسی",he:"عبرانی",hi:"ہندی",it:"اطالوی",ja:"جاپانی",ko:"کوریائی",nl:"ڈچ",pl:"پولش",pt:"پرتگالی",ru:"روسی",tr:"ترکی",vi:"ویتنامی",zh:"چینی",fa:"فارسی",ur:"اردو",emailPlaceholderText:"اپنا ای میل داخل کریں",incrementValue:"قدر اضافہ کریں",decrementValue:"قدر کم کریں",dropZoneInstructions:e=>e?"منتخب کرنے کے لیے کلک کریں یا فائلیں یہاں گھسیٹیں، یا فائل منتخب کرنے کے لیے Enter یا Space دبائیں":"فائلیں یہاں گھسیٹیں",fileSizeUnits:["بائٹس","KB","MB","GB","TB"],removeFile:"فائل حذف کریں",clearAllFiles:"تمام فائلیں صاف کریں",clearValue:"قدر صاف کریں",dateRangeStart:"Start",dateRangeEnd:"End",dateRangeNoLimit:"No limit",dateRangeSelectDate:"Select date",unknownType:"نامعلوم قسم",filesInputInstructions:(e,t,l)=>{let o=e==null||e>1?"منتخب کرنے کے لیے کلک کریں یا فائلیں یہاں گھسیٹیں":"منتخب کرنے کے لیے کلک کریں یا فائل یہاں گھسیٹیں";if(e||t){const n=[];if(e!=null&&e>1&&n.push(`زیادہ سے زیادہ ${e} فائلیں`),t&&l){const a=i.formatFileSize(t,{units:l});n.push(`ہر ایک زیادہ سے زیادہ ${a}`)}n.length>0&&(o+=` (${n.join("، ")})`)}return o},paginationLabel:"صفحہ بندی",paginationRange:(e,t,l,o)=>o>l?`قطاریں ${e} سے ${t} تک، ${l} میں سے ${o} میں سے`:`قطاریں ${e} سے ${t} تک، ${l} میں سے`,firstPage:"پہلا صفحہ",previousPage:"پچھلا صفحہ",nextPage:"اگلا صفحہ",lastPage:"آخری صفحہ",breadcrumbs:"بریڈ کرمبز",commandPalette:"کمانڈ پیلیٹ",typeACommand:"کمانڈ ٹائپ کریں...",noResultsFound:"کوئی نتیجہ نہیں ملا",noMatchingCommands:"کوئی مماثل کمانڈ نہیں ملی",appearanceSystem:"سسٹم",appearanceLight:"ہلکا",appearanceDark:"گہرا",ok:"OK",changeTypeConfirmation:"قسم تبدیل کرنے سے موجودہ قدر صاف ہو جائے گی۔ جاری رکھیں؟",notifications:"اطلاعات",markAllAsRead:"سب کو پڑھا ہوا نشان زد کریں",noNotifications:"کوئی اطلاع نہیں",schemaConflictsDetected:"اسکیما تنازعات کا پتا چلا",schemaViolationsDetected:"اسکیما خلاف ورزیوں کا پتا چلا",properties:"خصوصیات",uploading:"اپ لوڈ ہو رہا ہے...",dropFilesOrBrowse:"فائلیں یہاں چھوڑیں یا براؤز کرنے کے لیے کلک کریں",acceptedTypes:e=>`قابل قبول اقسام: ${e}`,enterUrlPrompt:"URL درج کریں:",exceeded:"(حد سے تجاوز)",pdfPreview:"PDF پیش نظارہ",lexical:{fontFamily:"فونٹ فیملی",fontSize:"فونٹ سائز",lineHeight:"لائن کی اونچائی",fontColor:"فونٹ رنگ",highlightColor:"ہائی لائٹ رنگ",backgroundColor:"پس منظر رنگ",bold:"بولڈ",italic:"ترچھا",underline:"خط کشیدہ",strikethrough:"کٹا ہوا",code:"کوڈ",clearFormatting:"فارمیٹنگ صاف کریں",normal:"عام",heading:e=>`سرخی ${e}`,bulletList:"بلٹ فہرست",orderedList:"نمبر شدہ فہرست",checkList:"چیک فہرست",indent:"اندر کریں",outdent:"باہر کریں",blockquote:"اقتباس",codeBlock:"کوڈ بلاک",horizontalRule:"افقی لکیر",insertTable:"ٹیبل داخل کریں",link:"لنک",undo:"واپس",redo:"دوبارہ",cut:"کاٹیں",copy:"نقل",paste:"چسپاں",defaultOption:"پہلے سے طے شدہ",slashCommands:"سلیش کمانڈز",noCommandsFound:"کوئی کمانڈ نہیں ملی",changeBlockType:"بلاک کی قسم تبدیل کریں",blockTypes:"بلاک کی اقسام",enterUrl:"URL درج کریں:",tableActions:"Table actions",insertRowAbove:"Insert row above",insertRowBelow:"Insert row below",insertColumnLeft:"Insert column left",insertColumnRight:"Insert column right",deleteRow:"Delete row",deleteColumn:"Delete column",deleteTable:"Delete table"},dataTable:{sortAscending:"صعودی ترتیب",sortDescending:"نزولی ترتیب",clearSort:"ترتیب صاف کریں",filterPlaceholder:"فلٹر...",clearFilter:"فلٹر صاف کریں",selectAll:"سب منتخب کریں",deselectAll:"سب غیر منتخب کریں",selectedCount:e=>`${e} منتخب`,resetAll:"سب ری سیٹ کریں",noResults:"کوئی نتائج نہیں ملے",loading:"لوڈ ہو رہا ہے...",filterPanelAddCondition:"شرط شامل کریں",filterPanelApply:"لاگو کریں",filterPanelClear:"فلٹرز صاف کریں",filterPanelAnd:"اور",filterPanelOr:"یا",filterPanelContains:"شامل ہے",filterPanelNotContains:"شامل نہیں ہے",filterPanelEquals:"برابر ہے",filterPanelNotEquals:"برابر نہیں ہے",filterPanelStartsWith:"سے شروع ہوتا ہے",filterPanelEndsWith:"پر ختم ہوتا ہے",filterPanelIsNull:"خالی ہے",filterPanelIsNotNull:"خالی نہیں ہے",filterPanelGt:"سے بڑا",filterPanelGte:"سے بڑا یا برابر",filterPanelLt:"سے چھوٹا",filterPanelLte:"سے چھوٹا یا برابر",filterPanelBetween:"کے درمیان",filterPanelValuePlaceholder:"قدر...",sortMultiHint:"متعدد کالموں کو ترتیب دینے کے لیے Shift دبائیں",columnVisibility:"کالم",showAllColumns:"سب دکھائیں",menuSortAsc:"صعودی ترتیب",menuSortDesc:"نزولی ترتیب",menuClearSort:"ترتیب ہٹائیں",menuHideColumn:"کالم چھپائیں",menuChooseColumns:"کالم منتخب کریں",menuResetColumns:"کالم ری سیٹ کریں",menuFilter:"فلٹر",rowCount:(e,t)=>`قطاریں: ${e} کل قطاریں: ${t}`,filterTagsPlaceholder:"قدریں منتخب کریں...",groupCount:e=>`${e} آئٹم`,collapseGroup:"گروپ سکیڑیں",expandGroup:"گروپ پھیلائیں",describeFilter:{textContains:(e,t)=>`${e} "${t}" پر مشتمل`,textNotContains:(e,t)=>`${e} "${t}" پر مشتمل نہیں`,textEquals:(e,t)=>`${e} "${t}" کے برابر`,textNotEquals:(e,t)=>`${e} "${t}" کے برابر نہیں`,textStartsWith:(e,t)=>`${e} "${t}" سے شروع ہوتا ہے`,textEndsWith:(e,t)=>`${e} "${t}" پر ختم ہوتا ہے`,compareEq:(e,t)=>`${e} = ${t}`,compareNeq:(e,t)=>`${e} ≠ ${t}`,compareGt:(e,t)=>`${e} > ${t}`,compareGte:(e,t)=>`${e} ≥ ${t}`,compareLt:(e,t)=>`${e} < ${t}`,compareLte:(e,t)=>`${e} ≤ ${t}`,rangeBetween:(e,t,l)=>`${e} ${t} اور ${l} کے درمیان`,rangeGte:(e,t)=>`${e} ≥ ${t}`,rangeLte:(e,t)=>`${e} ≤ ${t}`,setIn:(e,t)=>`${e} [${t}] میں`,setNotIn:(e,t)=>`${e} [${t}] میں نہیں`,booleanIs:(e,t)=>`${e} ${t} ہے`,isNull:e=>`${e} خالی ہے`,isNotNull:e=>`${e} خالی نہیں ہے`,compositeAnd:e=>e.join(" اور "),compositeOr:e=>e.join(" یا ")}},prosemirror:{bold:"Bold",italic:"Italic",code:"Code",link:"Link",removeLink:"Remove Link",heading:e=>`Heading ${e}`,bulletList:"Bullet List",orderedList:"Ordered List",blockquote:"Blockquote",codeBlock:"Code Block",horizontalRule:"Horizontal Rule",linkUrlPlaceholder:"https://example.com"},carousel:{label:"کیروسیل",previousSlide:"پچھلی سلائیڈ",nextSlide:"اگلی سلائیڈ",slideNavigation:"سلائیڈ نیویگیشن",slideOfTotal:(e,t)=>`سلائیڈ ${e} از ${t}`,goToSlide:e=>`سلائیڈ ${e} پر جائیں`},datePicker:{label:"تاریخ منتخب کریں",previousYear:"پچھلا سال",previousMonth:"پچھلا مہینہ",selectMonth:"مہینہ منتخب کریں",selectYear:"سال منتخب کریں",nextMonth:"اگلا مہینہ",nextYear:"اگلا سال",previousYears:e=>`پچھلے ${e} سال`,nextYears:e=>`اگلے ${e} سال`,dateRangePickerLabel:"تاریخ کی حد منتخب کریں",monthNames:["جنوری","فروری","مارچ","اپریل","مئی","جون","جولائی","اگست","ستمبر","اکتوبر","نومبر","دسمبر"],shortMonthNames:["جنو","فرو","مار","اپر","مئی","جون","جول","اگس","ستم","اکت","نوم","دسم"],dayNames:["اتو","پیر","منگ","بدھ","جمع","جمعہ","ہفت"]},timePicker:{label:"وقت منتخب کنندہ",hoursLabel:"HH",minutesLabel:"MM",secondsLabel:"SS",selectHours:"گھنٹے منتخب کریں",selectMinutes:"منٹ منتخب کریں",selectSeconds:"سیکنڈ منتخب کریں",selectPeriod:"AM/PM منتخب کریں",nowLabel:"ابھی"},timeSelectTime:"وقت منتخب کریں",dateTimeSelectDateTime:"تاریخ اور وقت منتخب کریں",colorPicker:{hue:"رنگت",saturation:"سنترپشن",lightness:"چمک",alpha:"الفا",red:"سرخ",green:"سبز",blue:"نیلا",hex:"Hex",whiteness:"سفیدی",blackness:"سیاہی",chroma:"کروما"},spotlight:{placeholder:"تلاش کریں...",noResults:"کوئی نتائج نہیں ملے",recentItems:"حالیہ",close:"بند کریں"},virtualList:{listLabel:"سکرول کے قابل فہرست"},stepper:{step:"مرحلہ",stepOfTotal:(e,t)=>`مرحلہ ${e} از ${t}`,completed:"مکمل",next:"اگلا",previous:"پچھلا",complete:"مکمل کریں"},sortableList:{dragHandle:"ترتیب بدلنے کے لیے گھسیٹیں"},transferList:{available:"دستیاب",selected:"منتخب",moveRight:"منتخب میں منتقل کریں",moveLeft:"دستیاب میں منتقل کریں",moveAllRight:"سب منتخب میں منتقل کریں",moveAllLeft:"سب دستیاب میں منتقل کریں",searchAvailable:"دستیاب آئٹمز تلاش کریں…",searchSelected:"منتخب آئٹمز تلاش کریں…"},copyButton:{copied:"کاپی ہو گیا!",copyToClipboard:"کلپ بورڈ پر کاپی کریں"},numberStepper:{increment:"بڑھائیں",decrement:"گھٹائیں",value:"قدر"},statCard:{trendUp:"بڑھتا رجحان",trendDown:"گرتا رجحان",trendFlat:"کوئی تبدیلی نہیں"},otpInputLabel:"ایک بار کا پاس ورڈ درج کریں",otpDigitLabel:(e,t)=>`ہندسہ ${e} از ${t}`,scrollableGridView:"سکرول ایبل گرڈ ویو",onboardingTour:{label:"رہنمائی ٹور",stepIndicator:(e,t)=>`مرحلہ ${e} از ${t}`,skip:"چھوڑیں",previous:"پچھلا",next:"اگلا",finish:"مکمل"},searchPlaceholder:"تلاش کریں",pdfPageViewer:{loading:"Loading PDF...",loadFailed:"Failed to load PDF",invalidPdf:"Invalid PDF file",pageOutOfRange:(e,t)=>`Page ${e} is out of range (1-${t})`,renderFailed:"Failed to render PDF page"}};exports.default=r;
@@ -0,0 +1,2 @@
1
+ "use strict";const l=require("@tempots/dom"),d=require("@tempots/std");function j(i){return i.split(".").map(e=>{const s=e.match(/^\[(\d+)\]$/);return s?Number(s[1]):e})}function C(i){return typeof i=="number"?`[${i}]`:`.${i}`}function w(i){if(i.length===0)return"";const[t,...e]=i;return[typeof t=="number"?`[${t}]`:t,...e.map(C)].join("")}const I={valid:d.Validation.valid,invalid(i){return d.Validation.invalid({message:i})},invalidFields(i){const t={};for(const[e,s]of Object.entries(i))t[e]=typeof s=="string"?{message:s}:s;return d.Validation.invalid({dependencies:t})},fromError(i){return d.Validation.invalid(i)}};function b(i){return function(e){if(e.type==="valid")return e;let s=e.error;for(const n of i)if(s=s?.dependencies?.[n],s==null)return d.Validation.valid;return d.Validation.invalid(s)}}class g{path;change;signal;status;error;hasError;touched;errorVisible;dirty;dependencyErrors;#t={disabled:l.prop(!1),touched:l.prop(!1)};#s;#e=l.prop(void 0);parent;disabled;#i=[];disabledOrHasErrors;constructor(t,e,s,n,c,o=d.strictEqual){this.path=t,this.change=e,this.signal=s,this.status=n,this.#s=o,this.#e.set(s.value),this.error=n.map(a=>a?.type==="invalid"?a.error?.message:void 0),this.hasError=this.error.map(a=>a!=null),this.touched=this.#t.touched,c.validationMode?this.errorVisible=l.computedOf(this.hasError,this.touched,c.validationMode)((a,r,u)=>u==="eager"?!!a:!!a&&!!r):this.errorVisible=l.computedOf(this.hasError,this.touched)((a,r)=>!!a&&!!r),this.dirty=l.computedOf(this.signal,this.#e)((a,r)=>!this.#s(a,r)),this.dependencyErrors=n.map(a=>a?.type==="invalid"?a.error?.dependencies:void 0),this.parent=c,this.disabled=l.computedOf(this.#t.disabled,c.disabled)((a,r)=>a||r),this.disabledOrHasErrors=l.computedOf(this.disabled,this.hasError)((a,r)=>a||r),this.onDispose(()=>{this.#t.disabled.dispose(),this.#t.touched.dispose(),this.disabled.dispose(),this.error.dispose(),this.errorVisible.dispose(),this.dirty.dispose(),this.#e.dispose(),this.dependencyErrors.dispose(),this.disabledOrHasErrors.dispose()})}get name(){return w(this.path)}onDispose=t=>{this.#i.push(t)};dispose=()=>{for(const t of this.#i)try{t()}catch(e){console.error("Error in dispose callback:",e)}this.#i.length=0};setDisabled=t=>{this.#t.disabled.set(t)};disable=()=>this.setDisabled(!0);enable=()=>this.setDisabled(!1);markTouched=()=>{this.#t.touched.set(!0)};resetTouched=()=>{this.#t.touched.set(!1)};markPristine=()=>{this.#e.set(this.signal.value)};reset=()=>{this.change(this.#e.value)};array=(t=d.strictEqual)=>new E(this.path,this.change,this.signal,this.status,this.parent,t);object=(t=d.strictEqual)=>new S(this.path,this.change,this.signal,this.status,this.parent,t);transform=(t,e,s=[],n=d.strictEqual)=>new g([...this.path,...s],c=>this.change(e(c)),this.signal.map(t,n),this.status.map(b(s)),this.parent,n);asyncTransform=(t,e,s,n=[],c=d.strictEqual)=>new g([...this.path,...n],o=>{e(o).then(a=>this.change(a))},this.signal.mapAsync(t,s,void 0,c),this.status.map(b(n)),this.parent,c)}class S extends g{#t=new Map;#s=new Map;#e=new Map;#i=l.prop(!1);touchedDeep=this.#i;#a=new Map;#n=new Map;#o=l.prop(!1);dirtyDeep=this.#o;#c;#h;#l=()=>{let t=!1;for(const e of this.#s.values())if(e){t=!0;break}this.#i.set(this.touched.value||t)};constructor(t,e,s,n,c,o){super(t,e,s.map(r=>r??{},o),n,c,o),this.#c=this.touched.on(()=>{this.#l()}),this.#h=this.dirty.on(()=>{this.#r()});const a=this.signal.on(()=>this.#r());this.onDispose(()=>{for(const r of this.#t.values())r.dispose();this.#t.clear();for(const r of this.#e.values())r();this.#e.clear(),this.#s.clear(),this.#i.dispose();for(const r of this.#n.values())r();this.#n.clear(),this.#a.clear(),this.#o.dispose(),this.#c(),this.#h(),a()})}field=t=>{if(this.#t.has(t))return this.#t.get(t);const e=async o=>{this.change({...this.signal.value,[t]:o})},s=new g([...this.path,t],e,this.signal.map(o=>o[t]),this.status.map(b([t])),{disabled:this.disabled,validationMode:this.parent.validationMode});this.#t.set(t,s);const n=s.touched.on(o=>{this.#s.set(t,o),this.#l()});this.#e.set(t,n);const c=s.dirty.on(o=>{this.#a.set(t,o),this.#r()});return this.#n.set(t,c),s};markAllTouched=()=>{this.markTouched();const t=this.signal.value;for(const e of Object.keys(t))this.field(e).markTouched();for(const e of this.#t.values())e.markTouched()};markAllPristine=()=>{this.markPristine();const t=this.signal.value;for(const e of Object.keys(t))this.field(e).markPristine?.();for(const e of this.#t.values())e.markPristine?.()};#r=()=>{let t=!1;for(const e of this.#a.values())if(e){t=!0;break}this.#o.set(this.dirty.value||t)}}class E extends g{#t=new Array;length;#s=new Map;#e=new Map;#i=l.prop(!1);touchedDeep=this.#i;#a=new Map;#n=new Map;#o=l.prop(!1);dirtyDeep=this.#o;#c;#h;#l=()=>{let t=!1;for(const e of this.#s.values())if(e){t=!0;break}this.#i.set(this.touched.value||t)};constructor(t,e,s,n,c,o){const a=s.map(h=>h??[],o);super(t,e,a,n,c,o);const r=a.on(h=>{const p=this.#t.length-h.length;p>0&&(this.#t.splice(h.length,p).forEach((y,v)=>{const f=h.length+v;y.dispose(),this.#e.get(f)?.(),this.#e.delete(f),this.#s.delete(f),this.#n.get(f)?.(),this.#n.delete(f),this.#a.delete(f)}),this.#l(),this.#r())});this.length=a.map(h=>h.length),this.#c=this.touched.on(()=>{this.#l()}),this.#h=this.dirty.on(()=>{this.#r()});const u=this.signal.on(()=>this.#r());this.onDispose(()=>{for(const h of this.#t)h.dispose();this.length.dispose(),this.#t.length=0,r(),a.dispose();for(const h of this.#e.values())h();this.#e.clear(),this.#s.clear(),this.#i.dispose();for(const h of this.#n.values())h();this.#n.clear(),this.#a.clear(),this.#o.dispose(),this.#c(),this.#h(),u()})}item=t=>{if(this.#t[t])return this.#t[t];const e=async o=>{const a=this.signal.value.slice();a[t]=o,this.change(a)},s=new g([...this.path,t],e,this.signal.map(o=>o[t]),this.status.map(b([t])),{disabled:this.disabled,validationMode:this.parent.validationMode});this.#t[t]=s;const n=s.touched.on(o=>{this.#s.set(t,o),this.#l()});this.#e.set(t,n);const c=s.dirty.on(o=>{this.#a.set(t,o),this.#r()});return this.#n.set(t,c),s};push=(...t)=>{this.change([...this.signal.value,...t])};pop=()=>{this.splice(this.signal.value.length-1,1)};shift=()=>{this.splice(0,1)};unshift=(...t)=>{this.change([...t,...this.signal.value])};removeAt=t=>{this.splice(t,1)};splice=(t,e)=>{const s=this.signal.value.slice();s.splice(t,e),this.change(s)};move=(t,e,s=1)=>{if(s<1||t===e)return;const n=this.signal.value.slice(),c=n.splice(t,s);n.splice(e,0,...c),this.change(n)};markAllTouched=()=>{this.markTouched();const t=this.signal.value.length;for(let e=0;e<t;e++)this.item(e).markTouched()};markAllPristine=()=>{this.markPristine();const t=this.signal.value.length;for(let e=0;e<t;e++)this.item(e).markPristine?.()};#r=()=>{let t=!1;for(const e of this.#a.values())if(e){t=!0;break}this.#o.set(this.dirty.value||t)}}function M(i){function t(e){return typeof e=="number"?e:e.toString()}return i.map(e=>typeof e=="object"&&e.key!=null?t(e.key):t(e))}function A(i){const t=i.filter(n=>n.path==null||n.path.length===0).map(n=>n.message),e=i.filter(n=>n.path!=null&&n.path.length>0).reduce((n,c)=>{const o=M(c.path),a=o.pop();let r=n;for(const u of o)r.dependencies==null&&(r.dependencies={}),r.dependencies[u]==null&&(r.dependencies[u]={}),r=r.dependencies[u];return r.dependencies==null&&(r.dependencies={}),r.dependencies[a]={message:c.message},n},{}),s=t.join(`
2
+ `);return{...e,message:s!=""?s:void 0}}function O({initialValue:i,onChange:t,validate:e,equals:s,validationMode:n,validateDebounceMs:c}){const o=l.Value.deriveProp(i),a=l.prop(d.Validation.valid),r=l.prop(!1),u=l.prop(n??"onTouched"),h=m=>{a.set(m)};let p;const y=async m=>{if(e!=null){const k=await e(m);h(k)}},v=async m=>{o.set(m),t?.(m);const k=u.value;if(e!=null){if(k==="onSubmit")return;const V=c??0;V>0?(p&&clearTimeout(p),p=setTimeout(()=>{y(m)},V)):await y(m)}},f=new g([],v,o,a,{disabled:r,validationMode:u},s??d.strictEqual);return f.onDispose(()=>{r.dispose(),o.dispose(),a.dispose(),u.dispose(),p&&clearTimeout(p)}),{controller:f,setStatus:h}}function T(i){return l.Fragment(l.attr.disabled(i.disabled),l.attr.name(i.name))}function F(i,{triggerOn:t="change"}={}){return l.Fragment(T(i),l.attr.value(i.signal),(t==="input"?l.on.input:l.on.change)(l.emitValue(i.change)))}function N(i,{triggerOn:t="change"}={}){return l.Fragment(T(i),l.attr.valueAsNumber(i.signal),(t==="input"?l.on.input:l.on.change)(l.emitValueAsNumber(i.change)))}function D(i){return i.issues!=null?d.Validation.invalid(A(i.issues)):d.Validation.valid}async function q({task:i,errorMessage:t,errorPath:e=["root"],validation:s}){try{const n=await i();return s!=null?s(n):d.Validation.valid}catch(n){const c=t??(n instanceof Error?n.message:"Operation failed");return e.length===1&&e[0]==="root"?d.Validation.invalid({message:c}):d.Validation.invalid({dependencies:P(e,c)})}}function P(i,t){if(i.length===1)return{[i[0]]:{message:t}};const[e,...s]=i;return{[e]:{dependencies:P(s,t)}}}function H({initialValue:i={},schema:t,onSubmit:e=async()=>d.Validation.valid,validationMode:s,validateDebounceMs:n}){const{controller:c,setStatus:o}=O({initialValue:i,validationMode:s??"onTouched",validateDebounceMs:n,validate:(s??"onTouched")==="onSubmit"||t==null?void 0:async h=>D(await t["~standard"].validate(h))}),a=l.prop(!1),r=c.object();return r.onDispose(()=>a.dispose()),{controller:r,setStatus:o,submit:async h=>{if(a.set(!0),h?.preventDefault(),r.markAllTouched(),t!=null){const y=r.signal.value,v=D(await t["~standard"].validate(y));if(o(v),v.type==="invalid"){a.set(!1);return}}const p=await e(r.signal.value);a.set(!1),p.type==="invalid"&&o(p)},submitting:a}}exports.ArrayController=E;exports.Controller=g;exports.ControllerValidation=I;exports.ObjectController=S;exports.connectCommonAttributes=T;exports.connectNumberInput=N;exports.connectStringInput=F;exports.convertStandardSchemaIssues=A;exports.convertStandardSchemaPathToPath=M;exports.makeMapValidation=b;exports.parsePath=j;exports.pathToString=w;exports.standardSchemaResultToValidation=D;exports.taskToValidation=q;exports.useController=O;exports.useForm=H;exports.wrapSegment=C;