@vritti/quantum-ui 0.1.11 → 0.1.15

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 (53) hide show
  1. package/dist/Button.js +3 -43
  2. package/dist/Button.js.map +1 -1
  3. package/dist/Checkbox.d.ts +10 -1
  4. package/dist/Checkbox.js +35 -7
  5. package/dist/Checkbox.js.map +1 -1
  6. package/dist/Form.d.ts +263 -0
  7. package/dist/Form.js +683 -0
  8. package/dist/Form.js.map +1 -0
  9. package/dist/OTPField.d.ts +3 -3
  10. package/dist/OTPField.js +135 -0
  11. package/dist/OTPField.js.map +1 -0
  12. package/dist/PasswordField.d.ts +3 -3
  13. package/dist/PasswordField.js +63 -57
  14. package/dist/PasswordField.js.map +1 -1
  15. package/dist/PhoneField.d.ts +3 -3
  16. package/dist/PhoneField.js +55 -58
  17. package/dist/PhoneField.js.map +1 -1
  18. package/dist/TextArea.d.ts +11 -0
  19. package/dist/TextArea.js +54 -0
  20. package/dist/TextArea.js.map +1 -0
  21. package/dist/TextField.d.ts +3 -3
  22. package/dist/TextField.js +26 -39
  23. package/dist/TextField.js.map +1 -1
  24. package/dist/assets/quantum-ui.css +8 -0
  25. package/dist/components/Form.d.ts +2 -0
  26. package/dist/components/Form.js +3 -0
  27. package/dist/components/Form.js.map +1 -0
  28. package/dist/components/OTPField.js +1 -134
  29. package/dist/components/OTPField.js.map +1 -1
  30. package/dist/components/Progress.js +2 -2
  31. package/dist/components/TextArea.d.ts +2 -0
  32. package/dist/components/TextArea.js +2 -0
  33. package/dist/components/TextArea.js.map +1 -0
  34. package/dist/field.js +431 -0
  35. package/dist/field.js.map +1 -0
  36. package/dist/index.d.ts +296 -8
  37. package/dist/index.js +4 -0
  38. package/dist/index.js.map +1 -1
  39. package/dist/index2.js +116 -54
  40. package/dist/index2.js.map +1 -1
  41. package/dist/index3.js +42 -38
  42. package/dist/index3.js.map +1 -1
  43. package/dist/index4.js +54 -116
  44. package/dist/index4.js.map +1 -1
  45. package/dist/index5.js +41 -0
  46. package/dist/index5.js.map +1 -0
  47. package/dist/shadcn/shadcnField.d.ts +1 -0
  48. package/dist/shadcn/shadcnField.js +2 -0
  49. package/dist/shadcn/shadcnField.js.map +1 -0
  50. package/dist/shadcnField.d.ts +1 -0
  51. package/package.json +20 -3
  52. package/dist/Label.js +0 -40
  53. package/dist/Label.js.map +0 -1
package/dist/index.d.ts CHANGED
@@ -1,11 +1,16 @@
1
1
  import * as CheckboxPrimitive from '@radix-ui/react-checkbox';
2
2
  import { ClassValue } from 'clsx';
3
3
  import { Context } from 'react';
4
+ import { Controller } from 'react-hook-form';
4
5
  import { Country } from 'react-phone-number-input';
5
6
  import { default as default_2 } from 'react';
7
+ import { FieldValues } from 'react-hook-form';
6
8
  import { isValidPhoneNumber } from 'react-phone-number-input';
9
+ import { JSX } from 'react/jsx-runtime';
10
+ import * as LabelPrimitive from '@radix-ui/react-label';
7
11
  import { Value as PhoneValue } from 'react-phone-number-input';
8
12
  import * as React_2 from 'react';
13
+ import { UseFormReturn } from 'react-hook-form';
9
14
  import { VariantProps } from 'class-variance-authority';
10
15
 
