@eintrek/erp-theme 1.0.1 → 1.0.4
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/command-block.d.ts +3 -0
- package/dist/components/footer.d.ts +1 -0
- package/dist/components/header.d.ts +1 -0
- package/dist/components/registry_item_row.d.ts +10 -0
- package/dist/components/ui/Form.d.ts +22 -24
- package/dist/components/ui/Input.d.ts +2 -16
- package/dist/components/ui/Label.d.ts +4 -7
- package/dist/components/ui/accordion.d.ts +7 -0
- package/dist/components/ui/alert-dialog.d.ts +14 -0
- package/dist/components/ui/alert.d.ts +9 -0
- package/dist/components/ui/aspect-ratio.d.ts +3 -0
- package/dist/components/ui/avatar.d.ts +6 -0
- package/dist/components/ui/badge.d.ts +9 -0
- package/dist/components/ui/breadcrumb.d.ts +11 -0
- package/dist/components/ui/button.d.ts +10 -0
- package/dist/components/ui/calendar.d.ts +23 -0
- package/dist/components/ui/card.d.ts +9 -0
- package/dist/components/ui/carousel.d.ts +19 -0
- package/dist/components/ui/chart.d.ts +40 -0
- package/dist/components/ui/checkbox.d.ts +4 -0
- package/dist/components/ui/collapsible.d.ts +5 -0
- package/dist/components/ui/command.d.ts +18 -0
- package/dist/components/ui/context-menu.d.ts +25 -0
- package/dist/components/ui/dialog.d.ts +15 -0
- package/dist/components/ui/drawer.d.ts +13 -0
- package/dist/components/ui/dropdown-menu.d.ts +25 -0
- package/dist/components/ui/faceted.d.ts +33 -0
- package/dist/components/ui/hover-card.d.ts +6 -0
- package/dist/components/ui/input-otp.d.ts +11 -0
- package/dist/components/ui/menubar.d.ts +26 -0
- package/dist/components/ui/navigation-menu.d.ts +14 -0
- package/dist/components/ui/pagination.d.ts +13 -0
- package/dist/components/ui/popover.d.ts +7 -0
- package/dist/components/ui/progress.d.ts +4 -0
- package/dist/components/ui/radio-group.d.ts +5 -0
- package/dist/components/ui/resizable.d.ts +8 -0
- package/dist/components/ui/scroll-area.d.ts +5 -0
- package/dist/components/ui/select.d.ts +15 -0
- package/dist/components/ui/separator.d.ts +4 -0
- package/dist/components/ui/sheet.d.ts +13 -0
- package/dist/components/ui/sidebar.d.ts +69 -0
- package/dist/components/ui/skeleton.d.ts +2 -0
- package/dist/components/ui/slider.d.ts +4 -0
- package/dist/components/ui/sonner.d.ts +3 -0
- package/dist/components/ui/sortable.d.ts +53 -0
- package/dist/components/ui/switch.d.ts +4 -0
- package/dist/components/ui/table.d.ts +10 -0
- package/dist/components/ui/tabs.d.ts +7 -0
- package/dist/components/ui/textarea.d.ts +3 -0
- package/dist/components/ui/toggle-group.d.ts +7 -0
- package/dist/components/ui/toggle.d.ts +9 -0
- package/dist/components/ui/tooltip.d.ts +7 -0
- package/dist/config/flag.d.ts +16 -0
- package/dist/config/site.d.ts +9 -0
- package/dist/hooks/use-callback-ref.d.ts +9 -0
- package/dist/hooks/use-debounced-callback.d.ts +4 -0
- package/dist/hooks/use-media-query.d.ts +1 -0
- package/dist/hooks/use-mobile.d.ts +1 -0
- package/dist/index.css +1 -1
- package/dist/index.d.ts +60 -6
- package/dist/index.esm.css +1 -1
- package/dist/index.esm.js +23197 -10067
- package/dist/index.esm.js.map +1 -1
- package/dist/index.js +23460 -10070
- package/dist/index.js.map +1 -1
- package/dist/lib/composition.d.ts +23 -0
- package/dist/lib/constants.d.ts +2 -0
- package/dist/lib/export.d.ts +6 -0
- package/dist/lib/fonts.d.ts +2 -0
- package/dist/lib/format.d.ts +1 -0
- package/dist/lib/handle-error.d.ts +1 -0
- package/dist/lib/id.d.ts +7 -0
- package/dist/lib/unstable-cache.d.ts +10 -0
- package/dist/lib/utils.d.ts +1 -0
- package/dist/types/index.d.ts +26 -0
- package/package.json +66 -40
- package/scripts/enforce-pnpm.js +18 -0
- package/dist/components/ui/Buttons.d.ts +0 -15
- package/dist/components/ui/Buttons.stories.d.ts +0 -25
- package/dist/components/ui/Cards.d.ts +0 -8
- package/dist/components/ui/Cards.stories.d.ts +0 -8
- package/dist/components/ui/Form.stories.d.ts +0 -8
- package/dist/components/ui/Input.stories.d.ts +0 -10
- package/dist/components/ui/InputDropdown.d.ts +0 -19
- package/dist/components/ui/InputDropdown.stories.d.ts +0 -9
- package/dist/components/ui/Label.stories.d.ts +0 -8
- package/dist/components/ui/Modal.d.ts +0 -12
- package/dist/components/ui/Modal.stories.d.ts +0 -13
- package/dist/components/ui/table/Table.d.ts +0 -6
- package/dist/components/ui/table/Table.stories.d.ts +0 -6
- package/dist/components/ui/table/TableBody.d.ts +0 -3
- package/dist/components/ui/table/TableBody.stories.d.ts +0 -7
- package/dist/components/ui/table/TableFilter.d.ts +0 -3
- package/dist/components/ui/table/TableFilter.stories.d.ts +0 -6
- package/dist/components/ui/table/TablePagination.d.ts +0 -10
- package/dist/components/ui/table/TablePagination.stories.d.ts +0 -6
- package/dist/components/ui/table/index.d.ts +0 -13
- package/dist/components/ui/table/types.d.ts +0 -54
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
/**
|
|
3
|
+
* A utility to compose multiple event handlers into a single event handler.
|
|
4
|
+
* Call originalEventHandler first, then ourEventHandler unless prevented.
|
|
5
|
+
*/
|
|
6
|
+
declare function composeEventHandlers<E>(originalEventHandler?: (event: E) => void, ourEventHandler?: (event: E) => void, { checkForDefaultPrevented }?: {
|
|
7
|
+
checkForDefaultPrevented?: boolean | undefined;
|
|
8
|
+
}): (event: E) => void;
|
|
9
|
+
/**
|
|
10
|
+
* @see https://github.com/radix-ui/primitives/blob/main/packages/react/compose-refs/src/compose-refs.tsx
|
|
11
|
+
*/
|
|
12
|
+
type PossibleRef<T> = React.Ref<T> | undefined;
|
|
13
|
+
/**
|
|
14
|
+
* A utility to compose multiple refs together.
|
|
15
|
+
* Accepts callback refs and RefObject(s).
|
|
16
|
+
*/
|
|
17
|
+
declare function composeRefs<T>(...refs: PossibleRef<T>[]): React.RefCallback<T>;
|
|
18
|
+
/**
|
|
19
|
+
* A custom hook that composes multiple refs.
|
|
20
|
+
* Accepts callback refs and RefObject(s).
|
|
21
|
+
*/
|
|
22
|
+
declare function useComposedRefs<T>(...refs: PossibleRef<T>[]): React.RefCallback<T>;
|
|
23
|
+
export { composeEventHandlers, composeRefs, useComposedRefs };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function formatDate(date: Date | string | number | undefined, opts?: Intl.DateTimeFormatOptions): string;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function getErrorMessage(err: unknown): string;
|
package/dist/lib/id.d.ts
ADDED
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
declare const prefixes: Record<string, unknown>;
|
|
2
|
+
interface GenerateIdOptions {
|
|
3
|
+
length?: number;
|
|
4
|
+
separator?: string;
|
|
5
|
+
}
|
|
6
|
+
export declare function generateId(prefixOrOptions?: keyof typeof prefixes | GenerateIdOptions, inputOptions?: GenerateIdOptions): string;
|
|
7
|
+
export {};
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @see https://github.com/ethanniser/NextMaster/blob/main/src/lib/unstable-cache.ts
|
|
3
|
+
*/
|
|
4
|
+
export declare const unstable_cache: <Inputs extends unknown[], Output>(cb: (...args: Inputs) => Promise<Output>, keyParts: string[], options?: {
|
|
5
|
+
/**
|
|
6
|
+
* The revalidation interval in seconds.
|
|
7
|
+
*/
|
|
8
|
+
revalidate?: number | false;
|
|
9
|
+
tags?: string[];
|
|
10
|
+
}) => (...args: Inputs) => Promise<Output>;
|
package/dist/lib/utils.d.ts
CHANGED
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import type { SQL } from "drizzle-orm";
|
|
2
|
+
export type Prettify<T> = {
|
|
3
|
+
[K in keyof T]: T[K];
|
|
4
|
+
} & {};
|
|
5
|
+
export type EmptyProps<T extends React.ElementType> = Omit<React.ComponentProps<T>, keyof React.ComponentProps<T>>;
|
|
6
|
+
export interface SearchParams {
|
|
7
|
+
[key: string]: string | string[] | undefined;
|
|
8
|
+
}
|
|
9
|
+
export interface Supplier {
|
|
10
|
+
id: number;
|
|
11
|
+
supplier_code: string;
|
|
12
|
+
supplier_name: string;
|
|
13
|
+
contact_person: string;
|
|
14
|
+
phone: string;
|
|
15
|
+
email: string;
|
|
16
|
+
address: string;
|
|
17
|
+
tax_id: string;
|
|
18
|
+
payment_terms: "cash" | "7" | "15" | "30" | "45" | "60";
|
|
19
|
+
status: "active" | "inactive";
|
|
20
|
+
}
|
|
21
|
+
export interface QueryBuilderOpts {
|
|
22
|
+
where?: SQL;
|
|
23
|
+
orderBy?: SQL;
|
|
24
|
+
distinct?: boolean;
|
|
25
|
+
nullish?: boolean;
|
|
26
|
+
}
|
package/package.json
CHANGED
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@eintrek/erp-theme",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.4",
|
|
4
4
|
"private": false,
|
|
5
|
+
"packageManager": "pnpm@10.17.1",
|
|
5
6
|
"type": "module",
|
|
6
7
|
"description": "A shadcn/ui component library with Storybook",
|
|
7
8
|
"main": "dist/index.js",
|
|
@@ -9,16 +10,18 @@
|
|
|
9
10
|
"types": "dist/index.d.ts",
|
|
10
11
|
"style": "dist/styles.css",
|
|
11
12
|
"files": [
|
|
12
|
-
"dist"
|
|
13
|
+
"dist",
|
|
14
|
+
"scripts/enforce-pnpm.js"
|
|
13
15
|
],
|
|
14
16
|
"scripts": {
|
|
15
|
-
"
|
|
16
|
-
"
|
|
17
|
+
"preinstall": "node scripts/enforce-pnpm.js",
|
|
18
|
+
"build": "cross-env NODE_ENV=production rollup -c --silent",
|
|
19
|
+
"dev": "cross-env NODE_ENV=production rollup -c -w",
|
|
17
20
|
"storybook": "storybook dev -p 6006",
|
|
18
21
|
"build-storybook": "storybook build",
|
|
19
22
|
"clean": "rimraf dist",
|
|
20
|
-
"prepare": "
|
|
21
|
-
"pack": "NODE_ENV=production pnpm build && pnpm pack"
|
|
23
|
+
"prepare": "rimraf dist && cross-env NODE_ENV=production rollup -c --silent",
|
|
24
|
+
"pack": "cross-env NODE_ENV=production pnpm build && pnpm pack"
|
|
22
25
|
},
|
|
23
26
|
"keywords": [
|
|
24
27
|
"react",
|
|
@@ -29,11 +32,13 @@
|
|
|
29
32
|
"typescript"
|
|
30
33
|
],
|
|
31
34
|
"peerDependencies": {
|
|
32
|
-
"next": "^15.
|
|
33
|
-
"react": "^19.1.
|
|
34
|
-
"react-dom": "^19.1.
|
|
35
|
+
"next": "^15.5.3",
|
|
36
|
+
"react": "^19.1.1",
|
|
37
|
+
"react-dom": "^19.1.1",
|
|
38
|
+
"embla-carousel-react": "^8.6.0"
|
|
35
39
|
},
|
|
36
40
|
"devDependencies": {
|
|
41
|
+
"@eslint/eslintrc": "^3.3.1",
|
|
37
42
|
"@rollup/plugin-commonjs": "^28.0.5",
|
|
38
43
|
"@rollup/plugin-node-resolve": "^16.0.1",
|
|
39
44
|
"@rollup/plugin-typescript": "^12.1.2",
|
|
@@ -41,13 +46,22 @@
|
|
|
41
46
|
"@storybook/addon-links": "^9.0.9",
|
|
42
47
|
"@storybook/addon-onboarding": "^9.0.9",
|
|
43
48
|
"@storybook/nextjs": "^9.0.9",
|
|
49
|
+
"@storybook/nextjs-vite": "^9.0.12",
|
|
50
|
+
"@tailwindcss/postcss": "^4.1.10",
|
|
51
|
+
"@types/node": "^24.0.3",
|
|
44
52
|
"@types/react": "^19.0.0",
|
|
45
53
|
"@types/react-date-range": "^1.4.10",
|
|
46
54
|
"@types/react-dom": "^19.0.0",
|
|
47
55
|
"autoprefixer": "^10.4.16",
|
|
56
|
+
"cross-env": "^7.0.3",
|
|
57
|
+
"eslint": "^9.29.0",
|
|
58
|
+
"eslint-config-next": "^15.3.4",
|
|
59
|
+
"eslint-plugin-storybook": "^9.0.12",
|
|
48
60
|
"postcss": "^8.4.32",
|
|
49
61
|
"postcss-import": "^16.1.0",
|
|
50
62
|
"postcss-prefix-selector": "^1.15.0",
|
|
63
|
+
"prettier-plugin-organize-imports": "^4.1.0",
|
|
64
|
+
"prettier-plugin-tailwindcss": "^0.6.13",
|
|
51
65
|
"react": "^19.1.0",
|
|
52
66
|
"react-dom": "^19.1.0",
|
|
53
67
|
"rimraf": "^5.0.5",
|
|
@@ -56,52 +70,64 @@
|
|
|
56
70
|
"rollup-plugin-postcss": "^4.0.2",
|
|
57
71
|
"rollup-plugin-typescript2": "^0.36.0",
|
|
58
72
|
"storybook": "^9.0.9",
|
|
59
|
-
"@tailwindcss/postcss": "^4.1.10",
|
|
60
73
|
"tailwindcss": "^4.0.0",
|
|
61
|
-
"typescript": "^5.
|
|
74
|
+
"typescript": "^5.9.2"
|
|
62
75
|
},
|
|
63
76
|
"dependencies": {
|
|
77
|
+
"@dnd-kit/core": "^6.3.1",
|
|
78
|
+
"@dnd-kit/modifiers": "^9.0.0",
|
|
79
|
+
"@dnd-kit/sortable": "^10.0.0",
|
|
80
|
+
"@dnd-kit/utilities": "^3.2.2",
|
|
81
|
+
"@faker-js/faker": "^9.8.0",
|
|
64
82
|
"@hookform/resolvers": "^5.1.1",
|
|
65
|
-
"@radix-ui/react-
|
|
66
|
-
"@radix-ui/react-
|
|
67
|
-
"@radix-ui/react-
|
|
68
|
-
"@radix-ui/react-avatar": "^1.0.4",
|
|
69
|
-
"@radix-ui/react-checkbox": "^1.0.4",
|
|
70
|
-
"@radix-ui/react-collapsible": "^1.0.3",
|
|
71
|
-
"@radix-ui/react-context-menu": "^2.1.5",
|
|
72
|
-
"@radix-ui/react-dialog": "^1.0.5",
|
|
73
|
-
"@radix-ui/react-dropdown-menu": "^2.0.6",
|
|
74
|
-
"@radix-ui/react-hover-card": "^1.0.7",
|
|
83
|
+
"@radix-ui/react-checkbox": "^1.3.3",
|
|
84
|
+
"@radix-ui/react-dialog": "^1.1.15",
|
|
85
|
+
"@radix-ui/react-dropdown-menu": "^2.1.16",
|
|
75
86
|
"@radix-ui/react-label": "^2.1.7",
|
|
76
|
-
"@radix-ui/react-
|
|
77
|
-
"@radix-ui/react-
|
|
78
|
-
"@radix-ui/react-
|
|
79
|
-
"@radix-ui/react-
|
|
80
|
-
"@radix-ui/react-radio-group": "^1.1.3",
|
|
81
|
-
"@radix-ui/react-scroll-area": "^1.0.5",
|
|
82
|
-
"@radix-ui/react-select": "^2.0.0",
|
|
83
|
-
"@radix-ui/react-separator": "^1.0.3",
|
|
84
|
-
"@radix-ui/react-slider": "^1.1.2",
|
|
87
|
+
"@radix-ui/react-popover": "^1.1.15",
|
|
88
|
+
"@radix-ui/react-progress": "^1.1.7",
|
|
89
|
+
"@radix-ui/react-select": "^2.2.6",
|
|
90
|
+
"@radix-ui/react-separator": "^1.1.7",
|
|
85
91
|
"@radix-ui/react-slot": "^1.2.3",
|
|
86
|
-
"@radix-ui/react-
|
|
87
|
-
"@radix-ui/react-tabs": "^1.0.4",
|
|
88
|
-
"@radix-ui/react-toast": "^1.1.5",
|
|
89
|
-
"@radix-ui/react-toggle": "^1.0.3",
|
|
90
|
-
"@radix-ui/react-toggle-group": "^1.0.4",
|
|
91
|
-
"@radix-ui/react-tooltip": "^1.0.7",
|
|
92
|
-
"@tanstack/react-table": "^8.21.3",
|
|
92
|
+
"@radix-ui/react-tabs": "^1.1.13",
|
|
93
93
|
"class-variance-authority": "^0.7.1",
|
|
94
94
|
"clsx": "^2.1.1",
|
|
95
|
+
"cmdk": "^1.1.1",
|
|
95
96
|
"date-fns": "^4.1.0",
|
|
97
|
+
"drizzle-orm": "^0.44.2",
|
|
98
|
+
"embla-carousel-react": "^8.6.0",
|
|
99
|
+
"geist": "^1.4.2",
|
|
100
|
+
"input-otp": "^1.4.2",
|
|
96
101
|
"lucide-react": "^0.516.0",
|
|
97
|
-
"
|
|
102
|
+
"motion": "^12.19.1",
|
|
103
|
+
"nanoid": "^5.1.5",
|
|
104
|
+
"next": "^15.5.3",
|
|
105
|
+
"next-themes": "^0.4.6",
|
|
106
|
+
"prettier": "^3.5.3",
|
|
107
|
+
"radix-ui": "^1.4.2",
|
|
108
|
+
"react": "^19.1.1",
|
|
109
|
+
"react-dom": "^19.1.1",
|
|
110
|
+
"react-day-picker": "^9.11.0",
|
|
111
|
+
"react-dropzone": "^14.3.8",
|
|
112
|
+
"react-error-boundary": "6.0.0",
|
|
98
113
|
"react-hook-form": "^7.58.1",
|
|
99
|
-
"react-
|
|
114
|
+
"react-resizable-panels": "^3.0.3",
|
|
115
|
+
"recharts": "^2.15.3",
|
|
116
|
+
"server-only": "^0.0.1",
|
|
117
|
+
"shadcn": "^3.3.1",
|
|
118
|
+
"sonner": "^2.0.5",
|
|
100
119
|
"tailwind-merge": "^2.6.0",
|
|
101
120
|
"tailwindcss-animate": "^1.0.7",
|
|
102
|
-
"
|
|
121
|
+
"tw-animate-css": "^1.3.4",
|
|
122
|
+
"vaul": "^1.1.2",
|
|
123
|
+
"zod": "^3.25.67"
|
|
103
124
|
},
|
|
104
125
|
"publishConfig": {
|
|
105
126
|
"registry": "https://registry.npmjs.org/"
|
|
127
|
+
},
|
|
128
|
+
"eslintConfig": {
|
|
129
|
+
"extends": [
|
|
130
|
+
"plugin:storybook/recommended"
|
|
131
|
+
]
|
|
106
132
|
}
|
|
107
133
|
}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Skip when this package is installed as a dependency (cwd under node_modules).
|
|
3
|
+
* In the repo root, allow only pnpm so npm/yarn do not corrupt the pnpm lockfile layout.
|
|
4
|
+
*/
|
|
5
|
+
const cwd = process.cwd().replace(/\\/g, "/");
|
|
6
|
+
if (/\/node_modules\//.test(cwd)) {
|
|
7
|
+
process.exit(0);
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
const execPath = process.env.npm_execpath ?? "";
|
|
11
|
+
if (execPath.includes("pnpm") || execPath.includes("pnpx")) {
|
|
12
|
+
process.exit(0);
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
console.error(
|
|
16
|
+
"@eintrek/erp-theme: use `pnpm install` in this repo (pnpm-lock.yaml). `npm install` is unsupported and often fails with npm resolution errors.",
|
|
17
|
+
);
|
|
18
|
+
process.exit(1);
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
import * as React from "react";
|
|
2
|
-
import { type VariantProps } from "class-variance-authority";
|
|
3
|
-
declare const buttonVariants: (props?: ({
|
|
4
|
-
variant?: "default" | "destructive" | "outline" | "secondary" | "ghost" | "link" | null | undefined;
|
|
5
|
-
size?: "default" | "sm" | "lg" | "icon" | null | undefined;
|
|
6
|
-
} & import("class-variance-authority/types").ClassProp) | undefined) => string;
|
|
7
|
-
export interface ButtonProps extends React.ButtonHTMLAttributes<HTMLButtonElement>, VariantProps<typeof buttonVariants> {
|
|
8
|
-
asChild?: boolean;
|
|
9
|
-
children?: React.ReactNode;
|
|
10
|
-
prefix?: string;
|
|
11
|
-
suffix?: string;
|
|
12
|
-
}
|
|
13
|
-
declare const Button: React.ForwardRefExoticComponent<ButtonProps & React.RefAttributes<HTMLButtonElement>>;
|
|
14
|
-
export { Button };
|
|
15
|
-
export type { buttonVariants };
|
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
import type { Meta, StoryObj } from '@storybook/react';
|
|
2
|
-
import { Button } from './Buttons';
|
|
3
|
-
declare const meta: Meta<typeof Button>;
|
|
4
|
-
export default meta;
|
|
5
|
-
type Story = StoryObj<typeof Button>;
|
|
6
|
-
export declare const Default: Story;
|
|
7
|
-
export declare const Secondary: Story;
|
|
8
|
-
export declare const Destructive: Story;
|
|
9
|
-
export declare const Outline: Story;
|
|
10
|
-
export declare const Ghost: Story;
|
|
11
|
-
export declare const Link: Story;
|
|
12
|
-
export declare const Small: Story;
|
|
13
|
-
export declare const Large: Story;
|
|
14
|
-
export declare const Blue: Story;
|
|
15
|
-
export declare const Green: Story;
|
|
16
|
-
export declare const Red: Story;
|
|
17
|
-
export declare const Yellow: Story;
|
|
18
|
-
export declare const Purple: Story;
|
|
19
|
-
export declare const Pink: Story;
|
|
20
|
-
export declare const Gray: Story;
|
|
21
|
-
export declare const Basic: Story;
|
|
22
|
-
export declare const Disabled: Story;
|
|
23
|
-
export declare const WithPrefixIcon: Story;
|
|
24
|
-
export declare const WithSuffixIcon: Story;
|
|
25
|
-
export declare const WithBothIcons: Story;
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
import * as React from "react";
|
|
2
|
-
declare const Card: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLDivElement> & React.RefAttributes<HTMLDivElement>>;
|
|
3
|
-
declare const CardHeader: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLDivElement> & React.RefAttributes<HTMLDivElement>>;
|
|
4
|
-
declare const CardTitle: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLHeadingElement> & React.RefAttributes<HTMLParagraphElement>>;
|
|
5
|
-
declare const CardDescription: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLParagraphElement> & React.RefAttributes<HTMLParagraphElement>>;
|
|
6
|
-
declare const CardContent: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLDivElement> & React.RefAttributes<HTMLDivElement>>;
|
|
7
|
-
declare const CardFooter: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLDivElement> & React.RefAttributes<HTMLDivElement>>;
|
|
8
|
-
export { Card, CardHeader, CardFooter, CardTitle, CardDescription, CardContent, };
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
import type { Meta, StoryObj } from '@storybook/react';
|
|
2
|
-
import { Card } from './Cards';
|
|
3
|
-
declare const meta: Meta<typeof Card>;
|
|
4
|
-
export default meta;
|
|
5
|
-
type Story = StoryObj<typeof Card>;
|
|
6
|
-
export declare const Default: Story;
|
|
7
|
-
export declare const WithImage: Story;
|
|
8
|
-
export declare const Simple: Story;
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
import type { Meta, StoryObj } from '@storybook/react';
|
|
2
|
-
import { Form } from './Form';
|
|
3
|
-
declare const meta: Meta<typeof Form>;
|
|
4
|
-
export default meta;
|
|
5
|
-
type Story = StoryObj<typeof Form>;
|
|
6
|
-
export declare const Basic: Story;
|
|
7
|
-
export declare const WithValidation: Story;
|
|
8
|
-
export declare const WithDefaultValues: Story;
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import type { Meta, StoryObj } from '@storybook/react';
|
|
2
|
-
import { Input } from './Input';
|
|
3
|
-
declare const meta: Meta<typeof Input>;
|
|
4
|
-
export default meta;
|
|
5
|
-
type Story = StoryObj<typeof Input>;
|
|
6
|
-
export declare const Basic: Story;
|
|
7
|
-
export declare const Disabled: Story;
|
|
8
|
-
export declare const WithIcon: Story;
|
|
9
|
-
export declare const SuffixText: Story;
|
|
10
|
-
export declare const SuffixIcon: Story;
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
export interface InputDropdownOption {
|
|
3
|
-
label: string;
|
|
4
|
-
value: string;
|
|
5
|
-
}
|
|
6
|
-
export interface InputDropdownProps {
|
|
7
|
-
label: string;
|
|
8
|
-
options: InputDropdownOption[];
|
|
9
|
-
value?: string;
|
|
10
|
-
onChange?: (e: React.ChangeEvent<HTMLSelectElement>) => void;
|
|
11
|
-
placeholder?: string;
|
|
12
|
-
required?: boolean;
|
|
13
|
-
error?: string;
|
|
14
|
-
name?: string;
|
|
15
|
-
disabled?: boolean;
|
|
16
|
-
inputClassName?: string;
|
|
17
|
-
}
|
|
18
|
-
declare const InputDropdown: React.FC<InputDropdownProps>;
|
|
19
|
-
export { InputDropdown };
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import type { Meta, StoryObj } from '@storybook/react';
|
|
2
|
-
import { InputDropdown } from './InputDropdown';
|
|
3
|
-
declare const meta: Meta<typeof InputDropdown>;
|
|
4
|
-
export default meta;
|
|
5
|
-
type Story = StoryObj<typeof InputDropdown>;
|
|
6
|
-
export declare const Basic: Story;
|
|
7
|
-
export declare const Disabled: Story;
|
|
8
|
-
export declare const CustomBackground: Story;
|
|
9
|
-
export declare const InputClassNameStringExample: Story;
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
import type { Meta, StoryObj } from '@storybook/react';
|
|
2
|
-
import { Label } from './Label';
|
|
3
|
-
declare const meta: Meta<typeof Label>;
|
|
4
|
-
export default meta;
|
|
5
|
-
type Story = StoryObj<typeof Label>;
|
|
6
|
-
export declare const Basic: Story;
|
|
7
|
-
export declare const Required: Story;
|
|
8
|
-
export declare const CustomClass: Story;
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
export interface ModalProps {
|
|
3
|
-
open: boolean;
|
|
4
|
-
onClose: () => void;
|
|
5
|
-
children: React.ReactNode;
|
|
6
|
-
actions?: React.ReactNode;
|
|
7
|
-
header?: React.ReactNode;
|
|
8
|
-
footer?: React.ReactNode;
|
|
9
|
-
size?: 'sm' | 'md' | 'lg' | 'full';
|
|
10
|
-
}
|
|
11
|
-
declare const Modal: React.FC<ModalProps>;
|
|
12
|
-
export { Modal };
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import type { Meta, StoryObj } from '@storybook/react';
|
|
2
|
-
import { Modal } from './Modal';
|
|
3
|
-
declare const meta: Meta<typeof Modal>;
|
|
4
|
-
export default meta;
|
|
5
|
-
type Story = StoryObj<typeof Modal>;
|
|
6
|
-
export declare const Basic: Story;
|
|
7
|
-
export declare const WithForm: Story;
|
|
8
|
-
export declare const WithFormFooterSubmit: Story;
|
|
9
|
-
export declare const WithHeaderAndFooter: Story;
|
|
10
|
-
export declare const Sizes: Story;
|
|
11
|
-
export declare const SuccessModal: Story;
|
|
12
|
-
export declare const WarningModal: Story;
|
|
13
|
-
export declare const InfoModal: Story;
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
import type { Meta, StoryObj } from '@storybook/react';
|
|
2
|
-
import { TableBody } from './TableBody';
|
|
3
|
-
declare const meta: Meta<typeof TableBody>;
|
|
4
|
-
export default meta;
|
|
5
|
-
type Story = StoryObj<typeof TableBody>;
|
|
6
|
-
export declare const Default: Story;
|
|
7
|
-
export declare const Basic: Story;
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
export interface TablePaginationProps {
|
|
2
|
-
pageIndex: number;
|
|
3
|
-
pageCount: number;
|
|
4
|
-
pageSize: number;
|
|
5
|
-
pageSizeOptions?: number[];
|
|
6
|
-
onPageChange: (page: number) => void;
|
|
7
|
-
onPageSizeChange: (size: number) => void;
|
|
8
|
-
className?: string;
|
|
9
|
-
}
|
|
10
|
-
export declare function TablePagination({ pageIndex, pageCount, pageSize, pageSizeOptions, onPageChange, onPageSizeChange, className, }: TablePaginationProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
import type { Meta, StoryObj } from '@storybook/react';
|
|
2
|
-
import { TablePagination } from './TablePagination';
|
|
3
|
-
declare const meta: Meta<typeof TablePagination>;
|
|
4
|
-
export default meta;
|
|
5
|
-
type Story = StoryObj<typeof TablePagination>;
|
|
6
|
-
export declare const FullyFeatured: Story;
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
export * from './types';
|
|
2
|
-
export * from './TableFilter';
|
|
3
|
-
export * from './TableBody';
|
|
4
|
-
export interface AccountingRecord {
|
|
5
|
-
id: number;
|
|
6
|
-
date: string;
|
|
7
|
-
description: string;
|
|
8
|
-
debit: number;
|
|
9
|
-
credit: number;
|
|
10
|
-
balance: number;
|
|
11
|
-
created_at: string;
|
|
12
|
-
}
|
|
13
|
-
export declare const mockAccountingData: AccountingRecord[];
|
|
@@ -1,54 +0,0 @@
|
|
|
1
|
-
import { Table as TableInstance, Row } from '@tanstack/react-table';
|
|
2
|
-
import { DateValueType } from 'react-tailwindcss-datepicker';
|
|
3
|
-
import { ReactNode } from 'react';
|
|
4
|
-
export interface TableData {
|
|
5
|
-
[key: string]: any;
|
|
6
|
-
}
|
|
7
|
-
export interface TableProps<T = any> {
|
|
8
|
-
data: T[];
|
|
9
|
-
columns: any[];
|
|
10
|
-
className?: string;
|
|
11
|
-
height?: string;
|
|
12
|
-
enableRowSelection?: boolean;
|
|
13
|
-
enableMultiRowSelection?: boolean;
|
|
14
|
-
enableSorting?: boolean;
|
|
15
|
-
enableFiltering?: boolean;
|
|
16
|
-
enablePagination?: boolean;
|
|
17
|
-
enableDateFilter?: boolean;
|
|
18
|
-
dateColumn?: string;
|
|
19
|
-
headerLeftSection?: ReactNode;
|
|
20
|
-
headerRightSection?: ReactNode;
|
|
21
|
-
onRowClick?: (row: Row<T>) => void;
|
|
22
|
-
onSelectionChange?: (selectedRows: Row<T>[]) => void;
|
|
23
|
-
onSortingChange?: (sorting: any) => void;
|
|
24
|
-
onFilteringChange?: (filters: any) => void;
|
|
25
|
-
onPaginationChange?: (pagination: any) => void;
|
|
26
|
-
onDateFilterChange?: (dateRange: DateValueType) => void;
|
|
27
|
-
}
|
|
28
|
-
export interface TableHeaderProps {
|
|
29
|
-
title?: string;
|
|
30
|
-
description?: string;
|
|
31
|
-
className?: string;
|
|
32
|
-
leftSection?: ReactNode;
|
|
33
|
-
rightSection?: ReactNode;
|
|
34
|
-
tabsSection?: ReactNode;
|
|
35
|
-
}
|
|
36
|
-
export interface TableFilterProps {
|
|
37
|
-
globalFilter: string;
|
|
38
|
-
setGlobalFilter: (value: string) => void;
|
|
39
|
-
showFilterPanel: boolean;
|
|
40
|
-
setShowFilterPanel: (value: boolean) => void;
|
|
41
|
-
enableDateFilter: boolean;
|
|
42
|
-
dateRange: DateValueType;
|
|
43
|
-
setDateRange: (value: DateValueType) => void;
|
|
44
|
-
isDatePickerOpen: boolean;
|
|
45
|
-
setIsDatePickerOpen: (value: boolean) => void;
|
|
46
|
-
table: any;
|
|
47
|
-
}
|
|
48
|
-
export interface TableBodyProps {
|
|
49
|
-
table: TableInstance<any>;
|
|
50
|
-
onRowClick?: (row: Row<any>) => void;
|
|
51
|
-
}
|
|
52
|
-
export interface TablePaginationProps {
|
|
53
|
-
table: TableInstance<any>;
|
|
54
|
-
}
|