@flowdrop/flowdrop 1.15.0 → 2.0.0-beta.10
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 +648 -0
- package/MIGRATION-2.0.md +642 -0
- package/README.md +28 -28
- package/dist/adapters/WorkflowAdapter.d.ts +1 -1
- package/dist/adapters/WorkflowAdapter.js +18 -13
- package/dist/adapters/agentspec/AgentSpecAdapter.js +10 -10
- package/dist/adapters/agentspec/defaultNodeTypes.js +9 -9
- package/dist/api/enhanced-client.js +6 -11
- package/dist/chat/batchFeedback.d.ts +39 -0
- package/dist/chat/batchFeedback.js +51 -0
- package/dist/commands/executor.js +66 -27
- package/dist/commands/storeIntegration.svelte.d.ts +4 -1
- package/dist/commands/storeIntegration.svelte.js +36 -21
- package/dist/commands/types.d.ts +2 -0
- package/dist/commands/types.js +5 -5
- package/dist/components/App.svelte +696 -565
- package/dist/components/App.svelte.d.ts +63 -16
- package/dist/components/Button.stories.svelte +65 -0
- package/dist/components/Button.stories.svelte.d.ts +19 -0
- package/dist/components/Button.svelte +62 -0
- package/dist/components/Button.svelte.d.ts +24 -0
- package/dist/components/CanvasIconButton.svelte +76 -0
- package/dist/components/CanvasIconButton.svelte.d.ts +18 -0
- package/dist/components/ConfigForm.svelte +181 -552
- package/dist/components/ConfigForm.svelte.d.ts +24 -7
- package/dist/components/ConfigModal.svelte +16 -3
- package/dist/components/ConfigPanel.svelte +234 -15
- package/dist/components/ConfigPanel.svelte.d.ts +6 -0
- package/dist/components/ConnectionLine.svelte +4 -2
- package/dist/components/EditorStatusBar.stories.svelte +44 -0
- package/dist/components/EditorStatusBar.stories.svelte.d.ts +27 -0
- package/dist/components/EditorStatusBar.svelte +99 -0
- package/dist/components/EditorStatusBar.svelte.d.ts +15 -0
- package/dist/components/IconButton.svelte +80 -0
- package/dist/components/IconButton.svelte.d.ts +30 -0
- package/dist/components/Input.svelte +74 -0
- package/dist/components/Input.svelte.d.ts +17 -0
- package/dist/components/LogoWordmark.svelte +113 -0
- package/dist/components/LogoWordmark.svelte.d.ts +26 -0
- package/dist/components/Navbar.svelte +78 -64
- package/dist/components/Navbar.svelte.d.ts +3 -0
- package/dist/components/NodeSidebar.svelte +48 -171
- package/dist/components/NodeStatusOverlay.svelte +94 -6
- package/dist/components/NodeSwapPicker.svelte +22 -38
- package/dist/components/PipelineStatus.svelte +22 -68
- package/dist/components/PipelineStatus.svelte.d.ts +3 -0
- package/dist/components/PortCoordinateTracker.svelte +5 -6
- package/dist/components/PortMappingRow.svelte +0 -2
- package/dist/components/SchemaForm.stories.svelte +1 -3
- package/dist/components/SchemaForm.svelte +22 -39
- package/dist/components/SchemaForm.svelte.d.ts +0 -8
- package/dist/components/Select.svelte +53 -0
- package/dist/components/Select.svelte.d.ts +15 -0
- package/dist/components/SettingsModal.svelte +8 -8
- package/dist/components/SettingsPanel.svelte +44 -10
- package/dist/components/SwapMappingEditor.svelte +67 -49
- package/dist/components/SwapMappingEditor.svelte.d.ts +0 -2
- package/dist/components/Textarea.svelte +39 -0
- package/dist/components/Textarea.svelte.d.ts +12 -0
- package/dist/components/ThemeToggle.svelte +15 -94
- package/dist/components/UniversalNode.svelte +45 -11
- package/dist/components/UniversalNode.svelte.d.ts +1 -1
- package/dist/components/WorkflowEditor.svelte +183 -162
- package/dist/components/WorkflowEditor.svelte.d.ts +39 -10
- package/dist/components/chat/AIChatPanel.svelte +99 -90
- package/dist/components/chat/AIChatPanel.svelte.d.ts +0 -4
- package/dist/components/chat/CommandPreview.svelte +2 -1
- package/dist/components/console/CommandConsole.svelte +7 -5
- package/dist/components/console/ConsoleAutocomplete.svelte +11 -12
- package/dist/components/console/ConsoleAutocomplete.svelte.d.ts +6 -0
- package/dist/components/console/ConsoleInput.svelte +18 -9
- package/dist/components/console/ConsoleOutput.svelte +4 -3
- package/dist/components/form/FormArray.svelte +42 -182
- package/dist/components/form/FormArray.svelte.d.ts +2 -1
- package/dist/components/form/FormAutocomplete.svelte +26 -21
- package/dist/components/form/FormCheckboxGroup.svelte +1 -5
- package/dist/components/form/FormCodeEditor.svelte +9 -7
- package/dist/components/form/FormField.svelte +22 -44
- package/dist/components/form/FormFieldLight.svelte +56 -50
- package/dist/components/form/FormFieldLight.svelte.d.ts +12 -0
- package/dist/components/form/FormFieldset.svelte +45 -11
- package/dist/components/form/FormMarkdownEditor.svelte +17 -9
- package/dist/components/form/FormNumberField.svelte +4 -36
- package/dist/components/form/FormPorts.svelte +262 -0
- package/dist/components/form/FormPorts.svelte.d.ts +13 -0
- package/dist/components/form/FormRangeField.svelte +62 -30
- package/dist/components/form/FormSelect.svelte +13 -75
- package/dist/components/form/FormTemplateEditor.svelte +17 -7
- package/dist/components/form/FormTextField.svelte +3 -35
- package/dist/components/form/FormTextarea.svelte +4 -39
- package/dist/components/form/FormToggle.svelte +5 -16
- package/dist/components/form/FormToggle.svelte.d.ts +4 -2
- package/dist/components/form/FormUISchemaRenderer.svelte +3 -1
- package/dist/components/form/resolveFieldType.d.ts +24 -0
- package/dist/components/form/resolveFieldType.js +55 -0
- package/dist/components/form/templateAutocomplete.js +1 -5
- package/dist/components/form/types.d.ts +1 -14
- package/dist/components/icons/CloseIcon.svelte +6 -0
- package/dist/components/icons/CloseIcon.svelte.d.ts +26 -0
- package/dist/components/icons/CommandLineIcon.svelte +15 -0
- package/dist/components/icons/CommandLineIcon.svelte.d.ts +26 -0
- package/dist/components/icons/MenuIcon.svelte +4 -0
- package/dist/components/icons/MenuIcon.svelte.d.ts +26 -0
- package/dist/components/icons/MenuOpenIcon.svelte +6 -0
- package/dist/components/icons/MenuOpenIcon.svelte.d.ts +26 -0
- package/dist/components/interrupt/ChoicePrompt.svelte +0 -10
- package/dist/components/interrupt/ConfirmationPrompt.svelte +0 -5
- package/dist/components/interrupt/FormPrompt.svelte +3 -2
- package/dist/components/interrupt/InterruptBubble.svelte +25 -27
- package/dist/components/interrupt/ReviewPrompt.svelte +10 -23
- package/dist/components/interrupt/TextInputPrompt.svelte +2 -7
- package/dist/components/layouts/MainLayout.svelte +24 -18
- package/dist/components/layouts/MainLayout.svelte.d.ts +4 -0
- package/dist/components/nodes/AtomNode.svelte +70 -72
- package/dist/components/nodes/AtomNode.svelte.d.ts +1 -1
- package/dist/components/nodes/GatewayNode.svelte +134 -172
- package/dist/components/nodes/GatewayNode.svelte.d.ts +1 -1
- package/dist/components/nodes/IdeaNode.svelte +79 -98
- package/dist/components/nodes/IdeaNode.svelte.d.ts +8 -4
- package/dist/components/nodes/NodeConfigButton.svelte +86 -0
- package/dist/components/nodes/NodeConfigButton.svelte.d.ts +15 -0
- package/dist/components/nodes/NotesNode.svelte +76 -85
- package/dist/components/nodes/NotesNode.svelte.d.ts +8 -4
- package/dist/components/nodes/SimpleNode.svelte +68 -137
- package/dist/components/nodes/SimpleNode.svelte.d.ts +4 -4
- package/dist/components/nodes/SquareNode.svelte +122 -169
- package/dist/components/nodes/SquareNode.svelte.d.ts +4 -4
- package/dist/components/nodes/TerminalNode.svelte +70 -127
- package/dist/components/nodes/TerminalNode.svelte.d.ts +4 -4
- package/dist/components/nodes/ToolNode.svelte +99 -104
- package/dist/components/nodes/ToolNode.svelte.d.ts +6 -6
- package/dist/components/nodes/WorkflowNode.svelte +145 -195
- package/dist/components/nodes/WorkflowNode.svelte.d.ts +1 -1
- package/dist/components/playground/ChatInput.svelte +11 -15
- package/dist/components/playground/ChatPanel.svelte +6 -49
- package/dist/components/playground/ChatPanel.svelte.d.ts +0 -14
- package/dist/components/playground/ControlPanel.svelte +134 -123
- package/dist/components/playground/ControlPanel.svelte.d.ts +3 -0
- package/dist/components/playground/ExecutionLogs.svelte +11 -9
- package/dist/components/playground/InputCollector.svelte +22 -57
- package/dist/components/playground/MessageStream.svelte +17 -23
- package/dist/components/playground/PipelineKanbanView.svelte +69 -8
- package/dist/components/playground/PipelineKanbanView.svelte.d.ts +2 -0
- package/dist/components/playground/PipelinePanel.svelte +31 -8
- package/dist/components/playground/PipelinePanel.svelte.d.ts +2 -0
- package/dist/components/playground/PipelineTableView.svelte +188 -44
- package/dist/components/playground/PipelineTableView.svelte.d.ts +2 -0
- package/dist/components/playground/Playground.svelte +154 -105
- package/dist/components/playground/Playground.svelte.d.ts +5 -0
- package/dist/components/playground/PlaygroundApp.svelte +12 -2
- package/dist/components/playground/PlaygroundApp.svelte.d.ts +6 -0
- package/dist/components/playground/PlaygroundModal.svelte +18 -3
- package/dist/components/playground/PlaygroundModal.svelte.d.ts +6 -0
- package/dist/components/playground/PlaygroundStudio.svelte +40 -37
- package/dist/components/playground/PlaygroundStudio.svelte.d.ts +6 -0
- package/dist/components/playground/SessionManager.svelte +9 -12
- package/dist/components/playground/pipelineViewUtils.svelte.d.ts +30 -1
- package/dist/components/playground/pipelineViewUtils.svelte.js +40 -3
- package/dist/components/surfaces/SurfaceOverlay.svelte +153 -0
- package/dist/components/surfaces/SurfaceOverlay.svelte.d.ts +14 -0
- package/dist/components/surfaces/TabbedSurface.svelte +133 -0
- package/dist/components/surfaces/TabbedSurface.svelte.d.ts +27 -0
- package/dist/config/endpoints.d.ts +23 -7
- package/dist/config/endpoints.js +30 -10
- package/dist/core/index.d.ts +6 -7
- package/dist/core/index.js +8 -12
- package/dist/display/index.d.ts +6 -3
- package/dist/display/index.js +7 -5
- package/dist/editor/index.d.ts +20 -21
- package/dist/editor/index.js +26 -36
- package/dist/form/code.d.ts +25 -15
- package/dist/form/code.js +44 -41
- package/dist/form/fieldRegistry.d.ts +17 -13
- package/dist/form/fieldRegistry.js +32 -12
- package/dist/form/full.d.ts +19 -14
- package/dist/form/full.js +26 -28
- package/dist/form/index.d.ts +3 -4
- package/dist/form/index.js +6 -5
- package/dist/form/markdown.d.ts +13 -8
- package/dist/form/markdown.js +22 -23
- package/dist/helpers/proximityConnect.d.ts +3 -2
- package/dist/helpers/proximityConnect.js +2 -5
- package/dist/helpers/workflowEditorHelper.d.ts +14 -5
- package/dist/helpers/workflowEditorHelper.js +32 -30
- package/dist/index.d.ts +28 -24
- package/dist/index.js +27 -50
- package/dist/messages/defaults.d.ts +2 -5
- package/dist/messages/defaults.js +3 -6
- package/dist/messages/index.d.ts +1 -2
- package/dist/messages/index.js +1 -2
- package/dist/mocks/app-forms.d.ts +6 -2
- package/dist/mocks/app-forms.js +11 -4
- package/dist/openapi/v1/openapi.yaml +38 -26
- package/dist/playground/index.d.ts +4 -5
- package/dist/playground/index.js +4 -32
- package/dist/playground/mount.d.ts +34 -5
- package/dist/playground/mount.js +58 -24
- package/dist/registry/{BaseRegistry.d.ts → BaseRegistry.svelte.d.ts} +22 -1
- package/dist/registry/{BaseRegistry.js → BaseRegistry.svelte.js} +37 -1
- package/dist/registry/builtinFormats.d.ts +9 -18
- package/dist/registry/builtinFormats.js +9 -39
- package/dist/registry/builtinNodeTypes.d.ts +53 -0
- package/dist/registry/builtinNodeTypes.js +67 -0
- package/dist/registry/builtinNodes.d.ts +2 -64
- package/dist/registry/builtinNodes.js +7 -103
- package/dist/registry/index.d.ts +3 -4
- package/dist/registry/index.js +4 -6
- package/dist/registry/nodeComponentRegistry.d.ts +184 -16
- package/dist/registry/nodeComponentRegistry.js +235 -17
- package/dist/registry/workflowFormatRegistry.d.ts +14 -9
- package/dist/registry/workflowFormatRegistry.js +24 -8
- package/dist/{schema → schemas}/index.d.ts +2 -2
- package/dist/{schema → schemas}/index.js +2 -2
- package/dist/schemas/v1/workflow.schema.json +19 -17
- package/dist/services/agentSpecExecutionService.d.ts +0 -2
- package/dist/services/agentSpecExecutionService.js +0 -3
- package/dist/services/apiVariableService.d.ts +2 -1
- package/dist/services/apiVariableService.js +16 -47
- package/dist/services/autoSaveService.d.ts +7 -0
- package/dist/services/autoSaveService.js +6 -4
- package/dist/services/categoriesApi.js +3 -6
- package/dist/services/chatService.d.ts +9 -4
- package/dist/services/chatService.js +23 -28
- package/dist/services/draftStorage.d.ts +129 -13
- package/dist/services/draftStorage.js +185 -37
- package/dist/services/dynamicSchemaService.d.ts +33 -5
- package/dist/services/dynamicSchemaService.js +67 -55
- package/dist/services/globalSave.d.ts +13 -12
- package/dist/services/globalSave.js +29 -51
- package/dist/services/historyService.d.ts +39 -11
- package/dist/services/historyService.js +60 -18
- package/dist/services/interruptService.d.ts +15 -9
- package/dist/services/interruptService.js +35 -37
- package/dist/services/nodeExecutionService.d.ts +18 -3
- package/dist/services/nodeExecutionService.js +71 -45
- package/dist/services/playgroundService.d.ts +16 -10
- package/dist/services/playgroundService.js +42 -43
- package/dist/services/portConfigApi.js +3 -6
- package/dist/services/settingsService.d.ts +9 -4
- package/dist/services/settingsService.js +23 -12
- package/dist/services/variableService.d.ts +2 -1
- package/dist/services/variableService.js +2 -2
- package/dist/services/workflowStorage.js +6 -6
- package/dist/skins/drafter.d.ts +30 -0
- package/dist/skins/drafter.js +198 -0
- package/dist/skins/index.d.ts +2 -1
- package/dist/skins/index.js +4 -2
- package/dist/stores/apiContext.d.ts +56 -0
- package/dist/stores/apiContext.js +80 -0
- package/dist/stores/categoriesStore.svelte.d.ts +28 -23
- package/dist/stores/categoriesStore.svelte.js +69 -64
- package/dist/stores/getInstance.svelte.d.ts +39 -0
- package/dist/stores/getInstance.svelte.js +65 -0
- package/dist/stores/historyStore.svelte.d.ts +89 -91
- package/dist/stores/historyStore.svelte.js +159 -158
- package/dist/stores/instanceContainer.svelte.d.ts +111 -0
- package/dist/stores/instanceContainer.svelte.js +119 -0
- package/dist/stores/interruptStore.svelte.d.ts +112 -82
- package/dist/stores/interruptStore.svelte.js +253 -226
- package/dist/stores/pipelinePanelStore.svelte.d.ts +27 -3
- package/dist/stores/pipelinePanelStore.svelte.js +61 -14
- package/dist/stores/playgroundStore.svelte.d.ts +169 -222
- package/dist/stores/playgroundStore.svelte.js +513 -580
- package/dist/stores/portCoordinateStore.svelte.d.ts +57 -51
- package/dist/stores/portCoordinateStore.svelte.js +109 -98
- package/dist/stores/settingsStore.svelte.d.ts +17 -1
- package/dist/stores/settingsStore.svelte.js +79 -12
- package/dist/stores/workflowStore.svelte.d.ts +212 -210
- package/dist/stores/workflowStore.svelte.js +527 -502
- package/dist/stories/EdgeDecorator.svelte +5 -2
- package/dist/stories/NodeDecorator.svelte +5 -3
- package/dist/styles/base.css +285 -14
- package/dist/styles/tokens.css +60 -2
- package/dist/svelte-app.d.ts +78 -11
- package/dist/svelte-app.js +210 -141
- package/dist/themes/drafter.d.ts +2 -0
- package/dist/themes/drafter.js +15 -0
- package/dist/themes/index.d.ts +2 -1
- package/dist/themes/index.js +8 -2
- package/dist/types/auth.d.ts +9 -51
- package/dist/types/auth.js +4 -54
- package/dist/types/events.d.ts +24 -3
- package/dist/types/events.js +2 -1
- package/dist/types/index.d.ts +117 -32
- package/dist/types/index.js +0 -1
- package/dist/types/navbar.d.ts +7 -0
- package/dist/types/playground.d.ts +18 -3
- package/dist/types/settings.d.ts +30 -1
- package/dist/types/settings.js +5 -2
- package/dist/types/skin.d.ts +1 -1
- package/dist/types/theme.d.ts +16 -2
- package/dist/types/uischema.d.ts +5 -0
- package/dist/utils/colors.d.ts +74 -21
- package/dist/utils/colors.js +92 -68
- package/dist/utils/connections.d.ts +9 -15
- package/dist/utils/connections.js +33 -88
- package/dist/utils/duration.d.ts +13 -0
- package/dist/utils/duration.js +45 -0
- package/dist/utils/edgeStyling.js +9 -5
- package/dist/utils/fetchWithAuth.d.ts +36 -15
- package/dist/utils/fetchWithAuth.js +53 -23
- package/dist/utils/icons.d.ts +5 -2
- package/dist/utils/icons.js +6 -5
- package/dist/utils/nodeIds.d.ts +1 -1
- package/dist/utils/nodeIds.js +1 -1
- package/dist/utils/nodeSwap.d.ts +6 -2
- package/dist/utils/nodeSwap.js +62 -129
- package/dist/utils/nodeTypes.d.ts +17 -8
- package/dist/utils/nodeTypes.js +27 -20
- package/dist/utils/performanceUtils.js +7 -0
- package/dist/utils/portUtils.d.ts +47 -11
- package/dist/utils/portUtils.js +67 -14
- package/dist/utils/portal.d.ts +18 -0
- package/dist/utils/portal.js +34 -0
- package/dist/utils/schemaMerge.d.ts +25 -0
- package/dist/utils/schemaMerge.js +61 -0
- package/package.json +7 -5
- package/dist/messages/deprecation.d.ts +0 -20
- package/dist/messages/deprecation.js +0 -33
- package/dist/registry/plugin.d.ts +0 -215
- package/dist/registry/plugin.js +0 -249
- package/dist/services/api.d.ts +0 -129
- package/dist/services/api.js +0 -217
|
@@ -19,8 +19,12 @@
|
|
|
19
19
|
|
|
20
20
|
<script lang="ts">
|
|
21
21
|
import Icon from '@iconify/svelte';
|
|
22
|
+
import Input from '../Input.svelte';
|
|
23
|
+
import Select from '../Select.svelte';
|
|
24
|
+
import Textarea from '../Textarea.svelte';
|
|
25
|
+
import IconButton from '../IconButton.svelte';
|
|
22
26
|
import type { FieldSchema } from './types.js';
|
|
23
|
-
import { m
|
|
27
|
+
import { m } from '../../messages/index.js';
|
|
24
28
|
|
|
25
29
|
interface Props {
|
|
26
30
|
/** Field identifier */
|
|
@@ -34,7 +38,8 @@
|
|
|
34
38
|
/** Maximum number of items allowed */
|
|
35
39
|
maxItems?: number;
|
|
36
40
|
/**
|
|
37
|
-
*
|
|
41
|
+
* Per-instance label for the add button (e.g. "Add Header" derived from
|
|
42
|
+
* the item schema title). Falls back to the global `messages.form.array.add`.
|
|
38
43
|
*/
|
|
39
44
|
addLabel?: string;
|
|
40
45
|
/** Whether the field is disabled */
|
|
@@ -54,11 +59,6 @@
|
|
|
54
59
|
onChange
|
|
55
60
|
}: Props = $props();
|
|
56
61
|
|
|
57
|
-
// svelte-ignore state_referenced_locally — deprecation warns once per mount; later prop rebinds aren't relevant
|
|
58
|
-
if (addLabel !== undefined) {
|
|
59
|
-
warnDeprecatedProp('FormArray', 'addLabel', 'messages.form.array.add');
|
|
60
|
-
}
|
|
61
|
-
|
|
62
62
|
// Hoist the array branch — every {#each} iteration would otherwise re-walk
|
|
63
63
|
// `m().form.array.*` for ~6 keys per item. One getter call instead of N×6.
|
|
64
64
|
const t = $derived(m().form.array);
|
|
@@ -288,40 +288,37 @@
|
|
|
288
288
|
<!-- Action buttons group -->
|
|
289
289
|
<div class="form-array__actions">
|
|
290
290
|
<!-- Move Up button -->
|
|
291
|
-
<
|
|
292
|
-
|
|
293
|
-
class="form-array__action-btn form-array__action-btn--move"
|
|
291
|
+
<IconButton
|
|
292
|
+
variant="primary"
|
|
294
293
|
onclick={() => moveItemUp(index)}
|
|
295
294
|
disabled={index === 0 || disabled}
|
|
296
|
-
|
|
295
|
+
ariaLabel={t.moveItemUp({ n: index + 1 })}
|
|
297
296
|
title={t.moveUp}
|
|
298
297
|
>
|
|
299
298
|
<Icon icon="heroicons:arrow-up" />
|
|
300
|
-
</
|
|
299
|
+
</IconButton>
|
|
301
300
|
|
|
302
301
|
<!-- Move Down button -->
|
|
303
|
-
<
|
|
304
|
-
|
|
305
|
-
class="form-array__action-btn form-array__action-btn--move"
|
|
302
|
+
<IconButton
|
|
303
|
+
variant="primary"
|
|
306
304
|
onclick={() => moveItemDown(index)}
|
|
307
305
|
disabled={index === items.length - 1 || disabled}
|
|
308
|
-
|
|
306
|
+
ariaLabel={t.moveItemDown({ n: index + 1 })}
|
|
309
307
|
title={t.moveDown}
|
|
310
308
|
>
|
|
311
309
|
<Icon icon="heroicons:arrow-down" />
|
|
312
|
-
</
|
|
310
|
+
</IconButton>
|
|
313
311
|
|
|
314
312
|
<!-- Delete button -->
|
|
315
|
-
<
|
|
316
|
-
|
|
317
|
-
class="form-array__action-btn form-array__action-btn--delete"
|
|
313
|
+
<IconButton
|
|
314
|
+
variant="danger"
|
|
318
315
|
onclick={() => removeItem(index)}
|
|
319
316
|
disabled={!canRemoveItem || disabled}
|
|
320
|
-
|
|
317
|
+
ariaLabel={t.deleteItem({ n: index + 1 })}
|
|
321
318
|
title={t.delete}
|
|
322
319
|
>
|
|
323
320
|
<Icon icon="heroicons:trash" />
|
|
324
|
-
</
|
|
321
|
+
</IconButton>
|
|
325
322
|
</div>
|
|
326
323
|
</div>
|
|
327
324
|
|
|
@@ -334,18 +331,16 @@
|
|
|
334
331
|
<!-- Simple type: render inline input -->
|
|
335
332
|
{#if itemSchema.type === 'string'}
|
|
336
333
|
{#if itemSchema.format === 'multiline'}
|
|
337
|
-
<
|
|
338
|
-
class="form-array__input form-array__textarea"
|
|
334
|
+
<Textarea
|
|
339
335
|
value={String(item ?? '')}
|
|
340
336
|
placeholder={itemSchema.placeholder ?? ''}
|
|
341
337
|
rows={3}
|
|
342
338
|
oninput={(e) => updateItem(index, e.currentTarget.value)}
|
|
343
339
|
{disabled}
|
|
344
|
-
|
|
340
|
+
/>
|
|
345
341
|
{:else}
|
|
346
|
-
<
|
|
342
|
+
<Input
|
|
347
343
|
type="text"
|
|
348
|
-
class="form-array__input"
|
|
349
344
|
value={String(item ?? '')}
|
|
350
345
|
placeholder={itemSchema.placeholder ?? ''}
|
|
351
346
|
oninput={(e) => updateItem(index, e.currentTarget.value)}
|
|
@@ -353,9 +348,9 @@
|
|
|
353
348
|
/>
|
|
354
349
|
{/if}
|
|
355
350
|
{:else if itemSchema.type === 'number' || itemSchema.type === 'integer'}
|
|
356
|
-
<
|
|
351
|
+
<Input
|
|
357
352
|
type="number"
|
|
358
|
-
class="
|
|
353
|
+
class="flowdrop-input--numeric"
|
|
359
354
|
value={item as number}
|
|
360
355
|
placeholder={itemSchema.placeholder ?? ''}
|
|
361
356
|
min={itemSchema.minimum}
|
|
@@ -384,21 +379,19 @@
|
|
|
384
379
|
</label>
|
|
385
380
|
{:else if itemSchema.enum}
|
|
386
381
|
<!-- Enum: render select -->
|
|
387
|
-
<
|
|
388
|
-
class="form-array__select"
|
|
382
|
+
<Select
|
|
389
383
|
value={String(item ?? '')}
|
|
390
384
|
onchange={(e) => updateItem(index, e.currentTarget.value)}
|
|
391
385
|
{disabled}
|
|
392
386
|
>
|
|
393
|
-
{#each itemSchema.enum as option}
|
|
387
|
+
{#each itemSchema.enum as option (option)}
|
|
394
388
|
<option value={String(option)}>{String(option)}</option>
|
|
395
389
|
{/each}
|
|
396
|
-
</
|
|
390
|
+
</Select>
|
|
397
391
|
{:else}
|
|
398
392
|
<!-- Fallback to text -->
|
|
399
|
-
<
|
|
393
|
+
<Input
|
|
400
394
|
type="text"
|
|
401
|
-
class="form-array__input"
|
|
402
395
|
value={String(item ?? '')}
|
|
403
396
|
placeholder={itemSchema.placeholder ?? ''}
|
|
404
397
|
oninput={(e) => updateItem(index, e.currentTarget.value)}
|
|
@@ -429,34 +422,31 @@
|
|
|
429
422
|
|
|
430
423
|
<div class="form-array__subform-input">
|
|
431
424
|
{#if propFieldSchema.enum}
|
|
432
|
-
<
|
|
425
|
+
<Select
|
|
433
426
|
id="{id}-{index}-{propKey}"
|
|
434
|
-
class="form-array__select"
|
|
435
427
|
value={String(propValue ?? '')}
|
|
436
428
|
onchange={(e) =>
|
|
437
429
|
updateObjectProperty(index, propKey, e.currentTarget.value)}
|
|
438
430
|
{disabled}
|
|
439
431
|
>
|
|
440
|
-
{#each propFieldSchema.enum as option}
|
|
432
|
+
{#each propFieldSchema.enum as option (option)}
|
|
441
433
|
<option value={String(option)}>{String(option)}</option>
|
|
442
434
|
{/each}
|
|
443
|
-
</
|
|
435
|
+
</Select>
|
|
444
436
|
{:else if propFieldSchema.type === 'string' && propFieldSchema.format === 'multiline'}
|
|
445
|
-
<
|
|
437
|
+
<Textarea
|
|
446
438
|
id="{id}-{index}-{propKey}"
|
|
447
|
-
class="form-array__input form-array__textarea"
|
|
448
439
|
value={String(propValue ?? '')}
|
|
449
440
|
placeholder={propFieldSchema.placeholder ?? ''}
|
|
450
441
|
rows={3}
|
|
451
442
|
oninput={(e) =>
|
|
452
443
|
updateObjectProperty(index, propKey, e.currentTarget.value)}
|
|
453
444
|
{disabled}
|
|
454
|
-
|
|
445
|
+
/>
|
|
455
446
|
{:else if propFieldSchema.type === 'string'}
|
|
456
|
-
<
|
|
447
|
+
<Input
|
|
457
448
|
id="{id}-{index}-{propKey}"
|
|
458
449
|
type="text"
|
|
459
|
-
class="form-array__input"
|
|
460
450
|
value={String(propValue ?? '')}
|
|
461
451
|
placeholder={propFieldSchema.placeholder ?? ''}
|
|
462
452
|
oninput={(e) =>
|
|
@@ -464,10 +454,10 @@
|
|
|
464
454
|
{disabled}
|
|
465
455
|
/>
|
|
466
456
|
{:else if propFieldSchema.type === 'number' || propFieldSchema.type === 'integer'}
|
|
467
|
-
<
|
|
457
|
+
<Input
|
|
468
458
|
id="{id}-{index}-{propKey}"
|
|
469
459
|
type="number"
|
|
470
|
-
class="
|
|
460
|
+
class="flowdrop-input--numeric"
|
|
471
461
|
value={propValue as number}
|
|
472
462
|
placeholder={propFieldSchema.placeholder ?? ''}
|
|
473
463
|
min={propFieldSchema.minimum}
|
|
@@ -497,10 +487,9 @@
|
|
|
497
487
|
</span>
|
|
498
488
|
</label>
|
|
499
489
|
{:else}
|
|
500
|
-
<
|
|
490
|
+
<Input
|
|
501
491
|
id="{id}-{index}-{propKey}"
|
|
502
492
|
type="text"
|
|
503
|
-
class="form-array__input"
|
|
504
493
|
value={String(propValue ?? '')}
|
|
505
494
|
placeholder={propFieldSchema.placeholder ?? ''}
|
|
506
495
|
oninput={(e) =>
|
|
@@ -600,7 +589,7 @@
|
|
|
600
589
|
flex-direction: column;
|
|
601
590
|
background-color: var(--fd-muted);
|
|
602
591
|
border: 1px solid var(--fd-border);
|
|
603
|
-
border-radius: var(--fd-radius
|
|
592
|
+
border-radius: var(--fd-control-radius);
|
|
604
593
|
overflow: hidden;
|
|
605
594
|
animation: itemFadeIn 0.25s ease-out forwards;
|
|
606
595
|
opacity: 0;
|
|
@@ -674,9 +663,7 @@
|
|
|
674
663
|
}
|
|
675
664
|
|
|
676
665
|
.form-array__item-toggle:focus-visible {
|
|
677
|
-
outline: none;
|
|
678
666
|
border-color: var(--fd-primary);
|
|
679
|
-
box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.2);
|
|
680
667
|
}
|
|
681
668
|
|
|
682
669
|
.form-array__item-toggle :global(svg) {
|
|
@@ -703,67 +690,8 @@
|
|
|
703
690
|
margin-left: auto;
|
|
704
691
|
}
|
|
705
692
|
|
|
706
|
-
.
|
|
707
|
-
|
|
708
|
-
align-items: center;
|
|
709
|
-
justify-content: center;
|
|
710
|
-
width: 2rem;
|
|
711
|
-
height: 2rem;
|
|
712
|
-
padding: 0;
|
|
713
|
-
border: 1px solid transparent;
|
|
714
|
-
border-radius: 0.375rem;
|
|
715
|
-
cursor: pointer;
|
|
716
|
-
transition: all 0.15s;
|
|
717
|
-
}
|
|
718
|
-
|
|
719
|
-
.form-array__action-btn :global(svg) {
|
|
720
|
-
width: 1rem;
|
|
721
|
-
height: 1rem;
|
|
722
|
-
}
|
|
723
|
-
|
|
724
|
-
.form-array__action-btn:focus-visible {
|
|
725
|
-
outline: none;
|
|
726
|
-
box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.3);
|
|
727
|
-
}
|
|
728
|
-
|
|
729
|
-
.form-array__action-btn:disabled {
|
|
730
|
-
opacity: 0.35;
|
|
731
|
-
cursor: not-allowed;
|
|
732
|
-
}
|
|
733
|
-
|
|
734
|
-
/* Move Up/Down buttons - Blue semantic color */
|
|
735
|
-
.form-array__action-btn--move {
|
|
736
|
-
background-color: var(--fd-primary-muted);
|
|
737
|
-
border-color: var(--fd-primary);
|
|
738
|
-
color: var(--fd-primary-hover);
|
|
739
|
-
}
|
|
740
|
-
|
|
741
|
-
.form-array__action-btn--move:hover:not(:disabled) {
|
|
742
|
-
background-color: var(--fd-primary-muted);
|
|
743
|
-
border-color: var(--fd-primary-hover);
|
|
744
|
-
color: var(--fd-primary-hover);
|
|
745
|
-
}
|
|
746
|
-
|
|
747
|
-
.form-array__action-btn--move:active:not(:disabled) {
|
|
748
|
-
background-color: var(--fd-primary);
|
|
749
|
-
}
|
|
750
|
-
|
|
751
|
-
/* Delete button - Red/Warning semantic color */
|
|
752
|
-
.form-array__action-btn--delete {
|
|
753
|
-
background-color: var(--fd-error-muted);
|
|
754
|
-
border-color: var(--fd-error);
|
|
755
|
-
color: var(--fd-error);
|
|
756
|
-
}
|
|
757
|
-
|
|
758
|
-
.form-array__action-btn--delete:hover:not(:disabled) {
|
|
759
|
-
background-color: var(--fd-error-muted);
|
|
760
|
-
border-color: var(--fd-error-hover);
|
|
761
|
-
color: var(--fd-error-hover);
|
|
762
|
-
}
|
|
763
|
-
|
|
764
|
-
.form-array__action-btn--delete:active:not(:disabled) {
|
|
765
|
-
background-color: var(--fd-error);
|
|
766
|
-
}
|
|
693
|
+
/* Action buttons (move/delete) now render through IconButton.svelte —
|
|
694
|
+
geometry + semantic tints live in base.css (.flowdrop-btn--icon*). */
|
|
767
695
|
|
|
768
696
|
/* ============================================
|
|
769
697
|
ITEM CONTENT
|
|
@@ -783,69 +711,6 @@
|
|
|
783
711
|
INPUTS (Simple Types)
|
|
784
712
|
============================================ */
|
|
785
713
|
|
|
786
|
-
.form-array__input {
|
|
787
|
-
width: 100%;
|
|
788
|
-
padding: 0.5rem 0.75rem;
|
|
789
|
-
border: 1px solid var(--fd-border);
|
|
790
|
-
border-radius: var(--fd-radius-md);
|
|
791
|
-
font-size: var(--fd-text-sm);
|
|
792
|
-
font-family: inherit;
|
|
793
|
-
color: var(--fd-foreground);
|
|
794
|
-
background-color: var(--fd-background);
|
|
795
|
-
transition: all var(--fd-transition-normal);
|
|
796
|
-
}
|
|
797
|
-
|
|
798
|
-
.form-array__input::placeholder {
|
|
799
|
-
color: var(--fd-muted-foreground);
|
|
800
|
-
}
|
|
801
|
-
|
|
802
|
-
.form-array__input:hover {
|
|
803
|
-
border-color: var(--fd-border-strong);
|
|
804
|
-
}
|
|
805
|
-
|
|
806
|
-
.form-array__input:focus {
|
|
807
|
-
outline: none;
|
|
808
|
-
border-color: var(--fd-primary);
|
|
809
|
-
box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.1);
|
|
810
|
-
}
|
|
811
|
-
|
|
812
|
-
.form-array__input--number {
|
|
813
|
-
font-variant-numeric: tabular-nums;
|
|
814
|
-
}
|
|
815
|
-
|
|
816
|
-
.form-array__textarea {
|
|
817
|
-
resize: vertical;
|
|
818
|
-
min-height: 4rem;
|
|
819
|
-
line-height: 1.5;
|
|
820
|
-
}
|
|
821
|
-
|
|
822
|
-
.form-array__select {
|
|
823
|
-
width: 100%;
|
|
824
|
-
padding: 0.5rem 2rem 0.5rem 0.75rem;
|
|
825
|
-
border: 1px solid var(--fd-border);
|
|
826
|
-
border-radius: var(--fd-radius-md);
|
|
827
|
-
font-size: var(--fd-text-sm);
|
|
828
|
-
font-family: inherit;
|
|
829
|
-
color: var(--fd-foreground);
|
|
830
|
-
background-color: var(--fd-background);
|
|
831
|
-
cursor: pointer;
|
|
832
|
-
appearance: none;
|
|
833
|
-
background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%239ca3af'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M19 9l-7 7-7-7'%3E%3C/path%3E%3C/svg%3E");
|
|
834
|
-
background-repeat: no-repeat;
|
|
835
|
-
background-position: right 0.5rem center;
|
|
836
|
-
background-size: 1rem;
|
|
837
|
-
}
|
|
838
|
-
|
|
839
|
-
.form-array__select:hover {
|
|
840
|
-
border-color: var(--fd-border-strong);
|
|
841
|
-
}
|
|
842
|
-
|
|
843
|
-
.form-array__select:focus {
|
|
844
|
-
outline: none;
|
|
845
|
-
border-color: var(--fd-primary);
|
|
846
|
-
box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.1);
|
|
847
|
-
}
|
|
848
|
-
|
|
849
714
|
/* ============================================
|
|
850
715
|
TOGGLE (Boolean in Array)
|
|
851
716
|
============================================ */
|
|
@@ -962,7 +827,7 @@
|
|
|
962
827
|
padding: 2rem 1rem;
|
|
963
828
|
background-color: var(--fd-muted);
|
|
964
829
|
border: 2px dashed var(--fd-border-strong);
|
|
965
|
-
border-radius: var(--fd-radius
|
|
830
|
+
border-radius: var(--fd-control-radius);
|
|
966
831
|
}
|
|
967
832
|
|
|
968
833
|
.form-array__empty :global(svg) {
|
|
@@ -990,7 +855,7 @@
|
|
|
990
855
|
gap: 0.5rem;
|
|
991
856
|
padding: 0.625rem 1rem;
|
|
992
857
|
border: 1px solid var(--fd-success);
|
|
993
|
-
border-radius: var(--fd-radius
|
|
858
|
+
border-radius: var(--fd-control-radius);
|
|
994
859
|
background-color: var(--fd-success-muted);
|
|
995
860
|
color: var(--fd-success-hover);
|
|
996
861
|
font-size: 0.8125rem;
|
|
@@ -1006,11 +871,6 @@
|
|
|
1006
871
|
color: var(--fd-success-hover);
|
|
1007
872
|
}
|
|
1008
873
|
|
|
1009
|
-
.form-array__add-btn:focus-visible {
|
|
1010
|
-
outline: none;
|
|
1011
|
-
box-shadow: 0 0 0 2px rgba(34, 197, 94, 0.3);
|
|
1012
|
-
}
|
|
1013
|
-
|
|
1014
874
|
.form-array__add-btn:active:not(:disabled) {
|
|
1015
875
|
background-color: var(--fd-success);
|
|
1016
876
|
}
|
|
@@ -11,7 +11,8 @@ interface Props {
|
|
|
11
11
|
/** Maximum number of items allowed */
|
|
12
12
|
maxItems?: number;
|
|
13
13
|
/**
|
|
14
|
-
*
|
|
14
|
+
* Per-instance label for the add button (e.g. "Add Header" derived from
|
|
15
|
+
* the item schema title). Falls back to the global `messages.form.array.add`.
|
|
15
16
|
*/
|
|
16
17
|
addLabel?: string;
|
|
17
18
|
/** Whether the field is disabled */
|
|
@@ -25,7 +25,7 @@
|
|
|
25
25
|
import Icon from '@iconify/svelte';
|
|
26
26
|
import type { AutocompleteConfig, AuthProvider } from '../../types/index.js';
|
|
27
27
|
import type { FieldOption } from './types.js';
|
|
28
|
-
import {
|
|
28
|
+
import { authenticatedFetch } from '../../utils/fetchWithAuth.js';
|
|
29
29
|
import { logger } from '../../utils/logger.js';
|
|
30
30
|
import { m } from '../../messages/index.js';
|
|
31
31
|
|
|
@@ -121,7 +121,8 @@
|
|
|
121
121
|
// Stable fingerprint — any change triggers selection clearing.
|
|
122
122
|
// JSON.stringify gives a canonical string without null-byte ambiguity.
|
|
123
123
|
const depFingerprint = $derived(JSON.stringify(depParamValues));
|
|
124
|
-
//
|
|
124
|
+
// intentional initial snapshot; the effect below tracks subsequent changes
|
|
125
|
+
// svelte-ignore state_referenced_locally
|
|
125
126
|
let prevDepFingerprint = depFingerprint;
|
|
126
127
|
|
|
127
128
|
$effect(() => {
|
|
@@ -135,9 +136,9 @@
|
|
|
135
136
|
});
|
|
136
137
|
|
|
137
138
|
// Generate unique IDs for accessibility
|
|
138
|
-
//
|
|
139
|
-
const listboxId = `${id}-listbox`;
|
|
139
|
+
// id prop never changes
|
|
140
140
|
// svelte-ignore state_referenced_locally
|
|
141
|
+
const listboxId = `${id}-listbox`;
|
|
141
142
|
const getOptionId = (index: number): string => `${id}-option-${index}`;
|
|
142
143
|
|
|
143
144
|
/**
|
|
@@ -244,16 +245,15 @@
|
|
|
244
245
|
|
|
245
246
|
let timeoutId: ReturnType<typeof setTimeout> | null = null;
|
|
246
247
|
try {
|
|
247
|
-
// Build headers with authentication (call getter to get current value)
|
|
248
|
-
const headers = await buildFetchHeaders(getAuthProvider?.());
|
|
249
|
-
|
|
250
248
|
timeoutId = setTimeout(() => controller.abort(), 5000);
|
|
251
249
|
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
250
|
+
// authenticatedFetch merges auth headers (call getter for current value)
|
|
251
|
+
// and applies the 401/403 lifecycle consistently with the rest of the lib.
|
|
252
|
+
const response = await authenticatedFetch(
|
|
253
|
+
buildUrl(query),
|
|
254
|
+
{ method: 'GET', signal: controller.signal },
|
|
255
|
+
{ authProvider: getAuthProvider?.() }
|
|
256
|
+
);
|
|
257
257
|
|
|
258
258
|
if (!response.ok) {
|
|
259
259
|
throw new Error(`HTTP ${response.status}: ${response.statusText}`);
|
|
@@ -639,7 +639,7 @@
|
|
|
639
639
|
class:form-autocomplete--has-value={selectedValues.length > 0}
|
|
640
640
|
>
|
|
641
641
|
<!-- Main input container styled like a textfield/textarea -->
|
|
642
|
-
<!--
|
|
642
|
+
<!-- role="presentation"; keyboard interaction is handled by the <input> inside -->
|
|
643
643
|
<div
|
|
644
644
|
class="form-autocomplete__field"
|
|
645
645
|
class:form-autocomplete__field--focused={isOpen}
|
|
@@ -726,7 +726,7 @@
|
|
|
726
726
|
</div>
|
|
727
727
|
|
|
728
728
|
<!-- Dropdown popover (uses Popover API to render in top layer, bypassing stacking contexts) -->
|
|
729
|
-
<!--
|
|
729
|
+
<!-- role="presentation" container; onmousedown prevents focus loss from input -->
|
|
730
730
|
<div
|
|
731
731
|
bind:this={popoverElement}
|
|
732
732
|
id={listboxId}
|
|
@@ -757,7 +757,8 @@
|
|
|
757
757
|
</li>
|
|
758
758
|
{:else}
|
|
759
759
|
{#each suggestions as option, index (option.value)}
|
|
760
|
-
<!--
|
|
760
|
+
<!-- WAI-ARIA combobox: keyboard nav handled on input, not individual options -->
|
|
761
|
+
<!-- svelte-ignore a11y_click_events_have_key_events -->
|
|
761
762
|
<li
|
|
762
763
|
id={getOptionId(index)}
|
|
763
764
|
class="form-autocomplete__option"
|
|
@@ -786,7 +787,6 @@
|
|
|
786
787
|
}
|
|
787
788
|
|
|
788
789
|
.form-autocomplete--disabled {
|
|
789
|
-
opacity: 0.6;
|
|
790
790
|
pointer-events: none;
|
|
791
791
|
}
|
|
792
792
|
|
|
@@ -803,7 +803,7 @@
|
|
|
803
803
|
font-size: var(--fd-text-sm);
|
|
804
804
|
font-family: inherit;
|
|
805
805
|
color: var(--fd-foreground);
|
|
806
|
-
background-color: var(--fd-
|
|
806
|
+
background-color: var(--fd-background);
|
|
807
807
|
transition: all var(--fd-transition-normal);
|
|
808
808
|
box-shadow: var(--fd-shadow-sm);
|
|
809
809
|
cursor: text;
|
|
@@ -816,11 +816,16 @@
|
|
|
816
816
|
}
|
|
817
817
|
|
|
818
818
|
.form-autocomplete__field--focused {
|
|
819
|
-
border-color: var(--fd-
|
|
819
|
+
border-color: var(--fd-ring);
|
|
820
820
|
background-color: var(--fd-background);
|
|
821
|
-
|
|
822
|
-
|
|
823
|
-
|
|
821
|
+
}
|
|
822
|
+
|
|
823
|
+
.form-autocomplete--disabled .form-autocomplete__field {
|
|
824
|
+
background-color: var(--fd-muted);
|
|
825
|
+
border-color: var(--fd-border-muted);
|
|
826
|
+
color: var(--fd-muted-foreground);
|
|
827
|
+
cursor: not-allowed;
|
|
828
|
+
opacity: 1;
|
|
824
829
|
}
|
|
825
830
|
|
|
826
831
|
/* Multiple mode - textarea-like styling */
|
|
@@ -86,7 +86,7 @@
|
|
|
86
86
|
padding: 0.75rem;
|
|
87
87
|
background-color: var(--fd-muted);
|
|
88
88
|
border: 1px solid var(--fd-border);
|
|
89
|
-
border-radius: var(--fd-radius
|
|
89
|
+
border-radius: var(--fd-control-radius);
|
|
90
90
|
}
|
|
91
91
|
|
|
92
92
|
.form-checkbox-item {
|
|
@@ -143,10 +143,6 @@
|
|
|
143
143
|
transform: scale(1);
|
|
144
144
|
}
|
|
145
145
|
|
|
146
|
-
.form-checkbox__input:focus-visible + .form-checkbox__custom {
|
|
147
|
-
box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.2);
|
|
148
|
-
}
|
|
149
|
-
|
|
150
146
|
.form-checkbox__label {
|
|
151
147
|
font-size: var(--fd-text-sm);
|
|
152
148
|
color: var(--fd-foreground);
|
|
@@ -364,7 +364,9 @@
|
|
|
364
364
|
border: 1px solid var(--fd-border);
|
|
365
365
|
border-radius: var(--fd-radius-lg);
|
|
366
366
|
overflow: hidden;
|
|
367
|
-
|
|
367
|
+
/* Match plain form fields (FormTextField/Textarea/Select): rest on the
|
|
368
|
+
input surface, not the recessed --fd-muted. */
|
|
369
|
+
background-color: var(--fd-background);
|
|
368
370
|
transition: all var(--fd-transition-normal);
|
|
369
371
|
box-shadow: var(--fd-shadow-sm);
|
|
370
372
|
}
|
|
@@ -374,12 +376,15 @@
|
|
|
374
376
|
background-color: var(--fd-background);
|
|
375
377
|
}
|
|
376
378
|
|
|
379
|
+
/* Compound widget: the focusable CodeMirror lives inside this container, so
|
|
380
|
+
the standard ring (centralized for simple elements) is drawn here via
|
|
381
|
+
:focus-within using the same --fd-ring tokens. Outline paints outside the
|
|
382
|
+
container's overflow, so it isn't clipped. */
|
|
377
383
|
.form-code-editor__container:focus-within {
|
|
378
384
|
border-color: var(--fd-primary);
|
|
379
385
|
background-color: var(--fd-background);
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
var(--fd-shadow-sm);
|
|
386
|
+
outline: var(--fd-ring-width) solid var(--fd-ring);
|
|
387
|
+
outline-offset: var(--fd-ring-offset);
|
|
383
388
|
}
|
|
384
389
|
|
|
385
390
|
.form-code-editor--error .form-code-editor__container {
|
|
@@ -388,9 +393,6 @@
|
|
|
388
393
|
|
|
389
394
|
.form-code-editor--error .form-code-editor__container:focus-within {
|
|
390
395
|
border-color: var(--fd-error);
|
|
391
|
-
box-shadow:
|
|
392
|
-
0 0 0 3px rgba(239, 68, 68, 0.12),
|
|
393
|
-
var(--fd-shadow-sm);
|
|
394
396
|
}
|
|
395
397
|
|
|
396
398
|
/* Dark theme overrides */
|