@cratis/components 4.23.1 → 4.25.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/compat-manifest.json +11 -11
- package/dist/esm/Common/CratisComponentsProvider.d.ts +2 -0
- package/dist/esm/Common/CratisComponentsProvider.d.ts.map +1 -1
- package/dist/esm/Common/CratisComponentsProvider.js.map +1 -1
- package/dist/esm/ConfigurationEditor/ConfigurationDestination.d.ts +13 -0
- package/dist/esm/ConfigurationEditor/ConfigurationDestination.d.ts.map +1 -0
- package/dist/esm/ConfigurationEditor/ConfigurationDestination.js +4 -0
- package/dist/esm/ConfigurationEditor/ConfigurationDestination.js.map +1 -0
- package/dist/esm/ConfigurationEditor/ConfigurationEditor.d.ts +27 -0
- package/dist/esm/ConfigurationEditor/ConfigurationEditor.d.ts.map +1 -0
- package/dist/esm/ConfigurationEditor/ConfigurationEditor.js +13 -0
- package/dist/esm/ConfigurationEditor/ConfigurationEditor.js.map +1 -0
- package/dist/esm/ConfigurationEditor/ConfigurationEditorPartAttributes.d.ts +6 -0
- package/dist/esm/ConfigurationEditor/ConfigurationEditorPartAttributes.d.ts.map +1 -0
- package/dist/esm/ConfigurationEditor/ConfigurationEditorPartAttributes.js +4 -0
- package/dist/esm/ConfigurationEditor/ConfigurationEditorPartAttributes.js.map +1 -0
- package/dist/esm/ConfigurationEditor/ConfigurationEditorProvider.d.ts +28 -0
- package/dist/esm/ConfigurationEditor/ConfigurationEditorProvider.d.ts.map +1 -0
- package/dist/esm/ConfigurationEditor/ConfigurationEditorProvider.js +16 -0
- package/dist/esm/ConfigurationEditor/ConfigurationEditorProvider.js.map +1 -0
- package/dist/esm/ConfigurationEditor/ConfigurationEditorRenderProps.d.ts +20 -0
- package/dist/esm/ConfigurationEditor/ConfigurationEditorRenderProps.d.ts.map +1 -0
- package/dist/esm/ConfigurationEditor/ConfigurationEditorRenderProps.js +4 -0
- package/dist/esm/ConfigurationEditor/ConfigurationEditorRenderProps.js.map +1 -0
- package/dist/esm/ConfigurationEditor/ConfigurationEditorRenderer.d.ts +5 -0
- package/dist/esm/ConfigurationEditor/ConfigurationEditorRenderer.d.ts.map +1 -0
- package/dist/esm/ConfigurationEditor/ConfigurationEditorRenderer.js +4 -0
- package/dist/esm/ConfigurationEditor/ConfigurationEditorRenderer.js.map +1 -0
- package/dist/esm/ConfigurationEditor/ConfigurationIconReference.d.ts +17 -0
- package/dist/esm/ConfigurationEditor/ConfigurationIconReference.d.ts.map +1 -0
- package/dist/esm/ConfigurationEditor/ConfigurationIconReference.js +4 -0
- package/dist/esm/ConfigurationEditor/ConfigurationIconReference.js.map +1 -0
- package/dist/esm/ConfigurationEditor/OrderedItem.d.ts +16 -0
- package/dist/esm/ConfigurationEditor/OrderedItem.d.ts.map +1 -0
- package/dist/esm/ConfigurationEditor/OrderedItem.js +4 -0
- package/dist/esm/ConfigurationEditor/OrderedItem.js.map +1 -0
- package/dist/esm/ConfigurationEditor/OrderedItemCapabilities.d.ts +23 -0
- package/dist/esm/ConfigurationEditor/OrderedItemCapabilities.d.ts.map +1 -0
- package/dist/esm/ConfigurationEditor/OrderedItemCapabilities.js +4 -0
- package/dist/esm/ConfigurationEditor/OrderedItemCapabilities.js.map +1 -0
- package/dist/esm/ConfigurationEditor/OrderedItemDestinationField.d.ts +22 -0
- package/dist/esm/ConfigurationEditor/OrderedItemDestinationField.d.ts.map +1 -0
- package/dist/esm/ConfigurationEditor/OrderedItemDestinationField.js +23 -0
- package/dist/esm/ConfigurationEditor/OrderedItemDestinationField.js.map +1 -0
- package/dist/esm/ConfigurationEditor/OrderedItemEditor.d.ts +74 -0
- package/dist/esm/ConfigurationEditor/OrderedItemEditor.d.ts.map +1 -0
- package/dist/esm/ConfigurationEditor/OrderedItemEditor.js +188 -0
- package/dist/esm/ConfigurationEditor/OrderedItemEditor.js.map +1 -0
- package/dist/esm/ConfigurationEditor/OrderedItemEditorParts.d.ts +43 -0
- package/dist/esm/ConfigurationEditor/OrderedItemEditorParts.d.ts.map +1 -0
- package/dist/esm/ConfigurationEditor/OrderedItemEditorParts.js +4 -0
- package/dist/esm/ConfigurationEditor/OrderedItemEditorParts.js.map +1 -0
- package/dist/esm/ConfigurationEditor/OrderedItemField.d.ts +3 -0
- package/dist/esm/ConfigurationEditor/OrderedItemField.d.ts.map +1 -0
- package/dist/esm/ConfigurationEditor/OrderedItemField.js +4 -0
- package/dist/esm/ConfigurationEditor/OrderedItemField.js.map +1 -0
- package/dist/esm/ConfigurationEditor/OrderedItemFieldAccess.d.ts +9 -0
- package/dist/esm/ConfigurationEditor/OrderedItemFieldAccess.d.ts.map +1 -0
- package/dist/esm/ConfigurationEditor/OrderedItemFieldAccess.js +4 -0
- package/dist/esm/ConfigurationEditor/OrderedItemFieldAccess.js.map +1 -0
- package/dist/esm/ConfigurationEditor/OrderedItemIconField.d.ts +32 -0
- package/dist/esm/ConfigurationEditor/OrderedItemIconField.d.ts.map +1 -0
- package/dist/esm/ConfigurationEditor/OrderedItemIconField.js +26 -0
- package/dist/esm/ConfigurationEditor/OrderedItemIconField.js.map +1 -0
- package/dist/esm/ConfigurationEditor/OrderedItemIconFieldProps.d.ts +26 -0
- package/dist/esm/ConfigurationEditor/OrderedItemIconFieldProps.d.ts.map +1 -0
- package/dist/esm/ConfigurationEditor/OrderedItemIconFieldProps.js +4 -0
- package/dist/esm/ConfigurationEditor/OrderedItemIconFieldProps.js.map +1 -0
- package/dist/esm/ConfigurationEditor/OrderedItemLabels.d.ts +47 -0
- package/dist/esm/ConfigurationEditor/OrderedItemLabels.d.ts.map +1 -0
- package/dist/esm/ConfigurationEditor/OrderedItemLabels.js +4 -0
- package/dist/esm/ConfigurationEditor/OrderedItemLabels.js.map +1 -0
- package/dist/esm/ConfigurationEditor/OrderedItemOperation.d.ts +3 -0
- package/dist/esm/ConfigurationEditor/OrderedItemOperation.d.ts.map +1 -0
- package/dist/esm/ConfigurationEditor/OrderedItemOperation.js +4 -0
- package/dist/esm/ConfigurationEditor/OrderedItemOperation.js.map +1 -0
- package/dist/esm/ConfigurationEditor/OrderedItemProposal.d.ts +45 -0
- package/dist/esm/ConfigurationEditor/OrderedItemProposal.d.ts.map +1 -0
- package/dist/esm/ConfigurationEditor/OrderedItemProposal.js +4 -0
- package/dist/esm/ConfigurationEditor/OrderedItemProposal.js.map +1 -0
- package/dist/esm/ConfigurationEditor/OrderedItemRow.d.ts +5 -0
- package/dist/esm/ConfigurationEditor/OrderedItemRow.d.ts.map +1 -0
- package/dist/esm/ConfigurationEditor/OrderedItemRow.js +59 -0
- package/dist/esm/ConfigurationEditor/OrderedItemRow.js.map +1 -0
- package/dist/esm/ConfigurationEditor/OrderedItemRowProps.d.ts +43 -0
- package/dist/esm/ConfigurationEditor/OrderedItemRowProps.d.ts.map +1 -0
- package/dist/esm/ConfigurationEditor/OrderedItemRowProps.js +4 -0
- package/dist/esm/ConfigurationEditor/OrderedItemRowProps.js.map +1 -0
- package/dist/esm/ConfigurationEditor/OrderedItemValidation.d.ts +7 -0
- package/dist/esm/ConfigurationEditor/OrderedItemValidation.d.ts.map +1 -0
- package/dist/esm/ConfigurationEditor/OrderedItemValidation.js +4 -0
- package/dist/esm/ConfigurationEditor/OrderedItemValidation.js.map +1 -0
- package/dist/esm/ConfigurationEditor/PropertyChangeProposal.d.ts +15 -0
- package/dist/esm/ConfigurationEditor/PropertyChangeProposal.d.ts.map +1 -0
- package/dist/esm/ConfigurationEditor/PropertyChangeProposal.js +4 -0
- package/dist/esm/ConfigurationEditor/PropertyChangeProposal.js.map +1 -0
- package/dist/esm/ConfigurationEditor/PropertyChoice.d.ts +8 -0
- package/dist/esm/ConfigurationEditor/PropertyChoice.d.ts.map +1 -0
- package/dist/esm/ConfigurationEditor/PropertyChoice.js +4 -0
- package/dist/esm/ConfigurationEditor/PropertyChoice.js.map +1 -0
- package/dist/esm/ConfigurationEditor/PropertyControl.d.ts +17 -0
- package/dist/esm/ConfigurationEditor/PropertyControl.d.ts.map +1 -0
- package/dist/esm/ConfigurationEditor/PropertyControl.js +88 -0
- package/dist/esm/ConfigurationEditor/PropertyControl.js.map +1 -0
- package/dist/esm/ConfigurationEditor/PropertyControls.d.ts +40 -0
- package/dist/esm/ConfigurationEditor/PropertyControls.d.ts.map +1 -0
- package/dist/esm/ConfigurationEditor/PropertyControls.js +41 -0
- package/dist/esm/ConfigurationEditor/PropertyControls.js.map +1 -0
- package/dist/esm/ConfigurationEditor/PropertyControlsLabels.d.ts +18 -0
- package/dist/esm/ConfigurationEditor/PropertyControlsLabels.d.ts.map +1 -0
- package/dist/esm/ConfigurationEditor/PropertyControlsLabels.js +4 -0
- package/dist/esm/ConfigurationEditor/PropertyControlsLabels.js.map +1 -0
- package/dist/esm/ConfigurationEditor/PropertyControlsParts.d.ts +31 -0
- package/dist/esm/ConfigurationEditor/PropertyControlsParts.d.ts.map +1 -0
- package/dist/esm/ConfigurationEditor/PropertyControlsParts.js +4 -0
- package/dist/esm/ConfigurationEditor/PropertyControlsParts.js.map +1 -0
- package/dist/esm/ConfigurationEditor/PropertyDescriptor.d.ts +55 -0
- package/dist/esm/ConfigurationEditor/PropertyDescriptor.d.ts.map +1 -0
- package/dist/esm/ConfigurationEditor/PropertyDescriptor.js +4 -0
- package/dist/esm/ConfigurationEditor/PropertyDescriptor.js.map +1 -0
- package/dist/esm/ConfigurationEditor/PropertyGroup.d.ts +16 -0
- package/dist/esm/ConfigurationEditor/PropertyGroup.d.ts.map +1 -0
- package/dist/esm/ConfigurationEditor/PropertyGroup.js +4 -0
- package/dist/esm/ConfigurationEditor/PropertyGroup.js.map +1 -0
- package/dist/esm/ConfigurationEditor/defaultOrderedItemLabels.d.ts +4 -0
- package/dist/esm/ConfigurationEditor/defaultOrderedItemLabels.d.ts.map +1 -0
- package/dist/esm/ConfigurationEditor/defaultOrderedItemLabels.js +25 -0
- package/dist/esm/ConfigurationEditor/defaultOrderedItemLabels.js.map +1 -0
- package/dist/esm/ConfigurationEditor/defaultPropertyControlsLabels.d.ts +4 -0
- package/dist/esm/ConfigurationEditor/defaultPropertyControlsLabels.d.ts.map +1 -0
- package/dist/esm/ConfigurationEditor/defaultPropertyControlsLabels.js +12 -0
- package/dist/esm/ConfigurationEditor/defaultPropertyControlsLabels.js.map +1 -0
- package/dist/esm/ConfigurationEditor/index.d.ts +32 -0
- package/dist/esm/ConfigurationEditor/index.d.ts.map +1 -0
- package/dist/esm/ConfigurationEditor/index.js +7 -0
- package/dist/esm/ConfigurationEditor/index.js.map +1 -0
- package/dist/esm/ConfigurationEditor/moveOrderedItem.d.ts +5 -0
- package/dist/esm/ConfigurationEditor/moveOrderedItem.d.ts.map +1 -0
- package/dist/esm/ConfigurationEditor/moveOrderedItem.js +9 -0
- package/dist/esm/ConfigurationEditor/moveOrderedItem.js.map +1 -0
- package/dist/esm/ConfigurationEditor/resolveOrderedItemDropIndex.d.ts +10 -0
- package/dist/esm/ConfigurationEditor/resolveOrderedItemDropIndex.d.ts.map +1 -0
- package/dist/esm/ConfigurationEditor/resolveOrderedItemDropIndex.js +7 -0
- package/dist/esm/ConfigurationEditor/resolveOrderedItemDropIndex.js.map +1 -0
- package/dist/esm/ConfigurationEditor/resolveOrderedItemFieldAccess.d.ts +6 -0
- package/dist/esm/ConfigurationEditor/resolveOrderedItemFieldAccess.d.ts.map +1 -0
- package/dist/esm/ConfigurationEditor/resolveOrderedItemFieldAccess.js +4 -0
- package/dist/esm/ConfigurationEditor/resolveOrderedItemFieldAccess.js.map +1 -0
- package/dist/esm/ConfigurationEditor/resolveOrderedItemLabels.d.ts +4 -0
- package/dist/esm/ConfigurationEditor/resolveOrderedItemLabels.d.ts.map +1 -0
- package/dist/esm/ConfigurationEditor/resolveOrderedItemLabels.js +13 -0
- package/dist/esm/ConfigurationEditor/resolveOrderedItemLabels.js.map +1 -0
- package/dist/esm/ConfigurationEditor/validateOrderedItem.d.ts +18 -0
- package/dist/esm/ConfigurationEditor/validateOrderedItem.d.ts.map +1 -0
- package/dist/esm/ConfigurationEditor/validateOrderedItem.js +21 -0
- package/dist/esm/ConfigurationEditor/validateOrderedItem.js.map +1 -0
- package/dist/esm/IconPicker/IconPicker.d.ts +57 -0
- package/dist/esm/IconPicker/IconPicker.d.ts.map +1 -0
- package/dist/esm/IconPicker/IconPicker.js +59 -0
- package/dist/esm/IconPicker/IconPicker.js.map +1 -0
- package/dist/esm/IconPicker/IconPickerAllowed.d.ts +8 -0
- package/dist/esm/IconPicker/IconPickerAllowed.d.ts.map +1 -0
- package/dist/esm/IconPicker/IconPickerAllowed.js +4 -0
- package/dist/esm/IconPicker/IconPickerAllowed.js.map +1 -0
- package/dist/esm/IconPicker/IconPickerBrowser.d.ts +32 -0
- package/dist/esm/IconPicker/IconPickerBrowser.d.ts.map +1 -0
- package/dist/esm/IconPicker/IconPickerBrowser.js +4 -0
- package/dist/esm/IconPicker/IconPickerBrowser.js.map +1 -0
- package/dist/esm/IconPicker/IconPickerBrowserGroup.d.ts +9 -0
- package/dist/esm/IconPicker/IconPickerBrowserGroup.d.ts.map +1 -0
- package/dist/esm/IconPicker/IconPickerBrowserGroup.js +4 -0
- package/dist/esm/IconPicker/IconPickerBrowserGroup.js.map +1 -0
- package/dist/esm/IconPicker/IconPickerCatalog.d.ts +19 -0
- package/dist/esm/IconPicker/IconPickerCatalog.d.ts.map +1 -0
- package/dist/esm/IconPicker/IconPickerCatalog.js +4 -0
- package/dist/esm/IconPicker/IconPickerCatalog.js.map +1 -0
- package/dist/esm/IconPicker/IconPickerCatalogStatus.d.ts +3 -0
- package/dist/esm/IconPicker/IconPickerCatalogStatus.d.ts.map +1 -0
- package/dist/esm/IconPicker/IconPickerCatalogStatus.js +4 -0
- package/dist/esm/IconPicker/IconPickerCatalogStatus.js.map +1 -0
- package/dist/esm/IconPicker/IconPickerCategoryFilter.d.ts +25 -0
- package/dist/esm/IconPicker/IconPickerCategoryFilter.d.ts.map +1 -0
- package/dist/esm/IconPicker/IconPickerCategoryFilter.js +23 -0
- package/dist/esm/IconPicker/IconPickerCategoryFilter.js.map +1 -0
- package/dist/esm/IconPicker/IconPickerEntry.d.ts +25 -0
- package/dist/esm/IconPicker/IconPickerEntry.d.ts.map +1 -0
- package/dist/esm/IconPicker/IconPickerEntry.js +4 -0
- package/dist/esm/IconPicker/IconPickerEntry.js.map +1 -0
- package/dist/esm/IconPicker/IconPickerGrid.d.ts +29 -0
- package/dist/esm/IconPicker/IconPickerGrid.d.ts.map +1 -0
- package/dist/esm/IconPicker/IconPickerGrid.js +24 -0
- package/dist/esm/IconPicker/IconPickerGrid.js.map +1 -0
- package/dist/esm/IconPicker/IconPickerIndexEntry.d.ts +11 -0
- package/dist/esm/IconPicker/IconPickerIndexEntry.d.ts.map +1 -0
- package/dist/esm/IconPicker/IconPickerIndexEntry.js +4 -0
- package/dist/esm/IconPicker/IconPickerIndexEntry.js.map +1 -0
- package/dist/esm/IconPicker/IconPickerLabels.d.ts +76 -0
- package/dist/esm/IconPicker/IconPickerLabels.d.ts.map +1 -0
- package/dist/esm/IconPicker/IconPickerLabels.js +4 -0
- package/dist/esm/IconPicker/IconPickerLabels.js.map +1 -0
- package/dist/esm/IconPicker/IconPickerLibrary.d.ts +12 -0
- package/dist/esm/IconPicker/IconPickerLibrary.d.ts.map +1 -0
- package/dist/esm/IconPicker/IconPickerLibrary.js +4 -0
- package/dist/esm/IconPicker/IconPickerLibrary.js.map +1 -0
- package/dist/esm/IconPicker/IconPickerLibraryFilter.d.ts +20 -0
- package/dist/esm/IconPicker/IconPickerLibraryFilter.d.ts.map +1 -0
- package/dist/esm/IconPicker/IconPickerLibraryFilter.js +7 -0
- package/dist/esm/IconPicker/IconPickerLibraryFilter.js.map +1 -0
- package/dist/esm/IconPicker/IconPickerParts.d.ts +65 -0
- package/dist/esm/IconPicker/IconPickerParts.d.ts.map +1 -0
- package/dist/esm/IconPicker/IconPickerParts.js +4 -0
- package/dist/esm/IconPicker/IconPickerParts.js.map +1 -0
- package/dist/esm/IconPicker/IconPickerPlacement.d.ts +3 -0
- package/dist/esm/IconPicker/IconPickerPlacement.d.ts.map +1 -0
- package/dist/esm/IconPicker/IconPickerPlacement.js +4 -0
- package/dist/esm/IconPicker/IconPickerPlacement.js.map +1 -0
- package/dist/esm/IconPicker/IconPickerPopout.d.ts +32 -0
- package/dist/esm/IconPicker/IconPickerPopout.d.ts.map +1 -0
- package/dist/esm/IconPicker/IconPickerPopout.js +41 -0
- package/dist/esm/IconPicker/IconPickerPopout.js.map +1 -0
- package/dist/esm/IconPicker/IconPickerResults.d.ts +31 -0
- package/dist/esm/IconPicker/IconPickerResults.d.ts.map +1 -0
- package/dist/esm/IconPicker/IconPickerResults.js +21 -0
- package/dist/esm/IconPicker/IconPickerResults.js.map +1 -0
- package/dist/esm/IconPicker/IconPickerSearch.d.ts +21 -0
- package/dist/esm/IconPicker/IconPickerSearch.d.ts.map +1 -0
- package/dist/esm/IconPicker/IconPickerSearch.js +21 -0
- package/dist/esm/IconPicker/IconPickerSearch.js.map +1 -0
- package/dist/esm/IconPicker/IconPickerSummary.d.ts +12 -0
- package/dist/esm/IconPicker/IconPickerSummary.d.ts.map +1 -0
- package/dist/esm/IconPicker/IconPickerSummary.js +4 -0
- package/dist/esm/IconPicker/IconPickerSummary.js.map +1 -0
- package/dist/esm/IconPicker/IconPickerTile.d.ts +36 -0
- package/dist/esm/IconPicker/IconPickerTile.d.ts.map +1 -0
- package/dist/esm/IconPicker/IconPickerTile.js +22 -0
- package/dist/esm/IconPicker/IconPickerTile.js.map +1 -0
- package/dist/esm/IconPicker/IconPickerTrigger.d.ts +39 -0
- package/dist/esm/IconPicker/IconPickerTrigger.d.ts.map +1 -0
- package/dist/esm/IconPicker/IconPickerTrigger.js +13 -0
- package/dist/esm/IconPicker/IconPickerTrigger.js.map +1 -0
- package/dist/esm/IconPicker/IconPickerValue.d.ts +16 -0
- package/dist/esm/IconPicker/IconPickerValue.d.ts.map +1 -0
- package/dist/esm/IconPicker/IconPickerValue.js +4 -0
- package/dist/esm/IconPicker/IconPickerValue.js.map +1 -0
- package/dist/esm/IconPicker/createIconPickerIndex.d.ts +10 -0
- package/dist/esm/IconPicker/createIconPickerIndex.d.ts.map +1 -0
- package/dist/esm/IconPicker/createIconPickerIndex.js +21 -0
- package/dist/esm/IconPicker/createIconPickerIndex.js.map +1 -0
- package/dist/esm/IconPicker/defaultIconPickerLabels.d.ts +4 -0
- package/dist/esm/IconPicker/defaultIconPickerLabels.d.ts.map +1 -0
- package/dist/esm/IconPicker/defaultIconPickerLabels.js +35 -0
- package/dist/esm/IconPicker/defaultIconPickerLabels.js.map +1 -0
- package/dist/esm/IconPicker/formatIconPickerIdentity.d.ts +8 -0
- package/dist/esm/IconPicker/formatIconPickerIdentity.d.ts.map +1 -0
- package/dist/esm/IconPicker/formatIconPickerIdentity.js +4 -0
- package/dist/esm/IconPicker/formatIconPickerIdentity.js.map +1 -0
- package/dist/esm/IconPicker/groupIconPickerByCategory.d.ts +10 -0
- package/dist/esm/IconPicker/groupIconPickerByCategory.d.ts.map +1 -0
- package/dist/esm/IconPicker/groupIconPickerByCategory.js +17 -0
- package/dist/esm/IconPicker/groupIconPickerByCategory.js.map +1 -0
- package/dist/esm/IconPicker/iconPickerIdentity.d.ts +8 -0
- package/dist/esm/IconPicker/iconPickerIdentity.d.ts.map +1 -0
- package/dist/esm/IconPicker/iconPickerIdentity.js +4 -0
- package/dist/esm/IconPicker/iconPickerIdentity.js.map +1 -0
- package/dist/esm/IconPicker/index.d.ts +19 -0
- package/dist/esm/IconPicker/index.d.ts.map +1 -0
- package/dist/esm/IconPicker/index.js +8 -0
- package/dist/esm/IconPicker/index.js.map +1 -0
- package/dist/esm/IconPicker/isIconPickerAllowed.d.ts +10 -0
- package/dist/esm/IconPicker/isIconPickerAllowed.d.ts.map +1 -0
- package/dist/esm/IconPicker/isIconPickerAllowed.js +12 -0
- package/dist/esm/IconPicker/isIconPickerAllowed.js.map +1 -0
- package/dist/esm/IconPicker/isSameIconPickerValue.d.ts +10 -0
- package/dist/esm/IconPicker/isSameIconPickerValue.d.ts.map +1 -0
- package/dist/esm/IconPicker/isSameIconPickerValue.js +4 -0
- package/dist/esm/IconPicker/isSameIconPickerValue.js.map +1 -0
- package/dist/esm/IconPicker/searchIconPickerIndex.d.ts +9 -0
- package/dist/esm/IconPicker/searchIconPickerIndex.d.ts.map +1 -0
- package/dist/esm/IconPicker/searchIconPickerIndex.js +9 -0
- package/dist/esm/IconPicker/searchIconPickerIndex.js.map +1 -0
- package/dist/esm/IconPicker/toIconPickerValue.d.ts +9 -0
- package/dist/esm/IconPicker/toIconPickerValue.d.ts.map +1 -0
- package/dist/esm/IconPicker/toIconPickerValue.js +6 -0
- package/dist/esm/IconPicker/toIconPickerValue.js.map +1 -0
- package/dist/esm/IconPicker/useGridColumns.d.ts +12 -0
- package/dist/esm/IconPicker/useGridColumns.d.ts.map +1 -0
- package/dist/esm/IconPicker/useGridColumns.js +26 -0
- package/dist/esm/IconPicker/useGridColumns.js.map +1 -0
- package/dist/esm/IconPicker/useIconPickerBrowser.d.ts +10 -0
- package/dist/esm/IconPicker/useIconPickerBrowser.d.ts.map +1 -0
- package/dist/esm/IconPicker/useIconPickerBrowser.js +45 -0
- package/dist/esm/IconPicker/useIconPickerBrowser.js.map +1 -0
- package/dist/esm/IconPicker/useIsVisible.d.ts +12 -0
- package/dist/esm/IconPicker/useIsVisible.d.ts.map +1 -0
- package/dist/esm/IconPicker/useIsVisible.js +23 -0
- package/dist/esm/IconPicker/useIsVisible.js.map +1 -0
- package/dist/esm/IconPicker/useNarrowViewport.d.ts +9 -0
- package/dist/esm/IconPicker/useNarrowViewport.d.ts.map +1 -0
- package/dist/esm/IconPicker/useNarrowViewport.js +15 -0
- package/dist/esm/IconPicker/useNarrowViewport.js.map +1 -0
- package/dist/esm/IconPicker/useRovingFocus.d.ts +29 -0
- package/dist/esm/IconPicker/useRovingFocus.d.ts.map +1 -0
- package/dist/esm/IconPicker/useRovingFocus.js +70 -0
- package/dist/esm/IconPicker/useRovingFocus.js.map +1 -0
- package/dist/esm/Toolbar/ToolbarButton.d.ts +4 -1
- package/dist/esm/Toolbar/ToolbarButton.d.ts.map +1 -1
- package/dist/esm/Toolbar/ToolbarButton.js +12 -2
- package/dist/esm/Toolbar/ToolbarButton.js.map +1 -1
- package/dist/esm/Toolbar/ToolbarDrawerContext.d.ts +13 -0
- package/dist/esm/Toolbar/ToolbarDrawerContext.d.ts.map +1 -0
- package/dist/esm/Toolbar/ToolbarDrawerContext.js +7 -0
- package/dist/esm/Toolbar/ToolbarDrawerContext.js.map +1 -0
- package/dist/esm/Toolbar/ToolbarDrawerItem.d.ts +23 -0
- package/dist/esm/Toolbar/ToolbarDrawerItem.d.ts.map +1 -0
- package/dist/esm/Toolbar/ToolbarDrawerItem.js +4 -0
- package/dist/esm/Toolbar/ToolbarDrawerItem.js.map +1 -0
- package/dist/esm/Toolbar/ToolbarDrawerPlacement.d.ts +57 -0
- package/dist/esm/Toolbar/ToolbarDrawerPlacement.d.ts.map +1 -0
- package/dist/esm/Toolbar/ToolbarDrawerPlacement.js +51 -0
- package/dist/esm/Toolbar/ToolbarDrawerPlacement.js.map +1 -0
- package/dist/esm/Toolbar/ToolbarDrawerTile.d.ts +43 -0
- package/dist/esm/Toolbar/ToolbarDrawerTile.d.ts.map +1 -0
- package/dist/esm/Toolbar/ToolbarDrawerTile.js +31 -0
- package/dist/esm/Toolbar/ToolbarDrawerTile.js.map +1 -0
- package/dist/esm/Toolbar/ToolbarFolder.d.ts +51 -5
- package/dist/esm/Toolbar/ToolbarFolder.d.ts.map +1 -1
- package/dist/esm/Toolbar/ToolbarFolder.js +109 -10
- package/dist/esm/Toolbar/ToolbarFolder.js.map +1 -1
- package/dist/esm/Toolbar/ToolbarFolderPresentation.d.ts +8 -0
- package/dist/esm/Toolbar/ToolbarFolderPresentation.d.ts.map +1 -0
- package/dist/esm/Toolbar/ToolbarFolderPresentation.js +4 -0
- package/dist/esm/Toolbar/ToolbarFolderPresentation.js.map +1 -0
- package/dist/esm/Toolbar/index.d.ts +2 -0
- package/dist/esm/Toolbar/index.d.ts.map +1 -1
- package/dist/esm/configuration/CratisComponentsDefaults.d.ts.map +1 -1
- package/dist/esm/configuration/CratisComponentsDefaults.js +1 -0
- package/dist/esm/configuration/CratisComponentsDefaults.js.map +1 -1
- package/dist/esm/styles.ConfigurationEditor.css +710 -0
- package/dist/esm/styles.IconPicker.css +464 -0
- package/dist/esm/styles.Toolbar.css +174 -0
- package/dist/esm/styles.css +971 -90
- package/dist/esm/types/parts.d.ts +69 -1
- package/dist/esm/types/parts.d.ts.map +1 -1
- package/dist/esm/types/parts.js +69 -1
- package/dist/esm/types/parts.js.map +1 -1
- package/package.json +11 -1
package/compat-manifest.json
CHANGED
|
@@ -68,7 +68,7 @@
|
|
|
68
68
|
{
|
|
69
69
|
"name": "@cratis/components",
|
|
70
70
|
"role": "core",
|
|
71
|
-
"version": "4.
|
|
71
|
+
"version": "4.25.0",
|
|
72
72
|
"releaseMajorRange": ">=4 <5",
|
|
73
73
|
"independentRelease": false,
|
|
74
74
|
"private": false,
|
|
@@ -92,7 +92,7 @@
|
|
|
92
92
|
{
|
|
93
93
|
"name": "@cratis/eslint-plugin-components",
|
|
94
94
|
"role": "eslint",
|
|
95
|
-
"version": "4.
|
|
95
|
+
"version": "4.25.0",
|
|
96
96
|
"releaseMajorRange": ">=4 <5",
|
|
97
97
|
"independentRelease": false,
|
|
98
98
|
"private": false,
|
|
@@ -105,7 +105,7 @@
|
|
|
105
105
|
{
|
|
106
106
|
"name": "@cratis/components.migrator",
|
|
107
107
|
"role": "migrator",
|
|
108
|
-
"version": "4.
|
|
108
|
+
"version": "4.25.0",
|
|
109
109
|
"releaseMajorRange": ">=4 <5",
|
|
110
110
|
"independentRelease": false,
|
|
111
111
|
"private": false,
|
|
@@ -116,13 +116,13 @@
|
|
|
116
116
|
{
|
|
117
117
|
"name": "@cratis/components.conformance",
|
|
118
118
|
"role": "conformance",
|
|
119
|
-
"version": "4.
|
|
119
|
+
"version": "4.25.0",
|
|
120
120
|
"releaseMajorRange": ">=4 <5",
|
|
121
121
|
"independentRelease": false,
|
|
122
122
|
"private": false,
|
|
123
123
|
"packageAccess": "public",
|
|
124
124
|
"peerDependencies": {
|
|
125
|
-
"@cratis/components": "4.
|
|
125
|
+
"@cratis/components": "4.25.0",
|
|
126
126
|
"react": "^19.0.0",
|
|
127
127
|
"react-dom": "^19.0.0"
|
|
128
128
|
},
|
|
@@ -132,13 +132,13 @@
|
|
|
132
132
|
{
|
|
133
133
|
"name": "@cratis/components.mui",
|
|
134
134
|
"role": "renderer-adapter",
|
|
135
|
-
"version": "4.
|
|
135
|
+
"version": "4.25.0",
|
|
136
136
|
"releaseMajorRange": ">=4 <5",
|
|
137
137
|
"independentRelease": false,
|
|
138
138
|
"private": false,
|
|
139
139
|
"packageAccess": "public",
|
|
140
140
|
"peerDependencies": {
|
|
141
|
-
"@cratis/components": "4.
|
|
141
|
+
"@cratis/components": "4.25.0",
|
|
142
142
|
"@emotion/react": ">=11.5 <12",
|
|
143
143
|
"@emotion/styled": ">=11.11 <12",
|
|
144
144
|
"@mui/material": ">=9 <10",
|
|
@@ -188,13 +188,13 @@
|
|
|
188
188
|
{
|
|
189
189
|
"name": "@cratis/components.primereact",
|
|
190
190
|
"role": "renderer-adapter",
|
|
191
|
-
"version": "4.
|
|
191
|
+
"version": "4.25.0",
|
|
192
192
|
"releaseMajorRange": ">=4 <5",
|
|
193
193
|
"independentRelease": false,
|
|
194
194
|
"private": false,
|
|
195
195
|
"packageAccess": "public",
|
|
196
196
|
"peerDependencies": {
|
|
197
|
-
"@cratis/components": "4.
|
|
197
|
+
"@cratis/components": "4.25.0",
|
|
198
198
|
"@primereact/core": ">=11 <12",
|
|
199
199
|
"@primereact/ui": ">=11 <12",
|
|
200
200
|
"@primeuix/themes": ">=3 <4",
|
|
@@ -256,13 +256,13 @@
|
|
|
256
256
|
{
|
|
257
257
|
"name": "@cratis/components.primereact10",
|
|
258
258
|
"role": "renderer-adapter",
|
|
259
|
-
"version": "4.
|
|
259
|
+
"version": "4.25.0",
|
|
260
260
|
"releaseMajorRange": ">=4 <5",
|
|
261
261
|
"independentRelease": false,
|
|
262
262
|
"private": false,
|
|
263
263
|
"packageAccess": "public",
|
|
264
264
|
"peerDependencies": {
|
|
265
|
-
"@cratis/components": "4.
|
|
265
|
+
"@cratis/components": "4.25.0",
|
|
266
266
|
"primereact": ">=10.9.9 <11",
|
|
267
267
|
"react": "^19.0.0",
|
|
268
268
|
"react-dom": "^19.0.0"
|
|
@@ -126,6 +126,8 @@ export interface CratisColumnFilterMessages {
|
|
|
126
126
|
export interface CratisToolbarMessages {
|
|
127
127
|
/** Accessible toolbar name used when neither `aria-label` nor `aria-labelledby` is supplied. */
|
|
128
128
|
label?: string;
|
|
129
|
+
/** Accessible name of the close button in a drawer {@link ToolbarFolder}. Defaults to 'Close'. */
|
|
130
|
+
closeDrawer?: string;
|
|
129
131
|
}
|
|
130
132
|
/** Components-owned message groups. */
|
|
131
133
|
export interface CratisComponentsMessages {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CratisComponentsProvider.d.ts","sourceRoot":"","sources":["../../../Common/CratisComponentsProvider.tsx"],"names":[],"mappings":"AAGA,OAAO,EAAW,KAAK,SAAS,EAAE,MAAM,OAAO,CAAC;AAGhD,OAAO,EAAW,KAAK,YAAY,EAAE,MAAM,6BAA0B,CAAC;AAEtE,OAAO,KAAK,EAAE,mBAAmB,EAAE,kBAAkB,EAAE,MAAM,yBAAsB,CAAC;AACpF,OAAO,KAAK,EAAE,wBAAwB,EAAE,MAAM,mCAAgC,CAAC;AAM/E,OAAO,EAAE,cAAc,EAAE,MAAM,8CAA2C,CAAC;AAC3E,OAAO,EAAE,yBAAyB,EAAE,MAAM,6CAA0C,CAAC;AAErF,wDAAwD;AACxD,MAAM,WAAW,uBAAuB;IACpC,yCAAyC;IACzC,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,+BAA+B;IAC/B,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,kCAAkC;IAClC,QAAQ,C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AAC,EAAE,MAAM,CAAC;
|
|
1
|
+
{"version":3,"file":"CratisComponentsProvider.d.ts","sourceRoot":"","sources":["../../../Common/CratisComponentsProvider.tsx"],"names":[],"mappings":"AAGA,OAAO,EAAW,KAAK,SAAS,EAAE,MAAM,OAAO,CAAC;AAGhD,OAAO,EAAW,KAAK,YAAY,EAAE,MAAM,6BAA0B,CAAC;AAEtE,OAAO,KAAK,EAAE,mBAAmB,EAAE,kBAAkB,EAAE,MAAM,yBAAsB,CAAC;AACpF,OAAO,KAAK,EAAE,wBAAwB,EAAE,MAAM,mCAAgC,CAAC;AAM/E,OAAO,EAAE,cAAc,EAAE,MAAM,8CAA2C,CAAC;AAC3E,OAAO,EAAE,yBAAyB,EAAE,MAAM,6CAA0C,CAAC;AAErF,wDAAwD;AACxD,MAAM,WAAW,uBAAuB;IACpC,yCAAyC;IACzC,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,+BAA+B;IAC/B,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,kCAAkC;IAClC,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,8BAA8B;IAC9B,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,8BAA8B;IAC9B,IAAI,CAAC,EAAE,MAAM,CAAC;CACjB;AAED,sEAAsE;AACtE,MAAM,WAAW,wBAAwB;IACrC,0BAA0B;IAC1B,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,0BAA0B;IAC1B,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,8BAA8B;IAC9B,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,mCAAmC;IACnC,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,+BAA+B;IAC/B,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB;;;;OAIG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;CAClB;AAED,2EAA2E;AAC3E,MAAM,WAAW,sBAAsB;IACnC,uDAAuD;IACvD,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,sDAAsD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B;IAC1C,4CAA4C;IAC5C,KAAK,CAAC,EAAE,sBAAsB,CAAC;IAC/B,mEAAmE;IACnE,OAAO,CAAC,EAAE,OAAO,GAAG,YAAY,CAAC;IACjC;;;OAGG;IACH,OAAO,CAAC,EAAE,kBAAkB,GAAG,SAAS,kBAAkB,EAAE,CAAC;IAC7D,iEAAiE;IACjE,WAAW,CAAC,EAAE,QAAQ,GAAG,SAAS,CAAC;IACnC,qFAAqF;IACrF,gBAAgB,CAAC,EAAE,MAAM,GAAG,OAAO,CAAC;IACpC,sDAAsD;IACtD,kBAAkB,CAAC,EAAE,wBAAwB,CAAC;IAC9C;;;OAGG;IACH,aAAa,CAAC,EAAE,mBAAmB,CAAC;IACpC,2BAA2B;IAC3B,QAAQ,EAAE,SAAS,CAAC;CACvB;AAED;;;;;;GAMG;AACH,eAAO,MAAM,2BAA2B,UAC7B,sBAAsB,GAAG,SAAS,KAC1C,sBAIF,CAAC;AAmEF,8EAA8E;AAC9E,eAAO,MAAM,wBAAwB,6GASlC,6BAA6B,gCAyB/B,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CratisComponentsProvider.js","sources":["../../../Common/CratisComponentsProvider.tsx"],"sourcesContent":["// Copyright (c) Cratis. All rights reserved.\n// Licensed under the MIT license. See LICENSE file in the project root for full license information.\n\nimport { useMemo, type ReactNode } from 'react';\nimport { I18nProvider } from 'react-aria-components/I18nProvider';\nimport { merge } from 'ts-deepmerge';\nimport { Toaster, type ToasterProps } from '../Notifications/Toaster';\nimport { unstable_RendererRoot } from '../renderer/RendererContext';\nimport type { CratisRendererSetup, unstable_UiLibrary } from '../renderer/manifest';\nimport type { CratisOverlayEnvironment } from '../renderer/overlayEnvironment';\nimport { CratisComponentsContext } from '../configuration/CratisComponentsContext';\nimport { cratisDefaults } from '../configuration/CratisComponentsDefaults';\n\nconst RendererRoot = unstable_RendererRoot;\n\nexport { cratisDefaults } from '../configuration/CratisComponentsDefaults';\nexport { useCratisComponentsConfig } from '../configuration/CratisComponentsContext';\n\n/** Localizable labels owned by the Cratis paginator. */\nexport interface CratisPaginatorMessages {\n /** Pagination navigation-region name. */\n navigation?: string;\n /** First-page action label. */\n first?: string;\n /** Previous-page action label. */\n previous?: string;\n /** Next-page action label. */\n next?: string;\n /** Last-page action label. */\n last?: string;\n}\n\n/** Localizable labels owned by the Cratis date picker composition. */\nexport interface CratisDatePickerMessages {\n /** Today action label. */\n today?: string;\n /** Clear action label. */\n clear?: string;\n /** Calendar-trigger label. */\n openCalendar?: string;\n /** Previous-month action label. */\n previousMonth?: string;\n /** Next-month action label. */\n nextMonth?: string;\n /**\n * Accessible name for the segmented date input when neither an explicit\n * `aria-label` nor a `placeholder` is supplied. Previously an orphaned\n * `'Date'` literal with no override path.\n */\n label?: string;\n}\n\n/** Localizable labels owned by the Cratis {@link Dropdown} composition. */\nexport interface CratisDropdownMessages {\n /** Accessible name for the options-popover trigger. */\n showOptions?: string;\n /** Accessible name for the clear-selection action. */\n clearSelection?: string;\n}\n\n/**\n * Localizable action and dismissal labels shared by every Cratis-owned dialog\n * surface — {@link Dialog}, {@link CommandDialog}, and {@link StepperCommandDialog}.\n */\nexport interface CratisDialogMessages {\n /** Primary confirmation label (the `Ok` action in `DialogButtons.Ok*`). */\n ok?: string;\n /** Cancellation label (the `Cancel` action, and the Stepper footer Cancel). */\n cancel?: string;\n /** Affirmative label (the `Yes` action in `DialogButtons.YesNo*`). */\n yes?: string;\n /** Negative label (the `No` action in `DialogButtons.YesNo*`). */\n no?: string;\n /** Accessible name for the header close (×) action. */\n close?: string;\n}\n\n/** Localizable navigation labels owned by {@link CommandStepper} / {@link StepperCommandDialog}. */\nexport interface CratisStepperMessages {\n /** Advance-to-next-step action label. */\n next?: string;\n /** Return-to-previous-step action label. */\n previous?: string;\n /** Final-step submit action label. */\n submit?: string;\n}\n\n/** Localizable labels owned by the Cratis {@link Toaster}. */\nexport interface CratisNotificationsMessages {\n /** Accessible name for a toast's dismiss action. */\n dismiss?: string;\n /** Accessible name for the toast region landmark. */\n region?: string;\n}\n\n/** Localizable labels owned by the Cratis {@link DataTableCore} composition. */\nexport interface CratisDataTableMessages {\n /** Accessible name for a single-selection row control. */\n selectRow?: string;\n /** Accessible name for the select-all control in a multiple-selection header. */\n selectAllRows?: string;\n /** Placeholder for the loaded-page search input. */\n search?: string;\n /** Accessible name for the loaded-page search input. */\n searchAriaLabel?: string;\n /** Message shown while loading an empty table. */\n loading?: string;\n /** Message shown when a query fails. */\n failed?: string;\n /** Message shown when a query denies access. */\n unauthorized?: string;\n}\n\n/** Localizable accessible names for the Cratis filter panel and its searches. */\nexport interface CratisFilterMessages {\n /** FilterPanel dialog name. Defaults to 'Filters'. */\n label?: string;\n /**\n * Search-input name for FilterPanel, its option groups, and standalone CheckboxListFilter.\n * Unset by default so an effective search placeholder retains precedence over 'Search'.\n * PivotViewer supplies group-specific names instead of using this shared name for its groups.\n */\n searchAriaLabel?: string;\n}\n\n/** Localizable labels owned by the Cratis column-filter popup. */\nexport interface CratisColumnFilterMessages {\n /** Builds the filter-trigger accessible name from the effective field. */\n filterTriggerAriaLabel?: (field: string) => string;\n /** Builds the value-control accessible name from the effective field. */\n valueAriaLabel?: (field: string) => string;\n /** Accessible name for the match-mode selector. */\n matchModeAriaLabel?: string;\n /** Localizes a match mode while retaining its default label as fallback input. */\n matchModeLabel?: (mode: string, defaultLabel: string) => string;\n /** Clear action label. */\n clear?: string;\n /** Apply action label. */\n apply?: string;\n /** Boolean true option label. */\n true?: string;\n /** Boolean false option label. */\n false?: string;\n}\n\n/** Localizable labels owned by the Cratis {@link Toolbar} composition. */\nexport interface CratisToolbarMessages {\n /** Accessible toolbar name used when neither `aria-label` nor `aria-labelledby` is supplied. */\n label?: string;\n}\n\n/** Components-owned message groups. */\nexport interface CratisComponentsMessages {\n /** Paginator labels. */\n paginator?: CratisPaginatorMessages;\n /** Date-picker labels. */\n datePicker?: CratisDatePickerMessages;\n /** Dropdown labels. */\n dropdown?: CratisDropdownMessages;\n /** Dialog action/dismissal labels shared by Dialog, CommandDialog, and StepperCommandDialog. */\n dialog?: CratisDialogMessages;\n /** Stepper navigation labels shared by CommandStepper and StepperCommandDialog. */\n stepper?: CratisStepperMessages;\n /** Toaster labels. */\n notifications?: CratisNotificationsMessages;\n /** DataTable search, selection, and query-state messages. */\n dataTable?: CratisDataTableMessages;\n /** FilterPanel dialog and search-input accessible names. */\n filter?: CratisFilterMessages;\n /** Column-filter popup labels and match-mode copy. */\n columnFilter?: CratisColumnFilterMessages;\n /** Toolbar accessible-name fallback. */\n toolbar?: CratisToolbarMessages;\n}\n\n/**\n * Components-owned icon vocabulary. Every name is a concept the library draws in more than one\n * place; registering one replaces that concept's built-in glyph everywhere it is drawn, without\n * touching the surrounding element, its part, or its accessible name.\n *\n * Resolution per site is `per-component prop → provider icon → built-in glyph`: a named prop such\n * as `Dialog`'s `closeIcon` means \"this one call site\" and keeps winning, while the provider\n * replaces the built-in default for the whole product. Registering nothing renders exactly what the\n * library renders today, because the built-in glyph stays at its call site and is never part of\n * {@link cratisDefaults}.\n *\n * A name registered as `null` draws no glyph while the button, its part, and its accessible name\n * remain — the same meaning `closeIcon={null}` already has.\n */\nexport interface CratisComponentsIcons {\n /** Dismissal mark. Drawn by `Dialog`'s header close, `Toaster`'s dismiss, `ChatSidebar`, the `Chat` panel, and the PivotViewer detail panel. Defaults to `×`. */\n close?: ReactNode;\n /** Remove-this-value mark. Drawn by `TagGroup`'s tag remove, `Chip`'s remove control, and `CommandForm`'s chips field. Defaults to `×`. */\n remove?: ReactNode;\n /** Expand/collapse chevron on a closed-by-default surface. Drawn by `Dropdown`'s trigger and `ComboBox`'s trigger. Defaults to `⌄` (`▾` in `ComboBox`). */\n expand?: ReactNode;\n /** Ascending sort indicator. Drawn by `DataTableCore`'s sortable column header. Defaults to `▲`. */\n sortAscending?: ReactNode;\n /** Descending sort indicator. Drawn by `DataTableCore`'s sortable column header. Defaults to `▼`. */\n sortDescending?: ReactNode;\n /** Step-backwards mark. Drawn by `TablePaginator`'s previous page and the date picker's previous month. Defaults to `‹`. */\n previous?: ReactNode;\n /** Step-forwards mark. Drawn by `TablePaginator`'s next page and the date picker's next month. Defaults to `›`. */\n next?: ReactNode;\n /** Clear-the-current-value mark. Drawn by `Dropdown`'s clear-selection action and the PivotViewer filter panel's clear action. Defaults to `×`. */\n clear?: ReactNode;\n}\n\ninterface LegacyLocaleMessages {\n today?: string;\n clear?: string;\n aria?: {\n navigation?: string;\n firstPageLabel?: string;\n prevPageLabel?: string;\n nextPageLabel?: string;\n lastPageLabel?: string;\n };\n [message: string]: unknown;\n}\n\n/** Renderer-independent application configuration for Components. */\nexport interface CratisComponentsConfig {\n /** BCP 47 locale used by React Aria for dates, numbers, and interaction announcements. */\n locale?: string;\n /** Cratis-owned labels not supplied by the platform's internationalization APIs. */\n messages?: CratisComponentsMessages;\n /** Cratis-owned icon vocabulary replacing the built-in glyphs the library draws. */\n icons?: CratisComponentsIcons;\n /**\n * @deprecated Use {@link messages}; React Aria supplies its own locale data.\n */\n locales?: Record<string, LegacyLocaleMessages>;\n}\n\n/** Props for the application-root Components provider. */\nexport interface CratisComponentsProviderProps {\n /** Locale and Components-owned messages. */\n value?: CratisComponentsConfig;\n /** Mounts the global toaster with defaults or explicit options. */\n toaster?: boolean | ToasterProps;\n /**\n * Selects one stable presentation library. The broader generic manifest and ordered,\n * last-wins composition form remain experimental.\n */\n library?: unstable_UiLibrary | readonly unstable_UiLibrary[];\n /** Experimental profile-promise behavior. Defaults to strict. */\n libraryMode?: 'strict' | 'degrade';\n /** Terminal slot fallback behavior. Defaults to the built-in Core implementation. */\n rendererFallback?: 'core' | 'throw';\n /** Host environment for overlay portal containers. */\n overlayEnvironment?: CratisOverlayEnvironment;\n /**\n * Non-secret renderer setup attestations. Values are booleans so credentials and license\n * tokens never cross the Components provider boundary.\n */\n rendererSetup?: CratisRendererSetup;\n /** Application content. */\n children: ReactNode;\n}\n\n/**\n * Deep-merges consumer configuration over {@link cratisDefaults}.\n *\n * `icons` merges by name only. An icon value is an opaque node — often a React element — so it is\n * carried over by identity instead of being deep-merged into, while a partial map still leaves every\n * unregistered name to its built-in glyph.\n */\nexport const mergeCratisComponentsConfig = (\n value: CratisComponentsConfig | undefined,\n): CratisComponentsConfig => {\n const { icons, ...rest } = value ?? {};\n const merged = merge(cratisDefaults, rest) as CratisComponentsConfig;\n return icons ? { ...merged, icons: { ...cratisDefaults.icons, ...icons } } : merged;\n};\n\nconst withLegacyLocaleMessages = (\n config: CratisComponentsConfig,\n explicitMessages: CratisComponentsMessages | undefined,\n): CratisComponentsConfig => {\n const legacy = config.locale ? config.locales?.[config.locale] : undefined;\n if (!legacy) return config;\n return {\n ...config,\n messages: {\n ...config.messages,\n paginator: {\n navigation:\n explicitMessages?.paginator?.navigation ??\n legacy.aria?.navigation ??\n config.messages?.paginator?.navigation,\n first:\n explicitMessages?.paginator?.first ??\n legacy.aria?.firstPageLabel ??\n config.messages?.paginator?.first,\n previous:\n explicitMessages?.paginator?.previous ??\n legacy.aria?.prevPageLabel ??\n config.messages?.paginator?.previous,\n next:\n explicitMessages?.paginator?.next ??\n legacy.aria?.nextPageLabel ??\n config.messages?.paginator?.next,\n last:\n explicitMessages?.paginator?.last ??\n legacy.aria?.lastPageLabel ??\n config.messages?.paginator?.last,\n },\n datePicker: {\n ...config.messages?.datePicker,\n today:\n explicitMessages?.datePicker?.today ??\n legacy.today ??\n config.messages?.datePicker?.today,\n clear:\n explicitMessages?.datePicker?.clear ??\n legacy.clear ??\n config.messages?.datePicker?.clear,\n openCalendar:\n explicitMessages?.datePicker?.openCalendar ??\n config.messages?.datePicker?.openCalendar,\n previousMonth:\n explicitMessages?.datePicker?.previousMonth ??\n config.messages?.datePicker?.previousMonth,\n nextMonth:\n explicitMessages?.datePicker?.nextMonth ??\n config.messages?.datePicker?.nextMonth,\n },\n },\n };\n};\n\nconst validLocale = (locale: string | undefined) => {\n if (!locale) return 'en-US';\n try {\n return new Intl.Locale(locale).toString();\n } catch {\n return 'en-US';\n }\n};\n\n/** Application root for locale, labels, and the optional app-wide toaster. */\nexport const CratisComponentsProvider = ({\n value,\n toaster,\n library,\n libraryMode,\n rendererFallback,\n overlayEnvironment,\n rendererSetup,\n children,\n}: CratisComponentsProviderProps) => {\n const resolved = useMemo(\n () =>\n withLegacyLocaleMessages(mergeCratisComponentsConfig(value), value?.messages),\n [value],\n );\n\n return (\n <RendererRoot\n library={library}\n libraryMode={libraryMode}\n rendererFallback={rendererFallback}\n overlayEnvironment={overlayEnvironment}\n rendererSetup={rendererSetup}\n >\n <CratisComponentsContext.Provider value={resolved}>\n <I18nProvider locale={validLocale(resolved.locale)}>\n {children}\n {toaster && (\n <Toaster {...(typeof toaster === 'object' ? toaster : {})} />\n )}\n </I18nProvider>\n </CratisComponentsContext.Provider>\n </RendererRoot>\n );\n};\n"],"names":["_jsx","_jsxs"],"mappings":";;;;;;;;;;AAaA,MAAM,YAAY,GAAG,qBAAqB;AA+PnC,MAAM,2BAA2B,GAAG,CACvC,KAAyC,KACjB;IACxB,MAAM,EAAE,KAAK,EAAE,GAAG,IAAI,EAAE,GAAG,KAAK,IAAI,EAAE;IACtC,MAAM,MAAM,GAAG,KAAK,CAAC,cAAc,EAAE,IAAI,CAA2B;IACpE,OAAO,KAAK,GAAG,EAAE,GAAG,MAAM,EAAE,KAAK,EAAE,EAAE,GAAG,cAAc,CAAC,KAAK,EAAE,GAAG,KAAK,EAAE,EAAE,GAAG,MAAM;AACvF;AAEA,MAAM,wBAAwB,GAAG,CAC7B,MAA8B,EAC9B,gBAAsD,KAC9B;IACxB,MAAM,MAAM,GAAG,MAAM,CAAC,MAAM,GAAG,MAAM,CAAC,OAAO,GAAG,MAAM,CAAC,MAAM,CAAC,GAAG,SAAS;AAC1E,IAAA,IAAI,CAAC,MAAM;AAAE,QAAA,OAAO,MAAM;IAC1B,OAAO;AACH,QAAA,GAAG,MAAM;AACT,QAAA,QAAQ,EAAE;YACN,GAAG,MAAM,CAAC,QAAQ;AAClB,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C,OAAO,QAAM,OAAO,OAAO,KAAK,QAAQ,GAAG,OAAO,GAAG,EAAE,CAAC,GAAI,CAChE,CAAA,EAAA,CACU,EAAA,CACgB,EAAA,CACxB;AAEvB;;"}
|
|
1
|
+
{"version":3,"file":"CratisComponentsProvider.js","sources":["../../../Common/CratisComponentsProvider.tsx"],"sourcesContent":["// Copyright (c) Cratis. All rights reserved.\n// Licensed under the MIT license. See LICENSE file in the project root for full license information.\n\nimport { useMemo, type ReactNode } from 'react';\nimport { I18nProvider } from 'react-aria-components/I18nProvider';\nimport { merge } from 'ts-deepmerge';\nimport { Toaster, type ToasterProps } from '../Notifications/Toaster';\nimport { unstable_RendererRoot } from '../renderer/RendererContext';\nimport type { CratisRendererSetup, unstable_UiLibrary } from '../renderer/manifest';\nimport type { CratisOverlayEnvironment } from '../renderer/overlayEnvironment';\nimport { CratisComponentsContext } from '../configuration/CratisComponentsContext';\nimport { cratisDefaults } from '../configuration/CratisComponentsDefaults';\n\nconst RendererRoot = unstable_RendererRoot;\n\nexport { cratisDefaults } from '../configuration/CratisComponentsDefaults';\nexport { useCratisComponentsConfig } from '../configuration/CratisComponentsContext';\n\n/** Localizable labels owned by the Cratis paginator. */\nexport interface CratisPaginatorMessages {\n /** Pagination navigation-region name. */\n navigation?: string;\n /** First-page action label. */\n first?: string;\n /** Previous-page action label. */\n previous?: string;\n /** Next-page action label. */\n next?: string;\n /** Last-page action label. */\n last?: string;\n}\n\n/** Localizable labels owned by the Cratis date picker composition. */\nexport interface CratisDatePickerMessages {\n /** Today action label. */\n today?: string;\n /** Clear action label. */\n clear?: string;\n /** Calendar-trigger label. */\n openCalendar?: string;\n /** Previous-month action label. */\n previousMonth?: string;\n /** Next-month action label. */\n nextMonth?: string;\n /**\n * Accessible name for the segmented date input when neither an explicit\n * `aria-label` nor a `placeholder` is supplied. Previously an orphaned\n * `'Date'` literal with no override path.\n */\n label?: string;\n}\n\n/** Localizable labels owned by the Cratis {@link Dropdown} composition. */\nexport interface CratisDropdownMessages {\n /** Accessible name for the options-popover trigger. */\n showOptions?: string;\n /** Accessible name for the clear-selection action. */\n clearSelection?: string;\n}\n\n/**\n * Localizable action and dismissal labels shared by every Cratis-owned dialog\n * surface — {@link Dialog}, {@link CommandDialog}, and {@link StepperCommandDialog}.\n */\nexport interface CratisDialogMessages {\n /** Primary confirmation label (the `Ok` action in `DialogButtons.Ok*`). */\n ok?: string;\n /** Cancellation label (the `Cancel` action, and the Stepper footer Cancel). */\n cancel?: string;\n /** Affirmative label (the `Yes` action in `DialogButtons.YesNo*`). */\n yes?: string;\n /** Negative label (the `No` action in `DialogButtons.YesNo*`). */\n no?: string;\n /** Accessible name for the header close (×) action. */\n close?: string;\n}\n\n/** Localizable navigation labels owned by {@link CommandStepper} / {@link StepperCommandDialog}. */\nexport interface CratisStepperMessages {\n /** Advance-to-next-step action label. */\n next?: string;\n /** Return-to-previous-step action label. */\n previous?: string;\n /** Final-step submit action label. */\n submit?: string;\n}\n\n/** Localizable labels owned by the Cratis {@link Toaster}. */\nexport interface CratisNotificationsMessages {\n /** Accessible name for a toast's dismiss action. */\n dismiss?: string;\n /** Accessible name for the toast region landmark. */\n region?: string;\n}\n\n/** Localizable labels owned by the Cratis {@link DataTableCore} composition. */\nexport interface CratisDataTableMessages {\n /** Accessible name for a single-selection row control. */\n selectRow?: string;\n /** Accessible name for the select-all control in a multiple-selection header. */\n selectAllRows?: string;\n /** Placeholder for the loaded-page search input. */\n search?: string;\n /** Accessible name for the loaded-page search input. */\n searchAriaLabel?: string;\n /** Message shown while loading an empty table. */\n loading?: string;\n /** Message shown when a query fails. */\n failed?: string;\n /** Message shown when a query denies access. */\n unauthorized?: string;\n}\n\n/** Localizable accessible names for the Cratis filter panel and its searches. */\nexport interface CratisFilterMessages {\n /** FilterPanel dialog name. Defaults to 'Filters'. */\n label?: string;\n /**\n * Search-input name for FilterPanel, its option groups, and standalone CheckboxListFilter.\n * Unset by default so an effective search placeholder retains precedence over 'Search'.\n * PivotViewer supplies group-specific names instead of using this shared name for its groups.\n */\n searchAriaLabel?: string;\n}\n\n/** Localizable labels owned by the Cratis column-filter popup. */\nexport interface CratisColumnFilterMessages {\n /** Builds the filter-trigger accessible name from the effective field. */\n filterTriggerAriaLabel?: (field: string) => string;\n /** Builds the value-control accessible name from the effective field. */\n valueAriaLabel?: (field: string) => string;\n /** Accessible name for the match-mode selector. */\n matchModeAriaLabel?: string;\n /** Localizes a match mode while retaining its default label as fallback input. */\n matchModeLabel?: (mode: string, defaultLabel: string) => string;\n /** Clear action label. */\n clear?: string;\n /** Apply action label. */\n apply?: string;\n /** Boolean true option label. */\n true?: string;\n /** Boolean false option label. */\n false?: string;\n}\n\n/** Localizable labels owned by the Cratis {@link Toolbar} composition. */\nexport interface CratisToolbarMessages {\n /** Accessible toolbar name used when neither `aria-label` nor `aria-labelledby` is supplied. */\n label?: string;\n /** Accessible name of the close button in a drawer {@link ToolbarFolder}. Defaults to 'Close'. */\n closeDrawer?: string;\n}\n\n/** Components-owned message groups. */\nexport interface CratisComponentsMessages {\n /** Paginator labels. */\n paginator?: CratisPaginatorMessages;\n /** Date-picker labels. */\n datePicker?: CratisDatePickerMessages;\n /** Dropdown labels. */\n dropdown?: CratisDropdownMessages;\n /** Dialog action/dismissal labels shared by Dialog, CommandDialog, and StepperCommandDialog. */\n dialog?: CratisDialogMessages;\n /** Stepper navigation labels shared by CommandStepper and StepperCommandDialog. */\n stepper?: CratisStepperMessages;\n /** Toaster labels. */\n notifications?: CratisNotificationsMessages;\n /** DataTable search, selection, and query-state messages. */\n dataTable?: CratisDataTableMessages;\n /** FilterPanel dialog and search-input accessible names. */\n filter?: CratisFilterMessages;\n /** Column-filter popup labels and match-mode copy. */\n columnFilter?: CratisColumnFilterMessages;\n /** Toolbar accessible-name fallback. */\n toolbar?: CratisToolbarMessages;\n}\n\n/**\n * Components-owned icon vocabulary. Every name is a concept the library draws in more than one\n * place; registering one replaces that concept's built-in glyph everywhere it is drawn, without\n * touching the surrounding element, its part, or its accessible name.\n *\n * Resolution per site is `per-component prop → provider icon → built-in glyph`: a named prop such\n * as `Dialog`'s `closeIcon` means \"this one call site\" and keeps winning, while the provider\n * replaces the built-in default for the whole product. Registering nothing renders exactly what the\n * library renders today, because the built-in glyph stays at its call site and is never part of\n * {@link cratisDefaults}.\n *\n * A name registered as `null` draws no glyph while the button, its part, and its accessible name\n * remain — the same meaning `closeIcon={null}` already has.\n */\nexport interface CratisComponentsIcons {\n /** Dismissal mark. Drawn by `Dialog`'s header close, `Toaster`'s dismiss, `ChatSidebar`, the `Chat` panel, and the PivotViewer detail panel. Defaults to `×`. */\n close?: ReactNode;\n /** Remove-this-value mark. Drawn by `TagGroup`'s tag remove, `Chip`'s remove control, and `CommandForm`'s chips field. Defaults to `×`. */\n remove?: ReactNode;\n /** Expand/collapse chevron on a closed-by-default surface. Drawn by `Dropdown`'s trigger and `ComboBox`'s trigger. Defaults to `⌄` (`▾` in `ComboBox`). */\n expand?: ReactNode;\n /** Ascending sort indicator. Drawn by `DataTableCore`'s sortable column header. Defaults to `▲`. */\n sortAscending?: ReactNode;\n /** Descending sort indicator. Drawn by `DataTableCore`'s sortable column header. Defaults to `▼`. */\n sortDescending?: ReactNode;\n /** Step-backwards mark. Drawn by `TablePaginator`'s previous page and the date picker's previous month. Defaults to `‹`. */\n previous?: ReactNode;\n /** Step-forwards mark. Drawn by `TablePaginator`'s next page and the date picker's next month. Defaults to `›`. */\n next?: ReactNode;\n /** Clear-the-current-value mark. Drawn by `Dropdown`'s clear-selection action and the PivotViewer filter panel's clear action. Defaults to `×`. */\n clear?: ReactNode;\n}\n\ninterface LegacyLocaleMessages {\n today?: string;\n clear?: string;\n aria?: {\n navigation?: string;\n firstPageLabel?: string;\n prevPageLabel?: string;\n nextPageLabel?: string;\n lastPageLabel?: string;\n };\n [message: string]: unknown;\n}\n\n/** Renderer-independent application configuration for Components. */\nexport interface CratisComponentsConfig {\n /** BCP 47 locale used by React Aria for dates, numbers, and interaction announcements. */\n locale?: string;\n /** Cratis-owned labels not supplied by the platform's internationalization APIs. */\n messages?: CratisComponentsMessages;\n /** Cratis-owned icon vocabulary replacing the built-in glyphs the library draws. */\n icons?: CratisComponentsIcons;\n /**\n * @deprecated Use {@link messages}; React Aria supplies its own locale data.\n */\n locales?: Record<string, LegacyLocaleMessages>;\n}\n\n/** Props for the application-root Components provider. */\nexport interface CratisComponentsProviderProps {\n /** Locale and Components-owned messages. */\n value?: CratisComponentsConfig;\n /** Mounts the global toaster with defaults or explicit options. */\n toaster?: boolean | ToasterProps;\n /**\n * Selects one stable presentation library. The broader generic manifest and ordered,\n * last-wins composition form remain experimental.\n */\n library?: unstable_UiLibrary | readonly unstable_UiLibrary[];\n /** Experimental profile-promise behavior. Defaults to strict. */\n libraryMode?: 'strict' | 'degrade';\n /** Terminal slot fallback behavior. Defaults to the built-in Core implementation. */\n rendererFallback?: 'core' | 'throw';\n /** Host environment for overlay portal containers. */\n overlayEnvironment?: CratisOverlayEnvironment;\n /**\n * Non-secret renderer setup attestations. Values are booleans so credentials and license\n * tokens never cross the Components provider boundary.\n */\n rendererSetup?: CratisRendererSetup;\n /** Application content. */\n children: ReactNode;\n}\n\n/**\n * Deep-merges consumer configuration over {@link cratisDefaults}.\n *\n * `icons` merges by name only. An icon value is an opaque node — often a React element — so it is\n * carried over by identity instead of being deep-merged into, while a partial map still leaves every\n * unregistered name to its built-in glyph.\n */\nexport const mergeCratisComponentsConfig = (\n value: CratisComponentsConfig | undefined,\n): CratisComponentsConfig => {\n const { icons, ...rest } = value ?? {};\n const merged = merge(cratisDefaults, rest) as CratisComponentsConfig;\n return icons ? { ...merged, icons: { ...cratisDefaults.icons, ...icons } } : merged;\n};\n\nconst withLegacyLocaleMessages = (\n config: CratisComponentsConfig,\n explicitMessages: CratisComponentsMessages | undefined,\n): CratisComponentsConfig => {\n const legacy = config.locale ? config.locales?.[config.locale] : undefined;\n if (!legacy) return config;\n return {\n ...config,\n messages: {\n ...config.messages,\n paginator: {\n navigation:\n explicitMessages?.paginator?.navigation ??\n legacy.aria?.navigation ??\n config.messages?.paginator?.navigation,\n first:\n explicitMessages?.paginator?.first ??\n legacy.aria?.firstPageLabel ??\n config.messages?.paginator?.first,\n previous:\n explicitMessages?.paginator?.previous ??\n legacy.aria?.prevPageLabel ??\n config.messages?.paginator?.previous,\n next:\n explicitMessages?.paginator?.next ??\n legacy.aria?.nextPageLabel ??\n config.messages?.paginator?.next,\n last:\n explicitMessages?.paginator?.last ??\n legacy.aria?.lastPageLabel ??\n config.messages?.paginator?.last,\n },\n datePicker: {\n ...config.messages?.datePicker,\n today:\n explicitMessages?.datePicker?.today ??\n legacy.today ??\n config.messages?.datePicker?.today,\n clear:\n explicitMessages?.datePicker?.clear ??\n legacy.clear ??\n config.messages?.datePicker?.clear,\n openCalendar:\n explicitMessages?.datePicker?.openCalendar ??\n config.messages?.datePicker?.openCalendar,\n previousMonth:\n explicitMessages?.datePicker?.previousMonth ??\n config.messages?.datePicker?.previousMonth,\n nextMonth:\n explicitMessages?.datePicker?.nextMonth ??\n config.messages?.datePicker?.nextMonth,\n },\n },\n };\n};\n\nconst validLocale = (locale: string | undefined) => {\n if (!locale) return 'en-US';\n try {\n return new Intl.Locale(locale).toString();\n } catch {\n return 'en-US';\n }\n};\n\n/** Application root for locale, labels, and the optional app-wide toaster. */\nexport const CratisComponentsProvider = ({\n value,\n toaster,\n library,\n libraryMode,\n rendererFallback,\n overlayEnvironment,\n rendererSetup,\n children,\n}: CratisComponentsProviderProps) => {\n const resolved = useMemo(\n () =>\n withLegacyLocaleMessages(mergeCratisComponentsConfig(value), value?.messages),\n [value],\n );\n\n return (\n <RendererRoot\n library={library}\n libraryMode={libraryMode}\n rendererFallback={rendererFallback}\n overlayEnvironment={overlayEnvironment}\n rendererSetup={rendererSetup}\n >\n <CratisComponentsContext.Provider value={resolved}>\n <I18nProvider locale={validLocale(resolved.locale)}>\n {children}\n {toaster && (\n <Toaster {...(typeof toaster === 'object' ? toaster : {})} />\n )}\n </I18nProvider>\n </C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AAC,QAAQ,EAAE;IAC7C;AAAE,IAAA,MAAM;AACJ,QAAA,OAAO,OAAO;IAClB;AACJ,CAAC;MAGY,wBAAwB,GAAG,CAAC,EACrC,KAAK,EACL,OAAO,EACP,OAAO,EACP,WAAW,EACX,gBAAgB,EAChB,kBAAkB,EAClB,aAAa,EACb,QAAQ,GACoB,KAAI;IAChC,MAAM,QAAQ,GAAG,OAAO,CACpB,MACI,wBAAwB,CAAC,2BAA2B,CAAC,KAAK,CAAC,EAAE,KAAK,EAAE,QAAQ,CAAC,EACjF,CAAC,KAAK,CAAC,CACV;AAED,IAAA,QACIA,GAAA,CAAC,YAAY,EAAA,EACT,OAAO,EAAE,OAAO,EAChB,WAAW,EAAE,WAAW,EACxB,gBAAgB,EAAE,gBAAgB,EAClC,kBAAkB,EAAE,kBAAkB,EACtC,aAAa,EAAE,aAAa,YAE5BA,GAAA,CAAC,uBAAuB,CAAC,QAAQ,IAAC,KAAK,EAAE,QAAQ,EAAA,QAAA,EAC7CC,KAAC,YAAY,EAAA,EAAC,MAAM,EAAE,WAAW,CAAC,QAAQ,CAAC,MAAM,CAAC,EAAA,QAAA,EAAA,CAC7C,QAAQ,EACR,OAAO,KACJD,GAAA,CAAC,OAAO,QAAM,OAAO,OAAO,KAAK,QAAQ,GAAG,OAAO,GAAG,EAAE,CAAC,GAAI,CAChE,CAAA,EAAA,CACU,EAAA,CACgB,EAAA,CACxB;AAEvB;;"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* A target an item can point at, supplied by the host. The editor lists and selects destinations;
|
|
3
|
+
* it never resolves them, navigates to them or discovers them from an application.
|
|
4
|
+
*/
|
|
5
|
+
export interface ConfigurationDestination {
|
|
6
|
+
/** Stable identity stored on the item. Never the label. */
|
|
7
|
+
id: string;
|
|
8
|
+
/** Localizable name shown to the person choosing. */
|
|
9
|
+
label: string;
|
|
10
|
+
/** Optional group the destination is listed under. */
|
|
11
|
+
group?: string;
|
|
12
|
+
}
|
|
13
|
+
//# sourceMappingURL=ConfigurationDestination.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ConfigurationDestination.d.ts","sourceRoot":"","sources":["../../../ConfigurationEditor/ConfigurationDestination.ts"],"names":[],"mappings":"AAGA;;;GAGG;AACH,MAAM,WAAW,wBAAwB;IACrC,2DAA2D;IAC3D,EAAE,EAAE,MAAM,CAAC;IAEX,qDAAqD;IACrD,KAAK,EAAE,MAAM,CAAC;IAEd,sDAAsD;IACtD,KAAK,CAAC,EAAE,MAAM,CAAC;CAClB"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ConfigurationDestination.js","sourceRoot":"","sources":["../../../ConfigurationEditor/ConfigurationDestination.ts"],"names":[],"mappings":"AAAA,6CAA6C;AAC7C,qGAAqG","sourcesContent":["// Copyright (c) Cratis. All rights reserved.\n// Licensed under the MIT license. See LICENSE file in the project root for full license information.\n\n/**\n * A target an item can point at, supplied by the host. The editor lists and selects destinations;\n * it never resolves them, navigates to them or discovers them from an application.\n */\nexport interface ConfigurationDestination {\n /** Stable identity stored on the item. Never the label. */\n id: string;\n\n /** Localizable name shown to the person choosing. */\n label: string;\n\n /** Optional group the destination is listed under. */\n group?: string;\n}\n"]}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import type { ReactNode } from 'react';
|
|
2
|
+
import type { ConfigurationEditorRenderProps } from './ConfigurationEditorRenderProps.js';
|
|
3
|
+
/** Props for the {@link ConfigurationEditor} component. */
|
|
4
|
+
export interface ConfigurationEditorProps<TValue = unknown, TContext = unknown> {
|
|
5
|
+
/** The host-defined type of the component being configured. Looked up in the nearest {@link ConfigurationEditorProvider}. */
|
|
6
|
+
componentType: string;
|
|
7
|
+
/** The component's current configuration. */
|
|
8
|
+
value: TValue;
|
|
9
|
+
/** Receives a proposed configuration. Apply it by passing a new `value`; ignore it to cancel. */
|
|
10
|
+
onChange: (proposal: TValue) => void;
|
|
11
|
+
/** Whether the person may change the configuration. */
|
|
12
|
+
readOnly?: boolean;
|
|
13
|
+
/** Host-defined data passed untouched to the registered editor and to the fallback. */
|
|
14
|
+
context?: TContext;
|
|
15
|
+
/**
|
|
16
|
+
* What to show when no editor is registered for the component type, typically generic
|
|
17
|
+
* {@link PropertyControls}. Without a fallback nothing is rendered.
|
|
18
|
+
*/
|
|
19
|
+
fallback?: ReactNode | ((props: ConfigurationEditorRenderProps<TValue, TContext>) => ReactNode);
|
|
20
|
+
}
|
|
21
|
+
/**
|
|
22
|
+
* Shows the configuration editor registered for a component type, or the generic fallback. Which
|
|
23
|
+
* component types exist, what an edit means, and which template policy applies are all the host's;
|
|
24
|
+
* this component only chooses the editor.
|
|
25
|
+
*/
|
|
26
|
+
export declare const ConfigurationEditor: <TValue, TContext = unknown>({ componentType, value, onChange, readOnly, context, fallback, }: ConfigurationEditorProps<TValue, TContext>) => import("react").JSX.Element;
|
|
27
|
+
//# sourceMappingURL=ConfigurationEditor.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ConfigurationEditor.d.ts","sourceRoot":"","sources":["../../../ConfigurationEditor/ConfigurationEditor.tsx"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAEvC,OAAO,KAAK,EAAE,8BAA8B,EAAE,MAAM,qCAAkC,CAAC;AAEvF,2DAA2D;AAC3D,MAAM,WAAW,wBAAwB,CAAC,MAAM,GAAG,OAAO,EAAE,QAAQ,GAAG,OAAO;IAC1E,6HAA6H;IAC7H,aAAa,EAAE,MAAM,CAAC;IAEtB,6CAA6C;IAC7C,KAAK,EAAE,MAAM,CAAC;IAEd,iGAAiG;IACjG,QAAQ,EAAE,CAAC,QAAQ,EAAE,MAAM,KAAK,IAAI,CAAC;IAErC,uDAAuD;IACvD,QAAQ,CAAC,EAAE,OAAO,CAAC;IAEnB,uFAAuF;IACvF,OAAO,CAAC,EAAE,QAAQ,CAAC;IAEnB;;;OAGG;IACH,QAAQ,CAAC,EAAE,SAAS,GAAG,CAAC,CAAC,KAAK,EAAE,8BAA8B,CAAC,MAAM,EAAE,QAAQ,CAAC,KAAK,SAAS,CAAC,CAAC;CACnG;AAED;;;;GAIG;AACH,eAAO,MAAM,mBAAmB,GAAI,MAAM,EAAE,QAAQ,GAAG,OAAO,oEAO3D,wBAAwB,CAAC,MAAM,EAAE,QAAQ,CAAC,gCAM5C,CAAC"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { jsx, Fragment } from 'react/jsx-runtime';
|
|
2
|
+
import { useConfigurationEditor } from './ConfigurationEditorProvider.js';
|
|
3
|
+
|
|
4
|
+
const ConfigurationEditor = ({ componentType, value, onChange, readOnly = false, context, fallback, }) => {
|
|
5
|
+
const editor = useConfigurationEditor(componentType);
|
|
6
|
+
const props = { componentType, value, onChange, readOnly, context };
|
|
7
|
+
if (editor)
|
|
8
|
+
return jsx(Fragment, { children: editor(props) });
|
|
9
|
+
return jsx(Fragment, { children: typeof fallback === 'function' ? fallback(props) : fallback });
|
|
10
|
+
};
|
|
11
|
+
|
|
12
|
+
export { ConfigurationEditor };
|
|
13
|
+
//# sourceMappingURL=ConfigurationEditor.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ConfigurationEditor.js","sources":["../../../ConfigurationEditor/ConfigurationEditor.tsx"],"sourcesContent":["// Copyright (c) Cratis. All rights reserved.\n// Licensed under the MIT license. See LICENSE file in the project root for full license information.\n\nimport type { ReactNode } from 'react';\nimport { useConfigurationEditor } from './ConfigurationEditorProvider';\nimport type { ConfigurationEditorRenderProps } from './ConfigurationEditorRenderProps';\n\n/** Props for the {@link ConfigurationEditor} component. */\nexport interface ConfigurationEditorProps<TValue = unknown, TContext = unknown> {\n /** The host-defined type of the component being configured. Looked up in the nearest {@link ConfigurationEditorProvider}. */\n componentType: string;\n\n /** The component's current configuration. */\n value: TValue;\n\n /** Receives a proposed configuration. Apply it by passing a new `value`; ignore it to cancel. */\n onChange: (proposal: TValue) => void;\n\n /** Whether the person may change the configuration. */\n readOnly?: boolean;\n\n /** Host-defined data passed untouched to the registered editor and to the fallback. */\n context?: TContext;\n\n /**\n * What to show when no editor is registered for the component type, typically generic\n * {@link PropertyControls}. Without a fallback nothing is rendered.\n */\n fallback?: ReactNode | ((props: ConfigurationEditorRenderProps<TValue, TContext>) => ReactNode);\n}\n\n/**\n * Shows the configuration editor registered for a component type, or the generic fallback. Which\n * component types exist, what an edit means, and which template policy applies are all the host's;\n * this component only chooses the editor.\n */\nexport const ConfigurationEditor = <TValue, TContext = unknown>({\n componentType,\n value,\n onChange,\n readOnly = false,\n context,\n fallback,\n}: ConfigurationEditorProps<TValue, TContext>) => {\n const editor = useConfigurationEditor<TValue, TContext>(componentType);\n const props: ConfigurationEditorRenderProps<TValue, TContext> = { componentType, value, onChange, readOnly, context };\n\n if (editor) return <>{editor(props)}</>;\n return <>{typeof fallback === 'function' ? fallback(props) : fallback}</>;\n};\n"],"names":["_jsx"],"mappings":";;;MAoCa,mBAAmB,GAAG,CAA6B,EAC5D,aAAa,EACb,KAAK,EACL,QAAQ,EACR,QAAQ,GAAG,KAAK,EAChB,OAAO,EACP,QAAQ,GACiC,KAAI;AAC7C,IAAA,MAAM,MAAM,GAAG,sBAAsB,CAAmB,aAAa,CAAC;AACtE,IAAA,MAAM,KAAK,GAAqD,EAAE,aAAa,EAAE,KAAK,EAAE,QAAQ,EAAE,QAAQ,EAAE,OAAO,EAAE;AAErH,IAAA,IAAI,MAAM;AAAE,QAAA,OAAOA,0BAAG,MAAM,CAAC,KAAK,CAAC,GAAI;AACvC,IAAA,OAAOA,0BAAG,OAAO,QAAQ,KAAK,UAAU,GAAG,QAAQ,CAAC,KAAK,CAAC,GAAG,QAAQ,GAAI;AAC7E;;"}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import type { HTMLAttributes } from 'react';
|
|
2
|
+
/** Attributes passed through to one part of a configuration editor, including `data-*` attributes. */
|
|
3
|
+
export type ConfigurationEditorPartAttributes<TElement> = HTMLAttributes<TElement> & {
|
|
4
|
+
[attribute: `data-${string}`]: string | number | boolean | undefined;
|
|
5
|
+
};
|
|
6
|
+
//# sourceMappingURL=ConfigurationEditorPartAttributes.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ConfigurationEditorPartAttributes.d.ts","sourceRoot":"","sources":["../../../ConfigurationEditor/ConfigurationEditorPartAttributes.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,OAAO,CAAC;AAE5C,sGAAsG;AACtG,MAAM,MAAM,iCAAiC,CAAC,QAAQ,IAAI,cAAc,CAAC,QAAQ,CAAC,GAAG;IACjF,CAAC,SAAS,EAAE,QAAQ,MAAM,EAAE,GAAG,MAAM,GAAG,MAAM,GAAG,OAAO,GAAG,SAAS,CAAC;CACxE,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ConfigurationEditorPartAttributes.js","sourceRoot":"","sources":["../../../ConfigurationEditor/ConfigurationEditorPartAttributes.ts"],"names":[],"mappings":"AAAA,6CAA6C;AAC7C,qGAAqG","sourcesContent":["// Copyright (c) Cratis. All rights reserved.\n// Licensed under the MIT license. See LICENSE file in the project root for full license information.\n\nimport type { HTMLAttributes } from 'react';\n\n/** Attributes passed through to one part of a configuration editor, including `data-*` attributes. */\nexport type ConfigurationEditorPartAttributes<TElement> = HTMLAttributes<TElement> & {\n [attribute: `data-${string}`]: string | number | boolean | undefined;\n};\n"]}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import { type ReactNode } from 'react';
|
|
2
|
+
import type { ConfigurationEditorRenderer } from './ConfigurationEditorRenderer.js';
|
|
3
|
+
/** The editors available to a subtree, by host-defined component type. */
|
|
4
|
+
export type ConfigurationEditorMap = Readonly<Record<string, ConfigurationEditorRenderer<never, never>>>;
|
|
5
|
+
/** Props for the {@link ConfigurationEditorProvider} component. */
|
|
6
|
+
export interface ConfigurationEditorProviderProps {
|
|
7
|
+
/**
|
|
8
|
+
* The specialised editors the host registers, keyed by its own component type names. A nested
|
|
9
|
+
* provider adds to and overrides its parent's editors.
|
|
10
|
+
*/
|
|
11
|
+
editors: ConfigurationEditorMap;
|
|
12
|
+
/** The subtree that can look the editors up. */
|
|
13
|
+
children?: ReactNode;
|
|
14
|
+
}
|
|
15
|
+
/**
|
|
16
|
+
* Makes component-specific configuration editors available to a subtree. This is the extension
|
|
17
|
+
* seam: a component brings its own editor, the host registers it under the type name it already
|
|
18
|
+
* uses, and {@link ConfigurationEditor} falls back to generic controls for everything else.
|
|
19
|
+
*/
|
|
20
|
+
export declare const ConfigurationEditorProvider: ({ editors, children }: ConfigurationEditorProviderProps) => import("react").JSX.Element;
|
|
21
|
+
/**
|
|
22
|
+
* Looks up the editor registered for a component type.
|
|
23
|
+
*
|
|
24
|
+
* @param componentType The host-defined component type.
|
|
25
|
+
* @returns The registered editor, or `undefined` when none is registered.
|
|
26
|
+
*/
|
|
27
|
+
export declare const useConfigurationEditor: <TValue, TContext = unknown>(componentType: string) => ConfigurationEditorRenderer<TValue, TContext> | undefined;
|
|
28
|
+
//# sourceMappingURL=ConfigurationEditorProvider.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ConfigurationEditorProvider.d.ts","sourceRoot":"","sources":["../../../ConfigurationEditor/ConfigurationEditorProvider.tsx"],"names":[],"mappings":"AAGA,OAAO,EAAsC,KAAK,SAAS,EAAE,MAAM,OAAO,CAAC;AAC3E,OAAO,KAAK,EAAE,2BAA2B,EAAE,MAAM,kCAA+B,CAAC;AAEjF,0EAA0E;AAC1E,MAAM,MAAM,sBAAsB,GAAG,QAAQ,CAAC,MAAM,CAAC,MAAM,EAAE,2BAA2B,CAAC,KAAK,EAAE,KAAK,CAAC,CAAC,CAAC,CAAC;AAIzG,mEAAmE;AACnE,MAAM,WAAW,gCAAgC;IAC7C;;;OAGG;IACH,OAAO,EAAE,sBAAsB,CAAC;IAEhC,gDAAgD;IAChD,QAAQ,CAAC,EAAE,SAAS,CAAC;CACxB;AAED;;;;GAIG;AACH,eAAO,MAAM,2BAA2B,0BAA2B,gCAAgC,gCAIlG,CAAC;AAEF;;;;;GAKG;AACH,eAAO,MAAM,sBAAsB,GAAI,MAAM,EAAE,QAAQ,GAAG,OAAO,iBAC9C,MAAM,KACtB,2BAA2B,CAAC,MAAM,EAAE,QAAQ,CAAC,GAAG,SAGlD,CAAC"}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { jsx } from 'react/jsx-runtime';
|
|
2
|
+
import { createContext, useContext, useMemo } from 'react';
|
|
3
|
+
|
|
4
|
+
const ConfigurationEditorContext = createContext({});
|
|
5
|
+
const ConfigurationEditorProvider = ({ editors, children }) => {
|
|
6
|
+
const parent = useContext(ConfigurationEditorContext);
|
|
7
|
+
const merged = useMemo(() => ({ ...parent, ...editors }), [parent, editors]);
|
|
8
|
+
return jsx(ConfigurationEditorContext.Provider, { value: merged, children: children });
|
|
9
|
+
};
|
|
10
|
+
const useConfigurationEditor = (componentType) => {
|
|
11
|
+
const editors = useContext(ConfigurationEditorContext);
|
|
12
|
+
return editors[componentType];
|
|
13
|
+
};
|
|
14
|
+
|
|
15
|
+
export { ConfigurationEditorProvider, useConfigurationEditor };
|
|
16
|
+
//# sourceMappingURL=ConfigurationEditorProvider.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ConfigurationEditorProvider.js","sources":["../../../ConfigurationEditor/ConfigurationEditorProvider.tsx"],"sourcesContent":["// Copyright (c) Cratis. All rights reserved.\n// Licensed under the MIT license. See LICENSE file in the project root for full license information.\n\nimport { createContext, useContext, useMemo, type ReactNode } from 'react';\nimport type { ConfigurationEditorRenderer } from './ConfigurationEditorRenderer';\n\n/** The editors available to a subtree, by host-defined component type. */\nexport type ConfigurationEditorMap = Readonly<Record<string, ConfigurationEditorRenderer<never, never>>>;\n\nconst ConfigurationEditorContext = createContext<ConfigurationEditorMap>({});\n\n/** Props for the {@link ConfigurationEditorProvider} component. */\nexport interface ConfigurationEditorProviderProps {\n /**\n * The specialised editors the host registers, keyed by its own component type names. A nested\n * provider adds to and overrides its parent's editors.\n */\n editors: ConfigurationEditorMap;\n\n /** The subtree that can look the editors up. */\n children?: ReactNode;\n}\n\n/**\n * Makes component-specific configuration editors available to a subtree. This is the extension\n * seam: a component brings its own editor, the host registers it under the type name it already\n * uses, and {@link ConfigurationEditor} falls back to generic controls for everything else.\n */\nexport const ConfigurationEditorProvider = ({ editors, children }: ConfigurationEditorProviderProps) => {\n const parent = useContext(ConfigurationEditorContext);\n const merged = useMemo(() => ({ ...parent, ...editors }), [parent, editors]);\n return <ConfigurationEditorContext.Provider value={merged}>{children}</ConfigurationEditorContext.Provider>;\n};\n\n/**\n * Looks up the editor registered for a component type.\n *\n * @param componentType The host-defined component type.\n * @returns The registered editor, or `undefined` when none is registered.\n */\nexport const useConfigurationEditor = <TValue, TContext = unknown>(\n componentType: string,\n): ConfigurationEditorRenderer<TValue, TContext> | undefined => {\n const editors = useContext(ConfigurationEditorContext);\n return editors[componentType] as unknown as ConfigurationEditorRenderer<TValue, TContext> | undefined;\n};\n"],"names":["_jsx"],"mappings":";;;AASA,MAAM,0BAA0B,GAAG,aAAa,CAAyB,EAAE,CAAC;AAmBrE,MAAM,2BAA2B,GAAG,CAAC,EAAE,OAAO,EAAE,QAAQ,EAAoC,KAAI;AACnG,IAAA,MAAM,MAAM,GAAG,UAAU,CAAC,0BAA0B,CAAC;IACrD,MAAM,MAAM,GAAG,OAAO,CAAC,OAAO,EAAE,GAAG,MAAM,EAAE,GAAG,OAAO,EAAE,CAAC,EAAE,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;IAC5E,OAAOA,GAAA,CAAC,0BAA0B,CAAC,QAAQ,EAAA,EAAC,KAAK,EAAE,MAAM,EAAA,QAAA,EAAG,QAAQ,EAAA,CAAuC;AAC/G;AAQO,MAAM,sBAAsB,GAAG,CAClC,aAAqB,KACsC;AAC3D,IAAA,MAAM,OAAO,GAAG,UAAU,CAAC,0BAA0B,CAAC;AACtD,IAAA,OAAO,OAAO,CAAC,aAAa,CAAyE;AACzG;;"}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* What a registered editor receives. The value is the host's own configuration for the component;
|
|
3
|
+
* the editor reads it and proposes a replacement through {@link onChange}.
|
|
4
|
+
*/
|
|
5
|
+
export interface ConfigurationEditorRenderProps<TValue = unknown, TContext = unknown> {
|
|
6
|
+
/** The host-defined component type the editor was looked up by. */
|
|
7
|
+
componentType: string;
|
|
8
|
+
/** The component's current configuration. */
|
|
9
|
+
value: TValue;
|
|
10
|
+
/**
|
|
11
|
+
* Proposes a new configuration. The editor is controlled: the host applies the proposal by passing
|
|
12
|
+
* a new `value`, or ignores it to cancel. The host still owns permission checks and persistence.
|
|
13
|
+
*/
|
|
14
|
+
onChange: (proposal: TValue) => void;
|
|
15
|
+
/** Whether the person may change the configuration. */
|
|
16
|
+
readOnly: boolean;
|
|
17
|
+
/** Host-defined data the editor needs, such as capabilities, destinations or an icon catalog. Passed through untouched. */
|
|
18
|
+
context?: TContext;
|
|
19
|
+
}
|
|
20
|
+
//# sourceMappingURL=ConfigurationEditorRenderProps.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ConfigurationEditorRenderProps.d.ts","sourceRoot":"","sources":["../../../ConfigurationEditor/ConfigurationEditorRenderProps.ts"],"names":[],"mappings":"AAGA;;;GAGG;AACH,MAAM,WAAW,8BAA8B,CAAC,MAAM,GAAG,OAAO,EAAE,QAAQ,GAAG,OAAO;IAChF,mEAAmE;IACnE,aAAa,EAAE,MAAM,CAAC;IAEtB,6CAA6C;IAC7C,KAAK,EAAE,MAAM,CAAC;IAEd;;;OAGG;IACH,QAAQ,EAAE,CAAC,QAAQ,EAAE,MAAM,KAAK,IAAI,CAAC;IAErC,uDAAuD;IACvD,QAAQ,EAAE,OAAO,CAAC;IAElB,2HAA2H;IAC3H,OAAO,CAAC,EAAE,QAAQ,CAAC;CACtB"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ConfigurationEditorRenderProps.js","sourceRoot":"","sources":["../../../ConfigurationEditor/ConfigurationEditorRenderProps.ts"],"names":[],"mappings":"AAAA,6CAA6C;AAC7C,qGAAqG","sourcesContent":["// Copyright (c) Cratis. All rights reserved.\n// Licensed under the MIT license. See LICENSE file in the project root for full license information.\n\n/**\n * What a registered editor receives. The value is the host's own configuration for the component;\n * the editor reads it and proposes a replacement through {@link onChange}.\n */\nexport interface ConfigurationEditorRenderProps<TValue = unknown, TContext = unknown> {\n /** The host-defined component type the editor was looked up by. */\n componentType: string;\n\n /** The component's current configuration. */\n value: TValue;\n\n /**\n * Proposes a new configuration. The editor is controlled: the host applies the proposal by passing\n * a new `value`, or ignores it to cancel. The host still owns permission checks and persistence.\n */\n onChange: (proposal: TValue) => void;\n\n /** Whether the person may change the configuration. */\n readOnly: boolean;\n\n /** Host-defined data the editor needs, such as capabilities, destinations or an icon catalog. Passed through untouched. */\n context?: TContext;\n}\n"]}
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import type { ReactNode } from 'react';
|
|
2
|
+
import type { ConfigurationEditorRenderProps } from './ConfigurationEditorRenderProps.js';
|
|
3
|
+
/** Renders the configuration experience of one component type. */
|
|
4
|
+
export type ConfigurationEditorRenderer<TValue = never, TContext = never> = (props: ConfigurationEditorRenderProps<TValue, TContext>) => ReactNode;
|
|
5
|
+
//# sourceMappingURL=ConfigurationEditorRenderer.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ConfigurationEditorRenderer.d.ts","sourceRoot":"","sources":["../../../ConfigurationEditor/ConfigurationEditorRenderer.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AACvC,OAAO,KAAK,EAAE,8BAA8B,EAAE,MAAM,qCAAkC,CAAC;AAEvF,kEAAkE;AAClE,MAAM,MAAM,2BAA2B,CAAC,MAAM,GAAG,KAAK,EAAE,QAAQ,GAAG,KAAK,IAAI,CACxE,KAAK,EAAE,8BAA8B,CAAC,MAAM,EAAE,QAAQ,CAAC,KACtD,SAAS,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ConfigurationEditorRenderer.js","sourceRoot":"","sources":["../../../ConfigurationEditor/ConfigurationEditorRenderer.ts"],"names":[],"mappings":"AAAA,6CAA6C;AAC7C,qGAAqG","sourcesContent":["// Copyright (c) Cratis. All rights reserved.\n// Licensed under the MIT license. See LICENSE file in the project root for full license information.\n\nimport type { ReactNode } from 'react';\nimport type { ConfigurationEditorRenderProps } from './ConfigurationEditorRenderProps';\n\n/** Renders the configuration experience of one component type. */\nexport type ConfigurationEditorRenderer<TValue = never, TContext = never> = (\n props: ConfigurationEditorRenderProps<TValue, TContext>,\n) => ReactNode;\n"]}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* A qualified, renderer-neutral reference to one icon. Labels, display names, CSS classes, markup
|
|
3
|
+
* and catalog order are never identity: two references are the same icon when `library`, `key` and
|
|
4
|
+
* `variant` all match.
|
|
5
|
+
*
|
|
6
|
+
* The shape is structural, so a host can pass the reference its icon library produces straight
|
|
7
|
+
* through without conversion.
|
|
8
|
+
*/
|
|
9
|
+
export interface ConfigurationIconReference {
|
|
10
|
+
/** Stable identity of the icon library the icon belongs to. */
|
|
11
|
+
library: string;
|
|
12
|
+
/** Stable identity of the icon inside its library. */
|
|
13
|
+
key: string;
|
|
14
|
+
/** Optional style variant of the icon. */
|
|
15
|
+
variant?: string;
|
|
16
|
+
}
|
|
17
|
+
//# sourceMappingURL=ConfigurationIconReference.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ConfigurationIconReference.d.ts","sourceRoot":"","sources":["../../../ConfigurationEditor/ConfigurationIconReference.ts"],"names":[],"mappings":"AAGA;;;;;;;GAOG;AACH,MAAM,WAAW,0BAA0B;IACvC,+DAA+D;IAC/D,OAAO,EAAE,MAAM,CAAC;IAEhB,sDAAsD;IACtD,GAAG,EAAE,MAAM,CAAC;IAEZ,0CAA0C;IAC1C,OAAO,CAAC,EAAE,MAAM,CAAC;CACpB"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ConfigurationIconReference.js","sourceRoot":"","sources":["../../../ConfigurationEditor/ConfigurationIconReference.ts"],"names":[],"mappings":"AAAA,6CAA6C;AAC7C,qGAAqG","sourcesContent":["// Copyright (c) Cratis. All rights reserved.\n// Licensed under the MIT license. See LICENSE file in the project root for full license information.\n\n/**\n * A qualified, renderer-neutral reference to one icon. Labels, display names, CSS classes, markup\n * and catalog order are never identity: two references are the same icon when `library`, `key` and\n * `variant` all match.\n *\n * The shape is structural, so a host can pass the reference its icon library produces straight\n * through without conversion.\n */\nexport interface ConfigurationIconReference {\n /** Stable identity of the icon library the icon belongs to. */\n library: string;\n\n /** Stable identity of the icon inside its library. */\n key: string;\n\n /** Optional style variant of the icon. */\n variant?: string;\n}\n"]}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import type { ConfigurationIconReference } from './ConfigurationIconReference.js';
|
|
2
|
+
/**
|
|
3
|
+
* One entry of an ordered collection, such as an item of a navigation component. Hosts extend this
|
|
4
|
+
* with their own properties; the editor carries them through every proposal unchanged.
|
|
5
|
+
*/
|
|
6
|
+
export interface OrderedItem {
|
|
7
|
+
/** Stable identity that survives rename and reorder. Assigned by the host, never by the editor. */
|
|
8
|
+
id: string;
|
|
9
|
+
/** Localizable text shown for the item. */
|
|
10
|
+
label: string;
|
|
11
|
+
/** The item's icon, if it has one. */
|
|
12
|
+
icon?: ConfigurationIconReference;
|
|
13
|
+
/** The id of the item's {@link ConfigurationDestination}, if it has one. */
|
|
14
|
+
destination?: string;
|
|
15
|
+
}
|
|
16
|
+
//# sourceMappingURL=OrderedItem.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"OrderedItem.d.ts","sourceRoot":"","sources":["../../../ConfigurationEditor/OrderedItem.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,0BAA0B,EAAE,MAAM,iCAA8B,CAAC;AAE/E;;;GAGG;AACH,MAAM,WAAW,WAAW;IACxB,mGAAmG;IACnG,EAAE,EAAE,MAAM,CAAC;IAEX,2CAA2C;IAC3C,KAAK,EAAE,MAAM,CAAC;IAEd,sCAAsC;IACtC,IAAI,CAAC,EAAE,0BAA0B,CAAC;IAElC,4EAA4E;IAC5E,WAAW,CAAC,EAAE,MAAM,CAAC;CACxB"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"OrderedItem.js","sourceRoot":"","sources":["../../../ConfigurationEditor/OrderedItem.ts"],"names":[],"mappings":"AAAA,6CAA6C;AAC7C,qGAAqG","sourcesContent":["// Copyright (c) Cratis. All rights reserved.\n// Licensed under the MIT license. See LICENSE file in the project root for full license information.\n\nimport type { ConfigurationIconReference } from './ConfigurationIconReference';\n\n/**\n * One entry of an ordered collection, such as an item of a navigation component. Hosts extend this\n * with their own properties; the editor carries them through every proposal unchanged.\n */\nexport interface OrderedItem {\n /** Stable identity that survives rename and reorder. Assigned by the host, never by the editor. */\n id: string;\n\n /** Localizable text shown for the item. */\n label: string;\n\n /** The item's icon, if it has one. */\n icon?: ConfigurationIconReference;\n\n /** The id of the item's {@link ConfigurationDestination}, if it has one. */\n destination?: string;\n}\n"]}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import type { OrderedItemField } from './OrderedItemField.js';
|
|
2
|
+
import type { OrderedItemFieldAccess } from './OrderedItemFieldAccess.js';
|
|
3
|
+
import type { OrderedItemOperation } from './OrderedItemOperation.js';
|
|
4
|
+
/**
|
|
5
|
+
* What the host allows on the collection. The editor enforces it twice: a restricted control is not
|
|
6
|
+
* offered, and a proposal for a restricted operation or field is never emitted. The host stays
|
|
7
|
+
* responsible for authoritative permission checks, persistence and template resolution.
|
|
8
|
+
*/
|
|
9
|
+
export interface OrderedItemCapabilities {
|
|
10
|
+
/** Whether items can be added. */
|
|
11
|
+
add: boolean;
|
|
12
|
+
/** Whether items can be removed. */
|
|
13
|
+
remove: boolean;
|
|
14
|
+
/** Whether items can be reordered. */
|
|
15
|
+
reorder: boolean;
|
|
16
|
+
/** Access to each field. A field that is left out is hidden. */
|
|
17
|
+
fields: Partial<Record<OrderedItemField, OrderedItemFieldAccess>>;
|
|
18
|
+
/** The most items the collection may hold. Adding is unavailable once it is reached. */
|
|
19
|
+
maxItems?: number;
|
|
20
|
+
/** Why an operation or field is restricted. Shown as text next to the restricted control. */
|
|
21
|
+
reasons?: Partial<Record<OrderedItemOperation | OrderedItemField, string>>;
|
|
22
|
+
}
|
|
23
|
+
//# sourceMappingURL=OrderedItemCapabilities.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"OrderedItemCapabilities.d.ts","sourceRoot":"","sources":["../../../ConfigurationEditor/OrderedItemCapabilities.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,uBAAoB,CAAC;AAC3D,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,6BAA0B,CAAC;AACvE,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,2BAAwB,CAAC;AAEnE;;;;GAIG;AACH,MAAM,WAAW,uBAAuB;IACpC,kCAAkC;IAClC,GAAG,EAAE,OAAO,CAAC;IAEb,oCAAoC;IACpC,MAAM,EAAE,OAAO,CAAC;IAEhB,sCAAsC;IACtC,OAAO,EAAE,OAAO,CAAC;IAEjB,gEAAgE;IAChE,MAAM,EAAE,OAAO,CAAC,MAAM,CAAC,gBAAgB,EAAE,sBAAsB,CAAC,CAAC,CAAC;IAElE,wFAAwF;IACxF,QAAQ,CAAC,EAAE,MAAM,CAAC;IAElB,6FAA6F;IAC7F,OAAO,CAAC,EAAE,OAAO,CAAC,MAAM,CAAC,oBAAoB,GAAG,gBAAgB,EAAE,MAAM,CAAC,CAAC,CAAC;CAC9E"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"OrderedItemCapabilities.js","sourceRoot":"","sources":["../../../ConfigurationEditor/OrderedItemCapabilities.ts"],"names":[],"mappings":"AAAA,6CAA6C;AAC7C,qGAAqG","sourcesContent":["// Copyright (c) Cratis. All rights reserved.\n// Licensed under the MIT license. See LICENSE file in the project root for full license information.\n\nimport type { OrderedItemField } from './OrderedItemField';\nimport type { OrderedItemFieldAccess } from './OrderedItemFieldAccess';\nimport type { OrderedItemOperation } from './OrderedItemOperation';\n\n/**\n * What the host allows on the collection. The editor enforces it twice: a restricted control is not\n * offered, and a proposal for a restricted operation or field is never emitted. The host stays\n * responsible for authoritative permission checks, persistence and template resolution.\n */\nexport interface OrderedItemCapabilities {\n /** Whether items can be added. */\n add: boolean;\n\n /** Whether items can be removed. */\n remove: boolean;\n\n /** Whether items can be reordered. */\n reorder: boolean;\n\n /** Access to each field. A field that is left out is hidden. */\n fields: Partial<Record<OrderedItemField, OrderedItemFieldAccess>>;\n\n /** The most items the collection may hold. Adding is unavailable once it is reached. */\n maxItems?: number;\n\n /** Why an operation or field is restricted. Shown as text next to the restricted control. */\n reasons?: Partial<Record<OrderedItemOperation | OrderedItemField, string>>;\n}\n"]}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import type { ConfigurationDestination } from './ConfigurationDestination.js';
|
|
2
|
+
import type { OrderedItem } from './OrderedItem.js';
|
|
3
|
+
import type { OrderedItemEditorParts } from './OrderedItemEditorParts.js';
|
|
4
|
+
import type { OrderedItemLabels } from './OrderedItemLabels.js';
|
|
5
|
+
interface DestinationFieldProps<TItem extends OrderedItem> {
|
|
6
|
+
item: TItem;
|
|
7
|
+
editable: boolean;
|
|
8
|
+
itemName: string;
|
|
9
|
+
labels: Required<OrderedItemLabels>;
|
|
10
|
+
destinations: ReadonlyArray<ConfigurationDestination>;
|
|
11
|
+
message: string | undefined;
|
|
12
|
+
messageId: string;
|
|
13
|
+
parts: OrderedItemEditorParts | undefined;
|
|
14
|
+
onChange: (destination: string | undefined) => void;
|
|
15
|
+
}
|
|
16
|
+
/**
|
|
17
|
+
* The destination field of one item: a select over the host's destinations, or the destination's
|
|
18
|
+
* name as text. A destination the host no longer lists stays selectable-as-current and is flagged.
|
|
19
|
+
*/
|
|
20
|
+
export declare const OrderedItemDestinationField: <TItem extends OrderedItem>({ item, editable, itemName, labels, destinations, message, messageId, parts, onChange, }: DestinationFieldProps<TItem>) => import("react").JSX.Element;
|
|
21
|
+
export {};
|
|
22
|
+
//# sourceMappingURL=OrderedItemDestinationField.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"OrderedItemDestinationField.d.ts","sourceRoot":"","sources":["../../../ConfigurationEditor/OrderedItemDestinationField.tsx"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,wBAAwB,EAAE,MAAM,+BAA4B,CAAC;AAC3E,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,kBAAe,CAAC;AACjD,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,6BAA0B,CAAC;AACvE,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,wBAAqB,CAAC;AAE7D,UAAU,qBAAqB,CAAC,KAAK,SAAS,WAAW;IACrD,IAAI,EAAE,KAAK,CAAC;IACZ,QAAQ,EAAE,OAAO,CAAC;IAClB,QAAQ,EAAE,MAAM,CAAC;IACjB,MAAM,EAAE,QAAQ,CAAC,iBAAiB,CAAC,CAAC;IACpC,YAAY,EAAE,aAAa,CAAC,wBAAwB,CAAC,CAAC;IACtD,OAAO,EAAE,MAAM,GAAG,SAAS,CAAC;IAC5B,SAAS,EAAE,MAAM,CAAC;IAClB,KAAK,EAAE,sBAAsB,GAAG,SAAS,CAAC;IAC1C,QAAQ,EAAE,CAAC,WAAW,EAAE,MAAM,GAAG,SAAS,KAAK,IAAI,CAAC;CACvD;AAYD;;;GAGG;AACH,eAAO,MAAM,2BAA2B,GAAI,KAAK,SAAS,WAAW,4FAUlE,qBAAqB,CAAC,KAAK,CAAC,gCAgD9B,CAAC"}
|