@nivaro/react 0.2.53 → 0.2.55
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/full.css +1 -1
- package/dist/hooks/useSessionRecorder.js +99 -98
- package/dist/index.d.ts +452 -4
- package/dist/index.js +644 -618
- package/dist/layout-editor.d.ts +252 -2
- package/dist/shared/components/BackgroundRunOffer.js +117 -0
- package/dist/shared/components/BroadcastView.js +214 -213
- package/dist/shared/components/CollectionBrowserView.js +2592 -2695
- package/dist/shared/components/FormWhatsNew.js +60 -0
- package/dist/shared/components/ItemEditForm.js +3968 -3618
- package/dist/shared/components/JobsTray.js +100 -55
- package/dist/shared/components/MyWorkView.js +91 -89
- package/dist/shared/components/NotificationBell.js +80 -79
- package/dist/shared/components/ProfileView.js +568 -520
- package/dist/shared/components/RecordCompare.js +254 -0
- package/dist/shared/components/RecordReadView.js +598 -543
- package/dist/shared/components/ReportView.js +578 -543
- package/dist/shared/components/RowPresence.js +91 -0
- package/dist/shared/components/TipLayer.js +27 -27
- package/dist/shared/components/WidgetSlot.js +474 -458
- package/dist/shared/components/ai/AiAnalyticsView.js +16 -6
- package/dist/shared/components/ai/AskPanel.js +139 -119
- package/dist/shared/components/ai/FirstWeekCard.js +126 -0
- package/dist/shared/components/bulk/BulkFieldUpdate.js +289 -0
- package/dist/shared/components/bulk/bulk-field-options.js +45 -0
- package/dist/shared/components/charts/CumulativeFlowChart.js +176 -0
- package/dist/shared/components/chat/ChannelArchive.js +326 -0
- package/dist/shared/components/chat/ChannelExtras.js +141 -121
- package/dist/shared/components/chat/ChatAnalyticsView.js +112 -110
- package/dist/shared/components/chat/ChatPanel.js +1695 -1733
- package/dist/shared/components/chat/Composer.js +357 -303
- package/dist/shared/components/chat/MessageActions.js +92 -0
- package/dist/shared/components/chat/MessageFormat.js +290 -264
- package/dist/shared/components/chat/OutboxBubbles.js +146 -0
- package/dist/shared/components/chat/RequestIdCard.js +135 -0
- package/dist/shared/components/chat/RoomHeaderMenu.js +202 -0
- package/dist/shared/components/chat/RoomParts.js +213 -274
- package/dist/shared/components/chat/ScreenClip.js +184 -0
- package/dist/shared/components/chat/chat-core.js +402 -483
- package/dist/shared/components/chat/chat-drafts.js +59 -0
- package/dist/shared/components/chat/chat-emoji.js +348 -0
- package/dist/shared/components/chat/chat-local-time.js +41 -0
- package/dist/shared/components/chat/chat-outbox.js +303 -0
- package/dist/shared/components/chat/chat-window.js +163 -0
- package/dist/shared/components/chat/huddle/HuddleControls.js +143 -0
- package/dist/shared/components/chat/huddle/HuddleStage.js +164 -0
- package/dist/shared/components/chat/huddle/huddle-store.js +342 -0
- package/dist/shared/components/chat/huddle/useHuddle.js +58 -0
- package/dist/shared/components/help-videos/api.js +80 -67
- package/dist/shared/components/help-videos/editor/DetailsTab.js +147 -130
- package/dist/shared/components/item-edit/CatalogPickerField.js +113 -112
- package/dist/shared/components/item-edit/ChangeReasonDialog.js +13 -13
- package/dist/shared/components/item-edit/FieldAffordances.js +9 -8
- package/dist/shared/components/item-edit/FieldRenderer.js +248 -245
- package/dist/shared/components/item-edit/FieldRow.js +382 -320
- package/dist/shared/components/item-edit/FormHelpVideoButton.js +59 -0
- package/dist/shared/components/item-edit/GroupSection.js +786 -639
- package/dist/shared/components/item-edit/HeaderTools.js +59 -56
- package/dist/shared/components/item-edit/InlineTableField.js +3 -1
- package/dist/shared/components/item-edit/LayoutContentBlock.js +47 -24
- package/dist/shared/components/item-edit/RelationCombobox.js +186 -176
- package/dist/shared/components/item-edit/entry/EntryStrip.js +54 -0
- package/dist/shared/components/item-edit/entry/entry-keys.js +27 -0
- package/dist/shared/components/item-edit/entry/useEntryKeyboard.js +70 -0
- package/dist/shared/components/item-edit/entry/useEntryMode.js +59 -0
- package/dist/shared/components/item-edit/form-structure-ui.js +105 -0
- package/dist/shared/components/item-edit/lazy-sections.js +36 -0
- package/dist/shared/components/item-edit/lock-why.js +94 -0
- package/dist/shared/components/item-edit/picker-miss.js +26 -0
- package/dist/shared/components/item-edit/placement-behaviour.js +196 -0
- package/dist/shared/components/item-edit/useFormUsageBeacon.js +65 -0
- package/dist/shared/components/layout-editor/AddPanel.js +226 -151
- package/dist/shared/components/layout-editor/ArrangeButton.js +34 -0
- package/dist/shared/components/layout-editor/AutoArrange.js +86 -0
- package/dist/shared/components/layout-editor/CanvasCompare.js +79 -0
- package/dist/shared/components/layout-editor/ChangeNote.js +147 -0
- package/dist/shared/components/layout-editor/CollabParts.js +175 -0
- package/dist/shared/components/layout-editor/DesignNode.js +311 -116
- package/dist/shared/components/layout-editor/EditorCanvas.js +30 -26
- package/dist/shared/components/layout-editor/EditorTopBar.js +463 -175
- package/dist/shared/components/layout-editor/FindReplace.js +188 -0
- package/dist/shared/components/layout-editor/FormMapButton.js +141 -0
- package/dist/shared/components/layout-editor/HistoryPanel.js +250 -109
- package/dist/shared/components/layout-editor/LayoutEditor.js +1196 -305
- package/dist/shared/components/layout-editor/LayoutsRail.js +94 -67
- package/dist/shared/components/layout-editor/NoteMarker.js +38 -0
- package/dist/shared/components/layout-editor/PlacementsTable.js +187 -0
- package/dist/shared/components/layout-editor/RestorePiece.js +143 -0
- package/dist/shared/components/layout-editor/ScheduleChange.js +106 -0
- package/dist/shared/components/layout-editor/SessionHistory.js +84 -0
- package/dist/shared/components/layout-editor/StagedChip.js +22 -0
- package/dist/shared/components/layout-editor/StructureMenu.js +464 -0
- package/dist/shared/components/layout-editor/UnsavedConfirm.js +103 -0
- package/dist/shared/components/layout-editor/ai/AiToolsButton.js +625 -0
- package/dist/shared/components/layout-editor/ai/ChangeCheck.js +153 -0
- package/dist/shared/components/layout-editor/ai/ai-tools-api.js +80 -0
- package/dist/shared/components/layout-editor/ai/assist-ops.js +38 -0
- package/dist/shared/components/layout-editor/ai/autofill-ops.js +73 -0
- package/dist/shared/components/layout-editor/ai/canvas-capture.js +41 -0
- package/dist/shared/components/layout-editor/ai-forms/AiComposer.js +271 -0
- package/dist/shared/components/layout-editor/ai-forms/AiFormsButton.js +182 -0
- package/dist/shared/components/layout-editor/ai-forms/MeaningSuggestions.js +109 -0
- package/dist/shared/components/layout-editor/ai-forms/SlimPanel.js +170 -0
- package/dist/shared/components/layout-editor/ai-forms/ai-forms-api.js +40 -0
- package/dist/shared/components/layout-editor/ai-forms/pending.js +25 -0
- package/dist/shared/components/layout-editor/ai-forms/plan.js +263 -0
- package/dist/shared/components/layout-editor/ai-rules/AiAskPopover.js +160 -0
- package/dist/shared/components/layout-editor/ai-rules/CascadeWriter.js +175 -0
- package/dist/shared/components/layout-editor/ai-rules/FieldRuleWriter.js +97 -0
- package/dist/shared/components/layout-editor/ai-rules/RuleWriter.js +94 -0
- package/dist/shared/components/layout-editor/ai-rules/ValidationSuggest.js +153 -0
- package/dist/shared/components/layout-editor/ai-rules/api.js +6 -0
- package/dist/shared/components/layout-editor/ai-text/AiTextTools.js +383 -0
- package/dist/shared/components/layout-editor/ai-text/text-ops.js +125 -0
- package/dist/shared/components/layout-editor/assist/AskPanel.js +278 -0
- package/dist/shared/components/layout-editor/assist/ExplainDiff.js +93 -0
- package/dist/shared/components/layout-editor/assist/ProposalsButton.js +150 -0
- package/dist/shared/components/layout-editor/assist/assist-api.js +63 -0
- package/dist/shared/components/layout-editor/assist/jump.js +142 -0
- package/dist/shared/components/layout-editor/assist/settings-index.js +118 -0
- package/dist/shared/components/layout-editor/auto-arrange.js +101 -0
- package/dist/shared/components/layout-editor/bulk/BulkChangesButton.js +221 -0
- package/dist/shared/components/layout-editor/bulk/BulkRun.js +237 -0
- package/dist/shared/components/layout-editor/bulk/MacrosPanel.js +230 -0
- package/dist/shared/components/layout-editor/bulk/bulk-api.js +65 -0
- package/dist/shared/components/layout-editor/bulk/field-labels.js +22 -0
- package/dist/shared/components/layout-editor/bulk/macro-record.js +142 -0
- package/dist/shared/components/layout-editor/bulk/useMacroRecorder.js +65 -0
- package/dist/shared/components/layout-editor/bundle-to-active.js +1 -0
- package/dist/shared/components/layout-editor/canvas-diff.js +157 -0
- package/dist/shared/components/layout-editor/collab/FormFollowShare.js +388 -0
- package/dist/shared/components/layout-editor/collab/collab-api.js +80 -0
- package/dist/shared/components/layout-editor/commands/CommandPalette.js +221 -0
- package/dist/shared/components/layout-editor/commands/intents.js +214 -0
- package/dist/shared/components/layout-editor/commands/parse.js +242 -0
- package/dist/shared/components/layout-editor/design-context.js +26 -6
- package/dist/shared/components/layout-editor/dnd/LayoutDndProvider.js +181 -164
- package/dist/shared/components/layout-editor/dnd/collision.js +25 -23
- package/dist/shared/components/layout-editor/dnd/node.js +69 -57
- package/dist/shared/components/layout-editor/dnd/rail-drop.js +56 -0
- package/dist/shared/components/layout-editor/draft-recovery.js +131 -0
- package/dist/shared/components/layout-editor/editor-notes.js +78 -0
- package/dist/shared/components/layout-editor/editors/swap-config.js +1 -0
- package/dist/shared/components/layout-editor/entry/PlacementPresets.js +149 -0
- package/dist/shared/components/layout-editor/entry/entry-editor-context.js +10 -0
- package/dist/shared/components/layout-editor/entry/presets.js +71 -0
- package/dist/shared/components/layout-editor/entry/tab-order.js +110 -0
- package/dist/shared/components/layout-editor/entry/theme-preview.js +37 -0
- package/dist/shared/components/layout-editor/explain/CanvasRules.js +142 -0
- package/dist/shared/components/layout-editor/explain/default-ghosts.js +81 -0
- package/dist/shared/components/layout-editor/explain/driver-hover.js +62 -0
- package/dist/shared/components/layout-editor/explain/field-sources.js +246 -0
- package/dist/shared/components/layout-editor/explain/rule-graph.js +215 -0
- package/dist/shared/components/layout-editor/explain/use-explain.js +132 -0
- package/dist/shared/components/layout-editor/field-zones.js +116 -0
- package/dist/shared/components/layout-editor/form-map.js +138 -0
- package/dist/shared/components/layout-editor/grid-guides.js +142 -0
- package/dist/shared/components/layout-editor/history-api.js +87 -0
- package/dist/shared/components/layout-editor/inheritance.js +55 -0
- package/dist/shared/components/layout-editor/inspect/inspect-api.js +66 -0
- package/dist/shared/components/layout-editor/inspect/picker-preview.js +48 -0
- package/dist/shared/components/layout-editor/inspect/width-fit.js +87 -0
- package/dist/shared/components/layout-editor/inspector/AiFillSetting.js +85 -0
- package/dist/shared/components/layout-editor/inspector/BehaviourSettings.js +402 -0
- package/dist/shared/components/layout-editor/inspector/Breadcrumb.js +36 -0
- package/dist/shared/components/layout-editor/inspector/BulkInspector.js +179 -0
- package/dist/shared/components/layout-editor/inspector/ColumnFit.js +112 -0
- package/dist/shared/components/layout-editor/inspector/GroupInspector.js +291 -141
- package/dist/shared/components/layout-editor/inspector/HelpTab.js +174 -0
- package/dist/shared/components/layout-editor/inspector/Inspector.js +282 -180
- package/dist/shared/components/layout-editor/inspector/LookTab.js +166 -109
- package/dist/shared/components/layout-editor/inspector/OverrideNotice.js +61 -0
- package/dist/shared/components/layout-editor/inspector/PickerMisses.js +129 -0
- package/dist/shared/components/layout-editor/inspector/PickerPreview.js +134 -0
- package/dist/shared/components/layout-editor/inspector/PickerTab.js +146 -118
- package/dist/shared/components/layout-editor/inspector/RulesTab.js +162 -111
- package/dist/shared/components/layout-editor/inspector/Translations.js +156 -0
- package/dist/shared/components/layout-editor/inspector/kit.js +71 -70
- package/dist/shared/components/layout-editor/inspector/tab-request.js +21 -0
- package/dist/shared/components/layout-editor/is-typing.js +9 -0
- package/dist/shared/components/layout-editor/keyboard-move.js +66 -0
- package/dist/shared/components/layout-editor/lint/LintPanel.js +190 -0
- package/dist/shared/components/layout-editor/lint/lint-api.js +52 -0
- package/dist/shared/components/layout-editor/load-error.js +37 -0
- package/dist/shared/components/layout-editor/matrix/FieldStateMatrix.js +305 -0
- package/dist/shared/components/layout-editor/matrix/MatrixGrid.js +181 -0
- package/dist/shared/components/layout-editor/matrix/RoleSectionMatrix.js +147 -0
- package/dist/shared/components/layout-editor/matrix/matrix-api.js +48 -0
- package/dist/shared/components/layout-editor/matrix/role-matrix.js +36 -0
- package/dist/shared/components/layout-editor/matrix/state-matrix.js +145 -0
- package/dist/shared/components/layout-editor/nav/FindPanel.js +109 -0
- package/dist/shared/components/layout-editor/nav/NavTools.js +114 -0
- package/dist/shared/components/layout-editor/nav/OutlinePanel.js +228 -0
- package/dist/shared/components/layout-editor/nav/ShortcutSheet.js +31 -0
- package/dist/shared/components/layout-editor/nav/find.js +20 -0
- package/dist/shared/components/layout-editor/nav/tree.js +142 -0
- package/dist/shared/components/layout-editor/nav/useEditorNav.js +101 -0
- package/dist/shared/components/layout-editor/nav/view-prefs.js +34 -0
- package/dist/shared/components/layout-editor/ops/ChangeRequestsPanel.js +143 -0
- package/dist/shared/components/layout-editor/ops/DependencyDiagram.js +179 -0
- package/dist/shared/components/layout-editor/ops/LayoutOpsBlocks.js +92 -0
- package/dist/shared/components/layout-editor/ops/PromotePanel.js +287 -0
- package/dist/shared/components/layout-editor/ops/ops-api.js +122 -0
- package/dist/shared/components/layout-editor/outputs/OutputsButton.js +254 -0
- package/dist/shared/components/layout-editor/outputs/help-sheet.js +154 -0
- package/dist/shared/components/layout-editor/outputs/output-api.js +61 -0
- package/dist/shared/components/layout-editor/overview/OverviewActions.js +15 -3
- package/dist/shared/components/layout-editor/overview/describe-conditions.js +24 -14
- package/dist/shared/components/layout-editor/overview/overview-api.js +105 -88
- package/dist/shared/components/layout-editor/overview/purpose.js +15 -13
- package/dist/shared/components/layout-editor/panel-style.js +8 -7
- package/dist/shared/components/layout-editor/parity-keys.json.js +4 -0
- package/dist/shared/components/layout-editor/pin.js +25 -0
- package/dist/shared/components/layout-editor/presence.js +111 -0
- package/dist/shared/components/layout-editor/preview/PreviewModes.js +224 -0
- package/dist/shared/components/layout-editor/preview/PreviewPanes.js +262 -0
- package/dist/shared/components/layout-editor/preview/preview-api.js +57 -0
- package/dist/shared/components/layout-editor/preview/preview-model.js +157 -0
- package/dist/shared/components/layout-editor/restore-piece.js +192 -0
- package/dist/shared/components/layout-editor/reuse/FieldMapStep.js +70 -0
- package/dist/shared/components/layout-editor/reuse/FormMoreMenu.js +127 -0
- package/dist/shared/components/layout-editor/reuse/LibraryRows.js +150 -0
- package/dist/shared/components/layout-editor/reuse/NewFormStart.js +20 -0
- package/dist/shared/components/layout-editor/reuse/SectionReuseActions.js +291 -0
- package/dist/shared/components/layout-editor/reuse/field-match.js +77 -0
- package/dist/shared/components/layout-editor/reuse/reuse-api.js +73 -0
- package/dist/shared/components/layout-editor/reuse/seed.js +13 -0
- package/dist/shared/components/layout-editor/reuse/useFormFromRecord.js +43 -0
- package/dist/shared/components/layout-editor/reuse/useRailCopy.js +34 -0
- package/dist/shared/components/layout-editor/section-structure.js +241 -0
- package/dist/shared/components/layout-editor/settings/EntrySection.js +296 -0
- package/dist/shared/components/layout-editor/settings/FormSettings.js +125 -103
- package/dist/shared/components/layout-editor/settings/InheritanceSection.js +1 -1
- package/dist/shared/components/layout-editor/settings/ResolveSettings.js +255 -0
- package/dist/shared/components/layout-editor/settings/ToolsSection.js +215 -105
- package/dist/shared/components/layout-editor/settings/WhoSection.js +139 -100
- package/dist/shared/components/layout-editor/settings/controls.js +8 -8
- package/dist/shared/components/layout-editor/settings/settings-registry.js +142 -21
- package/dist/shared/components/layout-editor/shortcuts.js +88 -0
- package/dist/shared/components/layout-editor/show-when.js +35 -0
- package/dist/shared/components/layout-editor/slot-names.js +4 -3
- package/dist/shared/components/layout-editor/staged-api.js +64 -0
- package/dist/shared/components/layout-editor/structure-ops.js +403 -0
- package/dist/shared/components/layout-editor/testing/CostLimitSetting.js +42 -0
- package/dist/shared/components/layout-editor/testing/TestingPanels.js +556 -0
- package/dist/shared/components/layout-editor/testing/testing-api.js +67 -0
- package/dist/shared/components/layout-editor/testing/testing-model.js +406 -0
- package/dist/shared/components/layout-editor/testing/use-record-check.js +44 -0
- package/dist/shared/components/layout-editor/toolbar-kit.js +242 -0
- package/dist/shared/components/layout-editor/unsaved-marks.js +72 -0
- package/dist/shared/components/layout-editor/usage/AbTestSection.js +355 -0
- package/dist/shared/components/layout-editor/usage/FillChip.js +27 -0
- package/dist/shared/components/layout-editor/usage/UsagePanel.js +232 -0
- package/dist/shared/components/layout-editor/usage/ab-api.js +86 -0
- package/dist/shared/components/layout-editor/usage/suggest-collapse.js +32 -0
- package/dist/shared/components/layout-editor/usage/suggest-sections.js +55 -0
- package/dist/shared/components/layout-editor/usage/usage-api.js +104 -0
- package/dist/shared/components/layout-editor/useLayoutDraft.js +573 -306
- package/dist/shared/components/notifications/NotificationAnalyticsView.js +148 -77
- package/dist/shared/components/panels/ErpFailureBanner.js +18 -17
- package/dist/shared/components/panels/ExternalRequestsChip.js +63 -62
- package/dist/shared/components/pipeline/PipelineEditorView.js +106 -104
- package/dist/shared/components/profile/AgentsPanel.js +479 -0
- package/dist/shared/components/queue/QueueWorklist.js +1026 -1040
- package/dist/shared/components/support/SuggestFormChange.js +143 -0
- package/dist/shared/components/support/SupportAnalytics.js +171 -0
- package/dist/shared/components/support/SupportView.js +75 -73
- package/dist/shared/lib/ai-fill.js +37 -0
- package/dist/shared/lib/background-runs.js +150 -0
- package/dist/shared/lib/delivery-ack.js +9 -0
- package/dist/shared/lib/entry-badge-style.js +13 -0
- package/dist/shared/lib/entry-config.js +71 -0
- package/dist/shared/lib/form-sections.js +64 -0
- package/dist/shared/lib/form-structure.js +99 -0
- package/dist/shared/lib/form-usage-beacon.js +133 -0
- package/dist/shared/lib/jobs-tray.js +25 -23
- package/dist/shared/lib/keyset-pager.js +37 -0
- package/dist/shared/lib/layout-i18n.js +66 -0
- package/dist/shared/lib/layout-lint.js +490 -0
- package/dist/shared/lib/layout-ops.js +116 -110
- package/dist/shared/lib/layout-resolve.js +113 -0
- package/dist/shared/lib/placement-behaviour.js +144 -0
- package/dist/shared/lib/prefetch.js +149 -0
- package/dist/shared/lib/presence-hooks.js +199 -0
- package/dist/shared/lib/record-outbox.js +82 -81
- package/dist/shared/lib/replay-socket.js +93 -0
- package/dist/shared/lib/request-gate.js +51 -50
- package/dist/shared/lib/room-gaps.js +96 -0
- package/dist/shared/lib/screenshot.js +54 -28
- package/dist/shared/lib/search-log.js +27 -0
- package/dist/shared/lib/socket-realtime.js +101 -80
- package/dist/shared/lib/visible-when.js +34 -0
- package/dist/shared/lib/worker-socket.js +200 -0
- package/package.json +1 -1
|
@@ -1,146 +1,168 @@
|
|
|
1
|
-
import { jsxs as
|
|
2
|
-
import { Search as
|
|
3
|
-
import { useState as
|
|
4
|
-
import { cn as
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
11
|
-
import {
|
|
12
|
-
import {
|
|
13
|
-
import {
|
|
14
|
-
import {
|
|
15
|
-
import {
|
|
16
|
-
import {
|
|
17
|
-
import {
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
1
|
+
import { jsxs as i, jsx as o } from "react/jsx-runtime";
|
|
2
|
+
import { Search as T, X as B, MessageCircleQuestion as F } from "lucide-react";
|
|
3
|
+
import { useState as M, useMemo as c, useCallback as q } from "react";
|
|
4
|
+
import { cn as u } from "../../../lib/utils.js";
|
|
5
|
+
import { isWhereQuestion as E } from "../assist/settings-index.js";
|
|
6
|
+
import { PanelHeader as I } from "../panel-frame.js";
|
|
7
|
+
import { groupTitle as O } from "../panel-style.js";
|
|
8
|
+
import { AddendumSection as P } from "./AddendumSection.js";
|
|
9
|
+
import { ButtonsSection as Q } from "./ButtonsSection.js";
|
|
10
|
+
import { inputCls as R, quietText as _, VisibleSettingsContext as j } from "./controls.js";
|
|
11
|
+
import { DefaultsSection as A } from "./DefaultsSection.js";
|
|
12
|
+
import { EntrySection as D } from "./EntrySection.js";
|
|
13
|
+
import { InheritanceSection as L } from "./InheritanceSection.js";
|
|
14
|
+
import { LayoutSection as W } from "./LayoutSection.js";
|
|
15
|
+
import { PdfSection as $ } from "./PdfSection.js";
|
|
16
|
+
import { ReadSection as z } from "./ReadSection.js";
|
|
17
|
+
import { layoutKindOf as H, visibleSections as K } from "./settings-registry.js";
|
|
18
|
+
import { ToolsSection as V } from "./ToolsSection.js";
|
|
19
|
+
import { WhoSection as X } from "./WhoSection.js";
|
|
20
|
+
const G = {
|
|
21
|
+
who: X,
|
|
22
|
+
layout: W,
|
|
23
|
+
buttons: Q,
|
|
24
|
+
read: z,
|
|
25
|
+
pdf: $,
|
|
26
|
+
addendum: P,
|
|
27
|
+
defaults: A,
|
|
28
|
+
entry: D,
|
|
29
|
+
inheritance: L,
|
|
30
|
+
tools: V
|
|
28
31
|
};
|
|
29
|
-
function
|
|
30
|
-
bundle:
|
|
31
|
-
apply:
|
|
32
|
-
flush:
|
|
33
|
-
collection:
|
|
34
|
-
onPreviewRole:
|
|
35
|
-
previewRoleId:
|
|
36
|
-
onPreviewRoleChange:
|
|
32
|
+
function ht({
|
|
33
|
+
bundle: a,
|
|
34
|
+
apply: d,
|
|
35
|
+
flush: m,
|
|
36
|
+
collection: p,
|
|
37
|
+
onPreviewRole: y,
|
|
38
|
+
previewRoleId: x,
|
|
39
|
+
onPreviewRoleChange: v,
|
|
40
|
+
onAskWhere: f
|
|
37
41
|
}) {
|
|
38
|
-
const [
|
|
39
|
-
() => new Set(
|
|
40
|
-
[
|
|
41
|
-
),
|
|
42
|
+
const [r, h] = M(""), n = H(a.layout), s = c(() => K(n, r), [n, r]), S = c(
|
|
43
|
+
() => new Set(s.flatMap((t) => t.settings.map((e) => e.key))),
|
|
44
|
+
[s]
|
|
45
|
+
), b = q(() => m == null ? void 0 : m(), [m]), k = c(
|
|
42
46
|
() => ({
|
|
43
|
-
bundle:
|
|
44
|
-
layout:
|
|
45
|
-
kind:
|
|
46
|
-
collection:
|
|
47
|
-
set: (t, e,
|
|
47
|
+
bundle: a,
|
|
48
|
+
layout: a.layout,
|
|
49
|
+
kind: n,
|
|
50
|
+
collection: p,
|
|
51
|
+
set: (t, e, l) => d(
|
|
48
52
|
[{ op: "layout_update", patch: t }],
|
|
49
|
-
(
|
|
53
|
+
(l == null ? void 0 : l.undoable) === !1 ? { label: e, undoable: !1 } : { label: e }
|
|
50
54
|
),
|
|
51
|
-
setText: (t, e) =>
|
|
52
|
-
flush:
|
|
55
|
+
setText: (t, e) => d([{ op: "layout_update", patch: t }], { label: e, text: !0 }),
|
|
56
|
+
flush: b,
|
|
57
|
+
apply: (t, e) => d(t, e)
|
|
53
58
|
}),
|
|
54
|
-
[
|
|
55
|
-
),
|
|
56
|
-
const e = t.currentTarget,
|
|
57
|
-
for (const
|
|
58
|
-
const
|
|
59
|
-
|
|
59
|
+
[a, n, p, d, b]
|
|
60
|
+
), N = typeof a.layout.name == "string" ? a.layout.name : "", C = (t) => {
|
|
61
|
+
const e = t.currentTarget, l = e.getBoundingClientRect().top;
|
|
62
|
+
for (const g of e.querySelectorAll("[data-section-title]")) {
|
|
63
|
+
const w = e.scrollTop > 0 && Math.abs(g.getBoundingClientRect().top - l) < 1;
|
|
64
|
+
g.toggleAttribute("data-stuck", w);
|
|
60
65
|
}
|
|
61
66
|
};
|
|
62
|
-
return /* @__PURE__ */
|
|
67
|
+
return /* @__PURE__ */ i("div", { className: "flex h-full min-h-0 flex-col", "data-form-settings": n, children: [
|
|
63
68
|
/* @__PURE__ */ o(
|
|
64
|
-
|
|
69
|
+
I,
|
|
65
70
|
{
|
|
66
71
|
eyebrow: "Form settings",
|
|
67
|
-
title:
|
|
72
|
+
title: N || "This form",
|
|
68
73
|
sub: "Who gets this form and how it behaves",
|
|
69
|
-
children: /* @__PURE__ */
|
|
70
|
-
/* @__PURE__ */ o(
|
|
74
|
+
children: /* @__PURE__ */ i("div", { className: "relative", children: [
|
|
75
|
+
/* @__PURE__ */ o(T, { className: "pointer-events-none absolute left-2.5 top-1/2 h-3.5 w-3.5 -translate-y-1/2 text-slate-400" }),
|
|
71
76
|
/* @__PURE__ */ o(
|
|
72
77
|
"input",
|
|
73
78
|
{
|
|
74
|
-
value:
|
|
75
|
-
onChange: (t) =>
|
|
79
|
+
value: r,
|
|
80
|
+
onChange: (t) => h(t.target.value),
|
|
76
81
|
placeholder: "Find a setting…",
|
|
77
82
|
"aria-label": "Find a setting",
|
|
78
83
|
"data-settings-search": !0,
|
|
79
|
-
className:
|
|
84
|
+
className: u(R, "pl-8 pr-8")
|
|
80
85
|
}
|
|
81
86
|
),
|
|
82
|
-
|
|
87
|
+
r && /* @__PURE__ */ o(
|
|
83
88
|
"button",
|
|
84
89
|
{
|
|
85
90
|
type: "button",
|
|
86
91
|
"aria-label": "Clear search",
|
|
87
|
-
onClick: () =>
|
|
92
|
+
onClick: () => h(""),
|
|
88
93
|
className: "absolute right-2 top-1/2 -translate-y-1/2 rounded p-0.5 text-slate-400 hover:text-slate-700 dark:hover:text-foreground",
|
|
89
|
-
children: /* @__PURE__ */ o(
|
|
94
|
+
children: /* @__PURE__ */ o(B, { className: "h-3.5 w-3.5" })
|
|
90
95
|
}
|
|
91
96
|
)
|
|
92
97
|
] })
|
|
93
98
|
}
|
|
94
99
|
),
|
|
95
|
-
/* @__PURE__ */
|
|
100
|
+
/* @__PURE__ */ i(
|
|
96
101
|
"div",
|
|
97
102
|
{
|
|
98
103
|
"data-panel-body": "",
|
|
99
|
-
onScroll:
|
|
104
|
+
onScroll: C,
|
|
100
105
|
className: "min-h-0 flex-1 overflow-y-auto px-4 pb-8",
|
|
101
|
-
children:
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
"”."
|
|
105
|
-
] }) : /* @__PURE__ */ o(R.Provider, { value: x, children: l.map(({ section: t }) => {
|
|
106
|
-
const e = L[t.id];
|
|
107
|
-
return /* @__PURE__ */ d(
|
|
108
|
-
"section",
|
|
106
|
+
children: [
|
|
107
|
+
f && r.trim() && (s.length === 0 || E(r)) && /* @__PURE__ */ i(
|
|
108
|
+
"button",
|
|
109
109
|
{
|
|
110
|
-
"
|
|
111
|
-
"
|
|
112
|
-
|
|
110
|
+
type: "button",
|
|
111
|
+
"data-settings-ask": "",
|
|
112
|
+
onClick: () => f(r.trim()),
|
|
113
|
+
className: "mt-3 inline-flex items-center gap-1.5 rounded-md px-2 py-1 text-[12px] font-medium text-slate-600 transition-colors hover:bg-muted hover:text-slate-900 dark:text-muted-foreground dark:hover:text-foreground",
|
|
113
114
|
children: [
|
|
114
|
-
/* @__PURE__ */ o(
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
"data-section-title": "",
|
|
119
|
-
className: p(
|
|
120
|
-
A,
|
|
121
|
-
"sticky top-0 z-10 -mx-4 border-b border-transparent bg-white px-4 pb-3 pt-4 data-[stuck]:border-slate-200 dark:bg-card dark:data-[stuck]:border-border"
|
|
122
|
-
),
|
|
123
|
-
children: t.title
|
|
124
|
-
}
|
|
125
|
-
),
|
|
126
|
-
/* @__PURE__ */ o("div", { className: "space-y-5", children: /* @__PURE__ */ o(
|
|
127
|
-
e,
|
|
128
|
-
{
|
|
129
|
-
...v,
|
|
130
|
-
onPreviewRole: g,
|
|
131
|
-
previewRoleId: y,
|
|
132
|
-
onPreviewRoleChange: S
|
|
133
|
-
}
|
|
134
|
-
) })
|
|
115
|
+
/* @__PURE__ */ o(F, { className: "h-3.5 w-3.5 text-nvr-cyan" }),
|
|
116
|
+
"Look everywhere for “",
|
|
117
|
+
r.trim(),
|
|
118
|
+
"”"
|
|
135
119
|
]
|
|
136
|
-
}
|
|
137
|
-
|
|
138
|
-
)
|
|
139
|
-
|
|
120
|
+
}
|
|
121
|
+
),
|
|
122
|
+
s.length === 0 ? /* @__PURE__ */ i("p", { className: u("py-8 text-center", _), children: [
|
|
123
|
+
"No setting matches “",
|
|
124
|
+
r.trim(),
|
|
125
|
+
"”."
|
|
126
|
+
] }) : /* @__PURE__ */ o(j.Provider, { value: S, children: s.map(({ section: t }) => {
|
|
127
|
+
const e = G[t.id];
|
|
128
|
+
return /* @__PURE__ */ i(
|
|
129
|
+
"section",
|
|
130
|
+
{
|
|
131
|
+
"data-section": t.id,
|
|
132
|
+
"aria-labelledby": `form-settings-${t.id}`,
|
|
133
|
+
className: "border-t border-slate-100 pb-6 first:border-t-0 dark:border-border/60",
|
|
134
|
+
children: [
|
|
135
|
+
/* @__PURE__ */ o(
|
|
136
|
+
"h3",
|
|
137
|
+
{
|
|
138
|
+
id: `form-settings-${t.id}`,
|
|
139
|
+
"data-section-title": "",
|
|
140
|
+
className: u(
|
|
141
|
+
O,
|
|
142
|
+
"sticky top-0 z-10 -mx-4 border-b border-transparent bg-white px-4 pb-3 pt-4 data-[stuck]:border-slate-200 dark:bg-card dark:data-[stuck]:border-border"
|
|
143
|
+
),
|
|
144
|
+
children: t.title
|
|
145
|
+
}
|
|
146
|
+
),
|
|
147
|
+
/* @__PURE__ */ o("div", { className: "space-y-5", children: /* @__PURE__ */ o(
|
|
148
|
+
e,
|
|
149
|
+
{
|
|
150
|
+
...k,
|
|
151
|
+
onPreviewRole: y,
|
|
152
|
+
previewRoleId: x,
|
|
153
|
+
onPreviewRoleChange: v
|
|
154
|
+
}
|
|
155
|
+
) })
|
|
156
|
+
]
|
|
157
|
+
},
|
|
158
|
+
t.id
|
|
159
|
+
);
|
|
160
|
+
}) })
|
|
161
|
+
]
|
|
140
162
|
}
|
|
141
163
|
)
|
|
142
164
|
] });
|
|
143
165
|
}
|
|
144
166
|
export {
|
|
145
|
-
|
|
167
|
+
ht as FormSettings
|
|
146
168
|
};
|
|
@@ -0,0 +1,255 @@
|
|
|
1
|
+
import { jsx as t, jsxs as r } from "react/jsx-runtime";
|
|
2
|
+
import { useQueryClient as W } from "@tanstack/react-query";
|
|
3
|
+
import { Lock as O, Smartphone as P } from "lucide-react";
|
|
4
|
+
import { useState as x, useEffect as A } from "react";
|
|
5
|
+
import { toast as q } from "sonner";
|
|
6
|
+
import { useItemEditAuth as D, useNivaroClient as M } from "../../../context.js";
|
|
7
|
+
import { post as R, patch as T } from "../../../lib/commands.js";
|
|
8
|
+
import { freezeOf as U, activeFreeze as _, localDay as S, dayWords as k, freezePatch as E, activeWindowOf as j, windowState as B, windowWords as Q, phoneOf as L, phoneOfPatch as V, activeWindowPatch as G, conditionsWithKey as H } from "../../../lib/layout-resolve.js";
|
|
9
|
+
import { cn as g } from "../../../lib/utils.js";
|
|
10
|
+
import { useLayoutEditorHost as J } from "../host.js";
|
|
11
|
+
import { useInvalidateLayouts as X, apiFailure as Y } from "../overview/overview-api.js";
|
|
12
|
+
import { amberStrip as Z } from "../panel-style.js";
|
|
13
|
+
import { Setting as $, smallBtn as b, quietText as w, inputCls as I, PickList as ee } from "./controls.js";
|
|
14
|
+
import { useCollectionLayoutList as te, settingsKeys as ne } from "./settings-api.js";
|
|
15
|
+
import { layoutKindOf as ae } from "./settings-registry.js";
|
|
16
|
+
const F = g(I, "h-8 w-[150px] font-mono dark:[color-scheme:dark]");
|
|
17
|
+
function ge(m) {
|
|
18
|
+
const { layout: c } = m, e = j(c.conditions), [a, l] = x((e == null ? void 0 : e.from) ?? ""), [s, u] = x((e == null ? void 0 : e.until) ?? "");
|
|
19
|
+
A(() => {
|
|
20
|
+
l((e == null ? void 0 : e.from) ?? ""), u((e == null ? void 0 : e.until) ?? "");
|
|
21
|
+
}, [e == null ? void 0 : e.from, e == null ? void 0 : e.until]);
|
|
22
|
+
const p = !!a && !!s && a > s, f = (o, i) => {
|
|
23
|
+
o && i && o > i || (o || null) === ((e == null ? void 0 : e.from) ?? null) && (i || null) === ((e == null ? void 0 : e.until) ?? null) || m.set(
|
|
24
|
+
G(c.conditions, { from: o || null, until: i || null }),
|
|
25
|
+
o || i ? "Set active dates" : "Clear active dates"
|
|
26
|
+
);
|
|
27
|
+
}, d = B(e, S());
|
|
28
|
+
return /* @__PURE__ */ t(
|
|
29
|
+
$,
|
|
30
|
+
{
|
|
31
|
+
k: "layout.conditions.active_window",
|
|
32
|
+
note: p ? /* @__PURE__ */ t("span", { className: "text-amber-700 dark:text-amber-300", children: "The end comes before the start." }) : e && d ? /* @__PURE__ */ t("span", { "data-active-window-state": d, children: d === "open" ? `In use now, ${Q(e)}.` : d === "before" ? `Not in use yet: starts ${k(e.from)}.` : `No longer in use: ended ${k(e.until)}.` }) : null,
|
|
33
|
+
children: /* @__PURE__ */ r("div", { className: "flex flex-wrap items-end gap-2", children: [
|
|
34
|
+
/* @__PURE__ */ r("label", { className: "flex flex-col gap-1", children: [
|
|
35
|
+
/* @__PURE__ */ t("span", { className: w, children: "From" }),
|
|
36
|
+
/* @__PURE__ */ t(
|
|
37
|
+
"input",
|
|
38
|
+
{
|
|
39
|
+
type: "date",
|
|
40
|
+
"aria-label": "Active from",
|
|
41
|
+
value: a,
|
|
42
|
+
max: s || void 0,
|
|
43
|
+
onChange: (o) => {
|
|
44
|
+
l(o.target.value), f(o.target.value, s);
|
|
45
|
+
},
|
|
46
|
+
className: F
|
|
47
|
+
}
|
|
48
|
+
)
|
|
49
|
+
] }),
|
|
50
|
+
/* @__PURE__ */ r("label", { className: "flex flex-col gap-1", children: [
|
|
51
|
+
/* @__PURE__ */ t("span", { className: w, children: "Until" }),
|
|
52
|
+
/* @__PURE__ */ t(
|
|
53
|
+
"input",
|
|
54
|
+
{
|
|
55
|
+
type: "date",
|
|
56
|
+
"aria-label": "Active until",
|
|
57
|
+
value: s,
|
|
58
|
+
min: a || void 0,
|
|
59
|
+
onChange: (o) => {
|
|
60
|
+
u(o.target.value), f(a, o.target.value);
|
|
61
|
+
},
|
|
62
|
+
className: F
|
|
63
|
+
}
|
|
64
|
+
)
|
|
65
|
+
] }),
|
|
66
|
+
(a || s) && /* @__PURE__ */ t(
|
|
67
|
+
"button",
|
|
68
|
+
{
|
|
69
|
+
type: "button",
|
|
70
|
+
className: g(b, "mb-0.5"),
|
|
71
|
+
onClick: () => {
|
|
72
|
+
l(""), u(""), f("", "");
|
|
73
|
+
},
|
|
74
|
+
children: "Clear"
|
|
75
|
+
}
|
|
76
|
+
)
|
|
77
|
+
] })
|
|
78
|
+
}
|
|
79
|
+
);
|
|
80
|
+
}
|
|
81
|
+
function xe(m) {
|
|
82
|
+
const { layout: c, collection: e } = m, a = Number(c.id), l = J(), s = M(), u = W(), p = X(e), f = te(e), [d, o] = x(!1), i = f.filter((n) => ae(n) === "grouped"), h = L(c.conditions), N = i.find((n) => n.id !== a && L(n.conditions) === a) ?? null, v = h != null ? i.find((n) => n.id === h) ?? null : null, C = (n) => {
|
|
83
|
+
l.layoutLink && l.navigate(l.layoutLink(e, n));
|
|
84
|
+
}, K = async () => {
|
|
85
|
+
o(!0);
|
|
86
|
+
try {
|
|
87
|
+
const n = String(c.name || "Form"), z = await s.request(
|
|
88
|
+
R(`/collection-layouts/${a}/clone`, { name: `${n} (phone)`.slice(0, 255) })
|
|
89
|
+
), y = z == null ? void 0 : z.data;
|
|
90
|
+
if (!(y != null && y.id)) throw new Error("No id came back");
|
|
91
|
+
await s.request(
|
|
92
|
+
T(`/collection-layouts/${y.id}`, {
|
|
93
|
+
conditions: H(y.conditions, "phone_of", a)
|
|
94
|
+
})
|
|
95
|
+
), u.invalidateQueries({ queryKey: ne.layouts(e) }), p(), q.success("Phone version made: remove what a phone does not need"), C(Number(y.id));
|
|
96
|
+
} catch (n) {
|
|
97
|
+
q.error(Y(n, "Could not make the phone version").message);
|
|
98
|
+
} finally {
|
|
99
|
+
o(!1);
|
|
100
|
+
}
|
|
101
|
+
};
|
|
102
|
+
return /* @__PURE__ */ t(
|
|
103
|
+
$,
|
|
104
|
+
{
|
|
105
|
+
k: "layout.conditions.phone_of",
|
|
106
|
+
note: h != null ? /* @__PURE__ */ r("span", { "data-phone-of": h, children: [
|
|
107
|
+
"This form opens instead of",
|
|
108
|
+
" ",
|
|
109
|
+
/* @__PURE__ */ t("strong", { className: "font-medium text-slate-700 dark:text-foreground", children: (v == null ? void 0 : v.name) ?? `form ${h}` }),
|
|
110
|
+
" ",
|
|
111
|
+
"on small screens, for the records and roles that form gets."
|
|
112
|
+
] }) : null,
|
|
113
|
+
children: N ? /* @__PURE__ */ r(
|
|
114
|
+
"div",
|
|
115
|
+
{
|
|
116
|
+
"data-phone-version": N.id,
|
|
117
|
+
className: "flex flex-wrap items-center gap-2 text-[12.5px] text-slate-700 dark:text-foreground",
|
|
118
|
+
children: [
|
|
119
|
+
/* @__PURE__ */ t(P, { className: "h-3.5 w-3.5 shrink-0 text-slate-500 dark:text-muted-foreground" }),
|
|
120
|
+
/* @__PURE__ */ t("span", { className: "min-w-0 truncate", children: N.name }),
|
|
121
|
+
l.layoutLink && /* @__PURE__ */ t("button", { type: "button", className: b, onClick: () => C(N.id), children: "Open" })
|
|
122
|
+
]
|
|
123
|
+
}
|
|
124
|
+
) : /* @__PURE__ */ r("div", { className: "flex flex-wrap items-center gap-2", children: [
|
|
125
|
+
/* @__PURE__ */ t(
|
|
126
|
+
ee,
|
|
127
|
+
{
|
|
128
|
+
ariaLabel: "Phone version of",
|
|
129
|
+
value: h != null ? String(h) : null,
|
|
130
|
+
placeholder: "Not a phone version",
|
|
131
|
+
clearLabel: "Not a phone version",
|
|
132
|
+
options: i.filter((n) => n.id !== a && L(n.conditions) == null).map((n) => ({ value: String(n.id), label: n.name })),
|
|
133
|
+
onChange: (n) => m.set(
|
|
134
|
+
V(c.conditions, n ? Number(n) : null),
|
|
135
|
+
n ? "Make this a phone version" : "Stop being a phone version"
|
|
136
|
+
),
|
|
137
|
+
className: "w-[220px]"
|
|
138
|
+
}
|
|
139
|
+
),
|
|
140
|
+
h == null && /* @__PURE__ */ r(
|
|
141
|
+
"button",
|
|
142
|
+
{
|
|
143
|
+
type: "button",
|
|
144
|
+
className: b,
|
|
145
|
+
disabled: d,
|
|
146
|
+
"data-action": "make-phone-version",
|
|
147
|
+
onClick: () => void K(),
|
|
148
|
+
children: [
|
|
149
|
+
/* @__PURE__ */ t(P, { className: "h-3.5 w-3.5" }),
|
|
150
|
+
d ? "Making…" : "Make a phone version"
|
|
151
|
+
]
|
|
152
|
+
}
|
|
153
|
+
),
|
|
154
|
+
v && l.layoutLink && /* @__PURE__ */ r("button", { type: "button", className: b, onClick: () => C(v.id), children: [
|
|
155
|
+
"Open ",
|
|
156
|
+
v.name
|
|
157
|
+
] })
|
|
158
|
+
] })
|
|
159
|
+
}
|
|
160
|
+
);
|
|
161
|
+
}
|
|
162
|
+
function Ne(m) {
|
|
163
|
+
const { layout: c } = m, { userId: e } = D(), a = U(c.conditions), l = _(c.conditions), [s, u] = x(""), [p, f] = x(""), d = s > S() && p.trim().length >= 3, o = () => {
|
|
164
|
+
d && (m.set(
|
|
165
|
+
E(c.conditions, {
|
|
166
|
+
until: s,
|
|
167
|
+
reason: p.trim().slice(0, 300),
|
|
168
|
+
by: e || null,
|
|
169
|
+
at: (/* @__PURE__ */ new Date()).toISOString()
|
|
170
|
+
}),
|
|
171
|
+
`Freeze edits until ${k(s)}`
|
|
172
|
+
), u(""), f(""));
|
|
173
|
+
};
|
|
174
|
+
return /* @__PURE__ */ t($, { k: "layout.conditions.freeze", children: a ? /* @__PURE__ */ r(
|
|
175
|
+
"div",
|
|
176
|
+
{
|
|
177
|
+
"data-layout-frozen": a.until,
|
|
178
|
+
className: g(
|
|
179
|
+
"flex flex-wrap items-center gap-2 rounded-md border px-2.5 py-2 text-[12.5px]",
|
|
180
|
+
l ? Z : "border-slate-200 text-slate-600 dark:border-border dark:text-muted-foreground"
|
|
181
|
+
),
|
|
182
|
+
children: [
|
|
183
|
+
/* @__PURE__ */ t(O, { className: "h-3.5 w-3.5 shrink-0" }),
|
|
184
|
+
/* @__PURE__ */ r("span", { className: "min-w-0 flex-1", children: [
|
|
185
|
+
l ? "Frozen until " : "The freeze ended on ",
|
|
186
|
+
k(a.until),
|
|
187
|
+
a.reason ? `: ${a.reason}` : ""
|
|
188
|
+
] }),
|
|
189
|
+
/* @__PURE__ */ t(
|
|
190
|
+
"button",
|
|
191
|
+
{
|
|
192
|
+
type: "button",
|
|
193
|
+
className: b,
|
|
194
|
+
"data-action": "lift-freeze",
|
|
195
|
+
onClick: () => m.set(
|
|
196
|
+
E(c.conditions, null),
|
|
197
|
+
l ? "Lift the edit freeze" : "Remove the ended freeze"
|
|
198
|
+
),
|
|
199
|
+
children: l ? "Lift" : "Remove"
|
|
200
|
+
}
|
|
201
|
+
)
|
|
202
|
+
]
|
|
203
|
+
}
|
|
204
|
+
) : /* @__PURE__ */ r("div", { className: "flex flex-wrap items-end gap-2", children: [
|
|
205
|
+
/* @__PURE__ */ r("label", { className: "flex flex-col gap-1", children: [
|
|
206
|
+
/* @__PURE__ */ t("span", { className: w, children: "Until" }),
|
|
207
|
+
/* @__PURE__ */ t(
|
|
208
|
+
"input",
|
|
209
|
+
{
|
|
210
|
+
type: "date",
|
|
211
|
+
"aria-label": "Frozen until",
|
|
212
|
+
value: s,
|
|
213
|
+
min: S(),
|
|
214
|
+
onChange: (i) => u(i.target.value),
|
|
215
|
+
className: F
|
|
216
|
+
}
|
|
217
|
+
)
|
|
218
|
+
] }),
|
|
219
|
+
/* @__PURE__ */ r("label", { className: "flex min-w-[180px] flex-1 flex-col gap-1", children: [
|
|
220
|
+
/* @__PURE__ */ t("span", { className: w, children: "Reason people see" }),
|
|
221
|
+
/* @__PURE__ */ t(
|
|
222
|
+
"input",
|
|
223
|
+
{
|
|
224
|
+
value: p,
|
|
225
|
+
maxLength: 300,
|
|
226
|
+
placeholder: "e.g. Go-live on Monday",
|
|
227
|
+
onChange: (i) => f(i.target.value),
|
|
228
|
+
onKeyDown: (i) => {
|
|
229
|
+
i.key === "Enter" && o();
|
|
230
|
+
},
|
|
231
|
+
className: g(I, "h-8")
|
|
232
|
+
}
|
|
233
|
+
)
|
|
234
|
+
] }),
|
|
235
|
+
/* @__PURE__ */ r(
|
|
236
|
+
"button",
|
|
237
|
+
{
|
|
238
|
+
type: "button",
|
|
239
|
+
className: g(b, "mb-0.5"),
|
|
240
|
+
disabled: !d,
|
|
241
|
+
"data-action": "freeze",
|
|
242
|
+
onClick: o,
|
|
243
|
+
children: [
|
|
244
|
+
/* @__PURE__ */ t(O, { className: "h-3.5 w-3.5" }),
|
|
245
|
+
"Freeze"
|
|
246
|
+
]
|
|
247
|
+
}
|
|
248
|
+
)
|
|
249
|
+
] }) });
|
|
250
|
+
}
|
|
251
|
+
export {
|
|
252
|
+
ge as ActiveDatesSetting,
|
|
253
|
+
Ne as FreezeSetting,
|
|
254
|
+
xe as PhoneVersionSetting
|
|
255
|
+
};
|