@primereact/core 11.0.0-alpha.8 → 11.0.0-rc.1

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 (46) hide show
  1. package/LICENSE.md +45 -0
  2. package/README.md +43 -0
  3. package/base/index.d.mts +1 -1
  4. package/base/index.mjs +1 -1
  5. package/base/index.mjs.map +1 -1
  6. package/component/index.d.mts +11 -9
  7. package/component/index.mjs +1 -1
  8. package/component/index.mjs.map +1 -1
  9. package/config/index.mjs +1 -1
  10. package/config/index.mjs.map +1 -1
  11. package/dnd/index.d.mts +69 -0
  12. package/dnd/index.mjs +2 -0
  13. package/dnd/index.mjs.map +1 -0
  14. package/headless/index.d.mts +1 -1
  15. package/headless/index.mjs +1 -1
  16. package/headless/index.mjs.map +1 -1
  17. package/icon/index.d.mts +3 -3
  18. package/icon/index.mjs +1 -46
  19. package/icon/index.mjs.map +1 -1
  20. package/index.d.mts +3 -0
  21. package/index.mjs +1 -1
  22. package/index.mjs.map +1 -1
  23. package/license/index.d.mts +22 -0
  24. package/license/index.mjs +2 -0
  25. package/license/index.mjs.map +1 -0
  26. package/locale/index.mjs +1 -1
  27. package/locale/index.mjs.map +1 -1
  28. package/motion/index.d.mts +24 -10
  29. package/motion/index.mjs +1 -1
  30. package/motion/index.mjs.map +1 -1
  31. package/overlay-manager/index.d.mts +84 -0
  32. package/overlay-manager/index.mjs +2 -0
  33. package/overlay-manager/index.mjs.map +1 -0
  34. package/package.json +13 -15
  35. package/passthrough/index.mjs +1 -1
  36. package/passthrough/index.mjs.map +1 -1
  37. package/theme/index.mjs +1 -1
  38. package/theme/index.mjs.map +1 -1
  39. package/umd/index.js +7 -212
  40. package/umd/index.js.map +1 -1
  41. package/use-style/index.mjs +1 -1
  42. package/use-style/index.mjs.map +1 -1
  43. package/utils/index.d.mts +73 -4
  44. package/utils/index.mjs +1 -1
  45. package/utils/index.mjs.map +1 -1
  46. package/LICENSE +0 -21
package/LICENSE.md ADDED
@@ -0,0 +1,45 @@
1
+ # PrimeUI License
2
+
3
+ This package is part of **PrimeUI**, a family of commercial UI libraries by PrimeTek Informatics.
4
+
5
+ ## How PrimeUI May Be Used
6
+
7
+ PrimeUI may be used under one of two licenses. You choose the one that applies to you based on eligibility.
8
+
9
+ ### Community License (Free)
10
+
11
+ Free for organizations that meet all of the following criteria:
12
+
13
+ - Less than $1,000,000 USD in annual gross revenue
14
+ - Fewer than 5 developers
15
+ - Fewer than 10 employees
16
+ - Less than $3,000,000 USD in venture capital or outside funding
17
+
18
+ Individuals, students, non-profits, and non-commercial open source projects also qualify.
19
+
20
+ The Community License provides full access to the core libraries and supports up to 4 developers. It requires annual renewal by confirming continued eligibility.
21
+
22
+ ### Commercial License (Paid)
23
+
24
+ For organizations that do not qualify for the Community License.
25
+
26
+ Licensed per developer, perpetual, with one year of updates included. Renewal is optional and extends access to new versions. The Commercial Suite also includes PrimeBlocks, Theme Designer, all PrimeUI Pro components, and Premium Support.
27
+
28
+ ## License Key
29
+
30
+ A valid license key is required to use this software. License verification is performed offline, with no telemetry and no remote connection. A missing, invalid, or expired key may cause the software to display a license notice.
31
+
32
+ ## Full Terms
33
+
34
+ The complete license terms, eligibility details, and renewal information are available at:
35
+
36
+ - Community License: https://primeui.dev/licenses/community
37
+ - Commercial License: https://primeui.dev/licenses/commercial
38
+
39
+ ## Restrictions
40
+
41
+ This software is distributed as a compiled package. You may not reverse-engineer, decompile, or extract its source code, redistribute it as a component library or development tool, or remove its license mechanisms. Redistributing the software so that third parties can develop with it requires a separate OEM License. See the full terms for details.
42
+
43
+ ---
44
+
45
+ © 2026 PrimeTek Informatics. All rights reserved.
package/README.md CHANGED
@@ -1 +1,44 @@
1
1
  # PrimeReact Core
2
+
3
+ Shared infrastructure for PrimeReact components. Every component in the library depends on this package for configuration, theming, Pass Through (PT), and styling.
4
+
5
+ ## Configuration
6
+
7
+ `PrimeReactProvider` and the `usePrimeReact()` hook expose global settings (theme, locale, ripple, PT defaults) through React context. Wrap the application once and every component reads from the same config.
8
+
9
+ ## Base component system
10
+
11
+ `useBase()` and `useComponent()` are the foundation every PrimeReact component is built on. They handle prop resolution, attribute selection, style injection, and PT application so component authors don't repeat that logic.
12
+
13
+ ## Pass Through (PT)
14
+
15
+ The PT system lets consumers override any internal DOM attribute or class on any element inside a component without forking it. PT values can be objects or functions receiving the current instance and state.
16
+
17
+ ## Styling
18
+
19
+ Dynamic stylesheet loading and `useStyle()` for injecting scoped CSS at runtime. Integrates with `@primeuix/styled` for design token resolution.
20
+
21
+ ## Utilities
22
+
23
+ Locale management, license verification, overlay positioning, DnD helpers, and re-exports of common utilities from `@primeuix/utils`.
24
+
25
+ ## Usage
26
+
27
+ ```tsx
28
+ import { PrimeReactProvider } from '@primereact/core';
29
+ import Aura from '@primeuix/themes/aura';
30
+
31
+ export default function App() {
32
+ return <PrimeReactProvider value={{ theme: { preset: Aura } }}>{/* components */}</PrimeReactProvider>;
33
+ }
34
+ ```
35
+
36
+ ```tsx
37
+ import { usePrimeReact } from '@primereact/core';
38
+
39
+ const { config, locale } = usePrimeReact();
40
+ ```
41
+
42
+ ## License
43
+
44
+ Licensed under the [PrimeUI License](https://primeui.dev/licenses) - Copyright (c) [PrimeTek Informatics](https://www.primetek.com.tr)
package/base/index.d.mts CHANGED
@@ -12,6 +12,6 @@ import * as React from 'react';
12
12
  declare const useBase: <IProps extends {
13
13
  id?: string;
14
14
  ref?: React.Ref<unknown>;
15
- }, DProps, Exposes extends Record<PropertyKey, unknown>>(name: string | undefined, options: useBaseOptions<IProps, DProps, Exposes>) => Instance<Pick<IProps & DProps, keyof DProps>, IProps, Record<PropertyKey, unknown>, Exposes>;
15
+ }, DProps, Exposes extends Record<PropertyKey, unknown>>(name: string | undefined, options: useBaseOptions<IProps, DProps, Exposes>) => Instance<Pick<DProps & IProps, keyof DProps>, IProps, Record<PropertyKey, unknown>, Exposes>;
16
16
 
17
17
  export { useBase };
package/base/index.mjs CHANGED
@@ -1,2 +1,2 @@
1
- var S=Object.defineProperty,b=Object.defineProperties;var v=Object.getOwnPropertyDescriptors;var k=Object.getOwnPropertySymbols;var K=Object.prototype.hasOwnProperty,T=Object.prototype.propertyIsEnumerable;var C=(t,o,e)=>o in t?S(t,o,{enumerable:!0,configurable:!0,writable:!0,value:e}):t[o]=e,c=(t,o)=>{for(var e in o||(o={}))K.call(o,e)&&C(t,e,o[e]);if(k)for(var e of k(o))T.call(o,e)&&C(t,e,o[e]);return t},R=(t,o)=>b(t,v(o));import{usePrimeReact as j}from"@primereact/core/config";import{combinedRefs as A}from"@primereact/core/utils";import{useAttrSelector as U,useId as _,useProps as h}from"@primereact/hooks";import{resolve as H}from"@primeuix/utils";import*as n from"react";var N=(t="UnknownBase",o)=>{var x,E,B;let e=j(),{inProps:s,defaultProps:l,setup:L}=o||{},d=_(s==null?void 0:s.id),I=U("pc_"),a=n.useRef((x=s==null?void 0:s.ref)!=null?x:null),i=n.useRef(null),f=n.useMemo(()=>({ref:a,elementRef:i,id:d,name:t,inProps:s,$attrSelector:I,$primereact:e}),[d,s,I,e]),O=n.useMemo(()=>{var M,g,w,D;let p=H(((g=(M=e==null?void 0:e.config)==null?void 0:M.defaults)==null?void 0:g[t])||((D=(w=e==null?void 0:e.config)==null?void 0:w.defaults)==null?void 0:D[t.toLowerCase()]),f);return c(c({},l),p==null?void 0:p.props)},[l,(B=(E=e==null?void 0:e.config)==null?void 0:E.defaults)==null?void 0:B[t]]),{props:y,attrs:P}=h(s,O),u=n.useMemo(()=>R(c({},f),{props:y,attrs:P}),[f,y,P]),r=H(L,u),m=n.useMemo(()=>{var p;return R(c(c({state:{},$computedSetup:r},r),u),{elementRef:(p=r==null?void 0:r.elementRef)!=null?p:i})},[r,u]);return n.useEffect(()=>{A(a,s==null?void 0:s.ref)},[a,s==null?void 0:s.ref]),n.useImperativeHandle(a,()=>m,[m]),m};export{N as useBase};
1
+ var S=Object.defineProperty,v=Object.defineProperties;var C=Object.getOwnPropertyDescriptors;var w=Object.getOwnPropertySymbols;var D=Object.prototype.hasOwnProperty,T=Object.prototype.propertyIsEnumerable;var k=(e,s,t)=>s in e?S(e,s,{enumerable:!0,configurable:!0,writable:!0,value:t}):e[s]=t,a=(e,s)=>{for(var t in s||(s={}))D.call(s,t)&&k(e,t,s[t]);if(w)for(var t of w(s))T.call(s,t)&&k(e,t,s[t]);return e},R=(e,s)=>v(e,C(s));import{usePrimeReact as j}from"@primereact/core/config";import{useAttrSelector as A,useId as U,useProps as _}from"@primereact/hooks";import{resolve as L,toKebabCase as $}from"@primeuix/utils";import*as o from"react";var F=(e="UnknownBase",s)=>{var M;let t=j(),{type:i,inProps:n,defaultProps:d,setup:l}=s||{},P=U(n==null?void 0:n.id),I=A("pc_"),[H,K]=o.useMemo(()=>e.toLowerCase().split("."),[e]),y=o.useRef(null),x=o.useRef(void 0),u=o.useMemo(()=>({ref:y,elementRef:x,id:P,name:e,type:i,scope:H,part:$(K),inProps:n,$attrSelector:I,$primereact:t}),[P,n,I,t,e,i]),r=(M=t.config)==null?void 0:M.defaults,O=o.useMemo(()=>{let c=L((r==null?void 0:r[e])||(r==null?void 0:r[e.toLowerCase()]),u);return a(a({},d),c==null?void 0:c.props)},[d,r,e]),{props:B,attrs:E}=_(O,n),m=o.useMemo(()=>R(a({},u),{props:B,attrs:E}),[u,B,E]),p=L(l,m),f=o.useMemo(()=>{var c;return R(a(a({state:{},$computedSetup:p},p),m),{elementRef:(c=p==null?void 0:p.elementRef)!=null?c:x})},[p,m]);return o.useImperativeHandle(y,()=>f,[f]),f};export{F as useBase};
2
2
  //# sourceMappingURL=index.mjs.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/base/useBase.ts"],"sourcesContent":["import { usePrimeReact } from '@primereact/core/config';\nimport { combinedRefs } from '@primereact/core/utils';\nimport { useAttrSelector, useId, useProps } from '@primereact/hooks';\nimport type { BaseInstance, BaseSetup, CommonInstance, Instance, useBaseOptions } from '@primereact/types/core';\nimport { resolve } from '@primeuix/utils';\nimport * as React from 'react';\n\n/**\n * A custom hook for creating a base instance.\n * This hook is used to initialize a base instance with common properties and methods.\n * It handles props, attributes, and provides a setup function for additional configuration.\n * @param name The name of the base instance.\n * @param options The options for the base instance.\n * @returns The base instance.\n */\nexport const useBase = <IProps extends { id?: string; ref?: React.Ref<unknown> }, DProps, Exposes extends Record<PropertyKey, unknown>>(name: string = 'UnknownBase', options: useBaseOptions<IProps, DProps, Exposes>) => {\n const $primereact = usePrimeReact();\n const { inProps, defaultProps, setup } = options || {};\n\n const id = useId(inProps?.id as string | undefined);\n const $attrSelector = useAttrSelector('pc_');\n\n const ref = React.useRef(inProps?.ref ?? null);\n const elementRef = React.useRef<HTMLElement | null>(null);\n\n const base = React.useMemo<BaseInstance<IProps>>(\n () => ({\n ref,\n elementRef,\n id,\n name,\n inProps,\n $attrSelector,\n $primereact\n }),\n [id, inProps, $attrSelector, $primereact]\n );\n\n const computedDefaultProps = React.useMemo<DProps>(() => {\n const globalDefaults = resolve($primereact?.config?.defaults?.[name] || $primereact?.config?.defaults?.[name.toLowerCase()], base) as { props?: DProps } | undefined;\n\n return { ...defaultProps, ...globalDefaults?.props } as DProps;\n }, [defaultProps, $primereact?.config?.defaults?.[name]]);\n\n const { props, attrs } = useProps(inProps, computedDefaultProps);\n\n const common = React.useMemo<CommonInstance<typeof props, IProps>>(\n () => ({\n ...base,\n props,\n attrs\n }),\n [base, props, attrs]\n );\n\n const $computedSetup = resolve(setup as BaseSetup<typeof props, IProps, Exposes>, common) as Exposes;\n\n const instance = React.useMemo<Instance<typeof props, IProps, Record<PropertyKey, unknown>, Exposes>>(\n () => ({\n state: {},\n $computedSetup,\n ...$computedSetup,\n ...common,\n elementRef: ($computedSetup?.elementRef ?? elementRef) as React.RefObject<HTMLElement | null>\n }),\n [$computedSetup, common]\n );\n\n React.useEffect(() => {\n combinedRefs(ref, inProps?.ref);\n }, [ref, inProps?.ref]);\n\n React.useImperativeHandle(ref as React.Ref<Instance<typeof props, IProps, typeof instance.state, Exposes>>, () => instance,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AAoB,EAEzDQ,EAAe,UACjB,IAAOC,EAAAL,EAAA,GACAL,GADA,CAEH,MAAAM,EACA,MAAAC,CACJ,GACA,CAACP,EAAMM,EAAOC,CAAK,CACvB,EAEMI,EAAiBP,EAAQX,EAAmDgB,CAAM,EAElFG,EAAiB,UACnB,IAAG,CA1DX,IAAA1B,EA0De,OAAAwB,EAAAL,IAAA,CACH,MAAO,CAAC,EACR,eAAAM,GACGA,GACAF,GAJA,CAKH,YAAavB,EAAAyB,GAAA,YAAAA,EAAgB,aAAhB,KAAAzB,EAA8Ba,CAC/C,IACA,CAACY,EAAgBF,CAAM,CAC3B,EAEA,OAAM,YAAU,IAAM,CAClBI,EAAaf,EAAKP,GAAA,YAAAA,EAAS,GAAG,CAClC,EAAG,CAACO,EAAKP,GAAA,YAAAA,EAAS,GAAG,CAAC,EAEhB,sBAAoBO,EAAkF,IAAMc,EAAU,CAACA,CAAQ,CAAC,EAE/HA,CACX","names":["usePrimeReact","combinedRefs","useAttrSelector","useId","useProps","resolve","React","useBase","name","options","_a","_b","_c","$primereact","usePrimeReact","inProps","defaultProps","setup","id","useId","$attrSelector","useAttrSelector","ref","elementRef","base","computedDefaultProps","_d","globalDefaults","resolve","__spreadValues","props","attrs","useProps","common","__spreadProps","$computedSetup","instance","combinedRefs"]}
1
+ {"version":3,"sources":["../../src/base/useBase.ts"],"sourcesContent":["import { usePrimeReact } from '@primereact/core/config';\nimport { useAttrSelector, useId, useProps } from '@primereact/hooks';\nimport type { BaseInstance, BaseSetup, CommonInstance, Instance, useBaseOptions } from '@primereact/types/core';\nimport { resolve, toKebabCase } from '@primeuix/utils';\nimport * as React from 'react';\n\n/**\n * A custom hook for creating a base instance.\n * This hook is used to initialize a base instance with common properties and methods.\n * It handles props, attributes, and provides a setup function for additional configuration.\n * @param name The name of the base instance.\n * @param options The options for the base instance.\n * @returns The base instance.\n */\nexport const useBase = <IProps extends { id?: string; ref?: React.Ref<unknown> }, DProps, Exposes extends Record<PropertyKey, unknown>>(name: string = 'UnknownBase', options: useBaseOptions<IProps, DProps, Exposes>) => {\n const $primereact = usePrimeReact();\n const { type, inProps, defaultProps, setup } = options || {};\n\n const id = useId(inProps?.id as string | undefined);\n const $attrSelector = useAttrSelector('pc_');\n const [scope, part] = React.useMemo(() => name.toLowerCase().split('.'), [name]);\n\n const ref = React.useRef(null);\n const elementRef = React.useRef<HTMLElement | undefined>(undefined);\n\n const base = React.useMemo<BaseInstance<IProps>>(() => {\n return {\n ref,\n elementRef,\n id,\n name,\n type,\n scope,\n part: toKebabCase(part),\n inProps,\n $attrSelector,\n $primereact\n };\n }, [id, inProps, $attrSelector, $primereact, name, type]);\n\n const globalDefaultsConfig = $primereact.config?.defaults;\n const computedDefaultProps = React.useMemo<DProps>(() => {\n const globalDefaults = resolve(globalDefaultsConfig?.[name] || globalDefaultsConfig?.[name.toLowerCase()], base) as { props?: DProps } | undefined;\n\n return { ...defaultProps, ...globalDefaults?.props } as DProps;\n }, [defaultProps, globalDefaultsConfig, name]);\n\n const { props, attrs } = useProps(computedDefaultProps, inProps);\n\n const common = React.useMemo<CommonInstance<typeof props, IProps>>(\n () => ({\n ...base,\n props,\n attrs\n }),\n [base, props, attrs]\n );\n\n const $computedSetup = resolve(setup as BaseSetup<typeof props, IProps, Exposes>, common) as Exposes;\n\n const instance = React.useMemo<Instance<typeof props, IProps, Record<PropertyKey, unknown>, Exposes>>(\n () => ({\n state: {},\n $computedSetup,\n ...$computedSetup,\n ...common,\n elementRef: ($computedSetup?.elementRef ?? elementRef) as React.RefObject<HTMLElement | undefined>\n }),\n [$computedSetup, common]\n );\n\n /*React.useEffect(() => {\n combinedRefs(ref, inProps?.ref);\n }, [inProps?.ref]);\n\n combinedRefs(ref, inProps?.ref);*/\n\n React.useImperativeHandle(ref as React.Ref<Instance<typeof props, IProps, typeof instance.state, Exposes>>, () => instance, [instance]);\n\n return instance;\n};\n"],"mappings":"6aAAA,OAAS,iBAAAA,MAAqB,0BAC9B,OAAS,mBAAAC,EAAi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EAAQd,EAAmDmB,CAAM,EAElFG,EAAiB,UACnB,IAAG,CA7DX,IAAA5B,EA6De,OAAA0B,EAAAL,IAAA,CACH,MAAO,CAAC,EACR,eAAAM,GACGA,GACAF,GAJA,CAKH,YAAazB,EAAA2B,GAAA,YAAAA,EAAgB,aAAhB,KAAA3B,EAA8Bc,CAC/C,IACA,CAACa,EAAgBF,CAAM,CAC3B,EAQA,OAAM,sBAAoBZ,EAAkF,IAAMe,EAAU,CAACA,CAAQ,CAAC,EAE/HA,CACX","names":["usePrimeReact","useAttrSelector","useId","useProps","resolve","toKebabCase","React","useBase","name","options","_a","$primereact","usePrimeReact","type","inProps","defaultProps","setup","id","useId","$attrSelector","useAttrSelector","scope","part","ref","elementRef","base","toKebabCase","globalDefaultsConfig","computedDefaultProps","globalDefaults","resolve","__spreadValues","props","attrs","useProps","common","__spreadProps","$computedSetup","instance"]}
@@ -1,10 +1,10 @@
1
1
  import * as _primereact_types_core from '@primereact/types/core';
