@pipe0/react-sdk 0.0.8 → 0.0.9

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.
@@ -0,0 +1,35 @@
1
+ import { type PipeCatalogTableData, type PipeCategory, type PipeId } from "@pipe0/client-sdk";
2
+ import { type ColumnFilter } from "@tanstack/react-table";
3
+ export type InputFieldEntries = Record<string, PipeId[]>;
4
+ export type OutputFieldEntries = Record<string, PipeId[]>;
5
+ export declare function usePipeCatalogTable(config?: {
6
+ initialColumnFilters?: ColumnFilter[];
7
+ }): {
8
+ table: import("@tanstack/react-table").Table<PipeCatalogTableData>;
9
+ sidebar: {
10
+ sortedInputFieldEntries: [string, ("run:prompt@1" | "company:newssummary:website@1" | "website:technologystack:builtwith@1" | "company:websiteurl:email@1" | "people:workemail:waterfall@1" | "people:is:workemail@1" | "people:split:name@1" | "people:join:name@1" | "people:professionalprofile:waterfall@1" | "people:professionalprofileurl:name@1" | "people:professionalprofileurl:email:waterfall@1" | "people:personalemail:professionalprofile:waterfall@1" | "people:validate:email:zerobounce@1" | "people:mobilenumber:professionalprofile:waterfall@1" | "people:mobilenumber:workemail:waterfall@1" | "company:profile:builtwith@1" | "company:identity@1" | "company:overview@1")[]][];
11
+ sortedOutputFieldEntries: [string, ("run:prompt@1" | "company:newssummary:website@1" | "website:technologystack:builtwith@1" | "company:websiteurl:email@1" | "people:workemail:waterfall@1" | "people:is:workemail@1" | "people:split:name@1" | "people:join:name@1" | "people:professionalprofile:waterfall@1" | "people:professionalprofileurl:name@1" | "people:professionalprofileurl:email:waterfall@1" | "people:personalemail:professionalprofile:waterfall@1" | "people:validate:email:zerobounce@1" | "people:mobilenumber:professionalprofile:waterfall@1" | "people:mobilenumber:workemail:waterfall@1" | "company:profile:builtwith@1" | "company:identity@1" | "company:overview@1")[]][];
12
+ sortedTagEntries: [string, ("run:prompt@1" | "company:newssummary:website@1" | "website:technologystack:builtwith@1" | "company:websiteurl:email@1" | "people:workemail:waterfall@1" | "people:is:workemail@1" | "people:split:name@1" | "people:join:name@1" | "people:professionalprofile:waterfall@1" | "people:professionalprofileurl:name@1" | "people:professionalprofileurl:email:waterfall@1" | "people:personalemail:professionalprofile:waterfall@1" | "people:validate:email:zerobounce@1" | "people:mobilenumber:professionalprofile:waterfall@1" | "people:mobilenumber:workemail:waterfall@1" | "company:profile:builtwith@1" | "company:identity@1" | "company:overview@1")[]][];
13
+ sortedProviderEntries: [string, ("run:prompt@1" | "company:newssummary:website@1" | "website:technologystack:builtwith@1" | "company:websiteurl:email@1" | "people:workemail:waterfall@1" | "people:is:workemail@1" | "people:split:name@1" | "people:join:name@1" | "people:professionalprofile:waterfall@1" | "people:professionalprofileurl:name@1" | "people:professionalprofileurl:email:waterfall@1" | "people:personalemail:professionalprofile:waterfall@1" | "people:validate:email:zerobounce@1" | "people:mobilenumber:professionalprofile:waterfall@1" | "people:mobilenumber:workemail:waterfall@1" | "company:profile:builtwith@1" | "company:identity@1" | "company:overview@1")[]][];
14
+ pipeIdsByInputField: Record<string, ("run:prompt@1" | "company:newssummary:website@1" | "website:technologystack:builtwith@1" | "company:websiteurl:email@1" | "people:workemail:waterfall@1" | "people:is:workemail@1" | "people:split:name@1" | "people:join:name@1" | "people:professionalprofile:waterfall@1" | "people:professionalprofileurl:name@1" | "people:professionalprofileurl:email:waterfall@1" | "people:personalemail:professionalprofile:waterfall@1" | "people:validate:email:zerobounce@1" | "people:mobilenumber:professionalprofile:waterfall@1" | "people:mobilenumber:workemail:waterfall@1" | "company:profile:builtwith@1" | "company:identity@1" | "company:overview@1")[]>;
15
+ pipeIdsByOutputField: Record<string, ("run:prompt@1" | "company:newssummary:website@1" | "website:technologystack:builtwith@1" | "company:websiteurl:email@1" | "people:workemail:waterfall@1" | "people:is:workemail@1" | "people:split:name@1" | "people:join:name@1" | "people:professionalprofile:waterfall@1" | "people:professionalprofileurl:name@1" | "people:professionalprofileurl:email:waterfall@1" | "people:personalemail:professionalprofile:waterfall@1" | "people:validate:email:zerobounce@1" | "people:mobilenumber:professionalprofile:waterfall@1" | "people:mobilenumber:workemail:waterfall@1" | "company:profile:builtwith@1" | "company:identity@1" | "company:overview@1")[]>;
16
+ pipeIdsByProvider: Record<string, ("run:prompt@1" | "company:newssummary:website@1" | "website:technologystack:builtwith@1" | "company:websiteurl:email@1" | "people:workemail:waterfall@1" | "people:is:workemail@1" | "people:split:name@1" | "people:join:name@1" | "people:professionalprofile:waterfall@1" | "people:professionalprofileurl:name@1" | "people:professionalprofileurl:email:waterfall@1" | "people:personalemail:professionalprofile:waterfall@1" | "people:validate:email:zerobounce@1" | "people:mobilenumber:professionalprofile:waterfall@1" | "people:mobilenumber:workemail:waterfall@1" | "company:profile:builtwith@1" | "company:identity@1" | "company:overview@1")[]>;
17
+ pipeIdsByTag: Record<string, ("run:prompt@1" | "company:newssummary:website@1" | "website:technologystack:builtwith@1" | "company:websiteurl:email@1" | "people:workemail:waterfall@1" | "people:is:workemail@1" | "people:split:name@1" | "people:join:name@1" | "people:professionalprofile:waterfall@1" | "people:professionalprofileurl:name@1" | "people:professionalprofileurl:email:waterfall@1" | "people:personalemail:professionalprofile:waterfall@1" | "people:validate:email:zerobounce@1" | "people:mobilenumber:professionalprofile:waterfall@1" | "people:mobilenumber:workemail:waterfall@1" | "company:profile:builtwith@1" | "company:identity@1" | "company:overview@1")[]>;
18
+ expandedSidebarSections: string[];
19
+ setExpandedSidebarSections: import("react").Dispatch<import("react").SetStateAction<string[]>>;
20
+ removeColumnFilter: (id: "inputFields" | "outputFields" | "tags" | "providers") => void;
21
+ addColumnFilter: (id: "inputFields" | "outputFields" | "tags" | "providers", value: string) => void;
22
+ };
23
+ pipeEntriesByBasePipe: Record<string, (import("@pipe0/client-sdk").PipeMetaCatalogEntry<"run:prompt@1" | "company:newssummary:website@1" | "website:technologystack:builtwith@1" | "company:websiteurl:email@1" | "people:workemail:waterfall@1" | "people:is:workemail@1" | "people:split:name@1" | "people:join:name@1" | "people:professionalprofile:waterfall@1" | "people:professionalprofileurl:name@1" | "people:professionalprofileurl:email:waterfall@1" | "people:personalemail:professionalprofile:waterfall@1" | "people:validate:email:zerobounce@1" | "people:mobilenumber:professionalprofile:waterfall@1" | "people:mobilenumber:workemail:waterfall@1" | "company:profile:builtwith@1" | "company:identity@1" | "company:overview@1"> & {
24
+ pipeId: PipeId;
25
+ })[]>;
26
+ filterByField: (id: "inputFields" | "outputFields", fieldName: string) => void;
27
+ globalFilterInput: string;
28
+ setGlobalFilterInput: import("react").Dispatch<import("react").SetStateAction<string>>;
29
+ isFilterChecked: (id: "inputFields" | "outputFields" | "tags" | "providers", value: string) => boolean;
30
+ resetColumnFilters: () => void;
31
+ category: PipeCategory;
32
+ setCategory: (category: PipeCategory | null) => void;
33
+ showFeaturedPipes: boolean;
34
+ };
35
+ //# sourceMappingURL=usePipeCatalogTableHook.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"usePipeCatalogTableHook.d.ts","sourceRoot":"","sources":["../../src/hooks/usePipeCatalogTableHook.ts"],"names":[],"mappings":"AAAA,OAAO,EAGL,KAAK,oBAAoB,EACzB,KAAK,YAAY,EACjB,KAAK,MAAM,EACZ,MAAM,mBAAmB,CAAC;AAC3B,OAAO,EACL,KAAK,YAAY,EAMlB,MAAM,uBAAuB,CAAC;AA6B/B,MAAM,MAAM,iBAAiB,GAAG,MAAM,CAAC,MAAM,EAAE,MAAM,EAAE,CAAC,CAAC;AACzD,MAAM,MAAM,kBAAkB,GAAG,MAAM,CAAC,MAAM,EAAE,MAAM,EAAE,CAAC,CAAC;AA0B1D,wBAAgB,mBAAmB,CACjC,MAAM,GAAE;IACN,oBAAoB,CAAC,EAAE,YAAY,EAAE,CAAC;CAClC;;;;;;;;;;;;;iCAkFA,aAAa,GAAG,cAAc,GAAG,MAAM,GAAG,WAAW;8BAhBrD,aAAa,GAAG,cAAc,GAAG,MAAM,GAAG,WAAW,SAClD,MAAM;;;;;wBA4BT,aAAa,GAAG,cAAc,aACvB,MAAM;;;0BARb,aAAa,GAAG,cAAc,GAAG,MAAM,GAAG,WAAW,SAClD,MAAM;;;4BA1CgB,YAAY,GAAG,IAAI;;EA0FnD"}
@@ -1,7 +1,7 @@
1
1
  import { getInitialTableData, getTableDataAggregates, } from "@pipe0/client-sdk";
