@pittorica/popover-react 0.25.0 → 0.26.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/Popover.d.ts +11 -17
- package/dist/Popover.d.ts.map +1 -1
- package/dist/index.d.ts +1 -2
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +717 -669
- package/package.json +12 -11
- package/dist/Popover.stories.d.ts +0 -8
- package/dist/Popover.stories.d.ts.map +0 -1
- package/dist/Popover.test.d.ts +0 -5
- package/dist/Popover.test.d.ts.map +0 -1
package/dist/Popover.d.ts
CHANGED
|
@@ -1,29 +1,23 @@
|
|
|
1
1
|
import { type ElementType, type ReactNode } from 'react';
|
|
2
2
|
import { type Placement } from '@floating-ui/react';
|
|
3
3
|
import { type BoxProps } from '@pittorica/box-react';
|
|
4
|
-
export type
|
|
4
|
+
export type PopoverRootProps = {
|
|
5
5
|
children: ReactNode;
|
|
6
6
|
/** @default 'bottom' */
|
|
7
7
|
placement?: Placement;
|
|
8
|
+
appearance?: 'light' | 'dark' | 'inherit';
|
|
8
9
|
};
|
|
9
|
-
export declare const
|
|
10
|
-
({ children, placement }: PopoverProps): import("react/jsx-runtime").JSX.Element;
|
|
11
|
-
displayName: string;
|
|
12
|
-
};
|
|
13
|
-
/**
|
|
14
|
-
* Fix TS2314: Use 'type' and generic E for polymorphic BoxProps.
|
|
15
|
-
*/
|
|
10
|
+
export declare const PopoverRoot: ({ children, placement, appearance, }: PopoverRootProps) => import("react/jsx-runtime").JSX.Element;
|
|
16
11
|
export type PopoverTriggerProps<E extends ElementType = 'span'> = BoxProps<E>;
|
|
17
|
-
export declare const PopoverTrigger: {
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
};
|
|
12
|
+
export declare const PopoverTrigger: <E extends ElementType = "span">({ children, as, ref: externalRef, ...props }: PopoverTriggerProps<E>) => import("react/jsx-runtime").JSX.Element;
|
|
13
|
+
export type PopoverContentProps<E extends ElementType = 'div'> = BoxProps<E>;
|
|
14
|
+
export declare const PopoverContent: <E extends ElementType = "div">({ children, className, as, ref: externalRef, style, ...props }: PopoverContentProps<E>) => import("react/jsx-runtime").JSX.Element | null;
|
|
21
15
|
/**
|
|
22
|
-
*
|
|
16
|
+
* Compound component object.
|
|
23
17
|
*/
|
|
24
|
-
export
|
|
25
|
-
|
|
26
|
-
<E extends ElementType = "
|
|
27
|
-
|
|
18
|
+
export declare const Popover: (({ children, placement, appearance, }: PopoverRootProps) => import("react/jsx-runtime").JSX.Element) & {
|
|
19
|
+
Root: ({ children, placement, appearance, }: PopoverRootProps) => import("react/jsx-runtime").JSX.Element;
|
|
20
|
+
Trigger: <E extends ElementType = "span">({ children, as, ref: externalRef, ...props }: PopoverTriggerProps<E>) => import("react/jsx-runtime").JSX.Element;
|
|
21
|
+
Content: <E extends ElementType = "div">({ children, className, as, ref: externalRef, style, ...props }: PopoverContentProps<E>) => import("react/jsx-runtime").JSX.Element | null;
|
|
28
22
|
};
|
|
29
23
|
//# sourceMappingURL=Popover.d.ts.map
|
package/dist/Popover.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Popover.d.ts","sourceRoot":"","sources":["../src/Popover.tsx"],"names":[],"mappings":"AAAA,OAAO,EAGL,KAAK,WAAW,EAChB,KAAK,SAAS,
|
|
1
|
+
{"version":3,"file":"Popover.d.ts","sourceRoot":"","sources":["../src/Popover.tsx"],"names":[],"mappings":"AAAA,OAAO,EAGL,KAAK,WAAW,EAChB,KAAK,SAAS,EAMf,MAAM,OAAO,CAAC;AAIf,OAAO,EAML,KAAK,SAAS,EAOf,MAAM,oBAAoB,CAAC;AAC5B,OAAO,EAAO,KAAK,QAAQ,EAAE,MAAM,sBAAsB,CAAC;AA8B1D,MAAM,MAAM,gBAAgB,GAAG;IAC7B,QAAQ,EAAE,SAAS,CAAC;IACpB,wBAAwB;IACxB,SAAS,CAAC,EAAE,SAAS,CAAC;IACtB,UAAU,CAAC,EAAE,OAAO,GAAG,MAAM,GAAG,SAAS,CAAC;CAC3C,CAAC;AAEF,eAAO,MAAM,WAAW,GAAI,sCAIzB,gBAAgB,4CA0ClB,CAAC;AAIF,MAAM,MAAM,mBAAmB,CAAC,CAAC,SAAS,WAAW,GAAG,MAAM,IAAI,QAAQ,CAAC,CAAC,CAAC,CAAC;AAE9E,eAAO,MAAM,cAAc,GAAI,CAAC,SAAS,WAAW,GAAG,MAAM,EAAE,8CAK5D,mBAAmB,CAAC,CAAC,CAAC,4CA0BxB,CAAC;AAIF,MAAM,MAAM,mBAAmB,CAAC,CAAC,SAAS,WAAW,GAAG,KAAK,IAAI,QAAQ,CAAC,CAAC,CAAC,CAAC;AAE7E,eAAO,MAAM,cAAc,GAAI,CAAC,SAAS,WAAW,GAAG,KAAK,EAAE,gEAO3D,mBAAmB,CAAC,CAAC,CAAC,mDA2DxB,CAAC;AAEF;;GAEG;AACH,eAAO,MAAM,OAAO,0CA5JjB,gBAAgB;iDAAhB,gBAAgB;cAgDY,CAAC,SAAS,WAAW,yDAKjD,mBAAmB,CAAC,CAAC,CAAC;cAgCM,CAAC,SAAS,WAAW,0EAOjD,mBAAmB,CAAC,CAAC,CAAC;CAoEvB,CAAC"}
|
package/dist/index.d.ts
CHANGED
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,cAAc,CAAC"}
|