@engrate/components 0.1.14 → 0.1.15
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/ui/PaginationDots/PaginationDots.d.ts +40 -0
- package/dist/components/ui/PaginationDots/index.d.ts +2 -0
- package/dist/components/ui/index.d.ts +1 -0
- package/dist/index.cjs.js +25 -25
- package/dist/index.es.js +3334 -3237
- package/dist/skills/engrate-component-user.md +9 -8
- package/dist/styles.css +1 -1
- package/package.json +1 -1
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
import { VariantProps } from 'class-variance-authority';
|
|
2
|
+
import * as React from 'react';
|
|
3
|
+
declare const paginationDotsVariants: (props?: ({
|
|
4
|
+
size?: "default" | "sm" | "lg" | null | undefined;
|
|
5
|
+
} & import('class-variance-authority/types').ClassProp) | undefined) => string;
|
|
6
|
+
interface PaginationDotsProps extends React.HTMLAttributes<HTMLDivElement>, VariantProps<typeof paginationDotsVariants> {
|
|
7
|
+
/** The index of the currently active dot (zero-based) */
|
|
8
|
+
value: number;
|
|
9
|
+
/** Callback fired when a dot is clicked */
|
|
10
|
+
onValueChange?: (index: number) => void;
|
|
11
|
+
}
|
|
12
|
+
/**
|
|
13
|
+
* A dot indicator for switching between content panels (e.g. carousels).
|
|
14
|
+
* The active dot smoothly morphs into a wider pill shape.
|
|
15
|
+
*
|
|
16
|
+
* @example
|
|
17
|
+
* ```tsx
|
|
18
|
+
* <PaginationDots value={active} onValueChange={setActive}>
|
|
19
|
+
* <PaginationDot index={0} />
|
|
20
|
+
* <PaginationDot index={1} />
|
|
21
|
+
* <PaginationDot index={2} />
|
|
22
|
+
* </PaginationDots>
|
|
23
|
+
* ```
|
|
24
|
+
*/
|
|
25
|
+
declare const PaginationDots: React.ForwardRefExoticComponent<PaginationDotsProps & React.RefAttributes<HTMLDivElement>>;
|
|
26
|
+
declare const paginationDotVariants: (props?: ({
|
|
27
|
+
size?: "default" | "sm" | "lg" | null | undefined;
|
|
28
|
+
active?: boolean | null | undefined;
|
|
29
|
+
} & import('class-variance-authority/types').ClassProp) | undefined) => string;
|
|
30
|
+
interface PaginationDotProps extends Omit<React.ButtonHTMLAttributes<HTMLButtonElement>, 'children'> {
|
|
31
|
+
/** Zero-based index of this dot */
|
|
32
|
+
index: number;
|
|
33
|
+
}
|
|
34
|
+
/**
|
|
35
|
+
* An individual dot within a PaginationDots group.
|
|
36
|
+
* Renders as a clickable button that morphs into a pill shape when active.
|
|
37
|
+
*/
|
|
38
|
+
declare const PaginationDot: React.ForwardRefExoticComponent<PaginationDotProps & React.RefAttributes<HTMLButtonElement>>;
|
|
39
|
+
export { PaginationDots, PaginationDot, paginationDotsVariants, paginationDotVariants, };
|
|
40
|
+
export type { PaginationDotsProps, PaginationDotProps };
|