@contember/binding 1.2.0-alpha.0 → 1.2.0-alpha.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/development/accessorTree/AccessorTree.js +2 -2
- package/dist/development/accessorTree/AccessorTree.js.map +1 -1
- package/dist/development/coreComponents/DataBindingProvider.js.map +1 -1
- package/dist/development/coreComponents/Entity.js.map +1 -1
- package/dist/development/coreComponents/EntityList.js.map +1 -1
- package/dist/development/coreComponents/EntityListSubTree.js.map +1 -1
- package/dist/development/coreComponents/EntitySubTree.js.map +1 -1
- package/dist/development/coreComponents/Field.js.map +1 -1
- package/dist/development/coreComponents/HasMany.js.map +1 -1
- package/dist/development/coreComponents/HasOne.js.map +1 -1
- package/dist/development/coreComponents/ParentEntity.js.map +1 -1
- package/dist/development/helperComponents/DeferredSubTrees.js.map +1 -1
- package/dist/development/helperComponents/EntityView.js.map +1 -1
- package/dist/development/helperComponents/FieldView.js.map +1 -1
- package/dist/development/helperComponents/If.js.map +1 -1
- package/dist/development/helperComponents/StaticRender.js.map +1 -1
- package/dist/development/helperComponents/SugaredField.js.map +1 -1
- package/dist/development/helperComponents/helpers/evaluateCondition.js.map +1 -1
- package/dist/development/treeParameters/LeafField.js.map +1 -1
- package/dist/production/accessorTree/AccessorTree.js +2 -2
- package/dist/production/accessorTree/AccessorTree.js.map +1 -1
- package/dist/production/coreComponents/DataBindingProvider.js.map +1 -1
- package/dist/production/coreComponents/Entity.js.map +1 -1
- package/dist/production/coreComponents/EntityList.js.map +1 -1
- package/dist/production/coreComponents/EntityListSubTree.js.map +1 -1
- package/dist/production/coreComponents/EntitySubTree.js.map +1 -1
- package/dist/production/coreComponents/Field.js.map +1 -1
- package/dist/production/coreComponents/HasMany.js.map +1 -1
- package/dist/production/coreComponents/HasOne.js.map +1 -1
- package/dist/production/coreComponents/ParentEntity.js.map +1 -1
- package/dist/production/helperComponents/DeferredSubTrees.js.map +1 -1
- package/dist/production/helperComponents/EntityView.js.map +1 -1
- package/dist/production/helperComponents/FieldView.js.map +1 -1
- package/dist/production/helperComponents/If.js.map +1 -1
- package/dist/production/helperComponents/StaticRender.js.map +1 -1
- package/dist/production/helperComponents/SugaredField.js.map +1 -1
- package/dist/production/helperComponents/helpers/evaluateCondition.js.map +1 -1
- package/dist/production/treeParameters/LeafField.js.map +1 -1
- package/dist/types/accessorTree/AccessorTree.d.ts +7 -4
- package/dist/types/accessorTree/AccessorTree.d.ts.map +1 -1
- package/dist/types/coreComponents/DataBindingProvider.d.ts +10 -0
- package/dist/types/coreComponents/DataBindingProvider.d.ts.map +1 -1
- package/dist/types/coreComponents/Entity.d.ts +3 -0
- package/dist/types/coreComponents/Entity.d.ts.map +1 -1
- package/dist/types/coreComponents/EntityList.d.ts +3 -0
- package/dist/types/coreComponents/EntityList.d.ts.map +1 -1
- package/dist/types/coreComponents/EntityListSubTree.d.ts +10 -0
- package/dist/types/coreComponents/EntityListSubTree.d.ts.map +1 -1
- package/dist/types/coreComponents/EntitySubTree.d.ts +10 -0
- package/dist/types/coreComponents/EntitySubTree.d.ts.map +1 -1
- package/dist/types/coreComponents/Field.d.ts +3 -0
- package/dist/types/coreComponents/Field.d.ts.map +1 -1
- package/dist/types/coreComponents/HasMany.d.ts +3 -0
- package/dist/types/coreComponents/HasMany.d.ts.map +1 -1
- package/dist/types/coreComponents/HasOne.d.ts +3 -0
- package/dist/types/coreComponents/HasOne.d.ts.map +1 -1
- package/dist/types/coreComponents/ParentEntity.d.ts +3 -0
- package/dist/types/coreComponents/ParentEntity.d.ts.map +1 -1
- package/dist/types/helperComponents/DeferredSubTrees.d.ts +3 -0
- package/dist/types/helperComponents/DeferredSubTrees.d.ts.map +1 -1
- package/dist/types/helperComponents/EntityView.d.ts +3 -0
- package/dist/types/helperComponents/EntityView.d.ts.map +1 -1
- package/dist/types/helperComponents/FieldView.d.ts +13 -0
- package/dist/types/helperComponents/FieldView.d.ts.map +1 -1
- package/dist/types/helperComponents/If.d.ts +3 -0
- package/dist/types/helperComponents/If.d.ts.map +1 -1
- package/dist/types/helperComponents/StaticRender.d.ts +3 -0
- package/dist/types/helperComponents/StaticRender.d.ts.map +1 -1
- package/dist/types/helperComponents/SugaredField.d.ts +3 -0
- package/dist/types/helperComponents/SugaredField.d.ts.map +1 -1
- package/dist/types/treeParameters/FieldEventListeners.d.ts +5 -2
- package/dist/types/treeParameters/FieldEventListeners.d.ts.map +1 -1
- package/dist/types/treeParameters/LeafField.d.ts +2 -2
- package/dist/types/treeParameters/LeafField.d.ts.map +1 -1
- package/dist/types/treeParameters/QualifiedFieldList.d.ts +7 -8
- package/dist/types/treeParameters/QualifiedFieldList.d.ts.map +1 -1
- package/dist/types/treeParameters/RelativeSingleField.d.ts +8 -8
- package/dist/types/treeParameters/RelativeSingleField.d.ts.map +1 -1
- package/dist/types/tsconfig.tsbuildinfo +1 -1
- package/package.json +5 -5
- package/src/accessorTree/AccessorTree.tsx +4 -1
- package/src/coreComponents/DataBindingProvider.tsx +10 -0
- package/src/coreComponents/Entity.tsx +3 -0
- package/src/coreComponents/EntityList.tsx +3 -0
- package/src/coreComponents/EntityListSubTree.tsx +10 -0
- package/src/coreComponents/EntitySubTree.tsx +10 -0
- package/src/coreComponents/Field.tsx +3 -0
- package/src/coreComponents/HasMany.tsx +3 -0
- package/src/coreComponents/HasOne.tsx +3 -0
- package/src/coreComponents/ParentEntity.tsx +3 -0
- package/src/helperComponents/DeferredSubTrees.tsx +3 -0
- package/src/helperComponents/EntityView.tsx +3 -0
- package/src/helperComponents/FieldView.tsx +13 -0
- package/src/helperComponents/If.tsx +3 -0
- package/src/helperComponents/StaticRender.tsx +3 -0
- package/src/helperComponents/SugaredField.tsx +3 -0
- package/src/helperComponents/helpers/evaluateCondition.ts +1 -1
- package/src/treeParameters/FieldEventListeners.ts +15 -5
- package/src/treeParameters/LeafField.ts +6 -4
- package/src/treeParameters/QualifiedFieldList.ts +24 -17
- package/src/treeParameters/RelativeSingleField.ts +19 -12
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FieldView.js","sources":["../../../src/helperComponents/FieldView.tsx"],"sourcesContent":["import { useArrayMapMemo, useConstantLengthInvariant } from '@contember/react-utils'\nimport { ReactElement, ReactNode, useCallback, useMemo } from 'react'\nimport { useEntity } from '../accessorPropagation'\nimport type { FieldAccessor } from '../accessors'\nimport { throwBindingError } from '../BindingError'\nimport { Component } from '../coreComponents'\nimport { QueryLanguage } from '../queryLanguage'\nimport type { FieldValue, RelativeSingleField, SugaredRelativeSingleField } from '../treeParameters'\nimport { SugaredField } from './SugaredField'\n\ninterface FieldViewCommonProps {\n\tfallbackIfUnpersisted?: ReactNode\n}\n\ntype FieldViewProps = FieldViewCommonProps &\n\t(\n\t\t| {\n\t\t\t\trender: (...accessors: FieldAccessor[]) => ReactNode\n\t\t\t\tfield: string | SugaredRelativeSingleField\n\t\t }\n\t\t| {\n\t\t\t\trender: (...accessors: FieldAccessor[]) => ReactNode\n\t\t\t\tfields: Array<string | SugaredRelativeSingleField>\n\t\t }\n\t)\n\n// Just short type aliases so that we can type the overloads in a tractable fashion.\ntype FV = FieldValue\ntype SRSF = string | SugaredRelativeSingleField\ntype CP = FieldViewCommonProps\ntype RN = ReactNode\ntype REN = ReactElement | null\n\nexport const FieldView = Component<FieldViewProps>(\n\tprops => {\n\t\tconst { fallbackIfUnpersisted, render } = props\n\t\tconst fields =\n\t\t\t'fields' in props && Array.isArray(props.fields)\n\t\t\t\t? props.fields\n\t\t\t\t: 'field' in props && props.field\n\t\t\t\t? [props.field]\n\t\t\t\t: throwBindingError(`FieldView: failed to supply either the 'field' or the 'fields' prop.`)\n\n\t\tuseConstantLengthInvariant(\n\t\t\tfields,\n\t\t\t`The number of fields in the 'fields' prop of the 'FieldView' must remain constant between renders!`,\n\t\t)\n\n\t\t// TODO over-subscribe less\n\t\tconst entityAccessor = useEntity()\n\t\tconst environment = entityAccessor.environment\n\n\t\tconst desugarField = useCallback(\n\t\t\t(rsf: SRSF) => QueryLanguage.desugarRelativeSingleField(rsf, environment),\n\t\t\t[environment],\n\t\t)\n\t\tconst desugaredFields = useArrayMapMemo(fields, desugarField)\n\n\t\tconst retrieveField = useCallback(\n\t\t\t(desugaredRsf: RelativeSingleField) => entityAccessor.getRelativeSingleField(desugaredRsf),\n\t\t\t[entityAccessor],\n\t\t)\n\t\tconst accessors = useArrayMapMemo(desugaredFields, retrieveField)\n\n\t\t// TODO we probably want something like useDeferredValue from here.\n\t\t// Will probably just wait for Concurrent React though.\n\t\tconst output = useMemo(() => {\n\t\t\tif (!entityAccessor.existsOnServer && fallbackIfUnpersisted !== undefined) {\n\t\t\t\treturn fallbackIfUnpersisted\n\t\t\t}\n\t\t\treturn render(...accessors)\n\t\t}, [accessors, entityAccessor.existsOnServer, fallbackIfUnpersisted, render])\n\n\t\treturn <>{output}</>\n\t},\n\tprops => {\n\t\tconst fields =\n\t\t\t'fields' in props && Array.isArray(props.fields)\n\t\t\t\t? props.fields\n\t\t\t\t: 'field' in props && props.field\n\t\t\t\t? [props.field]\n\t\t\t\t: throwBindingError(`FieldView: failed to supply either the 'field' or the 'fields' prop.`)\n\t\treturn (\n\t\t\t<>\n\t\t\t\t{props.fallbackIfUnpersisted}\n\t\t\t\t{fields.map((field, i) => (\n\t\t\t\t\t<SugaredField key={i} field={field} />\n\t\t\t\t))}\n\t\t\t</>\n\t\t)\n\t},\n\t'FieldView',\n) as {\n\t<FV1 extends FV>(props: CP & { field: SRSF; render: (field1: FieldAccessor<FV1>) => RN }): REN\n\t<FV1 extends FV>(props: CP & { fields: [SRSF]; render: (field1: FieldAccessor<FV1>) => RN }): REN\n\t<FV1 extends FV, FV2 extends FV>(\n\t\tprops: CP & { fields: [SRSF, SRSF]; render: (field1: FieldAccessor<FV1>, field2: FieldAccessor<FV2>) => RN },\n\t): REN\n\t<FV1 extends FV, FV2 extends FV, FV3 extends FV>(\n\t\tprops: CP & {\n\t\t\tfields: [SRSF, SRSF, SRSF]\n\t\t\trender: (field1: FieldAccessor<FV1>, field2: FieldAccessor<FV2>, field3: FieldAccessor<FV3>) => RN\n\t\t},\n\t): REN\n\t<FV1 extends FV, FV2 extends FV, FV3 extends FV, FV4 extends FV>(\n\t\tprops: CP & {\n\t\t\tfields: [SRSF, SRSF, SRSF, SRSF]\n\t\t\trender: (\n\t\t\t\tfield1: FieldAccessor<FV1>,\n\t\t\t\tfield2: FieldAccessor<FV2>,\n\t\t\t\tfield3: FieldAccessor<FV3>,\n\t\t\t\tfield4: FieldAccessor<FV4>,\n\t\t\t) => RN\n\t\t},\n\t): REN\n\t<FV1 extends FV, FV2 extends FV, FV3 extends FV, FV4 extends FV, FV5 extends FV>(\n\t\tprops: CP & {\n\t\t\tfields: [SRSF, SRSF, SRSF, SRSF, SRSF]\n\t\t\trender: (\n\t\t\t\tfield1: FieldAccessor<FV1>,\n\t\t\t\tfield2: FieldAccessor<FV2>,\n\t\t\t\tfield3: FieldAccessor<FV3>,\n\t\t\t\tfield4: FieldAccessor<FV4>,\n\t\t\t\tfield5: FieldAccessor<FV5>,\n\t\t\t) => RN\n\t\t},\n\t): REN\n\t(props: FieldViewProps): REN\n}\n"],"names":[],"mappings":";;;;;;;;
|
|
1
|
+
{"version":3,"file":"FieldView.js","sources":["../../../src/helperComponents/FieldView.tsx"],"sourcesContent":["import { useArrayMapMemo, useConstantLengthInvariant } from '@contember/react-utils'\nimport { ReactElement, ReactNode, useCallback, useMemo } from 'react'\nimport { useEntity } from '../accessorPropagation'\nimport type { FieldAccessor } from '../accessors'\nimport { throwBindingError } from '../BindingError'\nimport { Component } from '../coreComponents'\nimport { QueryLanguage } from '../queryLanguage'\nimport type { FieldValue, RelativeSingleField, SugaredRelativeSingleField } from '../treeParameters'\nimport { SugaredField } from './SugaredField'\n\ninterface FieldViewCommonProps {\n\tfallbackIfUnpersisted?: ReactNode\n}\n\ntype FieldViewProps = FieldViewCommonProps &\n\t(\n\t\t| {\n\t\t\t\trender: (...accessors: FieldAccessor[]) => ReactNode\n\t\t\t\tfield: string | SugaredRelativeSingleField\n\t\t }\n\t\t| {\n\t\t\t\trender: (...accessors: FieldAccessor[]) => ReactNode\n\t\t\t\tfields: Array<string | SugaredRelativeSingleField>\n\t\t }\n\t)\n\n// Just short type aliases so that we can type the overloads in a tractable fashion.\ntype FV = FieldValue\ntype SRSF = string | SugaredRelativeSingleField\ntype CP = FieldViewCommonProps\ntype RN = ReactNode\ntype REN = ReactElement | null\n\n/**\n * Base field view component with no default formatting.\n *\n * @example\n * ```\n * <FieldView\n * field=\"startsAt\"\n * render={(accessor) => <>{accessor.value}</>}\n * />\n * ```\n *\n * @group Field Views\n */\nexport const FieldView = Component<FieldViewProps>(\n\tprops => {\n\t\tconst { fallbackIfUnpersisted, render } = props\n\t\tconst fields =\n\t\t\t'fields' in props && Array.isArray(props.fields)\n\t\t\t\t? props.fields\n\t\t\t\t: 'field' in props && props.field\n\t\t\t\t? [props.field]\n\t\t\t\t: throwBindingError(`FieldView: failed to supply either the 'field' or the 'fields' prop.`)\n\n\t\tuseConstantLengthInvariant(\n\t\t\tfields,\n\t\t\t`The number of fields in the 'fields' prop of the 'FieldView' must remain constant between renders!`,\n\t\t)\n\n\t\t// TODO over-subscribe less\n\t\tconst entityAccessor = useEntity()\n\t\tconst environment = entityAccessor.environment\n\n\t\tconst desugarField = useCallback(\n\t\t\t(rsf: SRSF) => QueryLanguage.desugarRelativeSingleField(rsf, environment),\n\t\t\t[environment],\n\t\t)\n\t\tconst desugaredFields = useArrayMapMemo(fields, desugarField)\n\n\t\tconst retrieveField = useCallback(\n\t\t\t(desugaredRsf: RelativeSingleField) => entityAccessor.getRelativeSingleField(desugaredRsf),\n\t\t\t[entityAccessor],\n\t\t)\n\t\tconst accessors = useArrayMapMemo(desugaredFields, retrieveField)\n\n\t\t// TODO we probably want something like useDeferredValue from here.\n\t\t// Will probably just wait for Concurrent React though.\n\t\tconst output = useMemo(() => {\n\t\t\tif (!entityAccessor.existsOnServer && fallbackIfUnpersisted !== undefined) {\n\t\t\t\treturn fallbackIfUnpersisted\n\t\t\t}\n\t\t\treturn render(...accessors)\n\t\t}, [accessors, entityAccessor.existsOnServer, fallbackIfUnpersisted, render])\n\n\t\treturn <>{output}</>\n\t},\n\tprops => {\n\t\tconst fields =\n\t\t\t'fields' in props && Array.isArray(props.fields)\n\t\t\t\t? props.fields\n\t\t\t\t: 'field' in props && props.field\n\t\t\t\t? [props.field]\n\t\t\t\t: throwBindingError(`FieldView: failed to supply either the 'field' or the 'fields' prop.`)\n\t\treturn (\n\t\t\t<>\n\t\t\t\t{props.fallbackIfUnpersisted}\n\t\t\t\t{fields.map((field, i) => (\n\t\t\t\t\t<SugaredField key={i} field={field} />\n\t\t\t\t))}\n\t\t\t</>\n\t\t)\n\t},\n\t'FieldView',\n) as {\n\t<FV1 extends FV>(props: CP & { field: SRSF; render: (field1: FieldAccessor<FV1>) => RN }): REN\n\t<FV1 extends FV>(props: CP & { fields: [SRSF]; render: (field1: FieldAccessor<FV1>) => RN }): REN\n\t<FV1 extends FV, FV2 extends FV>(\n\t\tprops: CP & { fields: [SRSF, SRSF]; render: (field1: FieldAccessor<FV1>, field2: FieldAccessor<FV2>) => RN },\n\t): REN\n\t<FV1 extends FV, FV2 extends FV, FV3 extends FV>(\n\t\tprops: CP & {\n\t\t\tfields: [SRSF, SRSF, SRSF]\n\t\t\trender: (field1: FieldAccessor<FV1>, field2: FieldAccessor<FV2>, field3: FieldAccessor<FV3>) => RN\n\t\t},\n\t): REN\n\t<FV1 extends FV, FV2 extends FV, FV3 extends FV, FV4 extends FV>(\n\t\tprops: CP & {\n\t\t\tfields: [SRSF, SRSF, SRSF, SRSF]\n\t\t\trender: (\n\t\t\t\tfield1: FieldAccessor<FV1>,\n\t\t\t\tfield2: FieldAccessor<FV2>,\n\t\t\t\tfield3: FieldAccessor<FV3>,\n\t\t\t\tfield4: FieldAccessor<FV4>,\n\t\t\t) => RN\n\t\t},\n\t): REN\n\t<FV1 extends FV, FV2 extends FV, FV3 extends FV, FV4 extends FV, FV5 extends FV>(\n\t\tprops: CP & {\n\t\t\tfields: [SRSF, SRSF, SRSF, SRSF, SRSF]\n\t\t\trender: (\n\t\t\t\tfield1: FieldAccessor<FV1>,\n\t\t\t\tfield2: FieldAccessor<FV2>,\n\t\t\t\tfield3: FieldAccessor<FV3>,\n\t\t\t\tfield4: FieldAccessor<FV4>,\n\t\t\t\tfield5: FieldAccessor<FV5>,\n\t\t\t) => RN\n\t\t},\n\t): REN\n\t(props: FieldViewProps): REN\n}\n"],"names":[],"mappings":";;;;;;;;AA8CO,MAAM,YAAY;AAAA,EACxB,CAAS,UAAA;AACF,UAAA,EAAE,uBAAuB,OAAW,IAAA;AAC1C,UAAM,SACL,YAAY,SAAS,MAAM,QAAQ,MAAM,MAAM,IAC5C,MAAM,SACN,WAAW,SAAS,MAAM,QAC1B,CAAC,MAAM,KAAK,IACZ,kBAAkB,sEAAsE;AAE5F;AAAA,MACC;AAAA,MACA;AAAA,IAAA;AAID,UAAM,iBAAiB;AACvB,UAAM,cAAc,eAAe;AAEnC,UAAM,eAAe;AAAA,MACpB,CAAC,QAAc,cAAc,2BAA2B,KAAK,WAAW;AAAA,MACxE,CAAC,WAAW;AAAA,IAAA;AAEP,UAAA,kBAAkB,gBAAgB,QAAQ,YAAY;AAE5D,UAAM,gBAAgB;AAAA,MACrB,CAAC,iBAAsC,eAAe,uBAAuB,YAAY;AAAA,MACzF,CAAC,cAAc;AAAA,IAAA;AAEV,UAAA,YAAY,gBAAgB,iBAAiB,aAAa;AAI1D,UAAA,SAAS,QAAQ,MAAM;AAC5B,UAAI,CAAC,eAAe,kBAAkB,0BAA0B,QAAW;AACnE,eAAA;AAAA,MACR;AACO,aAAA,OAAO,GAAG,SAAS;AAAA,IAAA,GACxB,CAAC,WAAW,eAAe,gBAAgB,uBAAuB,MAAM,CAAC;AAE5E,2CAAU,UAAO,OAAA,CAAA;AAAA,EAClB;AAAA,EACA,CAAS,UAAA;AACR,UAAM,SACL,YAAY,SAAS,MAAM,QAAQ,MAAM,MAAM,IAC5C,MAAM,SACN,WAAW,SAAS,MAAM,QAC1B,CAAC,MAAM,KAAK,IACZ,kBAAkB,sEAAsE;AAC5F,WAEG,qBAAA,UAAA,EAAA,UAAA;AAAA,MAAM,MAAA;AAAA,MACN,OAAO,IAAI,CAAC,OAAO,MAClB,oBAAA,cAAA,EAAqB,SAAH,CAAiB,CACpC;AAAA,IACF,EAAA,CAAA;AAAA,EAEF;AAAA,EACA;AACD;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"If.js","sources":["../../../src/helperComponents/If.tsx"],"sourcesContent":["import type { ReactNode } from 'react'\nimport { useMemo } from 'react'\nimport { Component, Field } from '../coreComponents'\nimport { EntityAccessor } from '../accessors'\nimport { QueryLanguage } from '../queryLanguage'\nimport { useEntity, useEnvironment } from '../accessorPropagation'\nimport { Filter } from '../treeParameters'\nimport { FilterFieldsCollector } from './helpers/FilterFieldsCollector'\nimport { FilterEvaluator } from './helpers/FilterEvaluator'\n\nexport type IfProps =\n\t| IfFilterProps\n\t| IfCallbackProps\n\nexport interface IfFilterProps {\n\tcondition: string | Filter\n\tchildren?: ReactNode\n}\n\nexport interface IfCallbackProps {\n\tcondition: (accessor: EntityAccessor) => boolean\n\tchildren?: ReactNode\n}\n\nexport const If = Component<IfProps>(props => {\n\t\treturn typeof props.condition !== 'function'\n\t\t\t? <IfFilter condition={props.condition}>{props.children}</IfFilter>\n\t\t\t: <IfCallback condition={props.condition}>{props.children}</IfCallback>\n\t},\n\t'If',\n)\n\nconst IfCallback = Component<IfCallbackProps>(\n\t({ children, condition }) => {\n\t\tconst entity = useEntity()\n\t\tconst evaluated = useMemo(() => condition(entity), [condition, entity])\n\n\t\treturn evaluated ? <>{children}</> : null\n\t},\n\t({ children }) => {\n\t\treturn <>{children}</>\n\t},\n\t'IfCallback',\n)\n\nconst IfFilter = Component<IfFilterProps>(\n\t({ children, condition }) => {\n\t\tconst env = useEnvironment()\n\t\tconst entity = useEntity()\n\n\t\tconst schema = env.getSchema()\n\t\tconst evaluated = useMemo(\n\t\t\t() => new FilterEvaluator(schema).evaluateFilter(entity, QueryLanguage.desugarFilter(condition, env)),\n\t\t\t[condition, entity, env, schema],\n\t\t)\n\n\t\treturn evaluated ? <>{children}</> : null\n\t},\n\t({ children, condition }, env) => {\n\t\tconst desugaredFilter = QueryLanguage.desugarFilter(condition, env)\n\t\tconst collectedFields = new FilterFieldsCollector(env.getSchema(), desugaredFilter).collectFields(env.getSubTreeNode().entity)\n\t\tconst additionalFields = <>{Array.from(collectedFields).map(it => <Field field={it} key={it} />)}</>\n\n\t\treturn <>\n\t\t\t{additionalFields}\n\t\t\t{children}\n\t\t</>\n\t},\n\t'IfFilter',\n)\n\n"],"names":[],"mappings":";;;;;;;;;
|
|
1
|
+
{"version":3,"file":"If.js","sources":["../../../src/helperComponents/If.tsx"],"sourcesContent":["import type { ReactNode } from 'react'\nimport { useMemo } from 'react'\nimport { Component, Field } from '../coreComponents'\nimport { EntityAccessor } from '../accessors'\nimport { QueryLanguage } from '../queryLanguage'\nimport { useEntity, useEnvironment } from '../accessorPropagation'\nimport { Filter } from '../treeParameters'\nimport { FilterFieldsCollector } from './helpers/FilterFieldsCollector'\nimport { FilterEvaluator } from './helpers/FilterEvaluator'\n\nexport type IfProps =\n\t| IfFilterProps\n\t| IfCallbackProps\n\nexport interface IfFilterProps {\n\tcondition: string | Filter\n\tchildren?: ReactNode\n}\n\nexport interface IfCallbackProps {\n\tcondition: (accessor: EntityAccessor) => boolean\n\tchildren?: ReactNode\n}\n\n/**\n * @group Logic Components\n */\nexport const If = Component<IfProps>(props => {\n\t\treturn typeof props.condition !== 'function'\n\t\t\t? <IfFilter condition={props.condition}>{props.children}</IfFilter>\n\t\t\t: <IfCallback condition={props.condition}>{props.children}</IfCallback>\n\t},\n\t'If',\n)\n\nconst IfCallback = Component<IfCallbackProps>(\n\t({ children, condition }) => {\n\t\tconst entity = useEntity()\n\t\tconst evaluated = useMemo(() => condition(entity), [condition, entity])\n\n\t\treturn evaluated ? <>{children}</> : null\n\t},\n\t({ children }) => {\n\t\treturn <>{children}</>\n\t},\n\t'IfCallback',\n)\n\nconst IfFilter = Component<IfFilterProps>(\n\t({ children, condition }) => {\n\t\tconst env = useEnvironment()\n\t\tconst entity = useEntity()\n\n\t\tconst schema = env.getSchema()\n\t\tconst evaluated = useMemo(\n\t\t\t() => new FilterEvaluator(schema).evaluateFilter(entity, QueryLanguage.desugarFilter(condition, env)),\n\t\t\t[condition, entity, env, schema],\n\t\t)\n\n\t\treturn evaluated ? <>{children}</> : null\n\t},\n\t({ children, condition }, env) => {\n\t\tconst desugaredFilter = QueryLanguage.desugarFilter(condition, env)\n\t\tconst collectedFields = new FilterFieldsCollector(env.getSchema(), desugaredFilter).collectFields(env.getSubTreeNode().entity)\n\t\tconst additionalFields = <>{Array.from(collectedFields).map(it => <Field field={it} key={it} />)}</>\n\n\t\treturn <>\n\t\t\t{additionalFields}\n\t\t\t{children}\n\t\t</>\n\t},\n\t'IfFilter',\n)\n\n"],"names":[],"mappings":";;;;;;;;;AA2BO,MAAM,KAAK;AAAA,EAAmB,CAAS,UAAA;AAC5C,WAAO,OAAO,MAAM,cAAc,aAC9B,oBAAA,UAAA,EAAS,WAAW,MAAM,WAAY,UAAM,MAAA,SAAA,CAAS,IACrD,oBAAA,YAAA,EAAW,WAAW,MAAM,WAAY,gBAAM,SAAS,CAAA;AAAA,EAC5D;AAAA,EACA;AACD;AAEA,MAAM,aAAa;AAAA,EAClB,CAAC,EAAE,UAAU,gBAAgB;AAC5B,UAAM,SAAS;AACT,UAAA,YAAY,QAAQ,MAAM,UAAU,MAAM,GAAG,CAAC,WAAW,MAAM,CAAC;AAE/D,WAAA,YAAe,oBAAA,UAAA,EAAA,SAAA,CAAS,IAAM;AAAA,EACtC;AAAA,EACA,CAAC,EAAE,SAAA,MAAe;AACjB,2CAAU,SAAS,CAAA;AAAA,EACpB;AAAA,EACA;AACD;AAEA,MAAM,WAAW;AAAA,EAChB,CAAC,EAAE,UAAU,gBAAgB;AAC5B,UAAM,MAAM;AACZ,UAAM,SAAS;AAET,UAAA,SAAS,IAAI;AACnB,UAAM,YAAY;AAAA,MACjB,MAAM,IAAI,gBAAgB,MAAM,EAAE,eAAe,QAAQ,cAAc,cAAc,WAAW,GAAG,CAAC;AAAA,MACpG,CAAC,WAAW,QAAQ,KAAK,MAAM;AAAA,IAAA;AAGzB,WAAA,YAAe,oBAAA,UAAA,EAAA,SAAA,CAAS,IAAM;AAAA,EACtC;AAAA,EACA,CAAC,EAAE,UAAU,aAAa,QAAQ;AACjC,UAAM,kBAAkB,cAAc,cAAc,WAAW,GAAG;AAClE,UAAM,kBAAkB,IAAI,sBAAsB,IAAI,UAAU,GAAG,eAAe,EAAE,cAAc,IAAI,eAAe,EAAE,MAAM;AAC7H,UAAM,mBAAmB,oBAAA,UAAA,EAAG,UAAM,MAAA,KAAK,eAAe,EAAE,IAAI,CAAM,OAAA,oBAAC,OAAM,EAAA,OAAO,MAAS,EAAI,CAAE,EAAE,CAAA;AAEjG,WACE,qBAAA,UAAA,EAAA,UAAA;AAAA,MAAA;AAAA,MACA;AAAA,IACF,EAAA,CAAA;AAAA,EACD;AAAA,EACA;AACD;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"StaticRender.js","sources":["../../../src/helperComponents/StaticRender.tsx"],"sourcesContent":["import type { ReactNode } from 'react'\nimport { Component } from '../coreComponents'\n\nexport interface StaticRenderProps {\n\tchildren?: ReactNode\n}\n\nexport const StaticRender = Component<StaticRenderProps>(\n\t() => null,\n\t({ children }) => <>{children}</>,\n\t'StaticRender',\n)\n"],"names":[],"mappings":";;
|
|
1
|
+
{"version":3,"file":"StaticRender.js","sources":["../../../src/helperComponents/StaticRender.tsx"],"sourcesContent":["import type { ReactNode } from 'react'\nimport { Component } from '../coreComponents'\n\nexport interface StaticRenderProps {\n\tchildren?: ReactNode\n}\n\n/**\n * @group Data binding\n */\nexport const StaticRender = Component<StaticRenderProps>(\n\t() => null,\n\t({ children }) => <>{children}</>,\n\t'StaticRender',\n)\n"],"names":[],"mappings":";;AAUO,MAAM,eAAe;AAAA,EAC3B,MAAM;AAAA,EACN,CAAC,EAAE,SAAS,sCAAS,SAAS,CAAA;AAAA,EAC9B;AACD;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SugaredField.js","sources":["../../../src/helperComponents/SugaredField.tsx"],"sourcesContent":["import { Component, Field, FieldProps } from '../coreComponents'\nimport type { SugaredRelativeSingleField } from '../treeParameters'\nimport { FieldValue } from '../treeParameters'\nimport { ReactElement } from 'react'\n\nexport interface SugaredFieldProps<Persisted extends FieldValue = FieldValue> extends Omit<FieldProps<Persisted>, 'field'> {\n\tfield: string | SugaredRelativeSingleField\n}\n\nexport const SugaredField = Component(<Persisted extends FieldValue = FieldValue>(props: SugaredFieldProps<Persisted>) => {\n\tif (typeof props.field === 'string') {\n\t\treturn <Field {...props} field={props.field} />\n\t}\n\treturn <Field {...props} {...props.field} />\n}, 'SugaredField') as <Persisted extends FieldValue = FieldValue>(props: SugaredFieldProps<Persisted>) => ReactElement\n"],"names":[],"mappings":";;;
|
|
1
|
+
{"version":3,"file":"SugaredField.js","sources":["../../../src/helperComponents/SugaredField.tsx"],"sourcesContent":["import { Component, Field, FieldProps } from '../coreComponents'\nimport type { SugaredRelativeSingleField } from '../treeParameters'\nimport { FieldValue } from '../treeParameters'\nimport { ReactElement } from 'react'\n\nexport interface SugaredFieldProps<Persisted extends FieldValue = FieldValue> extends Omit<FieldProps<Persisted>, 'field'> {\n\tfield: string | SugaredRelativeSingleField\n}\n\n/**\n * @group Data binding\n */\nexport const SugaredField = Component(<Persisted extends FieldValue = FieldValue>(props: SugaredFieldProps<Persisted>) => {\n\tif (typeof props.field === 'string') {\n\t\treturn <Field {...props} field={props.field} />\n\t}\n\treturn <Field {...props} {...props.field} />\n}, 'SugaredField') as <Persisted extends FieldValue = FieldValue>(props: SugaredFieldProps<Persisted>) => ReactElement\n"],"names":[],"mappings":";;;AAYa,MAAA,eAAe,UAAU,CAA4C,UAAwC;AACrH,MAAA,OAAO,MAAM,UAAU,UAAU;AACpC,+BAAQ,OAAO,EAAA,GAAG,OAAO,OAAO,MAAM,MAAO,CAAA;AAAA,EAC9C;AACA,6BAAQ,OAAO,EAAA,GAAG,OAAQ,GAAG,MAAM,MAAO,CAAA;AAC3C,GAAG,cAAc;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"evaluateCondition.js","sources":["../../../../src/helperComponents/helpers/evaluateCondition.ts"],"sourcesContent":["import { GraphQlLiteral, Input } from '@contember/client'\nimport { FieldValue } from '../../treeParameters'\nimport { BindingError } from '../../BindingError'\n\nconst unwrapGraphqlLiteral = (value: Input.ColumnValue<GraphQlLiteral>): any => {\n\tif (value instanceof GraphQlLiteral) {\n\t\treturn value.value\n\t}\n\treturn value\n}\n\nexport const evaluateCondition = (value: FieldValue | null, condition: Input.Condition<Input.ColumnValue<GraphQlLiteral>>) => {\n\t\tconst handlers: {\n\t\t\t[K in keyof Required<Input.Condition<any>>]: (\n\t\t\t\tparam: Exclude<Input.Condition<any>[K], undefined>,\n\t\t\t) => boolean\n\t\t} = {\n\t\t\tand: expr => expr.every(it => evaluateCondition(value, it)),\n\t\t\tor: expr => expr.some(it => evaluateCondition(value, it)),\n\t\t\tnot: expr => !evaluateCondition(value, expr),\n\t\t\teq: expr => value === unwrapGraphqlLiteral(expr),\n\t\t\tnotEq: expr => value !== unwrapGraphqlLiteral(expr),\n\t\t\tisNull: expr => (value === null) === expr,\n\t\t\tin: expr => expr.map(unwrapGraphqlLiteral).includes(value),\n\t\t\tnotIn: expr => !expr.map(unwrapGraphqlLiteral).includes(value),\n\t\t\tlt: expr => value !== null && value < unwrapGraphqlLiteral(expr),\n\t\t\tlte: expr => value !== null && value <= unwrapGraphqlLiteral(expr),\n\t\t\tgt: expr => value !== null && value > unwrapGraphqlLiteral(expr),\n\t\t\tgte: expr => value !== null && value >= unwrapGraphqlLiteral(expr),\n\t\t\tcontains: expr => typeof value === 'string' && value.includes(unwrapGraphqlLiteral(expr)),\n\t\t\tstartsWith: expr => typeof value === 'string' && value.startsWith(unwrapGraphqlLiteral(expr)),\n\t\t\tendsWith: expr => typeof value === 'string' && value.endsWith(unwrapGraphqlLiteral(expr)),\n\t\t\tcontainsCI: expr => typeof value === 'string' && value.toLowerCase().includes(unwrapGraphqlLiteral(expr).toLowerCase()),\n\t\t\tstartsWithCI: expr => typeof value === 'string' && value.toLowerCase().startsWith(unwrapGraphqlLiteral(expr).toLowerCase()),\n\t\t\tendsWithCI: expr => typeof value === 'string' && value.toLowerCase().endsWith(unwrapGraphqlLiteral(expr).toLowerCase()),\n\t\t\tnever: () => false,\n\t\t\talways: () => true,\n\t\t\t// deprecated\n\t\t\tnull: expr => (value === null) === expr,\n\t\t}\n\t\treturn Object.entries(condition).every(([operator, argument]) => {\n\t\t\tif (value === undefined) {\n\t\t\t\treturn true\n\t\t\t}\n\t\t\tconst handlerKey = operator as keyof typeof handlers\n\t\t\tconst handler = handlers[handlerKey]\n\t\t\tif (!handler) {\n\t\t\t\tthrow new BindingError()\n\t\t\t}\n\t\t\treturn handler(argument)\n\t\t})\n\t}\n"],"names":[],"mappings":";;AAIA,MAAM,uBAAuB,CAAC,UAAkD;AAC/E,MAAI,iBAAiB,gBAAgB;AACpC,WAAO,MAAM;AAAA,EACd;AACO,SAAA;AACR;AAEa,MAAA,oBAAoB,CAAC,OAA0B,cAAkE;AAC5H,QAAM,WAIF;AAAA,IACH,KAAK,UAAQ,KAAK,MAAM,QAAM,kBAAkB,OAAO,EAAE,CAAC;AAAA,IAC1D,IAAI,UAAQ,KAAK,KAAK,QAAM,kBAAkB,OAAO,EAAE,CAAC;AAAA,IACxD,KAAK,CAAA,SAAQ,CAAC,kBAAkB,OAAO,IAAI;AAAA,IAC3C,IAAI,CAAA,SAAQ,UAAU,qBAAqB,IAAI;AAAA,IAC/C,OAAO,CAAA,SAAQ,UAAU,qBAAqB,IAAI;AAAA,IAClD,QAAQ,CAAS,SAAA,UAAU,SAAU;AAAA,IACrC,IAAI,CAAQ,SAAA,KAAK,IAAI,oBAAoB,EAAE,SAAS,KAAK;AAAA,IACzD,OAAO,UAAQ,CAAC,KAAK,IAAI,oBAAoB,EAAE,SAAS,KAAK;AAAA,IAC7D,IAAI,CAAQ,SAAA,UAAU,QAAQ,QAAQ,qBAAqB,IAAI;AAAA,IAC/D,KAAK,CAAQ,SAAA,UAAU,QAAQ,SAAS,qBAAqB,IAAI;AAAA,IACjE,IAAI,CAAQ,SAAA,UAAU,QAAQ,QAAQ,qBAAqB,IAAI;AAAA,IAC/D,KAAK,CAAQ,SAAA,UAAU,QAAQ,SAAS,qBAAqB,IAAI;AAAA,IACjE,UAAU,UAAQ,OAAO,UAAU,YAAY,MAAM,SAAS,qBAAqB,IAAI,CAAC;AAAA,IACxF,YAAY,UAAQ,OAAO,UAAU,YAAY,MAAM,WAAW,qBAAqB,IAAI,CAAC;AAAA,IAC5F,UAAU,UAAQ,OAAO,UAAU,YAAY,MAAM,SAAS,qBAAqB,IAAI,CAAC;AAAA,IACxF,YAAY,CAAA,SAAQ,OAAO,UAAU,YAAY,MAAM,YAAY,EAAE,SAAS,qBAAqB,IAAI,EAAE,aAAa;AAAA,IACtH,cAAc,CAAA,SAAQ,OAAO,UAAU,YAAY,MAAM,YAAY,EAAE,WAAW,qBAAqB,IAAI,EAAE,aAAa;AAAA,IAC1H,YAAY,CAAA,SAAQ,OAAO,UAAU,YAAY,MAAM,YAAY,EAAE,SAAS,qBAAqB,IAAI,EAAE,aAAa;AAAA,IACtH,OAAO,MAAM;AAAA,IACb,QAAQ,MAAM;AAAA;AAAA,IAEd,MAAM,CAAS,SAAA,UAAU,SAAU;AAAA,EAAA;AAE7B,SAAA,OAAO,QAAQ,SAAS,EAAE,MAAM,CAAC,CAAC,UAAU,QAAQ,MAAM;AAChE,QAAI,UAAU,QAAW;AACjB,aAAA;AAAA,IACR;AACA,UAAM,aAAa;AACb,UAAA,UAAU,SAAS,UAAU;AACnC,QAAI,CAAC,SAAS;AACb,YAAM,IAAI,aAAa;AAAA,IACxB;AACA,
|
|
1
|
+
{"version":3,"file":"evaluateCondition.js","sources":["../../../../src/helperComponents/helpers/evaluateCondition.ts"],"sourcesContent":["import { GraphQlLiteral, Input } from '@contember/client'\nimport { FieldValue } from '../../treeParameters'\nimport { BindingError } from '../../BindingError'\n\nconst unwrapGraphqlLiteral = (value: Input.ColumnValue<GraphQlLiteral>): any => {\n\tif (value instanceof GraphQlLiteral) {\n\t\treturn value.value\n\t}\n\treturn value\n}\n\nexport const evaluateCondition = (value: FieldValue | null, condition: Input.Condition<Input.ColumnValue<GraphQlLiteral>>) => {\n\t\tconst handlers: {\n\t\t\t[K in keyof Required<Input.Condition<any>>]: (\n\t\t\t\tparam: Exclude<Input.Condition<any>[K], undefined>,\n\t\t\t) => boolean\n\t\t} = {\n\t\t\tand: expr => expr.every(it => evaluateCondition(value, it)),\n\t\t\tor: expr => expr.some(it => evaluateCondition(value, it)),\n\t\t\tnot: expr => !evaluateCondition(value, expr),\n\t\t\teq: expr => value === unwrapGraphqlLiteral(expr),\n\t\t\tnotEq: expr => value !== unwrapGraphqlLiteral(expr),\n\t\t\tisNull: expr => (value === null) === expr,\n\t\t\tin: expr => expr.map(unwrapGraphqlLiteral).includes(value),\n\t\t\tnotIn: expr => !expr.map(unwrapGraphqlLiteral).includes(value),\n\t\t\tlt: expr => value !== null && value < unwrapGraphqlLiteral(expr),\n\t\t\tlte: expr => value !== null && value <= unwrapGraphqlLiteral(expr),\n\t\t\tgt: expr => value !== null && value > unwrapGraphqlLiteral(expr),\n\t\t\tgte: expr => value !== null && value >= unwrapGraphqlLiteral(expr),\n\t\t\tcontains: expr => typeof value === 'string' && value.includes(unwrapGraphqlLiteral(expr)),\n\t\t\tstartsWith: expr => typeof value === 'string' && value.startsWith(unwrapGraphqlLiteral(expr)),\n\t\t\tendsWith: expr => typeof value === 'string' && value.endsWith(unwrapGraphqlLiteral(expr)),\n\t\t\tcontainsCI: expr => typeof value === 'string' && value.toLowerCase().includes(unwrapGraphqlLiteral(expr).toLowerCase()),\n\t\t\tstartsWithCI: expr => typeof value === 'string' && value.toLowerCase().startsWith(unwrapGraphqlLiteral(expr).toLowerCase()),\n\t\t\tendsWithCI: expr => typeof value === 'string' && value.toLowerCase().endsWith(unwrapGraphqlLiteral(expr).toLowerCase()),\n\t\t\tnever: () => false,\n\t\t\talways: () => true,\n\t\t\t// deprecated\n\t\t\tnull: expr => (value === null) === expr,\n\t\t}\n\t\treturn Object.entries(condition).every(([operator, argument]) => {\n\t\t\tif (value === undefined) {\n\t\t\t\treturn true\n\t\t\t}\n\t\t\tconst handlerKey = operator as keyof typeof handlers\n\t\t\tconst handler = handlers[handlerKey]\n\t\t\tif (!handler) {\n\t\t\t\tthrow new BindingError()\n\t\t\t}\n\t\t\treturn (handler as any)(argument)\n\t\t})\n\t}\n"],"names":[],"mappings":";;AAIA,MAAM,uBAAuB,CAAC,UAAkD;AAC/E,MAAI,iBAAiB,gBAAgB;AACpC,WAAO,MAAM;AAAA,EACd;AACO,SAAA;AACR;AAEa,MAAA,oBAAoB,CAAC,OAA0B,cAAkE;AAC5H,QAAM,WAIF;AAAA,IACH,KAAK,UAAQ,KAAK,MAAM,QAAM,kBAAkB,OAAO,EAAE,CAAC;AAAA,IAC1D,IAAI,UAAQ,KAAK,KAAK,QAAM,kBAAkB,OAAO,EAAE,CAAC;AAAA,IACxD,KAAK,CAAA,SAAQ,CAAC,kBAAkB,OAAO,IAAI;AAAA,IAC3C,IAAI,CAAA,SAAQ,UAAU,qBAAqB,IAAI;AAAA,IAC/C,OAAO,CAAA,SAAQ,UAAU,qBAAqB,IAAI;AAAA,IAClD,QAAQ,CAAS,SAAA,UAAU,SAAU;AAAA,IACrC,IAAI,CAAQ,SAAA,KAAK,IAAI,oBAAoB,EAAE,SAAS,KAAK;AAAA,IACzD,OAAO,UAAQ,CAAC,KAAK,IAAI,oBAAoB,EAAE,SAAS,KAAK;AAAA,IAC7D,IAAI,CAAQ,SAAA,UAAU,QAAQ,QAAQ,qBAAqB,IAAI;AAAA,IAC/D,KAAK,CAAQ,SAAA,UAAU,QAAQ,SAAS,qBAAqB,IAAI;AAAA,IACjE,IAAI,CAAQ,SAAA,UAAU,QAAQ,QAAQ,qBAAqB,IAAI;AAAA,IAC/D,KAAK,CAAQ,SAAA,UAAU,QAAQ,SAAS,qBAAqB,IAAI;AAAA,IACjE,UAAU,UAAQ,OAAO,UAAU,YAAY,MAAM,SAAS,qBAAqB,IAAI,CAAC;AAAA,IACxF,YAAY,UAAQ,OAAO,UAAU,YAAY,MAAM,WAAW,qBAAqB,IAAI,CAAC;AAAA,IAC5F,UAAU,UAAQ,OAAO,UAAU,YAAY,MAAM,SAAS,qBAAqB,IAAI,CAAC;AAAA,IACxF,YAAY,CAAA,SAAQ,OAAO,UAAU,YAAY,MAAM,YAAY,EAAE,SAAS,qBAAqB,IAAI,EAAE,aAAa;AAAA,IACtH,cAAc,CAAA,SAAQ,OAAO,UAAU,YAAY,MAAM,YAAY,EAAE,WAAW,qBAAqB,IAAI,EAAE,aAAa;AAAA,IAC1H,YAAY,CAAA,SAAQ,OAAO,UAAU,YAAY,MAAM,YAAY,EAAE,SAAS,qBAAqB,IAAI,EAAE,aAAa;AAAA,IACtH,OAAO,MAAM;AAAA,IACb,QAAQ,MAAM;AAAA;AAAA,IAEd,MAAM,CAAS,SAAA,UAAU,SAAU;AAAA,EAAA;AAE7B,SAAA,OAAO,QAAQ,SAAS,EAAE,MAAM,CAAC,CAAC,UAAU,QAAQ,MAAM;AAChE,QAAI,UAAU,QAAW;AACjB,aAAA;AAAA,IACR;AACA,UAAM,aAAa;AACb,UAAA,UAAU,SAAS,UAAU;AACnC,QAAI,CAAC,SAAS;AACb,YAAM,IAAI,aAAa;AAAA,IACxB;AACA,WAAQ,QAAgB,QAAQ;AAAA,EAAA,CAChC;AACF;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"LeafField.js","sources":["../../../src/treeParameters/LeafField.ts"],"sourcesContent":["import type { FieldEventListeners, UnsugarableFieldEventListeners } from './FieldEventListeners'\nimport type { FieldValue, OptionallyVariableFieldValue } from './primitives'\n\n// These are specific to leaf fields. Common but required parameters are in AnyField.\n\nexport const LeafFieldDefaults = {\n\tisNonbearing: false,\n} as const\n\nexport interface LeafField extends FieldEventListeners {\n\tisNonbearing: boolean\n\tdefaultValue: FieldValue | undefined\n}\n\nexport
|
|
1
|
+
{"version":3,"file":"LeafField.js","sources":["../../../src/treeParameters/LeafField.ts"],"sourcesContent":["import type { FieldEventListeners, UnsugarableFieldEventListeners } from './FieldEventListeners'\nimport type { FieldValue, OptionallyVariableFieldValue } from './primitives'\n\n// These are specific to leaf fields. Common but required parameters are in AnyField.\n\nexport const LeafFieldDefaults = {\n\tisNonbearing: false,\n} as const\n\nexport interface LeafField extends FieldEventListeners {\n\tisNonbearing: boolean\n\tdefaultValue: FieldValue | undefined\n}\n\nexport type UnsugarableLeafField =\n\t& UnsugarableFieldEventListeners\n\t& {\n\t\tisNonbearing?: boolean\n\t\tdefaultValue?: OptionallyVariableFieldValue\n\t}\n"],"names":[],"mappings":"AAKO,MAAM,oBAAoB;AAAA,EAChC,cAAc;AACf;"}
|
|
@@ -4,8 +4,11 @@ export interface AccessorTreeProps {
|
|
|
4
4
|
state: AccessorTreeState;
|
|
5
5
|
children: ReactNode;
|
|
6
6
|
}
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
7
|
+
/**
|
|
8
|
+
* @group Data binding
|
|
9
|
+
*/
|
|
10
|
+
export declare const AccessorTree: {
|
|
11
|
+
({ state, children }: AccessorTreeProps): JSX.Element;
|
|
12
|
+
displayName: string;
|
|
13
|
+
};
|
|
11
14
|
//# sourceMappingURL=AccessorTree.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AccessorTree.d.ts","sourceRoot":"","sources":["../../../src/accessorTree/AccessorTree.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAA;AAEtC,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,qBAAqB,CAAA;AAK5D,MAAM,WAAW,iBAAiB;IACjC,KAAK,EAAE,iBAAiB,CAAA;IACxB,QAAQ,EAAE,SAAS,CAAA;CACnB;AAED,
|
|
1
|
+
{"version":3,"file":"AccessorTree.d.ts","sourceRoot":"","sources":["../../../src/accessorTree/AccessorTree.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAA;AAEtC,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,qBAAqB,CAAA;AAK5D,MAAM,WAAW,iBAAiB;IACjC,KAAK,EAAE,iBAAiB,CAAA;IACxB,QAAQ,EAAE,SAAS,CAAA;CACnB;AAED;;GAEG;AACH,eAAO,MAAM,YAAY;0BAAyB,iBAAiB;;CAmBlE,CAAA"}
|
|
@@ -9,5 +9,15 @@ export type DataBindingProviderProps<StateProps> = DataBindingProviderBaseProps
|
|
|
9
9
|
stateComponent: ComponentType<StateProps & DataBindingStateComponentProps>;
|
|
10
10
|
stateProps?: StateProps;
|
|
11
11
|
});
|
|
12
|
+
/**
|
|
13
|
+
* The `DataBindingProvider` is a root component for all other data binding related components.
|
|
14
|
+
*
|
|
15
|
+
* @example
|
|
16
|
+
* ```
|
|
17
|
+
* <DataBindingProvider stateComponent={FeedbackRenderer} />
|
|
18
|
+
* ```
|
|
19
|
+
*
|
|
20
|
+
* @group Data binding
|
|
21
|
+
*/
|
|
12
22
|
export declare const DataBindingProvider: <StateProps>(props: DataBindingProviderProps<StateProps>) => ReactElement;
|
|
13
23
|
//# sourceMappingURL=DataBindingProvider.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DataBindingProvider.d.ts","sourceRoot":"","sources":["../../../src/coreComponents/DataBindingProvider.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAuB,YAAY,EAAE,SAAS,EAAE,MAAM,OAAO,CAAA;AACnF,OAAO,EAAgB,iBAAiB,EAAE,wBAAwB,EAAkB,MAAM,iBAAiB,CAAA;AAE3G,MAAM,MAAM,4BAA4B,GACrC,wBAAwB,CAAA;AAE3B,MAAM,WAAW,8BAA8B;IAC9C,iBAAiB,EAAE,iBAAiB,CAAA;IACpC,QAAQ,CAAC,EAAE,SAAS,CAAA;CACpB;AAED,MAAM,MAAM,wBAAwB,CAAC,UAAU,IAAI,4BAA4B,GAC9E,CACG,EAAE,GACF;IACA,cAAc,EAAE,aAAa,CAAC,UAAU,GAAG,8BAA8B,CAAC,CAAA;IAC1E,UAAU,CAAC,EAAE,UAAU,CAAA;CACtB,CACH,CAAA;AAEF,eAAO,MAAM,mBAAmB,+DAiBmC,YAAY,CAAA"}
|
|
1
|
+
{"version":3,"file":"DataBindingProvider.d.ts","sourceRoot":"","sources":["../../../src/coreComponents/DataBindingProvider.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAuB,YAAY,EAAE,SAAS,EAAE,MAAM,OAAO,CAAA;AACnF,OAAO,EAAgB,iBAAiB,EAAE,wBAAwB,EAAkB,MAAM,iBAAiB,CAAA;AAE3G,MAAM,MAAM,4BAA4B,GACrC,wBAAwB,CAAA;AAE3B,MAAM,WAAW,8BAA8B;IAC9C,iBAAiB,EAAE,iBAAiB,CAAA;IACpC,QAAQ,CAAC,EAAE,SAAS,CAAA;CACpB;AAED,MAAM,MAAM,wBAAwB,CAAC,UAAU,IAAI,4BAA4B,GAC9E,CACG,EAAE,GACF;IACA,cAAc,EAAE,aAAa,CAAC,UAAU,GAAG,8BAA8B,CAAC,CAAA;IAC1E,UAAU,CAAC,EAAE,UAAU,CAAA;CACtB,CACH,CAAA;AAEF;;;;;;;;;GASG;AACH,eAAO,MAAM,mBAAmB,+DAiBmC,YAAY,CAAA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Entity.d.ts","sourceRoot":"","sources":["../../../src/coreComponents/Entity.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAA;AAEtC,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,cAAc,CAAA;AAGlD,MAAM,WAAW,eAAe;IAC/B,QAAQ,EAAE,cAAc,CAAA;IACxB,QAAQ,CAAC,EAAE,SAAS,CAAA;CACpB;AAED,MAAM,MAAM,WAAW,GAAG,eAAe,CAAA;AAEzC,eAAO,MAAM,MAAM,6CAUlB,CAAA"}
|
|
1
|
+
{"version":3,"file":"Entity.d.ts","sourceRoot":"","sources":["../../../src/coreComponents/Entity.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAA;AAEtC,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,cAAc,CAAA;AAGlD,MAAM,WAAW,eAAe;IAC/B,QAAQ,EAAE,cAAc,CAAA;IACxB,QAAQ,CAAC,EAAE,SAAS,CAAA;CACpB;AAED,MAAM,MAAM,WAAW,GAAG,eAAe,CAAA;AAEzC;;GAEG;AACH,eAAO,MAAM,MAAM,6CAUlB,CAAA"}
|
|
@@ -8,5 +8,8 @@ export type EntityListProps<ListProps> = EntityListBaseProps & ({} | {
|
|
|
8
8
|
listComponent: ComponentType<ListProps & EntityListBaseProps>;
|
|
9
9
|
listProps?: ListProps;
|
|
10
10
|
});
|
|
11
|
+
/**
|
|
12
|
+
* @group Data binding
|
|
13
|
+
*/
|
|
11
14
|
export declare const EntityList: <ListProps>(props: EntityListProps<ListProps>) => ReactElement;
|
|
12
15
|
//# sourceMappingURL=EntityList.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"EntityList.d.ts","sourceRoot":"","sources":["../../../src/coreComponents/EntityList.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAiB,YAAY,EAAE,SAAS,EAAE,MAAM,OAAO,CAAA;AAC7E,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,cAAc,CAAA;AAItD,MAAM,WAAW,mBAAmB;IACnC,QAAQ,EAAE,kBAAkB,CAAA;IAC5B,QAAQ,CAAC,EAAE,SAAS,CAAA;CACpB;AAED,MAAM,MAAM,eAAe,CAAC,SAAS,IAAI,mBAAmB,GAC3D,CACG,EAAE,GACF;IACA,aAAa,EAAE,aAAa,CAAC,SAAS,GAAG,mBAAmB,CAAC,CAAA;IAC7D,SAAS,CAAC,EAAE,SAAS,CAAA;CACpB,CACH,CAAA;AAEF,eAAO,MAAM,UAAU,oDAgCgC,YAAY,CAAA"}
|
|
1
|
+
{"version":3,"file":"EntityList.d.ts","sourceRoot":"","sources":["../../../src/coreComponents/EntityList.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAiB,YAAY,EAAE,SAAS,EAAE,MAAM,OAAO,CAAA;AAC7E,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,cAAc,CAAA;AAItD,MAAM,WAAW,mBAAmB;IACnC,QAAQ,EAAE,kBAAkB,CAAA;IAC5B,QAAQ,CAAC,EAAE,SAAS,CAAA;CACpB;AAED,MAAM,MAAM,eAAe,CAAC,SAAS,IAAI,mBAAmB,GAC3D,CACG,EAAE,GACF;IACA,aAAa,EAAE,aAAa,CAAC,SAAS,GAAG,mBAAmB,CAAC,CAAA;IAC7D,SAAS,CAAC,EAAE,SAAS,CAAA;CACpB,CACH,CAAA;AAEF;;GAEG;AACH,eAAO,MAAM,UAAU,oDAgCgC,YAAY,CAAA"}
|
|
@@ -12,5 +12,15 @@ export type EntityListSubTreeProps<ListProps, EntityProps> = {
|
|
|
12
12
|
listComponent: ComponentType<ListProps & EntityListBaseProps>;
|
|
13
13
|
listProps?: ListProps;
|
|
14
14
|
});
|
|
15
|
+
/**
|
|
16
|
+
* Creates a subtree with list of entities in current data binding context.
|
|
17
|
+
*
|
|
18
|
+
* @example
|
|
19
|
+
* ```
|
|
20
|
+
* <EntityListSubTree entities="Post" />
|
|
21
|
+
* ```
|
|
22
|
+
*
|
|
23
|
+
* @group Data binding
|
|
24
|
+
*/
|
|
15
25
|
export declare const EntityListSubTree: <ListProps, EntityProps>(props: EntityListSubTreeProps<ListProps, EntityProps>) => ReactElement;
|
|
16
26
|
//# sourceMappingURL=EntityListSubTree.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"EntityListSubTree.d.ts","sourceRoot":"","sources":["../../../src/coreComponents/EntityListSubTree.tsx"],"names":[],"mappings":"AACA,OAAO,EAAE,aAAa,EAAE,YAAY,EAAE,SAAS,EAAe,MAAM,OAAO,CAAA;AAO3E,OAAO,EAAE,WAAW,EAAE,MAAM,QAAQ,CAAA;AAEpC,OAAO,KAAK,EAAE,0BAA0B,EAAE,uCAAuC,EAAE,UAAU,EAAE,MAAM,mBAAmB,CAAA;AAExH,OAAO,EAAc,mBAAmB,EAAE,MAAM,cAAc,CAAA;AAI9D,MAAM,WAAW,gCAAgC;IAChD,SAAS,CAAC,EAAE,WAAW,CAAC,oBAAoB,CAAA;CAC5C;AAED,MAAM,MAAM,sBAAsB,CAAC,SAAS,EAAE,WAAW,IAAI;IAC5D,UAAU,CAAC,EAAE,UAAU,CAAA;IACvB,QAAQ,CAAC,EAAE,SAAS,CAAA;CACpB,GAAG,gCAAgC,GACnC,CAAC,0BAA0B,GAAG,uCAAuC,CAAC,GACtE,CACG,EAAE,GACF;IACA,aAAa,EAAE,aAAa,CAAC,SAAS,GAAG,mBAAmB,CAAC,CAAA;IAC7D,SAAS,CAAC,EAAE,SAAS,CAAA;CACpB,CACH,CAAA;AAEF,eAAO,MAAM,iBAAiB,qFAuC0D,YAAY,CAAA"}
|
|
1
|
+
{"version":3,"file":"EntityListSubTree.d.ts","sourceRoot":"","sources":["../../../src/coreComponents/EntityListSubTree.tsx"],"names":[],"mappings":"AACA,OAAO,EAAE,aAAa,EAAE,YAAY,EAAE,SAAS,EAAe,MAAM,OAAO,CAAA;AAO3E,OAAO,EAAE,WAAW,EAAE,MAAM,QAAQ,CAAA;AAEpC,OAAO,KAAK,EAAE,0BAA0B,EAAE,uCAAuC,EAAE,UAAU,EAAE,MAAM,mBAAmB,CAAA;AAExH,OAAO,EAAc,mBAAmB,EAAE,MAAM,cAAc,CAAA;AAI9D,MAAM,WAAW,gCAAgC;IAChD,SAAS,CAAC,EAAE,WAAW,CAAC,oBAAoB,CAAA;CAC5C;AAED,MAAM,MAAM,sBAAsB,CAAC,SAAS,EAAE,WAAW,IAAI;IAC5D,UAAU,CAAC,EAAE,UAAU,CAAA;IACvB,QAAQ,CAAC,EAAE,SAAS,CAAA;CACpB,GAAG,gCAAgC,GACnC,CAAC,0BAA0B,GAAG,uCAAuC,CAAC,GACtE,CACG,EAAE,GACF;IACA,aAAa,EAAE,aAAa,CAAC,SAAS,GAAG,mBAAmB,CAAC,CAAA;IAC7D,SAAS,CAAC,EAAE,SAAS,CAAA;CACpB,CACH,CAAA;AAEF;;;;;;;;;GASG;AACH,eAAO,MAAM,iBAAiB,qFAuC0D,YAAY,CAAA"}
|
|
@@ -10,5 +10,15 @@ export type EntitySubTreeProps<EntityProps> = {
|
|
|
10
10
|
treeRootId?: TreeRootId;
|
|
11
11
|
children?: ReactNode;
|
|
12
12
|
} & EntitySubTreeAdditionalProps & (SugaredQualifiedSingleEntity | (SugaredUnconstrainedQualifiedSingleEntity & EntitySubTreeAdditionalCreationProps));
|
|
13
|
+
/**
|
|
14
|
+
* Creates a single entity subtree in current data binding context.
|
|
15
|
+
*
|
|
16
|
+
* @example
|
|
17
|
+
* ```
|
|
18
|
+
* <EntitySubTree entity="Post(id = $id)" />
|
|
19
|
+
* ```
|
|
20
|
+
*
|
|
21
|
+
* @group Data binding
|
|
22
|
+
*/
|
|
13
23
|
export declare const EntitySubTree: <EntityProps>(pros: EntitySubTreeProps<EntityProps>) => ReactElement;
|
|
14
24
|
//# sourceMappingURL=EntitySubTree.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"EntitySubTree.d.ts","sourceRoot":"","sources":["../../../src/coreComponents/EntitySubTree.tsx"],"names":[],"mappings":"AACA,OAAO,EAAE,YAAY,EAAE,SAAS,EAAe,MAAM,OAAO,CAAA;AAE5D,OAAO,EAAyB,6BAA6B,EAAE,MAAM,oBAAoB,CAAA;AAEzF,OAAO,EAAE,WAAW,EAAE,MAAM,QAAQ,CAAA;AAEpC,OAAO,KAAK,EACX,4BAA4B,EAC5B,yCAAyC,EACzC,UAAU,EACV,MAAM,mBAAmB,CAAA;AAM1B,MAAM,WAAW,4BAA4B;IAC5C,SAAS,CAAC,EAAE,WAAW,CAAC,oBAAoB,CAAA;CAC5C;AAED,MAAM,MAAM,oCAAoC,GAAG,EAAE,GAAG,6BAA6B,CAAA;AAErF,MAAM,MAAM,kBAAkB,CAAC,WAAW,IACvC;IACD,UAAU,CAAC,EAAE,UAAU,CAAA;IACvB,QAAQ,CAAC,EAAE,SAAS,CAAA;CACpB,GACC,4BAA4B,GAC5B,CACC,4BAA4B,GAC5B,CAAC,yCAAyC,GAAG,oCAAoC,CAAC,CACpF,CAAA;AAEF,eAAO,MAAM,aAAa,0DAgDmC,YAAY,CAAA"}
|
|
1
|
+
{"version":3,"file":"EntitySubTree.d.ts","sourceRoot":"","sources":["../../../src/coreComponents/EntitySubTree.tsx"],"names":[],"mappings":"AACA,OAAO,EAAE,YAAY,EAAE,SAAS,EAAe,MAAM,OAAO,CAAA;AAE5D,OAAO,EAAyB,6BAA6B,EAAE,MAAM,oBAAoB,CAAA;AAEzF,OAAO,EAAE,WAAW,EAAE,MAAM,QAAQ,CAAA;AAEpC,OAAO,KAAK,EACX,4BAA4B,EAC5B,yCAAyC,EACzC,UAAU,EACV,MAAM,mBAAmB,CAAA;AAM1B,MAAM,WAAW,4BAA4B;IAC5C,SAAS,CAAC,EAAE,WAAW,CAAC,oBAAoB,CAAA;CAC5C;AAED,MAAM,MAAM,oCAAoC,GAAG,EAAE,GAAG,6BAA6B,CAAA;AAErF,MAAM,MAAM,kBAAkB,CAAC,WAAW,IACvC;IACD,UAAU,CAAC,EAAE,UAAU,CAAA;IACvB,QAAQ,CAAC,EAAE,SAAS,CAAA;CACpB,GACC,4BAA4B,GAC5B,CACC,4BAA4B,GAC5B,CAAC,yCAAyC,GAAG,oCAAoC,CAAC,CACpF,CAAA;AAEF;;;;;;;;;GASG;AACH,eAAO,MAAM,aAAa,0DAgDmC,YAAY,CAAA"}
|
|
@@ -7,5 +7,8 @@ export interface FieldRuntimeProps<Persisted extends FieldValue = FieldValue> {
|
|
|
7
7
|
}
|
|
8
8
|
export interface FieldProps<Persisted extends FieldValue = FieldValue> extends FieldBasicProps, FieldRuntimeProps<Persisted> {
|
|
9
9
|
}
|
|
10
|
+
/**
|
|
11
|
+
* @group Data binding
|
|
12
|
+
*/
|
|
10
13
|
export declare const Field: <Persisted extends FieldValue = FieldValue>(props: FieldProps<Persisted>) => ReactElement;
|
|
11
14
|
//# sourceMappingURL=Field.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Field.d.ts","sourceRoot":"","sources":["../../../src/coreComponents/Field.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,YAAY,EAAE,SAAS,EAAE,MAAM,OAAO,CAAA;AAGpD,OAAO,KAAK,EAAE,UAAU,EAAE,0BAA0B,EAAE,MAAM,mBAAmB,CAAA;AAI/E,MAAM,WAAW,eAAgB,SAAQ,0BAA0B;CAAG;AAEtE,MAAM,WAAW,iBAAiB,CAAC,SAAS,SAAS,UAAU,GAAG,UAAU;IAC3E,MAAM,CAAC,EAAE,CAAC,KAAK,EAAE,SAAS,GAAG,IAAI,KAAK,SAAS,CAAA;CAC/C;AAED,MAAM,WAAW,UAAU,CAAC,SAAS,SAAS,UAAU,GAAG,UAAU,CACpE,SAAQ,eAAe,EACtB,iBAAiB,CAAC,SAAS,CAAC;CAAG;AAEjC,eAAO,MAAM,KAAK,+EAwBgE,YAAY,CAAA"}
|
|
1
|
+
{"version":3,"file":"Field.d.ts","sourceRoot":"","sources":["../../../src/coreComponents/Field.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,YAAY,EAAE,SAAS,EAAE,MAAM,OAAO,CAAA;AAGpD,OAAO,KAAK,EAAE,UAAU,EAAE,0BAA0B,EAAE,MAAM,mBAAmB,CAAA;AAI/E,MAAM,WAAW,eAAgB,SAAQ,0BAA0B;CAAG;AAEtE,MAAM,WAAW,iBAAiB,CAAC,SAAS,SAAS,UAAU,GAAG,UAAU;IAC3E,MAAM,CAAC,EAAE,CAAC,KAAK,EAAE,SAAS,GAAG,IAAI,KAAK,SAAS,CAAA;CAC/C;AAED,MAAM,WAAW,UAAU,CAAC,SAAS,SAAS,UAAU,GAAG,UAAU,CACpE,SAAQ,eAAe,EACtB,iBAAiB,CAAC,SAAS,CAAC;CAAG;AAEjC;;GAEG;AACH,eAAO,MAAM,KAAK,+EAwBgE,YAAY,CAAA"}
|
|
@@ -9,5 +9,8 @@ export type HasManyProps<ListProps = never, EntityProps = never> = SugaredRelati
|
|
|
9
9
|
listComponent: ComponentType<ListProps & EntityListBaseProps>;
|
|
10
10
|
listProps?: ListProps;
|
|
11
11
|
});
|
|
12
|
+
/**
|
|
13
|
+
* @group Data binding
|
|
14
|
+
*/
|
|
12
15
|
export declare const HasMany: <ListProps, EntityProps>(props: HasManyProps<ListProps, EntityProps>) => ReactElement;
|
|
13
16
|
//# sourceMappingURL=HasMany.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"HasMany.d.ts","sourceRoot":"","sources":["../../../src/coreComponents/HasMany.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,YAAY,EAAE,SAAS,EAAE,MAAM,OAAO,CAAA;AAGnE,OAAO,EAAE,WAAW,EAAE,MAAM,QAAQ,CAAA;AAEpC,OAAO,KAAK,EAAE,yBAAyB,EAAE,MAAM,mBAAmB,CAAA;AAElE,OAAO,EAAc,mBAAmB,EAAE,MAAM,cAAc,CAAA;AAI9D,MAAM,MAAM,YAAY,CAAC,SAAS,GAAG,KAAK,EAAE,WAAW,GAAG,KAAK,IAAI,yBAAyB,GAAG;IAC9F,QAAQ,CAAC,EAAE,SAAS,CAAA;IACpB,SAAS,CAAC,EAAE,WAAW,CAAC,oBAAoB,CAAA;CAC5C,GAAG,CACA,EAAE,GACF;IACA,aAAa,EAAE,aAAa,CAAC,SAAS,GAAG,mBAAmB,CAAC,CAAA;IAC7D,SAAS,CAAC,EAAE,SAAS,CAAA;CACpB,CACH,CAAA;AAEF,eAAO,MAAM,OAAO,2EAqB0D,YAAY,CAAA"}
|
|
1
|
+
{"version":3,"file":"HasMany.d.ts","sourceRoot":"","sources":["../../../src/coreComponents/HasMany.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,YAAY,EAAE,SAAS,EAAE,MAAM,OAAO,CAAA;AAGnE,OAAO,EAAE,WAAW,EAAE,MAAM,QAAQ,CAAA;AAEpC,OAAO,KAAK,EAAE,yBAAyB,EAAE,MAAM,mBAAmB,CAAA;AAElE,OAAO,EAAc,mBAAmB,EAAE,MAAM,cAAc,CAAA;AAI9D,MAAM,MAAM,YAAY,CAAC,SAAS,GAAG,KAAK,EAAE,WAAW,GAAG,KAAK,IAAI,yBAAyB,GAAG;IAC9F,QAAQ,CAAC,EAAE,SAAS,CAAA;IACpB,SAAS,CAAC,EAAE,WAAW,CAAC,oBAAoB,CAAA;CAC5C,GAAG,CACA,EAAE,GACF;IACA,aAAa,EAAE,aAAa,CAAC,SAAS,GAAG,mBAAmB,CAAC,CAAA;IAC7D,SAAS,CAAC,EAAE,SAAS,CAAA;CACpB,CACH,CAAA;AAEF;;GAEG;AACH,eAAO,MAAM,OAAO,2EAqB0D,YAAY,CAAA"}
|
|
@@ -5,5 +5,8 @@ export type HasOneProps<EntityProps = never> = SugaredRelativeSingleEntity & {
|
|
|
5
5
|
children?: ReactNode;
|
|
6
6
|
variables?: Environment.ValuesMapWithFactory;
|
|
7
7
|
};
|
|
8
|
+
/**
|
|
9
|
+
* @group Data binding
|
|
10
|
+
*/
|
|
8
11
|
export declare const HasOne: <EntityProps extends {}>(props: HasOneProps<EntityProps>) => ReactElement;
|
|
9
12
|
//# sourceMappingURL=HasOne.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"HasOne.d.ts","sourceRoot":"","sources":["../../../src/coreComponents/HasOne.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,SAAS,EAAE,MAAM,OAAO,CAAA;AAGpD,OAAO,EAAE,WAAW,EAAE,MAAM,QAAQ,CAAA;AAEpC,OAAO,KAAK,EAAE,2BAA2B,EAAE,MAAM,mBAAmB,CAAA;AAMpE,MAAM,MAAM,WAAW,CAAC,WAAW,GAAG,KAAK,IAAI,2BAA2B,GAAG;IAC5E,QAAQ,CAAC,EAAE,SAAS,CAAA;IACpB,SAAS,CAAC,EAAE,WAAW,CAAC,oBAAoB,CAAA;CAC5C,CAAA;AAED,eAAO,MAAM,MAAM,+DAqB+C,YAAY,CAAA"}
|
|
1
|
+
{"version":3,"file":"HasOne.d.ts","sourceRoot":"","sources":["../../../src/coreComponents/HasOne.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,SAAS,EAAE,MAAM,OAAO,CAAA;AAGpD,OAAO,EAAE,WAAW,EAAE,MAAM,QAAQ,CAAA;AAEpC,OAAO,KAAK,EAAE,2BAA2B,EAAE,MAAM,mBAAmB,CAAA;AAMpE,MAAM,MAAM,WAAW,CAAC,WAAW,GAAG,KAAK,IAAI,2BAA2B,GAAG;IAC5E,QAAQ,CAAC,EAAE,SAAS,CAAA;IACpB,SAAS,CAAC,EAAE,WAAW,CAAC,oBAAoB,CAAA;CAC5C,CAAA;AAED;;GAEG;AACH,eAAO,MAAM,MAAM,+DAqB+C,YAAY,CAAA"}
|
|
@@ -3,5 +3,8 @@ import type { SugaredParentEntityParameters } from '../treeParameters';
|
|
|
3
3
|
export interface ParentEntityProps extends SugaredParentEntityParameters {
|
|
4
4
|
children?: ReactNode;
|
|
5
5
|
}
|
|
6
|
+
/**
|
|
7
|
+
* @group Data binding
|
|
8
|
+
*/
|
|
6
9
|
export declare const ParentEntity: React.NamedExoticComponent<ParentEntityProps>;
|
|
7
10
|
//# sourceMappingURL=ParentEntity.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ParentEntity.d.ts","sourceRoot":"","sources":["../../../src/coreComponents/ParentEntity.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAA;AAEtC,OAAO,KAAK,EAAE,6BAA6B,EAAE,MAAM,mBAAmB,CAAA;AAGtE,MAAM,WAAW,iBAAkB,SAAQ,6BAA6B;IACvE,QAAQ,CAAC,EAAE,SAAS,CAAA;CACpB;AAED,eAAO,MAAM,YAAY,+CAOxB,CAAA"}
|
|
1
|
+
{"version":3,"file":"ParentEntity.d.ts","sourceRoot":"","sources":["../../../src/coreComponents/ParentEntity.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAA;AAEtC,OAAO,KAAK,EAAE,6BAA6B,EAAE,MAAM,mBAAmB,CAAA;AAGtE,MAAM,WAAW,iBAAkB,SAAQ,6BAA6B;IACvE,QAAQ,CAAC,EAAE,SAAS,CAAA;CACpB;AAED;;GAEG;AACH,eAAO,MAAM,YAAY,+CAOxB,CAAA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DeferredSubTrees.d.ts","sourceRoot":"","sources":["../../../src/helperComponents/DeferredSubTrees.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAoC,MAAM,OAAO,CAAA;AAWnE,MAAM,WAAW,qBAAqB;IACrC,QAAQ,EAAE,SAAS,CAAA;IACnB,QAAQ,EAAE,SAAS,CAAA;CACnB;AAUD,eAAO,MAAM,gBAAgB,mDAkF5B,CAAA"}
|
|
1
|
+
{"version":3,"file":"DeferredSubTrees.d.ts","sourceRoot":"","sources":["../../../src/helperComponents/DeferredSubTrees.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAoC,MAAM,OAAO,CAAA;AAWnE,MAAM,WAAW,qBAAqB;IACrC,QAAQ,EAAE,SAAS,CAAA;IACnB,QAAQ,EAAE,SAAS,CAAA;CACnB;AAUD;;GAEG;AACH,eAAO,MAAM,gBAAgB,mDAkF5B,CAAA"}
|
|
@@ -5,5 +5,8 @@ export interface EntityViewProps {
|
|
|
5
5
|
render: (entity: EntityAccessor) => ReactNode;
|
|
6
6
|
field?: string | SugaredRelativeSingleEntity;
|
|
7
7
|
}
|
|
8
|
+
/**
|
|
9
|
+
* @group Data binding
|
|
10
|
+
*/
|
|
8
11
|
export declare function EntityView(props: EntityViewProps): JSX.Element;
|
|
9
12
|
//# sourceMappingURL=EntityView.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"EntityView.d.ts","sourceRoot":"","sources":["../../../src/helperComponents/EntityView.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAA;AAEtC,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,cAAc,CAAA;AAClD,OAAO,KAAK,EAAE,2BAA2B,EAAE,MAAM,mBAAmB,CAAA;AAEpE,MAAM,WAAW,eAAe;IAC/B,MAAM,EAAE,CAAC,MAAM,EAAE,cAAc,KAAK,SAAS,CAAA;IAC7C,KAAK,CAAC,EAAE,MAAM,GAAG,2BAA2B,CAAA;CAC5C;AAED,wBAAgB,UAAU,CAAC,KAAK,EAAE,eAAe,eAKhD"}
|
|
1
|
+
{"version":3,"file":"EntityView.d.ts","sourceRoot":"","sources":["../../../src/helperComponents/EntityView.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAA;AAEtC,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,cAAc,CAAA;AAClD,OAAO,KAAK,EAAE,2BAA2B,EAAE,MAAM,mBAAmB,CAAA;AAEpE,MAAM,WAAW,eAAe;IAC/B,MAAM,EAAE,CAAC,MAAM,EAAE,cAAc,KAAK,SAAS,CAAA;IAC7C,KAAK,CAAC,EAAE,MAAM,GAAG,2BAA2B,CAAA;CAC5C;AAED;;GAEG;AACH,wBAAgB,UAAU,CAAC,KAAK,EAAE,eAAe,eAKhD"}
|
|
@@ -15,6 +15,19 @@ type SRSF = string | SugaredRelativeSingleField;
|
|
|
15
15
|
type CP = FieldViewCommonProps;
|
|
16
16
|
type RN = ReactNode;
|
|
17
17
|
type REN = ReactElement | null;
|
|
18
|
+
/**
|
|
19
|
+
* Base field view component with no default formatting.
|
|
20
|
+
*
|
|
21
|
+
* @example
|
|
22
|
+
* ```
|
|
23
|
+
* <FieldView
|
|
24
|
+
* field="startsAt"
|
|
25
|
+
* render={(accessor) => <>{accessor.value}</>}
|
|
26
|
+
* />
|
|
27
|
+
* ```
|
|
28
|
+
*
|
|
29
|
+
* @group Field Views
|
|
30
|
+
*/
|
|
18
31
|
export declare const FieldView: {
|
|
19
32
|
<FV1 extends FieldValue>(props: FieldViewCommonProps & {
|
|
20
33
|
field: SRSF;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FieldView.d.ts","sourceRoot":"","sources":["../../../src/helperComponents/FieldView.tsx"],"names":[],"mappings":"AACA,OAAO,EAAE,YAAY,EAAE,SAAS,EAAwB,MAAM,OAAO,CAAA;AAErE,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,cAAc,CAAA;AAIjD,OAAO,KAAK,EAAE,UAAU,EAAuB,0BAA0B,EAAE,MAAM,mBAAmB,CAAA;AAGpG,UAAU,oBAAoB;IAC7B,qBAAqB,CAAC,EAAE,SAAS,CAAA;CACjC;AAED,KAAK,cAAc,GAAG,oBAAoB,GACzC,CACG;IACA,MAAM,EAAE,CAAC,GAAG,SAAS,EAAE,aAAa,EAAE,KAAK,SAAS,CAAA;IACpD,KAAK,EAAE,MAAM,GAAG,0BAA0B,CAAA;CACzC,GACD;IACA,MAAM,EAAE,CAAC,GAAG,SAAS,EAAE,aAAa,EAAE,KAAK,SAAS,CAAA;IACpD,MAAM,EAAE,KAAK,CAAC,MAAM,GAAG,0BAA0B,CAAC,CAAA;CACjD,CACH,CAAA;AAIF,KAAK,IAAI,GAAG,MAAM,GAAG,0BAA0B,CAAA;AAC/C,KAAK,EAAE,GAAG,oBAAoB,CAAA;AAC9B,KAAK,EAAE,GAAG,SAAS,CAAA;AACnB,KAAK,GAAG,GAAG,YAAY,GAAG,IAAI,CAAA;AAE9B,eAAO,MAAM,SAAS;;eA4DiB,IAAI;gDAA0C,EAAE;QAAK,GAAG;;gBACvD,CAAC,IAAI,CAAC;kDAA0C,EAAE;QAAK,GAAG;;gBAE1E,CAAC,IAAI,EAAE,IAAI,CAAC;8EAAsE,EAAE;QACxG,GAAG;;gBAGI,CAAC,IAAI,EAAE,IAAI,EAAE,IAAI,CAAC;4GACsE,EAAE;QAEjG,GAAG;;gBAGI,CAAC,IAAI,EAAE,IAAI,EAAE,IAAI,EAAE,IAAI,CAAC;0IAM3B,EAAE;QAEN,GAAG;;gBAGI,CAAC,IAAI,EAAE,IAAI,EAAE,IAAI,EAAE,IAAI,EAAE,IAAI,CAAC;wKAOjC,EAAE;QAEN,GAAG;YACE,cAAc,GAAG,GAAG;CAC5B,CAAA"}
|
|
1
|
+
{"version":3,"file":"FieldView.d.ts","sourceRoot":"","sources":["../../../src/helperComponents/FieldView.tsx"],"names":[],"mappings":"AACA,OAAO,EAAE,YAAY,EAAE,SAAS,EAAwB,MAAM,OAAO,CAAA;AAErE,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,cAAc,CAAA;AAIjD,OAAO,KAAK,EAAE,UAAU,EAAuB,0BAA0B,EAAE,MAAM,mBAAmB,CAAA;AAGpG,UAAU,oBAAoB;IAC7B,qBAAqB,CAAC,EAAE,SAAS,CAAA;CACjC;AAED,KAAK,cAAc,GAAG,oBAAoB,GACzC,CACG;IACA,MAAM,EAAE,CAAC,GAAG,SAAS,EAAE,aAAa,EAAE,KAAK,SAAS,CAAA;IACpD,KAAK,EAAE,MAAM,GAAG,0BAA0B,CAAA;CACzC,GACD;IACA,MAAM,EAAE,CAAC,GAAG,SAAS,EAAE,aAAa,EAAE,KAAK,SAAS,CAAA;IACpD,MAAM,EAAE,KAAK,CAAC,MAAM,GAAG,0BAA0B,CAAC,CAAA;CACjD,CACH,CAAA;AAIF,KAAK,IAAI,GAAG,MAAM,GAAG,0BAA0B,CAAA;AAC/C,KAAK,EAAE,GAAG,oBAAoB,CAAA;AAC9B,KAAK,EAAE,GAAG,SAAS,CAAA;AACnB,KAAK,GAAG,GAAG,YAAY,GAAG,IAAI,CAAA;AAE9B;;;;;;;;;;;;GAYG;AACH,eAAO,MAAM,SAAS;;eA4DiB,IAAI;gDAA0C,EAAE;QAAK,GAAG;;gBACvD,CAAC,IAAI,CAAC;kDAA0C,EAAE;QAAK,GAAG;;gBAE1E,CAAC,IAAI,EAAE,IAAI,CAAC;8EAAsE,EAAE;QACxG,GAAG;;gBAGI,CAAC,IAAI,EAAE,IAAI,EAAE,IAAI,CAAC;4GACsE,EAAE;QAEjG,GAAG;;gBAGI,CAAC,IAAI,EAAE,IAAI,EAAE,IAAI,EAAE,IAAI,CAAC;0IAM3B,EAAE;QAEN,GAAG;;gBAGI,CAAC,IAAI,EAAE,IAAI,EAAE,IAAI,EAAE,IAAI,EAAE,IAAI,CAAC;wKAOjC,EAAE;QAEN,GAAG;YACE,cAAc,GAAG,GAAG;CAC5B,CAAA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"If.d.ts","sourceRoot":"","sources":["../../../src/helperComponents/If.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAA;AAGtC,OAAO,EAAE,cAAc,EAAE,MAAM,cAAc,CAAA;AAG7C,OAAO,EAAE,MAAM,EAAE,MAAM,mBAAmB,CAAA;AAI1C,MAAM,MAAM,OAAO,GAChB,aAAa,GACb,eAAe,CAAA;AAElB,MAAM,WAAW,aAAa;IAC7B,SAAS,EAAE,MAAM,GAAG,MAAM,CAAA;IAC1B,QAAQ,CAAC,EAAE,SAAS,CAAA;CACpB;AAED,MAAM,WAAW,eAAe;IAC/B,SAAS,EAAE,CAAC,QAAQ,EAAE,cAAc,KAAK,OAAO,CAAA;IAChD,QAAQ,CAAC,EAAE,SAAS,CAAA;CACpB;AAED,eAAO,MAAM,EAAE,qCAMd,CAAA"}
|
|
1
|
+
{"version":3,"file":"If.d.ts","sourceRoot":"","sources":["../../../src/helperComponents/If.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAA;AAGtC,OAAO,EAAE,cAAc,EAAE,MAAM,cAAc,CAAA;AAG7C,OAAO,EAAE,MAAM,EAAE,MAAM,mBAAmB,CAAA;AAI1C,MAAM,MAAM,OAAO,GAChB,aAAa,GACb,eAAe,CAAA;AAElB,MAAM,WAAW,aAAa;IAC7B,SAAS,EAAE,MAAM,GAAG,MAAM,CAAA;IAC1B,QAAQ,CAAC,EAAE,SAAS,CAAA;CACpB;AAED,MAAM,WAAW,eAAe;IAC/B,SAAS,EAAE,CAAC,QAAQ,EAAE,cAAc,KAAK,OAAO,CAAA;IAChD,QAAQ,CAAC,EAAE,SAAS,CAAA;CACpB;AAED;;GAEG;AACH,eAAO,MAAM,EAAE,qCAMd,CAAA"}
|
|
@@ -2,5 +2,8 @@ import type { ReactNode } from 'react';
|
|
|
2
2
|
export interface StaticRenderProps {
|
|
3
3
|
children?: ReactNode;
|
|
4
4
|
}
|
|
5
|
+
/**
|
|
6
|
+
* @group Data binding
|
|
7
|
+
*/
|
|
5
8
|
export declare const StaticRender: React.NamedExoticComponent<StaticRenderProps>;
|
|
6
9
|
//# sourceMappingURL=StaticRender.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"StaticRender.d.ts","sourceRoot":"","sources":["../../../src/helperComponents/StaticRender.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAA;AAGtC,MAAM,WAAW,iBAAiB;IACjC,QAAQ,CAAC,EAAE,SAAS,CAAA;CACpB;AAED,eAAO,MAAM,YAAY,+CAIxB,CAAA"}
|
|
1
|
+
{"version":3,"file":"StaticRender.d.ts","sourceRoot":"","sources":["../../../src/helperComponents/StaticRender.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAA;AAGtC,MAAM,WAAW,iBAAiB;IACjC,QAAQ,CAAC,EAAE,SAAS,CAAA;CACpB;AAED;;GAEG;AACH,eAAO,MAAM,YAAY,+CAIxB,CAAA"}
|
|
@@ -5,5 +5,8 @@ import { ReactElement } from 'react';
|
|
|
5
5
|
export interface SugaredFieldProps<Persisted extends FieldValue = FieldValue> extends Omit<FieldProps<Persisted>, 'field'> {
|
|
6
6
|
field: string | SugaredRelativeSingleField;
|
|
7
7
|
}
|
|
8
|
+
/**
|
|
9
|
+
* @group Data binding
|
|
10
|
+
*/
|
|
8
11
|
export declare const SugaredField: <Persisted extends FieldValue = FieldValue>(props: SugaredFieldProps<Persisted>) => ReactElement;
|
|
9
12
|
//# sourceMappingURL=SugaredField.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SugaredField.d.ts","sourceRoot":"","sources":["../../../src/helperComponents/SugaredField.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAoB,UAAU,EAAE,MAAM,mBAAmB,CAAA;AAChE,OAAO,KAAK,EAAE,0BAA0B,EAAE,MAAM,mBAAmB,CAAA;AACnE,OAAO,EAAE,UAAU,EAAE,MAAM,mBAAmB,CAAA;AAC9C,OAAO,EAAE,YAAY,EAAE,MAAM,OAAO,CAAA;AAEpC,MAAM,WAAW,iBAAiB,CAAC,SAAS,SAAS,UAAU,GAAG,UAAU,CAAE,SAAQ,IAAI,CAAC,UAAU,CAAC,SAAS,CAAC,EAAE,OAAO,CAAC;IACzH,KAAK,EAAE,MAAM,GAAG,0BAA0B,CAAA;CAC1C;AAED,eAAO,MAAM,YAAY,sFAKiF,YAAY,CAAA"}
|
|
1
|
+
{"version":3,"file":"SugaredField.d.ts","sourceRoot":"","sources":["../../../src/helperComponents/SugaredField.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAoB,UAAU,EAAE,MAAM,mBAAmB,CAAA;AAChE,OAAO,KAAK,EAAE,0BAA0B,EAAE,MAAM,mBAAmB,CAAA;AACnE,OAAO,EAAE,UAAU,EAAE,MAAM,mBAAmB,CAAA;AAC9C,OAAO,EAAE,YAAY,EAAE,MAAM,OAAO,CAAA;AAEpC,MAAM,WAAW,iBAAiB,CAAC,SAAS,SAAS,UAAU,GAAG,UAAU,CAAE,SAAQ,IAAI,CAAC,UAAU,CAAC,SAAS,CAAC,EAAE,OAAO,CAAC;IACzH,KAAK,EAAE,MAAM,GAAG,0BAA0B,CAAA;CAC1C;AAED;;GAEG;AACH,eAAO,MAAM,YAAY,sFAKiF,YAAY,CAAA"}
|
|
@@ -6,8 +6,11 @@ export type FieldEventListenerStore<Value extends FieldValue = FieldValue> = Eve
|
|
|
6
6
|
export interface FieldEventListeners {
|
|
7
7
|
eventListeners: FieldEventListenerStore | undefined;
|
|
8
8
|
}
|
|
9
|
-
export type
|
|
10
|
-
|
|
9
|
+
export type FieldEventListenerValue<E extends keyof FieldAccessor.FieldEventListenerMap, Persisted extends FieldValue = FieldValue> = Events<Persisted>[E] | Set<Events<Persisted>[E]>;
|
|
10
|
+
export type UnsugarableFieldEventListeners<Persisted extends FieldValue = FieldValue> = {
|
|
11
|
+
onInitialize?: FieldEventListenerValue<'initialize', Persisted>;
|
|
12
|
+
onBeforeUpdate?: FieldEventListenerValue<'beforeUpdate', Persisted>;
|
|
13
|
+
onUpdate?: FieldEventListenerValue<'update', Persisted>;
|
|
11
14
|
};
|
|
12
15
|
export {};
|
|
13
16
|
//# sourceMappingURL=FieldEventListeners.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FieldEventListeners.d.ts","sourceRoot":"","sources":["../../../src/treeParameters/FieldEventListeners.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,cAAc,CAAA;AACjD,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,cAAc,CAAA;AAC9C,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,uBAAuB,CAAA;AAEhE,KAAK,MAAM,CAAC,KAAK,SAAS,UAAU,GAAG,UAAU,IAAI,aAAa,CAAC,qBAAqB,CAAC,KAAK,CAAC,CAAA;AAE/F,MAAM,MAAM,uBAAuB,CAAC,KAAK,SAAS,UAAU,GAAG,UAAU,IAAI,mBAAmB,CAC/F,MAAM,MAAM,CAAC,KAAK,CAAC,EACnB,OAAO,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC,CACtB,CAAA;AAED,MAAM,WAAW,mBAAmB;IACnC,cAAc,EAAE,uBAAuB,GAAG,SAAS,CAAA;CACnD;
|
|
1
|
+
{"version":3,"file":"FieldEventListeners.d.ts","sourceRoot":"","sources":["../../../src/treeParameters/FieldEventListeners.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,cAAc,CAAA;AACjD,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,cAAc,CAAA;AAC9C,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,uBAAuB,CAAA;AAEhE,KAAK,MAAM,CAAC,KAAK,SAAS,UAAU,GAAG,UAAU,IAAI,aAAa,CAAC,qBAAqB,CAAC,KAAK,CAAC,CAAA;AAE/F,MAAM,MAAM,uBAAuB,CAAC,KAAK,SAAS,UAAU,GAAG,UAAU,IAAI,mBAAmB,CAC/F,MAAM,MAAM,CAAC,KAAK,CAAC,EACnB,OAAO,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC,CACtB,CAAA;AAED,MAAM,WAAW,mBAAmB;IACnC,cAAc,EAAE,uBAAuB,GAAG,SAAS,CAAA;CACnD;AAED,MAAM,MAAM,uBAAuB,CAClC,CAAC,SAAS,MAAM,aAAa,CAAC,qBAAqB,EACnD,SAAS,SAAS,UAAU,GAAG,UAAU,IACtC,MAAM,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC,GAAG,GAAG,CAAC,MAAM,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC,CAAC,CAAA;AAEpD,MAAM,MAAM,8BAA8B,CAAC,SAAS,SAAS,UAAU,GAAG,UAAU,IAAI;IACvF,YAAY,CAAC,EAAE,uBAAuB,CAAC,YAAY,EAAE,SAAS,CAAC,CAAA;IAC/D,cAAc,CAAC,EAAE,uBAAuB,CAAC,cAAc,EAAE,SAAS,CAAC,CAAA;IACnE,QAAQ,CAAC,EAAE,uBAAuB,CAAC,QAAQ,EAAE,SAAS,CAAC,CAAA;CACvD,CAAA"}
|
|
@@ -7,8 +7,8 @@ export interface LeafField extends FieldEventListeners {
|
|
|
7
7
|
isNonbearing: boolean;
|
|
8
8
|
defaultValue: FieldValue | undefined;
|
|
9
9
|
}
|
|
10
|
-
export
|
|
10
|
+
export type UnsugarableLeafField = UnsugarableFieldEventListeners & {
|
|
11
11
|
isNonbearing?: boolean;
|
|
12
12
|
defaultValue?: OptionallyVariableFieldValue;
|
|
13
|
-
}
|
|
13
|
+
};
|
|
14
14
|
//# sourceMappingURL=LeafField.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"LeafField.d.ts","sourceRoot":"","sources":["../../../src/treeParameters/LeafField.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,mBAAmB,EAAE,8BAA8B,EAAE,MAAM,uBAAuB,CAAA;AAChG,OAAO,KAAK,EAAE,UAAU,EAAE,4BAA4B,EAAE,MAAM,cAAc,CAAA;AAI5E,eAAO,MAAM,iBAAiB;;CAEpB,CAAA;AAEV,MAAM,WAAW,SAAU,SAAQ,mBAAmB;IACrD,YAAY,EAAE,OAAO,CAAA;IACrB,YAAY,EAAE,UAAU,GAAG,SAAS,CAAA;CACpC;AAED,MAAM,
|
|
1
|
+
{"version":3,"file":"LeafField.d.ts","sourceRoot":"","sources":["../../../src/treeParameters/LeafField.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,mBAAmB,EAAE,8BAA8B,EAAE,MAAM,uBAAuB,CAAA;AAChG,OAAO,KAAK,EAAE,UAAU,EAAE,4BAA4B,EAAE,MAAM,cAAc,CAAA;AAI5E,eAAO,MAAM,iBAAiB;;CAEpB,CAAA;AAEV,MAAM,WAAW,SAAU,SAAQ,mBAAmB;IACrD,YAAY,EAAE,OAAO,CAAA;IACrB,YAAY,EAAE,UAAU,GAAG,SAAS,CAAA;CACpC;AAED,MAAM,MAAM,oBAAoB,GAC7B,8BAA8B,GAC9B;IACD,YAAY,CAAC,EAAE,OAAO,CAAA;IACtB,YAAY,CAAC,EAAE,4BAA4B,CAAA;CAC3C,CAAA"}
|
|
@@ -3,15 +3,14 @@ import type { EntityListParameters, SugarableEntityListParameters, UnsugarableEn
|
|
|
3
3
|
import type { HasOneRelation, SugarableHasOneRelation } from './HasOneRelation';
|
|
4
4
|
import type { LeafField, UnsugarableLeafField } from './LeafField';
|
|
5
5
|
import type { QualifiedEntityParameters, SugarableQualifiedEntityParameters, UnsugarableQualifiedEntityParameters } from './QualifiedEntityParameters';
|
|
6
|
-
export
|
|
6
|
+
export type QualifiedFieldList = EntityListParameters & QualifiedEntityParameters & AnyField & LeafField & {
|
|
7
7
|
hasOneRelationPath: HasOneRelation[];
|
|
8
|
-
}
|
|
9
|
-
export
|
|
8
|
+
};
|
|
9
|
+
export type SugarableQualifiedFieldList = SugarableEntityListParameters & SugarableQualifiedEntityParameters & SugarableAnyField & {
|
|
10
10
|
hasOneRelationPath?: SugarableHasOneRelation[] | SugarableHasOneRelation;
|
|
11
|
-
}
|
|
12
|
-
export
|
|
13
|
-
|
|
14
|
-
export interface SugaredQualifiedFieldList extends UnsugarableQualifiedFieldList {
|
|
11
|
+
};
|
|
12
|
+
export type UnsugarableQualifiedFieldList = UnsugarableEntityListParameters & UnsugarableQualifiedEntityParameters & UnsugarableLeafField;
|
|
13
|
+
export type SugaredQualifiedFieldList = UnsugarableQualifiedFieldList & {
|
|
15
14
|
fields: string | SugarableQualifiedFieldList;
|
|
16
|
-
}
|
|
15
|
+
};
|
|
17
16
|
//# sourceMappingURL=QualifiedFieldList.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"QualifiedFieldList.d.ts","sourceRoot":"","sources":["../../../src/treeParameters/QualifiedFieldList.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,QAAQ,EAAE,iBAAiB,EAAE,MAAM,YAAY,CAAA;AAC7D,OAAO,KAAK,EACX,oBAAoB,EACpB,6BAA6B,EAC7B,+BAA+B,EAC/B,MAAM,wBAAwB,CAAA;AAC/B,OAAO,KAAK,EAAE,cAAc,EAAE,uBAAuB,EAAE,MAAM,kBAAkB,CAAA;AAC/E,OAAO,KAAK,EAAE,SAAS,EAAE,oBAAoB,EAAE,MAAM,aAAa,CAAA;AAClE,OAAO,KAAK,EACX,yBAAyB,EACzB,kCAAkC,EAClC,oCAAoC,EACpC,MAAM,6BAA6B,CAAA;AAEpC,MAAM,
|
|
1
|
+
{"version":3,"file":"QualifiedFieldList.d.ts","sourceRoot":"","sources":["../../../src/treeParameters/QualifiedFieldList.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,QAAQ,EAAE,iBAAiB,EAAE,MAAM,YAAY,CAAA;AAC7D,OAAO,KAAK,EACX,oBAAoB,EACpB,6BAA6B,EAC7B,+BAA+B,EAC/B,MAAM,wBAAwB,CAAA;AAC/B,OAAO,KAAK,EAAE,cAAc,EAAE,uBAAuB,EAAE,MAAM,kBAAkB,CAAA;AAC/E,OAAO,KAAK,EAAE,SAAS,EAAE,oBAAoB,EAAE,MAAM,aAAa,CAAA;AAClE,OAAO,KAAK,EACX,yBAAyB,EACzB,kCAAkC,EAClC,oCAAoC,EACpC,MAAM,6BAA6B,CAAA;AAEpC,MAAM,MAAM,kBAAkB,GAC3B,oBAAoB,GACpB,yBAAyB,GACzB,QAAQ,GACR,SAAS,GACT;IACD,kBAAkB,EAAE,cAAc,EAAE,CAAA;CACpC,CAAA;AAEF,MAAM,MAAM,2BAA2B,GACpC,6BAA6B,GAC7B,kCAAkC,GAClC,iBAAiB,GACjB;IACD,kBAAkB,CAAC,EAAE,uBAAuB,EAAE,GAAG,uBAAuB,CAAA;CACxE,CAAA;AAEF,MAAM,MAAM,6BAA6B,GACtC,+BAA+B,GAC/B,oCAAoC,GACpC,oBAAoB,CAAA;AAIvB,MAAM,MAAM,yBAAyB,GAClC,6BAA6B,GAC7B;IACD,MAAM,EAAE,MAAM,GAAG,2BAA2B,CAAA;CAC5C,CAAA"}
|
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
import type { AnyField, SugarableAnyField } from './AnyField';
|
|
2
2
|
import type { HasOneRelation, SugarableHasOneRelation } from './HasOneRelation';
|
|
3
3
|
import type { LeafField, UnsugarableLeafField } from './LeafField';
|
|
4
|
-
export
|
|
4
|
+
export type RelativeSingleField = AnyField & LeafField & {
|
|
5
5
|
hasOneRelationPath: HasOneRelation[];
|
|
6
|
-
}
|
|
7
|
-
export
|
|
6
|
+
};
|
|
7
|
+
export type SugarableRelativeSingleField = SugarableAnyField & {
|
|
8
8
|
hasOneRelationPath?: SugarableHasOneRelation[] | SugarableHasOneRelation;
|
|
9
|
-
}
|
|
10
|
-
export
|
|
11
|
-
|
|
12
|
-
|
|
9
|
+
};
|
|
10
|
+
export type UnsugarableRelativeSingleField = UnsugarableLeafField;
|
|
11
|
+
export type SugaredRelativeSingleField = UnsugarableRelativeSingleField & {
|
|
12
|
+
/** E.g. authors(id = 123).person.name */
|
|
13
13
|
field: string | SugarableRelativeSingleField;
|
|
14
|
-
}
|
|
14
|
+
};
|
|
15
15
|
//# sourceMappingURL=RelativeSingleField.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"RelativeSingleField.d.ts","sourceRoot":"","sources":["../../../src/treeParameters/RelativeSingleField.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,QAAQ,EAAE,iBAAiB,EAAE,MAAM,YAAY,CAAA;AAC7D,OAAO,KAAK,EAAE,cAAc,EAAE,uBAAuB,EAAE,MAAM,kBAAkB,CAAA;AAC/E,OAAO,KAAK,EAAE,SAAS,EAAE,oBAAoB,EAAE,MAAM,aAAa,CAAA;AAElE,MAAM,
|
|
1
|
+
{"version":3,"file":"RelativeSingleField.d.ts","sourceRoot":"","sources":["../../../src/treeParameters/RelativeSingleField.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,QAAQ,EAAE,iBAAiB,EAAE,MAAM,YAAY,CAAA;AAC7D,OAAO,KAAK,EAAE,cAAc,EAAE,uBAAuB,EAAE,MAAM,kBAAkB,CAAA;AAC/E,OAAO,KAAK,EAAE,SAAS,EAAE,oBAAoB,EAAE,MAAM,aAAa,CAAA;AAElE,MAAM,MAAM,mBAAmB,GAC5B,QAAQ,GACR,SAAS,GACT;IACD,kBAAkB,EAAE,cAAc,EAAE,CAAA;CACpC,CAAA;AAEF,MAAM,MAAM,4BAA4B,GACrC,iBAAiB,GACjB;IACD,kBAAkB,CAAC,EAAE,uBAAuB,EAAE,GAAG,uBAAuB,CAAA;CACxE,CAAA;AAEF,MAAM,MAAM,8BAA8B,GACvC,oBAAoB,CAAA;AAGvB,MAAM,MAAM,0BAA0B,GACnC,8BAA8B,GAC9B;IACD,yCAAyC;IACzC,KAAK,EAAE,MAAM,GAAG,4BAA4B,CAAA;CAC5C,CAAA"}
|