@canonical/dataviews-core 0.47.0 → 0.48.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +27 -19
- package/dist/esm/lib/assertion/assertInvariant.js +14 -0
- package/dist/esm/lib/assertion/assertInvariant.js.map +1 -0
- package/dist/esm/lib/assertion/index.js +2 -0
- package/dist/esm/lib/assertion/index.js.map +1 -0
- package/dist/esm/lib/bindings/index.js +6 -20
- package/dist/esm/lib/bindings/index.js.map +1 -1
- package/dist/esm/lib/coordinator/createQueryCoordinator.js +65 -6
- package/dist/esm/lib/coordinator/createQueryCoordinator.js.map +1 -1
- package/dist/esm/lib/coordinator/index.js +2 -0
- package/dist/esm/lib/coordinator/index.js.map +1 -1
- package/dist/esm/lib/coordinator/isClauseReplaced.js +27 -0
- package/dist/esm/lib/coordinator/isClauseReplaced.js.map +1 -0
- package/dist/esm/lib/coordinator/readWithheld.js +13 -0
- package/dist/esm/lib/coordinator/readWithheld.js.map +1 -0
- package/dist/esm/lib/display/constants.js +2 -1
- package/dist/esm/lib/display/constants.js.map +1 -1
- package/dist/esm/lib/display/resolveDisplayStatus.js +24 -4
- package/dist/esm/lib/display/resolveDisplayStatus.js.map +1 -1
- package/dist/esm/lib/filter/createFilterInput.js +50 -16
- package/dist/esm/lib/filter/createFilterInput.js.map +1 -1
- package/dist/esm/lib/filter/createFilterInputs.js +116 -29
- package/dist/esm/lib/filter/createFilterInputs.js.map +1 -1
- package/dist/esm/lib/geometry/buildColumnTemplate.js +2 -2
- package/dist/esm/lib/geometry/buildColumnTemplate.js.map +1 -1
- package/dist/esm/lib/geometry/createColumnLayout.js +7 -10
- package/dist/esm/lib/geometry/createColumnLayout.js.map +1 -1
- package/dist/esm/lib/geometry/createGridInteraction.js +8 -5
- package/dist/esm/lib/geometry/createGridInteraction.js.map +1 -1
- package/dist/esm/lib/geometry/resolveColumns.js +5 -5
- package/dist/esm/lib/geometry/resolveColumns.js.map +1 -1
- package/dist/esm/lib/index.js +1 -1
- package/dist/esm/lib/index.js.map +1 -1
- package/dist/esm/lib/indexeddb/createIndexedDBViewStore.js +2 -2
- package/dist/esm/lib/indexeddb/createIndexedDBViewStore.js.map +1 -1
- package/dist/esm/lib/indexeddb/readSavedView.js +6 -2
- package/dist/esm/lib/indexeddb/readSavedView.js.map +1 -1
- package/dist/esm/lib/location/createMemoryLocation.js +2 -0
- package/dist/esm/lib/location/createMemoryLocation.js.map +1 -1
- package/dist/esm/lib/location/createPlatformLocation.js +3 -0
- package/dist/esm/lib/location/createPlatformLocation.js.map +1 -1
- package/dist/esm/lib/messages/composeStatus.js +10 -0
- package/dist/esm/lib/messages/composeStatus.js.map +1 -0
- package/dist/esm/lib/messages/constants.js +323 -0
- package/dist/esm/lib/messages/constants.js.map +1 -1
- package/dist/esm/lib/messages/resolveMessages.js +1 -1
- package/dist/esm/lib/messages/resolveMessages.js.map +1 -1
- package/dist/esm/lib/observable/createChannel.js +4 -2
- package/dist/esm/lib/observable/createChannel.js.map +1 -1
- package/dist/esm/lib/presentation/constants.js +5 -12
- package/dist/esm/lib/presentation/constants.js.map +1 -1
- package/dist/esm/lib/presentation/createMemoryPresentation.js +12 -0
- package/dist/esm/lib/presentation/createMemoryPresentation.js.map +1 -0
- package/dist/esm/lib/presentation/createPresentation.js +3 -3
- package/dist/esm/lib/presentation/createPresentation.js.map +1 -1
- package/dist/esm/lib/presentation/hideColumn.js +7 -6
- package/dist/esm/lib/presentation/hideColumn.js.map +1 -1
- package/dist/esm/lib/presentation/index.js +4 -1
- package/dist/esm/lib/presentation/index.js.map +1 -1
- package/dist/esm/lib/presentation/isTableKey.js +9 -0
- package/dist/esm/lib/presentation/isTableKey.js.map +1 -0
- package/dist/esm/lib/presentation/moveColumn.js +7 -7
- package/dist/esm/lib/presentation/moveColumn.js.map +1 -1
- package/dist/esm/lib/presentation/pickTableKeys.js +6 -0
- package/dist/esm/lib/presentation/pickTableKeys.js.map +1 -0
- package/dist/esm/lib/presentation/resetColumnArrangement.js +8 -12
- package/dist/esm/lib/presentation/resetColumnArrangement.js.map +1 -1
- package/dist/esm/lib/presentation/resolveArrangementParams.js +7 -12
- package/dist/esm/lib/presentation/resolveArrangementParams.js.map +1 -1
- package/dist/esm/lib/presentation/resolveColumnArrangement.js +9 -8
- package/dist/esm/lib/presentation/resolveColumnArrangement.js.map +1 -1
- package/dist/esm/lib/presentation/showColumn.js +5 -4
- package/dist/esm/lib/presentation/showColumn.js.map +1 -1
- package/dist/esm/lib/presentation/spellColumnArrangement.js +5 -9
- package/dist/esm/lib/presentation/spellColumnArrangement.js.map +1 -1
- package/dist/esm/lib/presentation/spellWidthKey.js +4 -4
- package/dist/esm/lib/presentation/spellWidthKey.js.map +1 -1
- package/dist/esm/lib/provider/constants.js +3 -22
- package/dist/esm/lib/provider/constants.js.map +1 -1
- package/dist/esm/lib/provider/createDataViewsProvider.js +46 -19
- package/dist/esm/lib/provider/createDataViewsProvider.js.map +1 -1
- package/dist/esm/lib/provider/createQueryCommands.js +32 -20
- package/dist/esm/lib/provider/createQueryCommands.js.map +1 -1
- package/dist/esm/lib/provider/createRecordTyping.js +14 -12
- package/dist/esm/lib/provider/createRecordTyping.js.map +1 -1
- package/dist/esm/lib/provider/createRequestCompleter.js +8 -3
- package/dist/esm/lib/provider/createRequestCompleter.js.map +1 -1
- package/dist/esm/lib/provider/isDataViewsProvider.js +4 -2
- package/dist/esm/lib/provider/isDataViewsProvider.js.map +1 -1
- package/dist/esm/lib/provider/isSameQuery.js +13 -0
- package/dist/esm/lib/provider/isSameQuery.js.map +1 -0
- package/dist/esm/lib/provider/listCarriedIssues.js +20 -0
- package/dist/esm/lib/provider/listCarriedIssues.js.map +1 -0
- package/dist/esm/lib/provider/observePorts.js +2 -2
- package/dist/esm/lib/provider/observePorts.js.map +1 -1
- package/dist/esm/lib/provider/readCommandCause.js +28 -0
- package/dist/esm/lib/provider/readCommandCause.js.map +1 -0
- package/dist/esm/lib/provider/readLocatedArrangement.js +15 -13
- package/dist/esm/lib/provider/readLocatedArrangement.js.map +1 -1
- package/dist/esm/lib/provider/readProviderHost.js +2 -2
- package/dist/esm/lib/provider/readProviderHost.js.map +1 -1
- package/dist/esm/lib/provider/readProviderRegistry.js +20 -0
- package/dist/esm/lib/provider/readProviderRegistry.js.map +1 -0
- package/dist/esm/lib/provider/readStartingPoint.js +2 -1
- package/dist/esm/lib/provider/readStartingPoint.js.map +1 -1
- package/dist/esm/lib/provider/registerProviderHost.js +2 -2
- package/dist/esm/lib/provider/registerProviderHost.js.map +1 -1
- package/dist/esm/lib/provider/resolveHistoryPolicy.js +7 -7
- package/dist/esm/lib/provider/resolveHistoryPolicy.js.map +1 -1
- package/dist/esm/lib/provider/runSource.js +13 -8
- package/dist/esm/lib/provider/runSource.js.map +1 -1
- package/dist/esm/lib/provider/shouldAdoptLocation.js +15 -0
- package/dist/esm/lib/provider/shouldAdoptLocation.js.map +1 -0
- package/dist/esm/lib/provider/spellLocation.js +7 -3
- package/dist/esm/lib/provider/spellLocation.js.map +1 -1
- package/dist/esm/lib/provider/syncLocation.js +61 -31
- package/dist/esm/lib/provider/syncLocation.js.map +1 -1
- package/dist/esm/lib/query/applyQueryCommand.js +129 -38
- package/dist/esm/lib/query/applyQueryCommand.js.map +1 -1
- package/dist/esm/lib/query/areListsEqual.js +1 -1
- package/dist/esm/lib/query/areListsEqual.js.map +1 -1
- package/dist/esm/lib/query/canonicalizeSlice.js +14 -17
- package/dist/esm/lib/query/canonicalizeSlice.js.map +1 -1
- package/dist/esm/lib/query/compareConjuncts.js +44 -0
- package/dist/esm/lib/query/compareConjuncts.js.map +1 -0
- package/dist/esm/lib/query/constants.js +6 -2
- package/dist/esm/lib/query/constants.js.map +1 -1
- package/dist/esm/lib/query/index.js +2 -0
- package/dist/esm/lib/query/index.js.map +1 -1
- package/dist/esm/lib/query/listConjuncts.js +13 -0
- package/dist/esm/lib/query/listConjuncts.js.map +1 -0
- package/dist/esm/lib/query/readCondition.js +36 -0
- package/dist/esm/lib/query/readCondition.js.map +1 -0
- package/dist/esm/lib/query/rejectOperandArity.js +2 -4
- package/dist/esm/lib/query/rejectOperandArity.js.map +1 -1
- package/dist/esm/lib/result/areFieldFacetsEqual.js +7 -1
- package/dist/esm/lib/result/areFieldFacetsEqual.js.map +1 -1
- package/dist/esm/lib/rows/constants.js +1 -1
- package/dist/esm/lib/rows/constants.js.map +1 -1
- package/dist/esm/lib/rows/createRowModel.js +2 -2
- package/dist/esm/lib/rows/createRowModel.js.map +1 -1
- package/dist/esm/lib/rows/createRowScopes.js +5 -2
- package/dist/esm/lib/rows/createRowScopes.js.map +1 -1
- package/dist/esm/lib/schema/createSchema.js +21 -10
- package/dist/esm/lib/schema/createSchema.js.map +1 -1
- package/dist/esm/lib/schema/parseNumberWithUnit.js +72 -0
- package/dist/esm/lib/schema/parseNumberWithUnit.js.map +1 -0
- package/dist/esm/lib/schema/resolveFieldKind.js +88 -29
- package/dist/esm/lib/schema/resolveFieldKind.js.map +1 -1
- package/dist/esm/lib/selection/createSelection.js +4 -2
- package/dist/esm/lib/selection/createSelection.js.map +1 -1
- package/dist/esm/lib/source/copyCapabilities.js +0 -1
- package/dist/esm/lib/source/copyCapabilities.js.map +1 -1
- package/dist/esm/lib/source/createArraySource.js +11 -8
- package/dist/esm/lib/source/createArraySource.js.map +1 -1
- package/dist/esm/lib/source/createPage.js +0 -1
- package/dist/esm/lib/source/createPage.js.map +1 -1
- package/dist/esm/lib/source/createQuerySource.js +32 -13
- package/dist/esm/lib/source/createQuerySource.js.map +1 -1
- package/dist/esm/lib/source/createRefusal.js +5 -0
- package/dist/esm/lib/source/createRefusal.js.map +1 -0
- package/dist/esm/lib/source/createRelaySource.js +49 -60
- package/dist/esm/lib/source/createRelaySource.js.map +1 -1
- package/dist/esm/lib/source/declareCapabilities.js +0 -1
- package/dist/esm/lib/source/declareCapabilities.js.map +1 -1
- package/dist/esm/lib/source/executeSlice.js +1 -0
- package/dist/esm/lib/source/executeSlice.js.map +1 -1
- package/dist/esm/lib/source/foldText.js +3 -0
- package/dist/esm/lib/source/foldText.js.map +1 -1
- package/dist/esm/lib/source/index.js +3 -1
- package/dist/esm/lib/source/index.js.map +1 -1
- package/dist/esm/lib/source/listFilterRefusals.js +30 -0
- package/dist/esm/lib/source/listFilterRefusals.js.map +1 -0
- package/dist/esm/lib/source/listGroupRefusals.js +22 -0
- package/dist/esm/lib/source/listGroupRefusals.js.map +1 -0
- package/dist/esm/lib/source/listOfferedOperators.js +25 -0
- package/dist/esm/lib/source/listOfferedOperators.js.map +1 -0
- package/dist/esm/lib/source/listQueryRefusals.js +35 -0
- package/dist/esm/lib/source/listQueryRefusals.js.map +1 -0
- package/dist/esm/lib/source/listSortRefusals.js +27 -0
- package/dist/esm/lib/source/listSortRefusals.js.map +1 -0
- package/dist/esm/lib/source/listWindowRefusals.js +20 -0
- package/dist/esm/lib/source/listWindowRefusals.js.map +1 -0
- package/dist/esm/lib/source/orderRows.js +36 -12
- package/dist/esm/lib/source/orderRows.js.map +1 -1
- package/dist/esm/lib/source/readFacets.js +30 -15
- package/dist/esm/lib/source/readFacets.js.map +1 -1
- package/dist/esm/lib/source/readRelayPage.js +55 -0
- package/dist/esm/lib/source/readRelayPage.js.map +1 -0
- package/dist/esm/lib/source/readSlice.js +5 -3
- package/dist/esm/lib/source/readSlice.js.map +1 -1
- package/dist/esm/lib/source/resolveErrorDelivery.js +27 -0
- package/dist/esm/lib/source/resolveErrorDelivery.js.map +1 -0
- package/dist/esm/lib/source/selectRows.js +72 -16
- package/dist/esm/lib/source/selectRows.js.map +1 -1
- package/dist/esm/lib/views/createViewCommands.js +6 -3
- package/dist/esm/lib/views/createViewCommands.js.map +1 -1
- package/dist/esm/lib/views/readStoredQuery.js +2 -1
- package/dist/esm/lib/views/readStoredQuery.js.map +1 -1
- package/dist/esm/lib/virtualization/createSizeIndex.js +19 -10
- package/dist/esm/lib/virtualization/createSizeIndex.js.map +1 -1
- package/dist/esm/lib/virtualization/createVirtualRange.js +30 -28
- package/dist/esm/lib/virtualization/createVirtualRange.js.map +1 -1
- package/dist/esm/lib/wire/areQueryIssuesEqual.js +12 -0
- package/dist/esm/lib/wire/areQueryIssuesEqual.js.map +1 -0
- package/dist/esm/lib/wire/constants.js +56 -36
- package/dist/esm/lib/wire/constants.js.map +1 -1
- package/dist/esm/lib/wire/decodeQuery.js +140 -168
- package/dist/esm/lib/wire/decodeQuery.js.map +1 -1
- package/dist/esm/lib/wire/encodeCarryingQuery.js +294 -0
- package/dist/esm/lib/wire/encodeCarryingQuery.js.map +1 -0
- package/dist/esm/lib/wire/encodeQuery.js +8 -76
- package/dist/esm/lib/wire/encodeQuery.js.map +1 -1
- package/dist/esm/lib/wire/index.js +6 -1
- package/dist/esm/lib/wire/index.js.map +1 -1
- package/dist/esm/lib/wire/isNarrowingIssue.js +15 -0
- package/dist/esm/lib/wire/isNarrowingIssue.js.map +1 -0
- package/dist/esm/lib/wire/isOwnedKey.js +6 -2
- package/dist/esm/lib/wire/isOwnedKey.js.map +1 -1
- package/dist/esm/lib/wire/isReservedKey.js +9 -0
- package/dist/esm/lib/wire/isReservedKey.js.map +1 -0
- package/dist/esm/lib/wire/readArrangementParams.js +18 -14
- package/dist/esm/lib/wire/readArrangementParams.js.map +1 -1
- package/dist/esm/lib/wire/readKeyPredicate.js +146 -0
- package/dist/esm/lib/wire/readKeyPredicate.js.map +1 -0
- package/dist/esm/lib/wire/readTableKey.js +21 -0
- package/dist/esm/lib/wire/readTableKey.js.map +1 -0
- package/dist/esm/lib/wire/readUndeclaredField.js +19 -0
- package/dist/esm/lib/wire/readUndeclaredField.js.map +1 -0
- package/dist/esm/lib/wire/readWireKey.js +38 -0
- package/dist/esm/lib/wire/readWireKey.js.map +1 -0
- package/dist/esm/lib/wire/recordConjunct.js +48 -0
- package/dist/esm/lib/wire/recordConjunct.js.map +1 -0
- package/dist/esm/lib/wire/rejectWireName.js +3 -2
- package/dist/esm/lib/wire/rejectWireName.js.map +1 -1
- package/dist/esm/lib/wire/spellArrangementKey.js +7 -0
- package/dist/esm/lib/wire/spellArrangementKey.js.map +1 -0
- package/dist/esm/lib/wire/spellArrangementParams.js +12 -15
- package/dist/esm/lib/wire/spellArrangementParams.js.map +1 -1
- package/dist/esm/lib/wire/spellOperand.js +33 -0
- package/dist/esm/lib/wire/spellOperand.js.map +1 -0
- package/dist/esm/lib/wire/spellTableId.js +12 -0
- package/dist/esm/lib/wire/spellTableId.js.map +1 -0
- package/dist/esm/lib/wire/spellWireKey.js +7 -4
- package/dist/esm/lib/wire/spellWireKey.js.map +1 -1
- package/dist/esm/lib/wire/spellWireValues.js +18 -0
- package/dist/esm/lib/wire/spellWireValues.js.map +1 -0
- package/dist/esm/testing/answerWith.js +10 -0
- package/dist/esm/testing/buildFailedResult.js +12 -0
- package/dist/esm/testing/buildPage.js +19 -0
- package/dist/esm/testing/buildRefusedResult.js +18 -0
- package/dist/esm/testing/buildRowModel.js +15 -0
- package/dist/esm/testing/buildSettledPage.js +22 -0
- package/dist/esm/testing/buildStoredView.js +19 -0
- package/dist/esm/testing/classifyInitializer.js +50 -0
- package/dist/esm/testing/countAtLeast.js +9 -0
- package/dist/esm/testing/countExactly.js +9 -0
- package/dist/esm/testing/createCountedRows.js +28 -0
- package/dist/esm/testing/createCountingViewStore.js +36 -0
- package/dist/esm/testing/createDeferred.js +9 -0
- package/dist/esm/testing/createManualSource.js +56 -0
- package/dist/esm/testing/createRecordingLocation.js +53 -0
- package/dist/esm/testing/createStandInPresentationStore.js +15 -0
- package/dist/esm/testing/createStandInViewStore.js +23 -0
- package/dist/esm/testing/declare.js +10 -0
- package/dist/esm/testing/declareSort.js +17 -0
- package/dist/esm/testing/filterStatusBy.js +13 -0
- package/dist/esm/testing/fixtures.js +694 -0
- package/dist/esm/testing/flushPresentation.js +16 -0
- package/dist/esm/testing/index.js +35 -0
- package/dist/esm/testing/installFakeClock.js +18 -0
- package/dist/esm/testing/isMovableForm.js +7 -0
- package/dist/esm/testing/isWrappedInitializer.js +33 -0
- package/dist/esm/testing/isWrapperCallee.js +10 -0
- package/dist/esm/testing/judgeExports.js +54 -0
- package/dist/esm/testing/listBracedExports.js +45 -0
- package/dist/esm/testing/listExports.js +68 -0
- package/dist/esm/testing/listFileRuleFindings.js +76 -0
- package/dist/esm/testing/listUnmarkedNames.js +40 -0
- package/dist/esm/testing/maskSource.js +149 -0
- package/dist/esm/testing/observeUntilFinished.js +15 -0
- package/dist/esm/testing/openIndexedDBTab.js +20 -0
- package/dist/esm/testing/orderNodesByName.js +31 -0
- package/dist/esm/testing/readDeclarationDoc.js +15 -0
- package/dist/esm/testing/readDeclarationExport.js +41 -0
- package/dist/esm/testing/readDefaultExport.js +55 -0
- package/dist/esm/testing/readDisplayStatus.js +14 -0
- package/dist/esm/testing/readFileRole.js +16 -0
- package/dist/esm/testing/readGroup.js +8 -0
- package/dist/esm/testing/readId.js +9 -0
- package/dist/esm/testing/readIssuedRequest.js +12 -0
- package/dist/esm/testing/readLocalBinding.js +44 -0
- package/dist/esm/testing/readSucceededPage.js +7 -0
- package/dist/esm/testing/relayTypes.js +5 -0
- package/dist/esm/testing/respellLink.js +27 -0
- package/dist/esm/testing/runFailureHandlers.js +26 -0
- package/dist/esm/testing/settleCalls.js +11 -0
- package/dist/esm/testing/skipBalanced.js +20 -0
- package/dist/esm/testing/skipTypeAnnotation.js +33 -0
- package/dist/esm/testing/types.js +2 -0
- package/dist/esm/testing/waitForState.js +40 -0
- package/dist/types/lib/assertion/assertInvariant.d.ts +9 -0
- package/dist/types/lib/assertion/assertInvariant.d.ts.map +1 -0
- package/dist/types/lib/assertion/index.d.ts +2 -0
- package/dist/types/lib/assertion/index.d.ts.map +1 -0
- package/dist/types/lib/bindings/index.d.ts +6 -20
- package/dist/types/lib/bindings/index.d.ts.map +1 -1
- package/dist/types/lib/coordinator/createQueryCoordinator.d.ts.map +1 -1
- package/dist/types/lib/coordinator/index.d.ts +2 -0
- package/dist/types/lib/coordinator/index.d.ts.map +1 -1
- package/dist/types/lib/coordinator/isClauseReplaced.d.ts +12 -0
- package/dist/types/lib/coordinator/isClauseReplaced.d.ts.map +1 -0
- package/dist/types/lib/coordinator/readWithheld.d.ts +9 -0
- package/dist/types/lib/coordinator/readWithheld.d.ts.map +1 -0
- package/dist/types/lib/coordinator/types.d.ts +34 -11
- package/dist/types/lib/coordinator/types.d.ts.map +1 -1
- package/dist/types/lib/display/constants.d.ts.map +1 -1
- package/dist/types/lib/display/resolveDisplayStatus.d.ts +6 -0
- package/dist/types/lib/display/resolveDisplayStatus.d.ts.map +1 -1
- package/dist/types/lib/display/types.d.ts +22 -16
- package/dist/types/lib/display/types.d.ts.map +1 -1
- package/dist/types/lib/filter/createFilterInput.d.ts.map +1 -1
- package/dist/types/lib/filter/createFilterInputs.d.ts +4 -2
- package/dist/types/lib/filter/createFilterInputs.d.ts.map +1 -1
- package/dist/types/lib/filter/types.d.ts +55 -2
- package/dist/types/lib/filter/types.d.ts.map +1 -1
- package/dist/types/lib/geometry/createColumnLayout.d.ts +3 -6
- package/dist/types/lib/geometry/createColumnLayout.d.ts.map +1 -1
- package/dist/types/lib/geometry/createGridInteraction.d.ts +3 -0
- package/dist/types/lib/geometry/createGridInteraction.d.ts.map +1 -1
- package/dist/types/lib/geometry/types.d.ts +3 -1
- package/dist/types/lib/geometry/types.d.ts.map +1 -1
- package/dist/types/lib/index.d.ts +7 -7
- package/dist/types/lib/index.d.ts.map +1 -1
- package/dist/types/lib/indexeddb/createIndexedDBViewStore.d.ts.map +1 -1
- package/dist/types/lib/indexeddb/readSavedView.d.ts +4 -1
- package/dist/types/lib/indexeddb/readSavedView.d.ts.map +1 -1
- package/dist/types/lib/indexeddb/types.d.ts +7 -0
- package/dist/types/lib/indexeddb/types.d.ts.map +1 -1
- package/dist/types/lib/location/createMemoryLocation.d.ts +2 -0
- package/dist/types/lib/location/createMemoryLocation.d.ts.map +1 -1
- package/dist/types/lib/location/createPlatformLocation.d.ts +3 -0
- package/dist/types/lib/location/createPlatformLocation.d.ts.map +1 -1
- package/dist/types/lib/messages/composeStatus.d.ts +6 -0
- package/dist/types/lib/messages/composeStatus.d.ts.map +1 -0
- package/dist/types/lib/messages/constants.d.ts +27 -1
- package/dist/types/lib/messages/constants.d.ts.map +1 -1
- package/dist/types/lib/messages/types.d.ts +381 -88
- package/dist/types/lib/messages/types.d.ts.map +1 -1
- package/dist/types/lib/observable/createChannel.d.ts +2 -0
- package/dist/types/lib/observable/createChannel.d.ts.map +1 -1
- package/dist/types/lib/presentation/constants.d.ts +4 -12
- package/dist/types/lib/presentation/constants.d.ts.map +1 -1
- package/dist/types/lib/presentation/createMemoryPresentation.d.ts +10 -0
- package/dist/types/lib/presentation/createMemoryPresentation.d.ts.map +1 -0
- package/dist/types/lib/presentation/hideColumn.d.ts +2 -2
- package/dist/types/lib/presentation/hideColumn.d.ts.map +1 -1
- package/dist/types/lib/presentation/index.d.ts +4 -1
- package/dist/types/lib/presentation/index.d.ts.map +1 -1
- package/dist/types/lib/presentation/isTableKey.d.ts +6 -0
- package/dist/types/lib/presentation/isTableKey.d.ts.map +1 -0
- package/dist/types/lib/presentation/moveColumn.d.ts +2 -3
- package/dist/types/lib/presentation/moveColumn.d.ts.map +1 -1
- package/dist/types/lib/presentation/pickTableKeys.d.ts +4 -0
- package/dist/types/lib/presentation/pickTableKeys.d.ts.map +1 -0
- package/dist/types/lib/presentation/resetColumnArrangement.d.ts +3 -8
- package/dist/types/lib/presentation/resetColumnArrangement.d.ts.map +1 -1
- package/dist/types/lib/presentation/resolveArrangementParams.d.ts +3 -9
- package/dist/types/lib/presentation/resolveArrangementParams.d.ts.map +1 -1
- package/dist/types/lib/presentation/resolveColumnArrangement.d.ts +3 -2
- package/dist/types/lib/presentation/resolveColumnArrangement.d.ts.map +1 -1
- package/dist/types/lib/presentation/showColumn.d.ts +1 -1
- package/dist/types/lib/presentation/showColumn.d.ts.map +1 -1
- package/dist/types/lib/presentation/spellColumnArrangement.d.ts +3 -7
- package/dist/types/lib/presentation/spellColumnArrangement.d.ts.map +1 -1
- package/dist/types/lib/presentation/spellWidthKey.d.ts +2 -2
- package/dist/types/lib/presentation/spellWidthKey.d.ts.map +1 -1
- package/dist/types/lib/presentation/types.d.ts +6 -2
- package/dist/types/lib/presentation/types.d.ts.map +1 -1
- package/dist/types/lib/provider/constants.d.ts +3 -15
- package/dist/types/lib/provider/constants.d.ts.map +1 -1
- package/dist/types/lib/provider/createDataViewsProvider.d.ts.map +1 -1
- package/dist/types/lib/provider/createQueryCommands.d.ts.map +1 -1
- package/dist/types/lib/provider/createRecordTyping.d.ts.map +1 -1
- package/dist/types/lib/provider/createRequestCompleter.d.ts.map +1 -1
- package/dist/types/lib/provider/isDataViewsProvider.d.ts.map +1 -1
- package/dist/types/lib/provider/isSameQuery.d.ts +8 -0
- package/dist/types/lib/provider/isSameQuery.d.ts.map +1 -0
- package/dist/types/lib/provider/listCarriedIssues.d.ts +10 -0
- package/dist/types/lib/provider/listCarriedIssues.d.ts.map +1 -0
- package/dist/types/lib/provider/readCommandCause.d.ts +10 -0
- package/dist/types/lib/provider/readCommandCause.d.ts.map +1 -0
- package/dist/types/lib/provider/readLocatedArrangement.d.ts +3 -5
- package/dist/types/lib/provider/readLocatedArrangement.d.ts.map +1 -1
- package/dist/types/lib/provider/readProviderRegistry.d.ts +10 -0
- package/dist/types/lib/provider/readProviderRegistry.d.ts.map +1 -0
- package/dist/types/lib/provider/readStartingPoint.d.ts.map +1 -1
- package/dist/types/lib/provider/runSource.d.ts.map +1 -1
- package/dist/types/lib/provider/shouldAdoptLocation.d.ts +19 -0
- package/dist/types/lib/provider/shouldAdoptLocation.d.ts.map +1 -0
- package/dist/types/lib/provider/spellLocation.d.ts +10 -1
- package/dist/types/lib/provider/spellLocation.d.ts.map +1 -1
- package/dist/types/lib/provider/syncLocation.d.ts.map +1 -1
- package/dist/types/lib/provider/types.d.ts +91 -36
- package/dist/types/lib/provider/types.d.ts.map +1 -1
- package/dist/types/lib/query/applyQueryCommand.d.ts +7 -2
- package/dist/types/lib/query/applyQueryCommand.d.ts.map +1 -1
- package/dist/types/lib/query/canonicalizeSlice.d.ts +4 -2
- package/dist/types/lib/query/canonicalizeSlice.d.ts.map +1 -1
- package/dist/types/lib/query/compareConjuncts.d.ts +14 -0
- package/dist/types/lib/query/compareConjuncts.d.ts.map +1 -0
- package/dist/types/lib/query/constants.d.ts +2 -2
- package/dist/types/lib/query/constants.d.ts.map +1 -1
- package/dist/types/lib/query/index.d.ts +2 -0
- package/dist/types/lib/query/index.d.ts.map +1 -1
- package/dist/types/lib/query/listConjuncts.d.ts +11 -0
- package/dist/types/lib/query/listConjuncts.d.ts.map +1 -0
- package/dist/types/lib/query/readCondition.d.ts +14 -0
- package/dist/types/lib/query/readCondition.d.ts.map +1 -0
- package/dist/types/lib/query/rejectOperandArity.d.ts +2 -2
- package/dist/types/lib/query/rejectOperandArity.d.ts.map +1 -1
- package/dist/types/lib/query/types.d.ts +89 -16
- package/dist/types/lib/query/types.d.ts.map +1 -1
- package/dist/types/lib/result/areFieldFacetsEqual.d.ts +7 -1
- package/dist/types/lib/result/areFieldFacetsEqual.d.ts.map +1 -1
- package/dist/types/lib/result/types.d.ts +66 -24
- package/dist/types/lib/result/types.d.ts.map +1 -1
- package/dist/types/lib/rows/createRowScopes.d.ts +3 -0
- package/dist/types/lib/rows/createRowScopes.d.ts.map +1 -1
- package/dist/types/lib/rows/types.d.ts +3 -3
- package/dist/types/lib/rows/types.d.ts.map +1 -1
- package/dist/types/lib/schema/createSchema.d.ts.map +1 -1
- package/dist/types/lib/schema/parseNumberWithUnit.d.ts +15 -0
- package/dist/types/lib/schema/parseNumberWithUnit.d.ts.map +1 -0
- package/dist/types/lib/schema/resolveFieldKind.d.ts.map +1 -1
- package/dist/types/lib/schema/types.d.ts +93 -29
- package/dist/types/lib/schema/types.d.ts.map +1 -1
- package/dist/types/lib/selection/createSelection.d.ts +2 -0
- package/dist/types/lib/selection/createSelection.d.ts.map +1 -1
- package/dist/types/lib/source/copyCapabilities.d.ts.map +1 -1
- package/dist/types/lib/source/createArraySource.d.ts +5 -2
- package/dist/types/lib/source/createArraySource.d.ts.map +1 -1
- package/dist/types/lib/source/createPage.d.ts.map +1 -1
- package/dist/types/lib/source/createQuerySource.d.ts +7 -0
- package/dist/types/lib/source/createQuerySource.d.ts.map +1 -1
- package/dist/types/lib/source/createRefusal.d.ts +4 -0
- package/dist/types/lib/source/createRefusal.d.ts.map +1 -0
- package/dist/types/lib/source/createRelaySource.d.ts +7 -1
- package/dist/types/lib/source/createRelaySource.d.ts.map +1 -1
- package/dist/types/lib/source/declareCapabilities.d.ts.map +1 -1
- package/dist/types/lib/source/executeSlice.d.ts.map +1 -1
- package/dist/types/lib/source/foldText.d.ts +3 -0
- package/dist/types/lib/source/foldText.d.ts.map +1 -1
- package/dist/types/lib/source/index.d.ts +3 -1
- package/dist/types/lib/source/index.d.ts.map +1 -1
- package/dist/types/lib/source/listFilterRefusals.d.ts +11 -0
- package/dist/types/lib/source/listFilterRefusals.d.ts.map +1 -0
- package/dist/types/lib/source/listGroupRefusals.d.ts +10 -0
- package/dist/types/lib/source/listGroupRefusals.d.ts.map +1 -0
- package/dist/types/lib/source/listOfferedOperators.d.ts +14 -0
- package/dist/types/lib/source/listOfferedOperators.d.ts.map +1 -0
- package/dist/types/lib/source/{refusalsOf.d.ts → listQueryRefusals.d.ts} +3 -3
- package/dist/types/lib/source/listQueryRefusals.d.ts.map +1 -0
- package/dist/types/lib/source/listSortRefusals.d.ts +10 -0
- package/dist/types/lib/source/listSortRefusals.d.ts.map +1 -0
- package/dist/types/lib/source/listWindowRefusals.d.ts +9 -0
- package/dist/types/lib/source/listWindowRefusals.d.ts.map +1 -0
- package/dist/types/lib/source/orderRows.d.ts +10 -5
- package/dist/types/lib/source/orderRows.d.ts.map +1 -1
- package/dist/types/lib/source/readFacets.d.ts +1 -1
- package/dist/types/lib/source/readFacets.d.ts.map +1 -1
- package/dist/types/lib/source/readRelayPage.d.ts +19 -0
- package/dist/types/lib/source/readRelayPage.d.ts.map +1 -0
- package/dist/types/lib/source/readSlice.d.ts +5 -3
- package/dist/types/lib/source/readSlice.d.ts.map +1 -1
- package/dist/types/lib/source/resolveErrorDelivery.d.ts +9 -0
- package/dist/types/lib/source/resolveErrorDelivery.d.ts.map +1 -0
- package/dist/types/lib/source/selectRows.d.ts +4 -2
- package/dist/types/lib/source/selectRows.d.ts.map +1 -1
- package/dist/types/lib/source/types.d.ts +36 -17
- package/dist/types/lib/source/types.d.ts.map +1 -1
- package/dist/types/lib/views/createViewCommands.d.ts.map +1 -1
- package/dist/types/lib/views/readStoredQuery.d.ts.map +1 -1
- package/dist/types/lib/views/types.d.ts +1 -1
- package/dist/types/lib/views/types.d.ts.map +1 -1
- package/dist/types/lib/virtualization/createSizeIndex.d.ts +3 -0
- package/dist/types/lib/virtualization/createSizeIndex.d.ts.map +1 -1
- package/dist/types/lib/virtualization/createVirtualRange.d.ts +4 -1
- package/dist/types/lib/virtualization/createVirtualRange.d.ts.map +1 -1
- package/dist/types/lib/virtualization/types.d.ts +4 -4
- package/dist/types/lib/virtualization/types.d.ts.map +1 -1
- package/dist/types/lib/wire/areQueryIssuesEqual.d.ts +7 -0
- package/dist/types/lib/wire/areQueryIssuesEqual.d.ts.map +1 -0
- package/dist/types/lib/wire/constants.d.ts +54 -18
- package/dist/types/lib/wire/constants.d.ts.map +1 -1
- package/dist/types/lib/wire/decodeQuery.d.ts +7 -4
- package/dist/types/lib/wire/decodeQuery.d.ts.map +1 -1
- package/dist/types/lib/wire/encodeCarryingQuery.d.ts +9 -0
- package/dist/types/lib/wire/encodeCarryingQuery.d.ts.map +1 -0
- package/dist/types/lib/wire/encodeQuery.d.ts.map +1 -1
- package/dist/types/lib/wire/index.d.ts +6 -1
- package/dist/types/lib/wire/index.d.ts.map +1 -1
- package/dist/types/lib/wire/isNarrowingIssue.d.ts +13 -0
- package/dist/types/lib/wire/isNarrowingIssue.d.ts.map +1 -0
- package/dist/types/lib/wire/isOwnedKey.d.ts +3 -1
- package/dist/types/lib/wire/isOwnedKey.d.ts.map +1 -1
- package/dist/types/lib/wire/isReservedKey.d.ts +6 -0
- package/dist/types/lib/wire/isReservedKey.d.ts.map +1 -0
- package/dist/types/lib/wire/readArrangementParams.d.ts +4 -8
- package/dist/types/lib/wire/readArrangementParams.d.ts.map +1 -1
- package/dist/types/lib/wire/readKeyPredicate.d.ts +9 -0
- package/dist/types/lib/wire/readKeyPredicate.d.ts.map +1 -0
- package/dist/types/lib/wire/readTableKey.d.ts +13 -0
- package/dist/types/lib/wire/readTableKey.d.ts.map +1 -0
- package/dist/types/lib/wire/readUndeclaredField.d.ts +11 -0
- package/dist/types/lib/wire/readUndeclaredField.d.ts.map +1 -0
- package/dist/types/lib/wire/readWireKey.d.ts +11 -0
- package/dist/types/lib/wire/readWireKey.d.ts.map +1 -0
- package/dist/types/lib/wire/recordConjunct.d.ts +10 -0
- package/dist/types/lib/wire/recordConjunct.d.ts.map +1 -0
- package/dist/types/lib/wire/rejectWireName.d.ts.map +1 -1
- package/dist/types/lib/wire/spellArrangementKey.d.ts +4 -0
- package/dist/types/lib/wire/spellArrangementKey.d.ts.map +1 -0
- package/dist/types/lib/wire/spellArrangementParams.d.ts +3 -9
- package/dist/types/lib/wire/spellArrangementParams.d.ts.map +1 -1
- package/dist/types/lib/wire/spellOperand.d.ts +4 -0
- package/dist/types/lib/wire/spellOperand.d.ts.map +1 -0
- package/dist/types/lib/wire/spellTableId.d.ts +6 -0
- package/dist/types/lib/wire/spellTableId.d.ts.map +1 -0
- package/dist/types/lib/wire/spellWireKey.d.ts +4 -4
- package/dist/types/lib/wire/spellWireKey.d.ts.map +1 -1
- package/dist/types/lib/wire/spellWireValues.d.ts +13 -0
- package/dist/types/lib/wire/spellWireValues.d.ts.map +1 -0
- package/dist/types/lib/wire/types.d.ts +68 -31
- package/dist/types/lib/wire/types.d.ts.map +1 -1
- package/dist/types/testing/answerWith.d.ts +9 -0
- package/dist/types/testing/buildFailedResult.d.ts +10 -0
- package/dist/types/testing/buildPage.d.ts +8 -0
- package/dist/types/testing/buildRefusedResult.d.ts +10 -0
- package/dist/types/testing/buildRowModel.d.ts +9 -0
- package/dist/types/testing/buildSettledPage.d.ts +17 -0
- package/dist/types/testing/buildStoredView.d.ts +8 -0
- package/dist/types/testing/classifyInitializer.d.ts +6 -0
- package/dist/types/testing/countAtLeast.d.ts +8 -0
- package/dist/types/testing/countExactly.d.ts +8 -0
- package/dist/types/testing/createCountedRows.d.ts +13 -0
- package/dist/types/testing/createCountingViewStore.d.ts +10 -0
- package/dist/types/testing/createDeferred.d.ts +8 -0
- package/dist/types/testing/createManualSource.d.ts +16 -0
- package/dist/types/testing/createRecordingLocation.d.ts +20 -0
- package/dist/types/testing/createStandInPresentationStore.d.ts +9 -0
- package/dist/types/testing/createStandInViewStore.d.ts +9 -0
- package/dist/types/testing/declare.d.ts +8 -0
- package/dist/types/testing/declareSort.d.ts +9 -0
- package/dist/types/testing/filterStatusBy.d.ts +8 -0
- package/dist/types/testing/fixtures.d.ts +117 -0
- package/dist/types/testing/flushPresentation.d.ts +13 -0
- package/dist/types/testing/index.d.ts +37 -0
- package/dist/types/testing/installFakeClock.d.ts +14 -0
- package/dist/types/testing/isMovableForm.d.ts +6 -0
- package/dist/types/testing/isWrappedInitializer.d.ts +6 -0
- package/dist/types/testing/isWrapperCallee.d.ts +2 -0
- package/dist/types/testing/judgeExports.d.ts +8 -0
- package/dist/types/testing/listBracedExports.d.ts +6 -0
- package/dist/types/testing/listExports.d.ts +7 -0
- package/dist/types/testing/listFileRuleFindings.d.ts +12 -0
- package/dist/types/testing/listUnmarkedNames.d.ts +10 -0
- package/dist/types/testing/maskSource.d.ts +6 -0
- package/dist/types/testing/observeUntilFinished.d.ts +12 -0
- package/dist/types/testing/openIndexedDBTab.d.ts +12 -0
- package/dist/types/testing/orderNodesByName.d.ts +11 -0
- package/dist/types/testing/readDeclarationDoc.d.ts +6 -0
- package/dist/types/testing/readDeclarationExport.d.ts +6 -0
- package/dist/types/testing/readDefaultExport.d.ts +6 -0
- package/dist/types/testing/readDisplayStatus.d.ts +8 -0
- package/dist/types/testing/readFileRole.d.ts +3 -0
- package/dist/types/testing/readGroup.d.ts +2 -0
- package/dist/types/testing/readId.d.ts +8 -0
- package/dist/types/testing/readIssuedRequest.d.ts +7 -0
- package/dist/types/testing/readLocalBinding.d.ts +6 -0
- package/dist/types/testing/readSucceededPage.d.ts +3 -0
- package/dist/types/testing/relayTypes.d.ts +38 -0
- package/dist/types/testing/respellLink.d.ts +12 -0
- package/dist/types/testing/runFailureHandlers.d.ts +12 -0
- package/dist/types/testing/settleCalls.d.ts +15 -0
- package/dist/types/testing/skipBalanced.d.ts +5 -0
- package/dist/types/testing/skipTypeAnnotation.d.ts +5 -0
- package/dist/types/testing/types.d.ts +228 -0
- package/dist/types/testing/waitForState.d.ts +11 -0
- package/package.json +19 -9
- package/dist/esm/lib/messages/DEFAULT_MESSAGES.js +0 -194
- package/dist/esm/lib/messages/DEFAULT_MESSAGES.js.map +0 -1
- package/dist/esm/lib/source/refusalsOf.js +0 -74
- package/dist/esm/lib/source/refusalsOf.js.map +0 -1
- package/dist/types/lib/messages/DEFAULT_MESSAGES.d.ts +0 -10
- package/dist/types/lib/messages/DEFAULT_MESSAGES.d.ts.map +0 -1
- package/dist/types/lib/source/refusalsOf.d.ts.map +0 -1
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Blank comments and the contents of strings, templates and regular
|
|
3
|
+
* expressions, keeping every offset and newline. Quotes stay as tokens and
|
|
4
|
+
* template substitutions stay as code, so later scans read only code.
|
|
5
|
+
*/
|
|
6
|
+
export default function maskSource(source: string): string;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Observe a record as a mounted control does, releasing when the test ends
|
|
3
|
+
* — before any store the test opened earlier is disposed, so a write still
|
|
4
|
+
* gathering reaches a live store. The release is returned for a test that
|
|
5
|
+
* releases sooner; releasing twice is releasing once.
|
|
6
|
+
*
|
|
7
|
+
* @experimental Pre-release: the whole surface is still settling, and this
|
|
8
|
+
* name may change or move before the first release.
|
|
9
|
+
*/
|
|
10
|
+
export default function observeUntilFinished(observable: {
|
|
11
|
+
readonly observe: () => () => void;
|
|
12
|
+
}): () => void;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { type IndexedDBFactory } from "../lib/indexeddb/index.js";
|
|
2
|
+
import type { PresentationStore } from "../lib/presentation/index.js";
|
|
3
|
+
import type { ViewStore } from "../lib/views/index.js";
|
|
4
|
+
/**
|
|
5
|
+
* Open one tab's store over a browser profile's IndexedDB — two stores on
|
|
6
|
+
* one factory are two tabs — disposed when the test that opened it ends,
|
|
7
|
+
* after every observation the test registered later.
|
|
8
|
+
*
|
|
9
|
+
* @experimental Pre-release: the whole surface is still settling, and this
|
|
10
|
+
* name may change or move before the first release.
|
|
11
|
+
*/
|
|
12
|
+
export default function openIndexedDBTab(indexedDB: IndexedDBFactory): ViewStore & PresentationStore;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Order named records by name through an array source declaring
|
|
3
|
+
* `collation`, and answer their ids in the order the source delivers them.
|
|
4
|
+
*
|
|
5
|
+
* @experimental Pre-release: the whole surface is still settling, and this
|
|
6
|
+
* name may change or move before the first release.
|
|
7
|
+
*/
|
|
8
|
+
export default function orderNodesByName(rows: readonly {
|
|
9
|
+
readonly id: string;
|
|
10
|
+
readonly name: string;
|
|
11
|
+
}[], collation: string): readonly string[];
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Read the TSDoc block right before a name's exported declaration in one
|
|
3
|
+
* source text: an empty string when the declaration has none, null when the
|
|
4
|
+
* text does not declare the name.
|
|
5
|
+
*/
|
|
6
|
+
export default function readDeclarationDoc(source: string, name: string): string | null;
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import type { ExportRecord } from "./types.js";
|
|
2
|
+
/**
|
|
3
|
+
* The record of one named `export` carried by its declaration, from the
|
|
4
|
+
* masked source, the masked text after `export` and that text's offset.
|
|
5
|
+
*/
|
|
6
|
+
export default function readDeclarationExport(masked: string, rest: string, offset: number): ExportRecord;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import type { DisplayStatus } from "../lib/display/index.js";
|
|
2
|
+
/**
|
|
3
|
+
* One display status of each kind, with a reason where the kind carries one.
|
|
4
|
+
*
|
|
5
|
+
* @experimental Pre-release: the whole surface is still settling, and this
|
|
6
|
+
* name may change or move before the first release.
|
|
7
|
+
*/
|
|
8
|
+
export default function readDisplayStatus(status: DisplayStatus["status"]): DisplayStatus;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import type { RowRecord } from "../lib/rows/index.js";
|
|
2
|
+
/**
|
|
3
|
+
* The identity every fixture record carries: its own `id`.
|
|
4
|
+
*
|
|
5
|
+
* @experimental Pre-release: the whole surface is still settling, and this
|
|
6
|
+
* name may change or move before the first release.
|
|
7
|
+
*/
|
|
8
|
+
export default function readId(row: RowRecord): string;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The request a command issued, failing loudly rather than casting.
|
|
3
|
+
*
|
|
4
|
+
* @experimental Pre-release: the whole surface is still settling, and this
|
|
5
|
+
* name may change or move before the first release.
|
|
6
|
+
*/
|
|
7
|
+
export default function readIssuedRequest(requestId: string | null): string;
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import type { LocalBinding } from "./types.js";
|
|
2
|
+
/**
|
|
3
|
+
* How a binding a file exports by name, through `export default X` or
|
|
4
|
+
* `export { X }`, is declared in the masked source.
|
|
5
|
+
*/
|
|
6
|
+
export default function readLocalBinding(masked: string, name: string): LocalBinding;
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The Relay test shapes, kept out of the ./testing entry so its types need
|
|
3
|
+
* no relay-runtime.
|
|
4
|
+
*/
|
|
5
|
+
import type { GraphQLResponse, Variables } from "relay-runtime";
|
|
6
|
+
/** A machine as the Relay test schema selects it. */
|
|
7
|
+
export type RelayMachine = {
|
|
8
|
+
readonly id: string;
|
|
9
|
+
readonly name: string;
|
|
10
|
+
readonly status: string;
|
|
11
|
+
};
|
|
12
|
+
/** The data `MachinesQuery` selects, as the Relay compiler types it. */
|
|
13
|
+
export type RelayMachinesData = {
|
|
14
|
+
readonly machines: {
|
|
15
|
+
readonly totalCount: number | null;
|
|
16
|
+
readonly pageInfo: {
|
|
17
|
+
readonly endCursor: string | null;
|
|
18
|
+
readonly hasNextPage: boolean | null;
|
|
19
|
+
};
|
|
20
|
+
readonly edges: ReadonlyArray<{
|
|
21
|
+
readonly node: RelayMachine | null;
|
|
22
|
+
} | null> | null;
|
|
23
|
+
} | null;
|
|
24
|
+
};
|
|
25
|
+
/** The compiled query type `MachinesQuery`, as the Relay compiler emits it. */
|
|
26
|
+
export type RelayMachinesOperation = {
|
|
27
|
+
readonly response: RelayMachinesData;
|
|
28
|
+
readonly variables: Variables;
|
|
29
|
+
};
|
|
30
|
+
/** One fetch the Relay test network received, answered by hand. */
|
|
31
|
+
export type RelayFetch = {
|
|
32
|
+
readonly variables: Variables;
|
|
33
|
+
/** Answer the fetch, by default with the server's page. */
|
|
34
|
+
readonly respond: (response?: GraphQLResponse) => void;
|
|
35
|
+
readonly fail: (error: Error) => void;
|
|
36
|
+
/** True when the fetch was abandoned before it was answered. */
|
|
37
|
+
cancelled: boolean;
|
|
38
|
+
};
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import type { Schema, SchemaFieldDefinition } from "../lib/schema/index.js";
|
|
2
|
+
import type { SourceCapabilities } from "../lib/source/index.js";
|
|
3
|
+
import type { RespelledLink } from "./types.js";
|
|
4
|
+
/**
|
|
5
|
+
* A followed link written back over itself, its narrowing refusals carried
|
|
6
|
+
* as the location loop carries them, and the written link read again,
|
|
7
|
+
* against the source's capabilities when given.
|
|
8
|
+
*
|
|
9
|
+
* @experimental Pre-release: the whole surface is still settling, and this
|
|
10
|
+
* name may change or move before the first release.
|
|
11
|
+
*/
|
|
12
|
+
export default function respellLink(schema: Schema<readonly SchemaFieldDefinition[]>, params: URLSearchParams, capabilities?: SourceCapabilities | null): RespelledLink;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import type { FailureHandlersContext } from "./types.js";
|
|
2
|
+
/**
|
|
3
|
+
* Run the test's failure handlers now, resolving with the messages they
|
|
4
|
+
* threw.
|
|
5
|
+
*
|
|
6
|
+
* @note Impure: runs each handler the test registered through
|
|
7
|
+
* `onTestFailed`.
|
|
8
|
+
*
|
|
9
|
+
* @experimental Pre-release: the whole surface is still settling, and this
|
|
10
|
+
* name may change or move before the first release.
|
|
11
|
+
*/
|
|
12
|
+
export default function runFailureHandlers(context: FailureHandlersContext): Promise<string[]>;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Wait for every answer a stand-in has given to settle. Code that reacts to
|
|
3
|
+
* an answer as it is given has run that reaction by the time this resolves,
|
|
4
|
+
* so a case waits for the answers, never for a duration.
|
|
5
|
+
*
|
|
6
|
+
* @experimental Pre-release: the whole surface is still settling, and this
|
|
7
|
+
* name may change or move before the first release.
|
|
8
|
+
*/
|
|
9
|
+
export default function settleCalls(calls: {
|
|
10
|
+
readonly mock: {
|
|
11
|
+
readonly results: readonly {
|
|
12
|
+
readonly value: unknown;
|
|
13
|
+
}[];
|
|
14
|
+
};
|
|
15
|
+
}): Promise<void>;
|
|
@@ -0,0 +1,228 @@
|
|
|
1
|
+
/** Test-only shapes, named here so a test file imports one place for them. */
|
|
2
|
+
import type { HistoryMode, QueryLocation } from "../lib/location/index.js";
|
|
3
|
+
import type { OwnedPresentation, PresentationStore } from "../lib/presentation/index.js";
|
|
4
|
+
import type { HistoryPolicy } from "../lib/provider/index.js";
|
|
5
|
+
import type { Query, Slice } from "../lib/query/index.js";
|
|
6
|
+
import type { QueryIssue, SourceDelivery, SourcePage, SourceRefusal } from "../lib/result/index.js";
|
|
7
|
+
import type { RowRecord } from "../lib/rows/index.js";
|
|
8
|
+
import type { Source, SourceActionRunner, SourceCapabilities, SourceRequest } from "../lib/source/index.js";
|
|
9
|
+
import type { ViewStore } from "../lib/views/index.js";
|
|
10
|
+
import type { DecodedQuery } from "../lib/wire/index.js";
|
|
11
|
+
/**
|
|
12
|
+
* One execution the manual source was asked for, and how to answer it.
|
|
13
|
+
*
|
|
14
|
+
* @experimental Pre-release: the whole surface is still settling, and this
|
|
15
|
+
* name may change or move before the first release.
|
|
16
|
+
*/
|
|
17
|
+
export type ManualCall<TRow extends object = RowRecord> = {
|
|
18
|
+
readonly request: SourceRequest;
|
|
19
|
+
readonly deliver: (delivery: SourceDelivery<TRow>) => void;
|
|
20
|
+
/** How many times this execution's release has been called. */
|
|
21
|
+
releases: number;
|
|
22
|
+
};
|
|
23
|
+
/**
|
|
24
|
+
* Configuration of one manual source.
|
|
25
|
+
*
|
|
26
|
+
* @experimental Pre-release: the whole surface is still settling, and this
|
|
27
|
+
* name may change or move before the first release.
|
|
28
|
+
*/
|
|
29
|
+
export type ManualSourceConfig<TRow extends object = RowRecord> = {
|
|
30
|
+
/** What the source declares; nothing executable by default. */
|
|
31
|
+
readonly capabilities?: SourceCapabilities | undefined;
|
|
32
|
+
/** Refusals the declaration cannot express. */
|
|
33
|
+
readonly listRefusals?: ((query: Query) => readonly SourceRefusal[]) | undefined;
|
|
34
|
+
/** The action runner, when the declaration names actions. */
|
|
35
|
+
readonly runAction?: SourceActionRunner | undefined;
|
|
36
|
+
/**
|
|
37
|
+
* Answer every execution at once with this page. Left out, the test
|
|
38
|
+
* delivers by hand through `callAt(n).deliver`.
|
|
39
|
+
*/
|
|
40
|
+
readonly answer?: ((request: SourceRequest) => SourcePage<TRow>) | undefined;
|
|
41
|
+
};
|
|
42
|
+
/**
|
|
43
|
+
* A source whose deliveries the test drives by hand.
|
|
44
|
+
*
|
|
45
|
+
* @experimental Pre-release: the whole surface is still settling, and this
|
|
46
|
+
* name may change or move before the first release.
|
|
47
|
+
*/
|
|
48
|
+
export type ManualSource<TRow extends object = RowRecord> = {
|
|
49
|
+
readonly source: Source<TRow>;
|
|
50
|
+
/** Every execution asked for, in order. */
|
|
51
|
+
readonly calls: readonly ManualCall<TRow>[];
|
|
52
|
+
/** The nth execution, or a failure rather than a skipped assertion. */
|
|
53
|
+
readonly callAt: (index: number) => ManualCall<TRow>;
|
|
54
|
+
/** The latest execution, or a failure when none was asked for. */
|
|
55
|
+
readonly readLatest: () => ManualCall<TRow>;
|
|
56
|
+
};
|
|
57
|
+
/** A counting store, and the number of listeners it holds. */
|
|
58
|
+
export type CountingViewStore = {
|
|
59
|
+
readonly store: ViewStore;
|
|
60
|
+
/** How many listeners the store holds right now. */
|
|
61
|
+
readonly subscribers: number;
|
|
62
|
+
};
|
|
63
|
+
/** Configuration of one counting store. */
|
|
64
|
+
export type CountingViewStoreConfig = {
|
|
65
|
+
/**
|
|
66
|
+
* What `subscribe` does before registering; a throw here is the store
|
|
67
|
+
* refusing to be heard, as storage the browser blocks might.
|
|
68
|
+
*/
|
|
69
|
+
readonly onSubscribe?: (() => void) | undefined;
|
|
70
|
+
};
|
|
71
|
+
/**
|
|
72
|
+
* One write a recording location received: the parameters, and the history
|
|
73
|
+
* mode the writer asked for — null when it asked for none.
|
|
74
|
+
*
|
|
75
|
+
* @experimental Pre-release: the whole surface is still settling, and this
|
|
76
|
+
* name may change or move before the first release.
|
|
77
|
+
*/
|
|
78
|
+
export type RecordedWrite = readonly [string, HistoryMode | null];
|
|
79
|
+
/**
|
|
80
|
+
* A location port and the record of what passed through it.
|
|
81
|
+
*
|
|
82
|
+
* @experimental Pre-release: the whole surface is still settling, and this
|
|
83
|
+
* name may change or move before the first release.
|
|
84
|
+
*/
|
|
85
|
+
export type RecordingLocation = {
|
|
86
|
+
readonly location: QueryLocation;
|
|
87
|
+
/** Every write, in order. */
|
|
88
|
+
readonly writes: RecordedWrite[];
|
|
89
|
+
/** What the location read at each notification its subscribers received. */
|
|
90
|
+
readonly notifications: string[];
|
|
91
|
+
/** How many times the port was read. */
|
|
92
|
+
readonly countReads: () => number;
|
|
93
|
+
/** How many times the port was subscribed to. */
|
|
94
|
+
readonly countSubscriptions: () => number;
|
|
95
|
+
/** Move the location from outside the loop, as the browser would. */
|
|
96
|
+
readonly move: (params: string) => void;
|
|
97
|
+
};
|
|
98
|
+
/** A promise and its settling functions, to answer a stand-in call on cue. */
|
|
99
|
+
export type Deferred<T> = {
|
|
100
|
+
readonly promise: Promise<T>;
|
|
101
|
+
readonly resolve: (value: T) => void;
|
|
102
|
+
readonly reject: (error: unknown) => void;
|
|
103
|
+
};
|
|
104
|
+
/** The field whose every read a set of counted rows counts. */
|
|
105
|
+
export type CountedField = "name" | "status";
|
|
106
|
+
/** Rows whose counted field counts every read, and how many there were. */
|
|
107
|
+
export type CountedRows = {
|
|
108
|
+
readonly rows: readonly RowRecord[];
|
|
109
|
+
readonly readCount: () => number;
|
|
110
|
+
};
|
|
111
|
+
/** The row a settled page carries: an identity and nothing else. */
|
|
112
|
+
export type SettledRow = {
|
|
113
|
+
readonly id: string;
|
|
114
|
+
};
|
|
115
|
+
/**
|
|
116
|
+
* One link as the wire grammar reads it: the parameters, the query and the
|
|
117
|
+
* issues they decode to, and the parameters written back over them.
|
|
118
|
+
*/
|
|
119
|
+
export type LinkReading = {
|
|
120
|
+
readonly params: string;
|
|
121
|
+
readonly slice: Slice;
|
|
122
|
+
readonly issues: readonly QueryIssue[];
|
|
123
|
+
readonly encoded: string;
|
|
124
|
+
};
|
|
125
|
+
/**
|
|
126
|
+
* One followed link written back with its refusals carried: how it read,
|
|
127
|
+
* what was written, and how that reads.
|
|
128
|
+
*/
|
|
129
|
+
export type RespelledLink = {
|
|
130
|
+
readonly decoded: DecodedQuery;
|
|
131
|
+
readonly written: URLSearchParams;
|
|
132
|
+
readonly reread: DecodedQuery;
|
|
133
|
+
};
|
|
134
|
+
/**
|
|
135
|
+
* What a file is to the file rules, read from its name: only a source file
|
|
136
|
+
* is judged.
|
|
137
|
+
*/
|
|
138
|
+
export type FileRole = "test" | "d.ts" | "stories" | "spec" | "config" | "barrel" | "css" | "source" | "other";
|
|
139
|
+
/** What one export carries: a type, a function, a value, a class or a re-export. */
|
|
140
|
+
export type ExportKind = "type" | "function" | "value" | "class" | "reexport" | "unknown";
|
|
141
|
+
/** How a local binding is declared, as the declaration rule tells them apart. */
|
|
142
|
+
export type BindingForm =
|
|
143
|
+
/** A `function` declaration. */
|
|
144
|
+
"function"
|
|
145
|
+
/** A `class` declaration. */
|
|
146
|
+
| "class"
|
|
147
|
+
/** A variable holding a function or a plain value. */
|
|
148
|
+
| "variable"
|
|
149
|
+
/** A variable holding a call or a cast, such as a context or a memo. */
|
|
150
|
+
| "wrapped"
|
|
151
|
+
/** A type, an enum, an import, or nothing found. */
|
|
152
|
+
| "other";
|
|
153
|
+
/** A local binding: what it exports as, and how it is declared. */
|
|
154
|
+
export type LocalBinding = {
|
|
155
|
+
readonly kind: ExportKind;
|
|
156
|
+
readonly form: BindingForm;
|
|
157
|
+
};
|
|
158
|
+
/** One export of a source text, as the export rule reads it. */
|
|
159
|
+
export type ExportRecord = {
|
|
160
|
+
/** The exported name; null for an anonymous default. */
|
|
161
|
+
readonly name: string | null;
|
|
162
|
+
readonly kind: ExportKind;
|
|
163
|
+
readonly isDefault: boolean;
|
|
164
|
+
/** Exported on a separate line from a declaration that could carry it. */
|
|
165
|
+
readonly isAtEnd: boolean;
|
|
166
|
+
/** The callee of `export default callee(…)`. */
|
|
167
|
+
readonly wrapper?: string;
|
|
168
|
+
/** The wrapper is `memo` or `forwardRef` over a `function` declaration. */
|
|
169
|
+
readonly wrapsFunction?: boolean;
|
|
170
|
+
};
|
|
171
|
+
/** A presentation with the store it runs over, for one script to run twice. */
|
|
172
|
+
export type ScriptedPresentation = {
|
|
173
|
+
readonly store: PresentationStore;
|
|
174
|
+
readonly presentation: OwnedPresentation;
|
|
175
|
+
};
|
|
176
|
+
/** A machine row whose fields other than its id may be absent. */
|
|
177
|
+
export type SparseMachine = {
|
|
178
|
+
readonly id: string;
|
|
179
|
+
readonly name?: string;
|
|
180
|
+
readonly cpu?: number;
|
|
181
|
+
};
|
|
182
|
+
/** A machine row with a status, as a row model reads it. */
|
|
183
|
+
export type StatusMachine = {
|
|
184
|
+
readonly id: string;
|
|
185
|
+
readonly status: string;
|
|
186
|
+
};
|
|
187
|
+
/** A row identified by a `uuid` rather than an `id`. */
|
|
188
|
+
export type UuidRow = {
|
|
189
|
+
readonly uuid: string;
|
|
190
|
+
};
|
|
191
|
+
/** An instance of the container record type. */
|
|
192
|
+
export type ContainerInstance = {
|
|
193
|
+
readonly id: string;
|
|
194
|
+
readonly type: "container";
|
|
195
|
+
readonly processes?: number;
|
|
196
|
+
};
|
|
197
|
+
/** An instance of the virtual-machine record type. */
|
|
198
|
+
export type VirtualMachineInstance = {
|
|
199
|
+
readonly id: string;
|
|
200
|
+
readonly type: "virtual-machine";
|
|
201
|
+
readonly secureboot?: string;
|
|
202
|
+
};
|
|
203
|
+
/** A row of either record type. */
|
|
204
|
+
export type Instance = ContainerInstance | VirtualMachineInstance;
|
|
205
|
+
/**
|
|
206
|
+
* What `runFailureHandlers` takes: the context the runner hands a test.
|
|
207
|
+
*
|
|
208
|
+
* Vitest's own `TestContext` satisfies this. The `task` record is typed
|
|
209
|
+
* `object` because the runner's published `Test` type keeps its properties
|
|
210
|
+
* to itself, and naming them here would tie the parameter to one `vitest`
|
|
211
|
+
* resolution; what this reads from the record is checked at run time.
|
|
212
|
+
*
|
|
213
|
+
* @experimental Pre-release: the whole surface is still settling, and this
|
|
214
|
+
* name may change or move before the first release.
|
|
215
|
+
*/
|
|
216
|
+
export type FailureHandlersContext = {
|
|
217
|
+
/** The test's task record, whose `onFailed` handlers this runs. */
|
|
218
|
+
readonly task: object;
|
|
219
|
+
};
|
|
220
|
+
/** What a location test sets up its provider with. */
|
|
221
|
+
export type LocationSetUp = {
|
|
222
|
+
readonly href?: string | undefined;
|
|
223
|
+
readonly location?: QueryLocation | undefined;
|
|
224
|
+
readonly capabilities?: SourceCapabilities | undefined;
|
|
225
|
+
/** The query the provider starts from, as a snapshot carries it. */
|
|
226
|
+
readonly query?: string | undefined;
|
|
227
|
+
readonly history?: HistoryPolicy | undefined;
|
|
228
|
+
};
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Resolve once `check` holds: checked now, then on each notification. No
|
|
3
|
+
* ceiling of its own; a test that fails while waiting names `awaited`, and
|
|
4
|
+
* once the test is aborted, notifications are ignored.
|
|
5
|
+
*
|
|
6
|
+
* @note Impure: subscribes until the state is reached or the test fails.
|
|
7
|
+
*
|
|
8
|
+
* @experimental Pre-release: the whole surface is still settling, and this
|
|
9
|
+
* name may change or move before the first release.
|
|
10
|
+
*/
|
|
11
|
+
export default function waitForState(subscribe: (listener: () => void) => () => void, check: () => boolean, awaited: string): Promise<void>;
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@canonical/dataviews-core",
|
|
3
3
|
"description": "Framework-agnostic collection-views core for Canonical apps: query grammar, schema-enforced field validation, observation channels, selection and window projection, lifecycle transition records, the request-lifecycle coordinator, the provider assembling them, the Location port with the flat URL query grammar and the authority loop that keeps them in step, and the source contract with its local-array, observable-query-client and Relay forward-connection sources, the provider's saved views over a store it is given and its presentation — column widths, order and visibility — over a presentation store or in memory, an explicitly imported local-first IndexedDB store implementing both, and the explicitly imported virtual range a virtualized table mounts its rows by",
|
|
4
|
-
"version": "0.
|
|
4
|
+
"version": "0.48.0",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"module": "dist/esm/index.js",
|
|
7
7
|
"types": "dist/types/index.d.ts",
|
|
@@ -19,6 +19,10 @@
|
|
|
19
19
|
"types": "./dist/types/lib/indexeddb/index.d.ts",
|
|
20
20
|
"import": "./dist/esm/lib/indexeddb/index.js"
|
|
21
21
|
},
|
|
22
|
+
"./testing": {
|
|
23
|
+
"types": "./dist/types/testing/index.d.ts",
|
|
24
|
+
"import": "./dist/esm/testing/index.js"
|
|
25
|
+
},
|
|
22
26
|
"./virtualization": {
|
|
23
27
|
"types": "./dist/types/lib/virtualization/index.d.ts",
|
|
24
28
|
"import": "./dist/esm/lib/virtualization/index.js"
|
|
@@ -43,8 +47,12 @@
|
|
|
43
47
|
"publishConfig": {
|
|
44
48
|
"access": "public"
|
|
45
49
|
},
|
|
50
|
+
"engines": {
|
|
51
|
+
"node": "^22.13.0 || ^24.0.0 || ^26.0.0"
|
|
52
|
+
},
|
|
46
53
|
"scripts": {
|
|
47
|
-
"build": "tsc -p tsconfig.build.json",
|
|
54
|
+
"build": "tsc -p tsconfig.build.json && bun run build:testing",
|
|
55
|
+
"build:testing": "tsc -p tsconfig.build.testing.json && cp -R dist/testing-build/esm/testing dist/esm/ && cp -R dist/testing-build/types/testing dist/types/ && rm -rf dist/testing-build && perl -pi -e 's#\\.\\./src/lib/#../lib/#g' dist/esm/testing/*.js dist/types/testing/*.d.ts",
|
|
48
56
|
"build:all": "bun run build",
|
|
49
57
|
"check": "bun run check:biome && bun run check:ts && bun run check:webarchitect",
|
|
50
58
|
"check:webarchitect": "webarchitect library",
|
|
@@ -53,15 +61,17 @@
|
|
|
53
61
|
"check:biome:fix": "biome check --write",
|
|
54
62
|
"check:ts": "tsc --noEmit",
|
|
55
63
|
"test": "bun run test:vitest",
|
|
56
|
-
"test:
|
|
64
|
+
"test:coverage": "vitest run --coverage",
|
|
65
|
+
"test:vitest": "vitest run",
|
|
57
66
|
"test:vitest:watch": "vitest"
|
|
58
67
|
},
|
|
59
68
|
"devDependencies": {
|
|
60
|
-
"@biomejs/biome": "2.
|
|
61
|
-
"@canonical/biome-config": "0.
|
|
62
|
-
"@canonical/
|
|
63
|
-
"@canonical/
|
|
64
|
-
"@canonical/
|
|
69
|
+
"@biomejs/biome": "2.6.9",
|
|
70
|
+
"@canonical/biome-config": "0.47.0",
|
|
71
|
+
"@canonical/i18n-core": "^0.48.0",
|
|
72
|
+
"@canonical/router-core": "^0.48.0",
|
|
73
|
+
"@canonical/typescript-config": "0.46.0",
|
|
74
|
+
"@canonical/webarchitect": "0.46.0",
|
|
65
75
|
"@tanstack/query-core": "^5.102.8",
|
|
66
76
|
"@types/node": "^26.0.0",
|
|
67
77
|
"@types/relay-runtime": "^20.1.1",
|
|
@@ -71,5 +81,5 @@
|
|
|
71
81
|
"typescript": "^7.0.2",
|
|
72
82
|
"vitest": "^5.0.0"
|
|
73
83
|
},
|
|
74
|
-
"gitHead": "
|
|
84
|
+
"gitHead": "aee4aebab851f90159776a7ba658d0c62e0d2bf4"
|
|
75
85
|
}
|