@parallelworks/ui 0.43.0 → 0.45.0
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 +348 -25
- package/dist/ai/agent/diff.d.ts +2 -1
- package/dist/ai/agent/diff.js +4 -12
- package/dist/ai/agent/diffHighlight.d.ts +1 -1
- package/dist/ai/agent/diffHighlight.js +4 -3
- package/dist/ai/agent/index.d.ts +2 -1
- package/dist/ai/agent/toolStrings.d.ts +37 -0
- package/dist/ai/agent/toolStrings.js +35 -0
- package/dist/ai/agent/toolfmt.d.ts +8 -3
- package/dist/ai/agent/toolfmt.js +50 -65
- package/dist/ai/ai.css +18 -31
- package/dist/ai/components/AllocationSelector.js +2 -2
- package/dist/ai/components/AttachmentManager.js +28 -29
- package/dist/ai/components/AttachmentUpload.js +25 -30
- package/dist/ai/components/BlockedGroupBanner.js +2 -2
- package/dist/ai/components/BranchNavigator.js +3 -4
- package/dist/ai/components/ChatEmptyState.js +8 -7
- package/dist/ai/components/ChatInput.js +10 -12
- package/dist/ai/components/ChatLayout.js +3 -3
- package/dist/ai/components/ChatMessage.js +49 -61
- package/dist/ai/components/ChatMessageList.js +46 -42
- package/dist/ai/components/ChatSidebar.js +26 -34
- package/dist/ai/components/ChatStage.js +1 -1
- package/dist/ai/components/ComposerChrome.js +3 -4
- package/dist/ai/components/DragOverlay.js +6 -4
- package/dist/ai/components/ModelSelector.js +14 -15
- package/dist/ai/components/PastedText.js +18 -14
- package/dist/ai/components/ProviderIssueBanner.js +3 -4
- package/dist/ai/components/Reasoning.d.ts +12 -6
- package/dist/ai/components/Reasoning.js +31 -18
- package/dist/ai/components/ShareDialog.js +25 -28
- package/dist/ai/components/SlashMenu.js +3 -3
- package/dist/ai/components/agent/ActivityLine.d.ts +0 -5
- package/dist/ai/components/agent/ActivityLine.js +17 -54
- package/dist/ai/components/agent/AgentMessageParts.js +139 -149
- package/dist/ai/components/conversationActions.js +16 -16
- package/dist/ai/core/ChatProvider.d.ts +2 -4
- package/dist/ai/core/ChatProvider.js +25 -38
- package/dist/ai/core/exportConversation.js +4 -4
- package/dist/ai/core/sidebarState.d.ts +8 -6
- package/dist/ai/core/sidebarState.js +21 -28
- package/dist/ai/core/useKeyboardShortcuts.js +14 -5
- package/dist/ai/index.d.ts +4 -5
- package/dist/ai/index.js +7 -7
- package/dist/ai/strings.d.ts +14 -31
- package/dist/ai/strings.js +19 -39
- package/dist/ai/types.d.ts +0 -5
- package/dist/ai/ui/ConversationSidebar.d.ts +12 -9
- package/dist/ai/ui/ConversationSidebar.js +43 -87
- package/dist/ai/ui/Markdown.d.ts +3 -6
- package/dist/ai/ui/Markdown.js +6 -73
- package/dist/ai/ui/Notice.js +10 -12
- package/dist/ai/ui/chip.d.ts +2 -2
- package/dist/ai/ui/chip.js +1 -1
- package/dist/ai/ui/sidebar.d.ts +4 -20
- package/dist/ai/ui/sidebar.js +30 -67
- package/dist/ai/utils.d.ts +0 -1
- package/dist/ai/utils.js +1 -14
- package/dist/brandIcons.d.ts +51 -0
- package/dist/brandIcons.js +75 -0
- package/dist/components/Avatar.d.ts +3 -1
- package/dist/components/Avatar.js +34 -28
- package/dist/components/Button.d.ts +12 -7
- package/dist/components/Button.js +39 -44
- package/dist/components/Callout.js +18 -12
- package/dist/components/Card.d.ts +18 -8
- package/dist/components/Card.js +17 -6
- package/dist/components/Checkbox.d.ts +9 -0
- package/dist/components/Checkbox.js +30 -0
- package/dist/components/Combobox.d.ts +9 -1
- package/dist/components/Combobox.js +71 -44
- package/dist/components/ConfirmModal.js +11 -11
- package/dist/components/ContextMenu.d.ts +2 -8
- package/dist/components/ContextMenu.js +2 -29
- package/dist/components/CopyToClipboard.js +17 -36
- package/dist/components/CreateModal.d.ts +3 -24
- package/dist/components/CreateModal.js +46 -113
- package/dist/components/DatePicker.d.ts +31 -0
- package/dist/components/DatePicker.js +191 -0
- package/dist/components/DescriptionList.js +4 -4
- package/dist/components/Disclosure.d.ts +34 -0
- package/dist/components/Disclosure.js +46 -0
- package/dist/components/Drawer.d.ts +47 -0
- package/dist/components/Drawer.js +120 -0
- package/dist/components/EmptyState.d.ts +15 -10
- package/dist/components/EmptyState.js +13 -8
- package/dist/components/ExternalLink.d.ts +8 -0
- package/dist/components/ExternalLink.js +29 -0
- package/dist/components/Field.d.ts +70 -0
- package/dist/components/Field.js +159 -0
- package/dist/components/HoverCard.js +11 -14
- package/dist/components/IconButton.d.ts +16 -13
- package/dist/components/IconButton.js +27 -18
- package/dist/components/InfoTip.js +16 -23
- package/dist/components/Input.d.ts +10 -9
- package/dist/components/Input.js +54 -96
- package/dist/components/LetterBadge.js +2 -2
- package/dist/components/Loader.d.ts +15 -8
- package/dist/components/Loader.js +29 -19
- package/dist/components/Markdown.d.ts +7 -1
- package/dist/components/Markdown.js +2 -0
- package/dist/components/MarkdownImpl.d.ts +1 -1
- package/dist/components/MarkdownImpl.js +55 -14
- package/dist/components/Menu.js +13 -15
- package/dist/components/MenuEntries.js +11 -16
- package/dist/components/Meter.d.ts +48 -0
- package/dist/components/Meter.js +94 -0
- package/dist/components/Modal.js +11 -14
- package/dist/components/NumberInput.d.ts +25 -0
- package/dist/components/NumberInput.js +55 -0
- package/dist/components/Overview.js +12 -10
- package/dist/components/PageHeader.d.ts +2 -3
- package/dist/components/PageHeader.js +30 -21
- package/dist/components/Pagination.d.ts +27 -14
- package/dist/components/Pagination.js +86 -25
- package/dist/components/Popover.d.ts +47 -0
- package/dist/components/Popover.js +63 -0
- package/dist/components/Provider.d.ts +197 -80
- package/dist/components/Provider.js +200 -118
- package/dist/components/Radio.d.ts +1 -1
- package/dist/components/Radio.js +4 -4
- package/dist/components/RefreshButton.d.ts +15 -0
- package/dist/components/RefreshButton.js +53 -0
- package/dist/components/RunStatusIcon.d.ts +12 -0
- package/dist/components/RunStatusIcon.js +84 -0
- package/dist/components/SearchInput.d.ts +16 -0
- package/dist/components/SearchInput.js +52 -0
- package/dist/components/Section.d.ts +28 -0
- package/dist/components/Section.js +76 -0
- package/dist/components/SegmentedControl.d.ts +7 -11
- package/dist/components/SegmentedControl.js +25 -56
- package/dist/components/Select.d.ts +8 -1
- package/dist/components/Select.js +47 -43
- package/dist/components/SettingModeOption.d.ts +3 -5
- package/dist/components/SettingModeOption.js +5 -6
- package/dist/components/SettingsCard.d.ts +32 -19
- package/dist/components/SettingsCard.js +40 -13
- package/dist/components/Skeleton.d.ts +22 -0
- package/dist/components/Skeleton.js +34 -0
- package/dist/components/Slider.d.ts +16 -0
- package/dist/components/Slider.js +30 -0
- package/dist/components/Sort.js +4 -6
- package/dist/components/StatusBadge.d.ts +3 -1
- package/dist/components/StatusBadge.js +9 -32
- package/dist/components/StatusIcons.d.ts +0 -4
- package/dist/components/StatusIcons.js +5 -13
- package/dist/components/Switch.d.ts +5 -1
- package/dist/components/Switch.js +23 -6
- package/dist/components/Table.js +13 -20
- package/dist/components/Tabs.d.ts +52 -0
- package/dist/components/Tabs.js +75 -0
- package/dist/components/ThemeEditor.d.ts +29 -0
- package/dist/components/ThemeEditor.js +397 -0
- package/dist/components/Toast.d.ts +57 -0
- package/dist/components/Toast.js +203 -0
- package/dist/components/Tooltip.js +12 -15
- package/dist/components/buttonClasses.d.ts +18 -0
- package/dist/components/buttonClasses.js +31 -0
- package/dist/components/codeTheme.d.ts +5 -0
- package/dist/components/codeTheme.js +93 -0
- package/dist/components/fieldBox.d.ts +14 -0
- package/dist/components/fieldBox.js +29 -0
- package/dist/components/floating.d.ts +26 -5
- package/dist/components/floating.js +31 -9
- package/dist/{ai/ui/codeBreaks.js → components/markdownCodeBreaks.js} +1 -1
- package/dist/components/persistedState.d.ts +2 -0
- package/dist/components/persistedState.js +63 -0
- package/dist/components/relativeTime.d.ts +36 -8
- package/dist/components/relativeTime.js +106 -23
- package/dist/components/segmented.d.ts +17 -0
- package/dist/components/segmented.js +27 -0
- package/dist/components/shortcutKey.d.ts +4 -0
- package/dist/components/shortcutKey.js +27 -0
- package/dist/components/splitter.d.ts +26 -0
- package/dist/components/splitter.js +69 -0
- package/dist/components/tone.d.ts +9 -0
- package/dist/components/tone.js +30 -0
- package/dist/components/useCopy.d.ts +14 -0
- package/dist/components/useCopy.js +31 -0
- package/dist/components/useCssIsDark.d.ts +2 -0
- package/dist/components/useCssIsDark.js +2 -1
- package/dist/components/useTheme.d.ts +10 -0
- package/dist/components/useTheme.js +40 -0
- package/dist/cx.d.ts +5 -0
- package/dist/cx.js +11 -0
- package/dist/editor/Editor.js +2 -2
- package/dist/editor/EditorField.js +7 -10
- package/dist/editor/FormCodePanel.js +10 -23
- package/dist/editor/Monaco.js +7 -4
- package/dist/editor/index.d.ts +1 -1
- package/dist/editor/index.js +2 -2
- package/dist/editor/themes.d.ts +4 -0
- package/dist/editor/themes.js +75 -76
- package/dist/file-explorer/FileExplorer.js +180 -187
- package/dist/file-explorer/FileExplorerContext.js +36 -58
- package/dist/file-explorer/FilePreview/CodePreviewEditor.js +2 -1
- package/dist/file-explorer/FilePreview/Inline.js +9 -7
- package/dist/file-explorer/FilePreview/StreamedBadge.js +2 -2
- package/dist/file-explorer/FilePreview/Viewer.js +32 -34
- package/dist/file-explorer/FilePreview/index.js +60 -92
- package/dist/file-explorer/FileRow.js +10 -15
- package/dist/file-explorer/FileRowsWindow.js +2 -6
- package/dist/file-explorer/FileTable.js +2 -2
- package/dist/file-explorer/FileTableHeaders.js +8 -11
- package/dist/file-explorer/LoadMoreRow.js +8 -9
- package/dist/file-explorer/TreeView.js +16 -16
- package/dist/file-explorer/helpers.d.ts +1 -4
- package/dist/file-explorer/helpers.js +101 -114
- package/dist/file-explorer/lib/utils.d.ts +0 -2
- package/dist/file-explorer/lib/utils.js +1 -25
- package/dist/file-explorer/toasts.js +104 -185
- package/dist/form/Fields/BooleanField.js +12 -14
- package/dist/form/Fields/CheckboxGroupField.d.ts +1 -1
- package/dist/form/Fields/CheckboxGroupField.js +16 -18
- package/dist/form/Fields/ColorField.js +11 -11
- package/dist/form/Fields/DropdownField.d.ts +1 -1
- package/dist/form/Fields/DropdownField.js +20 -36
- package/dist/form/Fields/DurationField.d.ts +1 -1
- package/dist/form/Fields/DurationField.js +36 -50
- package/dist/form/Fields/LabelField.js +2 -2
- package/dist/form/Fields/MultiDropdownField.d.ts +1 -1
- package/dist/form/Fields/MultiDropdownField.js +9 -14
- package/dist/form/Fields/NumberField.d.ts +1 -1
- package/dist/form/Fields/NumberField.js +13 -48
- package/dist/form/Fields/ObjectField.js +3 -3
- package/dist/form/Fields/RadioField.d.ts +1 -1
- package/dist/form/Fields/RadioField.js +15 -18
- package/dist/form/Fields/RangeField.js +34 -35
- package/dist/form/Fields/StringField.d.ts +1 -1
- package/dist/form/Fields/StringField.js +15 -25
- package/dist/form/Fields/TextAreaField.js +10 -15
- package/dist/form/Form.d.ts +7 -2
- package/dist/form/Form.js +144 -49
- package/dist/form/FormLayout.js +18 -12
- package/dist/form/Wizard/WizardContainer.js +44 -18
- package/dist/form/Wizard/WizardNavigation.d.ts +1 -1
- package/dist/form/Wizard/WizardNavigation.js +31 -56
- package/dist/form/Wizard/WizardStepIndicator.d.ts +3 -0
- package/dist/form/Wizard/WizardStepIndicator.js +98 -114
- package/dist/form/Wizard/types.d.ts +2 -2
- package/dist/form/fieldFrame.d.ts +7 -0
- package/dist/form/fieldFrame.js +19 -0
- package/dist/form/index.d.ts +5 -5
- package/dist/form/index.js +4 -6
- package/dist/form/layoutCSS.js +5 -4
- package/dist/form/types/fieldComponentTypes.d.ts +5 -3
- package/dist/form/useChoiceField.js +2 -3
- package/dist/form/useFieldValue.d.ts +3 -0
- package/dist/form/useFieldValue.js +24 -7
- package/dist/form/utils/duration.d.ts +2 -2
- package/dist/form/utils/duration.js +3 -3
- package/dist/form/utils/fieldPath.d.ts +5 -3
- package/dist/form/utils/fieldPath.js +18 -3
- package/dist/form/utils/secondaryField.d.ts +0 -7
- package/dist/form/utils/secondaryField.js +1 -12
- package/dist/form/validation.d.ts +29 -0
- package/dist/form/validation.js +14 -0
- package/dist/format.d.ts +28 -0
- package/dist/format.js +64 -0
- package/dist/graph/AnnotationBanner.js +20 -31
- package/dist/graph/Connectors.js +1 -1
- package/dist/graph/DependencyGraph.js +51 -65
- package/dist/graph/GraphEditor.js +24 -28
- package/dist/graph/GraphEditorDialogs.js +239 -245
- package/dist/graph/InputDialog.js +93 -112
- package/dist/graph/InputsEditor.js +83 -84
- package/dist/graph/JobSummary.js +10 -11
- package/dist/graph/MatrixGroup.js +3 -3
- package/dist/graph/ProblemsButton.js +9 -10
- package/dist/graph/ShortcutsButton.js +12 -17
- package/dist/graph/SuggestionInput.d.ts +1 -2
- package/dist/graph/SuggestionInput.js +1 -3
- package/dist/graph/TreeView.js +47 -45
- package/dist/graph/WorkflowSettingsDialog.js +97 -102
- package/dist/graph/editorChrome.js +10 -12
- package/dist/graph/editorFields.d.ts +19 -16
- package/dist/graph/editorFields.js +97 -135
- package/dist/graph/editorPrimitives.js +2 -2
- package/dist/graph/editorRows.js +22 -25
- package/dist/graph/editorStrings.d.ts +16 -19
- package/dist/graph/editorStrings.js +11 -23
- package/dist/graph/fieldProblems.js +2 -2
- package/dist/graph/graphEditorState.d.ts +4 -4
- package/dist/graph/inputRefs.d.ts +0 -13
- package/dist/graph/inputRefs.js +121 -159
- package/dist/graph/settingsViews.js +5 -3
- package/dist/graph/stepWith.js +100 -100
- package/dist/graph/toolbarPanel.d.ts +8 -0
- package/dist/graph/toolbarPanel.js +11 -0
- package/dist/icons.d.ts +234 -23
- package/dist/icons.js +249 -264
- package/dist/index.d.ts +38 -21
- package/dist/index.js +42 -21
- package/dist/list/ActionToolbar.d.ts +1 -5
- package/dist/list/ActionToolbar.js +21 -20
- package/dist/list/ListPage.js +7 -7
- package/dist/list/ListTable.d.ts +3 -2
- package/dist/list/ListTable.js +33 -29
- package/dist/list/ListViewControls.d.ts +0 -17
- package/dist/list/ListViewControls.js +50 -118
- package/dist/list/UserHoverCard.js +24 -32
- package/dist/list/index.d.ts +2 -4
- package/dist/list/index.js +3 -5
- package/dist/list/listSearch.d.ts +1 -1
- package/dist/list/listSearch.js +19 -14
- package/dist/list/rowMenu.js +20 -26
- package/dist/logviewer/LogViewer.js +268 -382
- package/dist/logviewer/logviewer.css +53 -41
- package/dist/styles/base.css +16 -40
- package/dist/styles/theme.css +75 -106
- package/dist/styles.css +1 -1
- package/dist/theme/color.d.ts +40 -0
- package/dist/theme/color.js +228 -0
- package/dist/theme/contrast.d.ts +42 -0
- package/dist/theme/contrast.js +145 -0
- package/dist/theme/derive.d.ts +25 -0
- package/dist/theme/derive.js +475 -0
- package/dist/theme/fit.d.ts +35 -0
- package/dist/theme/fit.js +185 -0
- package/dist/theme/index.d.ts +14 -29
- package/dist/theme/index.js +20 -279
- package/dist/theme/model.d.ts +64 -0
- package/dist/theme/model.js +219 -0
- package/package.json +9 -5
- package/dist/ai/ui/Avatar.d.ts +0 -7
- package/dist/ai/ui/Avatar.js +0 -24
- package/dist/components/Filter.d.ts +0 -15
- package/dist/components/Filter.js +0 -32
- package/dist/components/FilterPill.d.ts +0 -7
- package/dist/components/FilterPill.js +0 -14
- package/dist/components/Indicator.d.ts +0 -4
- package/dist/components/Indicator.js +0 -44
- package/dist/components/SectionHeader.d.ts +0 -8
- package/dist/components/SectionHeader.js +0 -11
- package/dist/components/SettingRow.d.ts +0 -18
- package/dist/components/SettingRow.js +0 -35
- package/dist/components/SettingsGroup.d.ts +0 -8
- package/dist/components/SettingsGroup.js +0 -17
- package/dist/components/ghostButton.d.ts +0 -4
- package/dist/components/ghostButton.js +0 -7
- package/dist/components/inputClasses.d.ts +0 -1
- package/dist/components/inputClasses.js +0 -4
- package/dist/duration.d.ts +0 -3
- package/dist/duration.js +0 -17
- package/dist/form/FieldGroup.d.ts +0 -11
- package/dist/form/FieldGroup.js +0 -36
- package/dist/form/FieldWrapper.d.ts +0 -16
- package/dist/form/FieldWrapper.js +0 -55
- package/dist/form/fieldContext.d.ts +0 -19
- package/dist/form/fieldContext.js +0 -26
- package/dist/graph/Collapse.d.ts +0 -7
- package/dist/graph/Collapse.js +0 -15
- package/dist/graph/ToolbarPopover.d.ts +0 -13
- package/dist/graph/ToolbarPopover.js +0 -39
- package/dist/icons/ai/AiOutlineRollback.js +0 -16
- package/dist/icons/bi/BiBell.js +0 -16
- package/dist/icons/bi/BiBellOff.js +0 -16
- package/dist/icons/bi/BiBuildings.js +0 -20
- package/dist/icons/bi/BiError.js +0 -20
- package/dist/icons/bi/BiExpandVertical.js +0 -16
- package/dist/icons/bi/BiPause.js +0 -16
- package/dist/icons/bi/BiPlay.js +0 -16
- package/dist/icons/bi/BiRedo.js +0 -16
- package/dist/icons/bi/BiSolidCheckShield.js +0 -16
- package/dist/icons/bi/BiSolidTrashAlt.js +0 -16
- package/dist/icons/bi/BiStop.js +0 -16
- package/dist/icons/bi/BiUndo.js +0 -16
- package/dist/icons/bs/BsArrowsCollapse.js +0 -22
- package/dist/icons/bs/BsBank2.js +0 -19
- package/dist/icons/bs/BsBriefcase.js +0 -19
- package/dist/icons/bs/BsBucket.js +0 -19
- package/dist/icons/bs/BsCalendarX.js +0 -23
- package/dist/icons/bs/BsChatLeft.js +0 -19
- package/dist/icons/bs/BsChevronDoubleDown.js +0 -29
- package/dist/icons/bs/BsChevronDoubleUp.js +0 -29
- package/dist/icons/bs/BsClipboardCheck.js +0 -34
- package/dist/icons/bs/BsCurrencyDollar.js +0 -19
- package/dist/icons/bs/BsDash.js +0 -19
- package/dist/icons/bs/BsFileEarmarkZip.js +0 -23
- package/dist/icons/bs/BsFiles.js +0 -19
- package/dist/icons/bs/BsGeoAlt.js +0 -23
- package/dist/icons/bs/BsGrid.js +0 -19
- package/dist/icons/bs/BsLayers.js +0 -19
- package/dist/icons/bs/BsLayoutThreeColumns.js +0 -19
- package/dist/icons/bs/BsListUl.js +0 -22
- package/dist/icons/bs/BsMortarboard.js +0 -23
- package/dist/icons/bs/BsMusicNoteBeamed.js +0 -34
- package/dist/icons/bs/BsOpenai.js +0 -19
- package/dist/icons/bs/BsPersonPlus.js +0 -26
- package/dist/icons/bs/BsSearch.js +0 -19
- package/dist/icons/bs/BsSend.js +0 -19
- package/dist/icons/bs/BsShieldSlash.js +0 -22
- package/dist/icons/bs/BsStar.js +0 -19
- package/dist/icons/bs/BsStarFill.js +0 -19
- package/dist/icons/bs/BsStopCircle.js +0 -23
- package/dist/icons/bs/BsTag.js +0 -23
- package/dist/icons/bs/BsTelephone.js +0 -19
- package/dist/icons/bs/BsTerminal.js +0 -23
- package/dist/icons/bs/BsTerminalFill.js +0 -19
- package/dist/icons/bs/BsThreeDots.js +0 -19
- package/dist/icons/bs/BsThreeDotsVertical.js +0 -19
- package/dist/icons/bs/BsZoomIn.js +0 -37
- package/dist/icons/fa/FaAmazon.js +0 -16
- package/dist/icons/fa/FaAngleDown.js +0 -16
- package/dist/icons/fa/FaAngleLeft.js +0 -16
- package/dist/icons/fa/FaAngleRight.js +0 -16
- package/dist/icons/fa/FaAngleUp.js +0 -16
- package/dist/icons/fa/FaArrowDown.js +0 -16
- package/dist/icons/fa/FaArrowLeft.js +0 -16
- package/dist/icons/fa/FaArrowRight.js +0 -16
- package/dist/icons/fa/FaArrowUp.js +0 -16
- package/dist/icons/fa/FaBalanceScale.js +0 -16
- package/dist/icons/fa/FaCaretDown.js +0 -16
- package/dist/icons/fa/FaCentos.js +0 -16
- package/dist/icons/fa/FaChartLine.js +0 -16
- package/dist/icons/fa/FaChartPie.js +0 -16
- package/dist/icons/fa/FaCheck.js +0 -16
- package/dist/icons/fa/FaChevronDown.js +0 -16
- package/dist/icons/fa/FaChevronUp.js +0 -16
- package/dist/icons/fa/FaChrome.js +0 -16
- package/dist/icons/fa/FaCircleNotch.js +0 -16
- package/dist/icons/fa/FaCloud.js +0 -16
- package/dist/icons/fa/FaCloudDownloadAlt.js +0 -16
- package/dist/icons/fa/FaCog.js +0 -16
- package/dist/icons/fa/FaCogs.js +0 -16
- package/dist/icons/fa/FaComments.js +0 -16
- package/dist/icons/fa/FaCompress.js +0 -16
- package/dist/icons/fa/FaDesktop.js +0 -16
- package/dist/icons/fa/FaDocker.js +0 -16
- package/dist/icons/fa/FaDollarSign.js +0 -16
- package/dist/icons/fa/FaEdge.js +0 -16
- package/dist/icons/fa/FaEdit.js +0 -16
- package/dist/icons/fa/FaExclamationTriangle.js +0 -16
- package/dist/icons/fa/FaExpand.js +0 -16
- package/dist/icons/fa/FaEye.js +0 -16
- package/dist/icons/fa/FaEyeSlash.js +0 -16
- package/dist/icons/fa/FaFile.js +0 -16
- package/dist/icons/fa/FaFilePdf.js +0 -16
- package/dist/icons/fa/FaFilter.js +0 -16
- package/dist/icons/fa/FaFirefoxBrowser.js +0 -16
- package/dist/icons/fa/FaFlask.js +0 -16
- package/dist/icons/fa/FaFolder.js +0 -16
- package/dist/icons/fa/FaGithub.js +0 -16
- package/dist/icons/fa/FaGitlab.js +0 -16
- package/dist/icons/fa/FaGlobe.js +0 -16
- package/dist/icons/fa/FaGlobeAmericas.js +0 -16
- package/dist/icons/fa/FaImage.js +0 -16
- package/dist/icons/fa/FaInfoCircle.js +0 -16
- package/dist/icons/fa/FaKey.js +0 -16
- package/dist/icons/fa/FaLayerGroup.js +0 -16
- package/dist/icons/fa/FaLink.js +0 -16
- package/dist/icons/fa/FaLinkedin.js +0 -16
- package/dist/icons/fa/FaLinux.js +0 -16
- package/dist/icons/fa/FaList.js +0 -16
- package/dist/icons/fa/FaLock.js +0 -16
- package/dist/icons/fa/FaOpenid.js +0 -16
- package/dist/icons/fa/FaOpera.js +0 -16
- package/dist/icons/fa/FaPaperclip.js +0 -16
- package/dist/icons/fa/FaPlus.js +0 -16
- package/dist/icons/fa/FaPowerOff.js +0 -16
- package/dist/icons/fa/FaPrint.js +0 -16
- package/dist/icons/fa/FaQrcode.js +0 -16
- package/dist/icons/fa/FaQuestionCircle.js +0 -16
- package/dist/icons/fa/FaRedhat.js +0 -16
- package/dist/icons/fa/FaRegCircle.js +0 -16
- package/dist/icons/fa/FaRegFileImage.js +0 -16
- package/dist/icons/fa/FaRegFolder.js +0 -16
- package/dist/icons/fa/FaRobot.js +0 -16
- package/dist/icons/fa/FaRocket.js +0 -16
- package/dist/icons/fa/FaRunning.js +0 -16
- package/dist/icons/fa/FaSafari.js +0 -16
- package/dist/icons/fa/FaSave.js +0 -16
- package/dist/icons/fa/FaSearch.js +0 -16
- package/dist/icons/fa/FaShieldAlt.js +0 -16
- package/dist/icons/fa/FaSlack.js +0 -16
- package/dist/icons/fa/FaStar.js +0 -16
- package/dist/icons/fa/FaStop.js +0 -16
- package/dist/icons/fa/FaSuse.js +0 -16
- package/dist/icons/fa/FaTerminal.js +0 -16
- package/dist/icons/fa/FaTimes.js +0 -16
- package/dist/icons/fa/FaUbuntu.js +0 -16
- package/dist/icons/fa/FaUndoAlt.js +0 -16
- package/dist/icons/fa/FaUnlink.js +0 -16
- package/dist/icons/fa/FaUser.js +0 -16
- package/dist/icons/fa/FaUsers.js +0 -16
- package/dist/icons/fa/FaWindows.js +0 -16
- package/dist/icons/fa6/FaApple.js +0 -16
- package/dist/icons/fa6/FaArrowsRotate.js +0 -16
- package/dist/icons/fa6/FaDebian.js +0 -16
- package/dist/icons/fa6/FaFilterCircleXmark.js +0 -16
- package/dist/icons/fa6/FaInbox.js +0 -16
- package/dist/icons/fa6/FaLocationDot.js +0 -16
- package/dist/icons/fa6/FaRegFilePdf.js +0 -16
- package/dist/icons/fa6/FaRegFolderOpen.js +0 -16
- package/dist/icons/fa6/FaUpRightFromSquare.js +0 -16
- package/dist/icons/fa6/FaWandMagicSparkles.js +0 -16
- package/dist/icons/fa6/FaXTwitter.js +0 -16
- package/dist/icons/fi/FiActivity.js +0 -23
- package/dist/icons/fi/FiAlertCircle.js +0 -49
- package/dist/icons/fi/FiChevronDown.js +0 -23
- package/dist/icons/fi/FiClock.js +0 -31
- package/dist/icons/fi/FiCopy.js +0 -34
- package/dist/icons/fi/FiDownload.js +0 -40
- package/dist/icons/fi/FiFile.js +0 -27
- package/dist/icons/fi/FiFileText.js +0 -55
- package/dist/icons/fi/FiHardDrive.js +0 -55
- package/dist/icons/fi/FiRotateCcw.js +0 -27
- package/dist/icons/fi/FiUpload.js +0 -40
- package/dist/icons/fi/FiX.js +0 -37
- package/dist/icons/fi/FiZap.js +0 -23
- package/dist/icons/gi/GiSpy.js +0 -16
- package/dist/icons/go/GoGitCommit.js +0 -16
- package/dist/icons/go/GoGitPullRequest.js +0 -20
- package/dist/icons/go/GoIssueOpened.js +0 -16
- package/dist/icons/go/GoPlus.js +0 -16
- package/dist/icons/go/GoRepoForked.js +0 -28
- package/dist/icons/go/GoSignOut.js +0 -16
- package/dist/icons/go/GoSkip.js +0 -20
- package/dist/icons/go/GoVideo.js +0 -20
- package/dist/icons/gr/GrCloudComputer.js +0 -20
- package/dist/icons/gr/GrInbox.js +0 -20
- package/dist/icons/gr/GrServerCluster.js +0 -20
- package/dist/icons/gr/GrStorage.js +0 -20
- package/dist/icons/gr/GrTasks.js +0 -20
- package/dist/icons/hi/HiCog.js +0 -24
- package/dist/icons/hi/HiDuplicate.js +0 -24
- package/dist/icons/hi/HiOutlineArchive.js +0 -26
- package/dist/icons/hi/HiOutlineClipboardCopy.js +0 -26
- package/dist/icons/hi/HiOutlineHome.js +0 -26
- package/dist/icons/hi/HiQuestionMarkCircle.js +0 -24
- package/dist/icons/hi/HiServer.js +0 -24
- package/dist/icons/hi2/HiMiniCheckCircle.js +0 -24
- package/dist/icons/hi2/HiMiniLanguage.js +0 -28
- package/dist/icons/hi2/HiMiniMinusCircle.js +0 -24
- package/dist/icons/hi2/HiMiniXCircle.js +0 -24
- package/dist/icons/hi2/HiSparkles.js +0 -24
- package/dist/icons/im/ImSpinner5.js +0 -19
- package/dist/icons/io/IoIosNotifications.js +0 -16
- package/dist/icons/io/IoMdBuild.js +0 -16
- package/dist/icons/io/IoMdClose.js +0 -16
- package/dist/icons/io5/IoCloudUploadOutline.js +0 -32
- package/dist/icons/io5/IoDocumentTextOutline.js +0 -31
- package/dist/icons/io5/IoFileTrayFullOutline.js +0 -31
- package/dist/icons/io5/IoHeart.js +0 -16
- package/dist/icons/io5/IoHeartDislike.js +0 -16
- package/dist/icons/io5/IoHeartOutline.js +0 -22
- package/dist/icons/io5/IoInformationCircleOutline.js +0 -50
- package/dist/icons/io5/IoSettingsOutline.js +0 -22
- package/dist/icons/io5/IoWarningOutline.js +0 -40
- package/dist/icons/lu/LuArrowRight.js +0 -27
- package/dist/icons/lu/LuBadgeCheck.js +0 -27
- package/dist/icons/lu/LuBraces.js +0 -27
- package/dist/icons/lu/LuBrainCircuit.js +0 -101
- package/dist/icons/lu/LuCalendar.js +0 -46
- package/dist/icons/lu/LuCheck.js +0 -23
- package/dist/icons/lu/LuChevronLeft.js +0 -23
- package/dist/icons/lu/LuChevronRight.js +0 -23
- package/dist/icons/lu/LuCode.js +0 -27
- package/dist/icons/lu/LuExternalLink.js +0 -35
- package/dist/icons/lu/LuEye.js +0 -31
- package/dist/icons/lu/LuEyeOff.js +0 -40
- package/dist/icons/lu/LuFolderTree.js +0 -40
- package/dist/icons/lu/LuIdCard.js +0 -55
- package/dist/icons/lu/LuKeyboard.js +0 -71
- package/dist/icons/lu/LuLogs.js +0 -65
- package/dist/icons/lu/LuMail.js +0 -33
- package/dist/icons/lu/LuMegaphone.js +0 -27
- package/dist/icons/lu/LuMoon.js +0 -23
- package/dist/icons/lu/LuNetwork.js +0 -63
- package/dist/icons/lu/LuPartyPopper.js +0 -65
- package/dist/icons/lu/LuSettings2.js +0 -48
- package/dist/icons/lu/LuSheet.js +0 -72
- package/dist/icons/lu/LuShield.js +0 -23
- package/dist/icons/lu/LuSun.js +0 -69
- package/dist/icons/lu/LuTextCursorInput.js +0 -45
- package/dist/icons/lu/LuX.js +0 -27
- package/dist/icons/lu/LuZoomIn.js +0 -59
- package/dist/icons/lu/LuZoomOut.js +0 -49
- package/dist/icons/md/MdClear.js +0 -23
- package/dist/icons/md/MdDragHandle.js +0 -23
- package/dist/icons/md/MdInstallDesktop.js +0 -31
- package/dist/icons/md/MdOutlineAttachMoney.js +0 -23
- package/dist/icons/md/MdOutlineMoneyOff.js +0 -23
- package/dist/icons/md/MdPieChart.js +0 -23
- package/dist/icons/md/MdRefresh.js +0 -23
- package/dist/icons/md/MdReplay.js +0 -23
- package/dist/icons/md/MdSmartphone.js +0 -23
- package/dist/icons/pi/PiArrowBendUpRightBold.js +0 -19
- package/dist/icons/pi/PiPlugsConnectedFill.js +0 -19
- package/dist/icons/pi/PiRectangleDashed.js +0 -19
- package/dist/icons/pi/PiShareBold.js +0 -19
- package/dist/icons/si/SiAnthropic.js +0 -19
- package/dist/icons/si/SiHelm.js +0 -19
- package/dist/icons/si/SiKubernetes.js +0 -19
- package/dist/icons/tb/TbAlertTriangle.js +0 -35
- package/dist/icons/tb/TbAlertTriangleFilled.js +0 -19
- package/dist/icons/tb/TbApi.js +0 -40
- package/dist/icons/tb/TbBrain.js +0 -50
- package/dist/icons/tb/TbBuildingTunnel.js +0 -65
- package/dist/icons/tb/TbEdit.js +0 -35
- package/dist/icons/tb/TbLayoutSidebar.js +0 -27
- package/dist/icons/tb/TbLayoutSidebarLeftCollapse.js +0 -35
- package/dist/icons/tb/TbLayoutSidebarRightCollapse.js +0 -35
- package/dist/icons/tb/TbUser.js +0 -27
- package/dist/icons/tb/TbUserOff.js +0 -35
- package/dist/icons/tb/TbWorldShare.js +0 -55
- package/dist/icons/tb/TbWorldWww.js +0 -65
- package/dist/icons/ti/TiArrowSortedDown.js +0 -20
- package/dist/icons/ti/TiArrowSortedUp.js +0 -20
- package/dist/icons/ti/TiArrowUnsorted.js +0 -20
- package/dist/icons/ti/TiCancel.js +0 -20
- package/dist/icons/vsc/VscChromeMinimize.js +0 -19
- package/dist/icons/vsc/VscJson.js +0 -19
- package/dist/icons/vsc/VscLayoutSidebarLeft.js +0 -19
- package/dist/icons/vsc/VscPass.js +0 -27
- package/dist/icons/vsc/VscSplitHorizontal.js +0 -19
- package/dist/icons/vsc/VscTerminalPowershell.js +0 -19
- package/dist/list/ListPager.d.ts +0 -14
- package/dist/list/ListPager.js +0 -62
- package/dist/list/textEntry.d.ts +0 -2
- package/dist/list/textEntry.js +0 -10
- /package/dist/{ai/ui/codeBreaks.d.ts → components/markdownCodeBreaks.d.ts} +0 -0
|
@@ -1,17 +1,21 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { WarningIcon } from "../../icons.js";
|
|
2
|
+
import { useStrings } from "../../components/Provider.js";
|
|
3
|
+
import { Button } from "../../components/Button.js";
|
|
2
4
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
3
5
|
import { useState } from "react";
|
|
4
6
|
//#region src/form/Wizard/WizardNavigation.tsx
|
|
5
|
-
function WizardNavigation({ isLastStep, canGoBack, isCurrentStepValid, nextLabel, prevLabel, submitLabel
|
|
7
|
+
function WizardNavigation({ isLastStep, canGoBack, isCurrentStepValid, nextLabel, prevLabel, submitLabel: submitLabelProp, onNext, onPrevious, onSubmit }) {
|
|
8
|
+
const { form: t, common } = useStrings();
|
|
9
|
+
const submitLabel = submitLabelProp ?? common.submit;
|
|
6
10
|
const [isLoading, setIsLoading] = useState(false);
|
|
7
11
|
const [error, setError] = useState(null);
|
|
8
12
|
const handleNext = async () => {
|
|
9
13
|
setIsLoading(true);
|
|
10
14
|
setError(null);
|
|
11
15
|
try {
|
|
12
|
-
if (!await onNext()) setError(
|
|
16
|
+
if (!await onNext()) setError(t.fixErrorsToContinue);
|
|
13
17
|
} catch (err) {
|
|
14
|
-
setError(err instanceof Error ? err.message :
|
|
18
|
+
setError(err instanceof Error ? err.message : t.stepFailed);
|
|
15
19
|
} finally {
|
|
16
20
|
setIsLoading(false);
|
|
17
21
|
}
|
|
@@ -22,68 +26,39 @@ function WizardNavigation({ isLastStep, canGoBack, isCurrentStepValid, nextLabel
|
|
|
22
26
|
try {
|
|
23
27
|
await onSubmit?.();
|
|
24
28
|
} catch (err) {
|
|
25
|
-
setError(err instanceof Error ? err.message :
|
|
29
|
+
setError(err instanceof Error ? err.message : t.stepFailed);
|
|
26
30
|
} finally {
|
|
27
31
|
setIsLoading(false);
|
|
28
32
|
}
|
|
29
33
|
};
|
|
30
|
-
return /* @__PURE__ */ jsxs("div", { children: [error && /* @__PURE__ */
|
|
31
|
-
|
|
32
|
-
|
|
34
|
+
return /* @__PURE__ */ jsxs("div", { children: [error && /* @__PURE__ */ jsxs("p", {
|
|
35
|
+
role: "alert",
|
|
36
|
+
className: "mb-3 flex items-center gap-1.5 text-sm text-(--theme-error)",
|
|
37
|
+
children: [/* @__PURE__ */ jsx(WarningIcon, {
|
|
38
|
+
"aria-hidden": "true",
|
|
39
|
+
className: "size-4 shrink-0"
|
|
40
|
+
}), error]
|
|
33
41
|
}), /* @__PURE__ */ jsxs("div", {
|
|
34
|
-
className: "flex gap-3
|
|
35
|
-
children: [/* @__PURE__ */ jsx(
|
|
36
|
-
|
|
42
|
+
className: "flex justify-between gap-3 pt-4",
|
|
43
|
+
children: [/* @__PURE__ */ jsx(Button, {
|
|
44
|
+
variant: "secondary",
|
|
37
45
|
onClick: onPrevious,
|
|
38
46
|
disabled: !canGoBack || isLoading,
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
backgroundColor: "var(--theme-app-bg)"
|
|
44
|
-
},
|
|
45
|
-
onMouseEnter: (e) => {
|
|
46
|
-
if (canGoBack && !isLoading) e.currentTarget.style.backgroundColor = "var(--theme-hover)";
|
|
47
|
-
},
|
|
48
|
-
onMouseLeave: (e) => {
|
|
49
|
-
e.currentTarget.style.backgroundColor = "var(--theme-app-bg)";
|
|
50
|
-
},
|
|
51
|
-
"aria-label": "Go to previous step",
|
|
52
|
-
children: prevLabel || "← Previous"
|
|
53
|
-
}), isLastStep && !onSubmit ? null : isLastStep ? /* @__PURE__ */ jsxs("button", {
|
|
54
|
-
type: "button",
|
|
47
|
+
"aria-label": t.previousStep,
|
|
48
|
+
children: prevLabel || common.previous
|
|
49
|
+
}), isLastStep && !onSubmit ? null : isLastStep ? /* @__PURE__ */ jsx(Button, {
|
|
50
|
+
variant: "primary",
|
|
55
51
|
onClick: handleSubmit,
|
|
56
|
-
disabled: !isCurrentStepValid
|
|
57
|
-
|
|
58
|
-
style: { backgroundColor: "var(--theme-element)" },
|
|
59
|
-
onMouseEnter: (e) => {
|
|
60
|
-
if (isCurrentStepValid && !isLoading) e.currentTarget.style.filter = "brightness(0.9)";
|
|
61
|
-
},
|
|
62
|
-
onMouseLeave: (e) => {
|
|
63
|
-
e.currentTarget.style.filter = "brightness(1)";
|
|
64
|
-
},
|
|
52
|
+
disabled: !isCurrentStepValid,
|
|
53
|
+
loading: isLoading,
|
|
65
54
|
"aria-label": submitLabel,
|
|
66
|
-
children:
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
}), submitLabel]
|
|
70
|
-
}) : /* @__PURE__ */ jsxs("button", {
|
|
71
|
-
type: "button",
|
|
55
|
+
children: submitLabel
|
|
56
|
+
}) : /* @__PURE__ */ jsx(Button, {
|
|
57
|
+
variant: "primary",
|
|
72
58
|
onClick: handleNext,
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
onMouseEnter: (e) => {
|
|
77
|
-
if (!isLoading) e.currentTarget.style.filter = "brightness(0.9)";
|
|
78
|
-
},
|
|
79
|
-
onMouseLeave: (e) => {
|
|
80
|
-
e.currentTarget.style.filter = "brightness(1)";
|
|
81
|
-
},
|
|
82
|
-
"aria-label": "Go to next step",
|
|
83
|
-
children: [isLoading && /* @__PURE__ */ jsx(Loader, {
|
|
84
|
-
size: 16,
|
|
85
|
-
full: false
|
|
86
|
-
}), nextLabel || "Next →"]
|
|
59
|
+
loading: isLoading,
|
|
60
|
+
"aria-label": t.nextStep,
|
|
61
|
+
children: nextLabel || common.next
|
|
87
62
|
})]
|
|
88
63
|
})] });
|
|
89
64
|
}
|
|
@@ -1,2 +1,5 @@
|
|
|
1
1
|
import type { WizardStepIndicatorProps } from './types.js';
|
|
2
|
+
/** Where a wizard is: "Step 3 of 10", a bar with a segment per page, and the list of every page,
|
|
3
|
+
* from which a person jumps to one they may. It keeps one size from three pages to a hundred,
|
|
4
|
+
* as a repeated page's copies can make, and at any width. */
|
|
2
5
|
export declare function WizardStepIndicator({ stepOrder, currentStep, steps, visitedSteps, invalidSteps, onStepClick, allowJump, hideStepNumbers, }: WizardStepIndicatorProps): import("react").JSX.Element;
|
|
@@ -1,124 +1,108 @@
|
|
|
1
|
+
import { cx } from "../../cx.js";
|
|
2
|
+
import { CheckIcon, WarningIcon } from "../../icons.js";
|
|
1
3
|
import { useStrings } from "../../components/Provider.js";
|
|
4
|
+
import { Button } from "../../components/Button.js";
|
|
5
|
+
import { Popover, useClosePopover } from "../../components/Popover.js";
|
|
2
6
|
import { stepText } from "./utils.js";
|
|
3
|
-
import {
|
|
4
|
-
import { jsx, jsxs } from "react/jsx-runtime";
|
|
5
|
-
import { useEffect, useRef, useState } from "react";
|
|
7
|
+
import { Fragment, jsx, jsxs } from "react/jsx-runtime";
|
|
6
8
|
//#region src/form/Wizard/WizardStepIndicator.tsx
|
|
9
|
+
/** Where a wizard is: "Step 3 of 10", a bar with a segment per page, and the list of every page,
|
|
10
|
+
* from which a person jumps to one they may. It keeps one size from three pages to a hundred,
|
|
11
|
+
* as a repeated page's copies can make, and at any width. */
|
|
7
12
|
function WizardStepIndicator({ stepOrder, currentStep, steps, visitedSteps, invalidSteps, onStepClick, allowJump = false, hideStepNumbers = false }) {
|
|
8
13
|
const { form: strings } = useStrings();
|
|
9
14
|
const currentIndex = stepOrder.indexOf(currentStep);
|
|
10
|
-
const
|
|
11
|
-
|
|
12
|
-
useEffect(() => {
|
|
13
|
-
const el = row.current;
|
|
14
|
-
if (!el) return;
|
|
15
|
-
const measure = () => setScrolls(el.scrollWidth > el.clientWidth);
|
|
16
|
-
measure();
|
|
17
|
-
if (typeof ResizeObserver === "undefined") return;
|
|
18
|
-
const observer = new ResizeObserver(measure);
|
|
19
|
-
for (const box of [el, ...el.children]) observer.observe(box);
|
|
20
|
-
return () => observer.disconnect();
|
|
21
|
-
}, [stepOrder.length]);
|
|
22
|
-
useEffect(() => {
|
|
23
|
-
const el = row.current;
|
|
24
|
-
const step = el?.children[currentIndex];
|
|
25
|
-
if (!el || !step || el.scrollWidth <= el.clientWidth) return;
|
|
26
|
-
const box = el.getBoundingClientRect();
|
|
27
|
-
const at = step.getBoundingClientRect();
|
|
28
|
-
if (at.left < box.left || at.right > box.right) el.scrollLeft += at.left - box.left - (box.width - at.width) / 2;
|
|
29
|
-
}, [currentIndex]);
|
|
30
|
-
const getStepStatus = (stepKey, index) => {
|
|
31
|
-
if (stepKey === currentStep) return "active";
|
|
32
|
-
if (index < currentIndex) return "completed";
|
|
33
|
-
return "upcoming";
|
|
34
|
-
};
|
|
35
|
-
return /* @__PURE__ */ jsx("ol", {
|
|
36
|
-
ref: row,
|
|
15
|
+
const statusOf = (key, index) => key === currentStep ? "current" : invalidSteps.has(key) ? "invalid" : index < currentIndex ? "done" : "upcoming";
|
|
16
|
+
return /* @__PURE__ */ jsxs("nav", {
|
|
37
17
|
"aria-label": strings.steps,
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
},
|
|
18
|
+
className: "mb-4",
|
|
19
|
+
children: [/* @__PURE__ */ jsxs("div", {
|
|
20
|
+
className: "flex items-center justify-between gap-3",
|
|
21
|
+
children: [/* @__PURE__ */ jsx("p", {
|
|
22
|
+
className: "text-xs font-medium text-(--theme-muted-text-color)",
|
|
23
|
+
children: strings.stepOf(currentIndex + 1, stepOrder.length)
|
|
24
|
+
}), /* @__PURE__ */ jsx(Popover, {
|
|
25
|
+
trigger: /* @__PURE__ */ jsx(Button, {
|
|
26
|
+
size: "xs",
|
|
27
|
+
variant: "ghost",
|
|
28
|
+
children: strings.allSteps
|
|
29
|
+
}),
|
|
30
|
+
title: strings.steps,
|
|
31
|
+
align: "end",
|
|
32
|
+
className: "w-72",
|
|
33
|
+
children: /* @__PURE__ */ jsx("ol", {
|
|
34
|
+
className: "-mx-1 flex max-h-80 flex-col gap-0.5 overflow-y-auto",
|
|
35
|
+
children: stepOrder.map((key, index) => /* @__PURE__ */ jsx(StepItem, {
|
|
36
|
+
number: hideStepNumbers ? void 0 : index + 1,
|
|
37
|
+
title: stepText(steps[key]?.title),
|
|
38
|
+
description: steps[key]?.description && stepText(steps[key].description),
|
|
39
|
+
status: statusOf(key, index),
|
|
40
|
+
onJump: allowJump && visitedSteps.has(key) && key !== currentStep ? () => onStepClick(key) : void 0
|
|
41
|
+
}, key))
|
|
42
|
+
})
|
|
43
|
+
})]
|
|
44
|
+
}), /* @__PURE__ */ jsx("div", {
|
|
45
|
+
"aria-hidden": "true",
|
|
46
|
+
className: "mt-2 flex gap-1",
|
|
47
|
+
children: stepOrder.map((key, index) => /* @__PURE__ */ jsx("span", { className: cx("h-1 min-w-0.5 flex-1 rounded-full", segmentClasses[statusOf(key, index)]) }, key))
|
|
48
|
+
})]
|
|
49
|
+
});
|
|
50
|
+
}
|
|
51
|
+
var segmentClasses = {
|
|
52
|
+
done: "bg-(--theme-accent)",
|
|
53
|
+
current: "bg-(--theme-accent)",
|
|
54
|
+
upcoming: "bg-(--theme-border)",
|
|
55
|
+
invalid: "bg-(--theme-error)"
|
|
56
|
+
};
|
|
57
|
+
function StepItem({ number, title, description, status, onJump }) {
|
|
58
|
+
const { form: strings } = useStrings();
|
|
59
|
+
const close = useClosePopover();
|
|
60
|
+
const marker = /* @__PURE__ */ jsx("span", {
|
|
61
|
+
"aria-hidden": "true",
|
|
62
|
+
className: cx("flex size-5 shrink-0 items-center justify-center rounded-full text-[0.6875rem] font-semibold tabular-nums", status === "current" && "bg-(--theme-accent) text-(--theme-accent-text)", status === "done" && "bg-(--theme-muted-panel-bg) text-(--theme-accent)", status === "upcoming" && "border border-(--theme-border) text-(--theme-muted-text-color)", status === "invalid" && "bg-(--theme-muted-panel-bg) text-(--theme-error)"),
|
|
63
|
+
children: status === "done" ? /* @__PURE__ */ jsx(CheckIcon, { className: "size-2.5" }) : status === "invalid" ? /* @__PURE__ */ jsx(WarningIcon, { className: "size-3" }) : number
|
|
64
|
+
});
|
|
65
|
+
const text = /* @__PURE__ */ jsxs("span", {
|
|
66
|
+
className: "flex min-w-0 flex-col",
|
|
67
|
+
children: [
|
|
68
|
+
/* @__PURE__ */ jsx("span", {
|
|
69
|
+
className: cx("truncate", status === "current" && "font-semibold"),
|
|
70
|
+
children: number === void 0 ? title : /* @__PURE__ */ jsxs(Fragment, { children: [/* @__PURE__ */ jsx("span", {
|
|
71
|
+
className: "sr-only",
|
|
72
|
+
children: strings.stepLabel(number, title)
|
|
73
|
+
}), /* @__PURE__ */ jsx("span", {
|
|
74
|
+
"aria-hidden": "true",
|
|
75
|
+
children: title
|
|
76
|
+
})] })
|
|
77
|
+
}),
|
|
78
|
+
status === "done" && /* @__PURE__ */ jsx("span", {
|
|
79
|
+
className: "sr-only",
|
|
80
|
+
children: strings.stepDone
|
|
81
|
+
}),
|
|
82
|
+
status === "invalid" && /* @__PURE__ */ jsx("span", {
|
|
83
|
+
className: "text-xs text-(--theme-error)",
|
|
84
|
+
children: strings.stepNeedsAttention
|
|
85
|
+
}),
|
|
86
|
+
description && /* @__PURE__ */ jsx("span", {
|
|
87
|
+
className: "text-xs text-(--theme-muted-text-color)",
|
|
88
|
+
children: description
|
|
89
|
+
})
|
|
90
|
+
]
|
|
91
|
+
});
|
|
92
|
+
const row = "flex w-full items-start gap-2 rounded-md px-1 py-1.5 text-left text-sm";
|
|
93
|
+
return /* @__PURE__ */ jsx("li", {
|
|
94
|
+
"aria-current": status === "current" ? "step" : void 0,
|
|
95
|
+
children: onJump ? /* @__PURE__ */ jsxs("button", {
|
|
96
|
+
type: "button",
|
|
97
|
+
className: cx(row, "cursor-pointer hover:bg-(--theme-muted-panel-bg)"),
|
|
98
|
+
onClick: () => {
|
|
99
|
+
onJump();
|
|
100
|
+
close();
|
|
101
|
+
},
|
|
102
|
+
children: [marker, text]
|
|
103
|
+
}) : /* @__PURE__ */ jsxs("div", {
|
|
104
|
+
className: cx(row, status === "upcoming" && "text-(--theme-muted-text-color)"),
|
|
105
|
+
children: [marker, text]
|
|
122
106
|
})
|
|
123
107
|
});
|
|
124
108
|
}
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import type { DynamicFormSchema, LabelPosition } from '../types/fieldTypes.js';
|
|
2
2
|
interface WizardNavigation {
|
|
3
|
-
/** Show
|
|
3
|
+
/** Show where the wizard is: "Step 3 of 10", a bar of its pages and the list of them */
|
|
4
4
|
showSteps?: boolean;
|
|
5
5
|
/** Allow clicking on completed steps to jump to them */
|
|
6
6
|
allowJump?: boolean;
|
|
7
|
-
/**
|
|
7
|
+
/** Leave the numbers out of the list of steps, showing only titles */
|
|
8
8
|
hideStepNumbers?: boolean;
|
|
9
9
|
}
|
|
10
10
|
/**
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import type { FieldProps } from '../components/Field.js';
|
|
2
|
+
import type { FieldComponentProps } from './types/fieldComponentTypes.js';
|
|
3
|
+
/** How a form field's props frame it: its label, help, description, required mark and error,
|
|
4
|
+
* laid out as the form lays out its fields. Spread on `Field`. */
|
|
5
|
+
export declare function fieldFrame({ field, label, labelPosition, error, disabled, spaceCompact, tooltipComponent, }: FieldComponentProps, { group }?: {
|
|
6
|
+
group?: boolean;
|
|
7
|
+
}): Omit<FieldProps, 'children'>;
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { resolvedFlag } from "./lib.js";
|
|
2
|
+
//#region src/form/fieldFrame.ts
|
|
3
|
+
/** How a form field's props frame it: its label, help, description, required mark and error,
|
|
4
|
+
* laid out as the form lays out its fields. Spread on `Field`. */
|
|
5
|
+
function fieldFrame({ field, label, labelPosition, error, disabled, spaceCompact, tooltipComponent }, { group = false } = {}) {
|
|
6
|
+
return {
|
|
7
|
+
label,
|
|
8
|
+
hint: tooltipComponent,
|
|
9
|
+
description: field.description,
|
|
10
|
+
group,
|
|
11
|
+
required: !resolvedFlag(field.optional),
|
|
12
|
+
error,
|
|
13
|
+
disabled,
|
|
14
|
+
layout: labelPosition === "top" ? "stacked" : "inline",
|
|
15
|
+
compact: spaceCompact
|
|
16
|
+
};
|
|
17
|
+
}
|
|
18
|
+
//#endregion
|
|
19
|
+
export { fieldFrame };
|
package/dist/form/index.d.ts
CHANGED
|
@@ -1,10 +1,8 @@
|
|
|
1
|
-
export { FieldGroup } from './FieldGroup.js';
|
|
2
1
|
export { getInvalidDurationPaths, setDurationValidity, } from './Fields/durationValidity.js';
|
|
3
2
|
export { default as NumberField, type INumberField, } from './Fields/NumberField.js';
|
|
4
3
|
export { ResourceOptionIcon } from './Fields/ResourceOptionIcon.js';
|
|
5
|
-
export { type FieldLabelBinding, FieldWrapper } from './FieldWrapper.js';
|
|
6
4
|
export { collectFieldsWithDefaults, DynamicDefaultsSync, DynamicForm, type DynamicFormProps, FieldsFromOptions, type FormValues, findSelfReferencingFieldNames, type ParentInfo, resolveMetaOverrides, useDynamicDefaultsSync, } from './Form.js';
|
|
7
|
-
export {
|
|
5
|
+
export { fieldFrame } from './fieldFrame.js';
|
|
8
6
|
export { type FieldComponent, FieldRegistryContext, Registry, } from './fieldRegistry.js';
|
|
9
7
|
export { type FormLayoutIssue, type FormLayoutNode, type LayoutBreakpoint, type LayoutGap, type LayoutTracks, type ResponsiveLayout, resolveFormLayout, } from './layout.js';
|
|
10
8
|
export { type LayoutCSSIssue, resolveLayoutCSS, } from './layoutCSS.js';
|
|
@@ -15,6 +13,8 @@ export { type ChoiceItem, useChoiceField } from './useChoiceField.js';
|
|
|
15
13
|
export { useFieldValue } from './useFieldValue.js';
|
|
16
14
|
export { useParsedOpts } from './useParsedOpts.js';
|
|
17
15
|
export { useDependentOptions, useFieldAt } from './utils/dependentOptions.js';
|
|
18
|
-
export { collectPartitionDurationIssues, FLEX_MAX_DURATION_RANGE, FLEX_WAIT_TIME_RANGE,
|
|
16
|
+
export { collectPartitionDurationIssues, FLEX_MAX_DURATION_RANGE, FLEX_WAIT_TIME_RANGE, formatDurationText, parseDurationText, STANDARD_MAX_DURATION_RANGE, } from './utils/duration.js';
|
|
17
|
+
export type { FieldOption, FieldOptionGroup, FieldOptionItem } from './utils/fieldItems.js';
|
|
19
18
|
export { getPlaceholder } from './utils/getPlaceholder.js';
|
|
20
|
-
export { applySecondaryField
|
|
19
|
+
export { applySecondaryField } from './utils/secondaryField.js';
|
|
20
|
+
export type { ServerError } from './validation.js';
|
package/dist/form/index.js
CHANGED
|
@@ -1,19 +1,17 @@
|
|
|
1
|
-
import { applySecondaryField
|
|
1
|
+
import { applySecondaryField } from "./utils/secondaryField.js";
|
|
2
2
|
import { enforceOneMustBeTrue, flattenGroups, impureSetValueFromPath, initializeValues, resolvedFlag } from "./lib.js";
|
|
3
|
-
import { FieldGroup } from "./FieldGroup.js";
|
|
4
3
|
import { resolveFormLayout } from "./layout.js";
|
|
5
4
|
import { resolveLayoutCSS } from "./layoutCSS.js";
|
|
6
|
-
import {
|
|
7
|
-
import { FieldWrapper } from "./FieldWrapper.js";
|
|
5
|
+
import { fieldFrame } from "./fieldFrame.js";
|
|
8
6
|
import { useFieldValue } from "./useFieldValue.js";
|
|
9
7
|
import { useChoiceField } from "./useChoiceField.js";
|
|
10
8
|
import { useDependentOptions, useFieldAt } from "./utils/dependentOptions.js";
|
|
11
9
|
import { getPlaceholder } from "./utils/getPlaceholder.js";
|
|
12
|
-
import { FLEX_MAX_DURATION_RANGE, FLEX_WAIT_TIME_RANGE, STANDARD_MAX_DURATION_RANGE, collectPartitionDurationIssues,
|
|
10
|
+
import { FLEX_MAX_DURATION_RANGE, FLEX_WAIT_TIME_RANGE, STANDARD_MAX_DURATION_RANGE, collectPartitionDurationIssues, formatDurationText, parseDurationText } from "./utils/duration.js";
|
|
13
11
|
import { getInvalidDurationPaths, setDurationValidity } from "./Fields/durationValidity.js";
|
|
14
12
|
import NumberField from "./Fields/NumberField.js";
|
|
15
13
|
import { FieldRegistryContext, Registry } from "./fieldRegistry.js";
|
|
16
14
|
import { useParsedOpts } from "./useParsedOpts.js";
|
|
17
15
|
import { DynamicDefaultsSync, DynamicForm, FieldsFromOptions, collectFieldsWithDefaults, findSelfReferencingFieldNames, resolveMetaOverrides, useDynamicDefaultsSync } from "./Form.js";
|
|
18
16
|
import { ResourceOptionIcon } from "./Fields/ResourceOptionIcon.js";
|
|
19
|
-
export { DynamicDefaultsSync, DynamicForm, FLEX_MAX_DURATION_RANGE, FLEX_WAIT_TIME_RANGE,
|
|
17
|
+
export { DynamicDefaultsSync, DynamicForm, FLEX_MAX_DURATION_RANGE, FLEX_WAIT_TIME_RANGE, FieldRegistryContext, FieldsFromOptions, NumberField, Registry, ResourceOptionIcon, STANDARD_MAX_DURATION_RANGE, applySecondaryField, collectFieldsWithDefaults, collectPartitionDurationIssues, enforceOneMustBeTrue, fieldFrame, findSelfReferencingFieldNames, flattenGroups, formatDurationText, getInvalidDurationPaths, getPlaceholder, impureSetValueFromPath, initializeValues, parseDurationText, resolveFormLayout, resolveLayoutCSS, resolveMetaOverrides, resolvedFlag, setDurationValidity, useChoiceField, useDependentOptions, useDynamicDefaultsSync, useFieldAt, useFieldValue, useParsedOpts };
|
package/dist/form/layoutCSS.js
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { isDarkColor } from "../theme/contrast.js";
|
|
2
|
+
import { deriveTheme } from "../theme/derive.js";
|
|
2
3
|
import { generate, lexer, parse, walk } from "css-tree";
|
|
3
4
|
//#region src/form/layoutCSS.ts
|
|
4
5
|
var properties = /* @__PURE__ */ new Set([
|
|
@@ -213,10 +214,10 @@ function resolveLayoutCSS(css) {
|
|
|
213
214
|
delete style["--form-accent"];
|
|
214
215
|
return {
|
|
215
216
|
style: {
|
|
216
|
-
...deriveTheme({
|
|
217
|
-
background,
|
|
217
|
+
...deriveTheme({ interface: {
|
|
218
|
+
base: background,
|
|
218
219
|
accent: expandHex(accent)
|
|
219
|
-
}),
|
|
220
|
+
} }),
|
|
220
221
|
backgroundColor: background,
|
|
221
222
|
color: "var(--theme-app)",
|
|
222
223
|
colorScheme: isDarkColor(background) ? "dark" : "light",
|
|
@@ -3,6 +3,7 @@ import type { BaseField, LabelPosition, RuntimeFieldExtensions } from './fieldTy
|
|
|
3
3
|
interface FieldBase {
|
|
4
4
|
type?: string;
|
|
5
5
|
label?: string;
|
|
6
|
+
description?: string;
|
|
6
7
|
hidden?: boolean | string;
|
|
7
8
|
disabled?: boolean | string;
|
|
8
9
|
optional?: boolean | string;
|
|
@@ -12,15 +13,16 @@ interface FieldBase {
|
|
|
12
13
|
}
|
|
13
14
|
/**
|
|
14
15
|
* What the form hands a field component. The field binds to its own value by `field.name`, with
|
|
15
|
-
* `useFieldValue
|
|
16
|
+
* `useFieldValue`, which also gives the form its rules, and reads any other with `useWatch`, so it
|
|
16
17
|
* renders again only when what it reads changes.
|
|
17
18
|
*/
|
|
18
19
|
export interface FieldComponentProps<TField extends FieldBase = FieldBase> {
|
|
19
20
|
field: TField;
|
|
20
21
|
label: string;
|
|
21
22
|
labelPosition: LabelPosition;
|
|
22
|
-
/**
|
|
23
|
-
|
|
23
|
+
/** What the form found wrong with the field's value, such as a value it needs or one the server
|
|
24
|
+
* rejected, shown under it; undefined while it has nothing to say. */
|
|
25
|
+
error?: string | undefined;
|
|
24
26
|
onChange?: ((val: unknown) => void) | undefined;
|
|
25
27
|
disabled: boolean;
|
|
26
28
|
computeOn?: boolean | undefined;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { itemValue, leaves } from "./utils/fieldItems.js";
|
|
1
|
+
import { findChoice, itemValue, leaves } from "./utils/fieldItems.js";
|
|
2
2
|
import { applySecondaryField } from "./utils/secondaryField.js";
|
|
3
3
|
import { useFieldValue } from "./useFieldValue.js";
|
|
4
4
|
import { useEffect, useEffectEvent, useRef } from "react";
|
|
@@ -17,8 +17,7 @@ function useChoiceField({ name, items, autoselect, secondaryField, onChange }) {
|
|
|
17
17
|
const [value, change] = useFieldValue(name);
|
|
18
18
|
const { setValue } = useFormContext();
|
|
19
19
|
const choose = (next) => {
|
|
20
|
-
|
|
21
|
-
applySecondaryField(secondaryField, chosen?.secondaryValue, (field, secondary) => setValue(field, secondary, { shouldDirty: true }));
|
|
20
|
+
applySecondaryField(secondaryField, findChoice(items, next)?.secondaryValue, (field, secondary) => setValue(field, secondary, { shouldDirty: true }));
|
|
22
21
|
onChange?.(next);
|
|
23
22
|
change(next);
|
|
24
23
|
};
|
|
@@ -3,5 +3,8 @@
|
|
|
3
3
|
* value changes, not when another field's does. A change marks the field touched as well as dirty: the
|
|
4
4
|
* form stops writing a computed default into a field once the person has set it, and a pick from a list
|
|
5
5
|
* sets a value without the blur that would otherwise mark it.
|
|
6
|
+
*
|
|
7
|
+
* It also gives the form the field's rules, such as needing a value, so a field component binds its
|
|
8
|
+
* value here rather than with its own `useController`.
|
|
6
9
|
*/
|
|
7
10
|
export declare function useFieldValue<T>(name: string): [T, (value: T) => void];
|
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { RequiredFieldContext, filled } from "./validation.js";
|
|
2
|
+
import { use, useCallback } from "react";
|
|
2
3
|
import { useController, useFormContext } from "react-hook-form";
|
|
3
4
|
//#region src/form/useFieldValue.ts
|
|
4
5
|
/**
|
|
@@ -6,14 +7,30 @@ import { useController, useFormContext } from "react-hook-form";
|
|
|
6
7
|
* value changes, not when another field's does. A change marks the field touched as well as dirty: the
|
|
7
8
|
* form stops writing a computed default into a field once the person has set it, and a pick from a list
|
|
8
9
|
* sets a value without the blur that would otherwise mark it.
|
|
10
|
+
*
|
|
11
|
+
* It also gives the form the field's rules, such as needing a value, so a field component binds its
|
|
12
|
+
* value here rather than with its own `useController`.
|
|
9
13
|
*/
|
|
10
14
|
function useFieldValue(name) {
|
|
11
|
-
const
|
|
12
|
-
const
|
|
13
|
-
const
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
})
|
|
15
|
+
const required = use(RequiredFieldContext);
|
|
16
|
+
const message = required?.name === name ? required.message : void 0;
|
|
17
|
+
const { field } = useController({
|
|
18
|
+
name,
|
|
19
|
+
rules: message === void 0 ? {} : { validate: { required: (value) => filled(value) || message } }
|
|
20
|
+
});
|
|
21
|
+
const { setValue, getFieldState, trigger } = useFormContext();
|
|
22
|
+
const change = useCallback((value) => {
|
|
23
|
+
setValue(name, value, {
|
|
24
|
+
shouldDirty: true,
|
|
25
|
+
shouldTouch: true
|
|
26
|
+
});
|
|
27
|
+
if (getFieldState(name).invalid) trigger(name);
|
|
28
|
+
}, [
|
|
29
|
+
name,
|
|
30
|
+
setValue,
|
|
31
|
+
getFieldState,
|
|
32
|
+
trigger
|
|
33
|
+
]);
|
|
17
34
|
return [field.value, change];
|
|
18
35
|
}
|
|
19
36
|
//#endregion
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
export declare function
|
|
2
|
-
export declare function
|
|
1
|
+
export declare function parseDurationText(text: string): number | null;
|
|
2
|
+
export declare function formatDurationText(totalSeconds: number): string;
|
|
3
3
|
export declare const FLEX_MAX_DURATION_RANGE: {
|
|
4
4
|
min: number;
|
|
5
5
|
max: number;
|
|
@@ -2,7 +2,7 @@ import { Duration } from "luxon";
|
|
|
2
2
|
//#region src/form/utils/duration.ts
|
|
3
3
|
var WITH_DAYS = /^(\d+)-(\d{1,2})(?::(\d{1,2})(?::(\d{1,2}))?)?$/;
|
|
4
4
|
var WITHOUT_DAYS = /^(\d+):(\d{1,2}):(\d{1,2})$/;
|
|
5
|
-
function
|
|
5
|
+
function parseDurationText(text) {
|
|
6
6
|
const trimmed = text.trim();
|
|
7
7
|
let days = 0;
|
|
8
8
|
let hours;
|
|
@@ -25,7 +25,7 @@ function parseDuration(text) {
|
|
|
25
25
|
if (minutes > 59 || seconds > 59) return null;
|
|
26
26
|
return days * 86400 + hours * 3600 + minutes * 60 + seconds;
|
|
27
27
|
}
|
|
28
|
-
function
|
|
28
|
+
function formatDurationText(totalSeconds) {
|
|
29
29
|
if (!Number.isFinite(totalSeconds) || totalSeconds < 0) return "";
|
|
30
30
|
const parts = Duration.fromObject({ seconds: Math.floor(totalSeconds) }).shiftTo("days", "hours", "minutes", "seconds");
|
|
31
31
|
const pad = (n) => String(n).padStart(2, "0");
|
|
@@ -66,4 +66,4 @@ function collectPartitionDurationIssues(partitions, invalidDurationPaths) {
|
|
|
66
66
|
return [...issues];
|
|
67
67
|
}
|
|
68
68
|
//#endregion
|
|
69
|
-
export { FLEX_MAX_DURATION_RANGE, FLEX_WAIT_TIME_RANGE, STANDARD_MAX_DURATION_RANGE, collectPartitionDurationIssues,
|
|
69
|
+
export { FLEX_MAX_DURATION_RANGE, FLEX_WAIT_TIME_RANGE, STANDARD_MAX_DURATION_RANGE, collectPartitionDurationIssues, formatDurationText, parseDurationText };
|
|
@@ -1,7 +1,9 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* A field's path as the form store names it
|
|
3
|
-
*
|
|
4
|
-
*
|
|
2
|
+
* A field's path as the form store names it, from any way a path to it is written: a workflow's
|
|
3
|
+
* `hosts[0].cpus`, the store's own `hosts.0.cpus`, or a JSON Pointer such as `#/hosts/0/cpus`, as a
|
|
4
|
+
* problem response locates a field. A workflow writes rows with brackets, but the store tells a field
|
|
5
|
+
* of a change by a path it starts, so a row's fields hear a change to their list only when both name
|
|
6
|
+
* it with dots.
|
|
5
7
|
*/
|
|
6
8
|
export declare function fieldPath(path: string): string;
|
|
7
9
|
/** The index of the innermost row a path is in, or undefined outside every list. */
|