@mistriwork/kit 1.0.0-rc.11 → 1.0.0-rc.13
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/client/actionGrants.d.ts +21 -0
- package/dist/client/actionGrants.js +24 -0
- package/dist/client/addressMount.d.ts +67 -0
- package/dist/client/addressMount.js +136 -0
- package/dist/client/app.d.ts +10 -0
- package/dist/client/app.js +976 -0
- package/dist/client/boot.d.ts +1 -0
- package/dist/client/boot.js +37 -0
- package/dist/client/brandLook.css +125 -0
- package/dist/client/breakdownBatch.d.ts +34 -0
- package/dist/client/breakdownBatch.js +115 -0
- package/dist/client/bulkActions.d.ts +66 -0
- package/dist/client/bulkActions.js +171 -0
- package/dist/client/chart.d.ts +20 -0
- package/dist/client/chart.js +80 -0
- package/dist/client/clauses.d.ts +121 -0
- package/dist/client/clauses.js +276 -0
- package/dist/client/columns.d.ts +77 -0
- package/dist/client/columns.js +102 -0
- package/dist/client/components/Accordion.d.ts +26 -0
- package/dist/client/components/Accordion.js +44 -0
- package/dist/client/components/ApiOperations.d.ts +3 -0
- package/dist/client/components/ApiOperations.js +162 -0
- package/dist/client/components/AppColumnMenu.d.ts +66 -0
- package/dist/client/components/AppColumnMenu.js +59 -0
- package/dist/client/components/AppColumnMenuPopups.d.ts +21 -0
- package/dist/client/components/AppColumnMenuPopups.js +92 -0
- package/dist/client/components/AppFooter.css +17 -0
- package/dist/client/components/AppFooter.d.ts +23 -0
- package/dist/client/components/AppFooter.js +12 -0
- package/dist/client/components/AppIssues.d.ts +4 -0
- package/dist/client/components/AppIssues.js +18 -0
- package/dist/client/components/AppList.d.ts +20 -0
- package/dist/client/components/AppList.js +696 -0
- package/dist/client/components/AttachmentList.d.ts +45 -0
- package/dist/client/components/AttachmentList.js +178 -0
- package/dist/client/components/BoardList.css +9 -0
- package/dist/client/components/Breakdown.d.ts +11 -0
- package/dist/client/components/Breakdown.js +157 -0
- package/dist/client/components/BreakdownRoom.d.ts +4 -0
- package/dist/client/components/BreakdownRoom.js +48 -0
- package/dist/client/components/CardsList.d.ts +23 -0
- package/dist/client/components/CardsList.js +209 -0
- package/dist/client/components/Chart.css +165 -0
- package/dist/client/components/Chart.d.ts +194 -0
- package/dist/client/components/Chart.js +801 -0
- package/dist/client/components/ChartFigure.d.ts +82 -0
- package/dist/client/components/ChartFigure.js +102 -0
- package/dist/client/components/ChartShapes.css +213 -0
- package/dist/client/components/ChartShapes.d.ts +63 -0
- package/dist/client/components/ChartShapes.js +393 -0
- package/dist/client/components/Checklist.css +16 -0
- package/dist/client/components/Composer.d.ts +1 -0
- package/dist/client/components/Composer.js +331 -0
- package/dist/client/components/Content.d.ts +8 -0
- package/dist/client/components/Content.js +170 -0
- package/dist/client/components/CountedLabel.d.ts +10 -0
- package/dist/client/components/CountedLabel.js +26 -0
- package/dist/client/components/Crumbs.d.ts +11 -0
- package/dist/client/components/Crumbs.js +142 -0
- package/dist/client/components/DashboardList.css +7 -0
- package/dist/client/components/DashboardList.d.ts +9 -0
- package/dist/client/components/DashboardList.js +46 -0
- package/dist/client/components/DashboardNote.d.ts +21 -0
- package/dist/client/components/DashboardNote.js +22 -0
- package/dist/client/components/DateField.css +6 -0
- package/dist/client/components/DateField.d.ts +7 -0
- package/dist/client/components/DateField.js +27 -0
- package/dist/client/components/DefinedFields.d.ts +50 -0
- package/dist/client/components/DefinedFields.js +186 -0
- package/dist/client/components/DeleteButton.d.ts +30 -0
- package/dist/client/components/DeleteButton.js +198 -0
- package/dist/client/components/Diagram.d.ts +7 -0
- package/dist/client/components/Diagram.js +320 -0
- package/dist/client/components/Dressed.d.ts +31 -0
- package/dist/client/components/Dressed.js +138 -0
- package/dist/client/components/Dropdown.d.ts +14 -0
- package/dist/client/components/Dropdown.js +20 -0
- package/dist/client/components/EditLayoutButton.d.ts +13 -0
- package/dist/client/components/EditLayoutButton.js +7 -0
- package/dist/client/components/Editable.d.ts +47 -0
- package/dist/client/components/Editable.js +422 -0
- package/dist/client/components/ErrorBoundary.d.ts +40 -0
- package/dist/client/components/ErrorBoundary.js +41 -0
- package/dist/client/components/Export.d.ts +15 -0
- package/dist/client/components/Export.js +151 -0
- package/dist/client/components/ExportHold.d.ts +18 -0
- package/dist/client/components/ExportHold.js +30 -0
- package/dist/client/components/FavoriteStar.d.ts +5 -0
- package/dist/client/components/FavoriteStar.js +14 -0
- package/dist/client/components/FieldArranger.d.ts +29 -0
- package/dist/client/components/FieldArranger.js +83 -0
- package/dist/client/components/FilePreview.css +20 -0
- package/dist/client/components/FilePreview.d.ts +26 -0
- package/dist/client/components/FilePreview.js +170 -0
- package/dist/client/components/FilterBoxes.d.ts +76 -0
- package/dist/client/components/FilterBoxes.js +294 -0
- package/dist/client/components/FilterRail.css +100 -0
- package/dist/client/components/FilterRail.d.ts +61 -0
- package/dist/client/components/FilterRail.js +559 -0
- package/dist/client/components/Gallery.d.ts +11 -0
- package/dist/client/components/Gallery.js +53 -0
- package/dist/client/components/Grid.d.ts +122 -0
- package/dist/client/components/Grid.js +1115 -0
- package/dist/client/components/GridCellEditor.d.ts +35 -0
- package/dist/client/components/GridCellEditor.js +291 -0
- package/dist/client/components/GridSelection.d.ts +16 -0
- package/dist/client/components/GridSelection.js +28 -0
- package/dist/client/components/HelpPanel.d.ts +5 -0
- package/dist/client/components/HelpPanel.js +92 -0
- package/dist/client/components/History.d.ts +10 -0
- package/dist/client/components/History.js +22 -0
- package/dist/client/components/Icon.d.ts +31 -0
- package/dist/client/components/Icon.js +20 -0
- package/dist/client/components/JsonPreview.d.ts +5 -0
- package/dist/client/components/JsonPreview.js +25 -0
- package/dist/client/components/JsonValue.d.ts +4 -0
- package/dist/client/components/JsonValue.js +3 -0
- package/dist/client/components/JsonView.css +109 -0
- package/dist/client/components/JsonView.d.ts +3 -0
- package/dist/client/components/JsonView.js +118 -0
- package/dist/client/components/Landing.d.ts +19 -0
- package/dist/client/components/Landing.js +55 -0
- package/dist/client/components/LandingSurface.css +177 -0
- package/dist/client/components/LandingSurface.d.ts +42 -0
- package/dist/client/components/LandingSurface.js +108 -0
- package/dist/client/components/LayoutBuilder.d.ts +36 -0
- package/dist/client/components/LayoutBuilder.js +104 -0
- package/dist/client/components/Lightbox.d.ts +29 -0
- package/dist/client/components/Lightbox.js +62 -0
- package/dist/client/components/ListEmpty.css +13 -0
- package/dist/client/components/ListEmpty.d.ts +10 -0
- package/dist/client/components/ListEmpty.js +8 -0
- package/dist/client/components/ListFilterBar.css +76 -0
- package/dist/client/components/ListFilterBar.d.ts +52 -0
- package/dist/client/components/ListFilterBar.js +304 -0
- package/dist/client/components/LiveNotices.css +105 -0
- package/dist/client/components/LiveNotices.d.ts +26 -0
- package/dist/client/components/LiveNotices.js +211 -0
- package/dist/client/components/MinorMoneyInput.d.ts +26 -0
- package/dist/client/components/MinorMoneyInput.js +50 -0
- package/dist/client/components/Modal.css +3 -0
- package/dist/client/components/MultiStepForm.css +122 -0
- package/dist/client/components/MultiStepForm.d.ts +59 -0
- package/dist/client/components/MultiStepForm.js +216 -0
- package/dist/client/components/NavGlyph.d.ts +14 -0
- package/dist/client/components/NavGlyph.js +27 -0
- package/dist/client/components/Nested.d.ts +21 -0
- package/dist/client/components/Nested.js +86 -0
- package/dist/client/components/NewRecord.d.ts +89 -0
- package/dist/client/components/NewRecord.js +897 -0
- package/dist/client/components/NewRecordButton.d.ts +13 -0
- package/dist/client/components/NewRecordButton.js +28 -0
- package/dist/client/components/Notes.css +39 -0
- package/dist/client/components/Notes.d.ts +59 -0
- package/dist/client/components/Notes.js +96 -0
- package/dist/client/components/OverflowMenu.d.ts +3 -0
- package/dist/client/components/OverflowMenu.js +60 -0
- package/dist/client/components/Page.d.ts +52 -0
- package/dist/client/components/Page.js +237 -0
- package/dist/client/components/PageCurrent.d.ts +38 -0
- package/dist/client/components/PageCurrent.js +27 -0
- package/dist/client/components/PageEmptyRun.d.ts +18 -0
- package/dist/client/components/PageEmptyRun.js +118 -0
- package/dist/client/components/PageFields.d.ts +3 -0
- package/dist/client/components/PageFields.js +294 -0
- package/dist/client/components/PageFlowDiagram.css +193 -0
- package/dist/client/components/PageFlowDiagram.d.ts +95 -0
- package/dist/client/components/PageFlowDiagram.js +276 -0
- package/dist/client/components/PageFlows.css +27 -0
- package/dist/client/components/PageFlows.d.ts +54 -0
- package/dist/client/components/PageFlows.js +92 -0
- package/dist/client/components/PageGroups.d.ts +43 -0
- package/dist/client/components/PageGroups.js +123 -0
- package/dist/client/components/PageHead.d.ts +28 -0
- package/dist/client/components/PageHead.js +279 -0
- package/dist/client/components/PageHeadline.d.ts +23 -0
- package/dist/client/components/PageHeadline.js +101 -0
- package/dist/client/components/PageHistory.d.ts +62 -0
- package/dist/client/components/PageHistory.js +160 -0
- package/dist/client/components/PageLayout.d.ts +22 -0
- package/dist/client/components/PageLayout.js +13 -0
- package/dist/client/components/PageMetrics.d.ts +11 -0
- package/dist/client/components/PageMetrics.js +252 -0
- package/dist/client/components/PageRelated.d.ts +70 -0
- package/dist/client/components/PageRelated.js +667 -0
- package/dist/client/components/PageRoom.d.ts +37 -0
- package/dist/client/components/PageRoom.js +277 -0
- package/dist/client/components/PageSectionBox.d.ts +28 -0
- package/dist/client/components/PageSectionBox.js +65 -0
- package/dist/client/components/PageSections.d.ts +38 -0
- package/dist/client/components/PageSections.js +352 -0
- package/dist/client/components/PageSkeleton.css +17 -0
- package/dist/client/components/PageSkeleton.d.ts +11 -0
- package/dist/client/components/PageSkeleton.js +25 -0
- package/dist/client/components/PageTimeline.d.ts +2 -0
- package/dist/client/components/PageTimeline.js +273 -0
- package/dist/client/components/Palette.d.ts +4 -0
- package/dist/client/components/Palette.js +176 -0
- package/dist/client/components/Peek.d.ts +1 -0
- package/dist/client/components/Peek.js +158 -0
- package/dist/client/components/PeekPanel.d.ts +16 -0
- package/dist/client/components/PeekPanel.js +120 -0
- package/dist/client/components/Picker.d.ts +13 -0
- package/dist/client/components/Picker.js +33 -0
- package/dist/client/components/Prefs.d.ts +3 -0
- package/dist/client/components/Prefs.js +121 -0
- package/dist/client/components/PresentationSwitch.d.ts +13 -0
- package/dist/client/components/PresentationSwitch.js +10 -0
- package/dist/client/components/Prompt.d.ts +35 -0
- package/dist/client/components/Prompt.js +114 -0
- package/dist/client/components/QrCode.css +11 -0
- package/dist/client/components/QrCode.d.ts +4 -0
- package/dist/client/components/QrCode.js +57 -0
- package/dist/client/components/QueueList.css +122 -0
- package/dist/client/components/QuickAdd.css +18 -0
- package/dist/client/components/QuickAdd.d.ts +11 -0
- package/dist/client/components/QuickAdd.js +53 -0
- package/dist/client/components/QuickAddOnDemand.d.ts +4 -0
- package/dist/client/components/QuickAddOnDemand.js +10 -0
- package/dist/client/components/Record.d.ts +36 -0
- package/dist/client/components/Record.js +385 -0
- package/dist/client/components/RecordGone.d.ts +7 -0
- package/dist/client/components/RecordGone.js +22 -0
- package/dist/client/components/RecordPicker.d.ts +59 -0
- package/dist/client/components/RecordPicker.js +299 -0
- package/dist/client/components/RecordSummaries.d.ts +55 -0
- package/dist/client/components/RecordSummaries.js +151 -0
- package/dist/client/components/RecordTags.d.ts +6 -0
- package/dist/client/components/RecordTags.js +119 -0
- package/dist/client/components/RecordTrailNav.d.ts +25 -0
- package/dist/client/components/RecordTrailNav.js +110 -0
- package/dist/client/components/RichText.d.ts +7 -0
- package/dist/client/components/RichText.js +82 -0
- package/dist/client/components/RichTextEditor.css +202 -0
- package/dist/client/components/RichTextEditor.d.ts +33 -0
- package/dist/client/components/RichTextEditor.js +348 -0
- package/dist/client/components/RichTextField.d.ts +26 -0
- package/dist/client/components/RichTextField.js +71 -0
- package/dist/client/components/Rooms.d.ts +35 -0
- package/dist/client/components/Rooms.js +276 -0
- package/dist/client/components/RowActions.d.ts +8 -0
- package/dist/client/components/RowActions.js +49 -0
- package/dist/client/components/RowHost.d.ts +110 -0
- package/dist/client/components/RowHost.js +212 -0
- package/dist/client/components/SavedViews.d.ts +25 -0
- package/dist/client/components/SavedViews.js +35 -0
- package/dist/client/components/SchemaExport.d.ts +15 -0
- package/dist/client/components/SchemaExport.js +42 -0
- package/dist/client/components/SectionPeriod.css +14 -0
- package/dist/client/components/SectionPeriod.d.ts +7 -0
- package/dist/client/components/SectionPeriod.js +14 -0
- package/dist/client/components/SetFieldDialog.d.ts +12 -0
- package/dist/client/components/SetFieldDialog.js +51 -0
- package/dist/client/components/Sidebar.d.ts +34 -0
- package/dist/client/components/Sidebar.js +398 -0
- package/dist/client/components/Skeleton.d.ts +35 -0
- package/dist/client/components/Skeleton.js +49 -0
- package/dist/client/components/SortMenu.d.ts +20 -0
- package/dist/client/components/SortMenu.js +45 -0
- package/dist/client/components/SplitListDetail.css +119 -0
- package/dist/client/components/SuggestBox.d.ts +29 -0
- package/dist/client/components/SuggestBox.js +60 -0
- package/dist/client/components/Summary.d.ts +14 -0
- package/dist/client/components/Summary.js +93 -0
- package/dist/client/components/TableRoom.d.ts +88 -0
- package/dist/client/components/TableRoom.js +246 -0
- package/dist/client/components/TableView.d.ts +111 -0
- package/dist/client/components/TableView.js +324 -0
- package/dist/client/components/ThMenu.d.ts +40 -0
- package/dist/client/components/ThMenu.js +163 -0
- package/dist/client/components/ThemeLab.d.ts +4 -0
- package/dist/client/components/ThemeLab.js +67 -0
- package/dist/client/components/TimelineSides.css +23 -0
- package/dist/client/components/TimelineSides.d.ts +7 -0
- package/dist/client/components/TimelineSides.js +9 -0
- package/dist/client/components/Tour.d.ts +12 -0
- package/dist/client/components/Tour.js +131 -0
- package/dist/client/components/Value.d.ts +38 -0
- package/dist/client/components/Value.js +172 -0
- package/dist/client/components/WorkPanel.d.ts +9 -0
- package/dist/client/components/WorkPanel.js +43 -0
- package/dist/client/components/WorkflowStatus.d.ts +6 -0
- package/dist/client/components/WorkflowStatus.js +44 -0
- package/dist/client/components/WriteConfirm.d.ts +4 -0
- package/dist/client/components/WriteConfirm.js +27 -0
- package/dist/client/components/appColumnMenuModel.d.ts +46 -0
- package/dist/client/components/appColumnMenuModel.js +51 -0
- package/dist/client/components/appListModel.d.ts +179 -0
- package/dist/client/components/appListModel.js +421 -0
- package/dist/client/components/appRooms.d.ts +106 -0
- package/dist/client/components/appRooms.js +133 -0
- package/dist/client/components/autoChart.d.ts +33 -0
- package/dist/client/components/autoChart.js +107 -0
- package/dist/client/components/avatarPhotos.d.ts +45 -0
- package/dist/client/components/avatarPhotos.js +93 -0
- package/dist/client/components/besideDetail.d.ts +1 -0
- package/dist/client/components/besideDetail.js +10 -0
- package/dist/client/components/boardNew.d.ts +2 -0
- package/dist/client/components/boardNew.js +8 -0
- package/dist/client/components/cardsModel.d.ts +11 -0
- package/dist/client/components/cardsModel.js +24 -0
- package/dist/client/components/chromeIcons.d.ts +16 -0
- package/dist/client/components/chromeIcons.js +16 -0
- package/dist/client/components/columnPresentation.d.ts +8 -0
- package/dist/client/components/columnPresentation.js +47 -0
- package/dist/client/components/componentSlot.d.ts +31 -0
- package/dist/client/components/componentSlot.js +76 -0
- package/dist/client/components/composerDraft.d.ts +16 -0
- package/dist/client/components/composerDraft.js +16 -0
- package/dist/client/components/conditionText.d.ts +14 -0
- package/dist/client/components/conditionText.js +45 -0
- package/dist/client/components/conditionWords.d.ts +37 -0
- package/dist/client/components/conditionWords.js +382 -0
- package/dist/client/components/crumbSlot.d.ts +14 -0
- package/dist/client/components/crumbSlot.js +49 -0
- package/dist/client/components/dashboardModel.d.ts +283 -0
- package/dist/client/components/dashboardModel.js +415 -0
- package/dist/client/components/dashboardParts.d.ts +9 -0
- package/dist/client/components/dashboardParts.js +18 -0
- package/dist/client/components/diagramModel.d.ts +83 -0
- package/dist/client/components/diagramModel.js +211 -0
- package/dist/client/components/dueOpen.d.ts +1 -0
- package/dist/client/components/dueOpen.js +23 -0
- package/dist/client/components/editInteraction.d.ts +20 -0
- package/dist/client/components/editInteraction.js +178 -0
- package/dist/client/components/favoriteNav.d.ts +6 -0
- package/dist/client/components/favoriteNav.js +31 -0
- package/dist/client/components/favorites.d.ts +23 -0
- package/dist/client/components/favorites.js +86 -0
- package/dist/client/components/filePreviewModel.d.ts +18 -0
- package/dist/client/components/filePreviewModel.js +21 -0
- package/dist/client/components/filterRailModel.d.ts +93 -0
- package/dist/client/components/filterRailModel.js +302 -0
- package/dist/client/components/formControlsStyle.d.ts +1 -0
- package/dist/client/components/formControlsStyle.js +3 -0
- package/dist/client/components/formDefaults.d.ts +17 -0
- package/dist/client/components/formDefaults.js +128 -0
- package/dist/client/components/gridArrange.d.ts +33 -0
- package/dist/client/components/gridArrange.js +62 -0
- package/dist/client/components/gridCellModel.d.ts +32 -0
- package/dist/client/components/gridCellModel.js +42 -0
- package/dist/client/components/gridSizing.d.ts +89 -0
- package/dist/client/components/gridSizing.js +295 -0
- package/dist/client/components/groupMoves.d.ts +44 -0
- package/dist/client/components/groupMoves.js +295 -0
- package/dist/client/components/groupOrder.d.ts +43 -0
- package/dist/client/components/groupOrder.js +63 -0
- package/dist/client/components/inputRenderers.d.ts +48 -0
- package/dist/client/components/inputRenderers.js +37 -0
- package/dist/client/components/intakeStyle.d.ts +2 -0
- package/dist/client/components/intakeStyle.js +6 -0
- package/dist/client/components/jsonModel.d.ts +98 -0
- package/dist/client/components/jsonModel.js +264 -0
- package/dist/client/components/listColumn.d.ts +20 -0
- package/dist/client/components/listColumn.js +31 -0
- package/dist/client/components/listNavigation.d.ts +16 -0
- package/dist/client/components/listNavigation.js +14 -0
- package/dist/client/components/mentionRows.d.ts +5 -0
- package/dist/client/components/mentionRows.js +62 -0
- package/dist/client/components/mount.d.ts +55 -0
- package/dist/client/components/mount.js +155 -0
- package/dist/client/components/myViews.d.ts +54 -0
- package/dist/client/components/myViews.js +82 -0
- package/dist/client/components/navCounts.d.ts +84 -0
- package/dist/client/components/navCounts.js +194 -0
- package/dist/client/components/navigationTree.d.ts +52 -0
- package/dist/client/components/navigationTree.js +49 -0
- package/dist/client/components/newMenuModel.d.ts +27 -0
- package/dist/client/components/newMenuModel.js +58 -0
- package/dist/client/components/newRecordModel.d.ts +58 -0
- package/dist/client/components/newRecordModel.js +232 -0
- package/dist/client/components/onDemand.d.ts +30 -0
- package/dist/client/components/onDemand.js +121 -0
- package/dist/client/components/optimisticMoves.d.ts +21 -0
- package/dist/client/components/optimisticMoves.js +145 -0
- package/dist/client/components/pageContext.d.ts +154 -0
- package/dist/client/components/pageContext.js +47 -0
- package/dist/client/components/pageFieldsRead.d.ts +67 -0
- package/dist/client/components/pageFieldsRead.js +55 -0
- package/dist/client/components/pageModel.d.ts +203 -0
- package/dist/client/components/pageModel.js +67 -0
- package/dist/client/components/pageStep.d.ts +31 -0
- package/dist/client/components/pageStep.js +15 -0
- package/dist/client/components/paletteModel.d.ts +9 -0
- package/dist/client/components/paletteModel.js +46 -0
- package/dist/client/components/pickerStaleness.d.ts +32 -0
- package/dist/client/components/pickerStaleness.js +27 -0
- package/dist/client/components/placeOrder.d.ts +47 -0
- package/dist/client/components/placeOrder.js +71 -0
- package/dist/client/components/pointerDrag.d.ts +54 -0
- package/dist/client/components/pointerDrag.js +95 -0
- package/dist/client/components/presentationFit.d.ts +19 -0
- package/dist/client/components/presentationFit.js +32 -0
- package/dist/client/components/recordKeys.d.ts +2 -0
- package/dist/client/components/recordKeys.js +8 -0
- package/dist/client/components/recordSearch.d.ts +31 -0
- package/dist/client/components/recordSearch.js +80 -0
- package/dist/client/components/recordSurface.d.ts +86 -0
- package/dist/client/components/recordSurface.js +267 -0
- package/dist/client/components/rowOpens.d.ts +19 -0
- package/dist/client/components/rowOpens.js +25 -0
- package/dist/client/components/sidebarModel.d.ts +152 -0
- package/dist/client/components/sidebarModel.js +372 -0
- package/dist/client/components/suggestModel.d.ts +22 -0
- package/dist/client/components/suggestModel.js +49 -0
- package/dist/client/components/suggestPart.d.ts +4 -0
- package/dist/client/components/suggestPart.js +4 -0
- package/dist/client/components/textMeasure.d.ts +2 -0
- package/dist/client/components/textMeasure.js +35 -0
- package/dist/client/components/unknownIcon.d.ts +8 -0
- package/dist/client/components/unknownIcon.js +32 -0
- package/dist/client/components/useBulkSelection.d.ts +30 -0
- package/dist/client/components/useBulkSelection.js +360 -0
- package/dist/client/components/useConditionWords.d.ts +17 -0
- package/dist/client/components/useConditionWords.js +104 -0
- package/dist/client/components/useGridKeyboard.d.ts +32 -0
- package/dist/client/components/useGridKeyboard.js +223 -0
- package/dist/client/components/useListOrder.d.ts +94 -0
- package/dist/client/components/useListOrder.js +294 -0
- package/dist/client/components/useMediaQuery.d.ts +10 -0
- package/dist/client/components/useMediaQuery.js +45 -0
- package/dist/client/components/useMessageLanguage.d.ts +1 -0
- package/dist/client/components/useMessageLanguage.js +6 -0
- package/dist/client/components/usePins.d.ts +20 -0
- package/dist/client/components/usePins.js +66 -0
- package/dist/client/components/usePointerDrag.d.ts +72 -0
- package/dist/client/components/usePointerDrag.js +553 -0
- package/dist/client/components/useRecordInsert.d.ts +42 -0
- package/dist/client/components/useRecordInsert.js +145 -0
- package/dist/client/components/useRowWindow.d.ts +35 -0
- package/dist/client/components/useRowWindow.js +149 -0
- package/dist/client/components/useStickyHead.d.ts +17 -0
- package/dist/client/components/useStickyHead.js +65 -0
- package/dist/client/components/useTabFold.d.ts +32 -0
- package/dist/client/components/useTabFold.js +145 -0
- package/dist/client/components/valueModel.d.ts +300 -0
- package/dist/client/components/valueModel.js +560 -0
- package/dist/client/components/valueRenderers.d.ts +36 -0
- package/dist/client/components/valueRenderers.js +13 -0
- package/dist/client/components/viewLink.d.ts +27 -0
- package/dist/client/components/viewLink.js +79 -0
- package/dist/client/components/walk.d.ts +14 -0
- package/dist/client/components/walk.js +16 -0
- package/dist/client/compose.d.ts +8 -0
- package/dist/client/compose.js +163 -0
- package/dist/client/composedHook.d.ts +20 -0
- package/dist/client/composedHook.js +12 -0
- package/dist/client/composedReads.d.ts +26 -0
- package/dist/client/composedReads.js +183 -0
- package/dist/client/composer.css +499 -0
- package/dist/client/composer.d.ts +121 -0
- package/dist/client/composer.js +1079 -0
- package/dist/client/composerEntry.d.ts +1 -0
- package/dist/client/composerEntry.js +58 -0
- package/dist/client/composerTab.d.ts +6 -0
- package/dist/client/composerTab.js +20 -0
- package/dist/client/conditions.d.ts +46 -0
- package/dist/client/conditions.js +150 -0
- package/dist/client/connectionList.d.ts +14 -0
- package/dist/client/connectionList.js +149 -0
- package/dist/client/connectionScope.d.ts +6 -0
- package/dist/client/connectionScope.js +14 -0
- package/dist/client/connectionTransition.d.ts +12 -0
- package/dist/client/connectionTransition.js +41 -0
- package/dist/client/copy/columnMenu/components/AppColumnMenu.d.ts +4 -0
- package/dist/client/copy/columnMenu/components/AppColumnMenu.js +6 -0
- package/dist/client/copy/columnMenu/components/AppColumnMenuPopups.d.ts +4 -0
- package/dist/client/copy/columnMenu/components/AppColumnMenuPopups.js +6 -0
- package/dist/client/copy/columnMenu/components/ThMenu.d.ts +35 -0
- package/dist/client/copy/columnMenu/components/ThMenu.js +37 -0
- package/dist/client/copy/columnMenu/components/appColumnMenuModel.d.ts +10 -0
- package/dist/client/copy/columnMenu/components/appColumnMenuModel.js +12 -0
- package/dist/client/copy/dashboards/breakdownBatch.d.ts +3 -0
- package/dist/client/copy/dashboards/breakdownBatch.js +5 -0
- package/dist/client/copy/dashboards/components/Breakdown.d.ts +32 -0
- package/dist/client/copy/dashboards/components/Breakdown.js +25 -0
- package/dist/client/copy/dashboards/components/BreakdownRoom.d.ts +3 -0
- package/dist/client/copy/dashboards/components/BreakdownRoom.js +5 -0
- package/dist/client/copy/dashboards/components/Chart.d.ts +26 -0
- package/dist/client/copy/dashboards/components/Chart.js +19 -0
- package/dist/client/copy/dashboards/components/ChartShapes.d.ts +16 -0
- package/dist/client/copy/dashboards/components/ChartShapes.js +12 -0
- package/dist/client/copy/dashboards/components/PageMetrics.d.ts +21 -0
- package/dist/client/copy/dashboards/components/PageMetrics.js +20 -0
- package/dist/client/copy/dashboards/components/SectionPeriod.d.ts +4 -0
- package/dist/client/copy/dashboards/components/SectionPeriod.js +6 -0
- package/dist/client/copy/dashboards/components/dashboardModel.d.ts +3 -0
- package/dist/client/copy/dashboards/components/dashboardModel.js +5 -0
- package/dist/client/copy/es.d.ts +11 -0
- package/dist/client/copy/es.js +60 -0
- package/dist/client/copy/filters/components/FilterBoxes.d.ts +10 -0
- package/dist/client/copy/filters/components/FilterBoxes.js +12 -0
- package/dist/client/copy/filters/components/FilterRail.d.ts +16 -0
- package/dist/client/copy/filters/components/FilterRail.js +18 -0
- package/dist/client/copy/filters/components/ListFilterBar.d.ts +9 -0
- package/dist/client/copy/filters/components/ListFilterBar.js +11 -0
- package/dist/client/copy/filters/components/conditionWords.d.ts +46 -0
- package/dist/client/copy/filters/components/conditionWords.js +95 -0
- package/dist/client/copy/filters/components/filterRailModel.d.ts +12 -0
- package/dist/client/copy/filters/components/filterRailModel.js +14 -0
- package/dist/client/copy/forms/components/DateField.d.ts +13 -0
- package/dist/client/copy/forms/components/DateField.js +15 -0
- package/dist/client/copy/forms/components/MinorMoneyInput.d.ts +4 -0
- package/dist/client/copy/forms/components/MinorMoneyInput.js +6 -0
- package/dist/client/copy/forms/components/MultiStepForm.d.ts +10 -0
- package/dist/client/copy/forms/components/MultiStepForm.js +12 -0
- package/dist/client/copy/forms/components/NewRecord.d.ts +29 -0
- package/dist/client/copy/forms/components/NewRecord.js +31 -0
- package/dist/client/copy/forms/components/NewRecordButton.d.ts +6 -0
- package/dist/client/copy/forms/components/NewRecordButton.js +8 -0
- package/dist/client/copy/forms/components/Picker.d.ts +4 -0
- package/dist/client/copy/forms/components/Picker.js +6 -0
- package/dist/client/copy/forms/components/QuickAdd.d.ts +3 -0
- package/dist/client/copy/forms/components/QuickAdd.js +5 -0
- package/dist/client/copy/forms/components/RecordPicker.d.ts +6 -0
- package/dist/client/copy/forms/components/RecordPicker.js +8 -0
- package/dist/client/copy/forms/components/RichTextEditor.d.ts +36 -0
- package/dist/client/copy/forms/components/RichTextEditor.js +40 -0
- package/dist/client/copy/forms/components/RichTextField.d.ts +3 -0
- package/dist/client/copy/forms/components/RichTextField.js +5 -0
- package/dist/client/copy/forms/components/SetFieldDialog.d.ts +10 -0
- package/dist/client/copy/forms/components/SetFieldDialog.js +9 -0
- package/dist/client/copy/forms/components/useRecordInsert.d.ts +7 -0
- package/dist/client/copy/forms/components/useRecordInsert.js +9 -0
- package/dist/client/copy/help/helpContent.d.ts +71 -0
- package/dist/client/copy/help/helpContent.js +73 -0
- package/dist/client/copy/lists/bulkActions.d.ts +12 -0
- package/dist/client/copy/lists/bulkActions.js +14 -0
- package/dist/client/copy/lists/components/AppList.d.ts +28 -0
- package/dist/client/copy/lists/components/AppList.js +30 -0
- package/dist/client/copy/lists/components/CardsList.d.ts +3 -0
- package/dist/client/copy/lists/components/CardsList.js +5 -0
- package/dist/client/copy/lists/components/Gallery.d.ts +7 -0
- package/dist/client/copy/lists/components/Gallery.js +9 -0
- package/dist/client/copy/lists/components/Grid.d.ts +30 -0
- package/dist/client/copy/lists/components/Grid.js +29 -0
- package/dist/client/copy/lists/components/GridCellEditor.d.ts +5 -0
- package/dist/client/copy/lists/components/GridCellEditor.js +7 -0
- package/dist/client/copy/lists/components/GridSelection.d.ts +4 -0
- package/dist/client/copy/lists/components/GridSelection.js +6 -0
- package/dist/client/copy/lists/components/Nested.d.ts +7 -0
- package/dist/client/copy/lists/components/Nested.js +9 -0
- package/dist/client/copy/lists/components/RowActions.d.ts +1 -0
- package/dist/client/copy/lists/components/RowActions.js +3 -0
- package/dist/client/copy/lists/components/SavedViews.d.ts +5 -0
- package/dist/client/copy/lists/components/SavedViews.js +7 -0
- package/dist/client/copy/lists/components/SortMenu.d.ts +5 -0
- package/dist/client/copy/lists/components/SortMenu.js +7 -0
- package/dist/client/copy/lists/components/TableRoom.d.ts +12 -0
- package/dist/client/copy/lists/components/TableRoom.js +14 -0
- package/dist/client/copy/lists/components/TableView.d.ts +37 -0
- package/dist/client/copy/lists/components/TableView.js +39 -0
- package/dist/client/copy/lists/components/appListModel.d.ts +6 -0
- package/dist/client/copy/lists/components/appListModel.js +5 -0
- package/dist/client/copy/lists/components/myViews.d.ts +4 -0
- package/dist/client/copy/lists/components/myViews.js +6 -0
- package/dist/client/copy/lists/components/placeOrder.d.ts +4 -0
- package/dist/client/copy/lists/components/placeOrder.js +6 -0
- package/dist/client/copy/lists/components/useBulkSelection.d.ts +20 -0
- package/dist/client/copy/lists/components/useBulkSelection.js +16 -0
- package/dist/client/copy/lists/components/useListOrder.d.ts +7 -0
- package/dist/client/copy/lists/components/useListOrder.js +9 -0
- package/dist/client/copy/public/components/appRooms.d.ts +3 -0
- package/dist/client/copy/public/components/appRooms.js +5 -0
- package/dist/client/copy/record/components/Actions.d.ts +13 -0
- package/dist/client/copy/record/components/Actions.js +15 -0
- package/dist/client/copy/record/components/AttachmentList.d.ts +23 -0
- package/dist/client/copy/record/components/AttachmentList.js +22 -0
- package/dist/client/copy/record/components/DeleteButton.d.ts +22 -0
- package/dist/client/copy/record/components/DeleteButton.js +24 -0
- package/dist/client/copy/record/components/Dressed.d.ts +5 -0
- package/dist/client/copy/record/components/Dressed.js +7 -0
- package/dist/client/copy/record/components/EditLayoutButton.d.ts +5 -0
- package/dist/client/copy/record/components/EditLayoutButton.js +7 -0
- package/dist/client/copy/record/components/Editable.d.ts +25 -0
- package/dist/client/copy/record/components/Editable.js +24 -0
- package/dist/client/copy/record/components/FieldArranger.d.ts +15 -0
- package/dist/client/copy/record/components/FieldArranger.js +17 -0
- package/dist/client/copy/record/components/FilePreview.d.ts +13 -0
- package/dist/client/copy/record/components/FilePreview.js +15 -0
- package/dist/client/copy/record/components/JsonPreview.d.ts +3 -0
- package/dist/client/copy/record/components/JsonPreview.js +5 -0
- package/dist/client/copy/record/components/JsonView.d.ts +12 -0
- package/dist/client/copy/record/components/JsonView.js +14 -0
- package/dist/client/copy/record/components/LayoutBuilder.d.ts +23 -0
- package/dist/client/copy/record/components/LayoutBuilder.js +25 -0
- package/dist/client/copy/record/components/Lightbox.d.ts +5 -0
- package/dist/client/copy/record/components/Lightbox.js +7 -0
- package/dist/client/copy/record/components/LiveNotices.d.ts +33 -0
- package/dist/client/copy/record/components/LiveNotices.js +29 -0
- package/dist/client/copy/record/components/PageCurrent.d.ts +1 -0
- package/dist/client/copy/record/components/PageCurrent.js +3 -0
- package/dist/client/copy/record/components/PageEmptyRun.d.ts +3 -0
- package/dist/client/copy/record/components/PageEmptyRun.js +5 -0
- package/dist/client/copy/record/components/PageFields.d.ts +5 -0
- package/dist/client/copy/record/components/PageFields.js +7 -0
- package/dist/client/copy/record/components/PageFlowDiagram.d.ts +33 -0
- package/dist/client/copy/record/components/PageFlowDiagram.js +37 -0
- package/dist/client/copy/record/components/PageFlows.d.ts +20 -0
- package/dist/client/copy/record/components/PageFlows.js +22 -0
- package/dist/client/copy/record/components/PageGroups.d.ts +12 -0
- package/dist/client/copy/record/components/PageGroups.js +14 -0
- package/dist/client/copy/record/components/PageHead.d.ts +8 -0
- package/dist/client/copy/record/components/PageHead.js +10 -0
- package/dist/client/copy/record/components/PageHistory.d.ts +18 -0
- package/dist/client/copy/record/components/PageHistory.js +20 -0
- package/dist/client/copy/record/components/PageLayout.d.ts +5 -0
- package/dist/client/copy/record/components/PageLayout.js +7 -0
- package/dist/client/copy/record/components/PageRelated.d.ts +24 -0
- package/dist/client/copy/record/components/PageRelated.js +26 -0
- package/dist/client/copy/record/components/PageRoom.d.ts +4 -0
- package/dist/client/copy/record/components/PageRoom.js +6 -0
- package/dist/client/copy/record/components/PageSectionBox.d.ts +6 -0
- package/dist/client/copy/record/components/PageSectionBox.js +10 -0
- package/dist/client/copy/record/components/PageTimeline.d.ts +9 -0
- package/dist/client/copy/record/components/PageTimeline.js +8 -0
- package/dist/client/copy/record/components/Peek.d.ts +3 -0
- package/dist/client/copy/record/components/Peek.js +5 -0
- package/dist/client/copy/record/components/PeekPanel.d.ts +5 -0
- package/dist/client/copy/record/components/PeekPanel.js +7 -0
- package/dist/client/copy/record/components/QrCode.d.ts +3 -0
- package/dist/client/copy/record/components/QrCode.js +5 -0
- package/dist/client/copy/record/components/Record.d.ts +19 -0
- package/dist/client/copy/record/components/Record.js +21 -0
- package/dist/client/copy/record/components/RecordGone.d.ts +4 -0
- package/dist/client/copy/record/components/RecordGone.js +6 -0
- package/dist/client/copy/record/components/RecordSummaries.d.ts +1 -0
- package/dist/client/copy/record/components/RecordSummaries.js +3 -0
- package/dist/client/copy/record/components/RecordTags.d.ts +9 -0
- package/dist/client/copy/record/components/RecordTags.js +11 -0
- package/dist/client/copy/record/components/RecordTrailNav.d.ts +8 -0
- package/dist/client/copy/record/components/RecordTrailNav.js +10 -0
- package/dist/client/copy/record/components/RichText.d.ts +4 -0
- package/dist/client/copy/record/components/RichText.js +6 -0
- package/dist/client/copy/record/components/Value.d.ts +4 -0
- package/dist/client/copy/record/components/Value.js +6 -0
- package/dist/client/copy/record/components/WorkflowStatus.d.ts +7 -0
- package/dist/client/copy/record/components/WorkflowStatus.js +9 -0
- package/dist/client/copy/record/components/WriteConfirm.d.ts +11 -0
- package/dist/client/copy/record/components/WriteConfirm.js +13 -0
- package/dist/client/copy/record/components/groupMoves.d.ts +7 -0
- package/dist/client/copy/record/components/groupMoves.js +9 -0
- package/dist/client/copy/record/components/jsonModel.d.ts +3 -0
- package/dist/client/copy/record/components/jsonModel.js +5 -0
- package/dist/client/copy/record/components/pageModel.d.ts +5 -0
- package/dist/client/copy/record/components/pageModel.js +7 -0
- package/dist/client/copy/record/components/recordSurface.d.ts +6 -0
- package/dist/client/copy/record/components/recordSurface.js +8 -0
- package/dist/client/copy/record/components/valueModel.d.ts +5 -0
- package/dist/client/copy/record/components/valueModel.js +7 -0
- package/dist/client/copy/record/fileSource.d.ts +3 -0
- package/dist/client/copy/record/fileSource.js +5 -0
- package/dist/client/copy/record/insert.d.ts +6 -0
- package/dist/client/copy/record/insert.js +8 -0
- package/dist/client/copy/record/page.d.ts +4 -0
- package/dist/client/copy/record/page.js +6 -0
- package/dist/client/copy/record/recordEditValidation.d.ts +4 -0
- package/dist/client/copy/record/recordEditValidation.js +6 -0
- package/dist/client/copy/record/savedPages.d.ts +4 -0
- package/dist/client/copy/record/savedPages.js +6 -0
- package/dist/client/copy/record/template.d.ts +9 -0
- package/dist/client/copy/record/template.js +11 -0
- package/dist/client/copy/record/write.d.ts +30 -0
- package/dist/client/copy/record/write.js +26 -0
- package/dist/client/copy/shell/app.d.ts +27 -0
- package/dist/client/copy/shell/app.js +43 -0
- package/dist/client/copy/shell/components/AppIssues.d.ts +10 -0
- package/dist/client/copy/shell/components/AppIssues.js +9 -0
- package/dist/client/copy/shell/components/Crumbs.d.ts +7 -0
- package/dist/client/copy/shell/components/Crumbs.js +17 -0
- package/dist/client/copy/shell/components/Dropdown.d.ts +3 -0
- package/dist/client/copy/shell/components/Dropdown.js +5 -0
- package/dist/client/copy/shell/components/ErrorBoundary.d.ts +4 -0
- package/dist/client/copy/shell/components/ErrorBoundary.js +6 -0
- package/dist/client/copy/shell/components/FavoriteStar.d.ts +4 -0
- package/dist/client/copy/shell/components/FavoriteStar.js +6 -0
- package/dist/client/copy/shell/components/MobileNavDrawer.d.ts +4 -0
- package/dist/client/copy/shell/components/MobileNavDrawer.js +12 -0
- package/dist/client/copy/shell/components/OverflowMenu.d.ts +3 -0
- package/dist/client/copy/shell/components/OverflowMenu.js +10 -0
- package/dist/client/copy/shell/components/Palette.d.ts +15 -0
- package/dist/client/copy/shell/components/Palette.js +18 -0
- package/dist/client/copy/shell/components/Prefs.d.ts +4 -0
- package/dist/client/copy/shell/components/Prefs.js +11 -0
- package/dist/client/copy/shell/components/Prompt.d.ts +1 -0
- package/dist/client/copy/shell/components/Prompt.js +3 -0
- package/dist/client/copy/shell/components/Rooms.d.ts +6 -0
- package/dist/client/copy/shell/components/Rooms.js +8 -0
- package/dist/client/copy/shell/components/Sidebar.d.ts +7 -0
- package/dist/client/copy/shell/components/Sidebar.js +9 -0
- package/dist/client/copy/shell/components/Skeleton.d.ts +5 -0
- package/dist/client/copy/shell/components/Skeleton.js +7 -0
- package/dist/client/copy/shell/components/TopNav.d.ts +4 -0
- package/dist/client/copy/shell/components/TopNav.js +12 -0
- package/dist/client/copy/shell/components/Tour.d.ts +4 -0
- package/dist/client/copy/shell/components/Tour.js +6 -0
- package/dist/client/copy/shell/components/newMenuModel.d.ts +3 -0
- package/dist/client/copy/shell/components/newMenuModel.js +5 -0
- package/dist/client/copy/shell/components/onDemand.d.ts +3 -0
- package/dist/client/copy/shell/components/onDemand.js +5 -0
- package/dist/client/copy/shell/components/sidebarModel.d.ts +3 -0
- package/dist/client/copy/shell/components/sidebarModel.js +5 -0
- package/dist/client/copy/shell/connectionList.d.ts +6 -0
- package/dist/client/copy/shell/connectionList.js +8 -0
- package/dist/client/copy/shell/core.d.ts +16 -0
- package/dist/client/copy/shell/core.js +18 -0
- package/dist/client/copy/shell/palette.d.ts +6 -0
- package/dist/client/copy/shell/palette.js +8 -0
- package/dist/client/copy/shell/prompt.d.ts +1 -0
- package/dist/client/copy/shell/prompt.js +3 -0
- package/dist/client/copy/shell/requestIdentity.d.ts +9 -0
- package/dist/client/copy/shell/requestIdentity.js +11 -0
- package/dist/client/copy/shell/resourceRequests.d.ts +4 -0
- package/dist/client/copy/shell/resourceRequests.js +6 -0
- package/dist/client/copy/shell/sessionIdentity.d.ts +11 -0
- package/dist/client/copy/shell/sessionIdentity.js +13 -0
- package/dist/client/copy/shell/sessionLifecycle.d.ts +5 -0
- package/dist/client/copy/shell/sessionLifecycle.js +7 -0
- package/dist/client/copy/shell/startup.d.ts +5 -0
- package/dist/client/copy/shell/startup.js +7 -0
- package/dist/client/copy/shell/theme.d.ts +5 -0
- package/dist/client/copy/shell/theme.js +14 -0
- package/dist/client/copy/shell/toast.d.ts +3 -0
- package/dist/client/copy/shell/toast.js +5 -0
- package/dist/client/copy/shell/updateAttempts.d.ts +6 -0
- package/dist/client/copy/shell/updateAttempts.js +8 -0
- package/dist/client/copy/shell/visualTheme.d.ts +4 -0
- package/dist/client/copy/shell/visualTheme.js +6 -0
- package/dist/client/copy/workbench/clauses.d.ts +3 -0
- package/dist/client/copy/workbench/clauses.js +5 -0
- package/dist/client/copy/workbench/components/ApiOperations.d.ts +21 -0
- package/dist/client/copy/workbench/components/ApiOperations.js +23 -0
- package/dist/client/copy/workbench/components/Composer.d.ts +105 -0
- package/dist/client/copy/workbench/components/Composer.js +92 -0
- package/dist/client/copy/workbench/components/Diagram.d.ts +56 -0
- package/dist/client/copy/workbench/components/Diagram.js +46 -0
- package/dist/client/copy/workbench/components/Export.d.ts +26 -0
- package/dist/client/copy/workbench/components/Export.js +25 -0
- package/dist/client/copy/workbench/components/HelpPanel.d.ts +10 -0
- package/dist/client/copy/workbench/components/HelpPanel.js +12 -0
- package/dist/client/copy/workbench/components/History.d.ts +11 -0
- package/dist/client/copy/workbench/components/History.js +10 -0
- package/dist/client/copy/workbench/components/Landing.d.ts +5 -0
- package/dist/client/copy/workbench/components/Landing.js +7 -0
- package/dist/client/copy/workbench/components/SchemaExport.d.ts +24 -0
- package/dist/client/copy/workbench/components/SchemaExport.js +20 -0
- package/dist/client/copy/workbench/components/Summary.d.ts +28 -0
- package/dist/client/copy/workbench/components/Summary.js +24 -0
- package/dist/client/copy/workbench/components/ThemeLab.d.ts +25 -0
- package/dist/client/copy/workbench/components/ThemeLab.js +27 -0
- package/dist/client/copy/workbench/components/WorkPanel.d.ts +12 -0
- package/dist/client/copy/workbench/components/WorkPanel.js +14 -0
- package/dist/client/copy/workbench/composer.d.ts +36 -0
- package/dist/client/copy/workbench/composer.js +32 -0
- package/dist/client/copy/workbench/composerEntry.d.ts +4 -0
- package/dist/client/copy/workbench/composerEntry.js +6 -0
- package/dist/client/copy/workbench/export.d.ts +8 -0
- package/dist/client/copy/workbench/export.js +7 -0
- package/dist/client/copy/workbench/filterbar.d.ts +6 -0
- package/dist/client/copy/workbench/filterbar.js +8 -0
- package/dist/client/copy/workbench/handoff.d.ts +20 -0
- package/dist/client/copy/workbench/handoff.js +19 -0
- package/dist/client/copy/workbench/help.d.ts +6 -0
- package/dist/client/copy/workbench/help.js +8 -0
- package/dist/client/copy/workbench/history.d.ts +3 -0
- package/dist/client/copy/workbench/history.js +5 -0
- package/dist/client/copy/workbench/schemaexport.d.ts +5 -0
- package/dist/client/copy/workbench/schemaexport.js +7 -0
- package/dist/client/copy/workbench/tour.d.ts +22 -0
- package/dist/client/copy/workbench/tour.js +24 -0
- package/dist/client/copy/workbench/views.d.ts +6 -0
- package/dist/client/copy/workbench/views.js +8 -0
- package/dist/client/core.d.ts +327 -0
- package/dist/client/core.js +1082 -0
- package/dist/client/customThemes.css +43 -0
- package/dist/client/dashboard.d.ts +16 -0
- package/dist/client/dashboard.js +35 -0
- package/dist/client/deeplink.d.ts +64 -0
- package/dist/client/deeplink.js +384 -0
- package/dist/client/delete.d.ts +8 -0
- package/dist/client/delete.js +35 -0
- package/dist/client/density.d.ts +8 -0
- package/dist/client/density.js +102 -0
- package/dist/client/devtoolsEventClient.d.ts +27 -0
- package/dist/client/devtoolsEventClient.js +32 -0
- package/dist/client/documents.d.ts +9 -0
- package/dist/client/documents.js +23 -0
- package/dist/client/dom.d.ts +36 -0
- package/dist/client/dom.js +232 -0
- package/dist/client/draftRecovery.d.ts +19 -0
- package/dist/client/draftRecovery.js +56 -0
- package/dist/client/export.d.ts +59 -0
- package/dist/client/export.js +217 -0
- package/dist/client/features.css +2187 -0
- package/dist/client/fieldErrors.d.ts +27 -0
- package/dist/client/fieldErrors.js +20 -0
- package/dist/client/fileSource.d.ts +10 -0
- package/dist/client/fileSource.js +115 -0
- package/dist/client/filterbar.d.ts +87 -0
- package/dist/client/filterbar.js +168 -0
- package/dist/client/firstPaint.d.ts +26 -0
- package/dist/client/firstPaint.js +102 -0
- package/dist/client/fonts/Barlow-OFL.txt +125 -0
- package/dist/client/fonts/IBMPlexMono-OFL.txt +104 -0
- package/dist/client/fonts/Inter-OFL.txt +92 -0
- package/dist/client/fonts/barlow-400.woff2 +0 -0
- package/dist/client/fonts/barlow-600.woff2 +0 -0
- package/dist/client/fonts/barlow-semi-condensed-700.woff2 +0 -0
- package/dist/client/fonts/ibm-plex-mono-400.woff2 +0 -0
- package/dist/client/fonts/ibm-plex-mono-500.woff2 +0 -0
- package/dist/client/fonts/inter-latin.woff2 +0 -0
- package/dist/client/formControls.css +5 -0
- package/dist/client/handoff.d.ts +47 -0
- package/dist/client/handoff.js +138 -0
- package/dist/client/help.css +151 -0
- package/dist/client/help.d.ts +20 -0
- package/dist/client/help.js +103 -0
- package/dist/client/helpContent.d.ts +95 -0
- package/dist/client/helpContent.js +661 -0
- package/dist/client/history.d.ts +10 -0
- package/dist/client/history.js +181 -0
- package/dist/client/historyToken.d.ts +18 -0
- package/dist/client/historyToken.js +27 -0
- package/dist/client/iconWeight.d.ts +16 -0
- package/dist/client/iconWeight.js +44 -0
- package/dist/client/index.html +244 -0
- package/dist/client/insert.d.ts +50 -0
- package/dist/client/insert.js +269 -0
- package/dist/client/kit.d.ts +7 -0
- package/dist/client/kit.js +1 -0
- package/dist/client/layoutDraftRecovery.d.ts +8 -0
- package/dist/client/layoutDraftRecovery.js +33 -0
- package/dist/client/ledgerLook.css +32 -0
- package/dist/client/liveReads.d.ts +23 -0
- package/dist/client/liveReads.js +38 -0
- package/dist/client/liveState.d.ts +94 -0
- package/dist/client/liveState.js +212 -0
- package/dist/client/locale.d.ts +141 -0
- package/dist/client/locale.js +0 -0
- package/dist/client/lumenLook.css +1867 -0
- package/dist/client/menu.d.ts +49 -0
- package/dist/client/menu.js +131 -0
- package/dist/client/menuScope.d.ts +6 -0
- package/dist/client/menuScope.js +4 -0
- package/dist/client/messages.d.ts +240 -0
- package/dist/client/messages.js +370 -0
- package/dist/client/motionStill.d.ts +1 -0
- package/dist/client/motionStill.js +17 -0
- package/dist/client/navigationHold.d.ts +37 -0
- package/dist/client/navigationHold.js +503 -0
- package/dist/client/nested.d.ts +8 -0
- package/dist/client/nested.js +26 -0
- package/dist/client/ownWrites.d.ts +33 -0
- package/dist/client/ownWrites.js +76 -0
- package/dist/client/page.css +4052 -0
- package/dist/client/page.d.ts +21 -0
- package/dist/client/page.js +187 -0
- package/dist/client/pagemarks.d.ts +32 -0
- package/dist/client/pagemarks.js +98 -0
- package/dist/client/palette.d.ts +38 -0
- package/dist/client/palette.js +360 -0
- package/dist/client/partsLook.css +1047 -0
- package/dist/client/peek.d.ts +11 -0
- package/dist/client/peek.js +51 -0
- package/dist/client/peekpanel.d.ts +26 -0
- package/dist/client/peekpanel.js +121 -0
- package/dist/client/pendingWork.d.ts +19 -0
- package/dist/client/pendingWork.js +36 -0
- package/dist/client/pins.d.ts +24 -0
- package/dist/client/pins.js +97 -0
- package/dist/client/prefs.d.ts +3 -0
- package/dist/client/prefs.js +32 -0
- package/dist/client/prompt.d.ts +27 -0
- package/dist/client/prompt.js +61 -0
- package/dist/client/readGathering.d.ts +4 -0
- package/dist/client/readGathering.js +23 -0
- package/dist/client/recordCompose.d.ts +11 -0
- package/dist/client/recordCompose.js +69 -0
- package/dist/client/recordDrafts.d.ts +40 -0
- package/dist/client/recordDrafts.js +57 -0
- package/dist/client/recordEditValidation.d.ts +12 -0
- package/dist/client/recordEditValidation.js +52 -0
- package/dist/client/recordIntent.d.ts +6 -0
- package/dist/client/recordIntent.js +15 -0
- package/dist/client/recordPress.d.ts +12 -0
- package/dist/client/recordPress.js +84 -0
- package/dist/client/recordSource.d.ts +6 -0
- package/dist/client/recordSource.js +15 -0
- package/dist/client/recordTrail.d.ts +77 -0
- package/dist/client/recordTrail.js +101 -0
- package/dist/client/recordWriteRefresh.d.ts +74 -0
- package/dist/client/recordWriteRefresh.js +284 -0
- package/dist/client/relatedRows.d.ts +4 -0
- package/dist/client/relatedRows.js +24 -0
- package/dist/client/requestIdentity.d.ts +36 -0
- package/dist/client/requestIdentity.js +97 -0
- package/dist/client/resourceRequests.d.ts +7 -0
- package/dist/client/resourceRequests.js +32 -0
- package/dist/client/roleLabels.d.ts +7 -0
- package/dist/client/roleLabels.js +24 -0
- package/dist/client/rowEditing.d.ts +15 -0
- package/dist/client/rowEditing.js +36 -0
- package/dist/client/sageLook.css +242 -0
- package/dist/client/savedPages.d.ts +27 -0
- package/dist/client/savedPages.js +135 -0
- package/dist/client/schemaexport.d.ts +14 -0
- package/dist/client/schemaexport.js +182 -0
- package/dist/client/sessionIdentity.d.ts +39 -0
- package/dist/client/sessionIdentity.js +255 -0
- package/dist/client/sessionLifecycle.d.ts +33 -0
- package/dist/client/sessionLifecycle.js +276 -0
- package/dist/client/shellHost.d.ts +70 -0
- package/dist/client/shellHost.js +92 -0
- package/dist/client/shellMain.d.ts +8 -0
- package/dist/client/shellMode.d.ts +433 -0
- package/dist/client/shellMode.js +68 -0
- package/dist/client/shellStart.d.ts +5 -0
- package/dist/client/shellStart.js +54 -0
- package/dist/client/shells.d.ts +123 -0
- package/dist/client/shells.js +1 -0
- package/dist/client/sql.css +139 -0
- package/dist/client/startup.d.ts +8 -0
- package/dist/client/startup.js +85 -0
- package/dist/client/startupHold.d.ts +10 -0
- package/dist/client/startupHold.js +73 -0
- package/dist/client/structure.css +1296 -0
- package/dist/client/style.css +3526 -0
- package/dist/client/styleImports.d.ts +3 -0
- package/dist/client/surfaces.d.ts +18 -0
- package/dist/client/surfaces.js +27 -0
- package/dist/client/surfacesLook.css +88 -0
- package/dist/client/template.d.ts +75 -0
- package/dist/client/template.js +403 -0
- package/dist/client/theme.d.ts +14 -0
- package/dist/client/theme.js +112 -0
- package/dist/client/themeFamilies.css +788 -0
- package/dist/client/thmenu.d.ts +12 -0
- package/dist/client/thmenu.js +94 -0
- package/dist/client/toast.d.ts +7 -0
- package/dist/client/toast.js +117 -0
- package/dist/client/tour.d.ts +8 -0
- package/dist/client/tour.js +176 -0
- package/dist/client/transport.d.ts +2 -0
- package/dist/client/transport.js +13 -0
- package/dist/client/typography.d.ts +4 -0
- package/dist/client/typography.js +51 -0
- package/dist/client/uiBridge.d.ts +57 -0
- package/dist/client/uiBridge.js +30 -0
- package/dist/client/updateAttempts.d.ts +46 -0
- package/dist/client/updateAttempts.js +131 -0
- package/dist/client/url.d.ts +74 -0
- package/dist/client/url.js +388 -0
- package/dist/client/views.d.ts +19 -0
- package/dist/client/views.js +133 -0
- package/dist/client/visualTheme.d.ts +62 -0
- package/dist/client/visualTheme.js +502 -0
- package/dist/client/visualThemes.css +421 -0
- package/dist/client/workshopLook.css +126 -0
- package/dist/client/write.d.ts +103 -0
- package/dist/client/write.js +885 -0
- package/dist/client/writePaths.d.ts +16 -0
- package/dist/client/writePaths.js +35 -0
- package/dist/client/yesNoRule.d.ts +12 -0
- package/dist/client/yesNoRule.js +39 -0
- package/dist/clientFiles.d.ts +11 -4
- package/dist/clientFiles.js +16 -12
- package/dist/vite.d.ts +136 -0
- package/dist/vite.js +571 -0
- package/package.json +136 -3
|
@@ -0,0 +1,304 @@
|
|
|
1
|
+
import { Fragment as _Fragment, jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
+
/**
|
|
3
|
+
* An App list's filters as controls, not a form: the bar a list draws above
|
|
4
|
+
* its rows unless its view says `filterBar: 'rail'` or `'none'`.
|
|
5
|
+
*
|
|
6
|
+
* The bar was a form — an empty box or Select per filter, then Filter, then
|
|
7
|
+
* Advanced — the heaviest thing above a quiet table, and on a phone more than
|
|
8
|
+
* half the first screen. So the list's name column keeps one search box, a
|
|
9
|
+
* real field with the 3:1 edge; every other filter the view declares is a
|
|
10
|
+
* quiet "+ Status" that opens, in a popover, the picker the rail draws for it
|
|
11
|
+
* (a checklist, Min/Max, date presets; a reference is the typeahead its box
|
|
12
|
+
* was); and what is applied is said in the same row as chips, each in its
|
|
13
|
+
* filter's place: a chip opens its picker again, its × (or Backspace) takes
|
|
14
|
+
* it out, and two or more earn one Clear all. On a phone the pickers are the
|
|
15
|
+
* rail's sheet, behind one Filters button that says how many apply.
|
|
16
|
+
*
|
|
17
|
+
* No picker writes a new kind of question. Each hands a condition tail to
|
|
18
|
+
* withCondition, as the boxes and the rail do, so a chip, the address
|
|
19
|
+
* (publicAddress.ts), a saved view and the crumb read it as they always did.
|
|
20
|
+
* A picker edits a draft and applies it with one button: every navigation
|
|
21
|
+
* redraws the list, and a popover that applied each tick would close under
|
|
22
|
+
* the reader's second one.
|
|
23
|
+
*/
|
|
24
|
+
import { useEffect, useLayoutEffect, useRef, useState } from 'react';
|
|
25
|
+
import { Button } from '@mistriwork/ui/Button.js';
|
|
26
|
+
import { Popover } from '@base-ui/react/popover';
|
|
27
|
+
import { WHOLE, canonicalize, conditionTail, mentionsColumn, ownedTails, squeeze, stripCondition, withCondition } from '../filterbar.js';
|
|
28
|
+
import { formatNumber } from '../locale.js';
|
|
29
|
+
import { columnKind } from '@mistriwork/engine/shared/schema.js';
|
|
30
|
+
import { layoutViewport, zoomAnchor } from '@mistriwork/ui/internal/anchor.js';
|
|
31
|
+
import { RefBox, boxTail, boxText, wrongForNumber } from './FilterBoxes.js';
|
|
32
|
+
import { useConditionWords } from './useConditionWords.js';
|
|
33
|
+
import { useArrived } from './onDemand.js';
|
|
34
|
+
import { SuggestBox } from './suggestPart.js';
|
|
35
|
+
import { FacetFor, useDraftCount } from './FilterRail.js';
|
|
36
|
+
import { clearFacets, facetActive } from './filterRailModel.js';
|
|
37
|
+
import { say } from '../copy/filters/components/ListFilterBar.js';
|
|
38
|
+
import { popupContainer } from '../shellHost.js';
|
|
39
|
+
export function ListFilterBar(props) {
|
|
40
|
+
const { boxes, search, refinement, tabQuery, apply, residue, phone, onSheet } = props;
|
|
41
|
+
const pickers = boxes.filter((box) => box !== search);
|
|
42
|
+
const columns = boxes.map((box) => box.column);
|
|
43
|
+
const active = boxes.filter((box) => facetActive(refinement, box.column, tabQuery)).length;
|
|
44
|
+
const narrowed = pickers.filter((box) => facetActive(refinement, box.column, tabQuery)).length;
|
|
45
|
+
/* One way to empty the row once there is more than one thing in it; the
|
|
46
|
+
lit tab's own conditions stay, as the rail's Clear all leaves them. The
|
|
47
|
+
focus goes to the row's first control, not the page. */
|
|
48
|
+
const clearAll = active >= 2 ? (_jsx("button", { type: "button", className: "applist-chips-clear", onClick: () => apply(clearFacets(refinement, columns, tabQuery), search?.column ?? pickers[0]?.column), children: say('list.clearAll') })) : null;
|
|
49
|
+
const residueChip = residue ? (_jsxs("span", { className: "applist-chip", children: [_jsx("span", { className: "applist-chip-text", children: residue.text }), _jsx("button", { type: "button", className: "applist-chip-x", "aria-label": say('common.remove2', { text: residue.text }), onClick: residue.remove, children: "\u00D7" })] })) : null;
|
|
50
|
+
const searchBox = search ? _jsx(SearchBox, { ...props, box: search }) : null;
|
|
51
|
+
/* On a desk the row keeps one line: the filters not yet asked for give way
|
|
52
|
+
from the end, into one "+ Filter" that opens every picker in the sheet,
|
|
53
|
+
rather than the last of them standing cut at the window's edge ("+ Orde…").
|
|
54
|
+
A chip never gives way — it says what the rows are. Counted before the
|
|
55
|
+
row is painted, so nothing is seen to jump. */
|
|
56
|
+
const idle = pickers.filter((box) => !facetActive(refinement, box.column, tabQuery));
|
|
57
|
+
const [folded, setFolded] = useState(0);
|
|
58
|
+
/* A new width is measured afresh even where nothing was folded: the fold
|
|
59
|
+
below runs after a render, and unfolding nothing renders nothing. */
|
|
60
|
+
const [, remeasure] = useState(0);
|
|
61
|
+
const mark = useRef(null);
|
|
62
|
+
const width = useRef(0);
|
|
63
|
+
useLayoutEffect(() => {
|
|
64
|
+
setFolded(0);
|
|
65
|
+
}, [refinement, tabQuery, boxes.length]);
|
|
66
|
+
useLayoutEffect(() => {
|
|
67
|
+
const row = mark.current?.closest('.applist-controls');
|
|
68
|
+
if (!row)
|
|
69
|
+
return;
|
|
70
|
+
/* The list's tabs give way after the filters (structure.css): told here when the filters have nothing left to give. */
|
|
71
|
+
row.toggleAttribute('data-filters-spent', !phone && folded >= idle.length);
|
|
72
|
+
if (phone)
|
|
73
|
+
return;
|
|
74
|
+
const over = row.scrollWidth - row.clientWidth;
|
|
75
|
+
if (over < 2 || folded >= idle.length)
|
|
76
|
+
return;
|
|
77
|
+
/* As many more of the shown pickers, from the end, as the room they stand in (their widths and the gaps before
|
|
78
|
+
them, in layout pixels as scrollWidth is) covers: every one that starts past where the row would have to end,
|
|
79
|
+
and the one before them. Never more than are needed — the "+ Filter" that folding brings takes room of its own —
|
|
80
|
+
so a row still too wide folds again on its next render. One a render, it was a render and a measure of the whole
|
|
81
|
+
row per picker, in every sort, filter and tab (test/built-client-vitals.mjs). */
|
|
82
|
+
const slots = [...row.querySelectorAll('.applist-slot[data-column]')];
|
|
83
|
+
const end = (node) => (node ? node.offsetLeft + node.offsetWidth : 0);
|
|
84
|
+
const limit = end(slots.at(-1)) - over;
|
|
85
|
+
setFolded(folded + 1 + slots.filter((slot) => end(slot.previousSibling) > limit).length);
|
|
86
|
+
});
|
|
87
|
+
useEffect(() => {
|
|
88
|
+
const row = mark.current?.closest('.applist-controls');
|
|
89
|
+
if (phone || !row || typeof ResizeObserver === 'undefined')
|
|
90
|
+
return undefined;
|
|
91
|
+
width.current = row.clientWidth;
|
|
92
|
+
const observer = new ResizeObserver(() => {
|
|
93
|
+
if (row.clientWidth === width.current)
|
|
94
|
+
return;
|
|
95
|
+
width.current = row.clientWidth;
|
|
96
|
+
setFolded(0);
|
|
97
|
+
remeasure((n) => n + 1);
|
|
98
|
+
});
|
|
99
|
+
observer.observe(row);
|
|
100
|
+
/* A look's face arriving after the first measure widens the words in a row whose own width never changed: the
|
|
101
|
+
fold was judged on the fallback's metrics, and the row scrolled 10px on a desk wherever the face was late. */
|
|
102
|
+
const fonts = typeof document === 'undefined' ? undefined : document.fonts;
|
|
103
|
+
const refit = () => {
|
|
104
|
+
setFolded(0);
|
|
105
|
+
remeasure((n) => n + 1);
|
|
106
|
+
};
|
|
107
|
+
fonts?.addEventListener?.('loadingdone', refit);
|
|
108
|
+
return () => {
|
|
109
|
+
observer.disconnect();
|
|
110
|
+
fonts?.removeEventListener?.('loadingdone', refit);
|
|
111
|
+
};
|
|
112
|
+
}, [phone]);
|
|
113
|
+
const hidden = new Set(folded ? idle.slice(-folded).map((box) => box.column) : []);
|
|
114
|
+
if (phone) {
|
|
115
|
+
/* The search stays in reach; the pickers are one button, and the chips
|
|
116
|
+
wrap under the box rather than pushing it off the row. */
|
|
117
|
+
return (_jsxs(_Fragment, { children: [searchBox, pickers.length > 0 && (_jsx("button", { type: "button", className: "applist-add applist-sheet-open", "aria-haspopup": "dialog", onClick: onSheet, children: narrowed ? say('common.filters', { narrowed }) : say('common.filtersButton') })), _jsxs("div", { className: "applist-bar-chips", children: [search && _jsx(FilterSlot, { ...props, box: search, chipOnly: true }), pickers.map((box) => (_jsx(FilterSlot, { ...props, box: box, chipOnly: true }, box.column))), residueChip, clearAll] })] }));
|
|
118
|
+
}
|
|
119
|
+
const rest = idle.filter((box) => hidden.has(box.column));
|
|
120
|
+
return (_jsxs(_Fragment, { children: [_jsx("span", { ref: mark, hidden: true }), searchBox, search && _jsx(FilterSlot, { ...props, box: search }), pickers
|
|
121
|
+
.filter((box) => !hidden.has(box.column))
|
|
122
|
+
.map((box) => (_jsx(FilterSlot, { ...props, box: box }, box.column))), rest.length > 0 && (_jsx("span", { className: "applist-slot applist-slot-more", children: _jsxs("button", { type: "button", className: "applist-add", "aria-haspopup": "dialog", "aria-label": say('moreFilters', { map: rest.map((box) => box.label).join(', ') }), onClick: onSheet, children: [_jsx("span", { className: "applist-add-mark", "aria-hidden": "true", children: "+" }), say('common.filter')] }) })), residueChip, clearAll] }));
|
|
123
|
+
}
|
|
124
|
+
/**
|
|
125
|
+
* One declared filter in its place in the row: its chip when it narrows the
|
|
126
|
+
* list, its "+" when it does not. A flag's "+" is one gesture, as its
|
|
127
|
+
* checkbox was; every other "+" opens the column's picker.
|
|
128
|
+
*/
|
|
129
|
+
function FilterSlot(props) {
|
|
130
|
+
const { box, search, refinement, tabQuery, apply, current, phone, onSheet, chipOnly } = props;
|
|
131
|
+
/* The lit tab says its own column; a chip would say it twice. */
|
|
132
|
+
const owned = mentionsColumn(tabQuery, box.column);
|
|
133
|
+
const tails = owned ? [] : ownedTails(refinement, box.column);
|
|
134
|
+
/* In the App's words: the label, the rule's word for a value, and a
|
|
135
|
+
reference by the name its box shows, not the id beneath it. */
|
|
136
|
+
const { speaker, sayTails } = useConditionWords(props.table, tails.map((tail) => `${box.column} ${tail}`));
|
|
137
|
+
const isSearch = box === search;
|
|
138
|
+
/* The search's own condition is in its box; a chip only for what the box cannot say. */
|
|
139
|
+
const chipped = tails.length > 0 && !(isSearch && tails.length === 1 && boxText(box, tails[0]));
|
|
140
|
+
if (chipped) {
|
|
141
|
+
const text = sayTails(speaker, box.column, tails);
|
|
142
|
+
const remove = () => apply(withCondition(current(), box.column, ''), box.column);
|
|
143
|
+
const onKeyDown = (e) => {
|
|
144
|
+
if (e.key !== 'Backspace' && e.key !== 'Delete')
|
|
145
|
+
return;
|
|
146
|
+
e.preventDefault();
|
|
147
|
+
remove();
|
|
148
|
+
};
|
|
149
|
+
const open = isSearch ? (_jsx("span", { className: "applist-chip-text", children: text })) : phone ? (_jsx("button", { type: "button", className: "applist-chip-text applist-chip-open", "aria-haspopup": "dialog", onClick: onSheet, onKeyDown: onKeyDown, children: text })) : (_jsx(Picker, { ...props, owned: false, className: "applist-chip-text applist-chip-open", onKeyDown: onKeyDown, children: text }));
|
|
150
|
+
return (_jsxs("span", { className: "applist-chip", "data-column": box.column, children: [open, _jsx("button", { type: "button", className: "applist-chip-x", "aria-label": say('common.remove2', { text }), onClick: remove, onKeyDown: onKeyDown, children: "\u00D7" })] }));
|
|
151
|
+
}
|
|
152
|
+
if (chipOnly || isSearch)
|
|
153
|
+
return null;
|
|
154
|
+
const plus = (_jsxs(_Fragment, { children: [_jsx("span", { className: "applist-add-mark", "aria-hidden": "true", children: "+" }), box.label] }));
|
|
155
|
+
if (box.kind === 'flag') {
|
|
156
|
+
return (_jsx("span", { className: "applist-slot", "data-column": box.column, children: _jsx("button", { type: "button", className: "applist-add", "aria-label": say('common.only', { label: box.label }), onClick: () => apply(withCondition(refinement, box.column, box.has?.segment ? WHOLE : '= true'), box.column), children: plus }) }));
|
|
157
|
+
}
|
|
158
|
+
return (_jsx("span", { className: "applist-slot", "data-column": box.column, children: _jsx(Picker, { ...props, owned: owned, className: "applist-add", label: say('common.filter2', { label: box.label }), children: plus }) }));
|
|
159
|
+
}
|
|
160
|
+
/* The list's name column as a search: Enter asks, and the field's own ×
|
|
161
|
+
(a search field's clear button) empties the question as Enter on an empty
|
|
162
|
+
box would. It reads what the question says and keeps what is typed. */
|
|
163
|
+
function SearchBox({ box, table, standing, refinement, typed, onType, onSearch, listLabel }) {
|
|
164
|
+
const input = useRef(null);
|
|
165
|
+
const viaEnter = useRef(false);
|
|
166
|
+
const said = boxText(box, squeeze(conditionTail(refinement, box.column)));
|
|
167
|
+
const fuzzy = !box.exact && (box.meta ? columnKind(box.meta.type) === 'text' : false);
|
|
168
|
+
const suggesting = useArrived(SuggestBox, Boolean(box.suggest?.length));
|
|
169
|
+
useEffect(() => {
|
|
170
|
+
const el = input.current;
|
|
171
|
+
if (!el)
|
|
172
|
+
return undefined;
|
|
173
|
+
/* The search event also comes with Enter, which the form already answers. */
|
|
174
|
+
const cleared = () => {
|
|
175
|
+
if (viaEnter.current) {
|
|
176
|
+
viaEnter.current = false;
|
|
177
|
+
return;
|
|
178
|
+
}
|
|
179
|
+
if (el.value === '' && said)
|
|
180
|
+
onSearch();
|
|
181
|
+
};
|
|
182
|
+
el.addEventListener('search', cleared);
|
|
183
|
+
return () => el.removeEventListener('search', cleared);
|
|
184
|
+
}, [said, onSearch, suggesting]);
|
|
185
|
+
const wrong = wrongForNumber(box, typed);
|
|
186
|
+
const inputProps = {
|
|
187
|
+
type: 'search',
|
|
188
|
+
className: 'applist-search-input',
|
|
189
|
+
...(box.meta && columnKind(box.meta.type) === 'number' ? { inputMode: 'decimal' } : {}),
|
|
190
|
+
...(wrong ? { 'aria-invalid': true, title: say('takesANumber', { label: box.label }) } : {}),
|
|
191
|
+
placeholder: fuzzy ? say('search', { listLabel: listLabel.toLowerCase() }) : say('labelEquals', { label: box.label }),
|
|
192
|
+
'aria-label': say('common.filter2', { label: box.label }),
|
|
193
|
+
...(wrong ? {} : { title: fuzzy ? say('matchesAnywhereInTheAny', { label: box.label.toLowerCase() }) : undefined }),
|
|
194
|
+
onKeyDown: (e) => {
|
|
195
|
+
viaEnter.current = e.key === 'Enter';
|
|
196
|
+
/* Asked for, not left to implicit submission: a form with two
|
|
197
|
+
fields (this and the query bar's) and no submit button has none. */
|
|
198
|
+
if (e.key === 'Enter' && !e.nativeEvent.isComposing) {
|
|
199
|
+
e.preventDefault();
|
|
200
|
+
onSearch();
|
|
201
|
+
}
|
|
202
|
+
},
|
|
203
|
+
};
|
|
204
|
+
return (_jsx("span", { className: "applist-search", "data-column": box.column, children: suggesting && box.suggest ? (_jsx(SuggestBox, { table: table.id, columns: box.suggest, standing: standing, text: typed ?? said, onText: onType, onPick: (value) => {
|
|
205
|
+
onType(value);
|
|
206
|
+
onSearch();
|
|
207
|
+
}, inputProps: inputProps, inputRef: input })) : (_jsx("input", { ref: input, ...inputProps, value: typed ?? said, onChange: (e) => onType(e.target.value) })) }));
|
|
208
|
+
}
|
|
209
|
+
/**
|
|
210
|
+
* A "+" or a chip, and the popover it opens: anchored on the zoom-aware
|
|
211
|
+
* ruler, drawn inside the enclosing dialog when there is one, the focus on
|
|
212
|
+
* its first field as it opens and back on its button when Escape closes it.
|
|
213
|
+
*/
|
|
214
|
+
function Picker({ className, label, onKeyDown, owned, children, ...props }) {
|
|
215
|
+
const { box, refinement } = props;
|
|
216
|
+
const trigger = useRef(null);
|
|
217
|
+
const popup = useRef(null);
|
|
218
|
+
const [open, setOpen] = useState(false);
|
|
219
|
+
const [container, setContainer] = useState(null);
|
|
220
|
+
useEffect(() => {
|
|
221
|
+
setContainer(trigger.current?.closest('dialog, [role="dialog"]'));
|
|
222
|
+
}, []);
|
|
223
|
+
return (_jsxs(Popover.Root, { open: open, onOpenChange: setOpen, children: [_jsx(Popover.Trigger, { render: _jsx("button", { type: "button", className: className, "aria-label": label, ref: trigger, onKeyDown: onKeyDown }), children: children }), _jsx(Popover.Portal, { container: container ?? popupContainer(), children: _jsx(Popover.Positioner, { anchor: () => (trigger.current ? zoomAnchor(trigger.current) : null), positionMethod: "fixed", side: "bottom", align: "start", sideOffset: 6, collisionBoundary: layoutViewport(), collisionPadding: 8, style: { zIndex: 40 }, children: _jsx(Popover.Popup, { ref: popup, className: "filter-pop", "aria-label": say('common.filter2', { label: box.label }), "data-column": box.column, initialFocus: () => popup.current?.querySelector('input:not([type="hidden"]):not([aria-hidden="true"])') ?? true, children: _jsx(FilterPicker, { box: box, table: props.table, refinement: refinement, standing: props.standing, unit: props.unitOf(box.column), owned: owned, apply: props.apply, close: () => setOpen(false) }) }) }) })] }));
|
|
224
|
+
}
|
|
225
|
+
/** One column's picker: a reference's typeahead, or the rail's facet over a draft. */
|
|
226
|
+
export function FilterPicker(props) {
|
|
227
|
+
const { box, refinement, owned, apply } = props;
|
|
228
|
+
return box.kind === 'ref' ? (_jsx(ReferencePicker, { box: box, tail: owned ? '' : squeeze(conditionTail(refinement, box.column)), refinement: refinement, apply: apply })) : (_jsx(FacetPicker, { ...props }));
|
|
229
|
+
}
|
|
230
|
+
/**
|
|
231
|
+
* The rail's facet for one column, editing a draft that one button applies,
|
|
232
|
+
* saying what it will show as the sheet's does — and, to a screen reader, as
|
|
233
|
+
* the draft changes. Where the lit tab speaks for the column the picker
|
|
234
|
+
* starts blank — the tab says it — and a tick replaces the tab's condition,
|
|
235
|
+
* as the box's choice did.
|
|
236
|
+
*/
|
|
237
|
+
function FacetPicker({ box, refinement, table, standing, unit, apply, owned, close }) {
|
|
238
|
+
const [draft, setDraft] = useState(refinement);
|
|
239
|
+
/* Read when the draft is applied, which can be in the event that set it (Enter in a box). */
|
|
240
|
+
const now = useRef(refinement);
|
|
241
|
+
const set = (tail) => {
|
|
242
|
+
now.current = withCondition(now.current, box.column, tail);
|
|
243
|
+
setDraft(now.current);
|
|
244
|
+
};
|
|
245
|
+
const unchanged = canonicalize(draft) === canonicalize(refinement);
|
|
246
|
+
const go = () => {
|
|
247
|
+
if (canonicalize(now.current) === canonicalize(refinement))
|
|
248
|
+
close();
|
|
249
|
+
else
|
|
250
|
+
apply(now.current, box.column);
|
|
251
|
+
};
|
|
252
|
+
const n = useDraftCount(table, standing, draft);
|
|
253
|
+
const form = useRef(null);
|
|
254
|
+
/* A facet whose shape is still being counted has no field yet as the
|
|
255
|
+
popover opens, which then holds the focus itself: the first field to
|
|
256
|
+
arrive takes it, unless the reader has already moved it. */
|
|
257
|
+
useEffect(() => {
|
|
258
|
+
const home = form.current;
|
|
259
|
+
const pop = home?.closest('.filter-pop');
|
|
260
|
+
if (!home || !pop || typeof MutationObserver === 'undefined')
|
|
261
|
+
return undefined;
|
|
262
|
+
const field = () => home.querySelector('input:not([type="hidden"]):not([aria-hidden="true"])');
|
|
263
|
+
if (field())
|
|
264
|
+
return undefined;
|
|
265
|
+
const observer = new MutationObserver(() => {
|
|
266
|
+
const first = field();
|
|
267
|
+
if (!first)
|
|
268
|
+
return;
|
|
269
|
+
observer.disconnect();
|
|
270
|
+
/* After the popover's own focus management has settled on its frame. */
|
|
271
|
+
setTimeout(() => {
|
|
272
|
+
if (document.activeElement === pop || document.activeElement === document.body)
|
|
273
|
+
first.focus();
|
|
274
|
+
}, 0);
|
|
275
|
+
});
|
|
276
|
+
observer.observe(home, { childList: true, subtree: true });
|
|
277
|
+
return () => observer.disconnect();
|
|
278
|
+
}, []);
|
|
279
|
+
return (_jsxs("form", { ref: form, className: "filter-pop-form", onSubmit: (e) => {
|
|
280
|
+
e.preventDefault();
|
|
281
|
+
e.stopPropagation();
|
|
282
|
+
go();
|
|
283
|
+
}, children: [_jsx(FacetFor, { box: box, table: table, refinement: owned && unchanged ? stripCondition(draft, box.column) : draft, standing: standing, unit: unit, set: set, onEnter: go, picking: true }), _jsx("p", { className: "visually-hidden", role: "status", children: typeof n === 'number' ? say('match', { n: formatNumber(n) }) : '' }), _jsx("div", { className: "filter-pop-foot", children: _jsx(Button, { intent: "primary", size: "compact", type: "submit", children: typeof n === 'number' ? say('showN', { n: formatNumber(n) }) : say('common.showResults') }) })] }));
|
|
284
|
+
}
|
|
285
|
+
/* A reference is the typeahead its box was: type a name, pick a row, and the
|
|
286
|
+
question says its id. A pick is the decision, so it applies at once; Enter
|
|
287
|
+
on typed text asks for it as written. The list is up as the picker opens. */
|
|
288
|
+
function ReferencePicker({ box, tail, refinement, apply, }) {
|
|
289
|
+
const [edit, setEdit] = useState(undefined);
|
|
290
|
+
const now = useRef(undefined);
|
|
291
|
+
const onEdit = (next) => {
|
|
292
|
+
now.current = next;
|
|
293
|
+
setEdit(next);
|
|
294
|
+
};
|
|
295
|
+
const submit = () => {
|
|
296
|
+
if (now.current)
|
|
297
|
+
apply(withCondition(refinement, box.column, boxTail(box, now.current, tail)), box.column);
|
|
298
|
+
};
|
|
299
|
+
return (_jsx("form", { className: "filter-pop-form", onSubmit: (e) => {
|
|
300
|
+
e.preventDefault();
|
|
301
|
+
e.stopPropagation();
|
|
302
|
+
submit();
|
|
303
|
+
}, children: _jsxs("div", { className: "facet", "data-column": box.column, children: [_jsx("span", { className: "facet-label", "aria-hidden": "true", children: box.label }), tail && (_jsx("button", { type: "button", className: "facet-clear", "aria-label": say('common.clear2', { label: box.label }), onClick: () => apply(withCondition(refinement, box.column, ''), box.column), children: say('common.clear') })), _jsx(RefBox, { box: box, tail: tail, edit: edit, onEdit: onEdit, onSubmit: submit, startOpen: true, portal: "body" })] }) }));
|
|
304
|
+
}
|
|
@@ -0,0 +1,105 @@
|
|
|
1
|
+
/* A component's own rules, brought with it: after the base, before any look (style.css names the order). */
|
|
2
|
+
@layer components {
|
|
3
|
+
/* Live sync's words (docs/design.md, rule 11). None of them is in flow: a change from elsewhere never moves what the
|
|
4
|
+
reader is looking at. */
|
|
5
|
+
|
|
6
|
+
/* Over a held list, at the top of the window below the bar, and not a toast: it stays until it is clicked or the
|
|
7
|
+
reader stops working in the list. */
|
|
8
|
+
.live-pill-host {
|
|
9
|
+
position: fixed; top: calc(var(--space-8) + var(--space-4)); left: 50%; transform: translateX(-50%);
|
|
10
|
+
z-index: 55; pointer-events: none;
|
|
11
|
+
}
|
|
12
|
+
.live-pill {
|
|
13
|
+
pointer-events: auto; min-height: 28px; padding: var(--space-1) var(--space-4);
|
|
14
|
+
border: 1px solid var(--line-strong); border-radius: 999px;
|
|
15
|
+
background: var(--surface); color: var(--ink); box-shadow: var(--shadow-pop);
|
|
16
|
+
font: 600 var(--text-sm)/20px var(--sans); cursor: pointer;
|
|
17
|
+
}
|
|
18
|
+
.live-pill:hover { background: var(--accent-soft); color: var(--accent-ink); }
|
|
19
|
+
|
|
20
|
+
/* In the head's top row, at its far end, out of flow: a record's name never waits on it. */
|
|
21
|
+
.page-head-top { position: relative; }
|
|
22
|
+
.live-updated {
|
|
23
|
+
position: absolute; inset-inline-end: 0; top: 50%; transform: translateY(-50%);
|
|
24
|
+
max-width: 60%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
|
|
25
|
+
font: var(--text-xs)/16px var(--sans); color: var(--ink-muted);
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
/* In a draft's bar beside the fields (a dialog, a board's card), a row of its own across it. */
|
|
29
|
+
.live-notice {
|
|
30
|
+
flex-basis: 100%; display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-3);
|
|
31
|
+
padding-bottom: var(--space-3); border-bottom: 1px solid var(--line);
|
|
32
|
+
}
|
|
33
|
+
.live-notice-text { flex: 1 1 12rem; min-width: 0; font: 600 var(--text-sm)/20px var(--sans); color: var(--ink); overflow-wrap: anywhere; }
|
|
34
|
+
.live-review { flex-basis: 100%; margin: 0; display: grid; gap: var(--space-3); max-height: 30dvh; overflow-y: auto; }
|
|
35
|
+
|
|
36
|
+
/* A record room's draft: hung from the record's head (the bar's place in it, .page-pending, is its last row and holds
|
|
37
|
+
nothing in flow), over the gap above the fields, one line at a desk. Out of flow, so the fields never move when it
|
|
38
|
+
comes or goes; opened to review, it lays the changes over the fields like a menu, and closes the same way. */
|
|
39
|
+
.page-pending { position: relative; }
|
|
40
|
+
/* The row it hangs in is reserved from the first edit, before any change arrives, so its coming moves nothing: the
|
|
41
|
+
notice's own height and a gap under it, one line at a desk, a sentence over two answers on a phone. */
|
|
42
|
+
.page-pending.has-live-draft { min-height: calc(var(--live-notice-h, 34px) + 2 * var(--space-3)); }
|
|
43
|
+
.live-notice.is-anchored {
|
|
44
|
+
position: absolute; z-index: 30; top: var(--space-3); inset-inline-start: 0;
|
|
45
|
+
width: max-content; max-width: 100%; box-sizing: border-box;
|
|
46
|
+
flex-wrap: nowrap; gap: var(--space-2);
|
|
47
|
+
padding: var(--space-1h) var(--space-1h) var(--space-1h) var(--space-4);
|
|
48
|
+
border: 1px solid var(--line-strong); border-radius: var(--radius, 6px);
|
|
49
|
+
background: var(--surface); box-shadow: var(--shadow-pop);
|
|
50
|
+
}
|
|
51
|
+
.live-notice.is-anchored .live-notice-text { flex: 0 1 auto; margin-inline-end: var(--space-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; overflow-wrap: normal; }
|
|
52
|
+
.live-notice.is-anchored > button { flex: none; min-height: 28px; padding: 0 var(--space-3); font: 500 var(--text-sm)/1 var(--sans); }
|
|
53
|
+
/* Answers are quiet words, not a box of boxes inside the box: a link's colour, a tint on hover. */
|
|
54
|
+
.live-notice.is-anchored > button.live-act { border-color: transparent; background: none; box-shadow: none; color: var(--link); }
|
|
55
|
+
.live-notice.is-anchored > button.live-act:hover { background: var(--accent-soft); color: var(--accent-ink); }
|
|
56
|
+
.live-notice.is-anchored.is-reviewing { flex-wrap: wrap; width: min(100%, 44rem); padding-block-end: var(--space-3); }
|
|
57
|
+
.live-notice.is-anchored :is(.live-review, .live-review-note) { padding-inline-end: var(--space-3); }
|
|
58
|
+
.live-notice.is-anchored .live-review { max-height: 50dvh; padding-block-start: var(--space-3); border-top: 1px solid var(--line); }
|
|
59
|
+
/* A phone: the sentence on its line, cut short rather than wrapped, and the two answers side by side under it, each
|
|
60
|
+
half the width and a thumb's height. Over the top of the fields, never over the bar of verbs at the foot. */
|
|
61
|
+
@media (max-width: 600px) {
|
|
62
|
+
.page-pending.has-live-draft { --live-notice-h: 76px; }
|
|
63
|
+
.live-notice.is-anchored {
|
|
64
|
+
inset-inline: 0; width: auto;
|
|
65
|
+
display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: var(--space-2);
|
|
66
|
+
padding: var(--space-2h) var(--space-3);
|
|
67
|
+
}
|
|
68
|
+
.live-notice.is-anchored .live-notice-text { grid-column: 1 / -1; margin: 0; }
|
|
69
|
+
.live-notice.is-anchored > button { min-height: 36px; justify-content: center; }
|
|
70
|
+
.live-notice.is-anchored > button:only-of-type { grid-column: 1 / -1; }
|
|
71
|
+
.live-notice.is-anchored.is-reviewing { width: auto; }
|
|
72
|
+
.live-notice.is-anchored :is(.live-review, .live-review-note) { grid-column: 1 / -1; padding-inline-end: 0; }
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
/* A command form's status line: the sentence, and Keep editing as a quiet word after it. The line is there before the
|
|
76
|
+
change and after it, so saying it there moves nothing. */
|
|
77
|
+
.live-notice.is-inline { display: inline; padding: 0; border: 0; }
|
|
78
|
+
.live-notice.is-inline .live-notice-text { font-weight: 600; }
|
|
79
|
+
.live-notice.is-inline > button {
|
|
80
|
+
margin-inline-start: var(--space-2); padding: 0; min-height: 0; border: 0; background: none;
|
|
81
|
+
font: inherit; color: var(--link); text-decoration: underline; text-underline-offset: 2px; cursor: pointer;
|
|
82
|
+
}
|
|
83
|
+
.live-review-field { display: grid; gap: var(--space-1); }
|
|
84
|
+
.live-review dt { font: 600 var(--text-xs)/16px var(--sans); color: var(--ink-muted); }
|
|
85
|
+
.live-review dd { margin: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)) auto; gap: var(--space-3); align-items: start; font: var(--text-sm)/18px var(--sans); }
|
|
86
|
+
.live-review-col { display: grid; min-width: 0; overflow-wrap: anywhere; }
|
|
87
|
+
.live-review-col small { color: var(--ink-subtle); font: var(--text-xs)/14px var(--sans); }
|
|
88
|
+
.live-review-note { flex-basis: 100%; margin: 0; color: var(--ink-muted); font: var(--text-sm)/18px var(--sans); }
|
|
89
|
+
@media (max-width: 600px) {
|
|
90
|
+
.live-review dd { grid-template-columns: minmax(0, 1fr); }
|
|
91
|
+
}
|
|
92
|
+
/* A command form's status line, kept for a screen reader alone while the form is ready (style.css), unless it holds a
|
|
93
|
+
change from elsewhere: then it is drawn, and Keep editing can be pressed. Out of flow, as a record's
|
|
94
|
+
notice is, and one line the height of the gap between the fields and the actions, so it covers neither and its
|
|
95
|
+
coming moves nothing; a long sentence gives way before its button does. Here, not in the first stylesheet: only a
|
|
96
|
+
form this part draws into needs it. */
|
|
97
|
+
.command-form form:has(> .command-feedback[data-live]) { position: relative; }
|
|
98
|
+
.command-form .command-feedback[data-phase="ready"][data-live] {
|
|
99
|
+
inset-inline: 0; width: auto; height: var(--space-6); min-height: 0; margin: 0; overflow: hidden; clip-path: none;
|
|
100
|
+
display: flex; align-items: center; color: var(--ink); font-size: var(--text-sm); white-space: nowrap;
|
|
101
|
+
}
|
|
102
|
+
.command-feedback[data-live] .live-notice.is-inline { display: flex; align-items: center; min-width: 0; }
|
|
103
|
+
.command-feedback[data-live] .live-notice-text { min-width: 0; overflow: hidden; text-overflow: ellipsis; }
|
|
104
|
+
.command-feedback[data-live] .live-notice.is-inline > button { flex: none; }
|
|
105
|
+
}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import type { TableMeta } from '@mistriwork/engine/shared/schema.js';
|
|
2
|
+
import './LiveNotices.css';
|
|
3
|
+
export declare function LivePill({ held, show }: {
|
|
4
|
+
held: number | 'many';
|
|
5
|
+
show: () => void;
|
|
6
|
+
}): import("react").ReactPortal;
|
|
7
|
+
/** Tests only: forget every record's pace. */
|
|
8
|
+
export declare function resetChangedBy(): void;
|
|
9
|
+
/**
|
|
10
|
+
* "Updated by Ana just now", for ten minutes, said again each minute; "by you" for the reader's own change in another
|
|
11
|
+
* tab. Not while the reader has a draft of the record: the notice over the draft says it, with what to do about it.
|
|
12
|
+
*/
|
|
13
|
+
export declare function LiveUpdatedLine({ table, recordKey }: {
|
|
14
|
+
table: TableMeta;
|
|
15
|
+
recordKey: Readonly<Record<string, unknown>>;
|
|
16
|
+
}): import("react").JSX.Element;
|
|
17
|
+
/**
|
|
18
|
+
* "Ana changed this ticket", beside a draft of that ticket, with Review changes and Keep editing. `anchored` hangs it
|
|
19
|
+
* from the record's head over the gap above the fields, out of flow (a record room's draft); `inline` says it in a
|
|
20
|
+
* form's status line, without Review, since what a command form holds is not the record's fields.
|
|
21
|
+
*/
|
|
22
|
+
export declare function LiveEditNotice({ table, recordKey, place, }: {
|
|
23
|
+
table: TableMeta;
|
|
24
|
+
recordKey: Readonly<Record<string, unknown>>;
|
|
25
|
+
place?: 'anchored' | 'inline';
|
|
26
|
+
}): import("react").JSX.Element;
|
|
@@ -0,0 +1,211 @@
|
|
|
1
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
+
/**
|
|
3
|
+
* What live sync says where a change from elsewhere lands (docs/design.md, rule 11): the pill over a list that is
|
|
4
|
+
* held, the line under a record's head, and the notice over a draft with the changes laid beside it.
|
|
5
|
+
*
|
|
6
|
+
* Out of flow, all of it: the pill is fixed to the window, the line sits in the head's top row without taking room
|
|
7
|
+
* from it, the notice over a record's draft hangs from the record's head, over the gap above its fields, and a
|
|
8
|
+
* command form's stands in its status line. None of it moves what the reader is looking at. A part of its own
|
|
9
|
+
* (onDemand.tsx), fetched when the first change that needs it arrives.
|
|
10
|
+
*/
|
|
11
|
+
import { useCallback, useEffect, useState, useSyncExternalStore } from 'react';
|
|
12
|
+
import { createPortal } from 'react-dom';
|
|
13
|
+
import { useQuery } from '@tanstack/react-query';
|
|
14
|
+
import { api, columnLabel } from '../core.js';
|
|
15
|
+
import { shell } from '../shellMode.js';
|
|
16
|
+
import { dirtyDraft, pendingCount, sameRow, stagedVersion, subscribeStaged, takeTheirs } from '../write.js';
|
|
17
|
+
import { pathEqualityFilter } from '../resourceRequests.js';
|
|
18
|
+
import { historyBody } from '@mistriwork/engine/shared/recordReads.js';
|
|
19
|
+
import { recordNoun } from '@mistriwork/engine/shared/appNoun.js';
|
|
20
|
+
import { dismissEditNotice, liveKeyText, useEditNotice, useRecentChange } from '../liveState.js';
|
|
21
|
+
import { say } from '../copy/record/components/LiveNotices.js';
|
|
22
|
+
import './LiveNotices.css';
|
|
23
|
+
import { portalRoot } from '../shellHost.js';
|
|
24
|
+
/* ---------- the pill over a held list ---------- */
|
|
25
|
+
export function LivePill({ held, show }) {
|
|
26
|
+
const label = held === 'many' ? say('pillMany') : say('pill', { updates: say('updates', { count: held }) });
|
|
27
|
+
return createPortal(_jsx("div", { className: "live-pill-host", role: "status", children: _jsx("button", { type: "button", className: "live-pill", onClick: show, "aria-label": say('showUpdates'), title: say('showUpdates'), children: label }) }), portalRoot());
|
|
28
|
+
}
|
|
29
|
+
/* ---------- who changed it, without leaking ---------- */
|
|
30
|
+
/* Tables whose history the reader cannot read (or that keep none): not asked again. */
|
|
31
|
+
const NO_HISTORY = new Set();
|
|
32
|
+
/* At most one history read a second for a record, however fast its changes come: a busy record's line under its head
|
|
33
|
+
and the notice over its draft both asked again on every live batch, about four reads a second each. The first change
|
|
34
|
+
in a second is asked at once, so it is named as fast as before; the ones after it wait out the second and are asked
|
|
35
|
+
as one, for the newest, so the name said is still the last author's. Shared by everything drawn for the record. */
|
|
36
|
+
const READ_GAP = 1000;
|
|
37
|
+
const paced = new Map();
|
|
38
|
+
/* The records kept: past it, the longest-kept one nothing draws is let go. */
|
|
39
|
+
const PACED_MOST = 200;
|
|
40
|
+
function pacedFor(id) {
|
|
41
|
+
let found = paced.get(id);
|
|
42
|
+
if (!found) {
|
|
43
|
+
paced.set(id, (found = { asked: 0, newest: 0, read: -Infinity, listeners: new Set() }));
|
|
44
|
+
for (const [other, p] of paced) {
|
|
45
|
+
if (paced.size <= PACED_MOST)
|
|
46
|
+
break;
|
|
47
|
+
if (!p.listeners.size && !p.timer)
|
|
48
|
+
paced.delete(other);
|
|
49
|
+
}
|
|
50
|
+
}
|
|
51
|
+
return found;
|
|
52
|
+
}
|
|
53
|
+
function subscribePaced(id, listener) {
|
|
54
|
+
const p = pacedFor(id);
|
|
55
|
+
p.listeners.add(listener);
|
|
56
|
+
return () => p.listeners.delete(listener);
|
|
57
|
+
}
|
|
58
|
+
function offerChange(id, at) {
|
|
59
|
+
const p = pacedFor(id);
|
|
60
|
+
if (at <= p.newest)
|
|
61
|
+
return;
|
|
62
|
+
p.newest = at;
|
|
63
|
+
if (p.timer)
|
|
64
|
+
return;
|
|
65
|
+
const ask = () => {
|
|
66
|
+
p.timer = undefined;
|
|
67
|
+
p.read = Date.now();
|
|
68
|
+
p.asked = p.newest;
|
|
69
|
+
for (const listener of p.listeners)
|
|
70
|
+
listener();
|
|
71
|
+
};
|
|
72
|
+
const wait = p.read + READ_GAP - Date.now();
|
|
73
|
+
if (wait <= 0)
|
|
74
|
+
ask();
|
|
75
|
+
else
|
|
76
|
+
p.timer = setTimeout(ask, wait);
|
|
77
|
+
}
|
|
78
|
+
/** Tests only: forget every record's pace. */
|
|
79
|
+
export function resetChangedBy() {
|
|
80
|
+
for (const p of paced.values())
|
|
81
|
+
clearTimeout(p.timer);
|
|
82
|
+
paced.clear();
|
|
83
|
+
}
|
|
84
|
+
/**
|
|
85
|
+
* The name of the newest author of a record, by the record's history under the reader's own grants: undefined where
|
|
86
|
+
* the reader may not read it (the server answers as it does for anyone) or it names no person. The event itself
|
|
87
|
+
* never carries an actor.
|
|
88
|
+
*/
|
|
89
|
+
function useChangedBy(table, key, at, wanted) {
|
|
90
|
+
const id = `${table.id}\u0000${liveKeyText(key)}`;
|
|
91
|
+
const subscribe = useCallback((listener) => subscribePaced(id, listener), [id]);
|
|
92
|
+
const asked = useSyncExternalStore(subscribe, () => paced.get(id)?.asked ?? 0, () => 0);
|
|
93
|
+
useEffect(() => {
|
|
94
|
+
if (wanted && at)
|
|
95
|
+
offerChange(id, at);
|
|
96
|
+
}, [id, at, wanted]);
|
|
97
|
+
const read = useQuery({
|
|
98
|
+
queryKey: ['live-history', table.id, liveKeyText(key), asked],
|
|
99
|
+
enabled: wanted && asked > 0 && !NO_HISTORY.has(table.id),
|
|
100
|
+
retry: false,
|
|
101
|
+
staleTime: 60_000,
|
|
102
|
+
gcTime: 60_000,
|
|
103
|
+
/* The name read for the change before stays while the next is read: no flicker to "someone" between them. */
|
|
104
|
+
placeholderData: (previous) => previous,
|
|
105
|
+
queryFn: async () => {
|
|
106
|
+
try {
|
|
107
|
+
const page = (await api('/api/record-history', historyBody(table, key, 1)));
|
|
108
|
+
const by = page.entries?.[0]?.by;
|
|
109
|
+
return by && !/[^\s@]+@[^\s@]+\.[^\s@]+/.test(by) ? by : null;
|
|
110
|
+
}
|
|
111
|
+
catch {
|
|
112
|
+
NO_HISTORY.add(table.id);
|
|
113
|
+
return null;
|
|
114
|
+
}
|
|
115
|
+
},
|
|
116
|
+
});
|
|
117
|
+
return read.data ?? undefined;
|
|
118
|
+
}
|
|
119
|
+
/* ---------- the line under a record's head ---------- */
|
|
120
|
+
const GONE_AFTER = 10 * 60_000;
|
|
121
|
+
/**
|
|
122
|
+
* "Updated by Ana just now", for ten minutes, said again each minute; "by you" for the reader's own change in another
|
|
123
|
+
* tab. Not while the reader has a draft of the record: the notice over the draft says it, with what to do about it.
|
|
124
|
+
*/
|
|
125
|
+
export function LiveUpdatedLine({ table, recordKey }) {
|
|
126
|
+
useSyncExternalStore(subscribeStaged, stagedVersion, stagedVersion);
|
|
127
|
+
const drafting = sameRow(table.id, recordKey) && pendingCount() > 0;
|
|
128
|
+
const recent = useRecentChange(table.id, liveKeyText(recordKey));
|
|
129
|
+
const [now, setNow] = useState(() => Date.now());
|
|
130
|
+
useEffect(() => {
|
|
131
|
+
const timer = setInterval(() => setNow(Date.now()), 60_000);
|
|
132
|
+
return () => clearInterval(timer);
|
|
133
|
+
}, []);
|
|
134
|
+
const name = useChangedBy(table, recordKey, recent?.at ?? 0, Boolean(recent && !recent.self));
|
|
135
|
+
if (!recent || drafting || now - recent.at >= GONE_AFTER)
|
|
136
|
+
return null;
|
|
137
|
+
const minutes = Math.floor((now - recent.at) / 60_000);
|
|
138
|
+
const when = minutes < 1 ? say('justNow') : say('minutesAgo', { count: minutes });
|
|
139
|
+
const who = recent.self ? say('you') : name;
|
|
140
|
+
return (_jsx("span", { className: "live-updated", role: "status", children: who ? say('updatedBy', { who, when }) : say('updated', { when }) }));
|
|
141
|
+
}
|
|
142
|
+
/* ---------- the notice over a draft ---------- */
|
|
143
|
+
/** What another person changed of the fields the reader is changing, side by side. */
|
|
144
|
+
function Review({ table, recordKey }) {
|
|
145
|
+
const draft = dirtyDraft();
|
|
146
|
+
const columns = draft ? Object.keys(draft.values) : [];
|
|
147
|
+
const theirs = useQuery({
|
|
148
|
+
// A copy of its own: the record the form is drawn from is not read over a draft.
|
|
149
|
+
queryKey: ['live-review', table.id, liveKeyText(recordKey), columns.join(',')],
|
|
150
|
+
enabled: columns.length > 0,
|
|
151
|
+
retry: false,
|
|
152
|
+
staleTime: 0,
|
|
153
|
+
gcTime: 0,
|
|
154
|
+
queryFn: async () => {
|
|
155
|
+
const reply = (await api('/api/view/run', {
|
|
156
|
+
count: 'none',
|
|
157
|
+
view: {
|
|
158
|
+
id: `live:${table.id}`,
|
|
159
|
+
name: table.name,
|
|
160
|
+
base: table.id,
|
|
161
|
+
columns: columns.map((path) => ({ path })),
|
|
162
|
+
filter: pathEqualityFilter(recordKey),
|
|
163
|
+
limit: 1,
|
|
164
|
+
},
|
|
165
|
+
}));
|
|
166
|
+
return reply.rows?.[0] ?? null;
|
|
167
|
+
},
|
|
168
|
+
});
|
|
169
|
+
if (!draft)
|
|
170
|
+
return null;
|
|
171
|
+
if (theirs.isPending)
|
|
172
|
+
return _jsx("p", { className: "live-review-note", children: say('reading') });
|
|
173
|
+
if (theirs.isError || !theirs.data)
|
|
174
|
+
return _jsx("p", { className: "live-review-note", children: say('couldNotRead') });
|
|
175
|
+
const said = (value) => (value === null || value === undefined || value === '' ? say('empty') : String(value));
|
|
176
|
+
const differing = columns.filter((column) => said(theirs.data[column]) !== said(draft.originals[column]));
|
|
177
|
+
if (!differing.length)
|
|
178
|
+
return _jsx("p", { className: "live-review-note", children: say('nothingDiffers') });
|
|
179
|
+
return (_jsx("dl", { className: "live-review", "aria-label": say('theirChanges'), children: differing.map((column) => (_jsxs("div", { className: "live-review-field", children: [_jsx("dt", { children: columnLabel(table.id, column) ?? column }), _jsxs("dd", { children: [_jsxs("span", { className: "live-review-col", children: [_jsx("small", { children: say('original') }), said(draft.originals[column])] }), _jsxs("span", { className: "live-review-col", children: [_jsx("small", { children: say('yours') }), said(draft.values[column])] }), _jsxs("span", { className: "live-review-col", children: [_jsx("small", { children: say('theirs') }), said(theirs.data[column])] }), _jsx("button", { type: "button", className: "ghost", onClick: () => takeTheirs(column, theirs.data[column]), children: say('takeTheirs') })] })] }, column))) }));
|
|
180
|
+
}
|
|
181
|
+
/**
|
|
182
|
+
* "Ana changed this ticket", beside a draft of that ticket, with Review changes and Keep editing. `anchored` hangs it
|
|
183
|
+
* from the record's head over the gap above the fields, out of flow (a record room's draft); `inline` says it in a
|
|
184
|
+
* form's status line, without Review, since what a command form holds is not the record's fields.
|
|
185
|
+
*/
|
|
186
|
+
export function LiveEditNotice({ table, recordKey, place, }) {
|
|
187
|
+
const text = liveKeyText(recordKey);
|
|
188
|
+
const notice = useEditNotice(table.id, text);
|
|
189
|
+
const [reviewing, setReviewing] = useState(false);
|
|
190
|
+
/* Asked for this change, not the last one: a second person's change under the same draft names the second person. */
|
|
191
|
+
const name = useChangedBy(table, recordKey, notice?.at ?? 0, Boolean(notice && !notice.self));
|
|
192
|
+
useEffect(() => {
|
|
193
|
+
if (!notice)
|
|
194
|
+
setReviewing(false);
|
|
195
|
+
}, [notice]);
|
|
196
|
+
if (!notice)
|
|
197
|
+
return null;
|
|
198
|
+
const record = recordNoun(shell().app()?.resources[table.id]?.noun, table.name);
|
|
199
|
+
const sentence = notice.kind === 'delete'
|
|
200
|
+
? name
|
|
201
|
+
? say('deletedBy', { name, record })
|
|
202
|
+
: say('deletedBySomeone', { record })
|
|
203
|
+
: notice.self
|
|
204
|
+
? say('changedByYou', { record })
|
|
205
|
+
: name
|
|
206
|
+
? say('changedBy', { name, record })
|
|
207
|
+
: say('changedBySomeone', { record });
|
|
208
|
+
if (place === 'inline')
|
|
209
|
+
return (_jsxs("span", { className: "live-notice is-inline", children: [_jsx("span", { className: "live-notice-text", children: sentence }), _jsx("button", { type: "button", className: "ghost", onClick: () => dismissEditNotice(table.id, text), children: say('keepEditing') })] }));
|
|
210
|
+
return (_jsxs("div", { className: `live-notice${place === 'anchored' ? ' is-anchored' : ''}${reviewing ? ' is-reviewing' : ''}`, role: "status", children: [_jsx("span", { className: "live-notice-text", title: sentence, children: sentence }), notice.kind === 'update' && (_jsx("button", { type: "button", className: `ghost${place === 'anchored' ? ' live-act' : ''}`, "aria-expanded": reviewing, onClick: () => setReviewing((on) => !on), children: say('review') })), _jsx("button", { type: "button", className: `ghost${place === 'anchored' ? ' live-act' : ''}`, onClick: () => dismissEditNotice(table.id, text), children: say('keepEditing') }), reviewing && notice.kind === 'update' && _jsx(Review, { table: table, recordKey: recordKey })] }));
|
|
211
|
+
}
|