@arcadeai/design-system 3.27.0 → 3.27.1
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/README.md +2 -2
- package/dist/calendar-w1IATMME.js +3042 -0
- package/dist/components/index.js +442 -435
- package/dist/components/ui/atoms/calendar.d.ts +21 -0
- package/dist/components/ui/atoms/calendar.d.ts.map +1 -0
- package/dist/components/ui/atoms/calendar.js +10 -0
- package/dist/components/ui/atoms/index.d.ts +2 -0
- package/dist/components/ui/atoms/index.d.ts.map +1 -1
- package/dist/components/ui/atoms/index.js +427 -422
- package/dist/components/ui/atoms/virtualized-grid.d.ts +23 -0
- package/dist/components/ui/atoms/virtualized-grid.d.ts.map +1 -0
- package/dist/components/ui/atoms/virtualized-grid.js +682 -0
- package/dist/components/ui/index.js +442 -435
- package/dist/components/ui/molecules/date-time-picker.d.ts +12 -0
- package/dist/components/ui/molecules/date-time-picker.d.ts.map +1 -0
- package/dist/components/ui/molecules/date-time-picker.js +84 -0
- package/dist/components/ui/molecules/index.d.ts +1 -0
- package/dist/components/ui/molecules/index.d.ts.map +1 -1
- package/dist/components/ui/molecules/index.js +13 -11
- package/dist/components/ui/molecules/requirement-badges.js +6 -5
- package/dist/components/ui/molecules/toolkit-card.d.ts.map +1 -1
- package/dist/components/ui/molecules/toolkit-card.js +1 -1
- package/dist/components/ui/molecules/toolkit-selection-summary.js +5 -4
- package/dist/components/ui/organisms/toolkit-picker/components/search-input.js +15 -14
- package/dist/components/ui/organisms/toolkit-picker/components/select-button.d.ts.map +1 -1
- package/dist/components/ui/organisms/toolkit-picker/components/select-button.js +10 -9
- package/dist/components/ui/organisms/toolkit-picker/components/toolkit-card-with-selection.js +1 -1
- package/dist/components/ui/organisms/toolkit-picker/components/toolkit-list.d.ts +3 -1
- package/dist/components/ui/organisms/toolkit-picker/components/toolkit-list.d.ts.map +1 -1
- package/dist/components/ui/organisms/toolkit-picker/components/toolkit-list.js +109 -57
- package/dist/components/ui/organisms/toolkit-picker/components/tools-list.d.ts +3 -1
- package/dist/components/ui/organisms/toolkit-picker/components/tools-list.d.ts.map +1 -1
- package/dist/components/ui/organisms/toolkit-picker/components/tools-list.js +74 -69
- package/dist/components/ui/organisms/toolkit-picker/hooks/featured-toolkits.d.ts +8 -0
- package/dist/components/ui/organisms/toolkit-picker/hooks/featured-toolkits.d.ts.map +1 -0
- package/dist/components/ui/organisms/toolkit-picker/hooks/featured-toolkits.js +11 -0
- package/dist/components/ui/organisms/toolkit-picker/hooks/use-toolkit-picker.d.ts +6 -4
- package/dist/components/ui/organisms/toolkit-picker/hooks/use-toolkit-picker.d.ts.map +1 -1
- package/dist/components/ui/organisms/toolkit-picker/hooks/use-toolkit-picker.js +195 -261
- package/dist/components/ui/organisms/toolkit-picker/mocks/toolkit-collection.d.ts +5 -1
- package/dist/components/ui/organisms/toolkit-picker/mocks/toolkit-collection.d.ts.map +1 -1
- package/dist/components/ui/organisms/toolkit-picker/mocks/toolkit-collection.js +154 -80
- package/dist/components/ui/organisms/toolkit-picker/toolkit-picker.d.ts.map +1 -1
- package/dist/components/ui/organisms/toolkit-picker/toolkit-picker.js +89 -75
- package/dist/hooks/use-columns.d.ts +6 -0
- package/dist/hooks/use-columns.d.ts.map +1 -0
- package/dist/hooks/use-columns.js +20 -0
- package/dist/main.js +476 -469
- package/dist/{toolkit-card-CsV6xoOG.js → toolkit-card-Qou74oWg.js} +4 -2
- package/package.json +7 -2
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { Calendar } from '../atoms/calendar';
|
|
2
|
+
import { ComponentProps } from 'react';
|
|
3
|
+
export type DateTimePickerProps = {
|
|
4
|
+
value?: Date;
|
|
5
|
+
onChange?: (date: Date | undefined) => void;
|
|
6
|
+
className?: string;
|
|
7
|
+
} & Omit<ComponentProps<typeof Calendar>, "selected" | "onSelect" | "mode">;
|
|
8
|
+
export declare function DateTimePicker({ value, onChange, className, ...calendarProps }: DateTimePickerProps): import("react/jsx-runtime").JSX.Element;
|
|
9
|
+
export declare namespace DateTimePicker {
|
|
10
|
+
var displayName: string;
|
|
11
|
+
}
|
|
12
|
+
//# sourceMappingURL=date-time-picker.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"date-time-picker.d.ts","sourceRoot":"","sources":["../../../../lib/components/ui/molecules/date-time-picker.tsx"],"names":[],"mappings":"AACA,OAAO,EAAE,QAAQ,EAAE,MAAM,kCAAkC,CAAC;AAU5D,OAAO,EAAE,KAAK,cAAc,EAAY,MAAM,OAAO,CAAC;AAEtD,MAAM,MAAM,mBAAmB,GAAG;IAChC,KAAK,CAAC,EAAE,IAAI,CAAC;IACb,QAAQ,CAAC,EAAE,CAAC,IAAI,EAAE,IAAI,GAAG,SAAS,KAAK,IAAI,CAAC;IAC5C,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB,GAAG,IAAI,CAAC,cAAc,CAAC,OAAO,QAAQ,CAAC,EAAE,UAAU,GAAG,UAAU,GAAG,MAAM,CAAC,CAAC;AAE5E,wBAAgB,cAAc,CAAC,EAC7B,KAAK,EACL,QAAQ,EACR,SAAS,EACT,GAAG,aAAa,EACjB,EAAE,mBAAmB,2CAgErB;yBArEe,cAAc"}
|
|
@@ -0,0 +1,84 @@
|
|
|
1
|
+
import { jsx as r, jsxs as t } from "react/jsx-runtime";
|
|
2
|
+
import { Button as g } from "../atoms/button.js";
|
|
3
|
+
import { f as k, C as w } from "../../../calendar-w1IATMME.js";
|
|
4
|
+
import { Input as x } from "../atoms/input.js";
|
|
5
|
+
import { Label as s } from "../atoms/label.js";
|
|
6
|
+
import { Popover as N, PopoverTrigger as b, PopoverContent as D } from "../atoms/popover.js";
|
|
7
|
+
import { ChevronDownIcon as v } from "lucide-react";
|
|
8
|
+
import { useState as C } from "react";
|
|
9
|
+
function P({
|
|
10
|
+
value: e,
|
|
11
|
+
onChange: a,
|
|
12
|
+
className: m,
|
|
13
|
+
...l
|
|
14
|
+
}) {
|
|
15
|
+
const [p, i] = C(!1), d = e ? k(e, "HH:mm:ss") : "";
|
|
16
|
+
return /* @__PURE__ */ r("div", { className: m, children: /* @__PURE__ */ t("div", { className: "flex gap-4", children: [
|
|
17
|
+
/* @__PURE__ */ t("div", { className: "flex flex-col gap-3", children: [
|
|
18
|
+
/* @__PURE__ */ t(s, { className: "px-1", htmlFor: "date-picker", children: [
|
|
19
|
+
"Date:",
|
|
20
|
+
" "
|
|
21
|
+
] }),
|
|
22
|
+
/* @__PURE__ */ t(N, { onOpenChange: i, open: p, children: [
|
|
23
|
+
/* @__PURE__ */ r(b, { asChild: !0, children: /* @__PURE__ */ t(
|
|
24
|
+
g,
|
|
25
|
+
{
|
|
26
|
+
className: "w-32 justify-between font-normal",
|
|
27
|
+
id: "date-picker",
|
|
28
|
+
variant: "outline",
|
|
29
|
+
children: [
|
|
30
|
+
e ? e.toLocaleDateString() : "Select date",
|
|
31
|
+
/* @__PURE__ */ r(v, {})
|
|
32
|
+
]
|
|
33
|
+
}
|
|
34
|
+
) }),
|
|
35
|
+
/* @__PURE__ */ r(
|
|
36
|
+
D,
|
|
37
|
+
{
|
|
38
|
+
align: "start",
|
|
39
|
+
className: "w-auto overflow-hidden p-0",
|
|
40
|
+
children: /* @__PURE__ */ r(
|
|
41
|
+
w,
|
|
42
|
+
{
|
|
43
|
+
captionLayout: "dropdown",
|
|
44
|
+
mode: "single",
|
|
45
|
+
onSelect: (o) => {
|
|
46
|
+
a?.(o), i(!1);
|
|
47
|
+
},
|
|
48
|
+
selected: e,
|
|
49
|
+
...l
|
|
50
|
+
}
|
|
51
|
+
)
|
|
52
|
+
}
|
|
53
|
+
)
|
|
54
|
+
] })
|
|
55
|
+
] }),
|
|
56
|
+
/* @__PURE__ */ t("div", { className: "flex flex-col gap-3", children: [
|
|
57
|
+
/* @__PURE__ */ t(s, { className: "px-1", htmlFor: "time-picker", children: [
|
|
58
|
+
"Time:",
|
|
59
|
+
" "
|
|
60
|
+
] }),
|
|
61
|
+
/* @__PURE__ */ r(
|
|
62
|
+
x,
|
|
63
|
+
{
|
|
64
|
+
className: "appearance-none bg-background [&::-webkit-calendar-picker-indicator]:hidden [&::-webkit-calendar-picker-indicator]:appearance-none",
|
|
65
|
+
id: "time-picker",
|
|
66
|
+
onChange: (o) => {
|
|
67
|
+
const n = o.target.value;
|
|
68
|
+
if (!(n && e))
|
|
69
|
+
return;
|
|
70
|
+
const [f, h, u] = n.split(":").map(Number), c = new Date(e);
|
|
71
|
+
c.setHours(f, h, u || 0), a?.(c);
|
|
72
|
+
},
|
|
73
|
+
step: "1",
|
|
74
|
+
type: "time",
|
|
75
|
+
value: d
|
|
76
|
+
}
|
|
77
|
+
)
|
|
78
|
+
] })
|
|
79
|
+
] }) });
|
|
80
|
+
}
|
|
81
|
+
P.displayName = "DateTimePicker";
|
|
82
|
+
export {
|
|
83
|
+
P as DateTimePicker
|
|
84
|
+
};
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
/** biome-ignore-all lint/performance/noBarrelFile: Barrel files are acceptable for atomic component folders */
|
|
2
|
+
export { DateTimePicker } from './date-time-picker';
|
|
2
3
|
export { EmptyState } from './empty-state';
|
|
3
4
|
export { RequirementBadges } from './requirement-badges';
|
|
4
5
|
export { ToolCard } from './tool-card';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../lib/components/ui/molecules/index.ts"],"names":[],"mappings":"AAAA,+GAA+G;AAE/G,OAAO,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAC3C,OAAO,EAAE,iBAAiB,EAAE,MAAM,sBAAsB,CAAC;AACzD,OAAO,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AACvC,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAC7C,OAAO,EAAE,oBAAoB,EAAE,MAAM,0BAA0B,CAAC;AAChE,OAAO,EAAE,uBAAuB,EAAE,MAAM,6BAA6B,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../lib/components/ui/molecules/index.ts"],"names":[],"mappings":"AAAA,+GAA+G;AAE/G,OAAO,EAAE,cAAc,EAAE,MAAM,oBAAoB,CAAC;AACpD,OAAO,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAC3C,OAAO,EAAE,iBAAiB,EAAE,MAAM,sBAAsB,CAAC;AACzD,OAAO,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AACvC,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAC7C,OAAO,EAAE,oBAAoB,EAAE,MAAM,0BAA0B,CAAC;AAChE,OAAO,EAAE,uBAAuB,EAAE,MAAM,6BAA6B,CAAC"}
|
|
@@ -1,13 +1,15 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
1
|
+
import { DateTimePicker as e } from "./date-time-picker.js";
|
|
2
|
+
import { EmptyState as m } from "./empty-state.js";
|
|
3
|
+
import { R as a, T as p } from "../../../toolkit-card-Qou74oWg.js";
|
|
4
|
+
import { ToolCard as f } from "./tool-card.js";
|
|
5
|
+
import { ToolkitPickerTrigger as k } from "./toolkit-picker-trigger.js";
|
|
6
|
+
import { ToolkitSelectionSummary as c } from "./toolkit-selection-summary.js";
|
|
6
7
|
export {
|
|
7
|
-
e as
|
|
8
|
-
m as
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
8
|
+
e as DateTimePicker,
|
|
9
|
+
m as EmptyState,
|
|
10
|
+
a as RequirementBadges,
|
|
11
|
+
f as ToolCard,
|
|
12
|
+
p as ToolkitCard,
|
|
13
|
+
k as ToolkitPickerTrigger,
|
|
14
|
+
c as ToolkitSelectionSummary
|
|
13
15
|
};
|
|
@@ -3,21 +3,22 @@ import "../../../utils-6KgZuQUR.js";
|
|
|
3
3
|
import "lucide-react";
|
|
4
4
|
import "../atoms/badge.js";
|
|
5
5
|
import "../atoms/byoc-badge.js";
|
|
6
|
+
import "react";
|
|
6
7
|
import "../atoms/chart.js";
|
|
7
8
|
import "../atoms/mobile-tooltip.js";
|
|
8
9
|
import "../atoms/pro-badge.js";
|
|
9
10
|
import "../../../react-resizable-panels.browser-31wAXhAV.js";
|
|
10
11
|
import "../atoms/sidebar.js";
|
|
11
|
-
import "react";
|
|
12
12
|
import "../atoms/tooltip.js";
|
|
13
|
-
import
|
|
13
|
+
import "./date-time-picker.js";
|
|
14
|
+
import { O as q, R as x, S as A } from "../../../toolkit-card-Qou74oWg.js";
|
|
14
15
|
import "./tool-card.js";
|
|
15
16
|
import "../../../metadata/oauth-providers.js";
|
|
16
17
|
import "../../../metadata/toolkits.js";
|
|
17
18
|
import "../organisms/toolkit-picker/hooks/use-toolkit-picker.js";
|
|
18
19
|
import "../utils/memo.js";
|
|
19
20
|
export {
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
21
|
+
q as OAuthBadge,
|
|
22
|
+
x as RequirementBadges,
|
|
23
|
+
A as SecretsBadge
|
|
23
24
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"toolkit-card.d.ts","sourceRoot":"","sources":["../../../../lib/components/ui/molecules/toolkit-card.tsx"],"names":[],"mappings":"AAKA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,uBAAuB,CAAC;AAI9D,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAC/B,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AAG7C,MAAM,MAAM,gBAAgB,GAAG;IAC7B,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,UAAU,EAAE,MAAM,CAAC;IACnB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,mBAAmB,CAAC,EAAE,OAAO,CAAC;IAC9B,kBAAkB,CAAC,EAAE,MAAM,CAAC;IAC5B,IAAI,CAAC,EAAE,CAAC,KAAK,EAAE;QAAE,SAAS,CAAC,EAAE,MAAM,CAAA;KAAE,KAAK,GAAG,CAAC,OAAO,CAAC;IACtD,mBAAmB,EAAE,gBAAgB,CAAC,qBAAqB,CAAC,CAAC;IAC7D,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB,QAAQ,CAAC,EAAE,CAAC,OAAO,EAAE,OAAO,KAAK,IAAI,CAAC;IACtC,MAAM,CAAC,EAAE,MAAM,IAAI,CAAC;IACpB,YAAY,CAAC,EAAE,OAAO,CAAC;CACxB,GAAG,IAAI,CAAC,KAAK,CAAC,cAAc,CAAC,cAAc,CAAC,EAAE,UAAU,CAAC,CAAC;AAgD3D,iBAAS,eAAe,CAAC,EACvB,IAAI,EACJ,OAAO,EACP,UAAU,EACV,IAAgC,EAChC,UAAkB,EAClB,mBAA2B,EAC3B,kBAAsB,EACtB,mBAAmB,EACnB,QAAQ,EACR,MAAM,EACN,YAAoB,EACpB,MAAM,EACN,KAAK,EACL,GAAG,IAAI,EACR,EAAE,gBAAgB,
|
|
1
|
+
{"version":3,"file":"toolkit-card.d.ts","sourceRoot":"","sources":["../../../../lib/components/ui/molecules/toolkit-card.tsx"],"names":[],"mappings":"AAKA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,uBAAuB,CAAC;AAI9D,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAC/B,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AAG7C,MAAM,MAAM,gBAAgB,GAAG;IAC7B,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,UAAU,EAAE,MAAM,CAAC;IACnB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,mBAAmB,CAAC,EAAE,OAAO,CAAC;IAC9B,kBAAkB,CAAC,EAAE,MAAM,CAAC;IAC5B,IAAI,CAAC,EAAE,CAAC,KAAK,EAAE;QAAE,SAAS,CAAC,EAAE,MAAM,CAAA;KAAE,KAAK,GAAG,CAAC,OAAO,CAAC;IACtD,mBAAmB,EAAE,gBAAgB,CAAC,qBAAqB,CAAC,CAAC;IAC7D,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB,QAAQ,CAAC,EAAE,CAAC,OAAO,EAAE,OAAO,KAAK,IAAI,CAAC;IACtC,MAAM,CAAC,EAAE,MAAM,IAAI,CAAC;IACpB,YAAY,CAAC,EAAE,OAAO,CAAC;CACxB,GAAG,IAAI,CAAC,KAAK,CAAC,cAAc,CAAC,cAAc,CAAC,EAAE,UAAU,CAAC,CAAC;AAgD3D,iBAAS,eAAe,CAAC,EACvB,IAAI,EACJ,OAAO,EACP,UAAU,EACV,IAAgC,EAChC,UAAkB,EAClB,mBAA2B,EAC3B,kBAAsB,EACtB,mBAAmB,EACnB,QAAQ,EACR,MAAM,EACN,YAAoB,EACpB,MAAM,EACN,KAAK,EACL,GAAG,IAAI,EACR,EAAE,gBAAgB,eAkJlB;AAmBD,eAAO,MAAM,WAAW,mDAGvB,CAAC"}
|
|
@@ -6,7 +6,7 @@ import "../../../utils-6KgZuQUR.js";
|
|
|
6
6
|
import "../../../index-r7CUvu2m.js";
|
|
7
7
|
import "lucide-react";
|
|
8
8
|
import "react";
|
|
9
|
-
import { T as k } from "../../../toolkit-card-
|
|
9
|
+
import { T as k } from "../../../toolkit-card-Qou74oWg.js";
|
|
10
10
|
import "../utils/memo.js";
|
|
11
11
|
export {
|
|
12
12
|
k as ToolkitCard
|
|
@@ -2,16 +2,17 @@ import { jsxs as t, jsx as e } from "react/jsx-runtime";
|
|
|
2
2
|
import { Package as u, X as y, CheckSquare as C } from "lucide-react";
|
|
3
3
|
import { Button as x } from "../atoms/button.js";
|
|
4
4
|
import { MobileTooltip as p, MobileTooltipTrigger as g, MobileTooltipContent as f } from "../atoms/mobile-tooltip.js";
|
|
5
|
+
import "react";
|
|
5
6
|
import "../atoms/chart.js";
|
|
6
7
|
import "../../../react-resizable-panels.browser-31wAXhAV.js";
|
|
7
8
|
import "../atoms/sidebar.js";
|
|
8
|
-
import "
|
|
9
|
-
import "../../../toolkit-card-
|
|
9
|
+
import "./date-time-picker.js";
|
|
10
|
+
import "../../../toolkit-card-Qou74oWg.js";
|
|
10
11
|
import "./tool-card.js";
|
|
11
12
|
import { getToolkitIcon as z } from "../../../metadata/toolkit-icons.js";
|
|
12
13
|
import "../organisms/toolkit-picker/hooks/use-toolkit-picker.js";
|
|
13
14
|
const j = 3;
|
|
14
|
-
function
|
|
15
|
+
function D({
|
|
15
16
|
selectedToolkits: s,
|
|
16
17
|
selectedTools: n,
|
|
17
18
|
onClear: N,
|
|
@@ -111,5 +112,5 @@ function _({
|
|
|
111
112
|
);
|
|
112
113
|
}
|
|
113
114
|
export {
|
|
114
|
-
|
|
115
|
+
D as ToolkitSelectionSummary
|
|
115
116
|
};
|
|
@@ -1,18 +1,19 @@
|
|
|
1
1
|
import { jsxs as d, jsx as e } from "react/jsx-runtime";
|
|
2
2
|
import { Search as y } from "lucide-react";
|
|
3
3
|
import "../../../atoms/mobile-tooltip.js";
|
|
4
|
+
import { useRef as T } from "react";
|
|
4
5
|
import "../../../atoms/chart.js";
|
|
5
|
-
import { Input as
|
|
6
|
+
import { Input as k } from "../../../atoms/input.js";
|
|
6
7
|
import "../../../../../react-resizable-panels.browser-31wAXhAV.js";
|
|
7
8
|
import "../../../atoms/sidebar.js";
|
|
8
|
-
import
|
|
9
|
-
import "../../../../../toolkit-card-
|
|
9
|
+
import "../../../molecules/date-time-picker.js";
|
|
10
|
+
import "../../../../../toolkit-card-Qou74oWg.js";
|
|
10
11
|
import "../../../molecules/tool-card.js";
|
|
11
12
|
import "../../../../../metadata/oauth-providers.js";
|
|
12
13
|
import "../../../../../metadata/toolkits.js";
|
|
13
14
|
import { useToolkitPicker as g } from "../hooks/use-toolkit-picker.js";
|
|
14
|
-
function
|
|
15
|
-
const r =
|
|
15
|
+
function C() {
|
|
16
|
+
const r = T(null), {
|
|
16
17
|
state: {
|
|
17
18
|
searchQuery: o,
|
|
18
19
|
activeTab: i,
|
|
@@ -22,26 +23,26 @@ function z() {
|
|
|
22
23
|
},
|
|
23
24
|
setSearchQuery: n,
|
|
24
25
|
toggleToolkit: c,
|
|
25
|
-
toggleTool:
|
|
26
|
-
setActiveTab:
|
|
27
|
-
setToolkitFilter:
|
|
28
|
-
} = g(),
|
|
26
|
+
toggleTool: m,
|
|
27
|
+
setActiveTab: u,
|
|
28
|
+
setToolkitFilter: p
|
|
29
|
+
} = g(), f = () => {
|
|
29
30
|
const t = Array.from(s)[0];
|
|
30
31
|
if (t) {
|
|
31
32
|
if (a === "single") {
|
|
32
|
-
|
|
33
|
+
p(t.name), u("tools");
|
|
33
34
|
return;
|
|
34
35
|
}
|
|
35
36
|
c(t);
|
|
36
37
|
}
|
|
37
38
|
}, h = () => {
|
|
38
39
|
const t = Array.from(l)[0];
|
|
39
|
-
t &&
|
|
40
|
+
t && m(t);
|
|
40
41
|
};
|
|
41
42
|
return /* @__PURE__ */ d("div", { className: "relative flex-1", children: [
|
|
42
43
|
/* @__PURE__ */ e(y, { className: "absolute top-1/2 left-3.5 size-4 -translate-y-1/2 text-gray-400" }),
|
|
43
44
|
/* @__PURE__ */ e(
|
|
44
|
-
|
|
45
|
+
k,
|
|
45
46
|
{
|
|
46
47
|
"aria-label": "Search toolkits and tools",
|
|
47
48
|
autoFocus: !0,
|
|
@@ -51,7 +52,7 @@ function z() {
|
|
|
51
52
|
onKeyDown: (t) => {
|
|
52
53
|
if (!(t.key !== "Enter" || !(o.trim().length > 0))) {
|
|
53
54
|
if (t.preventDefault(), t.stopPropagation(), i === "toolkits") {
|
|
54
|
-
|
|
55
|
+
f();
|
|
55
56
|
return;
|
|
56
57
|
}
|
|
57
58
|
h();
|
|
@@ -65,5 +66,5 @@ function z() {
|
|
|
65
66
|
] });
|
|
66
67
|
}
|
|
67
68
|
export {
|
|
68
|
-
|
|
69
|
+
C as SearchInput
|
|
69
70
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"select-button.d.ts","sourceRoot":"","sources":["../../../../../../lib/components/ui/organisms/toolkit-picker/components/select-button.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AAE9C,KAAK,iBAAiB,GAAG;IACvB,aAAa,EAAE,aAAa,CAAC;IAC7B,aAAa,EAAE,MAAM,CAAC;IACtB,QAAQ,EAAE,MAAM,IAAI,CAAC;IACrB,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB,CAAC;AAEF,wBAAgB,YAAY,CAAC,EAC3B,aAAa,EACb,aAAa,EACb,QAAQ,EACR,SAAS,GACV,EAAE,iBAAiB,
|
|
1
|
+
{"version":3,"file":"select-button.d.ts","sourceRoot":"","sources":["../../../../../../lib/components/ui/organisms/toolkit-picker/components/select-button.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AAE9C,KAAK,iBAAiB,GAAG;IACvB,aAAa,EAAE,aAAa,CAAC;IAC7B,aAAa,EAAE,MAAM,CAAC;IACtB,QAAQ,EAAE,MAAM,IAAI,CAAC;IACrB,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB,CAAC;AAEF,wBAAgB,YAAY,CAAC,EAC3B,aAAa,EACb,aAAa,EACb,QAAQ,EACR,SAAS,GACV,EAAE,iBAAiB,2CA2BnB"}
|
|
@@ -2,33 +2,34 @@ import { jsx as m } from "react/jsx-runtime";
|
|
|
2
2
|
import "lucide-react";
|
|
3
3
|
import { Button as n } from "../../../atoms/button.js";
|
|
4
4
|
import "../../../atoms/mobile-tooltip.js";
|
|
5
|
+
import "react";
|
|
5
6
|
import "../../../atoms/chart.js";
|
|
6
7
|
import "../../../../../react-resizable-panels.browser-31wAXhAV.js";
|
|
7
8
|
import "../../../atoms/sidebar.js";
|
|
8
|
-
import "
|
|
9
|
-
import "../../../../../toolkit-card-
|
|
9
|
+
import "../../../molecules/date-time-picker.js";
|
|
10
|
+
import "../../../../../toolkit-card-Qou74oWg.js";
|
|
10
11
|
import "../../../molecules/tool-card.js";
|
|
11
12
|
import "../../../../../metadata/oauth-providers.js";
|
|
12
13
|
import "../../../../../metadata/toolkits.js";
|
|
13
14
|
import "../hooks/use-toolkit-picker.js";
|
|
14
|
-
function
|
|
15
|
+
function $({
|
|
15
16
|
selectionMode: t,
|
|
16
17
|
selectedCount: o,
|
|
17
|
-
onCommit:
|
|
18
|
-
className:
|
|
18
|
+
onCommit: i,
|
|
19
|
+
className: r
|
|
19
20
|
}) {
|
|
20
21
|
return /* @__PURE__ */ m(
|
|
21
22
|
n,
|
|
22
23
|
{
|
|
23
|
-
className:
|
|
24
|
+
className: r,
|
|
24
25
|
"data-testid": "use-tools-button",
|
|
25
|
-
disabled: o === 0,
|
|
26
|
-
onClick:
|
|
26
|
+
disabled: t === "single" && o === 0,
|
|
27
|
+
onClick: i,
|
|
27
28
|
size: "sm",
|
|
28
29
|
children: t === "single" ? "Select Tool" : o === 0 ? "Select Tools" : `Use ${o} ${o === 1 ? "Tool" : "Tools"}`
|
|
29
30
|
}
|
|
30
31
|
);
|
|
31
32
|
}
|
|
32
33
|
export {
|
|
33
|
-
|
|
34
|
+
$ as SelectButton
|
|
34
35
|
};
|
package/dist/components/ui/organisms/toolkit-picker/components/toolkit-card-with-selection.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx as m } from "react/jsx-runtime";
|
|
2
|
-
import { T as c } from "../../../../../toolkit-card-
|
|
2
|
+
import { T as c } from "../../../../../toolkit-card-Qou74oWg.js";
|
|
3
3
|
import { getToolkitIcon as d } from "../../../../../metadata/toolkit-icons.js";
|
|
4
4
|
function g({
|
|
5
5
|
toolkit: e,
|
|
@@ -1,7 +1,9 @@
|
|
|
1
|
+
import { RefObject } from 'react';
|
|
1
2
|
import { SelectionMode } from '../index';
|
|
2
3
|
type ToolkitListProps = {
|
|
3
4
|
selectionMode: SelectionMode;
|
|
5
|
+
scrollContainerRef: RefObject<HTMLDivElement | null>;
|
|
4
6
|
};
|
|
5
|
-
export declare function ToolkitList({ selectionMode }: ToolkitListProps): import("react/jsx-runtime").JSX.Element;
|
|
7
|
+
export declare function ToolkitList({ selectionMode, scrollContainerRef, }: ToolkitListProps): import("react/jsx-runtime").JSX.Element;
|
|
6
8
|
export {};
|
|
7
9
|
//# sourceMappingURL=toolkit-list.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"toolkit-list.d.ts","sourceRoot":"","sources":["../../../../../../lib/components/ui/organisms/toolkit-picker/components/toolkit-list.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"toolkit-list.d.ts","sourceRoot":"","sources":["../../../../../../lib/components/ui/organisms/toolkit-picker/components/toolkit-list.tsx"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAIvC,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AAM9C,KAAK,gBAAgB,GAAG;IACtB,aAAa,EAAE,aAAa,CAAC;IAC7B,kBAAkB,EAAE,SAAS,CAAC,cAAc,GAAG,IAAI,CAAC,CAAC;CACtD,CAAC;AAEF,wBAAgB,WAAW,CAAC,EAC1B,aAAa,EACb,kBAAkB,GACnB,EAAE,gBAAgB,2CAqJlB"}
|
|
@@ -1,90 +1,142 @@
|
|
|
1
|
-
import { jsx as t, jsxs as
|
|
2
|
-
import {
|
|
3
|
-
import "
|
|
1
|
+
import { jsx as t, jsxs as s } from "react/jsx-runtime";
|
|
2
|
+
import { VirtualizedGrid as u } from "../../../atoms/virtualized-grid.js";
|
|
3
|
+
import "../../../molecules/date-time-picker.js";
|
|
4
|
+
import { EmptyState as w } from "../../../molecules/empty-state.js";
|
|
5
|
+
import "../../../../../toolkit-card-Qou74oWg.js";
|
|
4
6
|
import "../../../molecules/tool-card.js";
|
|
5
7
|
import "../../../../../metadata/oauth-providers.js";
|
|
6
8
|
import "../../../../../metadata/toolkits.js";
|
|
7
9
|
import "lucide-react";
|
|
8
|
-
import { useToolkitPicker as
|
|
10
|
+
import { useToolkitPicker as S } from "../hooks/use-toolkit-picker.js";
|
|
9
11
|
import "../../../atoms/mobile-tooltip.js";
|
|
12
|
+
import { useMemo as v } from "react";
|
|
10
13
|
import "../../../atoms/chart.js";
|
|
11
14
|
import "../../../../../react-resizable-panels.browser-31wAXhAV.js";
|
|
12
15
|
import "../../../atoms/sidebar.js";
|
|
13
|
-
import "
|
|
14
|
-
import {
|
|
15
|
-
|
|
16
|
+
import { useColumns as C } from "../../../../../hooks/use-columns.js";
|
|
17
|
+
import { FEATURED_TOOLKITS as R } from "../hooks/featured-toolkits.js";
|
|
18
|
+
import { ToolkitCardWithSelection as A } from "./toolkit-card-with-selection.js";
|
|
19
|
+
const x = 156;
|
|
20
|
+
function J({
|
|
21
|
+
selectionMode: f,
|
|
22
|
+
scrollContainerRef: d
|
|
23
|
+
}) {
|
|
16
24
|
const {
|
|
17
|
-
state: { filteredToolkits:
|
|
18
|
-
toggleToolkit:
|
|
19
|
-
setActiveTab:
|
|
20
|
-
setToolkitFilter:
|
|
21
|
-
} =
|
|
22
|
-
|
|
25
|
+
state: { filteredToolkits: m, selectedToolkits: l, selectedTools: T, searchQuery: o },
|
|
26
|
+
toggleToolkit: y,
|
|
27
|
+
setActiveTab: h,
|
|
28
|
+
setToolkitFilter: k
|
|
29
|
+
} = S(), n = C(), { selectedToolkitItems: a, featuredToolkitItems: i, unselectedToolkitItems: c } = v(() => {
|
|
30
|
+
const e = Array.from(m), g = new Set(
|
|
31
|
+
R.map((r) => r.toLowerCase())
|
|
32
|
+
), N = e.filter(
|
|
33
|
+
(r) => l.has(r.name)
|
|
34
|
+
), I = e.filter(
|
|
35
|
+
(r) => !(l.has(r.name) || o.trim()) && g.has(r.name.toLowerCase())
|
|
36
|
+
), b = e.filter(
|
|
37
|
+
(r) => !l.has(r.name) && (o.trim() || !g.has(r.name.toLowerCase()))
|
|
38
|
+
);
|
|
39
|
+
return {
|
|
40
|
+
selectedToolkitItems: N,
|
|
41
|
+
featuredToolkitItems: I,
|
|
42
|
+
unselectedToolkitItems: b
|
|
43
|
+
};
|
|
44
|
+
}, [m, o, l]);
|
|
45
|
+
if (m.size === 0)
|
|
23
46
|
return /* @__PURE__ */ t(
|
|
24
|
-
|
|
47
|
+
w,
|
|
25
48
|
{
|
|
26
49
|
"data-testid": "empty-toolkits",
|
|
27
50
|
description: "Try a different search term",
|
|
28
51
|
title: "No toolkits found"
|
|
29
52
|
}
|
|
30
53
|
);
|
|
31
|
-
const
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
54
|
+
const p = (e) => /* @__PURE__ */ t(
|
|
55
|
+
A,
|
|
56
|
+
{
|
|
57
|
+
onSelect: (g) => {
|
|
58
|
+
if (f === "single") {
|
|
59
|
+
h("tools"), k(e.name);
|
|
60
|
+
return;
|
|
61
|
+
}
|
|
62
|
+
y(e);
|
|
63
|
+
},
|
|
64
|
+
onView: () => {
|
|
65
|
+
k(e.name), h("tools");
|
|
66
|
+
},
|
|
67
|
+
selectedTools: new Set(T.keys()),
|
|
68
|
+
selectionMode: f,
|
|
69
|
+
toolkit: e
|
|
70
|
+
},
|
|
71
|
+
e.name
|
|
72
|
+
);
|
|
73
|
+
return /* @__PURE__ */ s("div", { className: "space-y-4", "data-testid": "toolkits-grid", children: [
|
|
74
|
+
a.length > 0 && /* @__PURE__ */ s("div", { className: "space-y-3", "data-testid": "selected-toolkits-section", children: [
|
|
75
|
+
/* @__PURE__ */ s("div", { className: "flex items-center gap-1.5", children: [
|
|
76
|
+
/* @__PURE__ */ t("h3", { className: "font-semibold text-neutral-700 text-sm dark:text-neutral-200", children: "Selected" }),
|
|
77
|
+
/* @__PURE__ */ t("span", { className: "rounded-full bg-emerald-300 px-1.5 py-0.5 text-emerald-900 text-xs dark:bg-emerald-500/25 dark:text-emerald-200", children: a.length })
|
|
78
|
+
] }),
|
|
79
|
+
/* @__PURE__ */ t(
|
|
80
|
+
u,
|
|
81
|
+
{
|
|
82
|
+
columns: n,
|
|
83
|
+
estimateRowSize: x,
|
|
84
|
+
getItemKey: (e) => e.name,
|
|
85
|
+
gridClassName: "grid grid-cols-1 gap-3 sm:grid-cols-2 xl:grid-cols-3",
|
|
86
|
+
items: a,
|
|
87
|
+
parentRef: d,
|
|
88
|
+
renderItem: p,
|
|
89
|
+
rowGapPx: 12
|
|
90
|
+
}
|
|
91
|
+
)
|
|
92
|
+
] }),
|
|
93
|
+
!o.trim() && i.length > 0 && /* @__PURE__ */ s(
|
|
46
94
|
"div",
|
|
47
95
|
{
|
|
48
|
-
className: "
|
|
49
|
-
"data-testid": "
|
|
96
|
+
className: "space-y-3 rounded-lg bg-neutral-50 p-4 dark:bg-neutral-900",
|
|
97
|
+
"data-testid": "featured-toolkits-section",
|
|
50
98
|
children: [
|
|
51
|
-
/* @__PURE__ */
|
|
52
|
-
/* @__PURE__ */ t("h3", { className: "font-semibold text-neutral-700 text-sm dark:text-neutral-200", children: "
|
|
53
|
-
/* @__PURE__ */ t("span", { className: "rounded-full bg-
|
|
99
|
+
/* @__PURE__ */ s("div", { className: "flex items-center gap-1.5", children: [
|
|
100
|
+
/* @__PURE__ */ t("h3", { className: "font-semibold text-neutral-700 text-sm dark:text-neutral-200", children: "Featured Toolkits" }),
|
|
101
|
+
/* @__PURE__ */ t("span", { className: "rounded-full bg-neutral-200 px-1.5 py-0.5 text-neutral-800 text-xs dark:bg-neutral-800 dark:text-neutral-200", children: i.length })
|
|
54
102
|
] }),
|
|
55
|
-
/* @__PURE__ */ t(
|
|
56
|
-
|
|
103
|
+
/* @__PURE__ */ t(
|
|
104
|
+
u,
|
|
57
105
|
{
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
106
|
+
columns: n,
|
|
107
|
+
estimateRowSize: x,
|
|
108
|
+
getItemKey: (e) => e.name,
|
|
109
|
+
gridClassName: "grid grid-cols-1 gap-3 sm:grid-cols-2 xl:grid-cols-3",
|
|
110
|
+
items: i,
|
|
111
|
+
parentRef: d,
|
|
112
|
+
renderItem: p,
|
|
113
|
+
rowGapPx: 12
|
|
114
|
+
}
|
|
115
|
+
)
|
|
66
116
|
]
|
|
67
117
|
}
|
|
68
118
|
),
|
|
69
|
-
/* @__PURE__ */
|
|
70
|
-
|
|
119
|
+
c.length > 0 && /* @__PURE__ */ s("div", { className: "space-y-3", children: [
|
|
120
|
+
(a.length > 0 || i.length > 0) && /* @__PURE__ */ s("div", { className: "flex items-center gap-1.5", children: [
|
|
71
121
|
/* @__PURE__ */ t("h3", { className: "font-semibold text-neutral-700 text-sm dark:text-neutral-200", children: "All toolkits" }),
|
|
72
122
|
/* @__PURE__ */ t("span", { className: "rounded-full bg-neutral-200 px-1.5 py-0.5 text-neutral-800 text-xs dark:bg-neutral-800 dark:text-neutral-200", children: c.length })
|
|
73
123
|
] }),
|
|
74
|
-
/* @__PURE__ */ t(
|
|
75
|
-
|
|
124
|
+
/* @__PURE__ */ t(
|
|
125
|
+
u,
|
|
76
126
|
{
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
127
|
+
columns: n,
|
|
128
|
+
estimateRowSize: x,
|
|
129
|
+
getItemKey: (e) => e.name,
|
|
130
|
+
gridClassName: "grid grid-cols-1 gap-3 sm:grid-cols-2 xl:grid-cols-3",
|
|
131
|
+
items: c,
|
|
132
|
+
parentRef: d,
|
|
133
|
+
renderItem: p,
|
|
134
|
+
rowGapPx: 12
|
|
135
|
+
}
|
|
136
|
+
)
|
|
85
137
|
] })
|
|
86
138
|
] });
|
|
87
139
|
}
|
|
88
140
|
export {
|
|
89
|
-
|
|
141
|
+
J as ToolkitList
|
|
90
142
|
};
|
|
@@ -1,7 +1,9 @@
|
|
|
1
|
+
import { RefObject } from 'react';
|
|
1
2
|
import { SelectionMode } from '../index';
|
|
2
3
|
type ToolsListProps = {
|
|
3
4
|
selectionMode: SelectionMode;
|
|
5
|
+
scrollContainerRef: RefObject<HTMLDivElement | null>;
|
|
4
6
|
};
|
|
5
|
-
export declare function ToolsList({ selectionMode }: ToolsListProps): import("react/jsx-runtime").JSX.Element;
|
|
7
|
+
export declare function ToolsList({ selectionMode, scrollContainerRef, }: ToolsListProps): import("react/jsx-runtime").JSX.Element;
|
|
6
8
|
export {};
|
|
7
9
|
//# sourceMappingURL=tools-list.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tools-list.d.ts","sourceRoot":"","sources":["../../../../../../lib/components/ui/organisms/toolkit-picker/components/tools-list.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"tools-list.d.ts","sourceRoot":"","sources":["../../../../../../lib/components/ui/organisms/toolkit-picker/components/tools-list.tsx"],"names":[],"mappings":"AAKA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAEvC,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AAK9C,KAAK,cAAc,GAAG;IACpB,aAAa,EAAE,aAAa,CAAC;IAC7B,kBAAkB,EAAE,SAAS,CAAC,cAAc,GAAG,IAAI,CAAC,CAAC;CACtD,CAAC;AAEF,wBAAgB,SAAS,CAAC,EACxB,aAAa,EACb,kBAAkB,GACnB,EAAE,cAAc,2CAsGhB"}
|