@uipath/apollo-wind 0.9.0 → 0.10.0-pr219.eea0372
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/custom/canvas.cjs +44 -0
- package/dist/components/custom/canvas.d.ts +14 -0
- package/dist/components/custom/canvas.js +10 -0
- package/dist/components/custom/chat-composer.cjs +105 -0
- package/dist/components/custom/chat-composer.d.ts +15 -0
- package/dist/components/custom/chat-composer.js +71 -0
- package/dist/components/custom/chat-first-experience.cjs +87 -0
- package/dist/components/custom/chat-first-experience.d.ts +24 -0
- package/dist/components/custom/chat-first-experience.js +53 -0
- package/dist/components/custom/chat-prompt-suggestions.cjs +48 -0
- package/dist/components/custom/chat-prompt-suggestions.d.ts +18 -0
- package/dist/components/custom/chat-prompt-suggestions.js +14 -0
- package/dist/components/custom/chat-steps-view.cjs +307 -0
- package/dist/components/custom/chat-steps-view.d.ts +38 -0
- package/dist/components/custom/chat-steps-view.js +273 -0
- package/dist/components/custom/flow-node.cjs +76 -0
- package/dist/components/custom/flow-node.d.ts +20 -0
- package/dist/components/custom/flow-node.js +42 -0
- package/dist/components/custom/flow-properties-bar.cjs +101 -0
- package/dist/components/custom/flow-properties-bar.d.ts +21 -0
- package/dist/components/custom/flow-properties-bar.js +67 -0
- package/dist/components/custom/flow-properties-expanded.cjs +324 -0
- package/dist/components/custom/flow-properties-expanded.d.ts +19 -0
- package/dist/components/custom/flow-properties-expanded.js +290 -0
- package/dist/components/custom/flow-properties-simple.cjs +357 -0
- package/dist/components/custom/flow-properties-simple.d.ts +62 -0
- package/dist/components/custom/flow-properties-simple.js +323 -0
- package/dist/components/custom/flow-properties.cjs +56 -0
- package/dist/components/custom/flow-properties.d.ts +28 -0
- package/dist/components/custom/flow-properties.js +22 -0
- package/dist/components/custom/global-header.cjs +415 -0
- package/dist/components/custom/global-header.d.ts +38 -0
- package/dist/components/custom/global-header.js +381 -0
- package/dist/components/custom/grid-maestro.cjs +62 -0
- package/dist/components/custom/grid-maestro.d.ts +19 -0
- package/dist/components/custom/grid-maestro.js +22 -0
- package/dist/components/custom/panel-delegate.cjs +280 -0
- package/dist/components/custom/panel-delegate.d.ts +34 -0
- package/dist/components/custom/panel-delegate.js +246 -0
- package/dist/components/custom/panel-flow.cjs +260 -0
- package/dist/components/custom/panel-flow.d.ts +38 -0
- package/dist/components/custom/panel-flow.js +223 -0
- package/dist/components/custom/panel-maestro.cjs +73 -0
- package/dist/components/custom/panel-maestro.d.ts +30 -0
- package/dist/components/custom/panel-maestro.js +39 -0
- package/dist/components/custom/toolbar-canvas.cjs +121 -0
- package/dist/components/custom/toolbar-canvas.d.ts +15 -0
- package/dist/components/custom/toolbar-canvas.js +87 -0
- package/dist/components/custom/toolbar-view.cjs +119 -0
- package/dist/components/custom/toolbar-view.d.ts +14 -0
- package/dist/components/custom/toolbar-view.js +85 -0
- package/dist/components/custom/viewport-guard.cjs +92 -0
- package/dist/components/custom/viewport-guard.d.ts +23 -0
- package/dist/components/custom/viewport-guard.js +55 -0
- package/dist/components/ui/button.cjs +3 -3
- package/dist/components/ui/button.js +3 -3
- package/dist/components/ui/chart.cjs +218 -0
- package/dist/components/ui/chart.d.ts +40 -0
- package/dist/components/ui/chart.js +169 -0
- package/dist/components/ui/data-table.cjs +14 -2
- package/dist/components/ui/data-table.d.ts +4 -1
- package/dist/components/ui/data-table.js +15 -3
- package/dist/components/ui/empty-state.cjs +17 -6
- package/dist/components/ui/empty-state.d.ts +7 -0
- package/dist/components/ui/empty-state.js +17 -6
- package/dist/components/ui/file-upload.cjs +82 -42
- package/dist/components/ui/file-upload.d.ts +3 -1
- package/dist/components/ui/file-upload.js +82 -42
- package/dist/components/ui/index.cjs +305 -165
- package/dist/components/ui/index.d.ts +2 -3
- package/dist/components/ui/index.js +2 -3
- package/dist/components/ui/tree-view.cjs +1101 -0
- package/dist/components/ui/tree-view.d.ts +95 -0
- package/dist/components/ui/tree-view.js +1067 -0
- package/dist/foundation/Future/colors.cjs +92 -0
- package/dist/foundation/Future/colors.d.ts +132 -0
- package/dist/foundation/Future/colors.js +43 -0
- package/dist/foundation/Future/radius.cjs +46 -0
- package/dist/foundation/Future/radius.d.ts +33 -0
- package/dist/foundation/Future/radius.js +12 -0
- package/dist/foundation/Future/responsive.cjs +49 -0
- package/dist/foundation/Future/responsive.d.ts +40 -0
- package/dist/foundation/Future/responsive.js +12 -0
- package/dist/foundation/Future/shadows.cjs +48 -0
- package/dist/foundation/Future/shadows.d.ts +29 -0
- package/dist/foundation/Future/shadows.js +11 -0
- package/dist/foundation/Future/spacing.cjs +71 -0
- package/dist/foundation/Future/spacing.d.ts +80 -0
- package/dist/foundation/Future/spacing.js +31 -0
- package/dist/foundation/Future/strokes.cjs +59 -0
- package/dist/foundation/Future/strokes.d.ts +49 -0
- package/dist/foundation/Future/strokes.js +19 -0
- package/dist/foundation/Future/types.cjs +18 -0
- package/dist/foundation/Future/types.d.ts +18 -0
- package/dist/foundation/Future/types.js +0 -0
- package/dist/foundation/Future/typography.cjs +79 -0
- package/dist/foundation/Future/typography.d.ts +86 -0
- package/dist/foundation/Future/typography.js +33 -0
- package/dist/index.cjs +125 -219
- package/dist/index.d.ts +2 -3
- package/dist/index.js +2 -4
- package/dist/src/foundation/Future/future-theme.css +297 -0
- package/dist/src/foundation/Future/legacy-theme.css +184 -0
- package/dist/styles.css +1678 -379
- package/dist/tailwind.css +4 -0
- package/dist/templates/Admin/settings-admin.d.ts +5 -0
- package/dist/templates/Admin/template-admin.d.ts +105 -0
- package/dist/templates/Delegate/template-delegate.d.ts +26 -0
- package/dist/templates/EmptyErrors/error-components.d.ts +3 -0
- package/dist/templates/Experiments/ideas-AnimatedGradientText.d.ts +23 -0
- package/dist/templates/Flow/template-flow.d.ts +52 -0
- package/dist/templates/Maestro/template-maestro.d.ts +52 -0
- package/dist/templates/{vscode-example.d.ts → VisualStudio/shell.d.ts} +1 -1
- package/package.json +10 -1
- package/dist/components/ui/menubar.cjs +0 -210
- package/dist/components/ui/menubar.d.ts +0 -28
- package/dist/components/ui/menubar.js +0 -131
- package/dist/components/ui/navigation-menu.cjs +0 -122
- package/dist/components/ui/navigation-menu.d.ts +0 -12
- package/dist/components/ui/navigation-menu.js +0 -64
- package/dist/examples/admin-layout-example.cjs +0 -490
- package/dist/examples/admin-layout-example.d.ts +0 -92
- package/dist/examples/admin-layout-example.js +0 -411
- package/dist/examples/app-shell-example.cjs +0 -452
- package/dist/examples/app-shell-example.d.ts +0 -52
- package/dist/examples/app-shell-example.js +0 -418
- package/dist/examples/dashboard-example.cjs +0 -590
- package/dist/examples/dashboard-example.d.ts +0 -11
- package/dist/examples/dashboard-example.js +0 -556
- package/dist/examples/data-management-example.cjs +0 -584
- package/dist/examples/data-management-example.d.ts +0 -1
- package/dist/examples/data-management-example.js +0 -550
- package/dist/examples/flow-editor-layout-example.cjs +0 -309
- package/dist/examples/flow-editor-layout-example.d.ts +0 -22
- package/dist/examples/flow-editor-layout-example.js +0 -269
- package/dist/examples/flow-start-example.cjs +0 -467
- package/dist/examples/flow-start-example.d.ts +0 -30
- package/dist/examples/flow-start-example.js +0 -433
- package/dist/examples/form-builder-example.cjs +0 -674
- package/dist/examples/form-builder-example.js +0 -640
- package/dist/examples/new-project-example.cjs +0 -550
- package/dist/examples/new-project-example.d.ts +0 -30
- package/dist/examples/new-project-example.js +0 -516
- package/dist/examples/settings-example.cjs +0 -864
- package/dist/examples/settings-example.d.ts +0 -1
- package/dist/examples/settings-example.js +0 -830
- package/dist/examples/vscode-example.cjs +0 -340
- package/dist/examples/vscode-example.d.ts +0 -80
- package/dist/examples/vscode-example.js +0 -270
- package/dist/templates/admin-layout-example.d.ts +0 -92
- package/dist/templates/app-shell-example.d.ts +0 -52
- package/dist/templates/dashboard-example.d.ts +0 -11
- package/dist/templates/data-management-example.d.ts +0 -1
- package/dist/templates/flow-editor-layout-example.d.ts +0 -22
- package/dist/templates/flow-start-example.d.ts +0 -30
- package/dist/templates/form-builder-example.d.ts +0 -1
- package/dist/templates/new-project-example.d.ts +0 -30
- package/dist/templates/settings-example.d.ts +0 -1
- /package/dist/{examples → templates/Forms}/form-builder-example.d.ts +0 -0
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __webpack_require__ = {};
|
|
3
|
+
(()=>{
|
|
4
|
+
__webpack_require__.d = (exports1, definition)=>{
|
|
5
|
+
for(var key in definition)if (__webpack_require__.o(definition, key) && !__webpack_require__.o(exports1, key)) Object.defineProperty(exports1, key, {
|
|
6
|
+
enumerable: true,
|
|
7
|
+
get: definition[key]
|
|
8
|
+
});
|
|
9
|
+
};
|
|
10
|
+
})();
|
|
11
|
+
(()=>{
|
|
12
|
+
__webpack_require__.o = (obj, prop)=>Object.prototype.hasOwnProperty.call(obj, prop);
|
|
13
|
+
})();
|
|
14
|
+
(()=>{
|
|
15
|
+
__webpack_require__.r = (exports1)=>{
|
|
16
|
+
if ('undefined' != typeof Symbol && Symbol.toStringTag) Object.defineProperty(exports1, Symbol.toStringTag, {
|
|
17
|
+
value: 'Module'
|
|
18
|
+
});
|
|
19
|
+
Object.defineProperty(exports1, '__esModule', {
|
|
20
|
+
value: true
|
|
21
|
+
});
|
|
22
|
+
};
|
|
23
|
+
})();
|
|
24
|
+
var __webpack_exports__ = {};
|
|
25
|
+
__webpack_require__.r(__webpack_exports__);
|
|
26
|
+
__webpack_require__.d(__webpack_exports__, {
|
|
27
|
+
Canvas: ()=>Canvas
|
|
28
|
+
});
|
|
29
|
+
const jsx_runtime_namespaceObject = require("react/jsx-runtime");
|
|
30
|
+
require("react");
|
|
31
|
+
const index_cjs_namespaceObject = require("../../lib/index.cjs");
|
|
32
|
+
function Canvas({ className, children }) {
|
|
33
|
+
return /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)("div", {
|
|
34
|
+
className: (0, index_cjs_namespaceObject.cn)('flex flex-1 flex-col overflow-auto bg-future-surface', className),
|
|
35
|
+
children: children
|
|
36
|
+
});
|
|
37
|
+
}
|
|
38
|
+
exports.Canvas = __webpack_exports__.Canvas;
|
|
39
|
+
for(var __webpack_i__ in __webpack_exports__)if (-1 === [
|
|
40
|
+
"Canvas"
|
|
41
|
+
].indexOf(__webpack_i__)) exports[__webpack_i__] = __webpack_exports__[__webpack_i__];
|
|
42
|
+
Object.defineProperty(exports, '__esModule', {
|
|
43
|
+
value: true
|
|
44
|
+
});
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
export interface CanvasProps {
|
|
3
|
+
className?: string;
|
|
4
|
+
children?: React.ReactNode;
|
|
5
|
+
}
|
|
6
|
+
/**
|
|
7
|
+
* Main content canvas for Delegate templates.
|
|
8
|
+
*
|
|
9
|
+
* Provides the dark background surface that sits alongside the DelegatePanel.
|
|
10
|
+
* Content placed inside the Canvas can be laid out freely — future iterations
|
|
11
|
+
* will add optional layout guidelines (max-width constraints, centered
|
|
12
|
+
* content zones, padding presets, etc.).
|
|
13
|
+
*/
|
|
14
|
+
export declare function Canvas({ className, children }: CanvasProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { jsx } from "react/jsx-runtime";
|
|
2
|
+
import "react";
|
|
3
|
+
import { cn } from "../../lib/index.js";
|
|
4
|
+
function Canvas({ className, children }) {
|
|
5
|
+
return /*#__PURE__*/ jsx("div", {
|
|
6
|
+
className: cn('flex flex-1 flex-col overflow-auto bg-future-surface', className),
|
|
7
|
+
children: children
|
|
8
|
+
});
|
|
9
|
+
}
|
|
10
|
+
export { Canvas };
|
|
@@ -0,0 +1,105 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __webpack_require__ = {};
|
|
3
|
+
(()=>{
|
|
4
|
+
__webpack_require__.d = (exports1, definition)=>{
|
|
5
|
+
for(var key in definition)if (__webpack_require__.o(definition, key) && !__webpack_require__.o(exports1, key)) Object.defineProperty(exports1, key, {
|
|
6
|
+
enumerable: true,
|
|
7
|
+
get: definition[key]
|
|
8
|
+
});
|
|
9
|
+
};
|
|
10
|
+
})();
|
|
11
|
+
(()=>{
|
|
12
|
+
__webpack_require__.o = (obj, prop)=>Object.prototype.hasOwnProperty.call(obj, prop);
|
|
13
|
+
})();
|
|
14
|
+
(()=>{
|
|
15
|
+
__webpack_require__.r = (exports1)=>{
|
|
16
|
+
if ('undefined' != typeof Symbol && Symbol.toStringTag) Object.defineProperty(exports1, Symbol.toStringTag, {
|
|
17
|
+
value: 'Module'
|
|
18
|
+
});
|
|
19
|
+
Object.defineProperty(exports1, '__esModule', {
|
|
20
|
+
value: true
|
|
21
|
+
});
|
|
22
|
+
};
|
|
23
|
+
})();
|
|
24
|
+
var __webpack_exports__ = {};
|
|
25
|
+
__webpack_require__.r(__webpack_exports__);
|
|
26
|
+
__webpack_require__.d(__webpack_exports__, {
|
|
27
|
+
ChatComposer: ()=>ChatComposer
|
|
28
|
+
});
|
|
29
|
+
const jsx_runtime_namespaceObject = require("react/jsx-runtime");
|
|
30
|
+
const external_lucide_react_namespaceObject = require("lucide-react");
|
|
31
|
+
const external_react_namespaceObject = require("react");
|
|
32
|
+
const index_cjs_namespaceObject = require("../../lib/index.cjs");
|
|
33
|
+
function ChatComposer({ className, placeholder = 'I would like you to automate my', onSubmit }) {
|
|
34
|
+
const [value, setValue] = external_react_namespaceObject.useState('');
|
|
35
|
+
const handleSubmit = ()=>{
|
|
36
|
+
if (value.trim()) {
|
|
37
|
+
onSubmit?.(value.trim());
|
|
38
|
+
setValue('');
|
|
39
|
+
}
|
|
40
|
+
};
|
|
41
|
+
const handleKeyDown = (e)=>{
|
|
42
|
+
if ('Enter' === e.key && !e.shiftKey) {
|
|
43
|
+
e.preventDefault();
|
|
44
|
+
handleSubmit();
|
|
45
|
+
}
|
|
46
|
+
};
|
|
47
|
+
return /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)("div", {
|
|
48
|
+
className: (0, index_cjs_namespaceObject.cn)('w-full max-w-[800px] rounded-[32px] bg-gradient-to-b from-future-surface to-future-surface-raised p-2', className),
|
|
49
|
+
children: /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsxs)("div", {
|
|
50
|
+
className: "flex min-h-[124px] flex-col justify-between rounded-3xl border border-future-border bg-future-surface-overlay pb-3 pl-4 pr-3 pt-4",
|
|
51
|
+
children: [
|
|
52
|
+
/*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)("textarea", {
|
|
53
|
+
className: "w-full resize-none bg-transparent text-base font-medium leading-5 text-future-foreground placeholder:text-future-foreground-subtle focus:outline-none",
|
|
54
|
+
placeholder: placeholder,
|
|
55
|
+
rows: 2,
|
|
56
|
+
value: value,
|
|
57
|
+
onChange: (e)=>setValue(e.target.value),
|
|
58
|
+
onKeyDown: handleKeyDown
|
|
59
|
+
}),
|
|
60
|
+
/*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsxs)("div", {
|
|
61
|
+
className: "flex items-center justify-between",
|
|
62
|
+
children: [
|
|
63
|
+
/*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsxs)("div", {
|
|
64
|
+
className: "flex items-center gap-1",
|
|
65
|
+
children: [
|
|
66
|
+
/*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)("button", {
|
|
67
|
+
type: "button",
|
|
68
|
+
className: "flex h-8 w-8 items-center justify-center rounded-2xl border border-future-border-inverse bg-future-surface-inverse transition-opacity hover:opacity-80",
|
|
69
|
+
"aria-label": "Add attachment",
|
|
70
|
+
children: /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(external_lucide_react_namespaceObject.Plus, {
|
|
71
|
+
className: "h-5 w-5 text-future-foreground-inverse"
|
|
72
|
+
})
|
|
73
|
+
}),
|
|
74
|
+
/*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)("button", {
|
|
75
|
+
type: "button",
|
|
76
|
+
className: "flex h-8 w-8 items-center justify-center rounded-2xl border border-future-border-inverse bg-future-surface-inverse transition-opacity hover:opacity-80",
|
|
77
|
+
"aria-label": "Add workflow",
|
|
78
|
+
children: /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(external_lucide_react_namespaceObject.Workflow, {
|
|
79
|
+
className: "h-5 w-5 text-future-foreground-inverse"
|
|
80
|
+
})
|
|
81
|
+
})
|
|
82
|
+
]
|
|
83
|
+
}),
|
|
84
|
+
/*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)("button", {
|
|
85
|
+
type: "button",
|
|
86
|
+
className: "flex h-8 w-8 items-center justify-center rounded-2xl bg-future-accent transition-opacity hover:opacity-90",
|
|
87
|
+
onClick: handleSubmit,
|
|
88
|
+
"aria-label": "Submit message",
|
|
89
|
+
children: /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(external_lucide_react_namespaceObject.CornerDownLeft, {
|
|
90
|
+
className: "h-5 w-5 -scale-y-100 rotate-90 text-future-foreground-on-accent"
|
|
91
|
+
})
|
|
92
|
+
})
|
|
93
|
+
]
|
|
94
|
+
})
|
|
95
|
+
]
|
|
96
|
+
})
|
|
97
|
+
});
|
|
98
|
+
}
|
|
99
|
+
exports.ChatComposer = __webpack_exports__.ChatComposer;
|
|
100
|
+
for(var __webpack_i__ in __webpack_exports__)if (-1 === [
|
|
101
|
+
"ChatComposer"
|
|
102
|
+
].indexOf(__webpack_i__)) exports[__webpack_i__] = __webpack_exports__[__webpack_i__];
|
|
103
|
+
Object.defineProperty(exports, '__esModule', {
|
|
104
|
+
value: true
|
|
105
|
+
});
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
export interface ChatComposerProps {
|
|
2
|
+
className?: string;
|
|
3
|
+
/** Placeholder text displayed when the input is empty */
|
|
4
|
+
placeholder?: string;
|
|
5
|
+
/** Callback when the user submits a message */
|
|
6
|
+
onSubmit?: (value: string) => void;
|
|
7
|
+
}
|
|
8
|
+
/**
|
|
9
|
+
* Reusable chat composer input with action buttons.
|
|
10
|
+
*
|
|
11
|
+
* Features a text area, left-side action buttons (add, workflow),
|
|
12
|
+
* and a cyan submit button. Fixed at 800px max-width to match the
|
|
13
|
+
* Delegate design spec.
|
|
14
|
+
*/
|
|
15
|
+
export declare function ChatComposer({ className, placeholder, onSubmit, }: ChatComposerProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,71 @@
|
|
|
1
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
2
|
+
import { CornerDownLeft, Plus, Workflow } from "lucide-react";
|
|
3
|
+
import { useState } from "react";
|
|
4
|
+
import { cn } from "../../lib/index.js";
|
|
5
|
+
function ChatComposer({ className, placeholder = 'I would like you to automate my', onSubmit }) {
|
|
6
|
+
const [value, setValue] = useState('');
|
|
7
|
+
const handleSubmit = ()=>{
|
|
8
|
+
if (value.trim()) {
|
|
9
|
+
onSubmit?.(value.trim());
|
|
10
|
+
setValue('');
|
|
11
|
+
}
|
|
12
|
+
};
|
|
13
|
+
const handleKeyDown = (e)=>{
|
|
14
|
+
if ('Enter' === e.key && !e.shiftKey) {
|
|
15
|
+
e.preventDefault();
|
|
16
|
+
handleSubmit();
|
|
17
|
+
}
|
|
18
|
+
};
|
|
19
|
+
return /*#__PURE__*/ jsx("div", {
|
|
20
|
+
className: cn('w-full max-w-[800px] rounded-[32px] bg-gradient-to-b from-future-surface to-future-surface-raised p-2', className),
|
|
21
|
+
children: /*#__PURE__*/ jsxs("div", {
|
|
22
|
+
className: "flex min-h-[124px] flex-col justify-between rounded-3xl border border-future-border bg-future-surface-overlay pb-3 pl-4 pr-3 pt-4",
|
|
23
|
+
children: [
|
|
24
|
+
/*#__PURE__*/ jsx("textarea", {
|
|
25
|
+
className: "w-full resize-none bg-transparent text-base font-medium leading-5 text-future-foreground placeholder:text-future-foreground-subtle focus:outline-none",
|
|
26
|
+
placeholder: placeholder,
|
|
27
|
+
rows: 2,
|
|
28
|
+
value: value,
|
|
29
|
+
onChange: (e)=>setValue(e.target.value),
|
|
30
|
+
onKeyDown: handleKeyDown
|
|
31
|
+
}),
|
|
32
|
+
/*#__PURE__*/ jsxs("div", {
|
|
33
|
+
className: "flex items-center justify-between",
|
|
34
|
+
children: [
|
|
35
|
+
/*#__PURE__*/ jsxs("div", {
|
|
36
|
+
className: "flex items-center gap-1",
|
|
37
|
+
children: [
|
|
38
|
+
/*#__PURE__*/ jsx("button", {
|
|
39
|
+
type: "button",
|
|
40
|
+
className: "flex h-8 w-8 items-center justify-center rounded-2xl border border-future-border-inverse bg-future-surface-inverse transition-opacity hover:opacity-80",
|
|
41
|
+
"aria-label": "Add attachment",
|
|
42
|
+
children: /*#__PURE__*/ jsx(Plus, {
|
|
43
|
+
className: "h-5 w-5 text-future-foreground-inverse"
|
|
44
|
+
})
|
|
45
|
+
}),
|
|
46
|
+
/*#__PURE__*/ jsx("button", {
|
|
47
|
+
type: "button",
|
|
48
|
+
className: "flex h-8 w-8 items-center justify-center rounded-2xl border border-future-border-inverse bg-future-surface-inverse transition-opacity hover:opacity-80",
|
|
49
|
+
"aria-label": "Add workflow",
|
|
50
|
+
children: /*#__PURE__*/ jsx(Workflow, {
|
|
51
|
+
className: "h-5 w-5 text-future-foreground-inverse"
|
|
52
|
+
})
|
|
53
|
+
})
|
|
54
|
+
]
|
|
55
|
+
}),
|
|
56
|
+
/*#__PURE__*/ jsx("button", {
|
|
57
|
+
type: "button",
|
|
58
|
+
className: "flex h-8 w-8 items-center justify-center rounded-2xl bg-future-accent transition-opacity hover:opacity-90",
|
|
59
|
+
onClick: handleSubmit,
|
|
60
|
+
"aria-label": "Submit message",
|
|
61
|
+
children: /*#__PURE__*/ jsx(CornerDownLeft, {
|
|
62
|
+
className: "h-5 w-5 -scale-y-100 rotate-90 text-future-foreground-on-accent"
|
|
63
|
+
})
|
|
64
|
+
})
|
|
65
|
+
]
|
|
66
|
+
})
|
|
67
|
+
]
|
|
68
|
+
})
|
|
69
|
+
});
|
|
70
|
+
}
|
|
71
|
+
export { ChatComposer };
|
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __webpack_require__ = {};
|
|
3
|
+
(()=>{
|
|
4
|
+
__webpack_require__.d = (exports1, definition)=>{
|
|
5
|
+
for(var key in definition)if (__webpack_require__.o(definition, key) && !__webpack_require__.o(exports1, key)) Object.defineProperty(exports1, key, {
|
|
6
|
+
enumerable: true,
|
|
7
|
+
get: definition[key]
|
|
8
|
+
});
|
|
9
|
+
};
|
|
10
|
+
})();
|
|
11
|
+
(()=>{
|
|
12
|
+
__webpack_require__.o = (obj, prop)=>Object.prototype.hasOwnProperty.call(obj, prop);
|
|
13
|
+
})();
|
|
14
|
+
(()=>{
|
|
15
|
+
__webpack_require__.r = (exports1)=>{
|
|
16
|
+
if ('undefined' != typeof Symbol && Symbol.toStringTag) Object.defineProperty(exports1, Symbol.toStringTag, {
|
|
17
|
+
value: 'Module'
|
|
18
|
+
});
|
|
19
|
+
Object.defineProperty(exports1, '__esModule', {
|
|
20
|
+
value: true
|
|
21
|
+
});
|
|
22
|
+
};
|
|
23
|
+
})();
|
|
24
|
+
var __webpack_exports__ = {};
|
|
25
|
+
__webpack_require__.r(__webpack_exports__);
|
|
26
|
+
__webpack_require__.d(__webpack_exports__, {
|
|
27
|
+
ChatFirstExperience: ()=>ChatFirstExperience
|
|
28
|
+
});
|
|
29
|
+
const jsx_runtime_namespaceObject = require("react/jsx-runtime");
|
|
30
|
+
const index_cjs_namespaceObject = require("../../lib/index.cjs");
|
|
31
|
+
const external_chat_composer_cjs_namespaceObject = require("./chat-composer.cjs");
|
|
32
|
+
const external_chat_prompt_suggestions_cjs_namespaceObject = require("./chat-prompt-suggestions.cjs");
|
|
33
|
+
function ChatFirstExperience({ className, userName = 'David', subtitle = 'What should we work on today?', composerPlaceholder = 'I would like you to automate my', suggestions = [
|
|
34
|
+
{
|
|
35
|
+
id: '1',
|
|
36
|
+
label: 'Make a list of affordable apartments in NYC'
|
|
37
|
+
},
|
|
38
|
+
{
|
|
39
|
+
id: '2',
|
|
40
|
+
label: 'Find the highest CD rates'
|
|
41
|
+
},
|
|
42
|
+
{
|
|
43
|
+
id: '3',
|
|
44
|
+
label: 'Lorem ipsum dolor sit amet'
|
|
45
|
+
}
|
|
46
|
+
], onSuggestionClick, onSubmit }) {
|
|
47
|
+
return /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)("div", {
|
|
48
|
+
className: (0, index_cjs_namespaceObject.cn)('flex flex-1 flex-col items-center justify-center', className),
|
|
49
|
+
children: /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsxs)("div", {
|
|
50
|
+
className: "flex w-full max-w-[800px] flex-col items-center gap-[37px]",
|
|
51
|
+
children: [
|
|
52
|
+
/*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsxs)("div", {
|
|
53
|
+
className: "flex flex-col items-center text-center",
|
|
54
|
+
children: [
|
|
55
|
+
/*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsxs)("h1", {
|
|
56
|
+
className: "text-[40px] font-bold leading-9 tracking-[-0.8px] text-future-foreground",
|
|
57
|
+
children: [
|
|
58
|
+
"Hello ",
|
|
59
|
+
userName
|
|
60
|
+
]
|
|
61
|
+
}),
|
|
62
|
+
/*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)("p", {
|
|
63
|
+
className: "mt-1 text-base font-normal leading-9 text-future-foreground-secondary",
|
|
64
|
+
children: subtitle
|
|
65
|
+
})
|
|
66
|
+
]
|
|
67
|
+
}),
|
|
68
|
+
/*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(external_chat_composer_cjs_namespaceObject.ChatComposer, {
|
|
69
|
+
placeholder: composerPlaceholder,
|
|
70
|
+
onSubmit: onSubmit
|
|
71
|
+
}),
|
|
72
|
+
/*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(external_chat_prompt_suggestions_cjs_namespaceObject.PromptSuggestions, {
|
|
73
|
+
className: "w-full",
|
|
74
|
+
suggestions: suggestions,
|
|
75
|
+
onSelect: onSuggestionClick
|
|
76
|
+
})
|
|
77
|
+
]
|
|
78
|
+
})
|
|
79
|
+
});
|
|
80
|
+
}
|
|
81
|
+
exports.ChatFirstExperience = __webpack_exports__.ChatFirstExperience;
|
|
82
|
+
for(var __webpack_i__ in __webpack_exports__)if (-1 === [
|
|
83
|
+
"ChatFirstExperience"
|
|
84
|
+
].indexOf(__webpack_i__)) exports[__webpack_i__] = __webpack_exports__[__webpack_i__];
|
|
85
|
+
Object.defineProperty(exports, '__esModule', {
|
|
86
|
+
value: true
|
|
87
|
+
});
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { type PromptSuggestion } from './chat-prompt-suggestions';
|
|
2
|
+
export interface ChatFirstExperienceProps {
|
|
3
|
+
className?: string;
|
|
4
|
+
/** Greeting name displayed in the heading */
|
|
5
|
+
userName?: string;
|
|
6
|
+
/** Subtitle below the greeting */
|
|
7
|
+
subtitle?: string;
|
|
8
|
+
/** Placeholder text inside the composer */
|
|
9
|
+
composerPlaceholder?: string;
|
|
10
|
+
/** Prompt suggestions shown below the composer */
|
|
11
|
+
suggestions?: PromptSuggestion[];
|
|
12
|
+
/** Callback when a suggestion is clicked */
|
|
13
|
+
onSuggestionClick?: (suggestion: PromptSuggestion) => void;
|
|
14
|
+
/** Callback when the composer submit button is clicked */
|
|
15
|
+
onSubmit?: (value: string) => void;
|
|
16
|
+
}
|
|
17
|
+
/**
|
|
18
|
+
* The initial "first run" experience shown in the Canvas when
|
|
19
|
+
* a user opens the Delegate Chat page with no active conversation.
|
|
20
|
+
*
|
|
21
|
+
* Displays a greeting, a composer input, and prompt suggestions,
|
|
22
|
+
* all constrained to 800px max-width and centered in the canvas.
|
|
23
|
+
*/
|
|
24
|
+
export declare function ChatFirstExperience({ className, userName, subtitle, composerPlaceholder, suggestions, onSuggestionClick, onSubmit, }: ChatFirstExperienceProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
2
|
+
import { cn } from "../../lib/index.js";
|
|
3
|
+
import { ChatComposer } from "./chat-composer.js";
|
|
4
|
+
import { PromptSuggestions } from "./chat-prompt-suggestions.js";
|
|
5
|
+
function ChatFirstExperience({ className, userName = 'David', subtitle = 'What should we work on today?', composerPlaceholder = 'I would like you to automate my', suggestions = [
|
|
6
|
+
{
|
|
7
|
+
id: '1',
|
|
8
|
+
label: 'Make a list of affordable apartments in NYC'
|
|
9
|
+
},
|
|
10
|
+
{
|
|
11
|
+
id: '2',
|
|
12
|
+
label: 'Find the highest CD rates'
|
|
13
|
+
},
|
|
14
|
+
{
|
|
15
|
+
id: '3',
|
|
16
|
+
label: 'Lorem ipsum dolor sit amet'
|
|
17
|
+
}
|
|
18
|
+
], onSuggestionClick, onSubmit }) {
|
|
19
|
+
return /*#__PURE__*/ jsx("div", {
|
|
20
|
+
className: cn('flex flex-1 flex-col items-center justify-center', className),
|
|
21
|
+
children: /*#__PURE__*/ jsxs("div", {
|
|
22
|
+
className: "flex w-full max-w-[800px] flex-col items-center gap-[37px]",
|
|
23
|
+
children: [
|
|
24
|
+
/*#__PURE__*/ jsxs("div", {
|
|
25
|
+
className: "flex flex-col items-center text-center",
|
|
26
|
+
children: [
|
|
27
|
+
/*#__PURE__*/ jsxs("h1", {
|
|
28
|
+
className: "text-[40px] font-bold leading-9 tracking-[-0.8px] text-future-foreground",
|
|
29
|
+
children: [
|
|
30
|
+
"Hello ",
|
|
31
|
+
userName
|
|
32
|
+
]
|
|
33
|
+
}),
|
|
34
|
+
/*#__PURE__*/ jsx("p", {
|
|
35
|
+
className: "mt-1 text-base font-normal leading-9 text-future-foreground-secondary",
|
|
36
|
+
children: subtitle
|
|
37
|
+
})
|
|
38
|
+
]
|
|
39
|
+
}),
|
|
40
|
+
/*#__PURE__*/ jsx(ChatComposer, {
|
|
41
|
+
placeholder: composerPlaceholder,
|
|
42
|
+
onSubmit: onSubmit
|
|
43
|
+
}),
|
|
44
|
+
/*#__PURE__*/ jsx(PromptSuggestions, {
|
|
45
|
+
className: "w-full",
|
|
46
|
+
suggestions: suggestions,
|
|
47
|
+
onSelect: onSuggestionClick
|
|
48
|
+
})
|
|
49
|
+
]
|
|
50
|
+
})
|
|
51
|
+
});
|
|
52
|
+
}
|
|
53
|
+
export { ChatFirstExperience };
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __webpack_require__ = {};
|
|
3
|
+
(()=>{
|
|
4
|
+
__webpack_require__.d = (exports1, definition)=>{
|
|
5
|
+
for(var key in definition)if (__webpack_require__.o(definition, key) && !__webpack_require__.o(exports1, key)) Object.defineProperty(exports1, key, {
|
|
6
|
+
enumerable: true,
|
|
7
|
+
get: definition[key]
|
|
8
|
+
});
|
|
9
|
+
};
|
|
10
|
+
})();
|
|
11
|
+
(()=>{
|
|
12
|
+
__webpack_require__.o = (obj, prop)=>Object.prototype.hasOwnProperty.call(obj, prop);
|
|
13
|
+
})();
|
|
14
|
+
(()=>{
|
|
15
|
+
__webpack_require__.r = (exports1)=>{
|
|
16
|
+
if ('undefined' != typeof Symbol && Symbol.toStringTag) Object.defineProperty(exports1, Symbol.toStringTag, {
|
|
17
|
+
value: 'Module'
|
|
18
|
+
});
|
|
19
|
+
Object.defineProperty(exports1, '__esModule', {
|
|
20
|
+
value: true
|
|
21
|
+
});
|
|
22
|
+
};
|
|
23
|
+
})();
|
|
24
|
+
var __webpack_exports__ = {};
|
|
25
|
+
__webpack_require__.r(__webpack_exports__);
|
|
26
|
+
__webpack_require__.d(__webpack_exports__, {
|
|
27
|
+
PromptSuggestions: ()=>PromptSuggestions
|
|
28
|
+
});
|
|
29
|
+
const jsx_runtime_namespaceObject = require("react/jsx-runtime");
|
|
30
|
+
const index_cjs_namespaceObject = require("../../lib/index.cjs");
|
|
31
|
+
function PromptSuggestions({ className, suggestions = [], onSelect }) {
|
|
32
|
+
if (0 === suggestions.length) return null;
|
|
33
|
+
return /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)("div", {
|
|
34
|
+
className: (0, index_cjs_namespaceObject.cn)('flex flex-col items-start gap-2', className),
|
|
35
|
+
children: suggestions.map((suggestion)=>/*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)("button", {
|
|
36
|
+
className: "flex h-10 items-center rounded-xl border border-future-border bg-future-surface-overlay px-4 py-2.5 text-sm font-medium leading-5 text-future-foreground transition-colors hover:bg-future-surface-hover",
|
|
37
|
+
onClick: ()=>onSelect?.(suggestion),
|
|
38
|
+
children: suggestion.label
|
|
39
|
+
}, suggestion.id))
|
|
40
|
+
});
|
|
41
|
+
}
|
|
42
|
+
exports.PromptSuggestions = __webpack_exports__.PromptSuggestions;
|
|
43
|
+
for(var __webpack_i__ in __webpack_exports__)if (-1 === [
|
|
44
|
+
"PromptSuggestions"
|
|
45
|
+
].indexOf(__webpack_i__)) exports[__webpack_i__] = __webpack_exports__[__webpack_i__];
|
|
46
|
+
Object.defineProperty(exports, '__esModule', {
|
|
47
|
+
value: true
|
|
48
|
+
});
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
export interface PromptSuggestion {
|
|
2
|
+
id: string;
|
|
3
|
+
label: string;
|
|
4
|
+
}
|
|
5
|
+
export interface PromptSuggestionsProps {
|
|
6
|
+
className?: string;
|
|
7
|
+
/** List of suggestions to display */
|
|
8
|
+
suggestions?: PromptSuggestion[];
|
|
9
|
+
/** Callback when a suggestion is clicked */
|
|
10
|
+
onSelect?: (suggestion: PromptSuggestion) => void;
|
|
11
|
+
}
|
|
12
|
+
/**
|
|
13
|
+
* A vertical list of clickable prompt suggestion pills.
|
|
14
|
+
*
|
|
15
|
+
* Styled per the Delegate Figma spec: zinc-800 background with
|
|
16
|
+
* zinc-700 border and zinc-50 text.
|
|
17
|
+
*/
|
|
18
|
+
export declare function PromptSuggestions({ className, suggestions, onSelect, }: PromptSuggestionsProps): import("react/jsx-runtime").JSX.Element | null;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { jsx } from "react/jsx-runtime";
|
|
2
|
+
import { cn } from "../../lib/index.js";
|
|
3
|
+
function PromptSuggestions({ className, suggestions = [], onSelect }) {
|
|
4
|
+
if (0 === suggestions.length) return null;
|
|
5
|
+
return /*#__PURE__*/ jsx("div", {
|
|
6
|
+
className: cn('flex flex-col items-start gap-2', className),
|
|
7
|
+
children: suggestions.map((suggestion)=>/*#__PURE__*/ jsx("button", {
|
|
8
|
+
className: "flex h-10 items-center rounded-xl border border-future-border bg-future-surface-overlay px-4 py-2.5 text-sm font-medium leading-5 text-future-foreground transition-colors hover:bg-future-surface-hover",
|
|
9
|
+
onClick: ()=>onSelect?.(suggestion),
|
|
10
|
+
children: suggestion.label
|
|
11
|
+
}, suggestion.id))
|
|
12
|
+
});
|
|
13
|
+
}
|
|
14
|
+
export { PromptSuggestions };
|