@teamprodevs/appsmith-custom-table 0.3.0 → 0.4.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/index.d.ts CHANGED
@@ -1,24 +1,8 @@
1
1
  import { default as default_2 } from 'zod';
2
2
  import { JSX } from 'react/jsx-runtime';
3
+ import { SortDirection } from '@tanstack/react-table';
3
4
 
4
- declare enum ColumnType {
5
- TEXT = "text",
6
- NUMBER = "number",
7
- ENUM = "enum",
8
- DATE = "date",
9
- CURRENCY = "currency",
10
- PHONE = "phone"
11
- }
12
-
13
- declare enum HTTP_METHODS {
14
- "GET" = "GET",
15
- "POST" = "POST",
16
- "PUT" = "PUT",
17
- "DELETE" = "DELETE",
18
- "PATCH" = "PATCH"
19
- }
20
-
21
- export declare function InfiniteTable(props: TableModel): JSX.Element;
5
+ export declare function ClientTable(props: TableModel): JSX.Element;
22
6
 
23
7
  declare enum ItemSize {
24
8
  "xs" = "xs",
@@ -35,33 +19,17 @@ declare enum PinDirection {
35
19
  declare type TableModel = default_2.infer<typeof TableModelSchema>;
36
20
 
37
21
  declare const TableModelSchema: default_2.ZodObject<{
38
- fetcher: default_2.ZodObject<{
39
- url: default_2.ZodURL;
40
- method: default_2.ZodOptional<default_2.ZodDefault<default_2.ZodEnum<typeof HTTP_METHODS>>>;
41
- headers: default_2.ZodOptional<default_2.ZodRecord<default_2.ZodString, default_2.ZodString>>;
42
- body: default_2.ZodOptional<default_2.ZodAny>;
43
- accessor: default_2.ZodOptional<default_2.ZodString>;
44
- paginationKeys: default_2.ZodOptional<default_2.ZodObject<{
45
- offset: default_2.ZodDefault<default_2.ZodString>;
46
- limit: default_2.ZodDefault<default_2.ZodString>;
47
- }, default_2.core.$strip>>;
48
- perPage: default_2.ZodOptional<default_2.ZodDefault<default_2.ZodNumber>>;
49
- pageParam: default_2.ZodOptional<default_2.ZodDefault<default_2.ZodNumber>>;
50
- }, default_2.core.$strip>;
22
+ data: default_2.ZodDefault<default_2.ZodArray<default_2.ZodAny>>;
23
+ limit: default_2.ZodOptional<default_2.ZodDefault<default_2.ZodNumber>>;
51
24
  schema: default_2.ZodRecord<default_2.ZodString, default_2.ZodObject<{
52
- type: default_2.ZodEnum<typeof ColumnType>;
53
- options: default_2.ZodOptional<default_2.ZodArray<default_2.ZodObject<{
54
- value: default_2.ZodString;
55
- title: default_2.ZodString;
56
- }, default_2.core.$strip>>>;
57
25
  sort: default_2.ZodOptional<default_2.ZodBoolean>;
58
- filter: default_2.ZodOptional<default_2.ZodBoolean>;
59
26
  size: default_2.ZodOptional<default_2.ZodEnum<typeof ItemSize>>;
60
27
  title: default_2.ZodOptional<default_2.ZodString>;
61
28
  className: default_2.ZodOptional<default_2.ZodString>;
62
29
  }, default_2.core.$strip>>;
63
30
  indexRow: default_2.ZodOptional<default_2.ZodObject<{
64
31
  enable: default_2.ZodBoolean;
32
+ pin: default_2.ZodOptional<default_2.ZodDefault<default_2.ZodEnum<typeof PinDirection>>>;
65
33
  size: default_2.ZodOptional<default_2.ZodDefault<default_2.ZodEnum<typeof ItemSize>>>;
66
34
  }, default_2.core.$strip>>;
67
35
  rowActions: default_2.ZodOptional<default_2.ZodArray<default_2.ZodObject<{
@@ -5744,10 +5712,6 @@ declare const TableModelSchema: default_2.ZodObject<{
5744
5712
  pin: default_2.ZodDefault<default_2.ZodEnum<typeof PinDirection>>;
5745
5713
  }, default_2.core.$strip>>;
5746
5714
  translations: default_2.ZodOptional<default_2.ZodRecord<default_2.ZodString, default_2.ZodString>>;
5747
- updateModel: default_2.ZodOptional<default_2.ZodFunction<default_2.ZodTuple<readonly [default_2.ZodAny], null>, default_2.core.$ZodFunctionOut>>;
5748
- triggerEvent: default_2.ZodOptional<default_2.ZodFunction<default_2.ZodTuple<readonly [default_2.ZodString, default_2.ZodObject<{
5749
- row: default_2.ZodAny;
5750
- }, default_2.core.$strip>], null>, default_2.core.$ZodFunctionOut>>;
5751
5715
  styles: default_2.ZodOptional<default_2.ZodObject<{
5752
5716
  head: default_2.ZodOptional<default_2.ZodObject<{
5753
5717
  body: default_2.ZodOptional<default_2.ZodString>;
@@ -5760,14 +5724,18 @@ declare const TableModelSchema: default_2.ZodObject<{
5760
5724
  row: default_2.ZodOptional<default_2.ZodString>;
5761
5725
  cell: default_2.ZodOptional<default_2.ZodString>;
5762
5726
  }, default_2.core.$strip>>;
5763
- card: default_2.ZodOptional<default_2.ZodObject<{
5764
- container: default_2.ZodOptional<default_2.ZodString>;
5765
- header: default_2.ZodOptional<default_2.ZodString>;
5766
- content: default_2.ZodOptional<default_2.ZodString>;
5767
- }, default_2.core.$strip>>;
5727
+ container: default_2.ZodOptional<default_2.ZodString>;
5768
5728
  table: default_2.ZodOptional<default_2.ZodString>;
5769
5729
  variables: default_2.ZodOptional<default_2.ZodRecord<default_2.ZodString, default_2.ZodString>>;
5770
5730
  }, default_2.core.$strip>>;
5731
+ triggerEvent: default_2.ZodOptional<default_2.ZodFunction<default_2.ZodTuple<readonly [default_2.ZodString, default_2.ZodObject<{
5732
+ row: default_2.ZodOptional<default_2.ZodAny>;
5733
+ sortCol: default_2.ZodOptional<default_2.ZodString>;
5734
+ sortOption: default_2.ZodOptional<default_2.ZodCustom<SortDirection, SortDirection>>;
5735
+ page: default_2.ZodOptional<default_2.ZodNumber>;
5736
+ limit: default_2.ZodOptional<default_2.ZodNumber>;
5737
+ }, default_2.core.$strip>], null>, default_2.core.$ZodFunctionOut>>;
5738
+ updateModel: default_2.ZodOptional<default_2.ZodFunction<default_2.ZodTuple<readonly [default_2.ZodAny], null>, default_2.core.$ZodFunctionOut>>;
5771
5739
  }, default_2.core.$strip>;
5772
5740
 
5773
5741
  export { }
package/package.json CHANGED
@@ -1,103 +1,104 @@
1
- {
2
- "name": "@teamprodevs/appsmith-custom-table",
3
- "version": "0.3.0",
4
- "type": "module",
5
- "private": false,
6
- "keywords": [
7
- "appsmith",
8
- "custom table",
9
- "tanstack table"
10
- ],
11
- "publishConfig": {
12
- "access": "public"
13
- },
14
- "scripts": {
15
- "build": "tsc -b && vite build",
16
- "lint": "eslint .",
17
- "preview": "vite preview",
18
- "prepublishOnly": "npm run build",
19
- "storybook": "storybook dev -p 6006",
20
- "build-storybook": "storybook build"
21
- },
22
- "repository": {
23
- "type": "git",
24
- "url": "git+https://github.com/smarts-uz/ts-vite-appsmith-table.git"
25
- },
26
- "types": "./dist/index.d.ts",
27
- "exports": {
28
- ".": {
29
- "import": "./dist/app.js",
30
- "require": "./dist/app.umd.cjs"
31
- },
32
- "./dist/styles.css": "./dist/styles.css"
33
- },
34
- "files": [
35
- "dist"
36
- ],
37
- "sideEffects": false,
38
- "main": "./dist/app.umd.js",
39
- "module": "./dist/app.es.js",
40
- "dependencies": {
41
- "@radix-ui/react-checkbox": "^1.3.3",
42
- "@radix-ui/react-dropdown-menu": "^2.1.16",
43
- "@radix-ui/react-hover-card": "^1.1.15",
44
- "@radix-ui/react-label": "^2.1.8",
45
- "@radix-ui/react-popover": "^1.1.15",
46
- "@radix-ui/react-select": "^2.2.6",
47
- "@radix-ui/react-separator": "^1.1.8",
48
- "@radix-ui/react-slider": "^1.3.6",
49
- "@radix-ui/react-slot": "^1.2.4",
50
- "@radix-ui/react-switch": "^1.2.6",
51
- "@radix-ui/react-tooltip": "^1.2.8",
52
- "@storybook/react": "^10.0.7",
53
- "@tailwindcss/vite": "^4.1.17",
54
- "@tanstack/react-query": "^5.90.7",
55
- "@tanstack/react-query-devtools": "^5.90.2",
56
- "@tanstack/react-table": "^8.21.3",
57
- "autoprefixer": "^10.4.22",
58
- "class-variance-authority": "^0.7.1",
59
- "clsx": "^2.1.1",
60
- "date-fns": "^4.1.0",
61
- "lodash": "^4.17.21",
62
- "lucide-react": "^0.553.0",
63
- "postcss": "^8.5.6",
64
- "react": "18.3.1",
65
- "react-day-picker": "^9.11.1",
66
- "tailwind-merge": "^3.3.1",
67
- "tailwindcss": "3.4.18",
68
- "tailwindcss-animate": "^1.0.7",
69
- "vite-plugin-dts": "^4.5.4",
70
- "vite-tsconfig-paths": "^5.1.4",
71
- "zod": "^4.1.12"
72
- },
73
- "devDependencies": {
74
- "@chromatic-com/storybook": "4.1.2",
75
- "@eslint/js": "latest",
76
- "@storybook/addon-a11y": "10.0.7",
77
- "@storybook/addon-docs": "10.0.7",
78
- "@storybook/addon-vitest": "10.0.7",
79
- "@storybook/react-vite": "10.0.7",
80
- "@types/lodash": "^4.17.20",
81
- "@types/node": "^24.6.0",
82
- "@types/react": "^19.1.16",
83
- "@types/react-dom": "^19.1.9",
84
- "@vitejs/plugin-react": "^5.0.4",
85
- "@vitest/browser-playwright": "^4.0.9",
86
- "@vitest/coverage-v8": "^4.0.9",
87
- "babel-plugin-react-compiler": "^1.0.0",
88
- "eslint": "^9.36.0",
89
- "eslint-plugin-react-hooks": "^5.2.0",
90
- "eslint-plugin-react-refresh": "^0.4.22",
91
- "eslint-plugin-storybook": "10.0.7",
92
- "globals": "^16.4.0",
93
- "playwright": "^1.56.1",
94
- "storybook": "10.0.7",
95
- "tw-animate-css": "^1.4.0",
96
- "typescript": "~5.9.3",
97
- "typescript-eslint": "^8.45.0",
98
- "vite": "^7.1.7",
99
- "vitest": "^4.0.9"
100
- },
101
- "author": "Ramz001",
102
- "license": "MIT"
103
- }
1
+ {
2
+ "name": "@teamprodevs/appsmith-custom-table",
3
+ "version": "0.4.0",
4
+ "type": "module",
5
+ "private": false,
6
+ "keywords": [
7
+ "appsmith",
8
+ "custom table",
9
+ "tanstack table"
10
+ ],
11
+ "publishConfig": {
12
+ "access": "public"
13
+ },
14
+ "scripts": {
15
+ "build": "tsc -b && vite build",
16
+ "lint": "eslint .",
17
+ "preview": "vite preview",
18
+ "prepublishOnly": "npm run build",
19
+ "storybook": "storybook dev -p 6006",
20
+ "build-storybook": "storybook build"
21
+ },
22
+ "repository": {
23
+ "type": "git",
24
+ "url": "git+https://github.com/smarts-uz/ts-vite-appsmith-table.git"
25
+ },
26
+ "types": "./dist/index.d.ts",
27
+ "exports": {
28
+ ".": {
29
+ "import": "./dist/app.js",
30
+ "require": "./dist/app.umd.cjs"
31
+ },
32
+ "./dist/styles.css": "./dist/styles.css"
33
+ },
34
+ "files": [
35
+ "dist"
36
+ ],
37
+ "sideEffects": false,
38
+ "main": "./dist/app.umd.js",
39
+ "module": "./dist/app.es.js",
40
+ "dependencies": {
41
+ "@radix-ui/react-checkbox": "^1.3.3",
42
+ "@radix-ui/react-dropdown-menu": "^2.1.16",
43
+ "@radix-ui/react-hover-card": "^1.1.15",
44
+ "@radix-ui/react-label": "^2.1.8",
45
+ "@radix-ui/react-popover": "^1.1.15",
46
+ "@radix-ui/react-select": "^2.2.6",
47
+ "@radix-ui/react-separator": "^1.1.8",
48
+ "@radix-ui/react-slider": "^1.3.6",
49
+ "@radix-ui/react-slot": "^1.2.4",
50
+ "@radix-ui/react-switch": "^1.2.6",
51
+ "@radix-ui/react-tooltip": "^1.2.8",
52
+ "@storybook/react": "^10.0.7",
53
+ "@tailwindcss/vite": "^4.1.17",
54
+ "@tanstack/react-query": "^5.90.7",
55
+ "@tanstack/react-query-devtools": "^5.90.2",
56
+ "@tanstack/react-table": "^8.21.3",
57
+ "autoprefixer": "^10.4.22",
58
+ "class-variance-authority": "^0.7.1",
59
+ "clsx": "^2.1.1",
60
+ "date-fns": "^4.1.0",
61
+ "lodash": "^4.17.21",
62
+ "lucide-react": "^0.553.0",
63
+ "nuqs": "^2.8.0",
64
+ "postcss": "^8.5.6",
65
+ "react": "18.3.1",
66
+ "react-day-picker": "^9.11.1",
67
+ "tailwind-merge": "^3.3.1",
68
+ "tailwindcss": "3.4.18",
69
+ "tailwindcss-animate": "^1.0.7",
70
+ "vite-plugin-dts": "^4.5.4",
71
+ "vite-tsconfig-paths": "^5.1.4",
72
+ "zod": "^4.1.12"
73
+ },
74
+ "devDependencies": {
75
+ "@chromatic-com/storybook": "4.1.2",
76
+ "@eslint/js": "latest",
77
+ "@storybook/addon-a11y": "10.0.7",
78
+ "@storybook/addon-docs": "10.0.7",
79
+ "@storybook/addon-vitest": "10.0.7",
80
+ "@storybook/react-vite": "10.0.7",
81
+ "@types/lodash": "^4.17.20",
82
+ "@types/node": "^24.6.0",
83
+ "@types/react": "^19.1.16",
84
+ "@types/react-dom": "^19.1.9",
85
+ "@vitejs/plugin-react": "^5.0.4",
86
+ "@vitest/browser-playwright": "^4.0.9",
87
+ "@vitest/coverage-v8": "^4.0.9",
88
+ "babel-plugin-react-compiler": "^1.0.0",
89
+ "eslint": "^9.36.0",
90
+ "eslint-plugin-react-hooks": "^5.2.0",
91
+ "eslint-plugin-react-refresh": "^0.4.22",
92
+ "eslint-plugin-storybook": "10.0.7",
93
+ "globals": "^16.4.0",
94
+ "playwright": "^1.56.1",
95
+ "storybook": "10.0.7",
96
+ "tw-animate-css": "^1.4.0",
97
+ "typescript": "~5.9.3",
98
+ "typescript-eslint": "^8.45.0",
99
+ "vite": "^7.1.7",
100
+ "vitest": "^4.0.9"
101
+ },
102
+ "author": "Ramz001",
103
+ "license": "MIT"
104
+ }
@@ -1,42 +0,0 @@
1
- import { c as s, T as c, P as u, a as i, b as m, C as P, Q as d } from "./ZDWCUMSJ-D0jBnQB_.js";
2
- import { g as v, c as C, a as e } from "./index-C1g_GPyX.js";
3
- var h = (t) => {
4
- const [r, o] = s({
5
- prefix: "TanstackQueryDevtools"
6
- }), a = v(), l = C(() => {
7
- const n = r.theme_preference || c;
8
- return n !== "system" ? n : a();
9
- });
10
- return e(d.Provider, {
11
- value: t,
12
- get children() {
13
- return e(u, {
14
- disabled: !0,
15
- localStore: r,
16
- setLocalStore: o,
17
- get children() {
18
- return e(i.Provider, {
19
- value: l,
20
- get children() {
21
- return e(m, {
22
- get children() {
23
- return e(P, {
24
- localStore: r,
25
- setLocalStore: o,
26
- get onClose() {
27
- return t.onClose;
28
- },
29
- showPanelViewOnly: !0
30
- });
31
- }
32
- });
33
- }
34
- });
35
- }
36
- });
37
- }
38
- });
39
- }, p = h;
40
- export {
41
- p as default
42
- };
@@ -1,33 +0,0 @@
1
- import { c, T as l, P as m, a as u, D as v, Q as i } from "./ZDWCUMSJ-D0jBnQB_.js";
2
- import { g as d, c as f, a as e } from "./index-C1g_GPyX.js";
3
- var p = (a) => {
4
- const [r, t] = c({
5
- prefix: "TanstackQueryDevtools"
6
- }), n = d(), s = f(() => {
7
- const o = r.theme_preference || l;
8
- return o !== "system" ? o : n();
9
- });
10
- return e(i.Provider, {
11
- value: a,
12
- get children() {
13
- return e(m, {
14
- localStore: r,
15
- setLocalStore: t,
16
- get children() {
17
- return e(u.Provider, {
18
- value: s,
19
- get children() {
20
- return e(v, {
21
- localStore: r,
22
- setLocalStore: t
23
- });
24
- }
25
- });
26
- }
27
- });
28
- }
29
- });
30
- }, C = p;
31
- export {
32
- C as default
33
- };