@yoopta/themes-shadcn 6.0.1 → 6.0.2

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 (139) hide show
  1. package/dist/embed/elements/embed/embed-element.d.ts +1 -1
  2. package/dist/embed/elements/embed/embed-element.d.ts.map +1 -1
  3. package/dist/embed/elements/embed/embed-render.d.ts.map +1 -1
  4. package/dist/embed/index.d.ts +1 -1
  5. package/dist/embed.js +2 -2
  6. package/dist/file/elements/file/file-element.d.ts +1 -1
  7. package/dist/file/elements/file/file-element.d.ts.map +1 -1
  8. package/dist/file/index.d.ts +1 -1
  9. package/dist/file.js +2 -2
  10. package/dist/image/elements/image/image-element.d.ts +1 -1
  11. package/dist/image/elements/image/image-element.d.ts.map +1 -1
  12. package/dist/image/elements/image/image-render.d.ts.map +1 -1
  13. package/dist/image/index.d.ts +1 -1
  14. package/dist/image.js +2 -2
  15. package/dist/index.js +1 -1
  16. package/dist/steps/elements/steps-list-item.d.ts.map +1 -1
  17. package/dist/steps.js +1 -1
  18. package/dist/video/elements/video/video-element.d.ts +1 -1
  19. package/dist/video/elements/video/video-element.d.ts.map +1 -1
  20. package/dist/video/elements/video/video-render.d.ts.map +1 -1
  21. package/dist/video/index.d.ts +1 -1
  22. package/dist/video.js +2 -2
  23. package/package.json +13 -13
  24. package/dist/accordion.js.map +0 -1
  25. package/dist/blockquote.js.map +0 -1
  26. package/dist/callout.js.map +0 -1
  27. package/dist/carousel.js.map +0 -1
  28. package/dist/chunks/Combination-3c924518.js +0 -1080
  29. package/dist/chunks/Combination-3c924518.js.map +0 -1
  30. package/dist/chunks/_tslib-514d60fe.js +0 -67
  31. package/dist/chunks/_tslib-514d60fe.js.map +0 -1
  32. package/dist/chunks/arrow-right-5ddace59.js +0 -30
  33. package/dist/chunks/arrow-right-5ddace59.js.map +0 -1
  34. package/dist/chunks/button-27a1fbc2.js +0 -76
  35. package/dist/chunks/button-27a1fbc2.js.map +0 -1
  36. package/dist/chunks/card-12ed876a.js +0 -38
  37. package/dist/chunks/card-12ed876a.js.map +0 -1
  38. package/dist/chunks/check-9acc031a.js +0 -14
  39. package/dist/chunks/check-9acc031a.js.map +0 -1
  40. package/dist/chunks/chevron-down-7424d0c3.js +0 -16
  41. package/dist/chunks/chevron-down-7424d0c3.js.map +0 -1
  42. package/dist/chunks/chevron-up-546faa64.js +0 -14
  43. package/dist/chunks/chevron-up-546faa64.js.map +0 -1
  44. package/dist/chunks/code-5407bf8e.js +0 -17
  45. package/dist/chunks/code-5407bf8e.js.map +0 -1
  46. package/dist/chunks/createLucideIcon-6ba35914.js +0 -56
  47. package/dist/chunks/createLucideIcon-6ba35914.js.map +0 -1
  48. package/dist/chunks/dropdown-menu-9ba446af.js +0 -1250
  49. package/dist/chunks/dropdown-menu-9ba446af.js.map +0 -1
  50. package/dist/chunks/external-link-1bf3c7a2.js +0 -18
  51. package/dist/chunks/external-link-1bf3c7a2.js.map +0 -1
  52. package/dist/chunks/file-text-9e348575.js +0 -23
  53. package/dist/chunks/file-text-9e348575.js.map +0 -1
  54. package/dist/chunks/hover-card-22a4067b.js +0 -258
  55. package/dist/chunks/hover-card-22a4067b.js.map +0 -1
  56. package/dist/chunks/index-0c94b090.js +0 -222
  57. package/dist/chunks/index-0c94b090.js.map +0 -1
  58. package/dist/chunks/index-12e7c5fd.js +0 -155
  59. package/dist/chunks/index-12e7c5fd.js.map +0 -1
  60. package/dist/chunks/index-26994c9d.js +0 -131
  61. package/dist/chunks/index-26994c9d.js.map +0 -1
  62. package/dist/chunks/index-600be8f8.js +0 -190
  63. package/dist/chunks/index-600be8f8.js.map +0 -1
  64. package/dist/chunks/index-7e966ec9.js +0 -16
  65. package/dist/chunks/index-7e966ec9.js.map +0 -1
  66. package/dist/chunks/index-9ac5afe2.js +0 -201
  67. package/dist/chunks/index-9ac5afe2.js.map +0 -1
  68. package/dist/chunks/index-9bb7ddb4.js +0 -104
  69. package/dist/chunks/index-9bb7ddb4.js.map +0 -1
  70. package/dist/chunks/index-ae9b48d5.js +0 -12
  71. package/dist/chunks/index-ae9b48d5.js.map +0 -1
  72. package/dist/chunks/index-b26053ec.js +0 -3805
  73. package/dist/chunks/index-b26053ec.js.map +0 -1
  74. package/dist/chunks/index-b8f2908d.js +0 -40
  75. package/dist/chunks/index-b8f2908d.js.map +0 -1
  76. package/dist/chunks/index-c655a86f.js +0 -7
  77. package/dist/chunks/index-c655a86f.js.map +0 -1
  78. package/dist/chunks/index-d9171717.js +0 -13
  79. package/dist/chunks/index-d9171717.js.map +0 -1
  80. package/dist/chunks/index-e42d0aaf.js +0 -36
  81. package/dist/chunks/index-e42d0aaf.js.map +0 -1
  82. package/dist/chunks/index-ebc47eac.js +0 -2765
  83. package/dist/chunks/index-ebc47eac.js.map +0 -1
  84. package/dist/chunks/index-ffe23855.js +0 -71
  85. package/dist/chunks/index-ffe23855.js.map +0 -1
  86. package/dist/chunks/input-7c5e4260.js +0 -13
  87. package/dist/chunks/input-7c5e4260.js.map +0 -1
  88. package/dist/chunks/label-2a076b3f.js +0 -70
  89. package/dist/chunks/label-2a076b3f.js.map +0 -1
  90. package/dist/chunks/language-select-b35256ab.js +0 -12
  91. package/dist/chunks/language-select-b35256ab.js.map +0 -1
  92. package/dist/chunks/play-c2a06e4e.js +0 -16
  93. package/dist/chunks/play-c2a06e4e.js.map +0 -1
  94. package/dist/chunks/plus-f36f52e8.js +0 -17
  95. package/dist/chunks/plus-f36f52e8.js.map +0 -1
  96. package/dist/chunks/popover-4b5c0941.js +0 -385
  97. package/dist/chunks/popover-4b5c0941.js.map +0 -1
  98. package/dist/chunks/scroll-area-8dc03d8f.js +0 -727
  99. package/dist/chunks/scroll-area-8dc03d8f.js.map +0 -1
  100. package/dist/chunks/select-88f1b66c.js +0 -1281
  101. package/dist/chunks/select-88f1b66c.js.map +0 -1
  102. package/dist/chunks/separator-a6b3e5d2.js +0 -74
  103. package/dist/chunks/separator-a6b3e5d2.js.map +0 -1
  104. package/dist/chunks/settings-2-8e53118c.js +0 -19
  105. package/dist/chunks/settings-2-8e53118c.js.map +0 -1
  106. package/dist/chunks/sparkles-a0316be3.js +0 -26
  107. package/dist/chunks/sparkles-a0316be3.js.map +0 -1
  108. package/dist/chunks/style-inject.es-746bb8ed.js +0 -29
  109. package/dist/chunks/style-inject.es-746bb8ed.js.map +0 -1
  110. package/dist/chunks/tabs-38ee85c4.js +0 -205
  111. package/dist/chunks/tabs-38ee85c4.js.map +0 -1
  112. package/dist/chunks/tooltip-eb8a0f63.js +0 -1671
  113. package/dist/chunks/tooltip-eb8a0f63.js.map +0 -1
  114. package/dist/chunks/trash-2-41ddec45.js +0 -20
  115. package/dist/chunks/trash-2-41ddec45.js.map +0 -1
  116. package/dist/chunks/upload-b987996c.js +0 -44
  117. package/dist/chunks/upload-b987996c.js.map +0 -1
  118. package/dist/chunks/utils-208f599b.js +0 -2500
  119. package/dist/chunks/utils-208f599b.js.map +0 -1
  120. package/dist/chunks/x-f7edc87d.js +0 -17
  121. package/dist/chunks/x-f7edc87d.js.map +0 -1
  122. package/dist/code-group.js.map +0 -1
  123. package/dist/code.js.map +0 -1
  124. package/dist/divider.js.map +0 -1
  125. package/dist/embed.js.map +0 -1
  126. package/dist/emoji.js.map +0 -1
  127. package/dist/file.js.map +0 -1
  128. package/dist/headings.js.map +0 -1
  129. package/dist/image.js.map +0 -1
  130. package/dist/index.js.map +0 -1
  131. package/dist/link.js.map +0 -1
  132. package/dist/lists.js.map +0 -1
  133. package/dist/mention.js.map +0 -1
  134. package/dist/paragraph.js.map +0 -1
  135. package/dist/steps.js.map +0 -1
  136. package/dist/table-of-contents.js.map +0 -1
  137. package/dist/table.js.map +0 -1
  138. package/dist/tabs.js.map +0 -1
  139. package/dist/video.js.map +0 -1