2
2
  import { ComponentInstance, ComponentProps, GlobalComponentProps, useComponentOptions, InComponentInstance, withComponentOptions } from '@primereact/types/core';
3
3
  import * as React from 'react';
4
- import * as _primereact_types_index from '@primereact/types/index';
4
+ import * as _primereact_types_types from '@primereact/types/types';
5
5
  import * as _primereact_types_styles from '@primereact/types/styles';
6
6
  import { StylesOptions } from '@primereact/types/styles';
7
- import * as _primereact_types_shared from '@primereact/types/shared';
7
+ import * as _primereact_types from '@primereact/types';
8
8
 
9
9
  /**
10
10
  * A component wrapper for rendering elements with additional props and attributes.
@@ -28,23 +28,25 @@ declare const defaultComponentProps: ComponentProps;
28
28
  * @param options The options to customize the component instance.
29
29
  * @returns The component instance.
30
30
  */
31
- declare function useComponent<IProps, DProps, Exposes extends Record<PropertyKey, unknown>, Styles>(name?: string, options?: useComponentOptions<IProps, DProps, Exposes, Styles>): InComponentInstance<_primereact_types_index.SafeRecord<Pick<IProps & {
32
- id?: string;
33
- ref?: React.Ref<unknown>;
34
- } & {
31
+ declare function useComponent<IProps, DProps, Exposes extends Record<PropertyKey, unknown>, Styles>(name?: string, options?: useComponentOptions<IProps, DProps, Exposes, Styles>): InComponentInstance<_primereact_types_types.SafeRecord<Pick<{
35
32
  ref?: React.Ref<unknown> | undefined;
36
33
  pIf?: boolean | undefined;
37
34
  style?: React.CSSProperties | ((instance?: _primereact_types_core.ComponentInstance<Record<PropertyKey, unknown>, Record<PropertyKey, unknown>, Record<PropertyKey, unknown>> | undefined) => React.CSSProperties | undefined) | undefined;
38
35
  className?: string | ((instance?: _primereact_types_core.ComponentInstance<Record<PropertyKey, unknown>, Record<PropertyKey, unknown>, Record<PropertyKey, unknown>> | undefined) => string | undefined) | undefined;
39
36
  as?: string | number | bigint | boolean | React.ComponentClass<any, any> | React.FunctionComponent<any> | React.ReactElement<unknown, string | React.JSXElementConstructor<any>> | Iterable<React.ReactNode> | React.ReactPortal | Promise<string | number | bigint | boolean | React.ReactPortal | React.ReactElement<unknown, string | React.JSXElementConstructor<any>> | Iterable<React.ReactNode> | null | undefined> | null | undefined;
40
37
  asChild?: boolean | undefined;
38
+ instance?: _primereact_types_core.ComponentInstance<Record<PropertyKey, unknown>, Record<PropertyKey, unknown>, Record<PropertyKey, unknown>> | undefined;
41
39
  pt?: Record<PropertyKey, unknown> | undefined;
42
40
  ptOptions?: _primereact_types_core.PassThroughOptions | undefined;
43
41
  unstyled?: boolean | undefined;
44
42
  dt?: unknown;
45
43
  styles?: _primereact_types_styles.StylesOptions | undefined;
46
- children?: React.ReactNode | ((instance: _primereact_types_core.ComponentInstance<Record<PropertyKey, unknown>, Record<PropertyKey, unknown>, Record<PropertyKey, unknown>>) => React.ReactNode);
47
- }, "dt" | "style" | "ref" | "pIf" | "className" | "as" | "asChild" | "pt" | "ptOptions" | "unstyled" | "styles" | "children">>, IProps, Record<PropertyKey, unknown>, Exposes>;
44
+ render?: ((instance: _primereact_types_core.ComponentInstance<Record<PropertyKey, unknown>, Record<PropertyKey, unknown>, Record<PropertyKey, unknown>>) => React.ReactNode) | undefined;
45
+ children?: any;
46
+ } & IProps & {
47
+ id?: string;
48
+ ref?: React.Ref<unknown>;
49
+ }, "dt" | "style" | "children" | "ref" | "pIf" | "className" | "as" | "asChild" | "instance" | "pt" | "ptOptions" | "unstyled" | "styles" | "render">>, IProps, Record<PropertyKey, unknown>, Exposes>;
48
50
 
49
51
  /**
50
52
  * A higher-order component for enhancing a component with additional features.
@@ -64,6 +66,6 @@ declare function useComponent<IProps, DProps, Exposes extends Record<PropertyKey
64
66
  * @param options.render A render function for the component.
65
67
  * @returns A React component wrapped with the specified options.
66
68
  */
67
- declare function withComponent<IProps, DProps, Exposes extends Record<PropertyKey, unknown> = Record<PropertyKey, unknown>, Styles = StylesOptions, CData = Record<string, unknown>>({ name, defaultProps, styles, components, setup, render }: withComponentOptions<IProps, DProps, Exposes, Styles, CData>): (<I extends ComponentInstance, T extends React.ElementType>(inProps?: IProps & _primereact_types_core.GlobalComponentProps<I, unknown, T, unknown, unknown> & {} & {} & Omit<_primereact_types_shared.ExtractProps<T>, keyof _primereact_types_core.GlobalComponentProps<I_1, P, T_1, unknown, unknown> | keyof IProps> & DProps) => React.JSX.Element | null) & CData & React.FC<{}>;
69
+ declare function withComponent<IProps, DProps, Exposes extends Record<PropertyKey, unknown> = Record<PropertyKey, unknown>, Styles = StylesOptions, CData = Record<string, unknown>>({ name, type, defaultProps, styles, components, setup, render }: withComponentOptions<IProps, DProps, Exposes, Styles, CData>): (<I extends ComponentInstance, T extends React.ElementType>(inProps?: IProps & _primereact_types_core.GlobalComponentProps<I, unknown, T, unknown, unknown> & {} & {} & Omit<_primereact_types.ExtractProps<T>, keyof _primereact_types_core.GlobalComponentProps<I_1, P, T_1, unknown, unknown> | keyof IProps> & DProps) => React.JSX.Element | null) & CData & React.FC<{}>;
68
70
 
69
71
  export { Component, defaultComponentProps, globalProps, useComponent, withComponent };