2
2
  import { createColumnHelper, getCoreRowModel, getFilteredRowModel, getPaginationRowModel, useReactTable, } from "@tanstack/react-table";
3
3
  import { useCallback, useEffect, useMemo, useRef, useState } from "react";
4
- export function useDebounce(cb, config = {}) {
4
+ function useDebounce(cb, config = {}) {
5
5
  const { initialValue = "", timeout = 400 } = config;
6
6
  const [value, setValue] = useState(initialValue);
7
7
  const cbRef = useRef(cb);
package/dist/index.d.ts CHANGED
@@ -1,2 +1,2 @@
1
- export * from "./hooks/usePipeCatalogTable.js";
1
+ export { usePipeCatalogTable, type InputFieldEntries, type OutputFieldEntries, } from "./hooks/usePipeCatalogTableHook.js";
2
2
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,gCAAgC,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,mBAAmB,EACnB,KAAK,iBAAiB,EACtB,KAAK,kBAAkB,GACxB,MAAM,oCAAoC,CAAC"}
package/dist/index.js CHANGED
@@ -1 +1 @@
1
- export * from "./hooks/usePipeCatalogTable.js";
1
+ export { usePipeCatalogTable, } from "./hooks/usePipeCatalogTableHook.js";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pipe0/react-sdk",
3
- "version": "0.0.8",
3
+ "version": "0.0.9",
4
4
  "type": "module",
5
5
  "description": "React utils to work with pipe0",
6
6
  "keywords": [
@@ -25,22 +25,23 @@
25
25
  "author": "",
26
26
  "license": "MIT",
27
27
  "dependencies": {
28
+ "@tanstack/react-table": "^8.21.2",
28
29
  "react": "^19.0.0",
29
30
  "react-dom": "^19.0.0",
30
- "@tanstack/react-table": "^8.21.2",
31
31
  "@pipe0/client-sdk": "0.0.51"
32
32
  },
33
33
  "devDependencies": {
34
- "@types/react": "^19.0.8",
35
34
  "@types/node": "^22.13.2",
36
- "eslint": "^9.30.0",
35
+ "@types/react": "^19.0.8",
37
36
  "@types/react-dom": "^19.0.3",
37
+ "eslint": "^9.30.0",
38
+ "rimraf": "^6.0.1",
38
39
  "@pipe0/eslint-config": "0.0.0"
39
40
  },
40
41
  "scripts": {
41
42
  "lint": "eslint . --max-warnings 0",
42
43
  "check-types": "tsc --noEmit",
43
- "dev": " tsc --watch",
44
- "build": "rm -rf ./dist && tsc"
44
+ "dev": "tsc --watch",
45
+ "build": "rimraf dist && tsc"
45
46
  }
46
47
  }
@@ -1,37 +0,0 @@
1
- import { type PipeCategory, type PipeId } from "@pipe0/client-sdk";
2
- import { type ColumnFilter } from "@tanstack/react-table";
3
- export declare function useDebounce(cb: (v: string) => unknown, config?: {
4
- initialValue?: string;
5
- timeout?: number;
6
- }): readonly [string, import("react").Dispatch<import("react").SetStateAction<string>>, (v: string) => void];
7
- export type InputFieldEntries = Record<string, PipeId[]>;
8
- export type OutputFieldEntries = Record<string, PipeId[]>;
9
- export declare function usePipeCatalogTable(config?: {
10
- initialColumnFilters?: ColumnFilter[];
11
- }): {
12
- table: import("@tanstack/react-table").Table<PipeCatalogTableData>;
13
- sidebar: {
14
- sortedInputFieldEntries: any;
15
- sortedOutputFieldEntries: any;
16
- sortedTagEntries: any;
17
- sortedProviderEntries: any;
18
- pipeIdsByInputField: any;
19
- pipeIdsByOutputField: any;
20
- pipeIdsByProvider: any;
21
- pipeIdsByTag: any;
22
- expandedSidebarSections: string[];
23
- setExpandedSidebarSections: import("react").Dispatch<import("react").SetStateAction<string[]>>;
24
- removeColumnFilter: (id: "inputFields" | "outputFields" | "tags" | "providers") => void;
25
- addColumnFilter: (id: "inputFields" | "outputFields" | "tags" | "providers", value: string) => void;
26
- };
27
- pipeEntriesByBasePipe: any;
28
- filterByField: (id: "inputFields" | "outputFields", fieldName: string) => void;
29
- globalFilterInput: string;
30
- setGlobalFilterInput: import("react").Dispatch<import("react").SetStateAction<string>>;
31
- isFilterChecked: (id: "inputFields" | "outputFields" | "tags" | "providers", value: string) => boolean;
32
- resetColumnFilters: () => void;
33
- category: any;
34
- setCategory: (category: PipeCategory | null) => void;
35
- showFeaturedPipes: boolean;
36
- };
37
- //# sourceMappingURL=usePipeCatalogTable.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"usePipeCatalogTable.d.ts","sourceRoot":"","sources":["../../src/hooks/usePipeCatalogTable.ts"],"names":[],"mappings":"AAAA,OAAO,EAIL,KAAK,YAAY,EACjB,KAAK,MAAM,EACZ,MAAM,mBAAmB,CAAC;AAC3B,OAAO,EACL,KAAK,YAAY,EAMlB,MAAM,uBAAuB,CAAC;AAG/B,wBAAgB,WAAW,CACzB,EAAE,EAAE,CAAC,CAAC,EAAE,MAAM,KAAK,OAAO,EAC1B,MAAM,GAAE;IAAE,YAAY,CAAC,EAAE,MAAM,CAAC;IAAC,OAAO,CAAC,EAAE,MAAM,CAAA;CAAO,2FAQjB,MAAM,WAc9C;AAED,MAAM,MAAM,iBAAiB,GAAG,MAAM,CAAC,MAAM,EAAE,MAAM,EAAE,CAAC,CAAC;AACzD,MAAM,MAAM,kBAAkB,GAAG,MAAM,CAAC,MAAM,EAAE,MAAM,EAAE,CAAC,CAAC;AA0B1D,wBAAgB,mBAAmB,CACjC,MAAM,GAAE;IACN,oBAAoB,CAAC,EAAE,YAAY,EAAE,CAAC;CAClC;;;;;;;;;;;;;iCAkFA,aAAa,GAAG,cAAc,GAAG,MAAM,GAAG,WAAW;8BAhBrD,aAAa,GAAG,cAAc,GAAG,MAAM,GAAG,WAAW,SAClD,MAAM;;;wBA4BT,aAAa,GAAG,cAAc,aACvB,MAAM;;;0BARb,aAAa,GAAG,cAAc,GAAG,MAAM,GAAG,WAAW,SAClD,MAAM;;;4BA1CgB,YAAY,GAAG,IAAI;;EA0FnD"}