11
16
  export declare function Button({
@@ -92,7 +97,9 @@ export declare function CardTitle({ className, ...props }: React_2.ComponentProp
92
97
  return <div data-slot='card-title' className={cn('leading-none font-semibold', className)} {...props} />;
93
98
  }
94
99
 
95
- export declare function Checkbox({
100
+ export declare const Checkbox: default_2.ForwardRefExoticComponent<CheckboxProps & default_2.RefAttributes<HTMLButtonElement>>;
101
+
102
+ declare function Checkbox_2({
96
103
  className,
97
104
  ...props
98
105
  }: React_2.ComponentProps<typeof CheckboxPrimitive.Root>) {
@@ -115,12 +122,271 @@ export declare function Checkbox({
115
122
  )
116
123
  }
117
124
 
125
+ declare interface CheckboxProps extends default_2.ComponentPropsWithoutRef<typeof Checkbox_2> {
126
+ label?: default_2.ReactNode;
127
+ description?: default_2.ReactNode;
128
+ error?: string;
129
+ }
130
+
118
131
  export declare function cn(...inputs: ClassValue[]) {
119
132
  return twMerge(clsx(inputs));
120
133
  }
121
134
 
135
+ export { Controller }
136
+
137
+ export declare function Field({
138
+ className,
139
+ orientation = "vertical",
140
+ ...props
141
+ }: React.ComponentProps<"div"> & VariantProps<typeof fieldVariants>) {
142
+ return (
143
+ <div
144
+ role="group"
145
+ data-slot="field"
146
+ data-orientation={orientation}
147
+ className={cn(fieldVariants({ orientation }), className)}
148
+ {...props}
149
+ />
150
+ )
151
+ }
152
+
153
+ export declare function FieldContent({ className, ...props }: React.ComponentProps<"div">) {
154
+ return (
155
+ <div
156
+ data-slot="field-content"
157
+ className={cn(
158
+ "group/field-content flex flex-1 flex-col gap-1.5 leading-snug",
159
+ className
160
+ )}
161
+ {...props}
162
+ />
163
+ )
164
+ }
165
+
166
+ export declare function FieldDescription({ className, ...props }: React.ComponentProps<"p">) {
167
+ return (
168
+ <p
169
+ data-slot="field-description"
170
+ className={cn(
171
+ "text-muted-foreground text-sm leading-normal font-normal group-has-[[data-orientation=horizontal]]/field:text-balance",
172
+ "last:mt-0 nth-last-2:-mt-1 [[data-variant=legend]+&]:-mt-1.5",
173
+ "[&>a:hover]:text-primary [&>a]:underline [&>a]:underline-offset-4",
174
+ className
175
+ )}
176
+ {...props}
177
+ />
178
+ )
179
+ }
180
+
181
+ export declare function FieldError({
182
+ className,
183
+ children,
184
+ errors,
185
+ ...props
186
+ }: React.ComponentProps<"div"> & {
187
+ errors?: Array<{ message?: string } | undefined>
188
+ }) {
189
+ const content = useMemo(() => {
190
+ if (children) {
191
+ return children
192
+ }
193
+
194
+ if (!errors?.length) {
195
+ return null
196
+ }
197
+
198
+ if (errors?.length == 1) {
199
+ return errors[0]?.message
200
+ }
201
+
202
+ return (
203
+ <ul className="ml-4 flex list-disc flex-col gap-1">
204
+ {errors.map(
205
+ (error, index) =>
206
+ error?.message && <li key={index}>{error.message}</li>
207
+ )}
208
+ </ul>
209
+ )
210
+ }, [children, errors])
211
+
212
+ if (!content) {
213
+ return null
214
+ }
215
+
216
+ return (
217
+ <div
218
+ role="alert"
219
+ data-slot="field-error"
220
+ className={cn("text-destructive text-sm font-normal", className)}
221
+ {...props}
222
+ >
223
+ {content}
224
+ </div>
225
+ )
226
+ }
227
+
228
+ export declare function FieldGroup({ className, ...props }: React.ComponentProps<"div">) {
229
+ return (
230
+ <div
231
+ data-slot="field-group"
232
+ className={cn(
233
+ "group/field-group @container/field-group flex w-full flex-col gap-4 data-[slot=checkbox-group]:gap-3 [&>[data-slot=field-group]]:gap-4",
234
+ className
235
+ )}
236
+ {...props}
237
+ />
238
+ )
239
+ }
240
+
241
+ export declare function FieldLabel({
242
+ className,
243
+ ...props
244
+ }: React.ComponentProps<typeof Label>) {
245
+ return (
246
+ <Label
247
+ data-slot="field-label"
248
+ className={cn(
249
+ "group/field-label peer/field-label flex w-fit gap-2 leading-snug group-data-[disabled=true]/field:opacity-50",
250
+ "has-[>[data-slot=field]]:w-full has-[>[data-slot=field]]:flex-col has-[>[data-slot=field]]:rounded-md has-[>[data-slot=field]]:border [&>*]:data-[slot=field]:p-4",
251
+ "has-data-[state=checked]:bg-primary/5 has-data-[state=checked]:border-primary dark:has-data-[state=checked]:bg-primary/10",
252
+ className
253
+ )}
254
+ {...props}
255
+ />
256
+ )
257
+ }
258
+
259
+ export declare function FieldLegend({
260
+ className,
261
+ variant = "legend",
262
+ ...props
263
+ }: React.ComponentProps<"legend"> & { variant?: "legend" | "label" }) {
264
+ return (
265
+ <legend
266
+ data-slot="field-legend"
267
+ data-variant={variant}
268
+ className={cn(
269
+ "mb-3 font-medium",
270
+ "data-[variant=legend]:text-base",
271
+ "data-[variant=label]:text-sm",
272
+ className
273
+ )}
274
+ {...props}
275
+ />
276
+ )
277
+ }
278
+
279
+ export declare function FieldSeparator({
280
+ children,
281
+ className,
282
+ ...props
283
+ }: React.ComponentProps<"div"> & {
284
+ children?: React.ReactNode
285
+ }) {
286
+ return (
287
+ <div
288
+ data-slot="field-separator"
289
+ data-content={!!children}
290
+ className={cn(
291
+ "relative -my-2 h-5 text-sm group-data-[variant=outline]/field-group:-mb-2",
292
+ className
293
+ )}
294
+ {...props}
295
+ >
296
+ <Separator className="absolute inset-0 top-1/2" />
297
+ {children && (
298
+ <span
299
+ className="bg-background text-muted-foreground relative mx-auto block w-fit px-2"
300
+ data-slot="field-separator-content"
301
+ >
302
+ {children}
303
+ </span>
304
+ )}
305
+ </div>
306
+ )
307
+ }
308
+
309
+ export declare function FieldSet({ className, ...props }: React.ComponentProps<"fieldset">) {
310
+ return (
311
+ <fieldset
312
+ data-slot="field-set"
313
+ className={cn(
314
+ "flex flex-col gap-4",
315
+ "has-[>[data-slot=checkbox-group]]:gap-3 has-[>[data-slot=radio-group]]:gap-3",
316
+ className
317
+ )}
318
+ {...props}
319
+ />
320
+ )
321
+ }
322
+
323
+ export declare function FieldTitle({ className, ...props }: React.ComponentProps<"div">) {
324
+ return (
325
+ <div
326
+ data-slot="field-label"
327
+ className={cn(
328
+ "flex w-fit items-center gap-2 text-sm leading-snug font-medium group-data-[disabled=true]/field:opacity-50",
329
+ className
330
+ )}
331
+ {...props}
332
+ />
333
+ )
334
+ }
335
+
336
+ declare const fieldVariants = cva(
337
+ "group/field flex w-full gap-2 data-[invalid=true]:text-destructive",
338
+ {
339
+ variants: {
340
+ orientation: {
341
+ vertical: ["flex-col [&>*]:w-full [&>.sr-only]:w-auto"],
342
+ horizontal: [
343
+ "flex-row items-center",
344
+ "[&>[data-slot=field-label]]:flex-auto",
345
+ "has-[>[data-slot=field-content]]:items-start has-[>[data-slot=field-content]]:[&>[role=checkbox],[role=radio]]:mt-px",
346
+ ],
347
+ responsive: [
348
+ "flex-col [&>*]:w-full [&>.sr-only]:w-auto @md/field-group:flex-row @md/field-group:items-center @md/field-group:[&>*]:w-auto",
349
+ "@md/field-group:[&>[data-slot=field-label]]:flex-auto",
350
+ "@md/field-group:has-[>[data-slot=field-content]]:items-start @md/field-group:has-[>[data-slot=field-content]]:[&>[role=checkbox],[role=radio]]:mt-px",
351
+ ],
352
+ },
353
+ },
354
+ defaultVariants: {
355
+ orientation: "vertical",
356
+ },
357
+ }
358
+ );
359
+
360
+ export declare function Form<TFieldValues extends FieldValues = FieldValues>({ form, onSubmit, children, showRootError, rootErrorPosition, rootErrorClassName, ...props }: FormProps<TFieldValues>): JSX.Element;
361
+
362
+ export declare namespace Form {
363
+ var displayName: string;
364
+ }
365
+
366
+ export declare interface FormProps<TFieldValues extends FieldValues = FieldValues> extends Omit<default_2.FormHTMLAttributes<HTMLFormElement>, 'onSubmit'> {
367
+ form: UseFormReturn<TFieldValues>;
368
+ onSubmit: (data: TFieldValues) => void | Promise<void>;
369
+ children: default_2.ReactNode;
370
+ showRootError?: boolean;
371
+ rootErrorPosition?: 'top' | 'bottom';
372
+ rootErrorClassName?: string;
373
+ }
374
+
122
375
  export { isValidPhoneNumber }
123
376
 
377
+ declare function Label({ className, ...props }: React_2.ComponentProps<typeof LabelPrimitive.Root>) {
378
+ return (
379
+ <LabelPrimitive.Root
380
+ data-slot='label'
381
+ className={cn(
382
+ 'flex items-center gap-2 text-sm leading-none font-medium select-none group-data-[disabled=true]:pointer-events-none group-data-[disabled=true]:opacity-50 peer-disabled:cursor-not-allowed peer-disabled:opacity-50',
383
+ className
384
+ )}
385
+ {...props}
386
+ />
387
+ );
388
+ }
389
+
124
390
  export declare const OnboardingContext: Context<OnboardingContextType | undefined>;
125
391
 
126
392
  export declare interface OnboardingContextType extends OnboardingData {
@@ -147,7 +413,21 @@ declare interface OnboardingProviderProps {
147
413
  children: default_2.ReactNode;
148
414
  }
149
415
 
150
- export declare const PasswordField: default_2.FC<PasswordFieldProps>;
416
+ export declare const OTPField: default_2.ForwardRefExoticComponent<OTPFieldProps & default_2.RefAttributes<HTMLInputElement>>;
417
+
418
+ export declare interface OTPFieldProps {
419
+ value: string;
420
+ onChange: (value: string) => void;
421
+ length?: number;
422
+ label?: string;
423
+ description?: default_2.ReactNode;
424
+ error?: string;
425
+ disabled?: boolean;
426
+ required?: boolean;
427
+ className?: string;
428
+ }
429
+
430
+ export declare const PasswordField: default_2.ForwardRefExoticComponent<Omit<PasswordFieldProps, "ref"> & default_2.RefAttributes<HTMLInputElement>>;
151
431
 
152
432
  declare interface PasswordFieldProps extends Omit<TextFieldProps, 'type' | 'endAdornment'> {
153
433
  showStrengthIndicator?: boolean;
@@ -156,15 +436,15 @@ declare interface PasswordFieldProps extends Omit<TextFieldProps, 'type' | 'endA
156
436
  toggleAriaLabel?: string;
157
437
  }
158
438
 
159
- export declare const PhoneField: default_2.FC<PhoneFieldProps>;
439
+ export declare const PhoneField: default_2.ForwardRefExoticComponent<PhoneFieldProps & default_2.RefAttributes<HTMLInputElement>>;
160
440
 
161
441
  export declare interface PhoneFieldProps {
162
442
  value?: PhoneValue;
163
443
  onChange: (value: PhoneValue | undefined) => void;
164
444
  defaultCountry?: Country;
165
445
  label?: string;
166
- message?: string;
167
- error?: boolean;
446
+ description?: default_2.ReactNode;
447
+ error?: string;
168
448
  disabled?: boolean;
169
449
  className?: string;
170
450
  placeholder?: string;
@@ -172,12 +452,20 @@ export declare interface PhoneFieldProps {
172
452
 
173
453
  export { PhoneValue }
174
454
 
175
- export declare const TextField: default_2.FC<TextFieldProps>;
455
+ export declare const TextArea: default_2.ForwardRefExoticComponent<Omit<TextAreaProps, "ref"> & default_2.RefAttributes<HTMLTextAreaElement>>;
456
+
457
+ export declare interface TextAreaProps extends default_2.ComponentProps<'textarea'> {
458
+ label?: string;
459
+ description?: default_2.ReactNode;
460
+ error?: string;
461
+ }
462
+
463
+ export declare const TextField: default_2.ForwardRefExoticComponent<Omit<TextFieldProps, "ref"> & default_2.RefAttributes<HTMLInputElement>>;
176
464
 
177
465
  declare interface TextFieldProps extends default_2.ComponentProps<'input'> {
178
466
  label?: string;
179
- message?: default_2.ReactNode;
180
- error?: boolean;
467
+ description?: default_2.ReactNode;
468
+ error?: string;
181
469
  startAdornment?: default_2.ReactNode;
182
470
  endAdornment?: default_2.ReactNode;
183
471
  }
package/dist/index.js CHANGED
@@ -6,6 +6,10 @@ export { C as Checkbox } from './Checkbox.js';
6
6
  export { T as TextField } from './TextField.js';
7
7
  export { P as PasswordField } from './PasswordField.js';
8
8
  export { P as PhoneField, i as isValidPhoneNumber } from './PhoneField.js';
9
+ export { O as OTPField } from './OTPField.js';
10
+ export { T as TextArea } from './TextArea.js';
9
11
  export { T as ThemeToggle } from './ThemeToggle.js';
10
12
  export { T as Typography } from './Typography.js';
13
+ export { C as Controller, F as Form } from './Form.js';
14
+ export { F as Field, h as FieldContent, b as FieldDescription, c as FieldError, d as FieldGroup, a as FieldLabel, e as FieldLegend, f as FieldSeparator, g as FieldSet, i as FieldTitle } from './field.js';
11
15
  //# sourceMappingURL=index.js.map
package/dist/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;"}
1
+ {"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;"}
package/dist/index2.js CHANGED
@@ -1,64 +1,126 @@
1
1
  import * as React from 'react';
2
2
  import { jsx } from 'react/jsx-runtime';
3
3
 
4
- // packages/react/context/src/create-context.tsx
5
- function createContextScope(scopeName, createContextScopeDeps = []) {
6
- let defaultContexts = [];
7
- function createContext3(rootComponentName, defaultContext) {
8
- const BaseContext = React.createContext(defaultContext);
9
- const index = defaultContexts.length;
10
- defaultContexts = [...defaultContexts, defaultContext];
11
- const Provider = (props) => {
12
- const { scope, children, ...context } = props;
13
- const Context = scope?.[scopeName]?.[index] || BaseContext;
14
- const value = React.useMemo(() => context, Object.values(context));
15
- return /* @__PURE__ */ jsx(Context.Provider, { value, children });
16
- };
17
- Provider.displayName = rootComponentName + "Provider";
18
- function useContext2(consumerName, scope) {
19
- const Context = scope?.[scopeName]?.[index] || BaseContext;
20
- const context = React.useContext(Context);
21
- if (context) return context;
22
- if (defaultContext !== void 0) return defaultContext;
23
- throw new Error(`\`${consumerName}\` must be used within \`${rootComponentName}\``);
24
- }
25
- return [Provider, useContext2];
4
+ // packages/react/compose-refs/src/compose-refs.tsx
5
+ function setRef(ref, value) {
6
+ if (typeof ref === "function") {
7
+ return ref(value);
8
+ } else if (ref !== null && ref !== void 0) {
9
+ ref.current = value;
26
10
  }
27
- const createScope = () => {
28
- const scopeContexts = defaultContexts.map((defaultContext) => {
29
- return React.createContext(defaultContext);
11
+ }
12
+ function composeRefs(...refs) {
13
+ return (node) => {
14
+ let hasCleanup = false;
15
+ const cleanups = refs.map((ref) => {
16
+ const cleanup = setRef(ref, node);
17
+ if (!hasCleanup && typeof cleanup == "function") {
18
+ hasCleanup = true;
19
+ }
20
+ return cleanup;
30
21
  });
31
- return function useScope(scope) {
32
- const contexts = scope?.[scopeName] || scopeContexts;
33
- return React.useMemo(
34
- () => ({ [`__scope${scopeName}`]: { ...scope, [scopeName]: contexts } }),
35
- [scope, contexts]
36
- );
37
- };
22
+ if (hasCleanup) {
23
+ return () => {
24
+ for (let i = 0; i < cleanups.length; i++) {
25
+ const cleanup = cleanups[i];
26
+ if (typeof cleanup == "function") {
27
+ cleanup();
28
+ } else {
29
+ setRef(refs[i], null);
30
+ }
31
+ }
32
+ };
33
+ }
38
34
  };
39
- createScope.scopeName = scopeName;
40
- return [createContext3, composeContextScopes(createScope, ...createContextScopeDeps)];
41
35
  }
42
- function composeContextScopes(...scopes) {
43
- const baseScope = scopes[0];
44
- if (scopes.length === 1) return baseScope;
45
- const createScope = () => {
46
- const scopeHooks = scopes.map((createScope2) => ({
47
- useScope: createScope2(),
48
- scopeName: createScope2.scopeName
49
- }));
50
- return function useComposedScopes(overrideScopes) {
51
- const nextScopes = scopeHooks.reduce((nextScopes2, { useScope, scopeName }) => {
52
- const scopeProps = useScope(overrideScopes);
53
- const currentScope = scopeProps[`__scope${scopeName}`];
54
- return { ...nextScopes2, ...currentScope };
55
- }, {});
56
- return React.useMemo(() => ({ [`__scope${baseScope.scopeName}`]: nextScopes }), [nextScopes]);
57
- };
58
- };
59
- createScope.scopeName = baseScope.scopeName;
60
- return createScope;
36
+ function useComposedRefs(...refs) {
37
+ return React.useCallback(composeRefs(...refs), refs);
38
+ }
39
+
40
+ // src/slot.tsx
41
+ // @__NO_SIDE_EFFECTS__
42
+ function createSlot(ownerName) {
43
+ const SlotClone = /* @__PURE__ */ createSlotClone(ownerName);
44
+ const Slot2 = React.forwardRef((props, forwardedRef) => {
45
+ const { children, ...slotProps } = props;
46
+ const childrenArray = React.Children.toArray(children);
47
+ const slottable = childrenArray.find(isSlottable);
48
+ if (slottable) {
49
+ const newElement = slottable.props.children;
50
+ const newChildren = childrenArray.map((child) => {
51
+ if (child === slottable) {
52
+ if (React.Children.count(newElement) > 1) return React.Children.only(null);
53
+ return React.isValidElement(newElement) ? newElement.props.children : null;
54
+ } else {
55
+ return child;
56
+ }
57
+ });
58
+ return /* @__PURE__ */ jsx(SlotClone, { ...slotProps, ref: forwardedRef, children: React.isValidElement(newElement) ? React.cloneElement(newElement, void 0, newChildren) : null });
59
+ }
60
+ return /* @__PURE__ */ jsx(SlotClone, { ...slotProps, ref: forwardedRef, children });
61
+ });
62
+ Slot2.displayName = `${ownerName}.Slot`;
63
+ return Slot2;
64
+ }
65
+ var Slot = /* @__PURE__ */ createSlot("Slot");
66
+ // @__NO_SIDE_EFFECTS__
67
+ function createSlotClone(ownerName) {
68
+ const SlotClone = React.forwardRef((props, forwardedRef) => {
69
+ const { children, ...slotProps } = props;
70
+ if (React.isValidElement(children)) {
71
+ const childrenRef = getElementRef(children);
72
+ const props2 = mergeProps(slotProps, children.props);
73
+ if (children.type !== React.Fragment) {
74
+ props2.ref = forwardedRef ? composeRefs(forwardedRef, childrenRef) : childrenRef;
75
+ }
76
+ return React.cloneElement(children, props2);
77
+ }
78
+ return React.Children.count(children) > 1 ? React.Children.only(null) : null;
79
+ });
80
+ SlotClone.displayName = `${ownerName}.SlotClone`;
81
+ return SlotClone;
82
+ }
83
+ var SLOTTABLE_IDENTIFIER = Symbol("radix.slottable");
84
+ function isSlottable(child) {
85
+ return React.isValidElement(child) && typeof child.type === "function" && "__radixId" in child.type && child.type.__radixId === SLOTTABLE_IDENTIFIER;
86
+ }
87
+ function mergeProps(slotProps, childProps) {
88
+ const overrideProps = { ...childProps };
89
+ for (const propName in childProps) {
90
+ const slotPropValue = slotProps[propName];
91
+ const childPropValue = childProps[propName];
92
+ const isHandler = /^on[A-Z]/.test(propName);
93
+ if (isHandler) {
94
+ if (slotPropValue && childPropValue) {
95
+ overrideProps[propName] = (...args) => {
96
+ const result = childPropValue(...args);
97
+ slotPropValue(...args);
98
+ return result;
99
+ };
100
+ } else if (slotPropValue) {
101
+ overrideProps[propName] = slotPropValue;
102
+ }
103
+ } else if (propName === "style") {
104
+ overrideProps[propName] = { ...slotPropValue, ...childPropValue };
105
+ } else if (propName === "className") {
106
+ overrideProps[propName] = [slotPropValue, childPropValue].filter(Boolean).join(" ");
107
+ }
108
+ }
109
+ return { ...slotProps, ...overrideProps };
110
+ }
111
+ function getElementRef(element) {
112
+ let getter = Object.getOwnPropertyDescriptor(element.props, "ref")?.get;
113
+ let mayWarn = getter && "isReactWarning" in getter && getter.isReactWarning;
114
+ if (mayWarn) {
115
+ return element.ref;
116
+ }
117
+ getter = Object.getOwnPropertyDescriptor(element, "ref")?.get;
118
+ mayWarn = getter && "isReactWarning" in getter && getter.isReactWarning;
119
+ if (mayWarn) {
120
+ return element.props.ref;
121
+ }
122
+ return element.props.ref || element.ref;
61
123
  }
62
124
 
63
- export { createContextScope as c };
125
+ export { Slot as S, composeRefs as a, createSlot as c, useComposedRefs as u };
64
126
  //# sourceMappingURL=index2.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index2.js","sources":["../node_modules/@radix-ui/react-context/dist/index.mjs"],"sourcesContent":["// packages/react/context/src/create-context.tsx\nimport * as React from \"react\";\nimport { jsx } from \"react/jsx-runtime\";\nfunction createContext2(rootComponentName, defaultContext) {\n const Context = React.createContext(defaultContext);\n const Provider = (props) => {\n const { children, ...context } = props;\n const value = React.useMemo(() => context, Object.values(context));\n return /* @__PURE__ */ jsx(Context.Provider, { value, children });\n };\n Provider.displayName = rootComponentName + \"Provider\";\n function useContext2(consumerName) {\n const context = React.useContext(Context);\n if (context) return context;\n if (defaultContext !== void 0) return defaultContext;\n throw new Error(`\\`${consumerName}\\` must be used within \\`${rootComponentName}\\``);\n }\n return [Provider, useContext2];\n}\nfunction createContextScope(scopeName, createContextScopeDeps = []) {\n let defaultContexts = [];\n function createContext3(rootComponentName, defaultContext) {\n const BaseContext = React.createContext(defaultContext);\n const index = defaultContexts.length;\n defaultContexts = [...defaultContexts, defaultContext];\n const Provider = (props) => {\n const { scope, children, ...context } = props;\n const Context = scope?.[scopeName]?.[index] || BaseContext;\n const value = React.useMemo(() => context, Object.values(context));\n return /* @__PURE__ */ jsx(Context.Provider, { value, children });\n };\n Provider.displayName = rootComponentName + \"Provider\";\n function useContext2(consumerName, scope) {\n const Context = scope?.[scopeName]?.[index] || BaseContext;\n const context = React.useContext(Context);\n if (context) return context;\n if (defaultContext !== void 0) return defaultContext;\n throw new Error(`\\`${consumerName}\\` must be used within \\`${rootComponentName}\\``);\n }\n return [Provider, useContext2];\n }\n const createScope = () => {\n const scopeContexts = defaultContexts.map((defaultContext) => {\n return React.createContext(defaultContext);\n });\n return function useScope(scope) {\n const contexts = scope?.[scopeName] || scopeContexts;\n return React.useMemo(\n () => ({ [`__scope${scopeName}`]: { ...scope, [scopeName]: contexts } }),\n [scope, contexts]\n );\n };\n };\n createScope.scopeName = scopeName;\n return [createContext3, composeContextScopes(createScope, ...createContextScopeDeps)];\n}\nfunction composeContextScopes(...scopes) {\n const baseScope = scopes[0];\n if (scopes.length === 1) return baseScope;\n const createScope = () => {\n const scopeHooks = scopes.map((createScope2) => ({\n useScope: createScope2(),\n scopeName: createScope2.scopeName\n }));\n return function useComposedScopes(overrideScopes) {\n const nextScopes = scopeHooks.reduce((nextScopes2, { useScope, scopeName }) => {\n const scopeProps = useScope(overrideScopes);\n const currentScope = scopeProps[`__scope${scopeName}`];\n return { ...nextScopes2, ...currentScope };\n }, {});\n return React.useMemo(() => ({ [`__scope${baseScope.scopeName}`]: nextScopes }), [nextScopes]);\n };\n };\n createScope.scopeName = baseScope.scopeName;\n return createScope;\n}\nexport {\n createContext2 as createContext,\n createContextScope\n};\n//# sourceMappingURL=index.mjs.map\n"],"names":[],"mappings":";;;AAAA;AAmBA,SAAS,kBAAkB,CAAC,SAAS,EAAE,sBAAsB,GAAG,EAAE,EAAE;AACpE,EAAE,IAAI,eAAe,GAAG,EAAE;AAC1B,EAAE,SAAS,cAAc,CAAC,iBAAiB,EAAE,cAAc,EAAE;AAC7D,IAAI,MAAM,WAAW,GAAG,KAAK,CAAC,aAAa,CAAC,cAAc,CAAC;AAC3D,IAAI,MAAM,KAAK,GAAG,eAAe,CAAC,MAAM;AACxC,IAAI,eAAe,GAAG,CAAC,GAAG,eAAe,EAAE,cAAc,CAAC;AAC1D,IAAI,MAAM,QAAQ,GAAG,CAAC,KAAK,KAAK;AAChC,MAAM,MAAM,EAAE,KAAK,EAAE,QAAQ,EAAE,GAAG,OAAO,EAAE,GAAG,KAAK;AACnD,MAAM,MAAM,OAAO,GAAG,KAAK,GAAG,SAAS,CAAC,GAAG,KAAK,CAAC,IAAI,WAAW;AAChE,MAAM,MAAM,KAAK,GAAG,KAAK,CAAC,OAAO,CAAC,MAAM,OAAO,EAAE,MAAM,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC;AACxE,MAAM,uBAAuB,GAAG,CAAC,OAAO,CAAC,QAAQ,EAAE,EAAE,KAAK,EAAE,QAAQ,EAAE,CAAC;AACvE,IAAI,CAAC;AACL,IAAI,QAAQ,CAAC,WAAW,GAAG,iBAAiB,GAAG,UAAU;AACzD,IAAI,SAAS,WAAW,CAAC,YAAY,EAAE,KAAK,EAAE;AAC9C,MAAM,MAAM,OAAO,GAAG,KAAK,GAAG,SAAS,CAAC,GAAG,KAAK,CAAC,IAAI,WAAW;AAChE,MAAM,MAAM,OAAO,GAAG,KA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AI,MAAM,UAAU,GAAG,MAAM,CAAC,GAAG,CAAC,CAAC,YAAY,MAAM;AACrD,MAAM,QAAQ,EAAE,YAAY,EAAE;AAC9B,MAAM,SAAS,EAAE,YAAY,CAAC;AAC9B,KAAK,CAAC,CAAC;AACP,IAAI,OAAO,SAAS,iBAAiB,CAAC,cAAc,EAAE;AACtD,MAAM,MAAM,UAAU,GAAG,UAAU,CAAC,MAAM,CAAC,CAAC,WAAW,EAAE,EAAE,QAAQ,EAAE,SAAS,EAAE,KAAK;AACrF,QAAQ,MAAM,UAAU,GAAG,QAAQ,CAAC,cAAc,CAAC;AACnD,QAAQ,MAAM,YAAY,GAAG,UAAU,CAAC,CAAC,OAAO,EAAE,SAAS,CAAC,CAAC,CAAC;AAC9D,QAAQ,OAAO,EAAE,GAAG,WAAW,EAAE,GAAG,YAAY,EAAE;AAClD,MAAM,CAAC,EAAE,EAAE,CAAC;AACZ,MAAM,OAAO,KAAK,CAAC,OAAO,CAAC,OAAO,EAAE,CAAC,CAAC,OAAO,EAAE,SAAS,CAAC,SAAS,CAAC,CAAC,GAAG,UAAU,EAAE,CAAC,EAAE,CAAC,UAAU,CAAC,CAAC;AACnG,IAAI,CAAC;AACL,EAAE,CAAC;AACH,EAAE,WAAW,CAAC,SAAS,GAAG,SAAS,CAAC,SAAS;AAC7C,EAAE,OAAO,WAAW;AACpB;;;;","x_google_ignoreList":[0]}
1
+ {"version":3,"file":"index2.js","sources":["../node_modules/@radix-ui/react-compose-refs/dist/index.mjs","../node_modules/@radix-ui/react-slot/dist/index.mjs"],"sourcesContent":["// packages/react/compose-refs/src/compose-refs.tsx\nimport * as React from \"react\";\nfunction setRef(ref, value) {\n if (typeof ref === \"function\") {\n return ref(value);\n } else if (ref !== null && ref !== void 0) {\n ref.current = value;\n }\n}\nfunction composeRefs(...refs) {\n return (node) => {\n let hasCleanup = false;\n const cleanups = refs.map((ref) => {\n const cleanup = setRef(ref, node);\n if (!hasCleanup && typeof cleanup == \"function\") {\n hasCleanup = true;\n }\n return cleanup;\n });\n if (hasCleanup) {\n return () => {\n for (let i = 0; i < cleanups.length; i++) {\n const cleanup = cleanups[i];\n if (typeof cleanup == \"function\") {\n cleanup();\n } else {\n setRef(refs[i], null);\n }\n }\n };\n }\n };\n}\nfunction useComposedRefs(...refs) {\n return React.useCallback(composeRefs(...refs), refs);\n}\nexport {\n composeRefs,\n useComposedRefs\n};\n//# sourceMappingURL=index.mjs.map\n","// src/slot.tsx\nimport * as React from \"react\";\nimport { composeRefs } from \"@radix-ui/react-compose-refs\";\nimport { Fragment as Fragment2, jsx } from \"react/jsx-runtime\";\n// @__NO_SIDE_EFFECTS__\nfunction createSlot(ownerName) {\n const SlotClone = /* @__PURE__ */ createSlotClone(ownerName);\n const Slot2 = React.forwardRef((props, forwardedRef) => {\n const { children, ...slotProps } = props;\n const childrenArray = React.Children.toArray(children);\n const slottable = childrenArray.find(isSlottable);\n if (slottable) {\n const newElement = slottable.props.children;\n const newChildren = childrenArray.map((child) => {\n if (child === slottable) {\n if (React.Children.count(newElement) > 1) return React.Children.only(null);\n return React.isValidElement(newElement) ? newElement.props.children : null;\n } else {\n return child;\n }\n });\n return /* @__PURE__ */ jsx(SlotClone, { ...slotProps, ref: forwardedRef, children: React.isValidElement(newElement) ? React.cloneElement(newElement, void 0, newChildren) : null });\n }\n return /* @__PURE__ */ jsx(SlotClone, { ...slotProps, ref: forwardedRef, children });\n });\n Slot2.displayName = `${ownerName}.Slot`;\n return Slot2;\n}\nvar Slot = /* @__PURE__ */ createSlot(\"Slot\");\n// @__NO_SIDE_EFFECTS__\nfunction createSlotClone(ownerName) {\n const SlotClone = React.forwardRef((props, forwardedRef) => {\n const { children, ...slotProps } = props;\n if (React.isValidElement(children)) {\n const childrenRef = getElementRef(children);\n const props2 = mergeProps(slotProps, children.props);\n if (children.type !== React.Fragment) {\n props2.ref = forwardedRef ? composeRefs(forwardedRef, childrenRef) : childrenRef;\n }\n return React.cloneElement(children, props2);\n }\n return React.Children.count(children) > 1 ? React.Children.only(null) : null;\n });\n SlotClone.displayName = `${ownerName}.SlotClone`;\n return SlotClone;\n}\nvar SLOTTABLE_IDENTIFIER = Symbol(\"radix.slottable\");\n// @__NO_SIDE_EFFECTS__\nfunction createSlottable(ownerName) {\n const Slottable2 = ({ children }) => {\n return /* @__PURE__ */ jsx(Fragment2, { children });\n };\n Slottable2.displayName = `${ownerName}.Slottable`;\n Slottable2.__radixId = SLOTTABLE_IDENTIFIER;\n return Slottable2;\n}\nvar Slottable = /* @__PURE__ */ createSlottable(\"Slottable\");\nfunction isSlottable(child) {\n return React.isValidElement(child) && typeof child.type === \"function\" && \"__radixId\" in child.type && child.type.__radixId === SLOTTABLE_IDENTIFIER;\n}\nfunction mergeProps(slotProps, childProps) {\n const overrideProps = { ...childProps };\n for (const propName in childProps) {\n const slotPropValue = slotProps[propName];\n const childPropValue = childProps[propName];\n const isHandler = /^on[A-Z]/.test(propName);\n if (isHandler) {\n if (slotPropValue && childPropValue) {\n overrideProps[propName] = (...args) => {\n const result = childPropValue(...args);\n slotPropValue(...args);\n return result;\n };\n } else if (slotPropValue) {\n overrideProps[propName] = slotPropValue;\n }\n } else if (propName === \"style\") {\n overrideProps[propName] = { ...slotPropValue, ...childPropValue };\n } else if (propName === \"className\") {\n overrideProps[propName] = [slotPropValue, childPropValue].filter(Boolean).join(\" \");\n }\n }\n return { ...slotProps, ...overrideProps };\n}\nfunction getElementRef(element) {\n let getter = Object.getOwnPropertyDescriptor(element.props, \"ref\")?.get;\n let mayWarn = getter && \"isReactWarning\" in getter && getter.isReactWarning;\n if (mayWarn) {\n return element.ref;\n }\n getter = Object.getOwnPropertyDescriptor(element, \"ref\")?.get;\n mayWarn = getter && \"isReactWarning\" in getter && getter.isReactWarning;\n if (mayWarn) {\n return element.props.ref;\n }\n return element.props.ref || element.ref;\n}\nexport {\n Slot as Root,\n Slot,\n Slottable,\n createSlot,\n createSlottable\n};\n//# sourceMappingURL=index.mjs.map\n"],"names":[],"mappings":";;;AAA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