@qoretechnologies/reqraft 0.10.64 → 0.10.65-pr.137.g62fcecc
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +53 -1
- package/dist/components/Description/describedControl.d.ts +54 -0
- package/dist/components/Description/describedControl.d.ts.map +1 -0
- package/dist/components/Description/describedControl.js +81 -0
- package/dist/components/Description/describedControl.js.map +1 -0
- package/dist/components/Description/index.d.ts.map +1 -1
- package/dist/components/Description/index.js +3 -2
- package/dist/components/Description/index.js.map +1 -1
- package/dist/components/colorValue/colorValue.d.ts +59 -0
- package/dist/components/colorValue/colorValue.d.ts.map +1 -0
- package/dist/components/colorValue/colorValue.js +245 -0
- package/dist/components/colorValue/colorValue.js.map +1 -0
- package/dist/components/colorValue/index.d.ts +34 -0
- package/dist/components/colorValue/index.d.ts.map +1 -0
- package/dist/components/colorValue/index.js +136 -0
- package/dist/components/colorValue/index.js.map +1 -0
- package/dist/components/colorValue/labels.d.ts +12 -0
- package/dist/components/colorValue/labels.d.ts.map +1 -0
- package/dist/components/colorValue/labels.js +11 -0
- package/dist/components/colorValue/labels.js.map +1 -0
- package/dist/components/composer/Composer.d.ts +1 -1
- package/dist/components/composer/Composer.d.ts.map +1 -1
- package/dist/components/composer/Composer.js +2 -2
- package/dist/components/composer/Composer.js.map +1 -1
- package/dist/components/dpqlEditor/DpqlEditor.d.ts.map +1 -1
- package/dist/components/dpqlEditor/DpqlEditor.js +25 -5
- package/dist/components/dpqlEditor/DpqlEditor.js.map +1 -1
- package/dist/components/dpqlEditor/dpqlHelpers.d.ts +36 -5
- package/dist/components/dpqlEditor/dpqlHelpers.d.ts.map +1 -1
- package/dist/components/dpqlEditor/dpqlHelpers.js +340 -62
- package/dist/components/dpqlEditor/dpqlHelpers.js.map +1 -1
- package/dist/components/dpqlEditor/dpqlTags.d.ts +11 -7
- package/dist/components/dpqlEditor/dpqlTags.d.ts.map +1 -1
- package/dist/components/dpqlEditor/dpqlTags.js +35 -17
- package/dist/components/dpqlEditor/dpqlTags.js.map +1 -1
- package/dist/components/dpqlEditor/types.d.ts +54 -8
- package/dist/components/dpqlEditor/types.d.ts.map +1 -1
- package/dist/components/dpqlEditor/useDpqlSession.d.ts +2 -2
- package/dist/components/dpqlEditor/useDpqlSession.d.ts.map +1 -1
- package/dist/components/dpqlEditor/useDpqlSession.js +16 -7
- package/dist/components/dpqlEditor/useDpqlSession.js.map +1 -1
- package/dist/components/form/engine/CompactRow.d.ts.map +1 -1
- package/dist/components/form/engine/CompactRow.js +207 -97
- package/dist/components/form/engine/CompactRow.js.map +1 -1
- package/dist/components/form/engine/CompactToolbar.d.ts.map +1 -1
- package/dist/components/form/engine/CompactToolbar.js +29 -3
- package/dist/components/form/engine/CompactToolbar.js.map +1 -1
- package/dist/components/form/engine/FormEngine.d.ts +58 -10
- package/dist/components/form/engine/FormEngine.d.ts.map +1 -1
- package/dist/components/form/engine/FormEngine.js +542 -112
- package/dist/components/form/engine/FormEngine.js.map +1 -1
- package/dist/components/form/engine/HiddenFieldsNote.d.ts +28 -0
- package/dist/components/form/engine/HiddenFieldsNote.d.ts.map +1 -0
- package/dist/components/form/engine/HiddenFieldsNote.js +32 -0
- package/dist/components/form/engine/HiddenFieldsNote.js.map +1 -0
- package/dist/components/form/engine/OptionFieldMessages.d.ts.map +1 -1
- package/dist/components/form/engine/OptionFieldMessages.js +24 -3
- package/dist/components/form/engine/OptionFieldMessages.js.map +1 -1
- package/dist/components/form/engine/_structuredData/SchemaDataView.d.ts +2 -2
- package/dist/components/form/engine/_structuredData/SchemaDataView.d.ts.map +1 -1
- package/dist/components/form/engine/_structuredData/SchemaDataView.js +12 -6
- package/dist/components/form/engine/_structuredData/SchemaDataView.js.map +1 -1
- package/dist/components/form/engine/compactRowContext.d.ts +21 -0
- package/dist/components/form/engine/compactRowContext.d.ts.map +1 -1
- package/dist/components/form/engine/compactRowContext.js.map +1 -1
- package/dist/components/form/engine/compactRowStyles.d.ts +20 -10
- package/dist/components/form/engine/compactRowStyles.d.ts.map +1 -1
- package/dist/components/form/engine/compactRowStyles.js +36 -30
- package/dist/components/form/engine/compactRowStyles.js.map +1 -1
- package/dist/components/form/engine/compactToolbarColors.d.ts +16 -0
- package/dist/components/form/engine/compactToolbarColors.d.ts.map +1 -0
- package/dist/components/form/engine/compactToolbarColors.js +21 -0
- package/dist/components/form/engine/compactToolbarColors.js.map +1 -0
- package/dist/components/form/engine/readFirst.d.ts +24 -8
- package/dist/components/form/engine/readFirst.d.ts.map +1 -1
- package/dist/components/form/engine/readFirst.js +77 -109
- package/dist/components/form/engine/readFirst.js.map +1 -1
- package/dist/components/form/engine/readFirstColors.d.ts +30 -0
- package/dist/components/form/engine/readFirstColors.d.ts.map +1 -0
- package/dist/components/form/engine/readFirstColors.js +51 -0
- package/dist/components/form/engine/readFirstColors.js.map +1 -0
- package/dist/components/form/engine/rowFocus.d.ts +2 -0
- package/dist/components/form/engine/rowFocus.d.ts.map +1 -1
- package/dist/components/form/engine/rowFocus.js +26 -3
- package/dist/components/form/engine/rowFocus.js.map +1 -1
- package/dist/components/form/engine/typeChoices.d.ts +1 -1
- package/dist/components/form/engine/variants/VariantCalmTable.d.ts.map +1 -1
- package/dist/components/form/engine/variants/VariantCalmTable.js +2 -1
- package/dist/components/form/engine/variants/VariantCalmTable.js.map +1 -1
- package/dist/components/form/engine/variants/VariantCards.d.ts.map +1 -1
- package/dist/components/form/engine/variants/VariantCards.js +2 -1
- package/dist/components/form/engine/variants/VariantCards.js.map +1 -1
- package/dist/components/form/engine/variants/VariantFocus.js +1 -1
- package/dist/components/form/engine/variants/VariantFocus.js.map +1 -1
- package/dist/components/form/engine/variants/VariantMinimal.d.ts.map +1 -1
- package/dist/components/form/engine/variants/VariantMinimal.js +2 -1
- package/dist/components/form/engine/variants/VariantMinimal.js.map +1 -1
- package/dist/components/form/engine/variants/variantParts.d.ts +1 -1
- package/dist/components/form/engine/variants/variantParts.d.ts.map +1 -1
- package/dist/components/form/engine/variants/variantParts.js +25 -17
- package/dist/components/form/engine/variants/variantParts.js.map +1 -1
- package/dist/components/form/expressions/DpqlRendering.d.ts +1 -1
- package/dist/components/form/expressions/DpqlRendering.d.ts.map +1 -1
- package/dist/components/form/expressions/DpqlRendering.js +3 -3
- package/dist/components/form/expressions/DpqlRendering.js.map +1 -1
- package/dist/components/form/expressions/ExpressionField.d.ts +64 -3
- package/dist/components/form/expressions/ExpressionField.d.ts.map +1 -1
- package/dist/components/form/expressions/ExpressionField.js +459 -100
- package/dist/components/form/expressions/ExpressionField.js.map +1 -1
- package/dist/components/form/expressions/argumentPresence.d.ts +14 -0
- package/dist/components/form/expressions/argumentPresence.d.ts.map +1 -1
- package/dist/components/form/expressions/argumentPresence.js +16 -1
- package/dist/components/form/expressions/argumentPresence.js.map +1 -1
- package/dist/components/form/expressions/builder/argumentDetail.d.ts.map +1 -1
- package/dist/components/form/expressions/builder/argumentDetail.js +4 -1
- package/dist/components/form/expressions/builder/argumentDetail.js.map +1 -1
- package/dist/components/form/expressions/builder/argumentLabel.d.ts.map +1 -1
- package/dist/components/form/expressions/builder/argumentLabel.js +27 -9
- package/dist/components/form/expressions/builder/argumentLabel.js.map +1 -1
- package/dist/components/form/expressions/builder/argumentWrapper.d.ts.map +1 -1
- package/dist/components/form/expressions/builder/argumentWrapper.js +3 -1
- package/dist/components/form/expressions/builder/argumentWrapper.js.map +1 -1
- package/dist/components/form/expressions/builder/confirmMismatchedTypesModal.d.ts.map +1 -1
- package/dist/components/form/expressions/builder/confirmMismatchedTypesModal.js +5 -4
- package/dist/components/form/expressions/builder/confirmMismatchedTypesModal.js.map +1 -1
- package/dist/components/form/expressions/builder/confirmUnsupportedTypeModal.d.ts +1 -1
- package/dist/components/form/expressions/builder/confirmUnsupportedTypeModal.d.ts.map +1 -1
- package/dist/components/form/expressions/builder/confirmUnsupportedTypeModal.js +6 -3
- package/dist/components/form/expressions/builder/confirmUnsupportedTypeModal.js.map +1 -1
- package/dist/components/form/expressions/builder/index.d.ts +24 -2
- package/dist/components/form/expressions/builder/index.d.ts.map +1 -1
- package/dist/components/form/expressions/builder/index.js +138 -78
- package/dist/components/form/expressions/builder/index.js.map +1 -1
- package/dist/components/form/expressions/builder/item.d.ts +6 -2
- package/dist/components/form/expressions/builder/item.d.ts.map +1 -1
- package/dist/components/form/expressions/builder/item.js +19 -5
- package/dist/components/form/expressions/builder/item.js.map +1 -1
- package/dist/components/form/expressions/builder/renderTemplate.js +1 -1
- package/dist/components/form/expressions/builder/renderTemplate.js.map +1 -1
- package/dist/components/form/expressions/dpqlMockRecordPath.d.ts +11 -0
- package/dist/components/form/expressions/dpqlMockRecordPath.d.ts.map +1 -0
- package/dist/components/form/expressions/dpqlMockRecordPath.js +254 -0
- package/dist/components/form/expressions/dpqlMockRecordPath.js.map +1 -0
- package/dist/components/form/expressions/expressionOperands.d.ts +16 -0
- package/dist/components/form/expressions/expressionOperands.d.ts.map +1 -0
- package/dist/components/form/expressions/expressionOperands.js +97 -0
- package/dist/components/form/expressions/expressionOperands.js.map +1 -0
- package/dist/components/form/expressions/fieldPath.d.ts +24 -0
- package/dist/components/form/expressions/fieldPath.d.ts.map +1 -0
- package/dist/components/form/expressions/fieldPath.js +152 -0
- package/dist/components/form/expressions/fieldPath.js.map +1 -0
- package/dist/components/form/expressions/mockExpressions.d.ts.map +1 -1
- package/dist/components/form/expressions/mockExpressions.js +22 -5
- package/dist/components/form/expressions/mockExpressions.js.map +1 -1
- package/dist/components/form/expressions/renderExpressionToText.d.ts +2 -0
- package/dist/components/form/expressions/renderExpressionToText.d.ts.map +1 -1
- package/dist/components/form/expressions/renderExpressionToText.js +40 -9
- package/dist/components/form/expressions/renderExpressionToText.js.map +1 -1
- package/dist/components/form/expressions/textOfExpression.d.ts +18 -0
- package/dist/components/form/expressions/textOfExpression.d.ts.map +1 -0
- package/dist/components/form/expressions/textOfExpression.js +49 -0
- package/dist/components/form/expressions/textOfExpression.js.map +1 -0
- package/dist/components/form/expressions/types.d.ts +7 -0
- package/dist/components/form/expressions/types.d.ts.map +1 -1
- package/dist/components/form/expressions/types.js +6 -1
- package/dist/components/form/expressions/types.js.map +1 -1
- package/dist/components/form/expressions/useExpressionType.d.ts +26 -0
- package/dist/components/form/expressions/useExpressionType.d.ts.map +1 -0
- package/dist/components/form/expressions/useExpressionType.js +181 -0
- package/dist/components/form/expressions/useExpressionType.js.map +1 -0
- package/dist/components/form/expressions/useRenderExpression.d.ts.map +1 -1
- package/dist/components/form/expressions/useRenderExpression.js +13 -9
- package/dist/components/form/expressions/useRenderExpression.js.map +1 -1
- package/dist/components/form/expressions/wildcardExpressions.d.ts +27 -0
- package/dist/components/form/expressions/wildcardExpressions.d.ts.map +1 -0
- package/dist/components/form/expressions/wildcardExpressions.js +101 -0
- package/dist/components/form/expressions/wildcardExpressions.js.map +1 -0
- package/dist/components/form/fields/Field.d.ts.map +1 -1
- package/dist/components/form/fields/Field.js +26 -9
- package/dist/components/form/fields/Field.js.map +1 -1
- package/dist/components/form/fields/allowed-values/AllowedValues.d.ts.map +1 -1
- package/dist/components/form/fields/allowed-values/AllowedValues.js +17 -4
- package/dist/components/form/fields/allowed-values/AllowedValues.js.map +1 -1
- package/dist/components/form/fields/array/ArrayAuto.d.ts.map +1 -1
- package/dist/components/form/fields/array/ArrayAuto.js +24 -0
- package/dist/components/form/fields/array/ArrayAuto.js.map +1 -1
- package/dist/components/form/fields/array/ArrayAutoField.d.ts.map +1 -1
- package/dist/components/form/fields/array/ArrayAutoField.js +36 -13
- package/dist/components/form/fields/array/ArrayAutoField.js.map +1 -1
- package/dist/components/form/fields/auto/AutoFormField.d.ts +20 -1
- package/dist/components/form/fields/auto/AutoFormField.d.ts.map +1 -1
- package/dist/components/form/fields/auto/AutoFormField.js +81 -36
- package/dist/components/form/fields/auto/AutoFormField.js.map +1 -1
- package/dist/components/form/fields/auto/hostEditorValue.d.ts +30 -0
- package/dist/components/form/fields/auto/hostEditorValue.d.ts.map +1 -0
- package/dist/components/form/fields/auto/hostEditorValue.js +53 -0
- package/dist/components/form/fields/auto/hostEditorValue.js.map +1 -0
- package/dist/components/form/fields/binary/Binary.d.ts.map +1 -1
- package/dist/components/form/fields/binary/Binary.js +23 -3
- package/dist/components/form/fields/binary/Binary.js.map +1 -1
- package/dist/components/form/fields/boolean/Boolean.d.ts +5 -0
- package/dist/components/form/fields/boolean/Boolean.d.ts.map +1 -1
- package/dist/components/form/fields/boolean/Boolean.js +9 -1
- package/dist/components/form/fields/boolean/Boolean.js.map +1 -1
- package/dist/components/form/fields/color/Color.d.ts +103 -16
- package/dist/components/form/fields/color/Color.d.ts.map +1 -1
- package/dist/components/form/fields/color/Color.js +616 -16
- package/dist/components/form/fields/color/Color.js.map +1 -1
- package/dist/components/form/fields/emittedValues.d.ts +34 -3
- package/dist/components/form/fields/emittedValues.d.ts.map +1 -1
- package/dist/components/form/fields/emittedValues.js +24 -1
- package/dist/components/form/fields/emittedValues.js.map +1 -1
- package/dist/components/form/fields/file/File.d.ts +1 -1
- package/dist/components/form/fields/file/File.d.ts.map +1 -1
- package/dist/components/form/fields/file/File.js +4 -2
- package/dist/components/form/fields/file/File.js.map +1 -1
- package/dist/components/form/fields/long-string/LongString.d.ts.map +1 -1
- package/dist/components/form/fields/long-string/LongString.js +17 -3
- package/dist/components/form/fields/long-string/LongString.js.map +1 -1
- package/dist/components/form/fields/markdown/MarkdownView.js +1 -1
- package/dist/components/form/fields/multi-select/MultiSelectFormField.d.ts.map +1 -1
- package/dist/components/form/fields/multi-select/MultiSelectFormField.js +4 -1
- package/dist/components/form/fields/multi-select/MultiSelectFormField.js.map +1 -1
- package/dist/components/form/fields/number/Number.d.ts +6 -0
- package/dist/components/form/fields/number/Number.d.ts.map +1 -1
- package/dist/components/form/fields/number/Number.js +41 -6
- package/dist/components/form/fields/number/Number.js.map +1 -1
- package/dist/components/form/fields/object/Object.d.ts +1 -1
- package/dist/components/form/fields/object/Object.d.ts.map +1 -1
- package/dist/components/form/fields/object/Object.js +4 -2
- package/dist/components/form/fields/object/Object.js.map +1 -1
- package/dist/components/form/fields/pendingEdit.d.ts +52 -0
- package/dist/components/form/fields/pendingEdit.d.ts.map +1 -0
- package/dist/components/form/fields/pendingEdit.js +79 -0
- package/dist/components/form/fields/pendingEdit.js.map +1 -0
- package/dist/components/form/fields/rich-text/RichText.d.ts +8 -1
- package/dist/components/form/fields/rich-text/RichText.d.ts.map +1 -1
- package/dist/components/form/fields/rich-text/RichText.js +188 -82
- package/dist/components/form/fields/rich-text/RichText.js.map +1 -1
- package/dist/components/form/fields/rich-text/useTemplateTags.d.ts +18 -0
- package/dist/components/form/fields/rich-text/useTemplateTags.d.ts.map +1 -0
- package/dist/components/form/fields/rich-text/useTemplateTags.js +49 -0
- package/dist/components/form/fields/rich-text/useTemplateTags.js.map +1 -0
- package/dist/components/form/fields/schema-definition/CatalogLeafForm.d.ts.map +1 -1
- package/dist/components/form/fields/schema-definition/CatalogLeafForm.js +4 -1
- package/dist/components/form/fields/schema-definition/CatalogLeafForm.js.map +1 -1
- package/dist/components/form/fields/schema-definition/CatalogNodeEditor.d.ts.map +1 -1
- package/dist/components/form/fields/schema-definition/CatalogNodeEditor.js +20 -5
- package/dist/components/form/fields/schema-definition/CatalogNodeEditor.js.map +1 -1
- package/dist/components/form/fields/schema-definition/TableEditor.d.ts.map +1 -1
- package/dist/components/form/fields/schema-definition/TableEditor.js +10 -2
- package/dist/components/form/fields/schema-definition/TableEditor.js.map +1 -1
- package/dist/components/form/fields/schema-definition/index.d.ts.map +1 -1
- package/dist/components/form/fields/schema-definition/index.js +8 -4
- package/dist/components/form/fields/schema-definition/index.js.map +1 -1
- package/dist/components/form/fields/select/Select.d.ts +2 -0
- package/dist/components/form/fields/select/Select.d.ts.map +1 -1
- package/dist/components/form/fields/select/Select.js +19 -10
- package/dist/components/form/fields/select/Select.js.map +1 -1
- package/dist/components/form/fields/select/SelectCollection.d.ts.map +1 -1
- package/dist/components/form/fields/select/SelectCollection.js +8 -2
- package/dist/components/form/fields/select/SelectCollection.js.map +1 -1
- package/dist/components/form/fields/select/unavailableRow.d.ts +23 -0
- package/dist/components/form/fields/select/unavailableRow.d.ts.map +1 -0
- package/dist/components/form/fields/select/unavailableRow.js +55 -0
- package/dist/components/form/fields/select/unavailableRow.js.map +1 -0
- package/dist/components/form/fields/template/ReadOnlyTemplateTag.d.ts +11 -5
- package/dist/components/form/fields/template/ReadOnlyTemplateTag.d.ts.map +1 -1
- package/dist/components/form/fields/template/ReadOnlyTemplateTag.js +13 -5
- package/dist/components/form/fields/template/ReadOnlyTemplateTag.js.map +1 -1
- package/dist/components/form/fields/template/TemplateBrowser.d.ts +22 -0
- package/dist/components/form/fields/template/TemplateBrowser.d.ts.map +1 -0
- package/dist/components/form/fields/template/TemplateBrowser.js +54 -0
- package/dist/components/form/fields/template/TemplateBrowser.js.map +1 -0
- package/dist/components/form/fields/template/TemplateField.d.ts +102 -1
- package/dist/components/form/fields/template/TemplateField.d.ts.map +1 -1
- package/dist/components/form/fields/template/TemplateField.js +572 -85
- package/dist/components/form/fields/template/TemplateField.js.map +1 -1
- package/dist/components/form/fields/template/TemplateText.d.ts +0 -17
- package/dist/components/form/fields/template/TemplateText.d.ts.map +1 -1
- package/dist/components/form/fields/template/TemplateText.js +9 -11
- package/dist/components/form/fields/template/TemplateText.js.map +1 -1
- package/dist/components/form/fields/template/writtenAsText.d.ts +61 -0
- package/dist/components/form/fields/template/writtenAsText.d.ts.map +1 -0
- package/dist/components/form/fields/template/writtenAsText.js +204 -0
- package/dist/components/form/fields/template/writtenAsText.js.map +1 -0
- package/dist/components/form/index.d.ts +10 -0
- package/dist/components/form/index.d.ts.map +1 -1
- package/dist/components/form/index.js +23 -1
- package/dist/components/form/index.js.map +1 -1
- package/dist/components/imageLightbox/ImageLightbox.d.ts.map +1 -1
- package/dist/components/imageLightbox/ImageLightbox.js +19 -7
- package/dist/components/imageLightbox/ImageLightbox.js.map +1 -1
- package/dist/components/log/Log.d.ts.map +1 -1
- package/dist/components/log/Log.js +16 -8
- package/dist/components/log/Log.js.map +1 -1
- package/dist/components/menu/Menu.d.ts.map +1 -1
- package/dist/components/menu/Menu.js +19 -10
- package/dist/components/menu/Menu.js.map +1 -1
- package/dist/components/smartEditor/CompletionMenu.d.ts +43 -0
- package/dist/components/smartEditor/CompletionMenu.d.ts.map +1 -0
- package/dist/components/smartEditor/CompletionMenu.js +196 -0
- package/dist/components/smartEditor/CompletionMenu.js.map +1 -0
- package/dist/components/smartEditor/MarkdownDoc.d.ts +1 -1
- package/dist/components/smartEditor/MarkdownDoc.js +3 -3
- package/dist/components/smartEditor/MarkdownDoc.js.map +1 -1
- package/dist/components/smartEditor/SmartEditor.d.ts.map +1 -1
- package/dist/components/smartEditor/SmartEditor.js +164 -180
- package/dist/components/smartEditor/SmartEditor.js.map +1 -1
- package/dist/components/smartEditor/completionStyle.d.ts +27 -0
- package/dist/components/smartEditor/completionStyle.d.ts.map +1 -0
- package/dist/components/smartEditor/completionStyle.js +68 -0
- package/dist/components/smartEditor/completionStyle.js.map +1 -0
- package/dist/components/smartEditor/index.d.ts +5 -1
- package/dist/components/smartEditor/index.d.ts.map +1 -1
- package/dist/components/smartEditor/index.js +19 -1
- package/dist/components/smartEditor/index.js.map +1 -1
- package/dist/components/smartEditor/templateCompletions.d.ts +18 -0
- package/dist/components/smartEditor/templateCompletions.d.ts.map +1 -0
- package/dist/components/smartEditor/templateCompletions.js +94 -0
- package/dist/components/smartEditor/templateCompletions.js.map +1 -0
- package/dist/components/smartEditor/typedReferences.d.ts +21 -0
- package/dist/components/smartEditor/typedReferences.d.ts.map +1 -0
- package/dist/components/smartEditor/typedReferences.js +82 -0
- package/dist/components/smartEditor/typedReferences.js.map +1 -0
- package/dist/components/smartEditor/types.d.ts +33 -1
- package/dist/components/smartEditor/types.d.ts.map +1 -1
- package/dist/components/smartEditor/useLspAutocomplete.d.ts +32 -0
- package/dist/components/smartEditor/useLspAutocomplete.d.ts.map +1 -1
- package/dist/components/smartEditor/useLspAutocomplete.js +228 -118
- package/dist/components/smartEditor/useLspAutocomplete.js.map +1 -1
- package/dist/components/smartEditor/useLspHover.d.ts +33 -7
- package/dist/components/smartEditor/useLspHover.d.ts.map +1 -1
- package/dist/components/smartEditor/useLspHover.js +279 -35
- package/dist/components/smartEditor/useLspHover.js.map +1 -1
- package/dist/components/smartEditor/useLspSemanticTokens.js +1 -1
- package/dist/components/smartEditor/useLspSemanticTokens.js.map +1 -1
- package/dist/components/smartEditor/useLspSession.d.ts +6 -0
- package/dist/components/smartEditor/useLspSession.d.ts.map +1 -1
- package/dist/components/smartEditor/useLspSession.js +7 -6
- package/dist/components/smartEditor/useLspSession.js.map +1 -1
- package/dist/components/supportTicket/AttachmentChips.d.ts.map +1 -1
- package/dist/components/supportTicket/AttachmentChips.js +15 -5
- package/dist/components/supportTicket/AttachmentChips.js.map +1 -1
- package/dist/components/supportTicket/ReferencePicker.d.ts +9 -2
- package/dist/components/supportTicket/ReferencePicker.d.ts.map +1 -1
- package/dist/components/supportTicket/ReferencePicker.js +27 -6
- package/dist/components/supportTicket/ReferencePicker.js.map +1 -1
- package/dist/components/supportTicket/TicketHeader.d.ts +3 -4
- package/dist/components/supportTicket/TicketHeader.d.ts.map +1 -1
- package/dist/components/supportTicket/TicketHeader.js +20 -2
- package/dist/components/supportTicket/TicketHeader.js.map +1 -1
- package/dist/components/supportTicket/TicketMetaTags.d.ts +1 -1
- package/dist/components/ticketReferences/TicketReferences.d.ts.map +1 -1
- package/dist/components/ticketReferences/TicketReferences.js +9 -4
- package/dist/components/ticketReferences/TicketReferences.js.map +1 -1
- package/dist/components/ticketThread/TicketThread.d.ts.map +1 -1
- package/dist/components/ticketThread/TicketThread.js +38 -13
- package/dist/components/ticketThread/TicketThread.js.map +1 -1
- package/dist/helpers/descriptionTooltip.d.ts +43 -0
- package/dist/helpers/descriptionTooltip.d.ts.map +1 -0
- package/dist/helpers/descriptionTooltip.js +70 -0
- package/dist/helpers/descriptionTooltip.js.map +1 -0
- package/dist/helpers/domProps.d.ts +5 -0
- package/dist/helpers/domProps.d.ts.map +1 -0
- package/dist/helpers/domProps.js +47 -0
- package/dist/helpers/domProps.js.map +1 -0
- package/dist/helpers/expressions.d.ts +107 -2
- package/dist/helpers/expressions.d.ts.map +1 -1
- package/dist/helpers/expressions.js +223 -8
- package/dist/helpers/expressions.js.map +1 -1
- package/dist/helpers/hoveringPointer.d.ts +26 -0
- package/dist/helpers/hoveringPointer.d.ts.map +1 -0
- package/dist/helpers/hoveringPointer.js +29 -0
- package/dist/helpers/hoveringPointer.js.map +1 -0
- package/dist/helpers/markdownText.d.ts +14 -0
- package/dist/helpers/markdownText.d.ts.map +1 -0
- package/dist/helpers/markdownText.js +160 -0
- package/dist/helpers/markdownText.js.map +1 -0
- package/dist/helpers/qorusTypeCatalogue.d.ts +53 -0
- package/dist/helpers/qorusTypeCatalogue.d.ts.map +1 -0
- package/dist/helpers/qorusTypeCatalogue.js +262 -0
- package/dist/helpers/qorusTypeCatalogue.js.map +1 -0
- package/dist/helpers/readableColors.d.ts +36 -0
- package/dist/helpers/readableColors.d.ts.map +1 -0
- package/dist/helpers/readableColors.js +116 -0
- package/dist/helpers/readableColors.js.map +1 -0
- package/dist/helpers/recordFieldReference.d.ts +15 -0
- package/dist/helpers/recordFieldReference.d.ts.map +1 -0
- package/dist/helpers/recordFieldReference.js +89 -0
- package/dist/helpers/recordFieldReference.js.map +1 -0
- package/dist/helpers/templateItems.d.ts +2 -2
- package/dist/helpers/templateItems.d.ts.map +1 -1
- package/dist/helpers/templateItems.js +6 -4
- package/dist/helpers/templateItems.js.map +1 -1
- package/dist/helpers/templateText.js +5 -2
- package/dist/helpers/templateText.js.map +1 -1
- package/dist/helpers/templates.d.ts +41 -14
- package/dist/helpers/templates.d.ts.map +1 -1
- package/dist/helpers/templates.js +152 -9
- package/dist/helpers/templates.js.map +1 -1
- package/dist/helpers/validations.d.ts +9 -0
- package/dist/helpers/validations.d.ts.map +1 -1
- package/dist/helpers/validations.js +139 -33
- package/dist/helpers/validations.js.map +1 -1
- package/dist/hooks/useQorusTypes.d.ts +7 -15
- package/dist/hooks/useQorusTypes.d.ts.map +1 -1
- package/dist/hooks/useQorusTypes.js +25 -166
- package/dist/hooks/useQorusTypes.js.map +1 -1
- package/dist/hooks/useReadableIntentShade.d.ts +9 -0
- package/dist/hooks/useReadableIntentShade.d.ts.map +1 -0
- package/dist/hooks/useReadableIntentShade.js +23 -0
- package/dist/hooks/useReadableIntentShade.js.map +1 -0
- package/dist/hooks/useReadableOpacity.d.ts +6 -0
- package/dist/hooks/useReadableOpacity.d.ts.map +1 -0
- package/dist/hooks/useReadableOpacity.js +17 -0
- package/dist/hooks/useReadableOpacity.js.map +1 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1 -0
- package/dist/index.js.map +1 -1
- package/dist/tracking/ui/ExperimentCard.d.ts +1 -1
- package/dist/tracking/ui/ExperimentCard.d.ts.map +1 -1
- package/dist/tracking/ui/ExperimentCard.js +26 -10
- package/dist/tracking/ui/ExperimentCard.js.map +1 -1
- package/dist/tracking/ui/card.d.ts +2 -2
- package/dist/tracking/ui/card.d.ts.map +1 -1
- package/dist/tracking/ui/card.js +2 -2
- package/dist/tracking/ui/card.js.map +1 -1
- package/dist/tracking/ui/readable.d.ts +14 -0
- package/dist/tracking/ui/readable.d.ts.map +1 -0
- package/dist/tracking/ui/readable.js +60 -0
- package/dist/tracking/ui/readable.js.map +1 -0
- package/dist/utils/fetch.d.ts +9 -2
- package/dist/utils/fetch.d.ts.map +1 -1
- package/dist/utils/fetch.js +6 -5
- package/dist/utils/fetch.js.map +1 -1
- package/dist/utils/websocket.d.ts +65 -2
- package/dist/utils/websocket.d.ts.map +1 -1
- package/dist/utils/websocket.js +276 -44
- package/dist/utils/websocket.js.map +1 -1
- package/package.json +14 -5
- package/.claude/CLAUDE.md +0 -317
- package/.tasks/EXPORT_EXPRESSION_BUILDER.md +0 -38
- package/.tasks/EXPRESSION_BUILDER_REPORT.md +0 -149
- package/.tasks/EXPRESSION_FIELD_SEAMS.md +0 -66
- package/.tasks/FIELD_STACK_REPORT.md +0 -234
- package/.tasks/FORM_ENGINE_COMPACT_READ_FIRST.md +0 -558
- package/.tasks/FORM_ENGINE_EXPRESSIONS.md +0 -197
- package/.tasks/FORM_ENGINE_OPTIONS_SYNC.md +0 -95
- package/.tasks/FORM_FIELD_EXTRAS.md +0 -72
- package/.tasks/INDEX.md +0 -111
- package/.tasks/LSP_SHARED_CONNECTION.md +0 -75
- package/.tasks/QONSOLE_ASSIST_FEATURES.md +0 -306
- package/.tasks/RENDER_EXPRESSION_LSP.md +0 -159
- package/.tasks/REQRAFT_AUTO_FIELD.md +0 -176
- package/.tasks/SCHEMA_DEFINITION_FIELD.md +0 -250
- package/.tasks/SMART_EDITOR_CONTEXT_AND_POLISH.md +0 -340
- package/.tasks/SMART_EDITOR_LSP_FEATURES.md +0 -299
- package/.tasks/SMART_EDITOR_REVIEW_FOLLOWUPS.md +0 -280
- package/.tasks/SMART_EDITOR_UX_POLISH.md +0 -383
- package/.tasks/SMART_EDITOR_VISUAL_POLISH.md +0 -246
- package/.tasks/STORY_NETWORK_ISOLATION.md +0 -98
- package/.tasks/TEMPLATE_TOKEN_GRAMMAR.md +0 -72
- package/CODE_OF_CONDUCT.md +0 -105
- package/CONTRIBUTING.MD +0 -78
- package/SECURITY.md +0 -3
- package/chromatic.config.json +0 -5
- package/design/COMPACT_ENGINE_REDESIGN.md +0 -156
- package/design/COMPACT_INFO_DISPLAY.md +0 -87
- package/design/COMPACT_PARITY.md +0 -85
- package/design/EXPRESSION_BUILDER_REPORT_STRATEGY.md +0 -92
- package/design/FORM_ENGINE_COMPACT.md +0 -300
- package/design/FORM_ENGINE_COMPACT_UX_PLAN.md +0 -353
- package/design/FORM_ENGINE_EXPRESSIONS.md +0 -257
- package/design/FORM_ENGINE_FIELD_MIGRATION.md +0 -419
- package/design/IDE_INTEGRATION.md +0 -64
- package/design/RENDER_EXPRESSION_TRANSPORT.md +0 -156
- package/design/SELECT_DIALOG_FLOOR.md +0 -86
- package/design/SMART_EDITOR_UX.md +0 -438
- package/design/TRACKING.md +0 -290
- package/design/UNAVAILABLE_ALLOWED_VALUES.md +0 -226
- package/src/components/Description/index.tsx +0 -254
- package/src/components/Description/markdownRendererContext.tsx +0 -29
- package/src/components/FocusedEditing/index.tsx +0 -50
- package/src/components/codeSize/index.tsx +0 -79
- package/src/components/composer/Composer.stories.tsx +0 -238
- package/src/components/composer/Composer.tsx +0 -554
- package/src/components/composer/helpers.ts +0 -74
- package/src/components/composer/index.ts +0 -2
- package/src/components/dpqlEditor/DpqlEditor.stories.tsx +0 -1183
- package/src/components/dpqlEditor/DpqlEditor.tsx +0 -219
- package/src/components/dpqlEditor/dpqlHelpers.ts +0 -287
- package/src/components/dpqlEditor/dpqlInserter.ts +0 -121
- package/src/components/dpqlEditor/dpqlProbe.ts +0 -165
- package/src/components/dpqlEditor/dpqlTags.ts +0 -114
- package/src/components/dpqlEditor/index.ts +0 -41
- package/src/components/dpqlEditor/types.ts +0 -203
- package/src/components/dpqlEditor/useDpqlProbe.ts +0 -33
- package/src/components/dpqlEditor/useDpqlSession.ts +0 -411
- package/src/components/form/engine/CompactRow.tsx +0 -2620
- package/src/components/form/engine/CompactToolbar.tsx +0 -330
- package/src/components/form/engine/FormEngine.stories.tsx +0 -9920
- package/src/components/form/engine/FormEngine.tsx +0 -4569
- package/src/components/form/engine/FormEngineRemote.stories.tsx +0 -679
- package/src/components/form/engine/FormEngineStickyHeaders.stories.tsx +0 -331
- package/src/components/form/engine/FormFieldsSkeleton.tsx +0 -82
- package/src/components/form/engine/OptionFieldMessages.tsx +0 -477
- package/src/components/form/engine/OptionsHelpDialog.tsx +0 -29
- package/src/components/form/engine/__fixtures__/basicFormOptions.ts +0 -309
- package/src/components/form/engine/__fixtures__/fieldChromeOptions.ts +0 -45
- package/src/components/form/engine/_structuredData/SchemaDataView.stories.tsx +0 -233
- package/src/components/form/engine/_structuredData/SchemaDataView.tsx +0 -742
- package/src/components/form/engine/_structuredData/StructuredDataView.stories.tsx +0 -85
- package/src/components/form/engine/_structuredData/StructuredDataView.tsx +0 -75
- package/src/components/form/engine/_structuredData/structuredData.ts +0 -145
- package/src/components/form/engine/compactRowContext.ts +0 -148
- package/src/components/form/engine/compactRowStyles.ts +0 -898
- package/src/components/form/engine/compactToolbarContext.ts +0 -69
- package/src/components/form/engine/optionActions.ts +0 -128
- package/src/components/form/engine/optionsContext.ts +0 -24
- package/src/components/form/engine/readFirst.ts +0 -1077
- package/src/components/form/engine/rendererTypes.ts +0 -107
- package/src/components/form/engine/revealRow.ts +0 -123
- package/src/components/form/engine/rowFocus.ts +0 -101
- package/src/components/form/engine/rowMenuContext.ts +0 -159
- package/src/components/form/engine/rowOpenPicker.ts +0 -27
- package/src/components/form/engine/typeChoices.ts +0 -63
- package/src/components/form/engine/variants/FormEngineVariants.stories.tsx +0 -159
- package/src/components/form/engine/variants/VariantCalmTable.tsx +0 -244
- package/src/components/form/engine/variants/VariantCards.tsx +0 -212
- package/src/components/form/engine/variants/VariantFocus.tsx +0 -382
- package/src/components/form/engine/variants/VariantMinimal.tsx +0 -170
- package/src/components/form/engine/variants/focusDemo.ts +0 -145
- package/src/components/form/engine/variants/variantModel.ts +0 -223
- package/src/components/form/engine/variants/variantParts.tsx +0 -313
- package/src/components/form/expressions/DpqlRendering.tsx +0 -85
- package/src/components/form/expressions/ExpressionField.stories.tsx +0 -1395
- package/src/components/form/expressions/ExpressionField.tsx +0 -503
- package/src/components/form/expressions/argumentPresence.ts +0 -213
- package/src/components/form/expressions/builder/ExpressionBuilder.stories.tsx +0 -1683
- package/src/components/form/expressions/builder/argumentDetail.tsx +0 -17
- package/src/components/form/expressions/builder/argumentLabel.tsx +0 -146
- package/src/components/form/expressions/builder/argumentSlot.tsx +0 -101
- package/src/components/form/expressions/builder/argumentWrapper.tsx +0 -243
- package/src/components/form/expressions/builder/confirmMismatchedTypesModal.tsx +0 -120
- package/src/components/form/expressions/builder/confirmUnsupportedTypeModal.tsx +0 -69
- package/src/components/form/expressions/builder/index.tsx +0 -1545
- package/src/components/form/expressions/builder/item.tsx +0 -89
- package/src/components/form/expressions/builder/moveToPositionStrip.tsx +0 -156
- package/src/components/form/expressions/builder/renderTemplate.tsx +0 -42
- package/src/components/form/expressions/dpqlMockLanguage.ts +0 -566
- package/src/components/form/expressions/dpqlMockLsp.ts +0 -126
- package/src/components/form/expressions/mockExpressions.ts +0 -317
- package/src/components/form/expressions/renderExpressionToText.ts +0 -137
- package/src/components/form/expressions/types.ts +0 -110
- package/src/components/form/expressions/useExpressions.ts +0 -101
- package/src/components/form/expressions/useRenderExpression.ts +0 -165
- package/src/components/form/fields/Field.stories.tsx +0 -143
- package/src/components/form/fields/Field.tsx +0 -732
- package/src/components/form/fields/allowed-values/AllowedValues.tsx +0 -297
- package/src/components/form/fields/array/ArrayAuto.tsx +0 -237
- package/src/components/form/fields/array/ArrayAutoField.stories.tsx +0 -475
- package/src/components/form/fields/array/ArrayAutoField.tsx +0 -367
- package/src/components/form/fields/auto/AutoFormField.stories.tsx +0 -825
- package/src/components/form/fields/auto/AutoFormField.tsx +0 -1164
- package/src/components/form/fields/binary/Binary.stories.tsx +0 -122
- package/src/components/form/fields/binary/Binary.tsx +0 -91
- package/src/components/form/fields/boolean/Boolean.stories.tsx +0 -125
- package/src/components/form/fields/boolean/Boolean.tsx +0 -34
- package/src/components/form/fields/byte-size/ByteSize.stories.tsx +0 -87
- package/src/components/form/fields/byte-size/ByteSize.tsx +0 -58
- package/src/components/form/fields/color/Color.stories.tsx +0 -99
- package/src/components/form/fields/color/Color.tsx +0 -46
- package/src/components/form/fields/cron/Cron.stories.tsx +0 -68
- package/src/components/form/fields/cron/Cron.tsx +0 -80
- package/src/components/form/fields/date/Date.stories.tsx +0 -77
- package/src/components/form/fields/date/Date.tsx +0 -55
- package/src/components/form/fields/emittedValues.ts +0 -70
- package/src/components/form/fields/file/File.stories.tsx +0 -161
- package/src/components/form/fields/file/File.tsx +0 -227
- package/src/components/form/fields/long-string/LongString.stories.tsx +0 -120
- package/src/components/form/fields/long-string/LongString.tsx +0 -130
- package/src/components/form/fields/markdown/Markdown.stories.tsx +0 -76
- package/src/components/form/fields/markdown/Markdown.tsx +0 -81
- package/src/components/form/fields/markdown/MarkdownView.tsx +0 -222
- package/src/components/form/fields/multi-select/MultiSelectFormField.tsx +0 -139
- package/src/components/form/fields/number/Number.stories.tsx +0 -159
- package/src/components/form/fields/number/Number.tsx +0 -160
- package/src/components/form/fields/object/Object.stories.tsx +0 -398
- package/src/components/form/fields/object/Object.tsx +0 -255
- package/src/components/form/fields/radio-group/RadioGroup.stories.tsx +0 -95
- package/src/components/form/fields/radio-group/RadioGroup.tsx +0 -46
- package/src/components/form/fields/radio-group/images/java-96x128.png +0 -0
- package/src/components/form/fields/radio-group/images/python-129x128.png +0 -0
- package/src/components/form/fields/radio-group/images/qore-106x128.png +0 -0
- package/src/components/form/fields/rich-text/RichText.stories.tsx +0 -260
- package/src/components/form/fields/rich-text/RichText.tsx +0 -537
- package/src/components/form/fields/schema-definition/CatalogLeafForm.tsx +0 -242
- package/src/components/form/fields/schema-definition/CatalogNodeEditor.tsx +0 -758
- package/src/components/form/fields/schema-definition/Hint.tsx +0 -22
- package/src/components/form/fields/schema-definition/InlineValidationBanner.tsx +0 -138
- package/src/components/form/fields/schema-definition/Loader.tsx +0 -20
- package/src/components/form/fields/schema-definition/MigrationsTab.tsx +0 -187
- package/src/components/form/fields/schema-definition/SchemaDefinitionField.stories.tsx +0 -286
- package/src/components/form/fields/schema-definition/TableEditor.tsx +0 -155
- package/src/components/form/fields/schema-definition/TablesTab.tsx +0 -138
- package/src/components/form/fields/schema-definition/catalog.ts +0 -237
- package/src/components/form/fields/schema-definition/helpers.ts +0 -90
- package/src/components/form/fields/schema-definition/index.tsx +0 -418
- package/src/components/form/fields/schema-definition/mockCatalog.ts +0 -325
- package/src/components/form/fields/schema-definition/mockDefinition.ts +0 -111
- package/src/components/form/fields/schema-definition/referenceSuggestions.tsx +0 -152
- package/src/components/form/fields/schema-definition/starterTemplate.ts +0 -68
- package/src/components/form/fields/schema-definition/types.ts +0 -185
- package/src/components/form/fields/schema-definition/useSchemaOptionCatalog.ts +0 -49
- package/src/components/form/fields/select/Select.stories.tsx +0 -872
- package/src/components/form/fields/select/Select.tsx +0 -624
- package/src/components/form/fields/select/SelectCollection.tsx +0 -594
- package/src/components/form/fields/string/String.stories.tsx +0 -86
- package/src/components/form/fields/string/String.tsx +0 -43
- package/src/components/form/fields/template/ExampleValueModal.stories.tsx +0 -114
- package/src/components/form/fields/template/ExampleValueModal.tsx +0 -99
- package/src/components/form/fields/template/ReadOnlyTemplateTag.tsx +0 -47
- package/src/components/form/fields/template/TemplateField.stories.tsx +0 -1121
- package/src/components/form/fields/template/TemplateField.tsx +0 -1717
- package/src/components/form/fields/template/TemplateText.tsx +0 -115
- package/src/components/form/fields/template/__fixtures__/longExampleValue.ts +0 -7
- package/src/components/form/fields/template/__fixtures__/multiLevelTemplates.json +0 -147
- package/src/components/form/fields/template/__fixtures__/templates.json +0 -83
- package/src/components/form/fields/timeout/Timeout.stories.tsx +0 -228
- package/src/components/form/fields/timeout/Timeout.tsx +0 -87
- package/src/components/form/fields/url/Url.stories.tsx +0 -94
- package/src/components/form/fields/url/Url.tsx +0 -85
- package/src/components/form/index.tsx +0 -47
- package/src/components/imageLightbox/ImageLightbox.stories.tsx +0 -238
- package/src/components/imageLightbox/ImageLightbox.tsx +0 -236
- package/src/components/imageLightbox/index.ts +0 -1
- package/src/components/log/Log.stories.tsx +0 -333
- package/src/components/log/Log.tsx +0 -285
- package/src/components/menu/Menu.stories.tsx +0 -155
- package/src/components/menu/Menu.tsx +0 -312
- package/src/components/qonsoleSmartInput/QonsoleSmartInput.stories.tsx +0 -797
- package/src/components/qonsoleSmartInput/QonsoleSmartInput.tsx +0 -105
- package/src/components/qonsoleSmartInput/index.ts +0 -16
- package/src/components/qonsoleSmartInput/qonsoleInserter.ts +0 -77
- package/src/components/qonsoleSmartInput/types.ts +0 -133
- package/src/components/qonsoleSmartInput/useQonsoleSession.ts +0 -124
- package/src/components/searchFilterBar/SearchFilterBar.stories.tsx +0 -62
- package/src/components/searchFilterBar/SearchFilterBar.tsx +0 -144
- package/src/components/searchFilterBar/index.ts +0 -1
- package/src/components/smartEditor/MarkdownDoc.tsx +0 -190
- package/src/components/smartEditor/SmartEditor.stories.tsx +0 -475
- package/src/components/smartEditor/SmartEditor.tsx +0 -808
- package/src/components/smartEditor/__fixtures__/mockLspServer.ts +0 -205
- package/src/components/smartEditor/helpers.ts +0 -217
- package/src/components/smartEditor/index.ts +0 -35
- package/src/components/smartEditor/styling.ts +0 -45
- package/src/components/smartEditor/types.ts +0 -211
- package/src/components/smartEditor/useLspAutocomplete.ts +0 -758
- package/src/components/smartEditor/useLspDiagnosticDecorations.ts +0 -125
- package/src/components/smartEditor/useLspHover.ts +0 -230
- package/src/components/smartEditor/useLspSemanticTokens.ts +0 -298
- package/src/components/smartEditor/useLspSession.ts +0 -231
- package/src/components/smartEditor/useLspSignatureHelp.ts +0 -198
- package/src/components/supportTicket/AttachmentChips.stories.tsx +0 -171
- package/src/components/supportTicket/AttachmentChips.tsx +0 -147
- package/src/components/supportTicket/InterfaceReferenceTags.stories.tsx +0 -257
- package/src/components/supportTicket/InterfaceReferenceTags.tsx +0 -129
- package/src/components/supportTicket/ReferencePicker.stories.tsx +0 -584
- package/src/components/supportTicket/ReferencePicker.tsx +0 -563
- package/src/components/supportTicket/TicketConversation.stories.tsx +0 -121
- package/src/components/supportTicket/TicketHeader.stories.tsx +0 -183
- package/src/components/supportTicket/TicketHeader.tsx +0 -247
- package/src/components/supportTicket/TicketMetaTags.stories.tsx +0 -103
- package/src/components/supportTicket/TicketMetaTags.tsx +0 -85
- package/src/components/supportTicket/TicketReplyBox.stories.tsx +0 -354
- package/src/components/supportTicket/TicketReplyBox.tsx +0 -150
- package/src/components/supportTicket/__fixtures__/kindMarks.ts +0 -28
- package/src/components/supportTicket/attachmentAccess.ts +0 -97
- package/src/components/supportTicket/fileToAttachment.ts +0 -24
- package/src/components/supportTicket/index.ts +0 -10
- package/src/components/supportTicket/meta.ts +0 -206
- package/src/components/supportTicket/ticketModel.ts +0 -131
- package/src/components/supportTicket/useLoadedImages.ts +0 -73
- package/src/components/ticketReferences/TicketReferences.stories.tsx +0 -315
- package/src/components/ticketReferences/TicketReferences.tsx +0 -906
- package/src/components/ticketReferences/index.ts +0 -2
- package/src/components/ticketThread/TicketThread.stories.tsx +0 -829
- package/src/components/ticketThread/TicketThread.tsx +0 -719
- package/src/components/ticketThread/index.ts +0 -6
- package/src/contexts/FetchContext.tsx +0 -25
- package/src/contexts/ReqraftContext.tsx +0 -9
- package/src/contexts/StorageContext.tsx +0 -33
- package/src/global.d.ts +0 -4
- package/src/helpers/allowedValues.ts +0 -249
- package/src/helpers/choiceChip.ts +0 -227
- package/src/helpers/common.ts +0 -326
- package/src/helpers/dpqlDetection.ts +0 -209
- package/src/helpers/expressions.ts +0 -140
- package/src/helpers/optionUiTypes.ts +0 -199
- package/src/helpers/options.ts +0 -150
- package/src/helpers/providerValue.ts +0 -125
- package/src/helpers/scrollbar.ts +0 -32
- package/src/helpers/singleLineString.ts +0 -61
- package/src/helpers/templateItems.ts +0 -81
- package/src/helpers/templateText.ts +0 -350
- package/src/helpers/templates.ts +0 -602
- package/src/helpers/validations.ts +0 -2085
- package/src/hooks/useArgSchema.ts +0 -37
- package/src/hooks/useCoarsePointer.ts +0 -30
- package/src/hooks/useFetch/useFetch.stories.tsx +0 -379
- package/src/hooks/useFetch/useFetch.tsx +0 -154
- package/src/hooks/usePhoneViewport.ts +0 -34
- package/src/hooks/useQorusTypes.ts +0 -233
- package/src/hooks/useReqraftProperty.ts +0 -16
- package/src/hooks/useStorage/useStorage.stories.tsx +0 -168
- package/src/hooks/useStorage/useStorage.ts +0 -35
- package/src/hooks/useTemplates.ts +0 -123
- package/src/hooks/useValidation.ts +0 -9
- package/src/hooks/useWebSocket/useWebSocket.ts +0 -224
- package/src/hooks/useWebSocket/useWebsocket.stories.tsx +0 -640
- package/src/hooks/useWhyDidYouUpdate.ts +0 -38
- package/src/index.tsx +0 -86
- package/src/providers/FetchProvider.tsx +0 -40
- package/src/providers/ReqraftProvider.tsx +0 -52
- package/src/providers/StorageProvider.tsx +0 -131
- package/src/stores/currentUser/currentUser.stories.tsx +0 -100
- package/src/stores/currentUser/currentUser.tsx +0 -94
- package/src/stories/Data/fileFieldArgSchema.json +0 -86
- package/src/stories/Tests/utils.ts +0 -320
- package/src/stories/storyNetwork.ts +0 -92
- package/src/stories/tracking.tsx +0 -206
- package/src/tracking/browser/attach.ts +0 -186
- package/src/tracking/browser/env.ts +0 -78
- package/src/tracking/core/consent.ts +0 -37
- package/src/tracking/core/engagement.ts +0 -47
- package/src/tracking/core/experiments.ts +0 -258
- package/src/tracking/core/hash.ts +0 -26
- package/src/tracking/core/ids.ts +0 -25
- package/src/tracking/core/observable.ts +0 -23
- package/src/tracking/core/queue.ts +0 -131
- package/src/tracking/core/sections.ts +0 -166
- package/src/tracking/core/storage.ts +0 -69
- package/src/tracking/core/tracker.ts +0 -417
- package/src/tracking/core/types.ts +0 -162
- package/src/tracking/core/utm.ts +0 -23
- package/src/tracking/index.ts +0 -72
- package/src/tracking/markup.ts +0 -17
- package/src/tracking/react/Experiment.tsx +0 -44
- package/src/tracking/react/TrackingProvider.tsx +0 -56
- package/src/tracking/react/hooks.ts +0 -106
- package/src/tracking/react/index.ts +0 -13
- package/src/tracking/testing.ts +0 -108
- package/src/tracking/ui/ExperimentCard.stories.tsx +0 -296
- package/src/tracking/ui/ExperimentCard.tsx +0 -667
- package/src/tracking/ui/ExperimentsOverlay.stories.tsx +0 -155
- package/src/tracking/ui/ExperimentsOverlay.tsx +0 -437
- package/src/tracking/ui/anchor.ts +0 -180
- package/src/tracking/ui/card.ts +0 -464
- package/src/tracking/ui/client.ts +0 -117
- package/src/tracking/ui/index.ts +0 -77
- package/src/tracking/ui/types.ts +0 -110
- package/src/tracking/ui/useExperimentsAdmin.ts +0 -103
- package/src/types/Form.ts +0 -29
- package/src/types.ts +0 -14
- package/src/utils/datetime.ts +0 -10
- package/src/utils/fetch.ts +0 -457
- package/src/utils/lspClient.ts +0 -711
- package/src/utils/lspClient.types.ts +0 -211
- package/src/utils/queryUnlessCancelled.ts +0 -28
- package/src/utils/websocket.ts +0 -293
- package/vite.config.ts +0 -58
- package/vitest.config.ts +0 -69
|
@@ -0,0 +1,262 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.qorusTypeSentenceForm = exports.qorusTypeDisplayName = exports.catalogueTypeName = exports.getQorusTypes = exports.defaultQorusTypes = exports.compactTypesList = void 0;
|
|
4
|
+
exports.compactTypesList = ['richtext', 'float', 'hash', 'list', 'bool', 'date', 'binary'];
|
|
5
|
+
/**
|
|
6
|
+
* reqraft's copy of the server's type catalogue (GET /system/qorus-type-info), used until the server answers: the
|
|
7
|
+
* same types, in the same order, with the same fields. __tests__/qorusTypeCatalogue.test.ts compares it with a
|
|
8
|
+
* recorded response (__tests__/fixtures/qorusTypeInfo.json), so a copy that drifts from the server fails.
|
|
9
|
+
*/
|
|
10
|
+
exports.defaultQorusTypes = [
|
|
11
|
+
{
|
|
12
|
+
name: 'any',
|
|
13
|
+
display_name: 'Any',
|
|
14
|
+
sentence_form: 'any value',
|
|
15
|
+
short_desc: 'Any data type',
|
|
16
|
+
desc: 'Any data type',
|
|
17
|
+
types_accepted: ['any'],
|
|
18
|
+
exact_match: ['any'],
|
|
19
|
+
},
|
|
20
|
+
{
|
|
21
|
+
name: 'context',
|
|
22
|
+
display_name: 'Context',
|
|
23
|
+
sentence_form: "a value of the context's type",
|
|
24
|
+
short_desc: 'The data type is determined by the context value chosen',
|
|
25
|
+
desc: 'The data type is determined by the context value chosen',
|
|
26
|
+
types_accepted: ['any'],
|
|
27
|
+
exact_match: ['any'],
|
|
28
|
+
},
|
|
29
|
+
{
|
|
30
|
+
name: 'string',
|
|
31
|
+
display_name: 'Text',
|
|
32
|
+
sentence_form: 'text',
|
|
33
|
+
short_desc: 'Text',
|
|
34
|
+
desc: 'Text',
|
|
35
|
+
types_accepted: ['any'],
|
|
36
|
+
exact_match: ['string', 'richtext'],
|
|
37
|
+
},
|
|
38
|
+
{
|
|
39
|
+
name: 'richtext',
|
|
40
|
+
display_name: 'Rich text',
|
|
41
|
+
sentence_form: 'formatted text',
|
|
42
|
+
short_desc: 'Text with formatting',
|
|
43
|
+
desc: 'Text with formatting',
|
|
44
|
+
types_accepted: ['any'],
|
|
45
|
+
exact_match: ['string', 'richtext'],
|
|
46
|
+
},
|
|
47
|
+
{
|
|
48
|
+
name: 'int',
|
|
49
|
+
display_name: 'Whole number',
|
|
50
|
+
sentence_form: 'a whole number',
|
|
51
|
+
short_desc: 'A whole number (64-bit)',
|
|
52
|
+
desc: 'A whole number (64-bit)',
|
|
53
|
+
types_accepted: ['int', 'float', 'number'],
|
|
54
|
+
exact_match: ['int', 'float', 'number'],
|
|
55
|
+
},
|
|
56
|
+
{
|
|
57
|
+
name: 'float',
|
|
58
|
+
display_name: 'Number',
|
|
59
|
+
sentence_form: 'a number',
|
|
60
|
+
short_desc: 'A number with a fractional part (double precision)',
|
|
61
|
+
desc: 'A number with a fractional part (double precision)',
|
|
62
|
+
types_accepted: ['float', 'int', 'number'],
|
|
63
|
+
exact_match: ['float', 'int', 'number'],
|
|
64
|
+
},
|
|
65
|
+
{
|
|
66
|
+
name: 'number',
|
|
67
|
+
display_name: 'Exact number',
|
|
68
|
+
sentence_form: 'an exact number',
|
|
69
|
+
short_desc: 'A decimal number kept exactly',
|
|
70
|
+
desc: 'A decimal number kept exactly',
|
|
71
|
+
types_accepted: ['number', 'float', 'int'],
|
|
72
|
+
exact_match: ['number', 'float', 'int'],
|
|
73
|
+
},
|
|
74
|
+
{
|
|
75
|
+
name: 'bool',
|
|
76
|
+
display_name: 'True or false',
|
|
77
|
+
sentence_form: 'true or false',
|
|
78
|
+
short_desc: 'True or false',
|
|
79
|
+
desc: 'True or false',
|
|
80
|
+
types_accepted: ['bool'],
|
|
81
|
+
exact_match: ['bool'],
|
|
82
|
+
},
|
|
83
|
+
{
|
|
84
|
+
name: 'date',
|
|
85
|
+
display_name: 'Date',
|
|
86
|
+
sentence_form: 'a date and time',
|
|
87
|
+
short_desc: 'A date and time',
|
|
88
|
+
desc: 'A date and time',
|
|
89
|
+
types_accepted: ['date'],
|
|
90
|
+
exact_match: ['date'],
|
|
91
|
+
},
|
|
92
|
+
{
|
|
93
|
+
name: 'time',
|
|
94
|
+
display_name: 'Time',
|
|
95
|
+
sentence_form: 'a time of day',
|
|
96
|
+
short_desc: 'A time of day',
|
|
97
|
+
desc: 'A time of day',
|
|
98
|
+
types_accepted: ['date'],
|
|
99
|
+
exact_match: ['date'],
|
|
100
|
+
},
|
|
101
|
+
{
|
|
102
|
+
name: 'binary',
|
|
103
|
+
display_name: 'Binary data',
|
|
104
|
+
sentence_form: 'binary data',
|
|
105
|
+
short_desc: 'Binary data',
|
|
106
|
+
desc: 'Binary data',
|
|
107
|
+
types_accepted: ['binary'],
|
|
108
|
+
exact_match: ['binary'],
|
|
109
|
+
},
|
|
110
|
+
{
|
|
111
|
+
name: 'data',
|
|
112
|
+
display_name: 'Text or binary data',
|
|
113
|
+
sentence_form: 'text or binary data',
|
|
114
|
+
short_desc: 'Text or binary data',
|
|
115
|
+
desc: 'Text or binary data',
|
|
116
|
+
types_accepted: ['string', 'richtext', 'binary', 'data'],
|
|
117
|
+
exact_match: ['string', 'richtext', 'binary', 'data'],
|
|
118
|
+
},
|
|
119
|
+
{
|
|
120
|
+
name: 'hash',
|
|
121
|
+
display_name: 'Key-value pairs (hash)',
|
|
122
|
+
sentence_form: 'key-value pairs (a hash)',
|
|
123
|
+
short_desc: 'Key-value pairs (hash)',
|
|
124
|
+
desc: 'Key-value pairs (a hash): each value is stored under a named key',
|
|
125
|
+
types_accepted: ['hash'],
|
|
126
|
+
exact_match: ['hash'],
|
|
127
|
+
},
|
|
128
|
+
{
|
|
129
|
+
name: 'list',
|
|
130
|
+
display_name: 'List',
|
|
131
|
+
sentence_form: 'a list',
|
|
132
|
+
short_desc: 'List',
|
|
133
|
+
desc: 'List',
|
|
134
|
+
types_accepted: ['list'],
|
|
135
|
+
exact_match: ['list'],
|
|
136
|
+
},
|
|
137
|
+
{
|
|
138
|
+
name: 'rgbcolor',
|
|
139
|
+
display_name: 'Color',
|
|
140
|
+
sentence_form: 'a color',
|
|
141
|
+
short_desc: 'A color: red, green and blue from 0 to 255 and an opacity from 0 to 1',
|
|
142
|
+
desc: 'A color, stored as a hash: r, g and b are integers from 0 to 255, and a is the opacity, from 0 (transparent) to 1 (opaque); a missing or null a is opaque. A hex code such as #ff0000 is not a stored color.',
|
|
143
|
+
types_accepted: ['rgbcolor'],
|
|
144
|
+
exact_match: ['rgbcolor'],
|
|
145
|
+
},
|
|
146
|
+
{
|
|
147
|
+
name: 'workflow',
|
|
148
|
+
display_name: 'Workflow',
|
|
149
|
+
sentence_form: 'a workflow',
|
|
150
|
+
short_desc: 'Qorus workflow',
|
|
151
|
+
desc: 'Qorus workflow',
|
|
152
|
+
types_accepted: ['workflow', 'string', 'richtext'],
|
|
153
|
+
exact_match: ['workflow', 'string', 'richtext'],
|
|
154
|
+
},
|
|
155
|
+
{
|
|
156
|
+
name: 'service',
|
|
157
|
+
display_name: 'Service',
|
|
158
|
+
sentence_form: 'a service',
|
|
159
|
+
short_desc: 'Qorus service',
|
|
160
|
+
desc: 'Qorus service',
|
|
161
|
+
types_accepted: ['service', 'string', 'richtext'],
|
|
162
|
+
exact_match: ['service', 'string', 'richtext'],
|
|
163
|
+
},
|
|
164
|
+
{
|
|
165
|
+
name: 'job',
|
|
166
|
+
display_name: 'Job',
|
|
167
|
+
sentence_form: 'a job',
|
|
168
|
+
short_desc: 'Qorus job',
|
|
169
|
+
desc: 'Qorus job',
|
|
170
|
+
types_accepted: ['job', 'string', 'richtext'],
|
|
171
|
+
exact_match: ['job', 'string', 'richtext'],
|
|
172
|
+
},
|
|
173
|
+
{
|
|
174
|
+
name: 'mapper',
|
|
175
|
+
display_name: 'Mapper',
|
|
176
|
+
sentence_form: 'a mapper',
|
|
177
|
+
short_desc: 'Qorus mapper',
|
|
178
|
+
desc: 'Qorus mapper',
|
|
179
|
+
types_accepted: ['mapper', 'string', 'richtext'],
|
|
180
|
+
exact_match: ['mapper', 'string', 'richtext'],
|
|
181
|
+
},
|
|
182
|
+
{
|
|
183
|
+
name: 'data-provider',
|
|
184
|
+
display_name: 'Data provider',
|
|
185
|
+
sentence_form: 'a data provider',
|
|
186
|
+
short_desc: 'Qorus data provider',
|
|
187
|
+
desc: 'Qorus data provider',
|
|
188
|
+
types_accepted: ['data-provider'],
|
|
189
|
+
exact_match: ['data-provider'],
|
|
190
|
+
},
|
|
191
|
+
{
|
|
192
|
+
name: 'connection',
|
|
193
|
+
display_name: 'Connection',
|
|
194
|
+
sentence_form: 'a connection',
|
|
195
|
+
short_desc: 'Qorus connection',
|
|
196
|
+
desc: 'Qorus connection',
|
|
197
|
+
types_accepted: ['connection', 'string', 'richtext'],
|
|
198
|
+
exact_match: ['connection', 'string', 'richtext'],
|
|
199
|
+
},
|
|
200
|
+
];
|
|
201
|
+
var getQorusTypes = function () { return exports.defaultQorusTypes; };
|
|
202
|
+
exports.getQorusTypes = getQorusTypes;
|
|
203
|
+
/** Qore's other names for a type the catalogue lists under its own (qorus#646). */
|
|
204
|
+
var QORE_TYPE_ALIASES = { boolean: 'bool', integer: 'int' };
|
|
205
|
+
/**
|
|
206
|
+
* A type's name as the catalogue lists it: Qore's other name for a type (`integer`, `boolean`) is the type it names
|
|
207
|
+
* (`int`, `bool`). The server's catalogue knows each type by one name only, and says which it converts by that name.
|
|
208
|
+
*/
|
|
209
|
+
var catalogueTypeName = function (typeName) { var _a; return (_a = QORE_TYPE_ALIASES[typeName]) !== null && _a !== void 0 ? _a : typeName; };
|
|
210
|
+
exports.catalogueTypeName = catalogueTypeName;
|
|
211
|
+
/**
|
|
212
|
+
* The catalogue's entry for a type (the server's catalogue, or reqraft's copy until it answers).
|
|
213
|
+
*
|
|
214
|
+
* The catalogue lists each type once, by its own name, and the catalogue's own entry for a name always wins. A type
|
|
215
|
+
* named another way is the type it is, as the server names it (qorus c6b3fb97c): `boolean` and `integer` are `bool`
|
|
216
|
+
* and `int`; an optional type (`*string`) and a soft one (`softint`, a declaration that converts a value to its base
|
|
217
|
+
* type) are their base type; a complex one (`hash<auto>`, `list<string>`) is its kind. Undefined for a type the
|
|
218
|
+
* catalogue lists under no name.
|
|
219
|
+
*/
|
|
220
|
+
var qorusTypeEntry = function (types, typeName) {
|
|
221
|
+
var _a, _b, _c, _d, _e, _f;
|
|
222
|
+
// a place with no type yet is named by nothing
|
|
223
|
+
if (!typeName) {
|
|
224
|
+
return undefined;
|
|
225
|
+
}
|
|
226
|
+
var listed = function (name) { return types === null || types === void 0 ? void 0 : types.find(function (type) { return type.name === name; }); };
|
|
227
|
+
var base = typeName.replace(/^\*/, '').replace(/<.*$/, '');
|
|
228
|
+
var unsoft = /^soft[a-z]/.test(base) ? base.slice(4) : base;
|
|
229
|
+
return ((_e = (_d = (_b = (_a = listed(typeName)) !== null && _a !== void 0 ? _a : listed(base)) !== null && _b !== void 0 ? _b : listed((_c = QORE_TYPE_ALIASES[base]) !== null && _c !== void 0 ? _c : '')) !== null && _d !== void 0 ? _d : listed(unsoft)) !== null && _e !== void 0 ? _e : listed((_f = QORE_TYPE_ALIASES[unsoft]) !== null && _f !== void 0 ? _f : ''));
|
|
230
|
+
};
|
|
231
|
+
/**
|
|
232
|
+
* What a type is called as a label ("Whole number"), by the type catalogue; a type it lists under no name keeps its
|
|
233
|
+
* name. See `qorusTypeEntry` for the names a type goes by.
|
|
234
|
+
*
|
|
235
|
+
* No type (`undefined` or an empty name: a place whose type is not known yet) has no name: `undefined`, and the
|
|
236
|
+
* caller draws or words its text without one (qorus#646).
|
|
237
|
+
*/
|
|
238
|
+
var qorusTypeDisplayName = function (types, typeName) { var _a, _b; return typeName ? ((_b = (_a = qorusTypeEntry(types, typeName)) === null || _a === void 0 ? void 0 : _a.display_name) !== null && _b !== void 0 ? _b : typeName) : undefined; };
|
|
239
|
+
exports.qorusTypeDisplayName = qorusTypeDisplayName;
|
|
240
|
+
/**
|
|
241
|
+
* What a type is called inside a sentence ("a whole number": "The expression gives a whole number"), by the type
|
|
242
|
+
* catalogue - its sentence form, which the server gives in the language it is asked for (qorus#646, c6b3fb97c).
|
|
243
|
+
*
|
|
244
|
+
* A catalogue with no sentence form for it (a server before c6b3fb97c) gives a wording that needs no article -
|
|
245
|
+
* "a value of type Whole number" - with its display name, or the type's own name where the catalogue lists it under
|
|
246
|
+
* none. An English article is never built from a display name: "a Exact number", "a Whole number" in a sentence
|
|
247
|
+
* of another language.
|
|
248
|
+
*
|
|
249
|
+
* No type (`undefined` or an empty name) has no sentence form: `undefined`, and the caller words its sentence
|
|
250
|
+
* without a type ("This expression gives nothing", "Converted to a whole number") rather than "a value of type
|
|
251
|
+
* undefined" (qorus#646).
|
|
252
|
+
*/
|
|
253
|
+
var qorusTypeSentenceForm = function (types, typeName) {
|
|
254
|
+
var _a;
|
|
255
|
+
if (!typeName) {
|
|
256
|
+
return undefined;
|
|
257
|
+
}
|
|
258
|
+
var entry = qorusTypeEntry(types, typeName);
|
|
259
|
+
return (entry === null || entry === void 0 ? void 0 : entry.sentence_form) || "a value of type ".concat((_a = entry === null || entry === void 0 ? void 0 : entry.display_name) !== null && _a !== void 0 ? _a : typeName);
|
|
260
|
+
};
|
|
261
|
+
exports.qorusTypeSentenceForm = qorusTypeSentenceForm;
|
|
262
|
+
//# sourceMappingURL=qorusTypeCatalogue.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"qorusTypeCatalogue.js","sourceRoot":"","sources":["../../src/helpers/qorusTypeCatalogue.ts"],"names":[],"mappings":";;;AAuBa,QAAA,gBAAgB,GAAG,CAAC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AAC,mCAAI,EAAE,CAAC,mCACrC,MAAM,CAAC,MAAM,CAAC,mCACd,MAAM,CAAC,MAAA,iBAAiB,CAAC,MAAM,CAAC,mCAAI,EAAE,CAAC,CACxC,CAAC;AACJ,CAAC,CAAC;AAEF;;;;;;GAMG;AACI,IAAM,oBAAoB,GAAG,UAClC,KAAqC,EACrC,QAA4B,gBAE5B,OAAA,QAAQ,CAAC,CAAC,CAAC,CAAC,MAAA,MAAA,cAAc,CAAC,KAAK,EAAE,QAAQ,CAAC,0CAAE,YAAY,mCAAI,QAAQ,CAAC,CAAC,CAAC,CAAC,SAAS,CAAA,EAAA,CAAC;AAJxE,QAAA,oBAAoB,wBAIoD;AAErF;;;;;;;;;;;;GAYG;AACI,IAAM,qBAAqB,GAAG,UACnC,KAAqC,EACrC,QAA4B;;IAE5B,IAAI,CAAC,QAAQ,EAAE,CAAC;QACd,OAAO,SAAS,CAAC;IACnB,CAAC;IACD,IAAM,KAAK,GAAG,cAAc,CAAC,KAAK,EAAE,QAAQ,CAAC,CAAC;IAC9C,OAAO,CAAA,KAAK,aAAL,KAAK,uBAAL,KAAK,CAAE,aAAa,KAAI,0BAAmB,MAAA,KAAK,aAAL,KAAK,uBAAL,KAAK,CAAE,YAAY,mCAAI,QAAQ,CAAE,CAAC;AACtF,CAAC,CAAC;AATW,QAAA,qBAAqB,yBAShC"}
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
import { IReqoreTheme } from '@qoretechnologies/reqore/dist/constants/theme';
|
|
2
|
+
/**
|
|
3
|
+
* Colors that stand out from what they are drawn on (WCAG 2.1 AA, qorus#646): 4.5:1 for text, 3:1 for icons and
|
|
4
|
+
* large text. Reqore has these from qoretechnologies/reqore#708 on (`getReadableAccentColorOn`, `getReadableAlpha`);
|
|
5
|
+
* until reqraft builds on that release, the read-first form picks its own colors with these.
|
|
6
|
+
*/
|
|
7
|
+
export declare const READABLE_TEXT = 4.5;
|
|
8
|
+
export declare const READABLE_ICON = 3;
|
|
9
|
+
export declare const READABLE_MARGIN = 0.1;
|
|
10
|
+
/** The WCAG contrast ratio of two opaque colors, unrounded (polished's getContrast rounds 4.495 up to 4.5). */
|
|
11
|
+
export declare const contrastRatio: (a: string, b: string) => number;
|
|
12
|
+
/**
|
|
13
|
+
* `color` in the shade of it that stands out by `minContrast` from every one of `backgrounds` (opaque): the color
|
|
14
|
+
* itself when it does, else moved toward white or black - whichever stands out more from the worst of them - only
|
|
15
|
+
* as far as it takes. The hue is kept: a warning stays amber, only lighter on a dark surface. `alpha` is how faded
|
|
16
|
+
* it is drawn: a mark that something else draws at 70% (reqore's panel and button icons) needs a stronger shade.
|
|
17
|
+
*/
|
|
18
|
+
export declare const getReadableShade: (color: string, backgrounds: string[], minContrast?: number, alpha?: number) => string;
|
|
19
|
+
/**
|
|
20
|
+
* How faded `color` can be drawn on every one of `backgrounds` (opaque) and still stand out by `minContrast`:
|
|
21
|
+
* `alpha`, or as little more as it takes (1 when even that does not).
|
|
22
|
+
*/
|
|
23
|
+
export declare const getReadableOpacity: (color: string, backgrounds: string[], alpha: number, minContrast?: number) => number;
|
|
24
|
+
/** A translucent `color` (rgba) at `alpha` that still stands out from `backgrounds` (see `getReadableOpacity`). */
|
|
25
|
+
export declare const getReadableFaded: (color: string, backgrounds: string[], alpha: number, minContrast?: number) => string;
|
|
26
|
+
/**
|
|
27
|
+
* What reqraft's components are drawn on in `theme`: its background, and a shade darker and lighter, as the page
|
|
28
|
+
* or a panel around them may be.
|
|
29
|
+
*/
|
|
30
|
+
export declare const getThemeSurfaces: (theme: IReqoreTheme) => string[];
|
|
31
|
+
/**
|
|
32
|
+
* How faded the theme's text can be drawn (`opacity`, a softer note) and still read on what it is drawn on in
|
|
33
|
+
* the theme (`getThemeSurfaces`): `opacity`, or as little more as it takes. An icon needs 3:1 (`READABLE_ICON`).
|
|
34
|
+
*/
|
|
35
|
+
export declare const getReadableTextOpacity: (theme: IReqoreTheme, opacity: number, minContrast?: number) => number;
|
|
36
|
+
//# sourceMappingURL=readableColors.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"readableColors.d.ts","sourceRoot":"","sources":["../../src/helpers/readableColors.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,+CAA+C,CAAC;AAS7E;;;;GAIG;AACH,eAAO,MAAM,aAAa,MAAM,CAAC;AACjC,eAAO,MAAM,aAAa,IAAI,CAAC;AAI/B,eAAO,MAAM,eAAe,MAAM,CAAC;AAEnC,+GAA+G;AAC/G,eAAO,MAAM,aAAa,MAAO,MAAM,KAAK,MAAM,KAAG,MAIpD,CAAC;AAYF;;;;;GAKG;AACH,eAAO,MAAM,gBAAgB,UACpB,MAAM,eACA,MAAM,EAAE,gBACR,MAAM,UACZ,MAAM,KACZ,MA0BF,CAAC;AAEF;;;GAGG;AACH,eAAO,MAAM,kBAAkB,UACtB,MAAM,eACA,MAAM,EAAE,SACd,MAAM,gBACA,MAAM,KAClB,MA6BF,CAAC;AAEF,mHAAmH;AACnH,eAAO,MAAM,gBAAgB,UACpB,MAAM,eACA,MAAM,EAAE,SACd,MAAM,gBACA,MAAM,KAClB,MAAiF,CAAC;AAErF;;;GAGG;AACH,eAAO,MAAM,gBAAgB,UAAW,YAAY,KAAG,MAAM,EAI5D,CAAC;AAEF;;;GAGG;AACH,eAAO,MAAM,sBAAsB,UAC1B,YAAY,WACV,MAAM,gBACF,MAAM,KAClB,MACyF,CAAC"}
|
|
@@ -0,0 +1,116 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.getReadableTextOpacity = exports.getThemeSurfaces = exports.getReadableFaded = exports.getReadableOpacity = exports.getReadableShade = exports.contrastRatio = exports.READABLE_MARGIN = exports.READABLE_ICON = exports.READABLE_TEXT = void 0;
|
|
4
|
+
var colors_1 = require("@qoretechnologies/reqore/dist/helpers/colors");
|
|
5
|
+
var polished_1 = require("polished");
|
|
6
|
+
/**
|
|
7
|
+
* Colors that stand out from what they are drawn on (WCAG 2.1 AA, qorus#646): 4.5:1 for text, 3:1 for icons and
|
|
8
|
+
* large text. Reqore has these from qoretechnologies/reqore#708 on (`getReadableAccentColorOn`, `getReadableAlpha`);
|
|
9
|
+
* until reqraft builds on that release, the read-first form picks its own colors with these.
|
|
10
|
+
*/
|
|
11
|
+
exports.READABLE_TEXT = 4.5;
|
|
12
|
+
exports.READABLE_ICON = 3;
|
|
13
|
+
/* A browser blends a color a shade differently (alphas in 255ths, its own rounding): a color that just reaches the
|
|
14
|
+
ratio here can fall a hair short on the page, so these aim a little past it. */
|
|
15
|
+
exports.READABLE_MARGIN = 0.1;
|
|
16
|
+
/** The WCAG contrast ratio of two opaque colors, unrounded (polished's getContrast rounds 4.495 up to 4.5). */
|
|
17
|
+
var contrastRatio = function (a, b) {
|
|
18
|
+
var _a = [(0, polished_1.getLuminance)(a), (0, polished_1.getLuminance)(b)].sort(function (x, y) { return y - x; }), light = _a[0], dark = _a[1];
|
|
19
|
+
return (light + 0.05) / (dark + 0.05);
|
|
20
|
+
};
|
|
21
|
+
exports.contrastRatio = contrastRatio;
|
|
22
|
+
/** `color` at `alpha` drawn over the opaque `background`. */
|
|
23
|
+
var drawnAt = function (color, alpha, background) {
|
|
24
|
+
return (0, polished_1.mix)(alpha, color, background);
|
|
25
|
+
};
|
|
26
|
+
/* how `color` stands out from the least contrasting of `backgrounds`, drawn on each at `alpha` */
|
|
27
|
+
var worst = function (color, backgrounds, alpha) {
|
|
28
|
+
if (alpha === void 0) { alpha = 1; }
|
|
29
|
+
return Math.min.apply(Math, backgrounds.map(function (background) { return (0, exports.contrastRatio)(drawnAt(color, alpha, background), background); }));
|
|
30
|
+
};
|
|
31
|
+
/**
|
|
32
|
+
* `color` in the shade of it that stands out by `minContrast` from every one of `backgrounds` (opaque): the color
|
|
33
|
+
* itself when it does, else moved toward white or black - whichever stands out more from the worst of them - only
|
|
34
|
+
* as far as it takes. The hue is kept: a warning stays amber, only lighter on a dark surface. `alpha` is how faded
|
|
35
|
+
* it is drawn: a mark that something else draws at 70% (reqore's panel and button icons) needs a stronger shade.
|
|
36
|
+
*/
|
|
37
|
+
var getReadableShade = function (color, backgrounds, minContrast, alpha) {
|
|
38
|
+
if (minContrast === void 0) { minContrast = exports.READABLE_TEXT; }
|
|
39
|
+
if (alpha === void 0) { alpha = 1; }
|
|
40
|
+
var target = minContrast + exports.READABLE_MARGIN;
|
|
41
|
+
if (worst(color, backgrounds, alpha) >= target) {
|
|
42
|
+
return color;
|
|
43
|
+
}
|
|
44
|
+
var toward = worst('#ffffff', backgrounds, alpha) >= worst('#000000', backgrounds, alpha) ?
|
|
45
|
+
'#ffffff'
|
|
46
|
+
: '#000000';
|
|
47
|
+
// the least of `toward` mixed in that reaches the ratio: halve the range until it is a hundredth wide
|
|
48
|
+
var low = 0;
|
|
49
|
+
var high = 1;
|
|
50
|
+
while (high - low > 0.01) {
|
|
51
|
+
var middle = (low + high) / 2;
|
|
52
|
+
if (worst((0, polished_1.mix)(middle, toward, color), backgrounds, alpha) >= target) {
|
|
53
|
+
high = middle;
|
|
54
|
+
}
|
|
55
|
+
else {
|
|
56
|
+
low = middle;
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
|
+
return (0, polished_1.mix)(high, toward, color);
|
|
60
|
+
};
|
|
61
|
+
exports.getReadableShade = getReadableShade;
|
|
62
|
+
/**
|
|
63
|
+
* How faded `color` can be drawn on every one of `backgrounds` (opaque) and still stand out by `minContrast`:
|
|
64
|
+
* `alpha`, or as little more as it takes (1 when even that does not).
|
|
65
|
+
*/
|
|
66
|
+
var getReadableOpacity = function (color, backgrounds, alpha, minContrast) {
|
|
67
|
+
if (minContrast === void 0) { minContrast = exports.READABLE_TEXT; }
|
|
68
|
+
var target = minContrast + exports.READABLE_MARGIN;
|
|
69
|
+
var reads = function (at) {
|
|
70
|
+
return backgrounds.every(function (background) { return (0, exports.contrastRatio)(drawnAt(color, at, background), background) >= target; });
|
|
71
|
+
};
|
|
72
|
+
if (alpha >= 1 || reads(alpha)) {
|
|
73
|
+
return alpha;
|
|
74
|
+
}
|
|
75
|
+
if (!reads(1)) {
|
|
76
|
+
return 1;
|
|
77
|
+
}
|
|
78
|
+
var low = alpha;
|
|
79
|
+
var high = 1;
|
|
80
|
+
while (high - low > 0.005) {
|
|
81
|
+
var middle = (low + high) / 2;
|
|
82
|
+
if (reads(middle)) {
|
|
83
|
+
high = middle;
|
|
84
|
+
}
|
|
85
|
+
else {
|
|
86
|
+
low = middle;
|
|
87
|
+
}
|
|
88
|
+
}
|
|
89
|
+
return Math.min(1, Math.ceil(high * 100) / 100);
|
|
90
|
+
};
|
|
91
|
+
exports.getReadableOpacity = getReadableOpacity;
|
|
92
|
+
/** A translucent `color` (rgba) at `alpha` that still stands out from `backgrounds` (see `getReadableOpacity`). */
|
|
93
|
+
var getReadableFaded = function (color, backgrounds, alpha, minContrast) {
|
|
94
|
+
if (minContrast === void 0) { minContrast = exports.READABLE_TEXT; }
|
|
95
|
+
return (0, polished_1.rgba)(color, (0, exports.getReadableOpacity)(color, backgrounds, alpha, minContrast));
|
|
96
|
+
};
|
|
97
|
+
exports.getReadableFaded = getReadableFaded;
|
|
98
|
+
/**
|
|
99
|
+
* What reqraft's components are drawn on in `theme`: its background, and a shade darker and lighter, as the page
|
|
100
|
+
* or a panel around them may be.
|
|
101
|
+
*/
|
|
102
|
+
var getThemeSurfaces = function (theme) {
|
|
103
|
+
var page = (0, colors_1.getMainBackgroundColor)(theme);
|
|
104
|
+
return [(0, colors_1.changeDarkness)(page, 0.05), page, (0, colors_1.changeLightness)(page, 0.05)];
|
|
105
|
+
};
|
|
106
|
+
exports.getThemeSurfaces = getThemeSurfaces;
|
|
107
|
+
/**
|
|
108
|
+
* How faded the theme's text can be drawn (`opacity`, a softer note) and still read on what it is drawn on in
|
|
109
|
+
* the theme (`getThemeSurfaces`): `opacity`, or as little more as it takes. An icon needs 3:1 (`READABLE_ICON`).
|
|
110
|
+
*/
|
|
111
|
+
var getReadableTextOpacity = function (theme, opacity, minContrast) {
|
|
112
|
+
if (minContrast === void 0) { minContrast = exports.READABLE_TEXT; }
|
|
113
|
+
return (0, exports.getReadableOpacity)((0, colors_1.getReadableColor)(theme), (0, exports.getThemeSurfaces)(theme), opacity, minContrast);
|
|
114
|
+
};
|
|
115
|
+
exports.getReadableTextOpacity = getReadableTextOpacity;
|
|
116
|
+
//# sourceMappingURL=readableColors.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"readableColors.js","sourceRoot":"","sources":["../../src/helpers/readableColors.ts"],"names":[],"mappings":";;;AACA,uEAKsD;AACtD,qCAAmD;AAEnD;;;;GAIG;AACU,QAAA,aAAa,GAAG,GAAG,CAAC;AACpB,QAAA,aAAa,GAAG,CAAC,CAAC;AAE/B;kFACkF;AACrE,QAAA,eAAe,GAAG,GAAG,CAAC;AAEnC,+GAA+G;AACxG,IAAM,aAAa,GAAG,UAAC,CAAS,EAAE,CAAS;IAC1C,IAAA,KAAgB,CAAC,IAAA,uBAAY,EAAC,CAAC,CAAC,EAAE,IAAA,uBAAY,EAAC,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,UAAC,CAAC,EAAE,CAAC,IAAK,OAAA,CAAC,GAAG,CAAC,EAAL,CAAK,CAAC,EAAvE,KAAK,QAAA,EAAE,IAAI,QAA4D,CAAC;IAE/E,OAAO,CAAC,KAAK,GAAG,IAAI,CAAC,GAAG,CAAC,IAAI,GAAG,IAAI,CAAC,CAAC;AACxC,CAAC,CAAC;AAJW,QAAA,aAAa,iBAIxB;AAEF,6DAA6D;AAC7D,IAAM,OAAO,GAAG,UAAC,KAAa,EAAE,KAAa,EAAE,UAAkB;IAC/D,OAAA,IAAA,cAAG,EAAC,KAAK,EAAE,KAAK,EAAE,UAAU,CAAC;AAA7B,CAA6B,CAAC;AAEhC,kGAAkG;AAClG,IAAM,KAAK,GAAG,UAAC,KAAa,EAAE,WAAqB,EAAE,KAAiB;IAAjB,sBAAA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gB,GAAG,UAC9B,KAAa,EACb,WAAqB,EACrB,KAAa,EACb,WAAmC;IAAnC,4BAAA,EAAA,cAAsB,qBAAa;IACxB,OAAA,IAAA,eAAI,EAAC,KAAK,EAAE,IAAA,0BAAkB,EAAC,KAAK,EAAE,WAAW,EAAE,KAAK,EAAE,WAAW,CAAC,CAAC;AAAvE,CAAuE,CAAC;AALxE,QAAA,gBAAgB,oBAKwD;AAErF;;;GAGG;AACI,IAAM,gBAAgB,GAAG,UAAC,KAAmB;IAClD,IAAM,IAAI,GAAG,IAAA,+BAAsB,EAAC,KAAK,CAAC,CAAC;IAE3C,OAAO,CAAC,IAAA,uBAAc,EAAC,IAAI,EAAE,IAAI,CAAC,EAAE,IAAI,EAAE,IAAA,wBAAe,EAAC,IAAI,EAAE,IAAI,CAAC,CAAC,CAAC;AACzE,CAAC,CAAC;AAJW,QAAA,gBAAgB,oBAI3B;AAEF;;;GAGG;AACI,IAAM,sBAAsB,GAAG,UACpC,KAAmB,EACnB,OAAe,EACf,WAAmC;IAAnC,4BAAA,EAAA,cAAsB,qBAAa;IAEnC,OAAA,IAAA,0BAAkB,EAAC,IAAA,yBAAgB,EAAC,KAAK,CAAC,EAAE,IAAA,wBAAgB,EAAC,KAAK,CAAC,EAAE,OAAO,EAAE,WAAW,CAAC;AAA1F,CAA0F,CAAC;AALhF,QAAA,sBAAsB,0BAK0D"}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The record field reference at the start of `text` - `@pos`, `@"create.order-id"`, `@orders[*].id` - read as the
|
|
3
|
+
* template the server gives it (`$record:{create.order-id}`, `$record:{orders[*].id}`) and the length it takes, or
|
|
4
|
+
* undefined where there is none.
|
|
5
|
+
*/
|
|
6
|
+
export declare const readRecordReference: (text: string) => {
|
|
7
|
+
template: string;
|
|
8
|
+
length: number;
|
|
9
|
+
} | undefined;
|
|
10
|
+
/**
|
|
11
|
+
* The `$record:{…}` template a field reference stands for, when `reference` is exactly one field reference
|
|
12
|
+
* (`@orders[*].id` is `$record:{orders[*].id}`), or undefined.
|
|
13
|
+
*/
|
|
14
|
+
export declare const recordTemplateOfReference: (reference: string) => string | undefined;
|
|
15
|
+
//# sourceMappingURL=recordFieldReference.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"recordFieldReference.d.ts","sourceRoot":"","sources":["../../src/helpers/recordFieldReference.ts"],"names":[],"mappings":"AA2BA;;;;GAIG;AACH,eAAO,MAAM,mBAAmB,SACxB,MAAM,KACX;IAAE,QAAQ,EAAE,MAAM,CAAC;IAAC,MAAM,EAAE,MAAM,CAAA;CAAE,GAAG,SA0CzC,CAAC;AAEF;;;GAGG;AACH,eAAO,MAAM,yBAAyB,cAAe,MAAM,KAAG,MAAM,GAAG,SAGtE,CAAC"}
|
|
@@ -0,0 +1,89 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// Copyright 2026 Qore Technologies, s.r.o.
|
|
3
|
+
// A record field reference in DPQL text - `@pos`, `@"create.order-id"`, `@orders[*].id` - read as the `$record:{…}`
|
|
4
|
+
// template it stands for (qorus#646). Qorus reads `$record:{<path>}` as a test path (`QorusRecordPath`), and its DPQL
|
|
5
|
+
// serializer writes the same path after `@` (qore#5480: dots separate the parts of a name, quoted or bare, and a dot
|
|
6
|
+
// that is part of a key is `\.`). A field written in DPQL and the template a value holds are one record field, so they
|
|
7
|
+
// are drawn as one chip; and the stories' stand-in for the server reads the reference back to the template with this.
|
|
8
|
+
// Pure: no React, no transport.
|
|
9
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
10
|
+
exports.recordTemplateOfReference = exports.readRecordReference = void 0;
|
|
11
|
+
/**
|
|
12
|
+
* The text in the braces of a template that decodes to `path`, as the Qorus IDE writes it (`recordTemplateOf`):
|
|
13
|
+
* every backslash and every brace is escaped, except the hash wildcard `{*}`. `Unit.Price` under `create` (the path
|
|
14
|
+
* `create.Unit\.Price`) is `$record:{create.Unit\\.Price}`.
|
|
15
|
+
*/
|
|
16
|
+
var recordTemplateText = function (path) {
|
|
17
|
+
return path.replace(/\{\*\}|[\\{}]/g, function (found) { return (found === '{*}' ? found : "\\".concat(found)); });
|
|
18
|
+
};
|
|
19
|
+
/** A key of a test path: a dot, a bracket, a brace or a backslash in it is escaped. */
|
|
20
|
+
var testPathKey = function (key) { return key.replace(/[.[{\\]/g, function (ch) { return "\\".concat(ch); }); };
|
|
21
|
+
/** The accessors a field reference may be followed by, as `dpql/parse` reads them. */
|
|
22
|
+
var ACCESSOR = /^(?:\[\*\]|\[\d+\]|\{\*\}|\.[\p{L}_](?:[\p{L}\p{M}\p{N}_]|-[a-zA-Z])*|\{"(?:\\.|[^"\\])*"\}|\{[A-Za-z_]\w*\})/u;
|
|
23
|
+
/** A field reference, bare or quoted, at the start of a text. */
|
|
24
|
+
var FIELD_REFERENCE = /^@(?:"((?:\\.|[^"\\])*)"|([\p{L}_][\p{L}\p{M}\p{N}_]*(?:\.[\p{L}\p{M}\p{N}_]+)*))/u;
|
|
25
|
+
/**
|
|
26
|
+
* The record field reference at the start of `text` - `@pos`, `@"create.order-id"`, `@orders[*].id` - read as the
|
|
27
|
+
* template the server gives it (`$record:{create.order-id}`, `$record:{orders[*].id}`) and the length it takes, or
|
|
28
|
+
* undefined where there is none.
|
|
29
|
+
*/
|
|
30
|
+
var readRecordReference = function (text) {
|
|
31
|
+
var match = FIELD_REFERENCE.exec(text);
|
|
32
|
+
if (!match)
|
|
33
|
+
return undefined;
|
|
34
|
+
var path;
|
|
35
|
+
if (match[1] !== undefined) {
|
|
36
|
+
// a quoted name: dots separate its parts, `\.` is a dot of a key, `\"` and `\\` are a quote and a backslash
|
|
37
|
+
var keys = [];
|
|
38
|
+
var key = '';
|
|
39
|
+
var quoted = match[1];
|
|
40
|
+
for (var i = 0; i < quoted.length; ++i) {
|
|
41
|
+
var ch = quoted[i];
|
|
42
|
+
if (ch === '\\' && i + 1 < quoted.length) {
|
|
43
|
+
key += quoted[++i];
|
|
44
|
+
}
|
|
45
|
+
else if (ch === '.') {
|
|
46
|
+
keys.push(key);
|
|
47
|
+
key = '';
|
|
48
|
+
}
|
|
49
|
+
else
|
|
50
|
+
key += ch;
|
|
51
|
+
}
|
|
52
|
+
keys.push(key);
|
|
53
|
+
path = keys.map(testPathKey).join('.');
|
|
54
|
+
}
|
|
55
|
+
else {
|
|
56
|
+
path = match[2];
|
|
57
|
+
}
|
|
58
|
+
var length = match[0].length;
|
|
59
|
+
for (var rest = text.slice(length), accessor = ACCESSOR.exec(rest); accessor;) {
|
|
60
|
+
var written = accessor[0];
|
|
61
|
+
if (written.startsWith('[') || written === '{*}') {
|
|
62
|
+
path += written;
|
|
63
|
+
}
|
|
64
|
+
else if (written.startsWith('.')) {
|
|
65
|
+
path += written;
|
|
66
|
+
}
|
|
67
|
+
else {
|
|
68
|
+
var key = written.startsWith('{"') ?
|
|
69
|
+
JSON.parse(written.slice(1, -1))
|
|
70
|
+
: written.slice(1, -1);
|
|
71
|
+
path += ".".concat(testPathKey(key));
|
|
72
|
+
}
|
|
73
|
+
length += written.length;
|
|
74
|
+
rest = text.slice(length);
|
|
75
|
+
accessor = ACCESSOR.exec(rest);
|
|
76
|
+
}
|
|
77
|
+
return { template: "$record:{".concat(recordTemplateText(path), "}"), length: length };
|
|
78
|
+
};
|
|
79
|
+
exports.readRecordReference = readRecordReference;
|
|
80
|
+
/**
|
|
81
|
+
* The `$record:{…}` template a field reference stands for, when `reference` is exactly one field reference
|
|
82
|
+
* (`@orders[*].id` is `$record:{orders[*].id}`), or undefined.
|
|
83
|
+
*/
|
|
84
|
+
var recordTemplateOfReference = function (reference) {
|
|
85
|
+
var read = (0, exports.readRecordReference)(reference);
|
|
86
|
+
return read && read.length === reference.length ? read.template : undefined;
|
|
87
|
+
};
|
|
88
|
+
exports.recordTemplateOfReference = recordTemplateOfReference;
|
|
89
|
+
//# sourceMappingURL=recordFieldReference.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"recordFie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C,EAAE,CAAC,CAAC,CAAC,CAAY;gBAC9C,CAAC,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC;YACzB,IAAI,IAAI,WAAI,WAAW,CAAC,GAAG,CAAC,CAAE,CAAC;QACjC,CAAC;QACD,MAAM,IAAI,OAAO,CAAC,MAAM,CAAC;QACzB,IAAI,GAAG,IAAI,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC;QAC1B,QAAQ,GAAG,QAAQ,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;IACjC,CAAC;IACD,OAAO,EAAE,QAAQ,EAAE,mBAAY,kBAAkB,CAAC,IAAI,CAAC,MAAG,EAAE,MAAM,QAAA,EAAE,CAAC;AACvE,CAAC,CAAC;AA5CW,QAAA,mBAAmB,uBA4C9B;AAEF;;;GAGG;AACI,IAAM,yBAAyB,GAAG,UAAC,SAAiB;IACzD,IAAM,IAAI,GAAG,IAAA,2BAAmB,EAAC,SAAS,CAAC,CAAC;IAC5C,OAAO,IAAI,IAAI,IAAI,CAAC,MAAM,KAAK,SAAS,CAAC,MAAM,CAAC,CAAC,CAAC,IAAI,CAAC,QAAQ,CAAC,CAAC,CAAC,SAAS,CAAC;AAC9E,CAAC,CAAC;AAHW,QAAA,yBAAyB,6BAGpC"}
|
|
@@ -40,8 +40,8 @@ export declare const templateItemsToShow: <T>(items: T[] | undefined) => T[] | u
|
|
|
40
40
|
* description into a `ReqoreTextEffect` and styled-components filters the prop
|
|
41
41
|
* off the DOM.
|
|
42
42
|
*
|
|
43
|
-
* Without a host renderer
|
|
44
|
-
*
|
|
43
|
+
* Without a host renderer a description reads as the prose its markdown renders
|
|
44
|
+
* to (`markdownToProse`): the words, none of the marks, on the row's one line.
|
|
45
45
|
*/
|
|
46
46
|
export declare const renderTemplateItemDescriptions: <T>(items: T[] | undefined, render: TMarkdownRenderer | undefined) => T[] | undefined;
|
|
47
47
|
//# sourceMappingURL=templateItems.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"templateItems.d.ts","sourceRoot":"","sources":["../../src/helpers/templateItems.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,mDAAmD,CAAC;
|
|
1
|
+
{"version":3,"file":"templateItems.d.ts","sourceRoot":"","sources":["../../src/helpers/templateItems.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,mDAAmD,CAAC;AAG3F;;;;;;;;;;;;;;;;;GAiBG;AACH,eAAO,MAAM,mBAAmB,aAAe,CAAC,EAAE,GAAG,SAAS,KAAG,CAAC,EAAE,GAAG,SAMtE,CAAC;AAEF;;;;;;;;;;;;;;;;;;;;;;;;GAwBG;AACH,eAAO,MAAM,8BAA8B,aAClC,CAAC,EAAE,GAAG,SAAS,UACd,iBAAiB,GAAG,SAAS,KACpC,CAAC,EAAE,GAAG,SAyBR,CAAC"}
|
|
@@ -12,6 +12,7 @@ var __assign = (this && this.__assign) || function () {
|
|
|
12
12
|
};
|
|
13
13
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
14
14
|
exports.renderTemplateItemDescriptions = exports.templateItemsToShow = void 0;
|
|
15
|
+
var markdownText_1 = require("./markdownText");
|
|
15
16
|
/**
|
|
16
17
|
* What a template picker should actually list.
|
|
17
18
|
*
|
|
@@ -60,11 +61,11 @@ exports.templateItemsToShow = templateItemsToShow;
|
|
|
60
61
|
* description into a `ReqoreTextEffect` and styled-components filters the prop
|
|
61
62
|
* off the DOM.
|
|
62
63
|
*
|
|
63
|
-
* Without a host renderer
|
|
64
|
-
*
|
|
64
|
+
* Without a host renderer a description reads as the prose its markdown renders
|
|
65
|
+
* to (`markdownToProse`): the words, none of the marks, on the row's one line.
|
|
65
66
|
*/
|
|
66
67
|
var renderTemplateItemDescriptions = function (items, render) {
|
|
67
|
-
if (!
|
|
68
|
+
if (!(items === null || items === void 0 ? void 0 : items.length)) {
|
|
68
69
|
return items;
|
|
69
70
|
}
|
|
70
71
|
return items.map(function (item) {
|
|
@@ -74,7 +75,8 @@ var renderTemplateItemDescriptions = function (items, render) {
|
|
|
74
75
|
/* `compact`, for the reason the context gives: a row is a constrained
|
|
75
76
|
container, and markdown authored as a document opens with a heading
|
|
76
77
|
that would outgrow the label above it. */
|
|
77
|
-
next.description =
|
|
78
|
+
next.description =
|
|
79
|
+
render ? render({ value: entry.description, compact: true }) : (0, markdownText_1.markdownToProse)(entry.description);
|
|
78
80
|
}
|
|
79
81
|
// Only when the item HAS children — writing the key unconditionally would
|
|
80
82
|
// give every leaf an `items` a picker could read as an empty submenu.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"templateItems.js","sourceRoot":"","sources":["../../src/helpers/templateItems.ts"],"names":[],"mappings":";;;;;;;;;;;;;;
|
|
1
|
+
{"version":3,"file":"templateItems.js","sourceRoot":"","sources":["../../src/helpers/templateItems.ts"],"names":[],"mappings":";;;;;;;;;;;;;;AACA,+CAAiD;AAEjD;;;;;;;;;;;;;;;;;GAiBG;AACI,IAAM,mBAAmB,GAAG,UAAK,KAAsB;IAC5D,IAAI,CAAA,KAAK,aAAL,KAAK,uBAAL,KAAK,CAAE,MAAM,MAAK,CAAC,EAAE,CAAC;QACxB,OAAO,KAAK,CAAC;IACf,CAAC;IACD,IAAM,IAAI,GAAG,KAAK,CAAC,CAAC,CAA0B,CAAC;IAC/C,OAAO,KAAK,CAAC,OAAO,CAAC,IAAI,CAAC,KAAK,CAAC,IAAI,IAAI,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC,CAAE,IAAI,CAAC,KAAa,CAAC,CAAC,CAAC,KAAK,CAAC;AACtF,CAAC,CAAC;AANW,QAAA,mBAAmB,uBAM9B;AAEF;;;;;;;;;;;;;;;;;;;;;;;;GAwBG;AACI,IAAM,8BAA8B,GAAG,UAC5C,KAAsB,EACtB,MAAqC;IAErC,IAAI,CAAC,CAAA,KAAK,aAAL,KAAK,uBAAL,KAAK,CAAE,MAAM,CAAA,EAAE,CAAC;QACnB,OAAO,KAAK,CAAC;IACf,CAAC;IAED,OAAO,KAAK,CAAC,GAAG,CAAC,UAAC,IAAI;QACpB,IAAM,KAAK,GAAG,IAAkD,CAAC;QACjE,IAAM,IAAI,GAAG,aAAK,KAAK,CAA6B,CAAC;QAErD,IAAI,OAAO,KAAK,CAAC,WAAW,KAAK,QAAQ,IAAI,KAAK,CAAC,WAAW,CAAC,IAAI,EAAE,EAAE,CAAC;YACtE;;wDAE4C;YAC5C,IAAI,CAAC,WAAW;gBACd,MAAM,CAAC,CAAC,CAAC,MAAM,CAAC,EAAE,KAAK,EAAE,KAAK,CAAC,WAAW,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC,CAAC,CAAC,CAAC,IAAA,8BAAe,EAAC,KAAK,CAAC,WAAW,CAAC,CAAC;QACtG,CAAC;QAED,0EAA0E;QAC1E,sEAAsE;QACtE,IAAI,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,KAAK,CAAC,EAAE,CAAC;YAC/B,IAAI,CAAC,KAAK,GAAG,IAAA,sCAA8B,EAAC,KAAK,CAAC,KAAK,EAAE,MAAM,CAAC,CAAC;QACnE,CAAC;QAED,OAAO,IAAS,CAAC;IACnB,CAAC,CAAC,CAAC;AACL,CAAC,CAAC;AA5BW,QAAA,8BAA8B,kCA4BzC"}
|
|
@@ -42,7 +42,7 @@ exports.templateChipLabel = templateChipLabel;
|
|
|
42
42
|
* Every value the catalogue offers, longest first.
|
|
43
43
|
*
|
|
44
44
|
* A host may write its references in a grammar reqraft has never seen — a Qorus
|
|
45
|
-
* test spells one `$._case.mode`, which `
|
|
45
|
+
* test spells one `$._case.mode`, which `templateTokenSpans` cannot match
|
|
46
46
|
* because it has no `$key:` at all. Asking the field's own list which strings
|
|
47
47
|
* it NAMES settles that without reqraft guessing at anybody's syntax, and it is
|
|
48
48
|
* the same question the whole-value branch of the read row already asks
|
|
@@ -152,7 +152,10 @@ var grammarSource = function (grammar) {
|
|
|
152
152
|
*/
|
|
153
153
|
var lineReferenceSpans = function (line, templates, tokenGrammar) {
|
|
154
154
|
var declared = grammarSource(tokenGrammar);
|
|
155
|
-
var candidates = __spreadArray(__spreadArray(__spreadArray([], (declared ? patternSpans(line, declared) : []), true),
|
|
155
|
+
var candidates = __spreadArray(__spreadArray(__spreadArray([], (declared ? patternSpans(line, declared) : []), true), (0, templates_1.templateTokenSpans)(line).map(function (_a) {
|
|
156
|
+
var start = _a[0], end = _a[1];
|
|
157
|
+
return ({ start: start, end: end });
|
|
158
|
+
}), true), catalogueValues(templates).flatMap(function (literal) { return literalSpans(line, literal); }), true).sort(function (a, b) { return a.start - b.start || b.end - a.end; });
|
|
156
159
|
var spans = [];
|
|
157
160
|
var cursor = 0;
|
|
158
161
|
candidates.forEach(function (span) {
|