@@ -1,2 +1,2 @@
1
- var Ce=Object.defineProperty,Pe=Object.defineProperties;var Se=Object.getOwnPropertyDescriptors;var J=Object.getOwnPropertySymbols;var pe=Object.prototype.hasOwnProperty,ue=Object.prototype.propertyIsEnumerable;var ce=(p,u,l)=>u in p?Ce(p,u,{enumerable:!0,configurable:!0,writable:!0,value:l}):p[u]=l,s=(p,u)=>{for(var l in u||(u={}))pe.call(u,l)&&ce(p,l,u[l]);if(J)for(var l of J(u))ue.call(u,l)&&ce(p,l,u[l]);return p},I=(p,u)=>Pe(p,Se(u));var $=(p,u)=>{var l={};for(var r in p)pe.call(p,r)&&u.indexOf(r)<0&&(l[r]=p[r]);if(p!=null&&J)for(var r of J(p))u.indexOf(r)<0&&ue.call(p,r)&&(l[r]=p[r]);return l};import{isValidElement as he}from"@primereact/core/utils";import{cn as be,resolve as Q}from"@primeuix/utils";import*as U from"react";function we(p={}){var d,h,T,k;let A=p,{pIf:u=!0,style:l,className:r,as:a,asChild:R,instance:n}=A,e=$(A,["pIf","style","className","as","asChild","instance"]);if(u===!1)return null;let m=a||((d=n==null?void 0:n.props)==null?void 0:d.as)||U.Fragment,i=R||((h=n==null?void 0:n.props)==null?void 0:h.asChild),P=m===U.Fragment,w=e,{ref:C=n==null?void 0:n.elementRef,children:f,attrs:O}=w,M=$(w,["ref","children","attrs"]),N=s(s({},O),M),j=Q(f,n,N),D=Q(l||((T=n==null?void 0:n.props)==null?void 0:T.style),n),B=Q(r||((k=n==null?void 0:n.props)==null?void 0:k.className),n);return i||P?U.createElement(U.Fragment,null,j):he(m)?Q(m,n):U.createElement(m,I(s({},N),{ref:C,style:s(s({},N.style),D),className:be(N.className,B)}),j)}we.displayName="PrimeReact.Component";import{omit as ke}from"@primeuix/utils";var ee={ref:void 0,pIf:!0,style:void 0,className:void 0,as:void 0,asChild:!1,pt:void 0,ptOptions:void 0,unstyled:void 0,dt:void 0,children:void 0},He=I(s({},ke(ee,"pt","ptOptions","dt","styles")),{instance:void 0,attrs:void 0});import{useBase as je}from"@primereact/core/base";import*as W from"react";import{useMountEffect as Te,useUnmountEffect as Ie,useUpdateEffect as xe}from"@primereact/hooks";import{mergeProps as ne}from"@primeuix/utils/mergeprops";import{getKeyValue as X,isArray as Oe,isFunction as _e,isNotEmpty as Ee,isString as te,resolve as le,toFlatCase as q}from"@primeuix/utils/object";import*as g from"react";function me(p,u){var F,G,z;let{id:l,name:r,props:a,attrs:R,$primereact:n,$attrSelector:e}=p||{},m=g.useCallback(t=>{let o=M(O(a.pt,r),X,`hooks.${t}`),c=h(X,`hooks.${t}`);o==null||o(),c==null||c()},[a.pt,r]),i=g.useCallback((t,...o)=>_e(t)?t(...o):t?ne(...o):Object.assign({},...o),[]),P=g.useCallback((t={},o="",c={},y=!0)=>{var ae;let b=/./g.test(o)&&!!c[o.split(".")[0]],{mergeSections:v=!0,mergeProps:S=!1}=(a==null?void 0:a.ptOptions)||((ae=n.passthrough)==null?void 0:ae.options)||{},L=y?b?d(f,o,c):h(f,o,c):void 0,_=b?void 0:A(t,f,o,I(s({},c),{global:L||{}})),E=C(o);return v||!v&&_?i(S,L,_,E):s(s({},_),E)},[a.ptOptions,i]),C=g.useCallback((t="")=>{var y,b;let o="data-pc-",c=t==="root"&&Ee((y=a==null?void 0:a.pt)==null?void 0:y["data-pc-section"]);return t!=="transition"&&I(s({},t==="root"&&I(s({[`${o}name`]:q(c?(b=a.pt)==null?void 0:b["data-pc-section"]:r)},c&&{[`${o}extend`]:q(r)}),{[`${e}`]:""})),{[`${o}section`]:q(t)})},[a.pt,e]),f=g.useCallback((t={},o="",c)=>{let y=X(t,o,c);return te(y)||Oe(y)?{className:y}:y},[]),O=g.useCallback((t,o="",c)=>{let y=(b,v=!1)=>{var E;let S=c?c(b):b,L=q(o),_=q(r);return(E=v?L!==_?S==null?void 0:S[L]:void 0:S==null?void 0:S[L])!=null?E:S};return t&&Object.hasOwn(t,"_usept")?{_usept:t._usept,originalValue:y(t.originalValue),value:y(t.value)}:y(t,!0)},[]),M=g.useCallback((t,o,c="",y)=>{var v;let b=S=>o(S,c,y);if(t&&Object.hasOwn(t,"_usept")){let{mergeSections:S=!0,mergeProps:L=!1}=t._usept||((v=n.passthrough)==null?void 0:v.options)||{},_=b(t.originalValue),E=b(t.value);return _===void 0&&E===void 0?void 0:te(E)?E:te(_)?_:S||!S&&E?i(L,_,E):E}return b(t)},[(F=n.passthrough)==null?void 0:F.options,i]),N=g.useMemo(()=>{var t;return O((t=n==null?void 0:n.passthrough)==null?void 0:t.value,void 0,o=>le(o,p))},[(G=n==null?void 0:n.passthrough)==null?void 0:G.value]),j=g.useMemo(()=>{var t;return O((t=n==null?void 0:n.passthrough)==null?void 0:t.value,void 0,o=>X(o,r,p)||le(o,p))},[(z=n==null?void 0:n.passthrough)==null?void 0:z.value]),D=g.useMemo(()=>Object.entries(R||{}).filter(([t])=>t==null?void 0:t.startsWith("pt-")).reduce((t,[o,c])=>{let[,y,...b]=o.split("-");return[y,b==null?void 0:b.join("-")].filter(Boolean).reduce((v,S,L,_)=>(v[S]||(v[S]=L===_.length-1?c:{}),v[S]),t),t},{}),[R]),B=g.useMemo(()=>Object.entries(R||{}).filter(([t])=>!(t!=null&&t.startsWith("pt-"))).reduce((t,[o,c])=>(t[o]=c,t),{}),[R]),A=g.useCallback((t={},o,c="",y)=>ne(M(O(t,r),o,c,y),M(D,o,c,y)),[D]),d=g.useCallback((t,o="",c)=>M(N,t,o,c),[N]),h=g.useCallback((t,o,c)=>M(j,t,o,c),[j]),w=g.useCallback((t="",o={})=>P(a.pt,t,s(s({},u),o)),[a.pt,u]),T=g.useCallback((t="",o={})=>{var y;let c=ne(B,w(t,o));return c&&Object.hasOwn(c,"id")&&((y=c.id)!=null||(c.id=l)),c},[w,l,B]),k=g.useCallback((t={},o="",c={})=>P(t,o,s(s({},u),c),!1),[u]);return Te(()=>m("onMounted")),xe(()=>m("onUpdated")),Ie(()=>m("onUnmounted")),g.useMemo(()=>({ptm:w,ptmi:T,ptmo:k}),[w,T,k])}import{StyleRegistry as Y}from"@primereact/core/utils";import{Theme as H,ThemeService as Le}from"@primeuix/styled";import{cn as Ke,getKeyValue as re}from"@primeuix/utils";import*as x from"react";import{ThemeContext as Me}from"@primereact/core/theme";import{useStyle as Ne}from"@primereact/core/use-style";import{css as oe,dt as ie,Theme as K}from"@primeuix/styled";import{isNotEmpty as ve,minifyCSS as se,resolve as de,toElement as Fe}from"@primeuix/utils";import*as V from"react";function fe(p,u){let l=V.useContext(Me),[r]=Ne(),a=V.useCallback((R,n)=>r({name:n==null?void 0:n.name,css:R,element:Fe(u),options:n}),[r,u]);return V.useMemo(()=>{let R=I(s({name:"base"},p),{load(n="",e={},m="",i=!1){let P=e.name||R.name,C=oe`${n}${m}`,f=i?K.transformCSS(P,C):C;return ve(f)?a(se(f),s({name:P},e)):{}},loadCSS(n){return this.load(this.css,n)},loadStyle(n,e=""){return this.load(this.style,n,e,!0)},getCommonTheme(n){return K.getCommon(this.name,n)},getComponentTheme(n){return K.getComponent(this.name,n)},getPresetTheme(n,e,m){return K.getCustomPreset(this.name,n,e,m)},getLayerOrderThemeCSS(){return K.getLayerOrderCSS(this.name)},getStyleSheet(n="",e={}){if(this.css){let m=de(this.css,{dt:ie}),i=se(oe`${m}${n}`),P=Object.entries(e).reduce((C,[f,O])=>(C.push(`${f}="${O}"`),C),[]).join(" ");return`<style type="text/css" data-primereact-style-id="${this.name}" ${P}>${i}</style>`}return""},getCommonThemeStyleSheet(n,e={}){return K.getCommonStyleSheet(this.name,n,e)},getThemeStyleSheet(n,e={}){let m=[K.getStyleSheet(this.name,n,e)];if(l){let i=this.name==="base"?"global-style":`${this.name}-style`,P=oe`${de(l,{dt:ie})}`,C=se(K.transformCSS(this.name,P)),f=Object.entries(e).reduce((O,[M,N])=>(O.push(`${M}="${N}"`),O),[]).join(" ");m.push(`<style type="text/css" data-primereact-style-id="${i}" ${f}>${C}</style>`)}return m.join("")}});return R},[p,l,a])}function ye(p,u,l){var A;let{props:r={unstyled:!1,dt:void 0},$primereact:a,$attrSelector:R,elementRef:n}=p||{},e=fe(u,n),m=x.useRef(null),i=x.useCallback(()=>{if(!Y.isStyleNameLoaded("base")){let{css:d}=e.baseStyles||{};e.load(d,s({name:"base"},f)),Y.setLoadedStyleName("base")}M()},[e]),P=x.useCallback(()=>{i(),j(i)},[i]),C=x.useMemo(()=>{var d;return r.unstyled!==void 0?r.unstyled:(d=a==null?void 0:a.config)==null?void 0:d.unstyled},[r,a==null?void 0:a.config]),f=x.useMemo(()=>{var d,h;return{nonce:(h=(d=a==null?void 0:a.config)==null?void 0:d.csp)==null?void 0:h.nonce}},[a==null?void 0:a.config]),O=x.useCallback(()=>{if(!Y.isStyleNameLoaded(e==null?void 0:e.name)&&(e!=null&&e.name)){let d=e.name==="global"?"base":e.name;e.loadCSS(s({name:d},f)),Y.setLoadedStyleName(e.name)}},[e,f]),M=x.useCallback(()=>{var d,h,w,T;if(!(C||(a==null?void 0:a.theme)==="none")){if(!H.isStyleNameLoaded("common")){let{primitive:k,semantic:F,global:G,style:z}=((d=e==null?void 0:e.getCommonTheme)==null?void 0:d.call(e))||{};e.load(k==null?void 0:k.css,s({name:"primitive-variables"},f)),e.load(F==null?void 0:F.css,s({name:"semantic-variables"},f)),e.load(G==null?void 0:G.css,s({name:"global-variables"},f)),e.load((h=e.baseStyles)==null?void 0:h.style,s({name:"global-style"},f),z,!0),H.setLoadedStyleName("common")}if(!H.isStyleNameLoaded(e==null?void 0:e.name)&&(e!=null&&e.name)){let{css:k,style:F}=((w=e==null?void 0:e.getComponentTheme)==null?void 0:w.call(e))||{};e.load(k,s({name:`${e.name}-variables`},f)),e.loadStyle(s({name:`${e.name}-style`},f),F),H.setLoadedStyleName(e.name)}if(!H.isStyleNameLoaded("layer-order")){let k=(T=e==null?void 0:e.getLayerOrderThemeCSS)==null?void 0:T.call(e);e.load(k,s({name:"layer-order",first:!0},f)),H.setLoadedStyleName("layer-order")}}},[C,e,f]),N=d=>{var T;let{css:h}=((T=e==null?void 0:e.getPresetTheme)==null?void 0:T.call(e,d,`[${R}]`))||{},w=e==null?void 0:e.load(h,s({name:`${R}-${e.name}`},f));m.current=w},j=x.useCallback((d=()=>{})=>{Le.on("theme:change",d)},[]),D=x.useCallback((d="",h={})=>C?void 0:Ke(re(e.classes,d,I(s({},l),{context:h}))),[C,p,e.classes]),B=x.useCallback((d="",h=!0,w={})=>{var T;if(h){let k=re(e.inlineStyles,d,I(s({},l),{context:w})),F=re((T=e.baseStyles)==null?void 0:T.inlineStyles,d,I(s({},l),{context:w}));return s(s({},F),k)}},[e.inlineStyles,(A=e.baseStyles)==null?void 0:A.inlineStyles,p]);return C||(O(),P(),N(r.dt)),x.useMemo(()=>({cx:D,sx:B,isUnstyled:C,$style:e}),[D,B,C,e])}function Re(p="UnknownComponent",u={}){let l=W.useMemo(()=>s(s({},ee),u.defaultProps),[u.defaultProps]),r=je(p,{inProps:u.inProps,defaultProps:l,setup:u.setup}),{ref:a,props:R}=r,n=W.useMemo(()=>({instance:r,props:r.props,attrs:r.attrs,state:r.state}),[r.props,r.attrs,r.state]),e=me(r,n),m=ye(r,R.styles||u.styles,n),i=W.useMemo(()=>s(s(s({},r),e),m),[r,e,m]);return W.useImperativeHandle(a,()=>i,[i]),i}import{isObject as ge}from"@primeuix/utils";import*as Z from"react";function Pn({name:p="UnknownComponent",defaultProps:u,styles:l,components:r,setup:a,render:R}){let e=Z.memo(m=>{let i=Re(p,{inProps:m,defaultProps:u,styles:l,setup:a}),P=R!=null?R:(()=>null);return i.props.pIf?Z.createElement(P,s({},i)):null},(m,i)=>!ge(m)||!ge(i)?!1:m===i&&Object.keys(u||{}).every(P=>m[P]===i[P]));return e.displayName=`PrimeReact.${p}`,Object.entries(r||{}).forEach(([m,i])=>{e[m]=i}),e}export{we as Component,He as defaultComponentProps,ee as globalProps,Re as useComponent,Pn as withComponent};
1
+ var Se=Object.defineProperty,he=Object.defineProperties;var we=Object.getOwnPropertyDescriptors;var J=Object.getOwnPropertySymbols;var ce=Object.prototype.hasOwnProperty,ue=Object.prototype.propertyIsEnumerable;var ae=(c,r,p)=>r in c?Se(c,r,{enumerable:!0,configurable:!0,writable:!0,value:p}):c[r]=p,a=(c,r)=>{for(var p in r||(r={}))ce.call(r,p)&&ae(c,p,r[p]);if(J)for(var p of J(r))ue.call(r,p)&&ae(c,p,r[p]);return c},I=(c,r)=>he(c,we(r));var $=(c,r)=>{var p={};for(var t in c)ce.call(c,t)&&r.indexOf(t)<0&&(p[t]=c[t]);if(c!=null&&J)for(var t of J(c))r.indexOf(t)<0&&ue.call(c,t)&&(p[t]=c[t]);return p};import{isValidElement as be,mergeRefs as ke}from"@primereact/core/utils";import{cn as Te,resolve as Q}from"@primeuix/utils";import*as A from"react";function xe(c={}){var j,D,v,d,R;let L=c,{pIf:r=!0,style:p,className:t,as:l,asChild:w,instance:n,render:e}=L,m=$(L,["pIf","style","className","as","asChild","instance","render"]);if(r===!1)return null;let u=l||((j=n==null?void 0:n.props)==null?void 0:j.as)||A.Fragment,f=e||w||((D=n==null?void 0:n.props)==null?void 0:D.asChild),y=u===A.Fragment,N=m,{ref:g,children:C,attrs:x}=N,O=$(N,["ref","children","attrs"]),b=a(a({},x),O),F=Q(e!=null?e:C,n,b),M=Q(p||((v=n==null?void 0:n.props)==null?void 0:v.style),n),H=Q(t||((d=n==null?void 0:n.props)==null?void 0:d.className),n);if(f||y)return A.createElement(A.Fragment,null,F);if(be(u))return Q(u,n);{let o=I(a({},b),{style:a(a({},b.style),M),className:Te(b.className,H)}),s=ke(n==null?void 0:n.elementRef,b.ref,g,(R=n==null?void 0:n.props)==null?void 0:R.ref);return o.children?A.createElement(u,I(a({},o),{ref:s})):A.createElement(u,I(a({},o),{ref:s}),F)}}xe.displayName="PrimeReact.Component";import{omit as Ie}from"@primeuix/utils";var ee=Object.freeze({ref:void 0,pIf:!0,style:void 0,className:void 0,as:void 0,asChild:!1,instance:void 0,pt:void 0,ptOptions:void 0,unstyled:void 0,dt:void 0,styles:void 0,render:void 0,children:void 0}),Ye=Object.freeze(I(a({},Ie(ee,"pt","ptOptions","dt","styles")),{attrs:void 0}));import{useBase as Ge}from"@primereact/core/base";import*as z from"react";import{useMountEffect as ve,useUnmountEffect as Ke,useUpdateEffect as Fe}from"@primereact/hooks";import{mergeProps as Le}from"@primeuix/utils/mergeprops";import{getKeyValue as ne,isNotEmpty as je,isString as le,resolve as pe}from"@primeuix/utils/object";import*as T from"react";import{mergeProps as Oe}from"@primeuix/utils/mergeprops";import{getKeyValue as Ee,isArray as _e,isFunction as Me,isString as Ne,toFlatCase as ie}from"@primeuix/utils/object";function X(c,...r){return Me(c)?c(...r):c?Oe(...r):Object.assign({},...r)}function Y(c={},r="",p){let t=Ee(c,r,p);return Ne(t)||_e(t)?{className:t}:t}function U(c,r,p,t){let l=(w,n=!1)=>{var f;let e=t?t(w):w,m=ie(r!=null?r:""),u=ie(p!=null?p:"");return(f=n?m!==u?e==null?void 0:e[m]:void 0:e==null?void 0:e[m])!=null?f:e};return c&&Object.hasOwn(c,"_usept")?{_usept:c._usept,originalValue:l(c.originalValue),value:l(c.value)}:l(c,!0)}function me(c,r){let{id:p,name:t,scope:l,part:w,props:n,attrs:e,$primereact:m,$attrSelector:u}=c||{},f=m==null?void 0:m.passthrough,y=f==null?void 0:f.value,g=f==null?void 0:f.options,C=T.useCallback((o,s,i="",S)=>{let h=k=>s(k,i,S);if(o&&Object.hasOwn(o,"_usept")){let{mergeSections:k=!0,mergeProps:K=!1}=o._usept||g||{},E=h(o.originalValue),_=h(o.value);return E===void 0&&_===void 0?void 0:le(_)?_:le(E)?E:k||!k&&_?X(K,E,_):_}return h(o)},[g]),x=T.useCallback(o=>{let s=C(U(n.pt,t,t),ne,`hooks.${o}`),i=C(U(y,void 0,t),ne,`hooks.${o}`);s==null||s(),i==null||i()},[n.pt,t,C,y]),O=T.useMemo(()=>U(y,void 0,t,o=>pe(o,c)),[y,t]),b=T.useMemo(()=>U(y,void 0,t,o=>ne(o,t,c)||pe(o,c)),[y,t]),F=T.useMemo(()=>Object.entries(e||{}).filter(([o])=>o==null?void 0:o.startsWith("pt-")).reduce((o,[s,i])=>{let[,S,...h]=s.split("-");return[S,h==null?void 0:h.join("-")].filter(Boolean).reduce((k,K,E,_)=>(k[K]||(k[K]=E===_.length-1?i:{}),k[K]),o),o},{}),[e]),M=T.useMemo(()=>Object.entries(e||{}).filter(([o])=>!(o!=null&&o.startsWith("pt-"))).reduce((o,[s,i])=>(o[s]=i,o),{}),[e]),H=T.useCallback((o="")=>{let s="data-";return o==="root"&&je(e==null?void 0:e["data-scope"])?{[`${s}extend`]:l,[`${s}styled`]:l}:I(a({[`${s}scope`]:l},o==="root"&&{[`${s}part`]:w,[`${s}id`]:u,[`${s}styled`]:l}),{[`${s}slot`]:o})},[l,w,u,e]),L=T.useCallback((o={},s,i="",S)=>{let h=C(U(o,t,t),s,i,S),k=C(F,s,i,S);return X(!0,h!=null?h:{},k!=null?k:{})},[F,C,t]),j=T.useCallback((o,s="",i)=>C(O,o,s,i),[O,C]),D=T.useCallback((o,s,i)=>C(b,o,s,i),[b,C]),N=T.useCallback((o={},s="",i={},S=!0)=>{let h=s.includes(".")&&!!i[s.split(".")[0]],{mergeSections:k=!0,mergeProps:K=!1}=(n==null?void 0:n.ptOptions)||g||{},E=S?h?j(Y,s,i):D(Y,s,i):void 0,_=h?void 0:L(o,Y,s,I(a({},i),{global:E||{}})),re=H(s);return k||!k&&_?X(K,E,_,re):a(a({},_),re)},[n.ptOptions,j,D,L,H]),v=T.useCallback((o="",s={})=>N(n.pt,o,a(a({},r),s)),[n.pt,r,N]),d=T.useCallback((o="",s={})=>{var S;let i=Le(M,v(o,s));return i&&Object.hasOwn(i,"id")&&((S=i.id)!=null||(i.id=p)),i},[v,p,M]),R=T.useCallback((o={},s="",i={})=>N(o,s,a(a({},r),i),!1),[r,N]);return ve(()=>x("onMounted")),Fe(()=>x("onUpdated")),Ke(()=>x("onUnmounted")),T.useMemo(()=>({ptm:v,ptmi:d,ptmo:R}),[v,d,R])}import{isDev as He,StyleRegistry as q}from"@primereact/core/utils";import{Theme as W,ThemeService as ye}from"@primeuix/styled";import{cn as Ue,getKeyValue as se,isClient as V}from"@primeuix/utils";import*as P from"react";import{ThemeContext as De}from"@primereact/core/theme";import{useStyle as Ae}from"@primereact/core/use-style";import{css as te,dt as de,Theme as B}from"@primeuix/styled";import{isNotEmpty as Be,minifyCSS as oe,resolve as fe,toElement as Ve}from"@primeuix/utils";import*as G from"react";function Re(c,r){let p=G.useContext(De),[t]=Ae(),l=G.useCallback((w,n)=>t({name:n==null?void 0:n.name,css:w,element:Ve(r),options:n}),[t,r]);return G.useMemo(()=>{let w=I(a({name:"base"},c),{load(n="",e={},m="",u=!1){let f=e.name||w.name,y=te`${n}${m}`,g=u?B.transformCSS(f,y):y;return Be(g)?l(oe(g),a({name:f},e)):void 0},loadCSS(n){return this.load(this.css,n)},loadStyle(n,e=""){return this.load(this.style,n,e,!0)},getCommonTheme(n){return B.getCommon(this.name,n)},getComponentTheme(n){return B.getComponent(this.name,n)},getPresetTheme(n,e,m){return B.getCustomPreset(this.name,n,e,m)},getLayerOrderThemeCSS(){return B.getLayerOrderCSS(this.name)},getStyleSheet(n="",e={}){if(this.css){let m=fe(this.css,{dt:de}),u=oe(te`${m}${n}`),f=Object.entries(e).reduce((y,[g,C])=>(y.push(`${g}="${C}"`),y),[]).join(" ");return`<style type="text/css" data-primereact-style-id="${this.name}" ${f}>${u}</style>`}return""},getCommonThemeStyleSheet(n,e={}){return B.getCommonStyleSheet(this.name,n,e)},getThemeStyleSheet(n,e={}){let m=[B.getStyleSheet(this.name,n,e)];if(p){let u=this.name==="base"?"global-style":`${this.name}-style`,f=te`${fe(p,{dt:de})}`,y=oe(B.transformCSS(this.name,f)),g=Object.entries(e).reduce((C,[x,O])=>(C.push(`${x}="${O}"`),C),[]).join(" ");m.push(`<style type="text/css" data-primereact-style-id="${u}" ${g}>${y}</style>`)}return m.join("")}});return w},[c,p,l])}function ge(c,r,p){var j,D,N,v;let{props:t={unstyled:!1,dt:void 0},$primereact:l,$attrSelector:w,elementRef:n}=c||{},e=Re(r,n),m=P.useMemo(()=>{var d;return t.unstyled!==void 0?t.unstyled:(d=l==null?void 0:l.config)==null?void 0:d.unstyled},[t.unstyled,(j=l==null?void 0:l.config)==null?void 0:j.unstyled]),u=P.useMemo(()=>{var d,R;return{nonce:(R=(d=l==null?void 0:l.config)==null?void 0:d.csp)==null?void 0:R.nonce}},[(N=(D=l==null?void 0:l.config)==null?void 0:D.csp)==null?void 0:N.nonce]),f=P.useRef(null),y=P.useRef(!1),g=P.useRef(null),C=P.useRef(null),x=P.useRef(!1);if(He){let d=r==null?void 0:r.style,R=typeof d=="string"?d:null;R!==null&&C.current!==R&&(C.current=R,x.current=!0)}let O=P.useCallback(()=>{if(!(e!=null&&e.name))return;let d=e.name==="global"?"base":e.name;if(!V()){e.loadCSS(a({name:d},u));return}g.current&&g.current!==e.name&&(q.releaseStyleName(g.current),g.current=null);let R=x.current;(R||!g.current)&&((R||q.retainStyleName(e.name))&&e.loadCSS(a({name:d},u)),g.current=e.name)},[e,u]),b=P.useCallback(()=>{if(m||(l==null?void 0:l.theme)==="none")return;let d=()=>{var K,E;let{primitive:i,semantic:S,global:h,style:k}=((K=e==null?void 0:e.getCommonTheme)==null?void 0:K.call(e))||{};e.load(i==null?void 0:i.css,a({name:"primitive-variables"},u)),e.load(S==null?void 0:S.css,a({name:"semantic-variables"},u)),e.load(h==null?void 0:h.css,a({name:"global-variables"},u)),e.load((E=e.baseStyles)==null?void 0:E.style,a({name:"global-style"},u),k,!0)},R=()=>{var h;let{css:i,style:S}=((h=e==null?void 0:e.getComponentTheme)==null?void 0:h.call(e))||{};e.load(i,a({name:`${e.name}-variables`},u)),e.loadStyle(a({name:`${e.name}-style`},u),S)},o=()=>{var S;let i=(S=e==null?void 0:e.getLayerOrderThemeCSS)==null?void 0:S.call(e);e.load(i,a({name:"layer-order",first:!0},u))};if(!V()){d(),e!=null&&e.name&&R(),o();return}let s=x.current;(s||!W.isStyleNameLoaded("common"))&&(d(),W.setLoadedStyleName("common")),(s||!W.isStyleNameLoaded(e==null?void 0:e.name))&&(e!=null&&e.name)&&(R(),W.setLoadedStyleName(e.name)),(s||!W.isStyleNameLoaded("layer-order"))&&(o(),W.setLoadedStyleName("layer-order"))},[m,e,u]),F=P.useCallback(()=>{let{css:d}=e.baseStyles||{};if(!V()){e.load(d,a({name:"base"},u)),b();return}let R=x.current;(R||!y.current)&&(y.current=!0,(R||q.retainStyleName("base"))&&e.load(d,a({name:"base"},u))),b(),x.current=!1},[e,u,b]),M=P.useCallback(d=>{var s;let{css:R}=((s=e==null?void 0:e.getPresetTheme)==null?void 0:s.call(e,d,`[${w}]`))||{},o=e==null?void 0:e.load(R,a({name:`${w}-${e.name}`},u));f.current=o||null},[e,w,u]),H=P.useCallback((d="",R={})=>m?void 0:Ue(se(e.classes,d,I(a({},p),{context:R}))),[m,p,e.classes]),L=P.useCallback((d="",R=!0,o={})=>{var s;if(R){let i=se(e.inlineStyles,d,I(a({},p),{context:o})),S=se((s=e.baseStyles)==null?void 0:s.inlineStyles,d,I(a({},p),{context:o}));return a(a({},S),i)}},[e.inlineStyles,(v=e.baseStyles)==null?void 0:v.inlineStyles,p]);return!V()&&!m&&(O(),F(),M(t.dt)),P.useInsertionEffect(()=>{!V()||m||(O(),F())},[m,O,F]),P.useEffect(()=>{if(!V()||m||(l==null?void 0:l.theme)==="none")return;let d=()=>{b(),M(t.dt)};return ye.on("theme:change",d),()=>{ye.off("theme:change",d)}},[m,l==null?void 0:l.theme,b,M,t.dt]),P.useInsertionEffect(()=>{var d;if(!(!V()||m))return(d=f.current)==null||d.remove(),f.current=null,M(t.dt),()=>{var R;(R=f.current)==null||R.remove(),f.current=null}},[m,t.dt,M]),P.useEffect(()=>{if(V())return()=>{y.current&&(q.releaseStyleName("base"),y.current=!1),g.current&&(q.releaseStyleName(g.current),g.current=null)}},[]),P.useMemo(()=>({cx:H,sx:L,isUnstyled:m,$style:e}),[H,L,m,e])}function Ce(c="UnknownComponent",r={}){let p=z.useMemo(()=>a(a({},ee),r.defaultProps),[r.defaultProps]),t=Ge(c,{type:r.type,inProps:r.inProps,defaultProps:p,setup:r.setup}),{ref:l,props:w}=t,n=z.useMemo(()=>({instance:t,props:t.props,attrs:t.attrs,state:t.state}),[t.props,t.attrs,t.state]),e=me(t,n),m=ge(t,w.styles||r.styles,n),u=z.useMemo(()=>a(a(a({},t),e),m),[t,e,m]);return z.useImperativeHandle(l,()=>u,[u]),u}import{isObject as Pe}from"@primeuix/utils";import*as Z from"react";function _n({name:c="UnknownComponent",type:r="primitive",defaultProps:p,styles:t,components:l,setup:w,render:n}){let m=Z.memo(u=>{let f=Ce(c,{type:r,inProps:u,defaultProps:p,styles:t,setup:w}),y=n!=null?n:(()=>null);return f.props.pIf?Z.createElement(y,a({},f)):null},(u,f)=>{if(!Pe(u)||!Pe(f))return!1;let y=u,g=f,C=Object.keys(y);if(C.length!==Object.keys(g).length)return!1;for(let x of C){let O=y[x],b=g[x];if(typeof O=="function"||typeof b=="function"){if(O!==b)return!1;continue}if(!Object.is(O,b))return!1}return!0});return m.displayName=`PrimeReact.${c}`,Object.entries(l||{}).forEach(([u,f])=>{m[u]=f}),m}export{xe as Component,Ye as defaultComponentProps,ee as globalProps,Ce as useComponent,_n as withComponent};
2
2
  //# sourceMappingURL=index.mjs.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/component/Component.tsx","../../src/component/Component.props.ts","../../src/component/useComponent.ts","../../src/component/useComponentPT.ts","../../src/component/useComponentStyle.ts","../../src/component/useComponentStyleHandler.ts","../../src/component/withComponent.tsx"],"sourcesContent":["import { isValidElement } from '@primereact/core/utils';\nimport type { ComponentInstance, ComponentProps } from '@primereact/types/core';\nimport { cn, resolve } from '@primeuix/utils';\nimport * as React from 'react';\n\n/**\n * A component wrapper for rendering elements with additional props and attributes.\n * @param inProps The properties to pass to the component.\n * @returns A React element or null if `pIf` is false.\n */\nexport function Component<I extends ComponentInstance = ComponentInstance>(inProps: ComponentProps<I> = {}) {\n const { pIf = true, style, className, as, asChild, instance, ...props } = inProps;\n\n if (pIf === false) return null;\n\n const AsComponent = (as || instance?.props?.as || React.Fragment) as React.ElementType;\n const renderAsChild = asChild || instance?.props?.asChild;\n const isFragment = AsComponent === React.Fragment;\n\n const { ref = instance?.elementRef, children, attrs: inAttrs, ...restAttrs } = props;\n const attrs = { ...inAttrs, ...restAttrs } as React.HTMLAttributes<HTMLElement>;\n // @ts-expect-error: Update resolve to handle attrs correctly\n const content = resolve(children, instance, attrs) as React.ReactNode;\n const styles = resolve(style || instance?.props?.style, instance) as React.CSSProperties | undefined;\n const classNames = resolve(className || instance?.props?.className, instance) as string | undefined;\n\n return renderAsChild || isFragment ? (\n <React.Fragment>{content}</React.Fragment>\n ) : isValidElement(AsComponent) ? (\n resolve(AsComponent, instance)\n ) : (\n <AsComponent {...attrs} ref={ref} style={{ ...attrs.style, ...styles }} className={cn(attrs.className, classNames)}>\n {content}\n </AsComponent>\n );\n}\n\nComponent.displayName = 'PrimeReact.Component';\n","import type { ComponentProps, GlobalComponentProps } from '@primereact/types/core';\nimport { omit } from '@primeuix/utils';\n\nexport const globalProps: GlobalComponentProps = {\n ref: undefined,\n pIf: true,\n style: undefined,\n className: undefined,\n as: undefined,\n asChild: false,\n pt: undefined,\n ptOptions: undefined,\n unstyled: undefined,\n dt: undefined,\n children: undefined\n};\n\nexport const defaultComponentProps: ComponentProps = {\n ...(omit(globalProps, 'pt', 'ptOptions', 'dt', 'styles') as Record<PropertyKey, unknown>),\n instance: undefined,\n attrs: undefined\n};\n","import { useBase } from '@primereact/core/base';\nimport type { InComponentInstance, useBaseOptions, useComponentOptions } from '@primereact/types/core';\nimport * as React from 'react';\nimport { globalProps } from './Component.props';\nimport { useComponentPT } from './useComponentPT';\nimport { useComponentStyle } from './useComponentStyle';\n\n/**\n * A hook for creating a component instance.\n * This hook initializes a component with properties, attributes, and styles, and provides methods for handling pass-through options and styles.\n * It also supports custom setup functions for additional configuration.\n *\n * @param name The name of the component, used for debugging and identification.\n * @param options The options to customize the component instance.\n * @returns The component instance.\n */\nexport function useComponent<IProps, DProps, Exposes extends Record<PropertyKey, unknown>, Styles>(name: string = 'UnknownComponent', options: useComponentOptions<IProps, DProps, Exposes, Styles> = {}) {\n const defaultProps = React.useMemo(() => ({ ...globalProps, ...options.defaultProps }), [options.defaultProps]);\n const baseInstance = useBase(name, {\n inProps: options.inProps,\n defaultProps,\n setup: options.setup\n } as useBaseOptions<IProps & { id?: string; ref?: React.Ref<unknown> }, typeof defaultProps, Exposes>);\n\n const { ref, props } = baseInstance;\n const $params = React.useMemo(() => {\n return {\n instance: baseInstance,\n props: baseInstance.props,\n attrs: baseInstance.attrs,\n state: baseInstance.state\n };\n }, [baseInstance.props, baseInstance.attrs, baseInstance.state]);\n\n const ptx = useComponentPT(baseInstance, $params);\n const stx = useComponentStyle(baseInstance, props.styles || options.styles, $params);\n\n const instance = React.useMemo<InComponentInstance<typeof props, IProps, typeof baseInstance.state, Exposes>>(\n () => ({\n ...baseInstance,\n ...ptx,\n ...stx\n }),\n [baseInstance, ptx, stx]\n );\n\n React.useImperativeHandle(ref as React.Ref<InComponentInstance<typeof props, IProps, typeof baseInstance.state, Exposes>>, () => instance, [instance]);\n\n return instance;\n}\n","import { useMountEffect, useUnmountEffect, useUpdateEffect } from '@primereact/hooks';\nimport type { GlobalComponentProps, Instance, PassThroughOptions, useComponentPTReturnType } from '@primereact/types/core';\nimport { mergeProps } from '@primeuix/utils/mergeprops';\nimport { getKeyValue, isArray, isFunction, isNotEmpty, isString, resolve, toFlatCase } from '@primeuix/utils/object';\nimport * as React from 'react';\n\n/**\n * A hook for managing pass-through options for a component.\n *\n * @param instance The instance of the component.\n * @param $params Additional parameters for the hook.\n * @returns An object containing the pass-through options.\n */\nexport function useComponentPT<Props extends GlobalComponentProps, IProps, Params>(instance: Instance<Props, IProps>, $params?: Params): useComponentPTReturnType {\n const { id, name, props, attrs, $primereact, $attrSelector } = instance || {};\n\n // methods\n const _hook = React.useCallback(\n (hookName: string) => {\n const selfHook = _usePT(_getPT(props.pt, name), getKeyValue, `hooks.${hookName}`) as (() => void) | undefined;\n const defaultHook = _useDefaultPT(getKeyValue, `hooks.${hookName}`) as (() => void) | undefined;\n\n selfHook?.();\n defaultHook?.();\n },\n [props.pt, name]\n );\n\n const _mergeProps = React.useCallback(<T extends unknown[], R = Record<PropertyKey, unknown>>(fn: ((...args: T) => R | undefined) | boolean, ...args: T): R => {\n return (isFunction(fn) ? fn(...args) : fn ? mergeProps(...args) : Object.assign({}, ...args)) as R;\n }, []);\n\n const _getPTValue = React.useCallback(\n (obj = {}, key = '', params: Record<string, unknown> = {}, searchInDefaultPT = true) => {\n const searchOut = /./g.test(key) && !!params[key.split('.')[0]];\n // @ts-expect-error - @todo\n const { mergeSections = true, mergeProps: useMergeProps = false } = props?.ptOptions || $primereact.passthrough?.options || {};\n const global = searchInDefaultPT ? (searchOut ? _useGlobalPT(_getPTClassValue, key, params) : _useDefaultPT(_getPTClassValue, key, params)) : undefined;\n const self = searchOut ? undefined : _getPTSelf(obj, _getPTClassValue, key, { ...params, global: global || {} });\n const datasets = _getPTDatasets(key);\n\n return mergeSections || (!mergeSections && self) ? _mergeProps(useMergeProps, global, self, datasets) : { ...self, ...datasets };\n },\n [props.ptOptions, _mergeProps]\n );\n\n const _getPTDatasets = React.useCallback(\n (key = '') => {\n const datasetPrefix = 'data-pc-';\n const isExtended = key === 'root' && isNotEmpty(props?.pt?.['data-pc-section']);\n\n return (\n key !== 'transition' && {\n ...(key === 'root' && {\n [`${datasetPrefix}name`]: toFlatCase((isExtended ? props.pt?.['data-pc-section'] : name) as string),\n ...(isExtended && { [`${datasetPrefix}extend`]: toFlatCase(name!) }),\n [`${$attrSelector}`]: ''\n }),\n [`${datasetPrefix}section`]: toFlatCase(key)\n }\n );\n },\n [props.pt, $attrSelector]\n );\n\n const _getPTClassValue = React.useCallback((obj: Record<string, unknown> = {}, key = '', params?: Record<string, unknown>) => {\n const value = getKeyValue(obj, key, params);\n\n return isString(value) || isArray(value) ? { className: value } : value;\n }, []);\n\n const _getPT = React.useCallback(<Fn extends (...args: unknown[]) => unknown>(pt?: Record<string, unknown>, key = '', fn?: Fn) => {\n const getValue = (value: unknown, checkSameKey = false) => {\n const computedValue = (fn ? fn(value) : value) as Record<string, unknown>;\n const _key = toFlatCase(key);\n const _cKey = toFlatCase(name!);\n\n return ((checkSameKey ? (_key !== _cKey ? computedValue?.[_key] : undefined) : computedValue?.[_key]) ?? computedValue) as Record<string, unknown>;\n };\n\n return pt && Object.hasOwn(pt, '_usept')\n ? {\n _usept: pt['_usept'],\n originalValue: getValue(pt.originalValue),\n value: getValue(pt.value)\n }\n : getValue(pt, true);\n }, []);\n\n const _usePT = React.useCallback(\n <Fn>(pt: Record<string, unknown>, fn: Fn, key: string = '', params?: Record<string, unknown>) => {\n const vfn = (value: unknown) => (fn as (...args: unknown[]) => unknown)(value, key, params);\n\n if (pt && Object.hasOwn(pt, '_usept')) {\n // @ts-expect-error - @todo\n const { mergeSections = true, mergeProps: useMergeProps = false } = (pt['_usept'] || $primereact.passthrough?.options || {}) as PassThroughOptions;\n const originalValue = vfn(pt.originalValue);\n const value = vfn(pt.value);\n\n if (originalValue === undefined && value === undefined) return undefined;\n else if (isString(value)) return value;\n else if (isString(originalValue)) return originalValue;\n\n return mergeSections || (!mergeSections && value) ? _mergeProps(useMergeProps, originalValue, value) : value;\n }\n\n return vfn(pt);\n },\n // @ts-expect-error - @todo\n [$primereact.passthrough?.options, _mergeProps]\n );\n\n // computed values\n // @ts-expect-error - @todo\n const $globalPT = React.useMemo(() => _getPT($primereact?.passthrough?.value, undefined, (value) => resolve(value, instance)), [$primereact?.passthrough?.value]);\n // @ts-expect-error - @todo\n const $defaultPT = React.useMemo(() => _getPT($primereact?.passthrough?.value, undefined, (value) => getKeyValue(value as Record<string, unknown>, name, instance) || resolve(value, instance)), [$primereact?.passthrough?.value]);\n const $attrsPT = React.useMemo(() => {\n return Object.entries(attrs || {})\n .filter(([key]) => key?.startsWith('pt-'))\n .reduce<Record<string, unknown>>((result, [key, value]) => {\n const [, slot, ...rest] = key.split('-');\n\n [slot, rest?.join('-')]?.filter(Boolean).reduce((currentObj, nestedKey, index, array) => {\n if (!currentObj[nestedKey]) {\n currentObj[nestedKey] = index === array.length - 1 ? value : {};\n }\n\n return currentObj[nestedKey] as Record<string, unknown>;\n }, result);\n\n return result;\n }, {});\n }, [attrs]);\n const $attrsWithoutPT = React.useMemo(() => {\n return Object.entries(attrs || {})\n .filter(([key]) => !key?.startsWith('pt-'))\n .reduce<Record<string, unknown>>((acc, [key, value]) => {\n acc[key] = value;\n\n return acc;\n }, {});\n }, [attrs]);\n\n // helpers\n const _getPTSelf = React.useCallback(\n <Fn>(obj: Record<string, unknown> = {}, fn: Fn, key: string = '', params?: Record<string, unknown>) => {\n return mergeProps(\n _usePT(_getPT(obj, name), fn, key, params), // Exp; <PRComponent pt={{ [passthrough_key]: { [attribute]: value } }}>\n _usePT($attrsPT, fn, key, params) // Exp; <PRComponent pt:[passthrough_key]:[attribute]={value}> or <PRComponent pt:[passthrough_key]={() =>{value}}>\n );\n },\n [$attrsPT]\n );\n\n const _useGlobalPT = React.useCallback(\n <Fn>(fn: Fn, key: string = '', params?: Record<string, unknown>) => {\n return _usePT($globalPT, fn, key, params);\n },\n [$globalPT]\n );\n\n const _useDefaultPT = React.useCallback(\n <Fn>(fn: Fn, key: string, params?: Record<string, unknown>) => {\n return _usePT($defaultPT, fn, key, params);\n },\n [$defaultPT]\n );\n\n // exposed methods\n const ptm = React.useCallback(\n (key = '', params: Record<string, unknown> | undefined = {}) => {\n return _getPTValue(props.pt, key, { ...$params, ...params }) as Record<string, unknown>;\n },\n [props.pt, $params]\n );\n\n const ptmi = React.useCallback(\n (key = '', params: Record<string, unknown> | undefined = {}) => {\n const _attrs = mergeProps($attrsWithoutPT, ptm(key, params)) as Record<string, unknown>;\n\n if (_attrs && Object.hasOwn(_attrs, 'id')) {\n _attrs.id ??= id;\n }\n\n return _attrs as Record<string, unknown>;\n },\n [ptm, id, $attrsWithoutPT]\n );\n\n const ptmo = React.useCallback(\n (obj: Record<string, unknown> = {}, key = '', params: Record<string, unknown> | undefined = {}) => {\n return _getPTValue(obj, key, { ...$params, ...params }, false) as Record<string, unknown>;\n },\n [$params]\n );\n\n // hooks\n useMountEffect(() => _hook('onMounted'));\n useUpdateEffect(() => _hook('onUpdated'));\n useUnmountEffect(() => _hook('onUnmounted'));\n\n return React.useMemo(\n () => ({\n ptm,\n ptmi,\n ptmo\n }),\n [ptm, ptmi, ptmo]\n );\n}\n","import { StyleRegistry } from '@primereact/core/utils';\nimport type { GlobalComponentProps, Instance, useComponentStyleReturnType } from '@primereact/types/core';\nimport { Theme, ThemeService } from '@primeuix/styled';\nimport { cn, getKeyValue } from '@primeuix/utils';\nimport * as React from 'react';\nimport { useComponentStyleHandler } from './useComponentStyleHandler';\n\n/**\n * A hook for managing component styles.\n *\n * @param instance The instance of the component.\n * @param styles The styles to apply to the component.\n * @param $params Additional parameters for the hook.\n * @returns An object containing the component styles.\n */\nexport function useComponentStyle<Props extends GlobalComponentProps, IProps, Styles, Params>(instance: Instance<Props, IProps>, styles?: Styles, $params?: Params): useComponentStyleReturnType {\n const { props = { unstyled: false, dt: undefined }, $primereact, $attrSelector, elementRef } = instance || {};\n const $style = useComponentStyleHandler(styles, elementRef);\n\n // refs\n const scopedStyleRef = React.useRef<HTMLStyleElement | null>(null);\n\n // methods\n const _load = React.useCallback(() => {\n if (!StyleRegistry.isStyleNameLoaded('base')) {\n const { css } = $style.baseStyles || {};\n\n $style.load(css, { name: 'base', ...$styleOptions });\n\n StyleRegistry.setLoadedStyleName('base');\n }\n\n _loadThemeStyles();\n }, [$style]);\n\n const _loadStyles = React.useCallback(() => {\n _load();\n _themeChangeListener(_load);\n }, [_load]);\n\n // computed values\n const $isUnstyled = React.useMemo(() => (props.unstyled !== undefined ? props.unstyled : $primereact?.config?.unstyled), [props, $primereact?.config]);\n const $styleOptions = React.useMemo(() => ({ nonce: $primereact?.config?.csp?.nonce }), [$primereact?.config]);\n\n // helpers\n const _loadCoreStyles = React.useCallback(() => {\n if (!StyleRegistry.isStyleNameLoaded($style?.name) && $style?.name) {\n const name = $style.name === 'global' ? 'base' : $style.name;\n\n $style.loadCSS({ name, ...$styleOptions });\n\n StyleRegistry.setLoadedStyleName($style.name);\n }\n }, [$style, $styleOptions]);\n\n const _loadThemeStyles = React.useCallback(() => {\n if ($isUnstyled || $primereact?.theme === 'none') return;\n\n // common\n if (!Theme.isStyleNameLoaded('common')) {\n const { primitive, semantic, global, style } = $style?.getCommonTheme?.() || {};\n\n $style.load(primitive?.css, { name: 'primitive-variables', ...$styleOptions });\n $style.load(semantic?.css, { name: 'semantic-variables', ...$styleOptions });\n $style.load(global?.css, { name: 'global-variables', ...$styleOptions });\n $style.load($style.baseStyles?.style, { name: 'global-style', ...$styleOptions }, style, true);\n\n Theme.setLoadedStyleName('common');\n }\n\n // component\n if (!Theme.isStyleNameLoaded($style?.name) && $style?.name) {\n const { css, style } = $style?.getComponentTheme?.() || {};\n\n $style.load(css, { name: `${$style.name}-variables`, ...$styleOptions });\n $style.loadStyle({ name: `${$style.name}-style`, ...$styleOptions }, style);\n\n Theme.setLoadedStyleName($style.name);\n }\n\n // layer order\n if (!Theme.isStyleNameLoaded('layer-order')) {\n const layerOrder = $style?.getLayerOrderThemeCSS?.();\n\n $style.load(layerOrder, { name: 'layer-order', first: true, ...$styleOptions });\n\n Theme.setLoadedStyleName('layer-order');\n }\n }, [$isUnstyled, $style, $styleOptions]);\n\n const _loadScopedThemeStyles = (preset: unknown) => {\n const { css } = $style?.getPresetTheme?.(preset, `[${$attrSelector}]`) || {};\n const scopedStyle = $style?.load(css, { name: `${$attrSelector}-${$style.name}`, ...$styleOptions });\n\n scopedStyleRef.current = scopedStyle as HTMLStyleElement;\n };\n\n /*const _unloadScopedThemeStyles = () => {\n scopedStyleRef.current?.remove();\n };*/\n\n const _themeChangeListener = React.useCallback((callback = () => {}) => {\n //if (!StyleRegistry.isStyleNameLoaded('base')) {\n //StyleRegistry.clearLoadedStyleNames();\n ThemeService.on('theme:change', callback);\n //}\n }, []);\n\n /*const _removeThemeListeners = () => {\n ThemeService.off('theme:change', _loadCoreStyles);\n ThemeService.off('theme:change', _load);\n ThemeService.off('theme:change', _themeScopedListener);\n };*/\n\n // exposed methods\n const cx = React.useCallback(\n (key = '', params = {}) => {\n return !$isUnstyled ? cn(getKeyValue($style.classes as Record<string, string>, key, { ...$params, context: params })) : undefined;\n },\n [$isUnstyled, instance, $style.classes]\n );\n\n const sx = React.useCallback(\n (key = '', when = true, params = {}) => {\n if (when) {\n const self = getKeyValue($style.inlineStyles as Record<string, React.CSSProperties>, key, { ...$params, context: params }) as React.CSSProperties;\n const base = getKeyValue($style.baseStyles?.inlineStyles as Record<string, React.CSSProperties>, key, { ...$params, context: params }) as React.CSSProperties;\n\n return { ...base, ...self };\n }\n\n return undefined;\n },\n [$style.inlineStyles, $style.baseStyles?.inlineStyles, instance]\n );\n\n // effects\n if (!$isUnstyled) {\n // @todo - remove\n //Theme.clearLoadedStyleNames();\n //StyleRegistry.clearLoadedStyleNames();\n _loadCoreStyles();\n _loadStyles();\n _loadScopedThemeStyles(props.dt);\n }\n\n return React.useMemo(\n () => ({\n cx,\n sx,\n isUnstyled: $isUnstyled,\n $style\n }),\n [cx, sx, $isUnstyled, $style]\n );\n}\n","import { ThemeContext } from '@primereact/core/theme';\nimport { useStyle } from '@primereact/core/use-style';\nimport type { StylesOptions, StyleType } from '@primereact/types/styles';\nimport { css as Css, dt, Theme } from '@primeuix/styled';\nimport { isNotEmpty, minifyCSS, resolve, toElement } from '@primeuix/utils';\nimport * as React from 'react';\n\n/**\n * A custom hook for managing component styles.\n *\n * @param styles The styles to apply to the component.\n * @param elementRef A reference to the HTML element.\n * @returns An object containing methods to load and manage styles.\n */\nexport function useComponentStyleHandler<Styles>(styles?: Styles, elementRef?: React.Ref<HTMLElement>) {\n const theme = React.useContext(ThemeContext);\n const [load] = useStyle();\n\n const _load = React.useCallback(\n (css?: string, options?: Record<PropertyKey, unknown>) => {\n return load({ name: options?.name as string | undefined, css, element: toElement(elementRef), options });\n },\n [load, elementRef]\n );\n\n return React.useMemo(() => {\n const handler = {\n name: 'base',\n ...(styles as StylesOptions),\n load(style: StyleType = '', options: Record<PropertyKey, unknown> & { name?: string } = {}, extendedStyle = '', enableThemeTransform = false) {\n const name = options.name || handler.name;\n const resolvedStyle = Css`${style}${extendedStyle}` as string;\n const computedStyle = enableThemeTransform ? Theme.transformCSS(name, resolvedStyle) : resolvedStyle;\n\n return isNotEmpty(computedStyle) ? _load(minifyCSS(computedStyle), { name, ...options }) : {};\n },\n loadCSS(options?: Record<PropertyKey, unknown>) {\n return this.load(this.css, options);\n },\n loadStyle(options?: Record<PropertyKey, unknown>, extendedStyle = '') {\n return this.load(this.style, options, extendedStyle, true);\n },\n getCommonTheme(params?: Record<PropertyKey, unknown>) {\n return Theme.getCommon(this.name, params);\n },\n getComponentTheme(params?: Record<PropertyKey, unknown>) {\n return Theme.getComponent(this.name, params);\n },\n // @todo: preset type\n getPresetTheme(preset: unknown, selector: string, params?: Record<PropertyKey, unknown>) {\n return Theme.getCustomPreset(this.name, preset, selector, params);\n },\n getLayerOrderThemeCSS() {\n return Theme.getLayerOrderCSS(this.name);\n },\n getStyleSheet(extendedCSS = '', props = {}) {\n if (this.css) {\n // @ts-expect-error: update dt definition in primeuix/styled\n const _css = resolve(this.css, { dt }) as string;\n const _style = minifyCSS(Css`${_css}${extendedCSS}`);\n const _props = Object.entries(props)\n .reduce<string[]>((acc, [k, v]) => {\n acc.push(`${k}=\"${v}\"`);\n\n return acc;\n }, [])\n .join(' ');\n\n return `<style type=\"text/css\" data-primereact-style-id=\"${this.name}\" ${_props}>${_style}</style>`;\n }\n\n return '';\n },\n getCommonThemeStyleSheet(params?: Record<PropertyKey, unknown>, props: Record<PropertyKey, unknown> = {}) {\n return Theme.getCommonStyleSheet(this.name, params, props);\n },\n getThemeStyleSheet(params?: Record<PropertyKey, unknown>, props: Record<PropertyKey, unknown> = {}) {\n const cssArr = [Theme.getStyleSheet(this.name, params, props)];\n\n if (theme) {\n const _name = this.name === 'base' ? 'global-style' : `${this.name}-style`;\n const _css = Css`${resolve(theme, { dt })}` as string;\n const _style = minifyCSS(Theme.transformCSS(this.name, _css));\n const _props = Object.entries(props)\n .reduce<string[]>((acc, [k, v]) => {\n acc.push(`${k}=\"${v}\"`);\n\n return acc;\n }, [])\n .join(' ');\n\n cssArr.push(`<style type=\"text/css\" data-primereact-style-id=\"${_name}\" ${_props}>${_style}</style>`);\n }\n\n return cssArr.join('');\n }\n };\n\n return handler;\n }, [styles, theme, _load]);\n}\n","import type { ComponentInstance, InComponentInstance, useComponentOptions, withComponentOptions } from '@primereact/types/core';\nimport type { BaseComponentProps } from '@primereact/types/shared';\nimport type { StylesOptions } from '@primereact/types/styles';\nimport { isObject } from '@primeuix/utils';\nimport * as React from 'react';\nimport { useComponent } from './useComponent';\n\n/**\n * A higher-order component for enhancing a component with additional features.\n *\n * @template IProps The interface for the component's input properties.\n * @template DProps The interface for the component's default properties.\n * @template Exposes The interface for the properties that the component exposes.\n * @template Styles The styles options for the component.\n * @template CData Additional data to expose on the component.\n *\n * @param options The options for the component.\n * @param options.name The name of the component, used for debugging and identification.\n * @param options.defaultProps The default properties for the component.\n * @param options.styles The styles to apply to the component.\n * @param options.components Additional components to include in the component.\n * @param options.setup A setup function for additional configuration of the component.\n * @param options.render A render function for the component.\n * @returns A React component wrapped with the specified options.\n */\nexport function withComponent<IProps, DProps, Exposes extends Record<PropertyKey, unknown> = Record<PropertyKey, unknown>, Styles = StylesOptions, CData = Record<string, unknown>>({\n name = 'UnknownComponent',\n defaultProps,\n styles,\n components,\n setup,\n render\n}: withComponentOptions<IProps, DProps, Exposes, Styles, CData>) {\n type InProps<I extends ComponentInstance, T extends React.ElementType> = BaseComponentProps<I, IProps, unknown, T> & DProps;\n\n const BaseComponent = <I extends ComponentInstance, T extends React.ElementType>(inProps?: InProps<I, T>) => {\n const instance = useComponent(name, { inProps, defaultProps, styles, setup } as useComponentOptions<InProps<I, T>, DProps, Exposes, Styles>);\n\n type RenderedComponentProps = InComponentInstance<typeof instance.props, InProps<I, T>, typeof instance.state, Exposes>;\n\n const RenderedComponent = (render as React.FC<RenderedComponentProps>) ?? (() => null);\n\n return instance.props.pIf ? <RenderedComponent {...(instance as RenderedComponentProps)} /> : null;\n };\n\n const Component = React.memo(BaseComponent, (prevProps, nextProps) => {\n if (!isObject(prevProps) || !isObject(nextProps)) {\n return false;\n }\n\n // Compare shallow equality for all defaultProps keys\n return prevProps === nextProps && Object.keys(defaultProps || {}).every((key) => (prevProps as Record<string, unknown>)[key] === (nextProps as Record<string, unknown>)[key]);\n }) as unknown as typeof BaseComponent & CData & React.FC;\n\n Component.displayName = `PrimeReact.${name}`;\n Object.entries(components || {}).forEach(([key, value]) => {\n (Component as Record<string, unknown>)[key] = value;\n });\n\n return Component;\n}\n"],"mappings":"8lBAAA,OAAS,kBAAAA,OAAsB,yBAE/B,OAAS,MAAAC,GAAI,WAAAC,MAAe,kBAC5B,UAAYC,MAAW,QAOhB,SAASC,GAA2DC,EAA6B,CAAC,EAAG,CAV5G,IAAAC,EAAAC,EAAAC,EAAAC,EAWI,IAA0EC,EAAAL,EAAlE,KAAAM,EAAM,GAAM,MAAAC,EAAO,UAAAC,EAAW,GAAAC,EAAI,QAAAC,EAAS,SAAAC,CAXvD,EAW8EN,EAAVO,EAAAC,EAAUR,EAAV,CAAxD,MAAY,QAAO,YAAW,KAAI,UAAS,aAEnD,GAAIC,IAAQ,GAAO,OAAO,KAE1B,IAAMQ,EAAeL,KAAMR,EAAAU,GAAA,YAAAA,EAAU,QAAV,YAAAV,EAAiB,KAAY,WAClDc,EAAgBL,KAAWR,EAAAS,GAAA,YAAAA,EAAU,QAAV,YAAAT,EAAiB,SAC5Cc,EAAaF,IAAsB,WAEsCG,EAAAL,EAAvE,KAAAM,EAAMP,GAAA,YAAAA,EAAU,WAAY,SAAAQ,EAAU,MAAOC,CAnBz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gB,kBACzB,UAAYC,MAAW,QAqBhB,SAASC,GAAoK,CAChL,KAAAC,EAAO,mBACP,aAAAC,EACA,OAAAC,EACA,WAAAC,EACA,MAAAC,EACA,OAAAC,CACJ,EAAiE,CAa7D,IAAMC,EAAkB,OAVyDC,GAA4B,CACzG,IAAMC,EAAWC,GAAaT,EAAM,CAAE,QAAAO,EAAS,aAAAN,EAAc,OAAAC,EAAQ,MAAAE,CAAM,CAAgE,EAIrIM,EAAqBL,GAAA,KAAAA,GAAgD,IAAM,MAEjF,OAAOG,EAAS,MAAM,IAAM,gBAACE,EAAAC,EAAA,GAAuBH,EAAqC,EAAK,IAClG,EAE4C,CAACI,EAAWC,IAChD,CAACC,GAASF,CAAS,GAAK,CAACE,GAASD,CAAS,EACpC,GAIJD,IAAcC,GAAa,OAAO,KAAKZ,GAAgB,CAAC,CAAC,EAAE,MAAOc,GAASH,EAAsCG,CAAG,IAAOF,EAAsCE,CAAG,CAAC,CAC/K,EAED,OAAAT,EAAU,YAAc,cAAcN,CAAI,GAC1C,OAAO,QAAQG,GAAc,CAAC,CAAC,EAAE,QAAQ,CAAC,CAACY,EAAKC,CAAK,IAAM,CACtDV,EAAsCS,CAAG,EAAIC,CAClD,CAAC,EAEMV,CACX","names":["isValidElement","cn","resolve","React","Component","inProps","_b","_c","_e","_f","_a","pIf","style","className","as","asChild","instance","props","__objRest","AsComponent","renderAsChild","isFragment","_d","ref","children","inAttrs","restAttrs","attrs","__spreadValues","content","resolve","styles","classNames","isValidElement","__spreadProps","cn","omit","globalProps","defaultComponentProps","__spreadProps","__spreadValues","omit","useBase","React","useMountEffect","useUnmountEffect","useUpdateEffect","mergeProps","getKeyValue","isArray","isFunction","isNotEmpty","isString","resolve","toFlatCase","React","useComponentPT","instance","$params","_a","_b","_c","id","name","props","attrs","$primereact","$attrSelector","_hook","hookName","selfHook","_usePT","_getPT","getKeyValue","defaultHook","_useDefaultPT","_mergeProps","fn","args","isFunction","mergeProps","_getPTValue","obj","key","params","searchInDefaultPT","searchOut","mergeSections","useMergeProps","global","_useGlobalPT","_getPTClassValue","self","_getPTSelf","__spreadProps","__spreadValues","datasets","_getPTDatasets","datasetPrefix","isExtended","isNotEmpty","toFlatCase","value","isString","isArray","pt","getValue","checkSameKey","computedValue","_key","_cKey","vfn","originalValue","$globalPT","resolve","$defaultPT","$attrsPT","result","slot","rest","currentObj","nestedKey","index","array","$attrsWithoutPT","acc","ptm","ptmi","_attrs","ptmo","useMountEffect","useUpdateEffect","useUnmountEffect","StyleRegistry","Theme","ThemeService","cn","getKeyValue","React","ThemeContext","useStyle","Css","dt","Theme","isNotEmpty","minifyCSS","resolve","toElement","React","useComponentStyleHandler","styles","elementRef","theme","ThemeContext","load","useStyle","_load","css","options","toElement","handler","__spreadProps","__spreadValues","style","extendedStyle","enableThemeTransform","name","resolvedStyle","Css","computedStyle","Theme","isNotEmpty","minifyCSS","params","preset","selector","extendedCSS","props","_css","resolve","dt","_style","_props","acc","k","v","cssArr","_name","useComponentStyle","instance","styles","$params","_a","props","$primereact","$attrSelector","elementRef","$style","useComponentStyleHandler","scopedStyleRef","_load","StyleRegistry","css","__spreadValues","$styleOptions","_loadThemeStyles","_loadStyles","_themeChangeListener","$isUnstyled","_b","_loadCoreStyles","name","_c","_d","Theme","primitive","semantic","global","style","layerOrder","_loadScopedThemeStyles","preset","scopedStyle","callback","ThemeService","cx","key","params","cn","getKeyValue","__spreadProps","sx","when","self","base","useComponent","name","options","defaultProps","__spreadValues","globalProps","baseInstance","useBase","ref","props","$params","ptx","useComponentPT","stx","useComponentStyle","instance","isObject","React","withComponent","name","defaultProps","styles","components","setup","render","Component","inProps","instance","useComponent","RenderedComponent","__spreadValues","prevProps","nextProps","isObject","key","value"]}
