@pipe0/react-sdk 0.0.2 → 0.0.3
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/CHANGELOG.md +8 -0
- package/package.json +14 -14
- package/src/hooks/usePipeCatalogTable.ts +3 -5
- package/src/index.ts +1 -0
package/CHANGELOG.md
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@pipe0/react-sdk",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.3",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "React utils to work with pipe0",
|
|
6
6
|
"keywords": [
|
|
@@ -19,23 +19,23 @@
|
|
|
19
19
|
".": "./src/index.ts"
|
|
20
20
|
},
|
|
21
21
|
"private": false,
|
|
22
|
-
"scripts": {
|
|
23
|
-
"lint": "eslint . --max-warnings 0",
|
|
24
|
-
"check-types": "tsc --noEmit"
|
|
25
|
-
},
|
|
26
22
|
"author": "",
|
|
27
23
|
"license": "MIT",
|
|
28
24
|
"dependencies": {
|
|
29
|
-
"
|
|
30
|
-
"react": "
|
|
31
|
-
"react-
|
|
32
|
-
"@
|
|
25
|
+
"react": "^19.0.0",
|
|
26
|
+
"react-dom": "^19.0.0",
|
|
27
|
+
"@tanstack/react-table": "^8.21.2",
|
|
28
|
+
"@pipe0/client-sdk": "0.0.48"
|
|
33
29
|
},
|
|
34
30
|
"devDependencies": {
|
|
35
|
-
"@
|
|
36
|
-
"@types/react": "catalog:",
|
|
31
|
+
"@types/react": "^19.0.8",
|
|
37
32
|
"@types/node": "^22.13.2",
|
|
38
|
-
"eslint": "
|
|
39
|
-
"@types/react-dom": "
|
|
33
|
+
"eslint": "^9.30.0",
|
|
34
|
+
"@types/react-dom": "^19.0.3",
|
|
35
|
+
"@pipe0/eslint-config": "0.0.0"
|
|
36
|
+
},
|
|
37
|
+
"scripts": {
|
|
38
|
+
"lint": "eslint . --max-warnings 0",
|
|
39
|
+
"check-types": "tsc --noEmit"
|
|
40
40
|
}
|
|
41
|
-
}
|
|
41
|
+
}
|
|
@@ -23,15 +23,14 @@ export function useDebounce(
|
|
|
23
23
|
const [value, setValue] = useState(initialValue);
|
|
24
24
|
|
|
25
25
|
const cbRef = useRef(cb);
|
|
26
|
+
cbRef.current = cb;
|
|
26
27
|
|
|
27
28
|
const setImmediately = useCallback((v: string) => {
|
|
28
29
|
setValue(v);
|
|
29
|
-
|
|
30
|
+
cbRef.current(v);
|
|
30
31
|
}, []);
|
|
31
32
|
|
|
32
33
|
useEffect(() => {
|
|
33
|
-
if (!cbRef.current) return;
|
|
34
|
-
cbRef.current = cb;
|
|
35
34
|
const handle = setTimeout(() => {
|
|
36
35
|
cbRef.current(value);
|
|
37
36
|
}, timeout);
|
|
@@ -97,7 +96,6 @@ export function usePipeCatalogTable(
|
|
|
97
96
|
});
|
|
98
97
|
|
|
99
98
|
const columnFilters = table.getState().columnFilters;
|
|
100
|
-
const x = "lsdfj";
|
|
101
99
|
const category: PipeCategory | null = useMemo(
|
|
102
100
|
() =>
|
|
103
101
|
(columnFilters.find((e) => e.id === "categories" && e.value)
|
|
@@ -117,7 +115,7 @@ export function usePipeCatalogTable(
|
|
|
117
115
|
pipeEntriesByBasePipe,
|
|
118
116
|
} = useMemo(() => {
|
|
119
117
|
return getTableDataAggregates(initialTableData, category);
|
|
120
|
-
}, [category]);
|
|
118
|
+
}, [category, initialTableData]);
|
|
121
119
|
|
|
122
120
|
const [expandedSidebarSections, setExpandedSidebarSections] = useState<
|
|
123
121
|
string[]
|
package/src/index.ts
CHANGED