@@ -1,201 +0,0 @@
1
- import * as React from 'react';
2
- import { jsx } from 'react/jsx-runtime';
3
- import * as ReactDOM from 'react-dom';
4
- import { c as composeRefs } from './index-b8f2908d.js';
5
-
6
- // packages/react/context/src/create-context.tsx
7
- function createContextScope(scopeName, createContextScopeDeps = []) {
8
- let defaultContexts = [];
9
- function createContext3(rootComponentName, defaultContext) {
10
- const BaseContext = React.createContext(defaultContext);
11
- const index = defaultContexts.length;
12
- defaultContexts = [...defaultContexts, defaultContext];
13
- const Provider = (props) => {
14
- const { scope, children, ...context } = props;
15
- const Context = scope?.[scopeName]?.[index] || BaseContext;
16
- const value = React.useMemo(() => context, Object.values(context));
17
- return /* @__PURE__ */ jsx(Context.Provider, { value, children });
18
- };
19
- Provider.displayName = rootComponentName + "Provider";
20
- function useContext2(consumerName, scope) {
21
- const Context = scope?.[scopeName]?.[index] || BaseContext;
22
- const context = React.useContext(Context);
23
- if (context) return context;
24
- if (defaultContext !== void 0) return defaultContext;
25
- throw new Error(`\`${consumerName}\` must be used within \`${rootComponentName}\``);
26
- }
27
- return [Provider, useContext2];
28
- }
29
- const createScope = () => {
30
- const scopeContexts = defaultContexts.map((defaultContext) => {
31
- return React.createContext(defaultContext);
32
- });
33
- return function useScope(scope) {
34
- const contexts = scope?.[scopeName] || scopeContexts;
35
- return React.useMemo(
36
- () => ({ [`__scope${scopeName}`]: { ...scope, [scopeName]: contexts } }),
37
- [scope, contexts]
38
- );
39
- };
40
- };
41
- createScope.scopeName = scopeName;
42
- return [createContext3, composeContextScopes(createScope, ...createContextScopeDeps)];
43
- }
44
- function composeContextScopes(...scopes) {
45
- const baseScope = scopes[0];
46
- if (scopes.length === 1) return baseScope;
47
- const createScope = () => {
48
- const scopeHooks = scopes.map((createScope2) => ({
49
- useScope: createScope2(),
50
- scopeName: createScope2.scopeName
51
- }));
52
- return function useComposedScopes(overrideScopes) {
53
- const nextScopes = scopeHooks.reduce((nextScopes2, { useScope, scopeName }) => {
54
- const scopeProps = useScope(overrideScopes);
55
- const currentScope = scopeProps[`__scope${scopeName}`];
56
- return { ...nextScopes2, ...currentScope };
57
- }, {});
58
- return React.useMemo(() => ({ [`__scope${baseScope.scopeName}`]: nextScopes }), [nextScopes]);
59
- };
60
- };
61
- createScope.scopeName = baseScope.scopeName;
62
- return createScope;
63
- }
64
-
65
- // src/primitive.tsx
66
- function composeEventHandlers(originalEventHandler, ourEventHandler, { checkForDefaultPrevented = true } = {}) {
67
- return function handleEvent(event) {
68
- originalEventHandler?.(event);
69
- if (checkForDefaultPrevented === false || !event.defaultPrevented) {
70
- return ourEventHandler?.(event);
71
- }
72
- };
73
- }
74
-
75
- // packages/react/use-layout-effect/src/use-layout-effect.tsx
76
- var useLayoutEffect2 = globalThis?.document ? React.useLayoutEffect : () => {
77
- };
78
-
79
- // src/slot.tsx
80
- // @__NO_SIDE_EFFECTS__
81
- function createSlot(ownerName) {
82
- const SlotClone = /* @__PURE__ */ createSlotClone(ownerName);
83
- const Slot2 = React.forwardRef((props, forwardedRef) => {
84
- const { children, ...slotProps } = props;
85
- const childrenArray = React.Children.toArray(children);
86
- const slottable = childrenArray.find(isSlottable);
87
- if (slottable) {
88
- const newElement = slottable.props.children;
89
- const newChildren = childrenArray.map((child) => {
90
- if (child === slottable) {
91
- if (React.Children.count(newElement) > 1) return React.Children.only(null);
92
- return React.isValidElement(newElement) ? newElement.props.children : null;
93
- } else {
94
- return child;
95
- }
96
- });
97
- return /* @__PURE__ */ jsx(SlotClone, { ...slotProps, ref: forwardedRef, children: React.isValidElement(newElement) ? React.cloneElement(newElement, void 0, newChildren) : null });
98
- }
99
- return /* @__PURE__ */ jsx(SlotClone, { ...slotProps, ref: forwardedRef, children });
100
- });
101
- Slot2.displayName = `${ownerName}.Slot`;
102
- return Slot2;
103
- }
104
- // @__NO_SIDE_EFFECTS__
105
- function createSlotClone(ownerName) {
106
- const SlotClone = React.forwardRef((props, forwardedRef) => {
107
- const { children, ...slotProps } = props;
108
- if (React.isValidElement(children)) {
109
- const childrenRef = getElementRef(children);
110
- const props2 = mergeProps(slotProps, children.props);
111
- if (children.type !== React.Fragment) {
112
- props2.ref = forwardedRef ? composeRefs(forwardedRef, childrenRef) : childrenRef;
113
- }
114
- return React.cloneElement(children, props2);
115
- }
116
- return React.Children.count(children) > 1 ? React.Children.only(null) : null;
117
- });
118
- SlotClone.displayName = `${ownerName}.SlotClone`;
119
- return SlotClone;
120
- }
121
- var SLOTTABLE_IDENTIFIER = Symbol("radix.slottable");
122
- function isSlottable(child) {
123
- return React.isValidElement(child) && typeof child.type === "function" && "__radixId" in child.type && child.type.__radixId === SLOTTABLE_IDENTIFIER;
124
- }
125
- function mergeProps(slotProps, childProps) {
126
- const overrideProps = { ...childProps };
127
- for (const propName in childProps) {
128
- const slotPropValue = slotProps[propName];
129
- const childPropValue = childProps[propName];
130
- const isHandler = /^on[A-Z]/.test(propName);
131
- if (isHandler) {
132
- if (slotPropValue && childPropValue) {
133
- overrideProps[propName] = (...args) => {
134
- const result = childPropValue(...args);
135
- slotPropValue(...args);
136
- return result;
137
- };
138
- } else if (slotPropValue) {
139
- overrideProps[propName] = slotPropValue;
140
- }
141
- } else if (propName === "style") {
142
- overrideProps[propName] = { ...slotPropValue, ...childPropValue };
143
- } else if (propName === "className") {
144
- overrideProps[propName] = [slotPropValue, childPropValue].filter(Boolean).join(" ");
145
- }
146
- }
147
- return { ...slotProps, ...overrideProps };
148
- }
149
- function getElementRef(element) {
150
- let getter = Object.getOwnPropertyDescriptor(element.props, "ref")?.get;
151
- let mayWarn = getter && "isReactWarning" in getter && getter.isReactWarning;
152
- if (mayWarn) {
153
- return element.ref;
154
- }
155
- getter = Object.getOwnPropertyDescriptor(element, "ref")?.get;
156
- mayWarn = getter && "isReactWarning" in getter && getter.isReactWarning;
157
- if (mayWarn) {
158
- return element.props.ref;
159
- }
160
- return element.props.ref || element.ref;
161
- }
162
-
163
- // src/primitive.tsx
164
- var NODES = [
165
- "a",
166
- "button",
167
- "div",
168
- "form",
169
- "h2",
170
- "h3",
171
- "img",
172
- "input",
173
- "label",
174
- "li",
175
- "nav",
176
- "ol",
177
- "p",
178
- "select",
179
- "span",
180
- "svg",
181
- "ul"
182
- ];
183
- var Primitive = NODES.reduce((primitive, node) => {
184
- const Slot = createSlot(`Primitive.${node}`);
185
- const Node = React.forwardRef((props, forwardedRef) => {
186
- const { asChild, ...primitiveProps } = props;
187
- const Comp = asChild ? Slot : node;
188
- if (typeof window !== "undefined") {
189
- window[Symbol.for("radix-ui")] = true;
190
- }
191
- return /* @__PURE__ */ jsx(Comp, { ...primitiveProps, ref: forwardedRef });
192
- });
193
- Node.displayName = `Primitive.${node}`;
194
- return { ...primitive, [node]: Node };
195
- }, {});
196
- function dispatchDiscreteCustomEvent(target, event) {
197
- if (target) ReactDOM.flushSync(() => target.dispatchEvent(event));
198
- }
199
-
200
- export { Primitive as P, composeEventHandlers as a, createContextScope as c, dispatchDiscreteCustomEvent as d, useLayoutEffect2 as u };
201
- //# sourceMappingURL=index-9ac5afe2.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index-9ac5afe2.js","sources":["../../../../../node_modules/@radix-ui/react-context/src/create-context.tsx","../../../../../node_modules/@radix-ui/primitive/src/primitive.tsx","../../../../../node_modules/@radix-ui/react-use-layout-effect/src/use-layout-effect.tsx","../../../../../node_modules/@radix-ui/react-primitive/node_modules/@radix-ui/react-slot/src/slot.tsx","../../../../../node_modules/@radix-ui/react-primitive/src/primitive.tsx"],"sourcesContent":["import * as React from 'react';\n\nfunction createContext<ContextValueType extends object | null>(\n rootComponentName: string,\n defaultContext?: ContextValueType\n) {\n const Context = React.createContext<ContextValueType | undefined>(defaultContext);\n\n const Provider: React.FC<ContextValueType & { children: React.ReactNode }> = (props) => {\n const { children, ...context } = props;\n // Only re-memoize when prop values change\n // eslint-disable-next-line react-hooks/exhaustive-deps\n const value = React.useMemo(() => context, Object.values(context)) as ContextValueType;\n return <Context.Provider value={value}>{children}</Context.Provider>;\n };\n\n Provider.displayName = rootComponentName + 'Provider';\n\n function useContext(consumerName: string) {\n const context = React.useContext(Context);\n if (context) return context;\n if (defaultContext !== undefined) return defaultContext;\n // if a defaultContext wasn't specified, it's a required context.\n throw new Error(`\\`${consumerName}\\` must be used within \\`${rootComponentName}\\``);\n }\n\n return [Provider, useContext] as const;\n}\n\n/* -------------------------------------------------------------------------------------------------\n * createContextScope\n * -----------------------------------------------------------------------------------------------*/\n\ntype Scope<C = any> = { [scopeName: string]: React.Context<C>[] } | undefined;\ntype ScopeHook = (scope: Scope) => { [__scopeProp: string]: Scope };\ninterface CreateScope {\n scopeName: string;\n (): ScopeHook;\n}\n\nfunction createContextScope(scopeName: string, createContextScopeDeps: CreateScope[] = []) {\n let defaultContexts: any[] = [];\n\n /* -----------------------------------------------------------------------------------------------\n * createContext\n * ---------------------------------------------------------------------------------------------*/\n\n function createContext<ContextValueType extends object | null>(\n rootComponentName: string,\n defaultContext?: ContextValueType\n ) {\n const BaseContext = React.createContext<ContextValueType | undefined>(defaultContext);\n const index = defaultContexts.length;\n defaultContexts = [...defaultContexts, defaultContext];\n\n const Provider: React.FC<\n ContextValueType & { scope: Scope<ContextValueType>; children: React.ReactNode }\n > = (props) => {\n const { scope, children, ...context } = props;\n const Context = scope?.[scopeName]?.[index] || BaseContext;\n // Only re-memoize when prop values change\n // eslint-disable-next-line react-hooks/exhaustive-deps\n const value = React.useMemo(() => context, Object.values(context)) as ContextValueType;\n return <Context.Provider value={value}>{children}</Context.Provider>;\n };\n\n Provider.displayName = rootComponentName + 'Provider';\n\n function useContext(consumerName: string, scope: Scope<ContextValueType | undefined>) {\n const Context = scope?.[scopeName]?.[index] || BaseContext;\n const context = React.useContext(Context);\n if (context) return context;\n if (defaultContext !== undefined) return defaultContext;\n // if a defaultContext wasn't specified, it's a required context.\n throw new Error(`\\`${consumerName}\\` must be used within \\`${rootComponentName}\\``);\n }\n\n return [Provider, useContext] as const;\n }\n\n /* -----------------------------------------------------------------------------------------------\n * createScope\n * ---------------------------------------------------------------------------------------------*/\n\n const createScope: CreateScope = () => {\n const scopeContexts = defaultContexts.map((defaultContext) => {\n return React.createContext(defaultContext);\n });\n return function useScope(scope: Scope) {\n const contexts = scope?.[scopeName] || scopeContexts;\n return React.useMemo(\n () => ({ [`__scope${scopeName}`]: { ...scope, [scopeName]: contexts } }),\n [scope, contexts]\n );\n };\n };\n\n createScope.scopeName = scopeName;\n return [createContext, composeContextScopes(createScope, ...createContextScopeDeps)] as const;\n}\n\n/* -------------------------------------------------------------------------------------------------\n * composeContextScopes\n * -----------------------------------------------------------------------------------------------*/\n\nfunction composeContextScopes(...scopes: CreateScope[]) {\n const baseScope = scopes[0];\n if (scopes.length === 1) return baseScope;\n\n const createScope: CreateScope = () => {\n const scopeHooks = scopes.map((createScope) => ({\n useScope: createScope(),\n scopeName: createScope.scopeName,\n }));\n\n return function useComposedScopes(overrideScopes) {\n const nextScopes = scopeHooks.reduce((nextScopes, { useScope, scopeName }) => {\n // We are calling a hook inside a callback which React warns against to avoid inconsistent\n // renders, however, scoping doesn't have render side effects so we ignore the rule.\n // eslint-disable-next-line react-hooks/rules-of-hooks\n const scopeProps = useScope(overrideScopes);\n const currentScope = scopeProps[`__scope${scopeName}`];\n return { ...nextScopes, ...currentScope };\n }, {});\n\n return React.useMemo(() => ({ [`__scope${baseScope.scopeName}`]: nextScopes }), [nextScopes]);\n };\n };\n\n createScope.scopeName = baseScope.scopeName;\n return createScope;\n}\n\n/* -----------------------------------------------------------------------------------------------*/\n\nexport { createContext, createContextScope };\nexport type { CreateScope, Scope };\n","/* eslint-disable no-restricted-properties */\n\n/* eslint-disable no-restricted-globals */\nexport const canUseDOM = !!(\n typeof window !== 'undefined' &&\n window.document &&\n window.document.createElement\n);\n/* eslint-enable no-restricted-globals */\n\nexport function composeEventHandlers<E extends { defaultPrevented: boolean }>(\n originalEventHandler?: (event: E) => void,\n ourEventHandler?: (event: E) => void,\n { checkForDefaultPrevented = true } = {}\n) {\n return function handleEvent(event: E) {\n originalEventHandler?.(event);\n\n if (checkForDefaultPrevented === false || !event.defaultPrevented) {\n return ourEventHandler?.(event);\n }\n };\n}\n\nexport function getOwnerWindow(element: Node | null | undefined) {\n if (!canUseDOM) {\n throw new Error('Cannot access window outside of the DOM');\n }\n // eslint-disable-next-line no-restricted-globals\n return element?.ownerDocument?.defaultView ?? window;\n}\n\nexport function getOwnerDocument(element: Node | null | undefined) {\n if (!canUseDOM) {\n throw new Error('Cannot access document outside of the DOM');\n }\n // eslint-disable-next-line no-restricted-globals\n return element?.ownerDocument ?? document;\n}\n\n/**\n * Lifted from https://github.com/ariakit/ariakit/blob/main/packages/ariakit-core/src/utils/dom.ts#L37\n * MIT License, Copyright (c) AriaKit.\n */\nexport function getActiveElement(\n node: Node | null | undefined,\n activeDescendant = false\n): HTMLElement | null {\n const { activeElement } = getOwnerDocument(node);\n if (!activeElement?.nodeName) {\n // `activeElement` might be an empty object if we're interacting with elements\n // inside of an iframe.\n return null;\n }\n\n if (isFrame(activeElement) && activeElement.contentDocument) {\n return getActiveElement(activeElement.contentDocument.body, activeDescendant);\n }\n\n if (activeDescendant) {\n const id = activeElement.getAttribute('aria-activedescendant');\n if (id) {\n const element = getOwnerDocument(activeElement).getElementById(id);\n if (element) {\n return element;\n }\n }\n }\n\n return activeElement as HTMLElement | null;\n}\n\nexport function isFrame(element: Element): element is HTMLIFrameElement {\n return element.tagName === 'IFRAME';\n}\n","import * as React from 'react';\n\n/**\n * On the server, React emits a warning when calling `useLayoutEffect`.\n * This is because neither `useLayoutEffect` nor `useEffect` run on the server.\n * We use this safe version which suppresses the warning by replacing it with a noop on the server.\n *\n * See: https://reactjs.org/docs/hooks-reference.html#uselayouteffect\n */\nconst useLayoutEffect = globalThis?.document ? React.useLayoutEffect : () => {};\n\nexport { useLayoutEffect };\n","import * as React from 'react';\nimport { composeRefs } from '@radix-ui/react-compose-refs';\n\n/* -------------------------------------------------------------------------------------------------\n * Slot\n * -----------------------------------------------------------------------------------------------*/\n\ninterface SlotProps extends React.HTMLAttributes<HTMLElement> {\n children?: React.ReactNode;\n}\n\n/* @__NO_SIDE_EFFECTS__ */ export function createSlot(ownerName: string) {\n const SlotClone = createSlotClone(ownerName);\n const Slot = React.forwardRef<HTMLElement, SlotProps>((props, forwardedRef) => {\n const { children, ...slotProps } = props;\n const childrenArray = React.Children.toArray(children);\n const slottable = childrenArray.find(isSlottable);\n\n if (slottable) {\n // the new element to render is the one passed as a child of `Slottable`\n const newElement = slottable.props.children;\n\n const newChildren = childrenArray.map((child) => {\n if (child === slottable) {\n // because the new element will be the one rendered, we are only interested\n // in grabbing its children (`newElement.props.children`)\n if (React.Children.count(newElement) > 1) return React.Children.only(null);\n return React.isValidElement(newElement)\n ? (newElement.props as { children: React.ReactNode }).children\n : null;\n } else {\n return child;\n }\n });\n\n return (\n <SlotClone {...slotProps} ref={forwardedRef}>\n {React.isValidElement(newElement)\n ? React.cloneElement(newElement, undefined, newChildren)\n : null}\n </SlotClone>\n );\n }\n\n return (\n <SlotClone {...slotProps} ref={forwardedRef}>\n {children}\n </SlotClone>\n );\n });\n\n Slot.displayName = `${ownerName}.Slot`;\n return Slot;\n}\n\nconst Slot = createSlot('Slot');\n\n/* -------------------------------------------------------------------------------------------------\n * SlotClone\n * -----------------------------------------------------------------------------------------------*/\n\ninterface SlotCloneProps {\n children: React.ReactNode;\n}\n\n/* @__NO_SIDE_EFFECTS__ */ function createSlotClone(ownerName: string) {\n const SlotClone = React.forwardRef<any, SlotCloneProps>((props, forwardedRef) => {\n const { children, ...slotProps } = props;\n\n if (React.isValidElement(children)) {\n const childrenRef = getElementRef(children);\n const props = mergeProps(slotProps, children.props as AnyProps);\n // do not pass ref to React.Fragment for React 19 compatibility\n if (children.type !== React.Fragment) {\n props.ref = forwardedRef ? composeRefs(forwardedRef, childrenRef) : childrenRef;\n }\n return React.cloneElement(children, props);\n }\n\n return React.Children.count(children) > 1 ? React.Children.only(null) : null;\n });\n\n SlotClone.displayName = `${ownerName}.SlotClone`;\n return SlotClone;\n}\n\n/* -------------------------------------------------------------------------------------------------\n * Slottable\n * -----------------------------------------------------------------------------------------------*/\n\nconst SLOTTABLE_IDENTIFIER = Symbol('radix.slottable');\n\ninterface SlottableProps {\n children: React.ReactNode;\n}\n\ninterface SlottableComponent extends React.FC<SlottableProps> {\n __radixId: symbol;\n}\n\n/* @__NO_SIDE_EFFECTS__ */ export function createSlottable(ownerName: string) {\n const Slottable: SlottableComponent = ({ children }) => {\n return <>{children}</>;\n };\n Slottable.displayName = `${ownerName}.Slottable`;\n Slottable.__radixId = SLOTTABLE_IDENTIFIER;\n return Slottable;\n}\n\nconst Slottable = createSlottable('Slottable');\n\n/* ---------------------------------------------------------------------------------------------- */\n\ntype AnyProps = Record<string, any>;\n\nfunction isSlottable(\n child: React.ReactNode\n): child is React.ReactElement<SlottableProps, typeof Slottable> {\n return (\n React.isValidElement(child) &&\n typeof child.type === 'function' &&\n '__radixId' in child.type &&\n child.type.__radixId === SLOTTABLE_IDENTIFIER\n );\n}\n\nfunction mergeProps(slotProps: AnyProps, childProps: AnyProps) {\n // all child props should override\n const overrideProps = { ...childProps };\n\n for (const propName in childProps) {\n const slotPropValue = slotProps[propName];\n const childPropValue = childProps[propName];\n\n const isHandler = /^on[A-Z]/.test(propName);\n if (isHandler) {\n // if the handler exists on both, we compose them\n if (slotPropValue && childPropValue) {\n overrideProps[propName] = (...args: unknown[]) => {\n const result = childPropValue(...args);\n slotPropValue(...args);\n return result;\n };\n }\n // but if it exists only on the slot, we use only this one\n else if (slotPropValue) {\n overrideProps[propName] = slotPropValue;\n }\n }\n // if it's `style`, we merge them\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\n return { ...slotProps, ...overrideProps };\n}\n\n// Before React 19 accessing `element.props.ref` will throw a warning and suggest using `element.ref`\n// After React 19 accessing `element.ref` does the opposite.\n// https://github.com/facebook/react/pull/28348\n//\n// Access the ref using the method that doesn't yield a warning.\nfunction getElementRef(element: React.ReactElement) {\n // React <=18 in DEV\n let getter = Object.getOwnPropertyDescriptor(element.props, 'ref')?.get;\n let mayWarn = getter && 'isReactWarning' in getter && getter.isReactWarning;\n if (mayWarn) {\n return (element as any).ref;\n }\n\n // React 19 in DEV\n getter = Object.getOwnPropertyDescriptor(element, 'ref')?.get;\n mayWarn = getter && 'isReactWarning' in getter && getter.isReactWarning;\n if (mayWarn) {\n return (element.props as { ref?: React.Ref<unknown> }).ref;\n }\n\n // Not DEV\n return (element.props as { ref?: React.Ref<unknown> }).ref || (element as any).ref;\n}\n\nexport {\n Slot,\n Slottable,\n //\n Slot as Root,\n};\nexport type { SlotProps };\n","import * as React from 'react';\nimport * as ReactDOM from 'react-dom';\nimport { createSlot } from '@radix-ui/react-slot';\n\nconst NODES = [\n 'a',\n 'button',\n 'div',\n 'form',\n 'h2',\n 'h3',\n 'img',\n 'input',\n 'label',\n 'li',\n 'nav',\n 'ol',\n 'p',\n 'select',\n 'span',\n 'svg',\n 'ul',\n] as const;\n\ntype Primitives = { [E in (typeof NODES)[number]]: PrimitiveForwardRefComponent<E> };\ntype PrimitivePropsWithRef<E extends React.ElementType> = React.ComponentPropsWithRef<E> & {\n asChild?: boolean;\n};\n\ninterface PrimitiveForwardRefComponent<E extends React.ElementType>\n extends React.ForwardRefExoticComponent<PrimitivePropsWithRef<E>> {}\n\n/* -------------------------------------------------------------------------------------------------\n * Primitive\n * -----------------------------------------------------------------------------------------------*/\n\nconst Primitive = NODES.reduce((primitive, node) => {\n const Slot = createSlot(`Primitive.${node}`);\n const Node = React.forwardRef((props: PrimitivePropsWithRef<typeof node>, forwardedRef: any) => {\n const { asChild, ...primitiveProps } = props;\n const Comp: any = asChild ? Slot : node;\n\n if (typeof window !== 'undefined') {\n (window as any)[Symbol.for('radix-ui')] = true;\n }\n\n return <Comp {...primitiveProps} ref={forwardedRef} />;\n });\n\n Node.displayName = `Primitive.${node}`;\n\n return { ...primitive, [node]: Node };\n}, {} as Primitives);\n\n/* -------------------------------------------------------------------------------------------------\n * Utils\n * -----------------------------------------------------------------------------------------------*/\n\n/**\n * Flush custom event dispatch\n * https://github.com/radix-ui/primitives/pull/1378\n *\n * React batches *all* event handlers since version 18, this introduces certain considerations when using custom event types.\n *\n * Internally, React prioritises events in the following order:\n * - discrete\n * - continuous\n * - default\n *\n * https://github.com/facebook/react/blob/a8a4742f1c54493df00da648a3f9d26e3db9c8b5/packages/react-dom/src/events/ReactDOMEventListener.js#L294-L350\n *\n * `discrete` is an important distinction as updates within these events are applied immediately.\n * React however, is not able to infer the priority of custom event types due to how they are detected internally.\n * Because of this, it's possible for updates from custom events to be unexpectedly batched when\n * dispatched by another `discrete` event.\n *\n * In order to ensure that updates from custom events are applied predictably, we need to manually flush the batch.\n * This utility should be used when dispatching a custom event from within another `discrete` event, this utility\n * is not necessary when dispatching known event types, or if dispatching a custom type inside a non-discrete event.\n * For example:\n *\n * dispatching a known click 👎\n * target.dispatchEvent(new Event(‘click’))\n *\n * dispatching a custom type within a non-discrete event 👎\n * onScroll={(event) => event.target.dispatchEvent(new CustomEvent(‘customType’))}\n *\n * dispatching a custom type within a `discrete` event 👍\n * onPointerDown={(event) => dispatchDiscreteCustomEvent(event.target, new CustomEvent(‘customType’))}\n *\n * Note: though React classifies `focus`, `focusin` and `focusout` events as `discrete`, it's not recommended to use\n * this utility with them. This is because it's possible for those handlers to be called implicitly during render\n * e.g. when focus is within a component as it is unmounted, or when managing focus on mount.\n */\n\nfunction dispatchDiscreteCustomEvent<E extends CustomEvent>(target: E['target'], event: E) {\n if (target) ReactDOM.flushSync(() => target.dispatchEvent(event));\n}\n\n/* -----------------------------------------------------------------------------------------------*/\n\nconst Root = Primitive;\n\nexport {\n Primitive,\n //\n Root,\n //\n dispatchDiscreteCustomEvent,\n};\nexport type { PrimitivePropsWithRef };\n"],"names":["createContext","useContext","createScope","nextScopes","useLayoutEffect","Slot","props"],"mappings":";;;;;;AAwCA,SAAS,kBAAmB,CAAA,SAAA,EAAmB,sBAAwC,GAAA,EAAI,EAAA;AACzF,EAAA,IAAI,kBAAyB,EAAC,CAAA;AAM9B,EAASA,SAAAA,cAAAA,CACP,mBACA,cACA,EAAA;AACA,IAA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I,GAAA,IAAA,CAAA;AAAA,KAC5C;AAEA,IAAA,uBAAQ,GAAA,CAAA,IAAA,EAAA,EAAM,GAAG,cAAA,EAAgB,KAAK,YAAc,EAAA,CAAA,CAAA;AAAA,GACrD,CAAA,CAAA;AAED,EAAK,IAAA,CAAA,WAAA,GAAc,aAAa,IAAI,CAAA,CAAA,CAAA;AAEpC,EAAA,OAAO,EAAE,GAAG,SAAA,EAAW,CAAC,IAAI,GAAG,IAAK,EAAA,CAAA;AACtC,CAAA,EAAG,EAAgB,EAAA;AA2CnB,SAAS,2BAAA,CAAmD,QAAqB,KAAU,EAAA;AACzF,EAAA,IAAI,QAAiB,QAAA,CAAA,SAAA,CAAU,MAAM,MAAO,CAAA,aAAA,CAAc,KAAK,CAAC,CAAA,CAAA;AAClE;;;;","x_google_ignoreList":[0,1,2,3,4]}
@@ -1,104 +0,0 @@
1
- import * as React from 'react';
2
- import { c as composeRefs } from './index-b8f2908d.js';
3
- import { jsx } from 'react/jsx-runtime';
4
-
5
- // src/slot.tsx
6
- var REACT_LAZY_TYPE = Symbol.for("react.lazy");
7
- var use = React[" use ".trim().toString()];
8
- function isPromiseLike(value) {
9
- return typeof value === "object" && value !== null && "then" in value;
10
- }
11
- function isLazyComponent(element) {
12
- return element != null && typeof element === "object" && "$$typeof" in element && element.$$typeof === REACT_LAZY_TYPE && "_payload" in element && isPromiseLike(element._payload);
13
- }
14
- // @__NO_SIDE_EFFECTS__
15
- function createSlot(ownerName) {
16
- const SlotClone = /* @__PURE__ */ createSlotClone(ownerName);
17
- const Slot2 = React.forwardRef((props, forwardedRef) => {
18
- let { children, ...slotProps } = props;
19
- if (isLazyComponent(children) && typeof use === "function") {
20
- children = use(children._payload);
21
- }
22
- const childrenArray = React.Children.toArray(children);
23
- const slottable = childrenArray.find(isSlottable);
24
- if (slottable) {
25
- const newElement = slottable.props.children;
26
- const newChildren = childrenArray.map((child) => {
27
- if (child === slottable) {
28
- if (React.Children.count(newElement) > 1) return React.Children.only(null);
29
- return React.isValidElement(newElement) ? newElement.props.children : null;
30
- } else {
31
- return child;
32
- }
33
- });
34
- return /* @__PURE__ */ jsx(SlotClone, { ...slotProps, ref: forwardedRef, children: React.isValidElement(newElement) ? React.cloneElement(newElement, void 0, newChildren) : null });
35
- }
36
- return /* @__PURE__ */ jsx(SlotClone, { ...slotProps, ref: forwardedRef, children });
37
- });
38
- Slot2.displayName = `${ownerName}.Slot`;
39
- return Slot2;
40
- }
41
- // @__NO_SIDE_EFFECTS__
42
- function createSlotClone(ownerName) {
43
- const SlotClone = React.forwardRef((props, forwardedRef) => {
44
- let { children, ...slotProps } = props;
45
- if (isLazyComponent(children) && typeof use === "function") {
46
- children = use(children._payload);
47
- }
48
- if (React.isValidElement(children)) {
49
- const childrenRef = getElementRef(children);
50
- const props2 = mergeProps(slotProps, children.props);
51
- if (children.type !== React.Fragment) {
52
- props2.ref = forwardedRef ? composeRefs(forwardedRef, childrenRef) : childrenRef;
53
- }
54
- return React.cloneElement(children, props2);
55
- }
56
- return React.Children.count(children) > 1 ? React.Children.only(null) : null;
57
- });
58
- SlotClone.displayName = `${ownerName}.SlotClone`;
59
- return SlotClone;
60
- }
61
- var SLOTTABLE_IDENTIFIER = Symbol("radix.slottable");
62
- function isSlottable(child) {
63
- return React.isValidElement(child) && typeof child.type === "function" && "__radixId" in child.type && child.type.__radixId === SLOTTABLE_IDENTIFIER;
64
- }
65
- function mergeProps(slotProps, childProps) {
66
- const overrideProps = { ...childProps };
67
- for (const propName in childProps) {
68
- const slotPropValue = slotProps[propName];
69
- const childPropValue = childProps[propName];
70
- const isHandler = /^on[A-Z]/.test(propName);
71
- if (isHandler) {
72
- if (slotPropValue && childPropValue) {
73
- overrideProps[propName] = (...args) => {
74
- const result = childPropValue(...args);
75
- slotPropValue(...args);
76
- return result;
77
- };
78
- } else if (slotPropValue) {
79
- overrideProps[propName] = slotPropValue;
80
- }
81
- } else if (propName === "style") {
82
- overrideProps[propName] = { ...slotPropValue, ...childPropValue };
83
- } else if (propName === "className") {
84
- overrideProps[propName] = [slotPropValue, childPropValue].filter(Boolean).join(" ");
85
- }
86
- }
87
- return { ...slotProps, ...overrideProps };
88
- }
89
- function getElementRef(element) {
90
- let getter = Object.getOwnPropertyDescriptor(element.props, "ref")?.get;
91
- let mayWarn = getter && "isReactWarning" in getter && getter.isReactWarning;
92
- if (mayWarn) {
93
- return element.ref;
94
- }
95
- getter = Object.getOwnPropertyDescriptor(element, "ref")?.get;
96
- mayWarn = getter && "isReactWarning" in getter && getter.isReactWarning;
97
- if (mayWarn) {
98
- return element.props.ref;
99
- }
100
- return element.props.ref || element.ref;
101
- }
102
-
103
- export { createSlot as c };
104
- //# sourceMappingURL=index-9bb7ddb4.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index-9bb7ddb4.js","sources":["../../../../../node_modules/@radix-ui/react-slot/src/slot.tsx"],"sourcesContent":["import * as React from 'react';\nimport { composeRefs } from '@radix-ui/react-compose-refs';\n\ndeclare module 'react' {\n interface ReactElement {\n $$typeof?: symbol | string;\n }\n}\n\nconst REACT_LAZY_TYPE = Symbol.for('react.lazy');\n\ninterface LazyReactElement extends React.ReactElement {\n $$typeof: typeof REACT_LAZY_TYPE;\n _payload: PromiseLike<Exclude<React.ReactNode, PromiseLike<any>>>;\n}\n\n/* -------------------------------------------------------------------------------------------------\n * Slot\n * -----------------------------------------------------------------------------------------------*/\n\nexport type Usable<T> = PromiseLike<T> | React.Context<T>;\nconst use: typeof React.use | undefined = (React as any)[' use '.trim().toString()];\n\ninterface SlotProps extends React.HTMLAttributes<HTMLElement> {\n children?: React.ReactNode;\n}\n\nfunction isPromiseLike(value: unknown): value is PromiseLike<unknown> {\n return typeof value === 'object' && value !== null && 'then' in value;\n}\n\nfunction isLazyComponent(element: React.ReactNode): element is LazyReactElement {\n return (\n element != null &&\n typeof element === 'object' &&\n '$$typeof' in element &&\n element.$$typeof === REACT_LAZY_TYPE &&\n '_payload' in element &&\n isPromiseLike(element._payload)\n );\n}\n\n/* @__NO_SIDE_EFFECTS__ */ export function createSlot(ownerName: string) {\n const SlotClone = createSlotClone(ownerName);\n const Slot = React.forwardRef<HTMLElement, SlotProps>((props, forwardedRef) => {\n let { children, ...slotProps } = props;\n if (isLazyComponent(children) && typeof use === 'function') {\n children = use(children._payload);\n }\n const childrenArray = React.Children.toArray(children);\n const slottable = childrenArray.find(isSlottable);\n\n if (slottable) {\n // the new element to render is the one passed as a child of `Slottable`\n const newElement = slottable.props.children;\n\n const newChildren = childrenArray.map((child) => {\n if (child === slottable) {\n // because the new element will be the one rendered, we are only interested\n // in grabbing its children (`newElement.props.children`)\n if (React.Children.count(newElement) > 1) return React.Children.only(null);\n return React.isValidElement(newElement)\n ? (newElement.props as { children: React.ReactNode }).children\n : null;\n } else {\n return child;\n }\n });\n\n return (\n <SlotClone {...slotProps} ref={forwardedRef}>\n {React.isValidElement(newElement)\n ? React.cloneElement(newElement, undefined, newChildren)\n : null}\n </SlotClone>\n );\n }\n\n return (\n <SlotClone {...slotProps} ref={forwardedRef}>\n {children}\n </SlotClone>\n );\n });\n\n Slot.displayName = `${ownerName}.Slot`;\n return Slot;\n}\n\nconst Slot = createSlot('Slot');\n\n/* -------------------------------------------------------------------------------------------------\n * SlotClone\n * -----------------------------------------------------------------------------------------------*/\n\ninterface SlotCloneProps {\n children: React.ReactNode;\n}\n\n/* @__NO_SIDE_EFFECTS__ */ function createSlotClone(ownerName: string) {\n const SlotClone = React.forwardRef<any, SlotCloneProps>((props, forwardedRef) => {\n let { children, ...slotProps } = props;\n if (isLazyComponent(children) && typeof use === 'function') {\n children = use(children._payload);\n }\n\n if (React.isValidElement(children)) {\n const childrenRef = getElementRef(children);\n const props = mergeProps(slotProps, children.props as AnyProps);\n // do not pass ref to React.Fragment for React 19 compatibility\n if (children.type !== React.Fragment) {\n props.ref = forwardedRef ? composeRefs(forwardedRef, childrenRef) : childrenRef;\n }\n return React.cloneElement(children, props);\n }\n\n return React.Children.count(children) > 1 ? React.Children.only(null) : null;\n });\n\n SlotClone.displayName = `${ownerName}.SlotClone`;\n return SlotClone;\n}\n\n/* -------------------------------------------------------------------------------------------------\n * Slottable\n * -----------------------------------------------------------------------------------------------*/\n\nconst SLOTTABLE_IDENTIFIER = Symbol('radix.slottable');\n\ninterface SlottableProps {\n children: React.ReactNode;\n}\n\ninterface SlottableComponent extends React.FC<SlottableProps> {\n __radixId: symbol;\n}\n\n/* @__NO_SIDE_EFFECTS__ */ export function createSlottable(ownerName: string) {\n const Slottable: SlottableComponent = ({ children }) => {\n return <>{children}</>;\n };\n Slottable.displayName = `${ownerName}.Slottable`;\n Slottable.__radixId = SLOTTABLE_IDENTIFIER;\n return Slottable;\n}\n\nconst Slottable = createSlottable('Slottable');\n\n/* ---------------------------------------------------------------------------------------------- */\n\ntype AnyProps = Record<string, any>;\n\nfunction isSlottable(\n child: React.ReactNode,\n): child is React.ReactElement<SlottableProps, typeof Slottable> {\n return (\n React.isValidElement(child) &&\n typeof child.type === 'function' &&\n '__radixId' in child.type &&\n child.type.__radixId === SLOTTABLE_IDENTIFIER\n );\n}\n\nfunction mergeProps(slotProps: AnyProps, childProps: AnyProps) {\n // all child props should override\n const overrideProps = { ...childProps };\n\n for (const propName in childProps) {\n const slotPropValue = slotProps[propName];\n const childPropValue = childProps[propName];\n\n const isHandler = /^on[A-Z]/.test(propName);\n if (isHandler) {\n // if the handler exists on both, we compose them\n if (slotPropValue && childPropValue) {\n overrideProps[propName] = (...args: unknown[]) => {\n const result = childPropValue(...args);\n slotPropValue(...args);\n return result;\n };\n }\n // but if it exists only on the slot, we use only this one\n else if (slotPropValue) {\n overrideProps[propName] = slotPropValue;\n }\n }\n // if it's `style`, we merge them\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\n return { ...slotProps, ...overrideProps };\n}\n\n// Before React 19 accessing `element.props.ref` will throw a warning and suggest using `element.ref`\n// After React 19 accessing `element.ref` does the opposite.\n// https://github.com/facebook/react/pull/28348\n//\n// Access the ref using the method that doesn't yield a warning.\nfunction getElementRef(element: React.ReactElement) {\n // React <=18 in DEV\n let getter = Object.getOwnPropertyDescriptor(element.props, 'ref')?.get;\n let mayWarn = getter && 'isReactWarning' in getter && getter.isReactWarning;\n if (mayWarn) {\n return (element as any).ref;\n }\n\n // React 19 in DEV\n getter = Object.getOwnPropertyDescriptor(element, 'ref')?.get;\n mayWarn = getter && 'isReactWarning' in getter && getter.isReactWarning;\n if (mayWarn) {\n return (element.props as { ref?: React.Ref<unknown> }).ref;\n }\n\n // Not DEV\n return (element.props as { ref?: React.Ref<unknown> }).ref || (element as any).ref;\n}\n\nexport {\n Slot,\n Slottable,\n //\n Slot as Root,\n};\nexport type { SlotProps };\n"],"names":["Slot","props"],"mappings":";;;;;AASA,IAAM,eAAA,GAAkB,MAAO,CAAA,GAAA,CAAI,YAAY,CAAA,CAAA;AAY/C,IAAM,MAAqC,KAAc,CAAA,OAAA,CAAQ,IAAK,EAAA,CAAE,UAAU,CAAA,CAAA;AAMlF,SAAS,cAAc,KAA+C,EAAA;AACpE,EAAA,OAAO,OAAO,KAAA,KAAU,QAAY,IAAA,KAAA,KAAU,QAAQ,MAAU,IAAA,KAAA,CAAA;AAClE,CAAA;AAEA,SAAS,gBAAgB,OAAuD,EAAA;AAC9E,EAAA,OACE,OAAW,IAAA,IAAA,IACX,OAAO,OAAA,KAAY,YACnB,UAAc,IAAA,OAAA,IACd,OAAQ,CAAA,QAAA,KAAa,eACrB,IAAA,UAAA,IAAc,OACd,IAAA,aAAA,CAAc,QAAQ,QAAQ,CAAA,CAAA;AAElC,CAAA;AAAA;AAEkC,SAAS,WAAW,SAAmB,EAAA;AACvE,EAAM,MAAA,SAAA,mCAA4B,SAAS,CAAA,CAAA;AAC3C,EAAA,MAAMA,KAAa,GAAA,KAAA,CAAA,UAAA,CAAmC,CAAC,KAAA,EAAO,YAAiB,KAAA;AAC7E,I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C,aAAe,EAAA,cAAc,EAAE,MAAO,CAAA,OAAO,CAAE,CAAA,IAAA,CAAK,GAAG,CAAA,CAAA;AAAA,KACpF;AAAA,GACF;AAEA,EAAA,OAAO,EAAE,GAAG,SAAW,EAAA,GAAG,aAAc,EAAA,CAAA;AAC1C,CAAA;AAOA,SAAS,cAAc,OAA6B,EAAA;AAElD,EAAA,IAAI,SAAS,MAAO,CAAA,wBAAA,CAAyB,OAAQ,CAAA,KAAA,EAAO,KAAK,CAAG,EAAA,GAAA,CAAA;AACpE,EAAA,IAAI,OAAU,GAAA,MAAA,IAAU,gBAAoB,IAAA,MAAA,IAAU,MAAO,CAAA,cAAA,CAAA;AAC7D,EAAA,IAAI,OAAS,EAAA;AACX,IAAA,OAAQ,OAAgB,CAAA,GAAA,CAAA;AAAA,GAC1B;AAGA,EAAA,MAAA,GAAS,MAAO,CAAA,wBAAA,CAAyB,OAAS,EAAA,KAAK,CAAG,EAAA,GAAA,CAAA;AAC1D,EAAU,OAAA,GAAA,MAAA,IAAU,gBAAoB,IAAA,MAAA,IAAU,MAAO,CAAA,cAAA,CAAA;AACzD,EAAA,IAAI,OAAS,EAAA;AACX,IAAA,OAAQ,QAAQ,KAAuC,CAAA,GAAA,CAAA;AAAA,GACzD;AAGA,EAAQ,OAAA,OAAA,CAAQ,KAAuC,CAAA,GAAA,IAAQ,OAAgB,CAAA,GAAA,CAAA;AACjF;;;;","x_google_ignoreList":[0]}
@@ -1,12 +0,0 @@
1
- import * as React from 'react';
2
- import 'react/jsx-runtime';
3
-
4
- // packages/react/direction/src/direction.tsx
5
- var DirectionContext = React.createContext(void 0);
6
- function useDirection(localDir) {
7
- const globalDir = React.useContext(DirectionContext);
8
- return localDir || globalDir || "ltr";
9
- }
10
-
11
- export { useDirection as u };
12
- //# sourceMappingURL=index-ae9b48d5.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index-ae9b48d5.js","sources":["../../../../../node_modules/@radix-ui/react-direction/src/direction.tsx"],"sourcesContent":["import * as React from 'react';\n\ntype Direction = 'ltr' | 'rtl';\nconst DirectionContext = React.createContext<Direction | undefined>(undefined);\n\n/* -------------------------------------------------------------------------------------------------\n * Direction\n * -----------------------------------------------------------------------------------------------*/\n\ninterface DirectionProviderProps {\n children?: React.ReactNode;\n dir: Direction;\n}\nconst DirectionProvider: React.FC<DirectionProviderProps> = (props) => {\n const { dir, children } = props;\n return <DirectionContext.Provider value={dir}>{children}</DirectionContext.Provider>;\n};\n\n/* -----------------------------------------------------------------------------------------------*/\n\nfunction useDirection(localDir?: Direction) {\n const globalDir = React.useContext(DirectionContext);\n return localDir || globalDir || 'ltr';\n}\n\nconst Provider = DirectionProvider;\n\nexport {\n useDirection,\n //\n Provider,\n //\n DirectionProvider,\n};\n"],"names":[],"mappings":";;;;AAGA,IAAM,gBAAA,GAAyB,oBAAqC,KAAS,CAAA,CAAA,CAAA;AAiB7E,SAAS,aAAa,QAAsB,EAAA;AAC1C,EAAM,MAAA,SAAA,GAAkB,iBAAW,gBAAgB,CAAA,CAAA;AACnD,EAAA,OAAO,YAAY,SAAa,IAAA,KAAA,CAAA;AAClC;;;;","x_google_ignoreList":[0]}