1
+ {"version":3,"sources":["../../src/component/Component.tsx","../../src/component/Component.props.ts","../../src/component/useComponent.ts","../../src/component/useComponentPT.ts","../../src/component/Component.utils.ts","../../src/component/useComponentStyle.ts","../../src/component/useComponentStyleHandler.ts","../../src/component/withComponent.tsx"],"sourcesContent":["import { isValidElement, mergeRefs } from '@primereact/core/utils';\nimport type { ComponentInstance, ComponentProps } from '@primereact/types/core';\nimport { cn, resolve } from '@primeuix/utils';\nimport * as React from 'react';\n\n/**\n * A component wrapper for rendering elements with additional props and attributes.\n * @param inProps The properties to pass to the component.\n * @returns A React element or null if `pIf` is false.\n */\nexport function Component<I extends ComponentInstance = ComponentInstance>(inProps: ComponentProps<I> = {}) {\n const { pIf = true, style, className, as, asChild, instance, render, ...props } = inProps;\n\n if (pIf === false) return null;\n\n const AsComponent = (as || instance?.props?.as || React.Fragment) as React.ElementType;\n const renderAsChild = render || asChild || instance?.props?.asChild;\n const isFragment = AsComponent === React.Fragment;\n\n const { ref: propRef, children, attrs: inAttrs, ...restAttrs } = props;\n const attrs = { ...inAttrs, ...restAttrs } as React.HTMLAttributes<HTMLElement> & React.RefAttributes<unknown>;\n const content = resolve(render ?? children, instance, attrs) as React.ReactNode;\n const styles = resolve(style || instance?.props?.style, instance) as React.CSSProperties | undefined;\n const classNames = resolve(className || instance?.props?.className, instance) as string | undefined;\n\n if (renderAsChild || isFragment) {\n return <React.Fragment>{content}</React.Fragment>;\n } else if (isValidElement(AsComponent)) {\n return resolve(AsComponent, instance);\n } else {\n const asProps = {\n ...attrs,\n style: { ...attrs.style, ...styles },\n className: cn(attrs.className, classNames)\n } as React.HTMLAttributes<HTMLElement>;\n\n // Merge refs so the rendered child fans its instance out to:\n // 1. `instance.elementRef` — drives styles, composition, `toElement` chains\n // 2. caller-supplied refs (`attrs.ref`, `props.ref`, `instance.props.ref`)\n // For nested wrappers (e.g. `<DatePicker.Input as={InputText}>`), this\n // ensures the outer wrapper's `elementRef.current` actually receives\n // the inner instance once it commits.\n const asRef = mergeRefs(instance?.elementRef as React.Ref<unknown> | undefined, attrs.ref as React.Ref<unknown> | undefined, propRef as React.Ref<unknown> | undefined, (instance?.props as { ref?: React.Ref<unknown> } | undefined)?.ref);\n\n return asProps.children ? (\n <AsComponent {...asProps} ref={asRef} />\n ) : (\n <AsComponent {...asProps} ref={asRef}>\n {content}\n </AsComponent>\n );\n }\n}\n\nComponent.displayName = 'PrimeReact.Component';\n","import type { ComponentProps, GlobalComponentProps } from '@primereact/types/core';\nimport { omit } from '@primeuix/utils';\n\nexport const globalProps: GlobalComponentProps = Object.freeze({\n ref: undefined,\n pIf: true,\n style: undefined,\n className: undefined,\n as: undefined,\n asChild: false,\n instance: undefined,\n pt: undefined,\n ptOptions: undefined,\n unstyled: undefined,\n dt: undefined,\n styles: undefined,\n render: undefined,\n children: undefined\n});\n\nexport const defaultComponentProps: ComponentProps = Object.freeze({\n ...(omit(globalProps, 'pt', 'ptOptions', 'dt', 'styles') as Record<PropertyKey, unknown>),\n attrs: undefined\n});\n","import { useBase } from '@primereact/core/base';\nimport type { InComponentInstance, useBaseOptions, useComponentOptions } from '@primereact/types/core';\nimport * as React from 'react';\nimport { globalProps } from './Component.props';\nimport { useComponentPT } from './useComponentPT';\nimport { useComponentStyle } from './useComponentStyle';\n\n/**\n * A hook for creating a component instance.\n * This hook initializes a component with properties, attributes, and styles, and provides methods for handling pass-through options and styles.\n * It also supports custom setup functions for additional configuration.\n *\n * @param name The name of the component, used for debugging and identification.\n * @param options The options to customize the component instance.\n * @returns The component instance.\n */\nexport function useComponent<IProps, DProps, Exposes extends Record<PropertyKey, unknown>, Styles>(name: string = 'UnknownComponent', options: useComponentOptions<IProps, DProps, Exposes, Styles> = {}) {\n const defaultProps = React.useMemo(() => ({ ...globalProps, ...options.defaultProps }), [options.defaultProps]);\n const baseInstance = useBase(name, {\n type: options.type,\n inProps: options.inProps,\n defaultProps,\n setup: options.setup\n } as useBaseOptions<IProps & { id?: string; ref?: React.Ref<unknown> }, typeof defaultProps, Exposes>);\n\n const { ref, props } = baseInstance;\n const $params = React.useMemo(() => {\n return {\n instance: baseInstance,\n props: baseInstance.props,\n attrs: baseInstance.attrs,\n state: baseInstance.state\n };\n }, [baseInstance.props, baseInstance.attrs, baseInstance.state]);\n\n const ptx = useComponentPT(baseInstance, $params);\n const stx = useComponentStyle(baseInstance, props.styles || options.styles, $params);\n\n const instance = React.useMemo<InComponentInstance<typeof props, IProps, typeof baseInstance.state, Exposes>>(\n () => ({\n ...baseInstance,\n ...ptx,\n ...stx\n }),\n [baseInstance, ptx, stx]\n );\n\n React.useImperativeHandle(ref as React.Ref<InComponentInstance<typeof props, IProps, typeof baseInstance.state, Exposes>>, () => instance, [instance]);\n\n return instance;\n}\n","import { useMountEffect, useUnmountEffect, useUpdateEffect } from '@primereact/hooks';\nimport type { GlobalComponentProps, Instance, PassThroughOptions, useComponentPTReturnType } from '@primereact/types/core';\nimport { mergeProps as primeuix_mergeProps } from '@primeuix/utils/mergeprops';\nimport { getKeyValue, isNotEmpty, isString, resolve } from '@primeuix/utils/object';\nimport * as React from 'react';\nimport { getPT, getPTClassValue, mergeProps } from './Component.utils';\n\n/**\n * A hook for managing pass-through options for a component.\n *\n * @param instance The instance of the component.\n * @param $params Additional parameters for the hook.\n * @returns An object containing the pass-through options.\n */\nexport function useComponentPT<Props extends GlobalComponentProps, IProps, Params>(instance: Instance<Props, IProps>, $params?: Params): useComponentPTReturnType {\n const { id, name, scope, part, props, attrs, $primereact, $attrSelector } = instance || {};\n const passthrough = $primereact?.passthrough;\n const passthroughValue = passthrough?.value;\n const passthroughOptions = passthrough?.options;\n\n const _usePT = React.useCallback(\n <Fn>(pt: Record<string, unknown>, fn: Fn, key: string = '', params?: Record<string, unknown>) => {\n const vfn = (value: unknown) => (fn as (...args: unknown[]) => unknown)(value, key, params);\n\n if (pt && Object.hasOwn(pt, '_usept')) {\n const { mergeSections = true, mergeProps: useMergeProps = false } = (pt['_usept'] || passthroughOptions || {}) as PassThroughOptions;\n const originalValue = vfn(pt.originalValue);\n const value = vfn(pt.value);\n\n if (originalValue === undefined && value === undefined) return undefined;\n else if (isString(value)) return value;\n else if (isString(originalValue)) return originalValue;\n\n return mergeSections || (!mergeSections && value) ? mergeProps(useMergeProps, originalValue, value) : value;\n }\n\n return vfn(pt);\n },\n [passthroughOptions]\n );\n\n const _hook = React.useCallback(\n (hookName: string) => {\n const selfHook = _usePT(getPT(props.pt, name, name), getKeyValue, `hooks.${hookName}`) as (() => void) | undefined;\n const defaultHook = _usePT(getPT(passthroughValue, undefined, name), getKeyValue, `hooks.${hookName}`) as (() => void) | undefined;\n\n selfHook?.();\n defaultHook?.();\n },\n [props.pt, name, _usePT, passthroughValue]\n );\n\n // computed values\n const $globalPT = React.useMemo(() => getPT(passthroughValue, undefined, name, (value) => resolve(value, instance)), [passthroughValue, name]);\n const $defaultPT = React.useMemo(() => getPT(passthroughValue, undefined, name, (value) => getKeyValue(value as Record<string, unknown>, name, instance) || resolve(value, instance)), [passthroughValue, name]);\n\n const $attrsPT = React.useMemo(() => {\n return Object.entries(attrs || {})\n .filter(([key]) => key?.startsWith('pt-'))\n .reduce<Record<string, unknown>>((result, [key, value]) => {\n const [, slot, ...rest] = key.split('-');\n\n [slot, rest?.join('-')].filter(Boolean).reduce((currentObj, nestedKey, index, array) => {\n if (!currentObj[nestedKey]) {\n currentObj[nestedKey] = index === array.length - 1 ? value : {};\n }\n\n return currentObj[nestedKey] as Record<string, unknown>;\n }, result);\n\n return result;\n }, {});\n }, [attrs]);\n\n const $attrsWithoutPT = React.useMemo(() => {\n return Object.entries(attrs || {})\n .filter(([key]) => !key?.startsWith('pt-'))\n .reduce<Record<string, unknown>>((acc, [key, value]) => {\n acc[key] = value;\n\n return acc;\n }, {});\n }, [attrs]);\n\n const _getPTDatasets = React.useCallback(\n (key = '') => {\n const datasetPrefix = 'data-';\n const isExtended = key === 'root' && isNotEmpty(attrs?.['data-scope']);\n\n return isExtended\n ? {\n [`${datasetPrefix}extend`]: scope,\n [`${datasetPrefix}styled`]: scope\n }\n : {\n [`${datasetPrefix}scope`]: scope,\n ...(key === 'root' && {\n [`${datasetPrefix}part`]: part,\n [`${datasetPrefix}id`]: $attrSelector,\n [`${datasetPrefix}styled`]: scope\n }),\n [`${datasetPrefix}slot`]: key\n };\n },\n [scope, part, $attrSelector, attrs]\n );\n\n const _getPTSelf = React.useCallback(\n <Fn>(obj: Record<string, unknown> = {}, fn: Fn, key: string = '', params?: Record<string, unknown>) => {\n const componentPT = _usePT(getPT(obj, name, name), fn, key, params) as Record<PropertyKey, unknown> | undefined;\n const attrsPT = _usePT($attrsPT, fn, key, params) as Record<PropertyKey, unknown> | undefined;\n\n return mergeProps(\n true,\n componentPT ?? {}, // Exp; <PRComponent pt={{ [passthrough_key]: { [attribute]: value } }}>\n attrsPT ?? {} // Exp; <PRComponent pt:[passthrough_key]:[attribute]={value}> or <PRComponent pt:[passthrough_key]={() =>{value}}>\n );\n },\n [$attrsPT, _usePT, name]\n );\n\n const _useGlobalPT = React.useCallback(\n <Fn>(fn: Fn, key: string = '', params?: Record<string, unknown>) => {\n return _usePT($globalPT, fn, key, params);\n },\n [$globalPT, _usePT]\n );\n\n const _useDefaultPT = React.useCallback(\n <Fn>(fn: Fn, key: string, params?: Record<string, unknown>) => {\n return _usePT($defaultPT, fn, key, params);\n },\n [$defaultPT, _usePT]\n );\n\n const _getPTValue = React.useCallback(\n (obj = {}, key = '', params: Record<string, unknown> = {}, searchInDefaultPT = true) => {\n const searchOut = key.includes('.') && !!params[key.split('.')[0]];\n const { mergeSections = true, mergeProps: useMergeProps = false } = props?.ptOptions || passthroughOptions || {};\n const global = searchInDefaultPT ? (searchOut ? _useGlobalPT(getPTClassValue, key, params) : _useDefaultPT(getPTClassValue, key, params)) : undefined;\n const self = searchOut ? undefined : _getPTSelf(obj, getPTClassValue, key, { ...params, global: global || {} });\n const datasets = _getPTDatasets(key);\n\n return mergeSections || (!mergeSections && self) ? mergeProps(useMergeProps, global, self, datasets) : { ...self, ...datasets };\n },\n [props.ptOptions, _useGlobalPT, _useDefaultPT, _getPTSelf, _getPTDatasets]\n );\n\n // exposed methods\n const ptm = React.useCallback(\n (key = '', params: Record<string, unknown> | undefined = {}) => {\n return _getPTValue(props.pt, key, { ...$params, ...params }) as Record<string, unknown>;\n },\n [props.pt, $params, _getPTValue]\n );\n\n const ptmi = React.useCallback(\n (key = '', params: Record<string, unknown> | undefined = {}) => {\n const _attrs = primeuix_mergeProps($attrsWithoutPT, ptm(key, params)) as Record<string, unknown>;\n\n if (_attrs && Object.hasOwn(_attrs, 'id')) {\n _attrs.id ??= id;\n }\n\n return _attrs as Record<string, unknown>;\n },\n [ptm, id, $attrsWithoutPT]\n );\n\n const ptmo = React.useCallback(\n (obj: Record<string, unknown> = {}, key = '', params: Record<string, unknown> | undefined = {}) => {\n return _getPTValue(obj, key, { ...$params, ...params }, false) as Record<string, unknown>;\n },\n [$params, _getPTValue]\n );\n\n // hooks\n useMountEffect(() => _hook('onMounted'));\n useUpdateEffect(() => _hook('onUpdated'));\n useUnmountEffect(() => _hook('onUnmounted'));\n\n return React.useMemo(\n () => ({\n ptm,\n ptmi,\n ptmo\n }),\n [ptm, ptmi, ptmo]\n );\n}\n","import { mergeProps as primeuix_mergeProps } from '@primeuix/utils/mergeprops';\nimport { getKeyValue, isArray, isFunction, isString, toFlatCase } from '@primeuix/utils/object';\n\n/**\n * Merges props based on the merge function or merge flag.\n */\nexport function mergeProps<T extends unknown[], R = Record<PropertyKey, unknown>>(fn: ((...args: T) => R | undefined) | boolean, ...args: T): R {\n return (isFunction(fn) ? fn(...args) : fn ? primeuix_mergeProps(...args) : Object.assign({}, ...args)) as R;\n}\n\n/**\n * Resolves a PT class value — wraps string/array values in { className }.\n */\nexport function getPTClassValue(obj: Record<string, unknown> = {}, key = '', params?: Record<string, unknown>) {\n const value = getKeyValue(obj, key, params);\n\n return isString(value) || isArray(value) ? { className: value } : value;\n}\n\n/**\n * Extracts pass-through value for a given component name from the PT object.\n */\nexport function getPT<Fn extends (...args: unknown[]) => unknown>(pt: Record<string, unknown> | undefined, key: string | undefined, name: string | undefined, fn?: Fn) {\n const getValue = (value: unknown, checkSameKey = false) => {\n const computedValue = (fn ? fn(value) : value) as Record<string, unknown>;\n const _key = toFlatCase(key ?? '');\n const _cKey = toFlatCase(name ?? '');\n\n return ((checkSameKey ? (_key !== _cKey ? computedValue?.[_key] : undefined) : computedValue?.[_key]) ?? computedValue) as Record<string, unknown>;\n };\n\n return pt && Object.hasOwn(pt, '_usept')\n ? {\n _usept: pt['_usept'],\n originalValue: getValue(pt.originalValue),\n value: getValue(pt.value)\n }\n : getValue(pt, true);\n}\n","import { isDev, StyleRegistry } from '@primereact/core/utils';\nimport type { GlobalComponentProps, Instance, useComponentStyleReturnType } from '@primereact/types/core';\nimport { Theme, ThemeService } from '@primeuix/styled';\nimport { cn, getKeyValue, isClient } from '@primeuix/utils';\nimport * as React from 'react';\nimport { useComponentStyleHandler } from './useComponentStyleHandler';\n\n/**\n * A hook for managing component styles.\n *\n * @param instance The instance of the component.\n * @param styles The styles to apply to the component.\n * @param $params Additional parameters for the hook.\n * @returns An object containing the component styles.\n */\nexport function useComponentStyle<Props extends GlobalComponentProps, IProps, Styles, Params>(instance: Instance<Props, IProps>, styles?: Styles, $params?: Params): useComponentStyleReturnType {\n const { props = { unstyled: false, dt: undefined }, $primereact, $attrSelector, elementRef } = instance || {};\n const $style = useComponentStyleHandler(styles, elementRef as React.Ref<HTMLElement> | undefined);\n const $isUnstyled = React.useMemo(() => (props.unstyled !== undefined ? props.unstyled : $primereact?.config?.unstyled), [props.unstyled, $primereact?.config?.unstyled]);\n const $styleOptions = React.useMemo(() => ({ nonce: $primereact?.config?.csp?.nonce }), [$primereact?.config?.csp?.nonce]);\n\n // refs\n const scopedStyleRef = React.useRef<HTMLStyleElement | null>(null);\n const hasRetainedBaseStyleRef = React.useRef(false);\n const retainedComponentStyleNameRef = React.useRef<string | null>(null);\n const styleContentRef = React.useRef<string | null>(null);\n const stylesChangedRef = React.useRef(false);\n\n // Detect HMR in dev: compare the actual string content of the style template.\n // When the source CSS changes, bypass the loaded-style cache so the new CSS is re-injected.\n if (isDev) {\n const nextStyleSource = (styles as { style?: unknown } | undefined)?.style;\n const nextContent = typeof nextStyleSource === 'string' ? nextStyleSource : null;\n\n if (nextContent !== null && styleContentRef.current !== nextContent) {\n styleContentRef.current = nextContent;\n stylesChangedRef.current = true;\n }\n }\n\n // helpers\n const _loadCoreStyles = React.useCallback(() => {\n if (!$style?.name) {\n return;\n }\n\n const name = $style.name === 'global' ? 'base' : $style.name;\n\n if (!isClient()) {\n $style.loadCSS({ name, ...$styleOptions });\n\n return;\n }\n\n if (retainedComponentStyleNameRef.current && retainedComponentStyleNameRef.current !== $style.name) {\n StyleRegistry.releaseStyleName(retainedComponentStyleNameRef.current);\n retainedComponentStyleNameRef.current = null;\n }\n\n const hmr = stylesChangedRef.current;\n\n if (hmr || !retainedComponentStyleNameRef.current) {\n if (hmr || StyleRegistry.retainStyleName($style.name)) {\n $style.loadCSS({ name, ...$styleOptions });\n }\n\n retainedComponentStyleNameRef.current = $style.name;\n }\n }, [$style, $styleOptions]);\n\n const _loadThemeStyles = React.useCallback(() => {\n if ($isUnstyled || $primereact?.theme === 'none') return;\n\n const loadCommonThemeStyles = () => {\n const { primitive, semantic, global, style } = $style?.getCommonTheme?.() || {};\n\n $style.load(primitive?.css, { name: 'primitive-variables', ...$styleOptions });\n $style.load(semantic?.css, { name: 'semantic-variables', ...$styleOptions });\n $style.load(global?.css, { name: 'global-variables', ...$styleOptions });\n $style.load($style.baseStyles?.style, { name: 'global-style', ...$styleOptions }, style, true);\n };\n\n const loadComponentThemeStyles = () => {\n const { css, style } = $style?.getComponentTheme?.() || {};\n\n $style.load(css, { name: `${$style.name}-variables`, ...$styleOptions });\n $style.loadStyle({ name: `${$style.name}-style`, ...$styleOptions }, style);\n };\n\n const loadLayerOrderStyles = () => {\n const layerOrder = $style?.getLayerOrderThemeCSS?.();\n\n $style.load(layerOrder, { name: 'layer-order', first: true, ...$styleOptions });\n };\n\n // Server-side renders should not rely on global loaded-name state.\n if (!isClient()) {\n loadCommonThemeStyles();\n\n if ($style?.name) {\n loadComponentThemeStyles();\n }\n\n loadLayerOrderStyles();\n\n return;\n }\n\n const hmr = stylesChangedRef.current;\n\n // common\n if (hmr || !Theme.isStyleNameLoaded('common')) {\n loadCommonThemeStyles();\n Theme.setLoadedStyleName('common');\n }\n\n // component\n if ((hmr || !Theme.isStyleNameLoaded($style?.name)) && $style?.name) {\n loadComponentThemeStyles();\n Theme.setLoadedStyleName($style.name);\n }\n\n // layer order\n if (hmr || !Theme.isStyleNameLoaded('layer-order')) {\n loadLayerOrderStyles();\n Theme.setLoadedStyleName('layer-order');\n }\n }, [$isUnstyled, $style, $styleOptions]);\n\n // methods\n const _load = React.useCallback(() => {\n const { css } = $style.baseStyles || {};\n\n if (!isClient()) {\n $style.load(css, { name: 'base', ...$styleOptions });\n\n _loadThemeStyles();\n\n return;\n }\n\n const hmr = stylesChangedRef.current;\n\n if (hmr || !hasRetainedBaseStyleRef.current) {\n hasRetainedBaseStyleRef.current = true;\n\n if (hmr || StyleRegistry.retainStyleName('base')) {\n $style.load(css, { name: 'base', ...$styleOptions });\n }\n }\n\n _loadThemeStyles();\n\n // Reset HMR flag after applying changes; subsequent renders use cached path so animations aren't disrupted.\n stylesChangedRef.current = false;\n }, [$style, $styleOptions, _loadThemeStyles]);\n\n const _loadScopedThemeStyles = React.useCallback(\n (preset: unknown) => {\n const { css } = $style?.getPresetTheme?.(preset, `[${$attrSelector}]`) || {};\n const scopedStyle = $style?.load(css, { name: `${$attrSelector}-${$style.name}`, ...$styleOptions });\n\n scopedStyleRef.current = (scopedStyle as HTMLStyleElement) || null;\n },\n [$style, $attrSelector, $styleOptions]\n );\n\n // exposed methods\n const cx = React.useCallback(\n (key = '', params = {}) => {\n return !$isUnstyled ? cn(getKeyValue($style.classes as Record<string, string>, key, { ...$params, context: params })) : undefined;\n },\n [$isUnstyled, $params, $style.classes]\n );\n\n const sx = React.useCallback(\n (key = '', when = true, params = {}) => {\n if (when) {\n const self = getKeyValue($style.inlineStyles as Record<string, React.CSSProperties>, key, { ...$params, context: params }) as React.CSSProperties;\n const base = getKeyValue($style.baseStyles?.inlineStyles as Record<string, React.CSSProperties>, key, { ...$params, context: params }) as React.CSSProperties;\n\n return { ...base, ...self };\n }\n\n return undefined;\n },\n [$style.inlineStyles, $style.baseStyles?.inlineStyles, $params]\n );\n\n if (!isClient() && !$isUnstyled) {\n _loadCoreStyles();\n _load();\n _loadScopedThemeStyles(props.dt);\n }\n\n // effects\n React.useInsertionEffect(() => {\n if (!isClient() || $isUnstyled) {\n return;\n }\n\n _loadCoreStyles();\n _load();\n }, [$isUnstyled, _loadCoreStyles, _load]);\n\n React.useEffect(() => {\n if (!isClient() || $isUnstyled || $primereact?.theme === 'none') {\n return;\n }\n\n const handleThemeChange = () => {\n _loadThemeStyles();\n _loadScopedThemeStyles(props.dt);\n };\n\n ThemeService.on('theme:change', handleThemeChange);\n\n return () => {\n ThemeService.off('theme:change', handleThemeChange);\n };\n }, [$isUnstyled, $primereact?.theme, _loadThemeStyles, _loadScopedThemeStyles, props.dt]);\n\n React.useInsertionEffect(() => {\n if (!isClient() || $isUnstyled) {\n return;\n }\n\n scopedStyleRef.current?.remove();\n scopedStyleRef.current = null;\n\n _loadScopedThemeStyles(props.dt);\n\n return () => {\n scopedStyleRef.current?.remove();\n scopedStyleRef.current = null;\n };\n }, [$isUnstyled, props.dt, _loadScopedThemeStyles]);\n\n React.useEffect(() => {\n if (!isClient()) {\n return;\n }\n\n return () => {\n if (hasRetainedBaseStyleRef.current) {\n StyleRegistry.releaseStyleName('base');\n hasRetainedBaseStyleRef.current = false;\n }\n\n if (retainedComponentStyleNameRef.current) {\n StyleRegistry.releaseStyleName(retainedComponentStyleNameRef.current);\n retainedComponentStyleNameRef.current = null;\n }\n };\n }, []);\n\n return React.useMemo(\n () => ({\n cx,\n sx,\n isUnstyled: $isUnstyled,\n $style\n }),\n [cx, sx, $isUnstyled, $style]\n );\n}\n","import { ThemeContext } from '@primereact/core/theme';\nimport { useStyle } from '@primereact/core/use-style';\nimport type { StylesOptions, StyleType } from '@primereact/types/styles';\nimport { css as Css, dt, Theme } from '@primeuix/styled';\nimport { isNotEmpty, minifyCSS, resolve, toElement } from '@primeuix/utils';\nimport * as React from 'react';\n\n/**\n * A custom hook for managing component styles.\n *\n * @param styles The styles to apply to the component.\n * @param elementRef A reference to the HTML element.\n * @returns An object containing methods to load and manage styles.\n */\nexport function useComponentStyleHandler<Styles>(styles?: Styles, elementRef?: React.Ref<HTMLElement>) {\n const theme = React.useContext(ThemeContext);\n const [load] = useStyle();\n\n const _load = React.useCallback(\n (css?: string, options?: Record<PropertyKey, unknown>) => {\n return load({ name: options?.name as string | undefined, css, element: toElement(elementRef), options });\n },\n [load, elementRef]\n );\n\n return React.useMemo(() => {\n const handler = {\n name: 'base',\n ...(styles as StylesOptions),\n load(style: StyleType = '', options: Record<PropertyKey, unknown> & { name?: string } = {}, extendedStyle = '', enableThemeTransform = false) {\n const name = options.name || handler.name;\n const resolvedStyle = Css`${style}${extendedStyle}` as string;\n const computedStyle = enableThemeTransform ? Theme.transformCSS(name, resolvedStyle) : resolvedStyle;\n\n return isNotEmpty(computedStyle) ? _load(minifyCSS(computedStyle), { name, ...options }) : undefined;\n },\n loadCSS(options?: Record<PropertyKey, unknown>) {\n return this.load(this.css, options);\n },\n loadStyle(options?: Record<PropertyKey, unknown>, extendedStyle = '') {\n return this.load(this.style, options, extendedStyle, true);\n },\n getCommonTheme(params?: Record<PropertyKey, unknown>) {\n return Theme.getCommon(this.name, params);\n },\n getComponentTheme(params?: Record<PropertyKey, unknown>) {\n return Theme.getComponent(this.name, params);\n },\n // @todo: preset type\n getPresetTheme(preset: unknown, selector: string, params?: Record<PropertyKey, unknown>) {\n return Theme.getCustomPreset(this.name, preset, selector, params);\n },\n getLayerOrderThemeCSS() {\n return Theme.getLayerOrderCSS(this.name);\n },\n getStyleSheet(extendedCSS = '', props = {}) {\n if (this.css) {\n // @ts-expect-error: update dt definition in primeuix/styled\n const _css = resolve(this.css, { dt }) as string;\n const _style = minifyCSS(Css`${_css}${extendedCSS}`);\n const _props = Object.entries(props)\n .reduce<string[]>((acc, [k, v]) => {\n acc.push(`${k}=\"${v}\"`);\n\n return acc;\n }, [])\n .join(' ');\n\n return `<style type=\"text/css\" data-primereact-style-id=\"${this.name}\" ${_props}>${_style}</style>`;\n }\n\n return '';\n },\n getCommonThemeStyleSheet(params?: Record<PropertyKey, unknown>, props: Record<PropertyKey, unknown> = {}) {\n return Theme.getCommonStyleSheet(this.name, params, props);\n },\n getThemeStyleSheet(params?: Record<PropertyKey, unknown>, props: Record<PropertyKey, unknown> = {}) {\n const cssArr = [Theme.getStyleSheet(this.name, params, props)];\n\n if (theme) {\n const _name = this.name === 'base' ? 'global-style' : `${this.name}-style`;\n const _css = Css`${resolve(theme, { dt })}` as string;\n const _style = minifyCSS(Theme.transformCSS(this.name, _css));\n const _props = Object.entries(props)\n .reduce<string[]>((acc, [k, v]) => {\n acc.push(`${k}=\"${v}\"`);\n\n return acc;\n }, [])\n .join(' ');\n\n cssArr.push(`<style type=\"text/css\" data-primereact-style-id=\"${_name}\" ${_props}>${_style}</style>`);\n }\n\n return cssArr.join('');\n }\n };\n\n return handler;\n }, [styles, theme, _load]);\n}\n","import type { ComponentInstance, InComponentInstance, useComponentOptions, withComponentOptions } from '@primereact/types/core';\nimport type { BaseComponentProps } from '@primereact/types';\nimport type { StylesOptions } from '@primereact/types/styles';\nimport { isObject } from '@primeuix/utils';\nimport * as React from 'react';\nimport { useComponent } from './useComponent';\n\n/**\n * A higher-order component for enhancing a component with additional features.\n *\n * @template IProps The interface for the component's input properties.\n * @template DProps The interface for the component's default properties.\n * @template Exposes The interface for the properties that the component exposes.\n * @template Styles The styles options for the component.\n * @template CData Additional data to expose on the component.\n *\n * @param options The options for the component.\n * @param options.name The name of the component, used for debugging and identification.\n * @param options.defaultProps The default properties for the component.\n * @param options.styles The styles to apply to the component.\n * @param options.components Additional components to include in the component.\n * @param options.setup A setup function for additional configuration of the component.\n * @param options.render A render function for the component.\n * @returns A React component wrapped with the specified options.\n */\nexport function withComponent<IProps, DProps, Exposes extends Record<PropertyKey, unknown> = Record<PropertyKey, unknown>, Styles = StylesOptions, CData = Record<string, unknown>>({\n name = 'UnknownComponent',\n type = 'primitive',\n defaultProps,\n styles,\n components,\n setup,\n render\n}: withComponentOptions<IProps, DProps, Exposes, Styles, CData>) {\n type InProps<I extends ComponentInstance, T extends React.ElementType> = BaseComponentProps<I, IProps, unknown, T> & DProps;\n\n const BaseComponent = <I extends ComponentInstance, T extends React.ElementType>(inProps?: InProps<I, T>) => {\n const instance = useComponent(name, { type, inProps, defaultProps, styles, setup } as useComponentOptions<InProps<I, T>, DProps, Exposes, Styles>);\n\n type RenderedComponentProps = InComponentInstance<typeof instance.props, InProps<I, T>, typeof instance.state, Exposes>;\n\n const RenderedComponent = (render as React.FC<RenderedComponentProps>) ?? (() => null);\n\n return instance.props.pIf ? <RenderedComponent {...(instance as RenderedComponentProps)} /> : null;\n };\n\n const Component = React.memo(BaseComponent, (prevProps, nextProps) => {\n if (!isObject(prevProps) || !isObject(nextProps)) {\n return false;\n }\n\n // Function props (render props, event handlers) are recreated on every parent render\n // and their closures may reference ambient state. `shallowEqualProps` ignores function\n // mismatches to reduce churn, but that strands render-prop children against state updates.\n // Fall back to identity checks for functions so re-renders flow through.\n const prevRecord = prevProps as Record<string, unknown>;\n const nextRecord = nextProps as Record<string, unknown>;\n const keys = Object.keys(prevRecord);\n\n if (keys.length !== Object.keys(nextRecord).length) return false;\n\n for (const key of keys) {\n const prev = prevRecord[key];\n const next = nextRecord[key];\n\n if (typeof prev === 'function' || typeof next === 'function') {\n if (prev !== next) return false;\n continue;\n }\n\n if (!Object.is(prev, next)) return false;\n }\n\n return true;\n }) as unknown as typeof BaseComponent & CData & React.FC;\n\n Component.displayName = `PrimeReact.${name}`;\n Object.entries(components || {}).forEach(([key, value]) => {\n (Component as Record<string, unknown>)[key] = value;\n });\n\n return Component;\n}\n"],"mappings":"8lBAAA,OAAS,kBAAAA,GAAgB,aAAAC,OAAiB,yBAE1C,OAAS,MAAAC,GAAI,WAAAC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E,OAAQ,MAAO,GAE3D,QAAWE,KAAOD,EAAM,CACpB,IAAME,EAAOJ,EAAWG,CAAG,EACrBE,EAAOJ,EAAWE,CAAG,EAE3B,GAAI,OAAOC,GAAS,YAAc,OAAOC,GAAS,WAAY,CAC1D,GAAID,IAASC,EAAM,MAAO,GAC1B,QACJ,CAEA,GAAI,CAAC,OAAO,GAAGD,EAAMC,CAAI,EAAG,MAAO,EACvC,CAEA,MAAO,EACX,CAAC,EAED,OAAAd,EAAU,YAAc,cAAcP,CAAI,GAC1C,OAAO,QAAQI,GAAc,CAAC,CAAC,EAAE,QAAQ,CAAC,CAACe,EAAKG,CAAK,IAAM,CACtDf,EAAsCY,CAAG,EAAIG,CAClD,CAAC,EAEMf,CACX","names":["isValidElement","mergeRefs","cn","resolve","React","Component","inProps","_b","_c","_e","_f","_g","_a","pIf","style","className","as","asChild","instance","render","props","__objRest","AsComponent","renderAsChild","isFragment","_d","propRef","children","inAttrs","restAttrs","attrs","__spreadValues","content","resolve","styles","classNames","isValidElement","asProps","__spreadProps","cn","asRef","mergeRefs","omit","globalProps","defaultComponentProps","__spreadProps","__spreadValues","omit","useBase","React","useMountEffect","useUnmountEffect","useUpdateEffect","primeuix_mergeProps","getKeyValue","isNotEmpty","isString","resolve","React","primeuix_mergeProps","getKeyValue","isArray","isFunction","isString","toFlatCase","mergeProps","fn","args","getPTClassValue","obj","key","params","value","getPT","pt","name","getValue","checkSameKey","_a","computedValue","_key","_cKey","useComponentPT","instance","$params","id","name","scope","part","props","attrs","$primereact","$attrSelector","passthrough","passthroughValue","passthroughOptions","_usePT","pt","fn","key","params","vfn","value","mergeSections","useMergeProps","originalValue","isString","mergeProps","_hook","hookName","selfHook","getPT","getKeyValue","defaultHook","$globalPT","resolve","$defaultPT","$attrsPT","result","slot","rest","currentObj","nestedKey","index","array","$attrsWithoutPT","acc","_getPTDatasets","datasetPrefix","isNotEmpty","__spreadProps","__spreadValues","_getPTSelf","obj","componentPT","attrsPT","_useGlobalPT","_useDefaultPT","_getPTValue","searchInDefaultPT","searchOut","global","getPTClassValue","self","datasets","ptm","ptmi","_a","_attrs","primeuix_mergeProps","ptmo","useMountEffect","useUpdateEffect","useUnmountEffect","isDev","StyleRegistry","Theme","ThemeService","cn","getKeyValue","isClient","React","ThemeContext","useStyle","Css","dt","Theme","isNotEmpty","minifyCSS","resolve","toElement","React","useComponentStyleHandler","styles","elementRef","theme","ThemeContext","load","useStyle","_load","css","options","toElement","handler","__spreadProps","__spreadValues","style","extendedStyle","enableThemeTransform","name","resolvedStyle","Css","computedStyle","Theme","isNotEmpty","minifyCSS","params","preset","selector","extendedCSS","props","_css","resolve","dt","_style","_props","acc","k","v","cssArr","_name","useComponentStyle","instance","styles","$params","_a","_b","_c","_d","props","$primereact","$attrSelector","elementRef","$style","useComponentStyleHandler","$isUnstyled","$styleOptions","scopedStyleRef","hasRetainedBaseStyleRef","retainedComponentStyleNameRef","styleContentRef","stylesChangedRef","isDev","nextStyleSource","nextContent","_loadCoreStyles","name","isClient","__spreadValues","StyleRegistry","hmr","_loadThemeStyles","loadCommonThemeStyles","primitive","semantic","global","style","loadComponentThemeStyles","css","loadLayerOrderStyles","layerOrder","Theme","_load","_loadScopedThemeStyles","preset","scopedStyle","cx","key","params","cn","getKeyValue","__spreadProps","sx","when","self","base","handleThemeChange","ThemeService","useComponent","name","options","defaultProps","__spreadValues","globalProps","baseInstance","useBase","ref","props","$params","ptx","useComponentPT","stx","useComponentStyle","instance","isObject","React","withComponent","name","type","defaultProps","styles","components","setup","render","Component","inProps","instance","useComponent","RenderedComponent","__spreadValues","prevProps","nextProps","isObject","prevRecord","nextRecord","keys","key","prev","next","value"]}
package/config/index.mjs CHANGED
@@ -1,2 +1,2 @@
1
- "use client";var E=Object.defineProperty;var d=Object.getOwnPropertySymbols;var A=Object.prototype.hasOwnProperty,_=Object.prototype.propertyIsEnumerable;var f=(o,e,r)=>e in o?E(o,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):o[e]=r,a=(o,e)=>{for(var r in e||(e={}))A.call(e,r)&&f(o,r,e[r]);if(d)for(var r of d(e))_.call(e,r)&&f(o,r,e[r]);return o};import{LocaleProvider as S}from"@primereact/core/locale";import{PassThroughProvider as C}from"@primereact/core/passthrough";import{ThemeProvider as v}from"@primereact/core/theme";import{useProps as O}from"@primereact/hooks";import{resolve as N}from"@primeuix/utils";import*as n from"react";import{FilterMatchMode as t}from"@primereact/core/api";var l={csp:{nonce:void 0},defaults:void 0,filterMatchModeOptions:{text:[t.STARTS_WITH,t.CONTAINS,t.NOT_CONTAINS,t.ENDS_WITH,t.EQUALS,t.NOT_EQUALS],numeric:[t.EQUALS,t.NOT_EQUALS,t.LESS_THAN,t.LESS_THAN_OR_EQUAL_TO,t.GREATER_THAN,t.GREATER_THAN_OR_EQUAL_TO],date:[t.DATE_IS,t.DATE_IS_NOT,t.DATE_BEFORE,t.DATE_AFTER]},inputVariant:void 0,locale:"en",pt:void 0,ptOptions:{mergeSections:!0,mergeProps:!1},ripple:!1,theme:void 0,stylesheet:void 0,unstyled:!1,zIndex:{modal:1100,overlay:1e3,menu:1e3,tooltip:1100}};var m=n.createContext(void 0);function F(o={}){var c,u;let{props:e,attrs:r}=O(o,l),[s,P]=n.useState(e.inputVariant),[R,T]=n.useState(e.defaults),[h,x]=n.useState(e.zIndex),p={inputVariant:s,setInputVariant:P,defaults:R,setDefaults:T,zIndex:h,setZIndex:x};return n.createElement(m.Provider,{value:p},n.createElement(S,{lang:e.locale},n.createElement(C,a({value:e.pt},e.ptOptions),n.createElement(v,a({preset:(c=e.theme)==null?void 0:c.preset,stylesheet:e.stylesheet},(u=e.theme)==null?void 0:u.options),N(r.children,p)))))}import{LocaleContext as I}from"@primereact/core/locale";import{PassThroughContext as L}from"@primereact/core/passthrough";import{ThemeContext as g}from"@primereact/core/theme";import*as i from"react";function k(){let o=i.useContext(m),e=i.useContext(I),r=i.useContext(L),s=i.useContext(g);if(o===void 0)throw new Error("Context must be used within a PrimeReactProvider");return{config:o,locale:e,passthrough:r,theme:s}}export{m as PrimeReactContext,F as PrimeReactProvider,l as defaultConfigProps,k as usePrimeReact};
1
+ var _=Object.defineProperty;var R=Object.getOwnPropertySymbols;var v=Object.prototype.hasOwnProperty,S=Object.prototype.propertyIsEnumerable;var P=(i,e,t)=>e in i?_(i,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):i[e]=t,c=(i,e)=>{for(var t in e||(e={}))v.call(e,t)&&P(i,t,e[t]);if(R)for(var t of R(e))S.call(e,t)&&P(i,t,e[t]);return i};import{showInvalidLicenseBanner as C}from"@primereact/core/license";import{LocaleProvider as L}from"@primereact/core/locale";import{PassThroughProvider as N}from"@primereact/core/passthrough";import{ThemeProvider as O}from"@primereact/core/theme";import{useProps as g}from"@primereact/hooks";import{registerLicense as I,verifyLicense as y}from"@primeui/license-manager";import{resolve as D}from"@primeuix/utils";import*as o from"react";import{FilterMatchMode as r}from"@primereact/core/api";var T={csp:{nonce:void 0},defaults:void 0,filterMatchModeOptions:{text:[r.STARTS_WITH,r.CONTAINS,r.NOT_CONTAINS,r.ENDS_WITH,r.EQUALS,r.NOT_EQUALS],numeric:[r.EQUALS,r.NOT_EQUALS,r.LESS_THAN,r.LESS_THAN_OR_EQUAL_TO,r.GREATER_THAN,r.GREATER_THAN_OR_EQUAL_TO],date:[r.DATE_IS,r.DATE_IS_NOT,r.DATE_BEFORE,r.DATE_AFTER]},inputVariant:void 0,locale:"en",pt:void 0,ptOptions:{mergeSections:!0,mergeProps:!1},ripple:!1,theme:void 0,stylesheet:void 0,unstyled:!1,zIndex:{modal:1100,overlay:1e3,menu:1e3,tooltip:1100},license:void 0};var M="2026-06-28",m=o.createContext(void 0);function k(i={}){var f,u;let{props:e,attrs:t}=g(T,i),[s,h]=o.useState(e.inputVariant),[p,E]=o.useState(e.defaults),[d,x]=o.useState(e.zIndex);o.useEffect(()=>{e.license&&I({primeui:e.license}),y("primeui",{releaseDate:M}).then(l=>{l.valid||(console.warn(`[PrimeUI] ${l.message}`),C())})},[]);let a=o.useMemo(()=>({inputVariant:s,setInputVariant:h,defaults:p,setDefaults:E,zIndex:d,setZIndex:x}),[s,p,d]),A=o.useMemo(()=>D(t.children,a),[t.children,a]);return o.createElement(m.Provider,{value:a},o.createElement(L,{lang:e.locale},o.createElement(N,c({value:e.pt},e.ptOptions),o.createElement(O,c({preset:(f=e.theme)==null?void 0:f.preset,stylesheet:e.stylesheet},(u=e.theme)==null?void 0:u.options),A))))}import{LocaleContext as U}from"@primereact/core/locale";import{PassThroughContext as H}from"@primereact/core/passthrough";import{ThemeContext as Q}from"@primereact/core/theme";import*as n from"react";function te(){let i=n.useContext(m),e=n.useContext(U),t=n.useContext(H),s=n.useContext(Q);if(i===void 0)throw new Error("[PrimeReact] PrimeReactProvider not found. Wrap your application in <PrimeReactProvider> before using PrimeReact components.");return n.useMemo(()=>({config:i,locale:e,passthrough:t,theme:s}),[i,e,t,s])}export{m as PrimeReactContext,k as PrimeReactProvider,T as defaultConfigProps,te as usePrimeReact};
2
2
  //# sourceMappingURL=index.mjs.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/config/PrimeReact.context.tsx","../../src/config/PrimeReact.props.ts","../../src/config/usePrimeReact.ts"],"sourcesContent":["import { LocaleProvider } from '@primereact/core/locale';\nimport { PassThroughProvider } from '@primereact/core/passthrough';\nimport { ThemeProvider } from '@primereact/core/theme';\nimport { useProps } from '@primereact/hooks';\nimport type { PrimeReactProps } from '@primereact/types/core';\nimport { resolve } from '@primeuix/utils';\nimport * as React from 'react';\nimport { defaultConfigProps } from './PrimeReact.props';\n\nexport const PrimeReactContext = React.createContext<PrimeReactProps | undefined>(undefined);\n\nexport function PrimeReactProvider(inProps: React.PropsWithChildren<PrimeReactProps> = {}) {\n const { props, attrs } = useProps(inProps, defaultConfigProps);\n\n // states\n const [inputVariant, setInputVariant] = React.useState(props.inputVariant);\n const [defaults, setDefaults] = React.useState(props.defaults);\n const [zIndex, setZIndex] = React.useState(props.zIndex);\n\n const value = {\n inputVariant,\n setInputVariant,\n defaults,\n setDefaults,\n zIndex,\n setZIndex\n };\n\n return (\n <PrimeReactContext.Provider value={value}>\n <LocaleProvider lang={props.locale}>\n <PassThroughProvider value={props.pt} {...props.ptOptions}>\n <ThemeProvider preset={props.theme?.preset} stylesheet={props.stylesheet} {...props.theme?.options}>\n {resolve(attrs.children, value)}\n </ThemeProvider>\n </PassThroughProvider>\n </LocaleProvider>\n </PrimeReactContext.Provider>\n );\n}\n","import { FilterMatchMode } from '@primereact/core/api';\nimport type { PrimeReactProps } from '@primereact/types/core';\n\nexport const defaultConfigProps: PrimeReactProps = {\n csp: { nonce: undefined },\n defaults: undefined,\n filterMatchModeOptions: {\n text: [FilterMatchMode.STARTS_WITH, FilterMatchMode.CONTAINS, FilterMatchMode.NOT_CONTAINS, FilterMatchMode.ENDS_WITH, FilterMatchMode.EQUALS, FilterMatchMode.NOT_EQUALS],\n numeric: [FilterMatchMode.EQUALS, FilterMatchMode.NOT_EQUALS, FilterMatchMode.LESS_THAN, FilterMatchMode.LESS_THAN_OR_EQUAL_TO, FilterMatchMode.GREATER_THAN, FilterMatchMode.GREATER_THAN_OR_EQUAL_TO],\n date: [FilterMatchMode.DATE_IS, FilterMatchMode.DATE_IS_NOT, FilterMatchMode.DATE_BEFORE, FilterMatchMode.DATE_AFTER]\n },\n inputVariant: undefined,\n locale: 'en',\n pt: undefined,\n ptOptions: { mergeSections: true, mergeProps: false },\n ripple: false,\n theme: undefined,\n stylesheet: undefined,\n unstyled: false,\n zIndex: { modal: 1100, overlay: 1000, menu: 1000, tooltip: 1100 }\n};\n","import { LocaleContext } from '@primereact/core/locale';\nimport { PassThroughContext } from '@primereact/core/passthrough';\nimport { ThemeContext } from '@primereact/core/theme';\nimport * as React from 'react';\nimport { PrimeReactContext } from './PrimeReact.context';\n\nexport function usePrimeReact() {\n const config = React.useContext(PrimeReactContext);\n const locale = React.useContext(LocaleContext);\n const passthrough = React.useContext(PassThroughContext);\n const theme = React.useContext(ThemeContext);\n\n if (config === undefined) {\n throw new Error('Context must be used within a PrimeReactProvider');\n }\n\n return {\n config,\n locale,\n passthrough,\n theme\n };\n}\n"],"mappings":"sWAAA,OAAS,kBAAAA,MAAsB,0BAC/B,OAAS,uBAAAC,MAA2B,+BACpC,OAAS,iBAAAC,MAAqB,yBAC9B,OAAS,YAAAC,MAAgB,oBAEzB,OAAS,WAAAC,MAAe,kBACxB,UAAYC,MAAW,QCNvB,OAAS,mBAAAC,MAAuB,uBAGzB,IAAMC,EAAsC,CAC/C,IAAK,CAAE,MAAO,MAAU,EACxB,SAAU,OACV,uBAAwB,CACpB,KAAM,CAACD,EAAgB,YAAaA,EAAgB,SAAUA,EAAgB,aAAcA,EAAgB,UAAWA,EAAgB,OAAQA,EAAgB,UAAU,EACzK,QAAS,CAACA,EAAgB,OAAQA,EAAgB,WAAYA,EAAgB,UAAWA,EAAgB,sBAAuBA,EAAgB,aAAcA,EAAgB,wBAAwB,EACtM,KAAM,CAACA,EAAgB,QAASA,EAAgB,YAAaA,EAAgB,YAAaA,EAAgB,UAAU,CACxH,EACA,aAAc,OACd,OAAQ,KACR,GAAI,OACJ,UAAW,CAAE,cAAe,GAAM,WAAY,EAAM,EACpD,OAAQ,GACR,MAAO,OACP,WAAY,OACZ,SAAU,GACV,OAAQ,CAAE,MAAO,KAAM,QAAS,IAAM,KAAM,IAAM,QAAS,IAAK,CACpE,EDXO,IAAME,EAA0B,gBAA2C,MAAS,EAEpF,SAASC,EAAmBC,EAAoD,CAAC,EAAG,CAX3F,IAAAC,EAAAC,EAYI,GAAM,CAAE,MAAAC,EAAO,MAAAC,CAAM,EAAIC,EAASL,EAASM,CAAkB,EAGvD,CAACC,EAAcC,CAAe,EAAU,WAASL,EAAM,YAAY,EACnE,CAACM,EAAUC,CAAW,EAAU,WAASP,EAAM,QAAQ,EACvD,CAACQ,EAAQC,CAAS,EAAU,WAAST,EAAM,MAAM,EAEjDU,EAAQ,CACV,aAAAN,EACA,gBAAAC,EACA,SAAAC,EACA,YAAAC,EACA,OAAAC,EACA,UAAAC,CACJ,EAEA,OACI,gBAACd,EAAkB,SAAlB,CAA2B,MAAOe,GAC/B,gBAACC,EAAA,CAAe,KAAMX,EAAM,QACxB,gBAACY,EAAAC,EAAA,CAAoB,MAAOb,EAAM,IAAQA,EAAM,WAC5C,gBAACc,EAAAD,EAAA,CAAc,QAAQf,EAAAE,EAAM,QAAN,YAAAF,EAAa,OAAQ,WAAYE,EAAM,aAAgBD,EAAAC,EAAM,QAAN,YAAAD,EAAa,SACtFgB,EAAQd,EAAM,SAAUS,CAAK,CAClC,CACJ,CACJ,CACJ,CAER,CEvCA,OAAS,iBAAAM,MAAqB,0BAC9B,OAAS,sBAAAC,MAA0B,+BACnC,OAAS,gBAAAC,MAAoB,yBAC7B,UAAYC,MAAW,QAGhB,SAASC,GAAgB,CAC5B,IAAMC,EAAe,aAAWC,CAAiB,EAC3CC,EAAe,aAAWC,CAAa,EACvCC,EAAoB,aAAWC,CAAkB,EACjDC,EAAc,aAAWC,CAAY,EAE3C,GAAIP,IAAW,OACX,MAAM,IAAI,MAAM,kDAAkD,EAGtE,MAAO,CACH,OAAAA,EACA,OAAAE,EACA,YAAAE,EACA,MAAAE,CACJ,CACJ","names":["LocaleProvider","PassThroughProvider","ThemeProvider","useProps","resolve","React","FilterMatchMode","defaultConfigProps","PrimeReactContext","PrimeReactProvider","inProps","_a","_b","props","attrs","useProps","defaultConfigProps","inputVariant","setInputVariant","defaults","setDefaults","zIndex","setZIndex","value","LocaleProvider","PassThroughProvider","__spreadValues","ThemeProvider","resolve","LocaleContext","PassThroughContext","ThemeContext","React","usePrimeReact","config","PrimeReactContext","locale","LocaleContext","passthrough","PassThroughContext","theme","ThemeContext"]}
1
+ {"version":3,"sources":["../../src/config/PrimeReact.context.tsx","../../src/config/PrimeReact.props.ts","../../src/config/usePrimeReact.ts"],"sourcesContent":["'use client';\nimport { showInvalidLicenseBanner } from '@primereact/core/license';\nimport { LocaleProvider } from '@primereact/core/locale';\nimport { PassThroughProvider } from '@primereact/core/passthrough';\nimport { ThemeProvider } from '@primereact/core/theme';\nimport { useProps } from '@primereact/hooks';\nimport type { PrimeReactProps } from '@primereact/types/core';\nimport { registerLicense, verifyLicense } from '@primeui/license-manager';\nimport { resolve } from '@primeuix/utils';\nimport * as React from 'react';\nimport { defaultConfigProps } from './PrimeReact.props';\n\nconst RELEASE_DATE = '2026-06-28';\n\nexport const PrimeReactContext = React.createContext<PrimeReactProps | undefined>(undefined);\n\nexport function PrimeReactProvider(inProps: React.PropsWithChildren<PrimeReactProps> = {}) {\n const { props, attrs } = useProps(defaultConfigProps, inProps);\n\n // states\n const [inputVariant, setInputVariant] = React.useState(props.inputVariant);\n const [defaults, setDefaults] = React.useState(props.defaults);\n const [zIndex, setZIndex] = React.useState(props.zIndex);\n\n React.useEffect(() => {\n if (props.license) registerLicense({ primeui: props.license });\n\n verifyLicense('primeui', { releaseDate: RELEASE_DATE }).then((result) => {\n if (!result.valid) {\n // eslint-disable-next-line no-console\n console.warn(`[PrimeUI] ${result.message}`);\n showInvalidLicenseBanner();\n }\n });\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, []);\n\n const value = React.useMemo(\n () => ({\n inputVariant,\n setInputVariant,\n defaults,\n setDefaults,\n zIndex,\n setZIndex\n }),\n [inputVariant, defaults, zIndex]\n );\n const resolvedChildren = React.useMemo(() => resolve(attrs.children, value) as React.ReactNode, [attrs.children, value]);\n\n return (\n <PrimeReactContext.Provider value={value}>\n <LocaleProvider lang={props.locale}>\n <PassThroughProvider value={props.pt} {...props.ptOptions}>\n <ThemeProvider preset={props.theme?.preset} stylesheet={props.stylesheet} {...props.theme?.options}>\n {resolvedChildren}\n </ThemeProvider>\n </PassThroughProvider>\n </LocaleProvider>\n </PrimeReactContext.Provider>\n );\n}\n","import { FilterMatchMode } from '@primereact/core/api';\nimport type { PrimeReactProps } from '@primereact/types/core';\n\nexport const defaultConfigProps: PrimeReactProps = {\n csp: { nonce: undefined },\n defaults: undefined,\n filterMatchModeOptions: {\n text: [FilterMatchMode.STARTS_WITH, FilterMatchMode.CONTAINS, FilterMatchMode.NOT_CONTAINS, FilterMatchMode.ENDS_WITH, FilterMatchMode.EQUALS, FilterMatchMode.NOT_EQUALS],\n numeric: [FilterMatchMode.EQUALS, FilterMatchMode.NOT_EQUALS, FilterMatchMode.LESS_THAN, FilterMatchMode.LESS_THAN_OR_EQUAL_TO, FilterMatchMode.GREATER_THAN, FilterMatchMode.GREATER_THAN_OR_EQUAL_TO],\n date: [FilterMatchMode.DATE_IS, FilterMatchMode.DATE_IS_NOT, FilterMatchMode.DATE_BEFORE, FilterMatchMode.DATE_AFTER]\n },\n inputVariant: undefined,\n locale: 'en',\n pt: undefined,\n ptOptions: { mergeSections: true, mergeProps: false },\n ripple: false,\n theme: undefined,\n stylesheet: undefined,\n unstyled: false,\n zIndex: { modal: 1100, overlay: 1000, menu: 1000, tooltip: 1100 },\n license: undefined\n};\n","import { LocaleContext } from '@primereact/core/locale';\nimport { PassThroughContext } from '@primereact/core/passthrough';\nimport { ThemeContext } from '@primereact/core/theme';\nimport * as React from 'react';\nimport { PrimeReactContext } from './PrimeReact.context';\n\nexport function usePrimeReact() {\n const config = React.useContext(PrimeReactContext);\n const locale = React.useContext(LocaleContext);\n const passthrough = React.useContext(PassThroughContext);\n const theme = React.useContext(ThemeContext);\n\n if (config === undefined) {\n throw new Error('[PrimeReact] PrimeReactProvider not found. Wrap your application in <PrimeReactProvider> before using PrimeReact components.');\n }\n\n return React.useMemo(\n () => ({\n config,\n locale,\n passthrough,\n theme\n }),\n [config, locale, passthrough, theme]\n );\n}\n"],"mappings":"yVACA,OAAS,4BAAAA,MAAgC,2BACzC,OAAS,kBAAAC,MAAsB,0BAC/B,OAAS,uBAAAC,MAA2B,+BACpC,OAAS,iBAAAC,MAAqB,yBAC9B,OAAS,YAAAC,MAAgB,oBAEzB,OAAS,mBAAAC,EAAiB,iBAAAC,MAAqB,2BAC/C,OAAS,WAAAC,MAAe,kBACxB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AAO,CACH,aAAAV,EACA,gBAAAC,EACA,SAAAC,EACA,YAAAC,EACA,OAAAC,EACA,UAAAC,CACJ,GACA,CAACL,EAAcE,EAAUE,CAAM,CACnC,EACMO,EAAyB,UAAQ,IAAMC,EAAQf,EAAM,SAAUa,CAAK,EAAsB,CAACb,EAAM,SAAUa,CAAK,CAAC,EAEvH,OACI,gBAACnB,EAAkB,SAAlB,CAA2B,MAAOmB,GAC/B,gBAACG,EAAA,CAAe,KAAMjB,EAAM,QACxB,gBAACkB,EAAAC,EAAA,CAAoB,MAAOnB,EAAM,IAAQA,EAAM,WAC5C,gBAACoB,EAAAD,EAAA,CAAc,QAAQrB,EAAAE,EAAM,QAAN,YAAAF,EAAa,OAAQ,WAAYE,EAAM,aAAgBD,EAAAC,EAAM,QAAN,YAAAD,EAAa,SACtFgB,CACL,CACJ,CACJ,CACJ,CAER,CE7DA,OAAS,iBAAAM,MAAqB,0BAC9B,OAAS,sBAAAC,MAA0B,+BACnC,OAAS,gBAAAC,MAAoB,yBAC7B,UAAYC,MAAW,QAGhB,SAASC,IAAgB,CAC5B,IAAMC,EAAe,aAAWC,CAAiB,EAC3CC,EAAe,aAAWC,CAAa,EACvCC,EAAoB,aAAWC,CAAkB,EACjDC,EAAc,aAAWC,CAAY,EAE3C,GAAIP,IAAW,OACX,MAAM,IAAI,MAAM,8HAA8H,EAGlJ,OAAa,UACT,KAAO,CACH,OAAAA,EACA,OAAAE,EACA,YAAAE,EACA,MAAAE,CACJ,GACA,CAACN,EAAQE,EAAQE,EAAaE,CAAK,CACvC,CACJ","names":["showInvalidLicenseBanner","LocaleProvider","PassThroughProvider","ThemeProvider","useProps","registerLicense","verifyLicense","resolve","React","FilterMatchMode","defaultConfigProps","RELEASE_DATE","PrimeReactContext","PrimeReactProvider","inProps","_a","_b","props","attrs","useProps","defaultConfigProps","inputVariant","setInputVariant","defaults","setDefaults","zIndex","setZIndex","registerLicense","verifyLicense","result","showInvalidLicenseBanner","value","resolvedChildren","resolve","LocaleProvider","PassThroughProvider","__spreadValues","ThemeProvider","LocaleContext","PassThroughContext","ThemeContext","React","usePrimeReact","config","PrimeReactContext","locale","LocaleContext","passthrough","PassThroughContext","theme","ThemeContext"]}