@agentshouse/mdmodel 0.1.0-ce4af152f38d8 → 0.1.0-ce7e4efd1b42d
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/API.md +153 -186
- package/README.md +25 -25
- package/dist/body.d.ts +85 -0
- package/dist/body.d.ts.map +1 -0
- package/dist/body.js +1083 -0
- package/dist/built-in.d.ts +4 -0
- package/dist/built-in.d.ts.map +1 -0
- package/dist/built-in.js +19 -0
- package/dist/definition.d.ts +23 -10
- package/dist/definition.d.ts.map +1 -1
- package/dist/definition.js +171 -116
- package/dist/document.d.ts +14 -8
- package/dist/document.d.ts.map +1 -1
- package/dist/document.js +747 -137
- package/dist/event.d.ts +1 -2
- package/dist/event.d.ts.map +1 -1
- package/dist/event.js +2 -3
- package/dist/facts.d.ts.map +1 -1
- package/dist/facts.js +3 -0
- package/dist/fields.d.ts +1 -1
- package/dist/fields.d.ts.map +1 -1
- package/dist/fields.js +2 -2
- package/dist/form.d.ts +4 -0
- package/dist/form.d.ts.map +1 -0
- package/dist/form.js +153 -0
- package/dist/house-model.d.ts +870 -0
- package/dist/house-model.d.ts.map +1 -0
- package/dist/house-model.js +472 -0
- package/dist/house-references/crockford.d.ts +4 -0
- package/dist/house-references/crockford.d.ts.map +1 -0
- package/dist/house-references/crockford.js +3 -0
- package/dist/house-references/patterns.d.ts +9 -0
- package/dist/house-references/patterns.d.ts.map +1 -0
- package/dist/house-references/patterns.js +13 -0
- package/dist/index.d.ts +30 -15
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +19 -10
- package/dist/indexed.d.ts +9 -0
- package/dist/indexed.d.ts.map +1 -0
- package/dist/indexed.js +55 -0
- package/dist/kinds.d.ts +3 -0
- package/dist/kinds.d.ts.map +1 -1
- package/dist/kinds.js +60 -0
- package/dist/markdown.d.ts +71 -0
- package/dist/markdown.d.ts.map +1 -0
- package/dist/markdown.js +232 -0
- package/dist/media-type.d.ts +72 -0
- package/dist/media-type.d.ts.map +1 -0
- package/dist/media-type.js +157 -0
- package/dist/moment.d.ts +7 -0
- package/dist/moment.d.ts.map +1 -0
- package/dist/moment.js +18 -0
- package/dist/not-ready.d.ts +2 -0
- package/dist/not-ready.d.ts.map +1 -0
- package/dist/not-ready.js +5 -0
- package/dist/paths.d.ts +15 -1
- package/dist/paths.d.ts.map +1 -1
- package/dist/paths.js +88 -19
- package/dist/query/language.d.ts +2 -1
- package/dist/query/language.d.ts.map +1 -1
- package/dist/query/language.js +1 -1
- package/dist/query/match.d.ts +1 -1
- package/dist/query/match.d.ts.map +1 -1
- package/dist/query/rows.d.ts +1 -1
- package/dist/query/rows.d.ts.map +1 -1
- package/dist/query/rows.js +2 -5
- package/dist/query/sql.d.ts +5 -1
- package/dist/query/sql.d.ts.map +1 -1
- package/dist/query/sql.js +3 -3
- package/dist/query/walk.d.ts +63 -0
- package/dist/query/walk.d.ts.map +1 -0
- package/dist/query/walk.js +263 -0
- package/dist/references.d.ts +2 -2
- package/dist/references.d.ts.map +1 -1
- package/dist/references.js +1 -1
- package/dist/refuse.d.ts +1 -0
- package/dist/refuse.d.ts.map +1 -1
- package/dist/refuse.js +1 -0
- package/dist/room-types.d.ts +7 -0
- package/dist/room-types.d.ts.map +1 -0
- package/dist/room-types.js +136 -0
- package/dist/schema.d.ts +1 -3
- package/dist/schema.d.ts.map +1 -1
- package/dist/schema.js +9 -73
- package/dist/types.d.ts +11 -38
- package/dist/types.d.ts.map +1 -1
- package/dist/validate.d.ts +6 -2
- package/dist/validate.d.ts.map +1 -1
- package/dist/validate.js +111 -178
- package/dist/yaml.d.ts +4 -4
- package/dist/yaml.d.ts.map +1 -1
- package/dist/yaml.js +1 -1
- package/fixtures/README.md +45 -63
- package/fixtures/cases/absent-link-dangles/library/item.md +1 -1
- package/fixtures/cases/absent-link-dangles/schema.yaml +2 -3
- package/fixtures/cases/absent-optional-field/library/companies/acme.md +1 -1
- package/fixtures/cases/absent-optional-field/library/deals/lead.md +3 -3
- package/fixtures/cases/absent-optional-field/schema.yaml +10 -11
- package/fixtures/cases/absolute-link/library/item.md +1 -1
- package/fixtures/cases/absolute-link/schema.yaml +2 -3
- package/fixtures/cases/attachment-reference-any-file/library/companies/acme.md +1 -1
- package/fixtures/cases/attachment-reference-any-file/library/deals/renewal.md +13 -10
- package/fixtures/cases/attachment-reference-any-file/library/places/depot.md +1 -1
- package/fixtures/cases/attachment-reference-any-file/library/products/seats.md +1 -1
- package/fixtures/cases/attachment-reference-any-file/library/products/support.md +1 -1
- package/fixtures/cases/attachment-reference-dangles/library/companies/acme.md +1 -1
- package/fixtures/cases/attachment-reference-dangles/library/deals/renewal.md +13 -10
- package/fixtures/cases/attachment-reference-dangles/library/places/depot.md +1 -1
- package/fixtures/cases/attachment-reference-dangles/library/products/seats.md +1 -1
- package/fixtures/cases/attachment-reference-dangles/library/products/support.md +1 -1
- package/fixtures/cases/attachment-reference-outside/expected.json +2 -1
- package/fixtures/cases/attachment-reference-outside/library/companies/acme.md +1 -1
- package/fixtures/cases/attachment-reference-outside/library/deals/renewal.md +13 -10
- package/fixtures/cases/attachment-reference-outside/library/places/depot.md +1 -1
- package/fixtures/cases/attachment-reference-outside/library/products/seats.md +1 -1
- package/fixtures/cases/attachment-reference-outside/library/products/support.md +1 -1
- package/fixtures/cases/binary-any-reference/expected.json +2 -1
- package/fixtures/cases/binary-any-reference/library/notes/draft.md +1 -1
- package/fixtures/cases/binary-prototype-reference/expected.json +2 -1
- package/fixtures/cases/binary-prototype-reference/library/notes/draft.md +1 -1
- package/fixtures/cases/binary-typed-reference/expected.json +2 -1
- package/fixtures/cases/binary-typed-reference/library/notes/draft.md +1 -1
- package/fixtures/cases/boolean-field/expected.json +2 -1
- package/fixtures/cases/boolean-field/library/companies/acme.md +1 -1
- package/fixtures/cases/boolean-field/library/deals/renewal.md +49 -24
- package/fixtures/cases/boolean-field/schema.yaml +10 -11
- package/fixtures/cases/bracketed-link-definition/library/item.md +1 -1
- package/fixtures/cases/bracketed-link-definition/schema.yaml +2 -3
- package/fixtures/cases/closed-nested-object/expected.json +2 -1
- package/fixtures/cases/closed-nested-object/library/companies/acme.md +1 -1
- package/fixtures/cases/closed-nested-object/library/deals/renewal.md +50 -25
- package/fixtures/cases/closed-nested-object/schema.yaml +10 -11
- package/fixtures/cases/composed-root-reference/library/a.md +2 -2
- package/fixtures/cases/{conditional-section → conditional-long-text}/expected.json +3 -2
- package/fixtures/cases/{conditional-section → conditional-long-text}/library/questions/hosting.md +2 -2
- package/fixtures/cases/{conditional-section → conditional-long-text}/library/questions/payments.md +2 -2
- package/fixtures/cases/conditional-long-text/schema.yaml +13 -0
- package/fixtures/cases/cross-room-link/library/clients/acme.md +1 -1
- package/fixtures/cases/cross-room-reference/library/clients/acme.md +4 -4
- package/fixtures/cases/cross-room-reference/schema.yaml +1 -2
- package/fixtures/cases/date-time-format/expected.json +2 -1
- package/fixtures/cases/date-time-format/library/companies/acme.md +1 -1
- package/fixtures/cases/date-time-format/library/deals/renewal.md +49 -24
- package/fixtures/cases/date-time-format/schema.yaml +10 -11
- package/fixtures/cases/default-unfilled/library/companies/acme.md +1 -1
- package/fixtures/cases/default-unfilled/library/deals/renewal.md +47 -22
- package/fixtures/cases/default-unfilled/schema.yaml +10 -11
- package/fixtures/cases/defs-pattern/expected.json +2 -1
- package/fixtures/cases/defs-pattern/library/companies/acme.md +1 -1
- package/fixtures/cases/defs-pattern/library/deals/renewal.md +49 -24
- package/fixtures/cases/defs-pattern/schema.yaml +10 -11
- package/fixtures/cases/dependent-rule/library/companies/acme.md +1 -1
- package/fixtures/cases/dependent-rule/library/deals/renewal.md +48 -23
- package/fixtures/cases/dependent-rule/schema.yaml +10 -11
- package/fixtures/cases/duplicate-link-definition/library/item.md +1 -1
- package/fixtures/cases/duplicate-link-definition/schema.yaml +2 -3
- package/fixtures/cases/email-format/expected.json +2 -1
- package/fixtures/cases/email-format/library/companies/acme.md +1 -1
- package/fixtures/cases/email-format/library/deals/renewal.md +49 -24
- package/fixtures/cases/email-format/schema.yaml +10 -11
- package/fixtures/cases/equal-labels/expected.json +5 -0
- package/fixtures/cases/equal-labels/schema.yaml +4 -0
- package/fixtures/cases/fenced-link-definition/library/item.md +1 -1
- package/fixtures/cases/fenced-link-definition/schema.yaml +2 -3
- package/fixtures/cases/field-enum/expected.json +2 -1
- package/fixtures/cases/field-enum/library/item.md +2 -2
- package/fixtures/cases/field-enum/schema.yaml +3 -4
- package/fixtures/cases/integer-field/expected.json +2 -1
- package/fixtures/cases/integer-field/library/companies/acme.md +1 -1
- package/fixtures/cases/integer-field/library/deals/renewal.md +49 -24
- package/fixtures/cases/integer-field/schema.yaml +10 -11
- package/fixtures/cases/json-schema-constructs/library/companies/acme.md +1 -1
- package/fixtures/cases/json-schema-constructs/library/deals/renewal.md +49 -24
- package/fixtures/cases/json-schema-constructs/schema.yaml +10 -11
- package/fixtures/cases/labels-in-the-rooms-language/library/deals/atlas.md +7 -0
- package/fixtures/cases/labels-in-the-rooms-language/schema.yaml +9 -0
- package/fixtures/cases/lazy-list-item/expected.json +3 -0
- package/fixtures/cases/lazy-list-item/library/item.md +10 -0
- package/fixtures/cases/lazy-list-item/schema.yaml +3 -0
- package/fixtures/cases/link-into-a-reserved-name/library/notes/a.md +1 -1
- package/fixtures/cases/list-item-enum/expected.json +7 -0
- package/fixtures/cases/list-item-enum/library/task.md +7 -0
- package/fixtures/cases/list-item-enum/schema.yaml +3 -0
- package/fixtures/cases/list-item-kind/expected.json +7 -0
- package/fixtures/cases/list-item-kind/library/task.md +6 -0
- package/fixtures/cases/list-item-kind/schema.yaml +3 -0
- package/fixtures/cases/list-items/expected.json +1 -0
- package/fixtures/cases/list-items/library/page.md +26 -0
- package/fixtures/cases/list-items/schema.yaml +10 -0
- package/fixtures/cases/list-of-objects-closed/expected.json +2 -1
- package/fixtures/cases/list-of-objects-closed/library/companies/acme.md +1 -1
- package/fixtures/cases/list-of-objects-closed/library/deals/renewal.md +49 -25
- package/fixtures/cases/list-of-objects-closed/schema.yaml +10 -11
- package/fixtures/cases/list-of-objects-item/expected.json +2 -1
- package/fixtures/cases/list-of-objects-item/library/companies/acme.md +1 -1
- package/fixtures/cases/list-of-objects-item/library/deals/renewal.md +49 -24
- package/fixtures/cases/list-of-objects-item/schema.yaml +10 -11
- package/fixtures/cases/list-of-objects-reference/expected.json +2 -1
- package/fixtures/cases/list-of-objects-reference/library/companies/acme.md +1 -1
- package/fixtures/cases/list-of-objects-reference/library/deals/renewal.md +12 -9
- package/fixtures/cases/list-of-objects-reference/library/places/depot.md +1 -1
- package/fixtures/cases/list-of-objects-reference/library/products/seats.md +1 -1
- package/fixtures/cases/list-of-objects-reference/library/products/support.md +1 -1
- package/fixtures/cases/list-reference-path/expected.json +7 -0
- package/fixtures/cases/list-reference-path/library/page.md +5 -0
- package/fixtures/cases/list-reference-path/schema.yaml +3 -0
- package/fixtures/cases/list-reference-type/expected.json +7 -0
- package/fixtures/cases/list-reference-type/library/page.md +6 -0
- package/fixtures/cases/list-reference-type/schema.yaml +3 -0
- package/fixtures/cases/list-size/expected.json +2 -1
- package/fixtures/cases/list-size/library/companies/acme.md +1 -1
- package/fixtures/cases/list-size/library/deals/renewal.md +51 -24
- package/fixtures/cases/list-size/schema.yaml +10 -11
- package/fixtures/cases/long-value-past-six-levels/expected.json +5 -0
- package/fixtures/cases/long-value-past-six-levels/schema.yaml +15 -0
- package/fixtures/cases/malformed-list/context.json +1 -0
- package/fixtures/cases/malformed-list/expected.json +7 -0
- package/fixtures/cases/{structured-section → malformed-list}/library/item.md +1 -1
- package/fixtures/cases/malformed-list/schema.yaml +6 -0
- package/fixtures/cases/member-document/library/people/ana.md +2 -2
- package/fixtures/cases/member-on-another-type/library/note.md +1 -1
- package/fixtures/cases/missing-required-field/library/item.md +1 -1
- package/fixtures/cases/missing-required-field/schema.yaml +3 -4
- package/fixtures/cases/misspelled-key/expected.json +2 -1
- package/fixtures/cases/misspelled-key/library/companies/acme.md +1 -1
- package/fixtures/cases/misspelled-key/library/deals/renewal.md +50 -25
- package/fixtures/cases/misspelled-key/schema.yaml +10 -11
- package/fixtures/cases/name-not-a-string/context.json +1 -0
- package/fixtures/cases/name-not-a-string/expected.json +5 -0
- package/fixtures/cases/name-not-a-string/schema.yaml +5 -0
- package/fixtures/cases/nested-defs/expected.json +2 -1
- package/fixtures/cases/nested-defs/library/deal.md +3 -3
- package/fixtures/cases/nested-object-reference/expected.json +2 -1
- package/fixtures/cases/nested-object-reference/library/companies/acme.md +1 -1
- package/fixtures/cases/nested-object-reference/library/deals/renewal.md +12 -9
- package/fixtures/cases/nested-object-reference/library/places/depot.md +1 -1
- package/fixtures/cases/nested-object-reference/library/products/seats.md +1 -1
- package/fixtures/cases/nested-object-reference/library/products/support.md +1 -1
- package/fixtures/cases/nested-reference/library/companies/acme.md +1 -1
- package/fixtures/cases/nested-reference/library/deals/renewal.md +13 -10
- package/fixtures/cases/nested-reference/library/places/depot.md +1 -1
- package/fixtures/cases/nested-reference/library/products/seats.md +1 -1
- package/fixtures/cases/nested-reference/library/products/support.md +1 -1
- package/fixtures/cases/nested-required-field/expected.json +2 -1
- package/fixtures/cases/nested-required-field/library/companies/acme.md +1 -1
- package/fixtures/cases/nested-required-field/library/deals/renewal.md +48 -23
- package/fixtures/cases/nested-required-field/schema.yaml +10 -11
- package/fixtures/cases/numeric-range/expected.json +2 -1
- package/fixtures/cases/numeric-range/library/companies/acme.md +1 -1
- package/fixtures/cases/numeric-range/library/deals/renewal.md +49 -24
- package/fixtures/cases/numeric-range/schema.yaml +10 -11
- package/fixtures/cases/one-key-two-labels/context.json +1 -0
- package/fixtures/cases/one-key-two-labels/expected.json +5 -0
- package/fixtures/cases/one-key-two-labels/schema.yaml +5 -0
- package/fixtures/cases/one-key-two-types/context.json +1 -0
- package/fixtures/cases/one-key-two-types/expected.json +5 -0
- package/fixtures/cases/one-key-two-types/schema.yaml +4 -0
- package/fixtures/cases/one-of-variant/expected.json +2 -1
- package/fixtures/cases/one-of-variant/library/companies/acme.md +1 -1
- package/fixtures/cases/one-of-variant/library/deals/renewal.md +49 -24
- package/fixtures/cases/one-of-variant/schema.yaml +10 -11
- package/fixtures/cases/other-room-reference/expected.json +2 -1
- package/fixtures/cases/other-room-reference/library/companies/acme.md +1 -1
- package/fixtures/cases/other-room-reference/library/deals/renewal.md +12 -9
- package/fixtures/cases/other-room-reference/library/places/depot.md +1 -1
- package/fixtures/cases/other-room-reference/library/products/seats.md +1 -1
- package/fixtures/cases/other-room-reference/library/products/support.md +1 -1
- package/fixtures/cases/prototype-field/expected.json +2 -1
- package/fixtures/cases/prototype-field/library/item.md +2 -2
- package/fixtures/cases/prototype-field/schema.yaml +2 -3
- package/fixtures/cases/reference-into-a-reserved-name/expected.json +2 -1
- package/fixtures/cases/reference-into-a-reserved-name/library/notes/a.md +1 -1
- package/fixtures/cases/referenced-missing-file/library/a.md +2 -2
- package/fixtures/cases/referenced-missing-file/library/b.md +2 -2
- package/fixtures/cases/referenced-missing-file/schema.yaml +3 -4
- package/fixtures/cases/sections-keyword-refused/context.json +1 -0
- package/fixtures/cases/sections-keyword-refused/expected.json +5 -0
- package/fixtures/cases/{structured-section → sections-keyword-refused}/schema.yaml +1 -2
- package/fixtures/cases/shortcut-reference-link/library/item.md +1 -1
- package/fixtures/cases/shortcut-reference-link/schema.yaml +2 -3
- package/fixtures/cases/string-length/expected.json +2 -1
- package/fixtures/cases/string-length/library/companies/acme.md +1 -1
- package/fixtures/cases/string-length/library/deals/renewal.md +49 -24
- package/fixtures/cases/string-length/schema.yaml +10 -11
- package/fixtures/cases/submission-keys/library/notes/visitor.md +2 -2
- package/fixtures/cases/text-field-kind/expected.json +1 -4
- package/fixtures/cases/text-field-kind/library/page.md +1 -1
- package/fixtures/cases/thematic-break-ends-the-values/context.json +1 -0
- package/fixtures/cases/thematic-break-ends-the-values/expected.json +1 -0
- package/fixtures/cases/thematic-break-ends-the-values/library/item.md +10 -0
- package/fixtures/cases/thematic-break-ends-the-values/schema.yaml +3 -0
- package/fixtures/cases/typed-path-names-its-type/library/settings/prefs/one.md +1 -1
- package/fixtures/cases/types-folder-content/library/types/task.md +1 -1
- package/fixtures/cases/undeclared-field/expected.json +2 -1
- package/fixtures/cases/undeclared-field/library/item.md +2 -2
- package/fixtures/cases/undeclared-field/schema.yaml +2 -3
- package/fixtures/cases/unevaluated-items-closed/expected.json +2 -1
- package/fixtures/cases/unevaluated-items-closed/library/trip.md +13 -3
- package/fixtures/cases/unnamed-typed-path-checks-its-fields/library/rooms/team/tasks/plan.md +2 -1
- package/fixtures/cases/unnamed-typed-path-names-a-type/library/rooms/team/tasks/plan.md +3 -2
- package/fixtures/cases/unnamed-typed-path-reads-its-type/library/rooms/team/tasks/plan.md +3 -2
- package/fixtures/cases/unnamed-typed-path-without-a-body/library/rooms/team/tasks/plan.md +2 -2
- package/fixtures/cases/unresolved-link/library/item.md +1 -1
- package/fixtures/cases/unresolved-link/schema.yaml +2 -3
- package/fixtures/cases/valid-typed-document/library/people/ada.md +1 -1
- package/fixtures/cases/valid-typed-document/library/tasks/one.md +11 -11
- package/fixtures/cases/valid-typed-document/schema.yaml +5 -6
- package/fixtures/forms.json +347 -0
- package/fixtures/preamble.json +29 -8
- package/fixtures/queries.json +397 -2
- package/package.json +10 -1
- package/dist/blocks.d.ts +0 -11
- package/dist/blocks.d.ts.map +0 -1
- package/dist/blocks.js +0 -87
- package/dist/divide.d.ts +0 -3
- package/dist/divide.d.ts.map +0 -1
- package/dist/divide.js +0 -320
- package/dist/links.d.ts +0 -29
- package/dist/links.d.ts.map +0 -1
- package/dist/links.js +0 -821
- package/dist/project.d.ts +0 -22
- package/dist/project.d.ts.map +0 -1
- package/dist/project.js +0 -126
- package/dist/sections.d.ts +0 -11
- package/dist/sections.d.ts.map +0 -1
- package/dist/sections.js +0 -57
- package/fixtures/cases/conditional-section/schema.yaml +0 -14
- package/fixtures/cases/missing-section-item-kind/expected.json +0 -5
- package/fixtures/cases/missing-section-item-kind/schema.yaml +0 -6
- package/fixtures/cases/null-refused/expected.json +0 -6
- package/fixtures/cases/null-refused/library/companies/acme.md +0 -4
- package/fixtures/cases/null-refused/library/deals/renewal.md +0 -31
- package/fixtures/cases/null-refused/schema.yaml +0 -56
- package/fixtures/cases/open-map-value/expected.json +0 -6
- package/fixtures/cases/open-map-value/library/companies/acme.md +0 -4
- package/fixtures/cases/open-map-value/library/deals/renewal.md +0 -31
- package/fixtures/cases/open-map-value/schema.yaml +0 -56
- package/fixtures/cases/section-item-enum/expected.json +0 -6
- package/fixtures/cases/section-item-enum/library/task.md +0 -8
- package/fixtures/cases/section-item-enum/schema.yaml +0 -3
- package/fixtures/cases/section-item-kind/expected.json +0 -6
- package/fixtures/cases/section-item-kind/library/task.md +0 -8
- package/fixtures/cases/section-item-kind/schema.yaml +0 -3
- package/fixtures/cases/section-items/library/page.md +0 -42
- package/fixtures/cases/section-items/schema.yaml +0 -10
- package/fixtures/cases/section-reference-path/expected.json +0 -6
- package/fixtures/cases/section-reference-path/library/page.md +0 -7
- package/fixtures/cases/section-reference-path/schema.yaml +0 -3
- package/fixtures/cases/section-reference-type/expected.json +0 -6
- package/fixtures/cases/section-reference-type/library/page.md +0 -7
- package/fixtures/cases/section-reference-type/schema.yaml +0 -3
- package/fixtures/cases/structured-section/expected.json +0 -6
- package/fixtures/division.json +0 -408
- package/fixtures/projection.json +0 -254
- /package/fixtures/cases/{conditional-section → conditional-long-text}/context.json +0 -0
- /package/fixtures/cases/{missing-section-item-kind → equal-labels}/context.json +0 -0
- /package/fixtures/cases/{null-refused → labels-in-the-rooms-language}/context.json +0 -0
- /package/fixtures/cases/{section-items → labels-in-the-rooms-language}/expected.json +0 -0
- /package/fixtures/cases/{open-map-value → lazy-list-item}/context.json +0 -0
- /package/fixtures/cases/{section-item-enum → list-item-enum}/context.json +0 -0
- /package/fixtures/cases/{section-item-kind → list-item-kind}/context.json +0 -0
- /package/fixtures/cases/{section-items → list-items}/context.json +0 -0
- /package/fixtures/cases/{section-items → list-items}/library/other.md +0 -0
- /package/fixtures/cases/{section-reference-path → list-reference-path}/context.json +0 -0
- /package/fixtures/cases/{section-reference-path → list-reference-path}/library/other.md +0 -0
- /package/fixtures/cases/{section-reference-type → list-reference-type}/context.json +0 -0
- /package/fixtures/cases/{section-reference-type → list-reference-type}/library/note.md +0 -0
- /package/fixtures/cases/{structured-section → long-value-past-six-levels}/context.json +0 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"built-in.d.ts","sourceRoot":"","sources":["../src/built-in.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,YAAY,CAAC;AAiBhD,eAAO,MAAM,WAAW,eAA8C,CAAC;AAEvE,eAAO,MAAM,gBAAgB,EAAE,aAG7B,CAAC"}
|
package/dist/built-in.js
ADDED
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { HOUSE_MODEL_DECLARATION } from './house-model.js';
|
|
2
|
+
import { INBOX_TYPES, ROOM_TYPES_TEXT } from './room-types.js';
|
|
3
|
+
import { verify } from './validate.js';
|
|
4
|
+
function modelText(model) {
|
|
5
|
+
return `${Object.entries(model)
|
|
6
|
+
.map(([name, declared]) => `${name}: ${JSON.stringify(declared)}`)
|
|
7
|
+
.join('\n')}\n`;
|
|
8
|
+
}
|
|
9
|
+
function builtIn(text, provided) {
|
|
10
|
+
const checked = verify(text, provided);
|
|
11
|
+
if (checked.verdict === 'accept')
|
|
12
|
+
return checked.model;
|
|
13
|
+
throw new Error(`House's built-in types refuse: ${checked.rule} ${checked.location ?? ''}`.trim());
|
|
14
|
+
}
|
|
15
|
+
export const HOUSE_MODEL = builtIn(modelText(HOUSE_MODEL_DECLARATION));
|
|
16
|
+
export const HOUSE_ROOM_TYPES = Object.freeze({
|
|
17
|
+
...builtIn(ROOM_TYPES_TEXT, HOUSE_MODEL),
|
|
18
|
+
nameable: INBOX_TYPES,
|
|
19
|
+
});
|
package/dist/definition.d.ts
CHANGED
|
@@ -8,9 +8,13 @@ export type ValueFacts = {
|
|
|
8
8
|
readonly crossRoom?: true;
|
|
9
9
|
readonly prose: boolean;
|
|
10
10
|
readonly conditional?: true;
|
|
11
|
+
readonly title?: string;
|
|
12
|
+
readonly markdown?: true;
|
|
13
|
+
readonly json?: true;
|
|
11
14
|
readonly prefix?: readonly ValueFacts[];
|
|
12
15
|
readonly items?: ValueFacts;
|
|
13
16
|
readonly properties?: Readonly<Record<string, ValueFacts>>;
|
|
17
|
+
readonly required?: readonly string[];
|
|
14
18
|
readonly patterns?: readonly PatternFacts[];
|
|
15
19
|
readonly additional?: ValueFacts;
|
|
16
20
|
};
|
|
@@ -18,14 +22,6 @@ export type PatternFacts = {
|
|
|
18
22
|
readonly pattern: string;
|
|
19
23
|
readonly facts: ValueFacts;
|
|
20
24
|
};
|
|
21
|
-
export type SectionSpec = {
|
|
22
|
-
readonly kind: 'text';
|
|
23
|
-
readonly required: boolean;
|
|
24
|
-
} | {
|
|
25
|
-
readonly kind: 'list';
|
|
26
|
-
readonly required: boolean;
|
|
27
|
-
readonly items: ValueFacts;
|
|
28
|
-
};
|
|
29
25
|
export type Shape = {
|
|
30
26
|
readonly schema: Readonly<Record<string, unknown>>;
|
|
31
27
|
readonly defs: Readonly<Record<string, unknown>>;
|
|
@@ -44,29 +40,45 @@ export type FieldRules = {
|
|
|
44
40
|
export type Definition = {
|
|
45
41
|
readonly name: string;
|
|
46
42
|
readonly memberDocument: boolean;
|
|
47
|
-
readonly
|
|
43
|
+
readonly root: ValueFacts;
|
|
48
44
|
readonly fields: Readonly<Record<string, ValueFacts>>;
|
|
49
|
-
readonly sections: Readonly<Record<string, SectionSpec>>;
|
|
50
45
|
readonly rules: Readonly<Record<string, FieldRules>>;
|
|
51
46
|
readonly createRoles?: readonly string[];
|
|
52
47
|
readonly deleteRoles?: readonly string[];
|
|
48
|
+
readonly indexed?: readonly string[];
|
|
53
49
|
readonly shape: Shape;
|
|
54
50
|
};
|
|
55
51
|
export type Failure = {
|
|
56
52
|
readonly rule: string;
|
|
57
53
|
readonly location?: string;
|
|
58
54
|
};
|
|
55
|
+
export type Placed = {
|
|
56
|
+
readonly node: Record<string, unknown>;
|
|
57
|
+
readonly at: string;
|
|
58
|
+
};
|
|
59
59
|
export declare const JSON_TYPES: readonly JsonType[];
|
|
60
60
|
export declare const BUILT_IN_TYPE = "any";
|
|
61
61
|
export declare const ATTACHMENT = "attachment";
|
|
62
|
+
export declare const OPENING: readonly string[];
|
|
63
|
+
export declare const UNIONS: readonly string[];
|
|
62
64
|
export declare const ARRAY_INDEX: RegExp;
|
|
63
65
|
export declare const JSON_POINTER: RegExp;
|
|
66
|
+
export declare function refuse(rule: string, location: string): Failure;
|
|
64
67
|
export declare function escapePointer(key: string): string;
|
|
65
68
|
export declare function pointerSegments(pointer: string): string[];
|
|
66
69
|
export declare function refTarget(reference: string, defs: Readonly<Record<string, unknown>>): {
|
|
67
70
|
readonly name: string;
|
|
68
71
|
readonly node: unknown;
|
|
69
72
|
} | undefined;
|
|
73
|
+
export declare function conjoined(declared: readonly {
|
|
74
|
+
readonly node: unknown;
|
|
75
|
+
readonly at: string;
|
|
76
|
+
}[], defs: Readonly<Record<string, unknown>>, ancestry: ReadonlySet<unknown>): {
|
|
77
|
+
readonly held: readonly Placed[];
|
|
78
|
+
readonly ancestry: ReadonlySet<unknown>;
|
|
79
|
+
};
|
|
80
|
+
export declare function variantsOf({ node, at }: Placed): Placed[];
|
|
81
|
+
export declare function admitted(nodes: readonly unknown[], defs: Readonly<Record<string, unknown>>, ancestry: ReadonlySet<unknown>): Set<string> | null;
|
|
70
82
|
export declare function valueFacts(node: unknown, defs: Readonly<Record<string, unknown>>): ValueFacts;
|
|
71
83
|
export declare function itemFacts(facts: ValueFacts, index: number): ValueFacts | undefined;
|
|
72
84
|
export declare function memberFacts(facts: ValueFacts, key: string): ValueFacts | undefined;
|
|
@@ -78,5 +90,6 @@ export type PointerFacts = {
|
|
|
78
90
|
export declare function crossedFacts(facts: ValueFacts): ValueFacts[];
|
|
79
91
|
export declare function fieldFacts(definition: Definition, key: string): ValueFacts | undefined;
|
|
80
92
|
export declare function pointerFacts(definition: Definition, pointer: string): PointerFacts | undefined;
|
|
93
|
+
export declare function untitled(definition: Definition): Definition;
|
|
81
94
|
export declare function readSchema(text: string, provided?: VerifiedModel, checked?: boolean): VerifiedModel | Failure;
|
|
82
95
|
//# sourceMappingURL=definition.d.ts.map
|
package/dist/definition.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"definition.d.ts","sourceRoot":"","sources":["../src/definition.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"definition.d.ts","sourceRoot":"","sources":["../src/definition.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,YAAY,CAAC;AAGhD,MAAM,MAAM,QAAQ,GAAG,QAAQ,GAAG,QAAQ,GAAG,SAAS,GAAG,SAAS,GAAG,QAAQ,GAAG,OAAO,GAAG,MAAM,CAAC;AAEjG,MAAM,MAAM,UAAU,GAAG;IACvB,QAAQ,CAAC,IAAI,CAAC,EAAE,QAAQ,CAAC;IACzB,QAAQ,CAAC,MAAM,CAAC,EAAE,MAAM,CAAC;IACzB,QAAQ,CAAC,MAAM,CAAC,EAAE,SAAS,OAAO,EAAE,CAAC;IACrC,QAAQ,CAAC,SAAS,CAAC,EAAE,SAAS,MAAM,EAAE,CAAC;IACvC,QAAQ,CAAC,SAAS,CAAC,EAAE,IAAI,CAAC;IAC1B,QAAQ,CAAC,KAAK,EAAE,OAAO,CAAC;IACxB,QAAQ,CAAC,WAAW,CAAC,EAAE,IAAI,CAAC;IAC5B,QAAQ,CAAC,KAAK,CAAC,EAAE,MAAM,CAAC;IACxB,QAAQ,CAAC,QAAQ,CAAC,EAAE,IAAI,CAAC;IACzB,QAAQ,CAAC,IAAI,CAAC,EAAE,IAAI,CAAC;IACrB,QAAQ,CAAC,MAAM,CAAC,EAAE,SAAS,UAAU,EAAE,CAAC;IACxC,QAAQ,CAAC,KAAK,CAAC,EAAE,UAA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AAC,KAAK,EAAE,UAAU,EAAE,KAAK,EAAE,MAAM,GAAG,UAAU,GAAG,SAAS,CAElF;AAED,wBAAgB,WAAW,CAAC,KAAK,EAAE,UAAU,EAAE,GAAG,EAAE,MAAM,GAAG,UAAU,GAAG,SAAS,CAKlF;AAED,MAAM,MAAM,YAAY,GAAG;IACzB,QAAQ,CAAC,KAAK,EAAE,UAAU,CAAC;IAC3B,QAAQ,CAAC,OAAO,EAAE,OAAO,CAAC;IAC1B,QAAQ,CAAC,WAAW,EAAE,OAAO,CAAC;CAC/B,CAAC;AAEF,wBAAgB,YAAY,CAAC,KAAK,EAAE,UAAU,GAAG,UAAU,EAAE,CAK5D;AAED,wBAAgB,UAAU,CAAC,UAAU,EAAE,UAAU,EAAE,GAAG,EAAE,MAAM,GAAG,UAAU,GAAG,SAAS,CAItF;AAqBD,wBAAgB,YAAY,CAAC,UAAU,EAAE,UAAU,EAAE,OAAO,EAAE,MAAM,GAAG,YAAY,GAAG,SAAS,CAc9F;AAmED,wBAAgB,QAAQ,CAAC,UAAU,EAAE,UAAU,GAAG,UAAU,CAY3D;AAmND,wBAAgB,UAAU,CACxB,IAAI,EAAE,MAAM,EACZ,QAAQ,GAAE,aAAwB,EAClC,OAAO,UAAO,GACb,aAAa,GAAG,OAAO,CA0CzB"}
|
package/dist/definition.js
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import { MEMBER_FIELD,
|
|
1
|
+
import { MEMBER_FIELD, SITE_FIELD, SUBMITTED_FIELD, TYPE_FIELD } from './fields.js';
|
|
2
|
+
import { MEDIA_TYPES } from './media-type.js';
|
|
2
3
|
import { linearPattern } from './pattern.js';
|
|
3
4
|
import { equalValue, isRecord, jsValue, parseYamlMapping, YamlError } from './yaml.js';
|
|
4
5
|
export const JSON_TYPES = [
|
|
@@ -12,7 +13,6 @@ export const JSON_TYPES = [
|
|
|
12
13
|
];
|
|
13
14
|
export const BUILT_IN_TYPE = 'any';
|
|
14
15
|
export const ATTACHMENT = 'attachment';
|
|
15
|
-
const SCALAR_TYPES = new Set(['string', 'number', 'integer', 'boolean']);
|
|
16
16
|
const COMPOSITES = ['array', 'object'];
|
|
17
17
|
const ANNOTATIONS = new Set([
|
|
18
18
|
'$comment',
|
|
@@ -24,20 +24,22 @@ const ANNOTATIONS = new Set([
|
|
|
24
24
|
'readOnly',
|
|
25
25
|
'writeOnly',
|
|
26
26
|
]);
|
|
27
|
+
export const OPENING = ['additionalProperties', 'unevaluatedProperties'];
|
|
27
28
|
const FIELD_RULES = ['change_roles', 'initial_roles', 'transitions'];
|
|
28
29
|
const PROVIDED_KEYWORDS = ['create_roles', 'delete_roles'];
|
|
29
30
|
const NO_TYPES = Object.freeze({ types: Object.freeze({}) });
|
|
30
31
|
const DEFS_REFERENCE = '#/$defs/';
|
|
31
32
|
const UNBOUNDED_FORMAT = 'url';
|
|
33
|
+
export const UNIONS = ['anyOf', 'oneOf'];
|
|
32
34
|
const UNRESOLVED = /[\u0000-\u001f\u007f%[\]\\^{|}]|\s$/u;
|
|
33
35
|
export const ARRAY_INDEX = /^(?:0|[1-9][0-9]*)$/u;
|
|
34
36
|
export const JSON_POINTER = /^(?:\/(?:[^~/]|~[01])*)*$/u;
|
|
35
37
|
const HOUSE_KEYS = {
|
|
36
38
|
[TYPE_FIELD]: { prose: false },
|
|
37
39
|
[SITE_FIELD]: { prose: false },
|
|
38
|
-
[
|
|
40
|
+
[SUBMITTED_FIELD]: { prose: false },
|
|
39
41
|
};
|
|
40
|
-
function refuse(rule, location) {
|
|
42
|
+
export function refuse(rule, location) {
|
|
41
43
|
return { rule, location };
|
|
42
44
|
}
|
|
43
45
|
export function escapePointer(key) {
|
|
@@ -247,36 +249,41 @@ function firstOf(held, read) {
|
|
|
247
249
|
}
|
|
248
250
|
return undefined;
|
|
249
251
|
}
|
|
250
|
-
function conjoined(
|
|
252
|
+
export function conjoined(declared, defs, ancestry) {
|
|
251
253
|
const held = [];
|
|
252
254
|
const reached = new Set(ancestry);
|
|
253
|
-
const visit = (node) => {
|
|
254
|
-
if (!isRecord(node) || held.
|
|
255
|
+
const visit = (node, at) => {
|
|
256
|
+
if (!isRecord(node) || held.some((one) => one.node === node))
|
|
255
257
|
return;
|
|
256
|
-
held.push(node);
|
|
258
|
+
held.push({ node, at });
|
|
257
259
|
if (typeof node.$ref === 'string') {
|
|
258
260
|
const target = refTarget(node.$ref, defs)?.node;
|
|
259
261
|
if (target !== undefined && !reached.has(target)) {
|
|
260
262
|
reached.add(target);
|
|
261
|
-
visit(target);
|
|
263
|
+
visit(target, node.$ref.slice('#'.length));
|
|
262
264
|
}
|
|
263
265
|
}
|
|
264
266
|
if (Array.isArray(node.allOf))
|
|
265
|
-
|
|
266
|
-
visit(one);
|
|
267
|
+
node.allOf.forEach((one, index) => visit(one, `${at}/allOf/${index}`));
|
|
267
268
|
};
|
|
268
|
-
for (const node of
|
|
269
|
-
visit(node);
|
|
269
|
+
for (const { node, at } of declared)
|
|
270
|
+
visit(node, at);
|
|
270
271
|
return { held, ancestry: reached };
|
|
271
272
|
}
|
|
272
|
-
function variantsOf(node) {
|
|
273
|
+
export function variantsOf({ node, at }) {
|
|
274
|
+
const listed = (keyword) => {
|
|
275
|
+
const branches = node[keyword];
|
|
276
|
+
return Array.isArray(branches)
|
|
277
|
+
? branches.map((branch, index) => ({ node: branch, at: `${at}/${keyword}/${index}` }))
|
|
278
|
+
: [];
|
|
279
|
+
};
|
|
273
280
|
return [
|
|
274
|
-
...(
|
|
275
|
-
...(
|
|
276
|
-
node.then,
|
|
277
|
-
node.else,
|
|
278
|
-
...(isRecord(node.dependentSchemas) ?
|
|
279
|
-
].filter(isRecord);
|
|
281
|
+
...listed('anyOf'),
|
|
282
|
+
...listed('oneOf'),
|
|
283
|
+
{ node: node.then, at: `${at}/then` },
|
|
284
|
+
{ node: node.else, at: `${at}/else` },
|
|
285
|
+
...Object.entries(isRecord(node.dependentSchemas) ? node.dependentSchemas : {}).map(([key, branch]) => ({ node: branch, at: `${at}/dependentSchemas/${escapePointer(key)}` })),
|
|
286
|
+
].filter((one) => isRecord(one.node));
|
|
280
287
|
}
|
|
281
288
|
function united(left, right) {
|
|
282
289
|
if (left === undefined || right === undefined)
|
|
@@ -307,6 +314,8 @@ function joined(left, right) {
|
|
|
307
314
|
return shared === undefined ? [] : [{ pattern, facts: shared }];
|
|
308
315
|
});
|
|
309
316
|
const additional = both(left.additional, right.additional);
|
|
317
|
+
const required = (left.required ?? []).filter((name) => right.required?.includes(name) === true);
|
|
318
|
+
const title = left.title ?? right.title;
|
|
310
319
|
return {
|
|
311
320
|
...(type === undefined ? {} : { type }),
|
|
312
321
|
...(format === undefined ? {} : { format }),
|
|
@@ -314,9 +323,13 @@ function joined(left, right) {
|
|
|
314
323
|
...(reference === undefined ? {} : { reference }),
|
|
315
324
|
...(reference !== undefined && crossRoom ? { crossRoom: true } : {}),
|
|
316
325
|
prose: left.prose && right.prose,
|
|
326
|
+
...(title === undefined ? {} : { title }),
|
|
327
|
+
...(left.markdown === true || right.markdown === true ? { markdown: true } : {}),
|
|
328
|
+
...(left.json === true || right.json === true ? { json: true } : {}),
|
|
317
329
|
...(prefix === undefined ? {} : { prefix }),
|
|
318
330
|
...(items === undefined ? {} : { items }),
|
|
319
331
|
...(Object.keys(properties).length === 0 ? {} : { properties }),
|
|
332
|
+
...(required.length === 0 ? {} : { required }),
|
|
320
333
|
...(patterns.length === 0 ? {} : { patterns }),
|
|
321
334
|
...(additional === undefined ? {} : { additional }),
|
|
322
335
|
};
|
|
@@ -368,12 +381,78 @@ function inheritedOf(held) {
|
|
|
368
381
|
return Object.keys(kept).length === 0 ? [] : [kept];
|
|
369
382
|
});
|
|
370
383
|
}
|
|
384
|
+
function typeSet(type) {
|
|
385
|
+
const listed = typeof type === 'string' ? [type] : Array.isArray(type) ? type : null;
|
|
386
|
+
return listed === null
|
|
387
|
+
? null
|
|
388
|
+
: new Set(listed.map((one) => (one === 'integer' ? 'number' : String(one))));
|
|
389
|
+
}
|
|
390
|
+
function valueType(value) {
|
|
391
|
+
if (value === null)
|
|
392
|
+
return 'null';
|
|
393
|
+
if (Array.isArray(value))
|
|
394
|
+
return 'array';
|
|
395
|
+
return typeof value;
|
|
396
|
+
}
|
|
397
|
+
function narrowed(left, right) {
|
|
398
|
+
if (left === null)
|
|
399
|
+
return right;
|
|
400
|
+
if (right === null)
|
|
401
|
+
return left;
|
|
402
|
+
return new Set([...left].filter((one) => right.has(one)));
|
|
403
|
+
}
|
|
404
|
+
export function admitted(nodes, defs, ancestry) {
|
|
405
|
+
const conjunction = conjoined(nodes.map((node) => ({ node, at: '' })), defs, ancestry);
|
|
406
|
+
let kept = null;
|
|
407
|
+
for (const { node } of conjunction.held) {
|
|
408
|
+
kept = narrowed(kept, typeSet(node.type));
|
|
409
|
+
if (Array.isArray(node.enum))
|
|
410
|
+
kept = narrowed(kept, new Set(node.enum.map(valueType)));
|
|
411
|
+
if (Object.hasOwn(node, 'const'))
|
|
412
|
+
kept = narrowed(kept, new Set([valueType(node.const)]));
|
|
413
|
+
for (const keyword of UNIONS) {
|
|
414
|
+
const branches = node[keyword];
|
|
415
|
+
if (!Array.isArray(branches))
|
|
416
|
+
continue;
|
|
417
|
+
let union = new Set();
|
|
418
|
+
for (const branch of branches) {
|
|
419
|
+
const one = admitted([branch], defs, conjunction.ancestry);
|
|
420
|
+
if (one === null) {
|
|
421
|
+
union = null;
|
|
422
|
+
break;
|
|
423
|
+
}
|
|
424
|
+
for (const type of one)
|
|
425
|
+
union.add(type);
|
|
426
|
+
}
|
|
427
|
+
kept = narrowed(kept, union);
|
|
428
|
+
}
|
|
429
|
+
}
|
|
430
|
+
return kept;
|
|
431
|
+
}
|
|
432
|
+
function structuredUnion(held, defs, ancestry) {
|
|
433
|
+
return held.some((node) => UNIONS.some((keyword) => Array.isArray(node[keyword]) &&
|
|
434
|
+
node[keyword].some((branch) => {
|
|
435
|
+
const types = admitted([branch], defs, ancestry);
|
|
436
|
+
return types === null || types.has('object') || types.has('array');
|
|
437
|
+
})));
|
|
438
|
+
}
|
|
439
|
+
function openWhole(held) {
|
|
440
|
+
return held.some((node) => OPENING.some((keyword) => node[keyword] === true));
|
|
441
|
+
}
|
|
442
|
+
function writtenAsJson(held, defs, ancestry) {
|
|
443
|
+
const types = admitted(held, defs, ancestry);
|
|
444
|
+
if (types === null || types.size !== 1)
|
|
445
|
+
return true;
|
|
446
|
+
return structuredUnion(held, defs, ancestry) || (types.has('object') && openWhole(held));
|
|
447
|
+
}
|
|
371
448
|
function factsOf(nodes, defs, ancestry) {
|
|
372
|
-
const {
|
|
449
|
+
const conjunction = conjoined(nodes.map((node) => ({ node, at: '' })), defs, ancestry);
|
|
450
|
+
const reached = conjunction.ancestry;
|
|
451
|
+
const held = conjunction.held.map(({ node }) => node);
|
|
373
452
|
const inherited = inheritedOf(held);
|
|
374
|
-
const variants = new Map(held
|
|
453
|
+
const variants = new Map(conjunction.held
|
|
375
454
|
.flatMap(variantsOf)
|
|
376
|
-
.map((branch) => [branch, factsOf([branch, ...inherited], defs, reached)]));
|
|
455
|
+
.map(({ node: branch }) => [branch, factsOf([branch, ...inherited], defs, reached)]));
|
|
377
456
|
const unions = alternativesOf(held, variants);
|
|
378
457
|
const alternatives = unions.map((kept) => kept.reduce(joined));
|
|
379
458
|
const listed = [
|
|
@@ -414,13 +493,18 @@ function factsOf(nodes, defs, ancestry) {
|
|
|
414
493
|
: Array.from({ length: Math.max(...tuples.map((tuple) => tuple.length)) }, (_, index) => factsOf(tuples.flatMap((tuple) => (index < tuple.length ? [tuple[index]] : [])), defs, reached))));
|
|
415
494
|
const mapped = type === 'object' || type === undefined;
|
|
416
495
|
const properties = mapped ? propertiesOf(held, variants, defs, reached) : undefined;
|
|
496
|
+
const required = mapped
|
|
497
|
+
? [...new Set(held.flatMap((node) => (Array.isArray(node.required) ? node.required : [])))]
|
|
498
|
+
: [];
|
|
417
499
|
const patterns = mapped
|
|
418
500
|
? held.flatMap((node) => Object.entries(isRecord(node.patternProperties) ? node.patternProperties : {}).map(([pattern, schema]) => ({ pattern, facts: factsOf([schema], defs, reached) })))
|
|
419
501
|
: [];
|
|
420
502
|
const opened = mapped
|
|
421
|
-
? held.flatMap((node) =>
|
|
503
|
+
? held.flatMap((node) => OPENING.map((keyword) => (node[keyword] === true ? {} : node[keyword])).filter(isRecord))
|
|
422
504
|
: [];
|
|
423
505
|
const additional = opened.length === 0 ? undefined : factsOf(opened, defs, reached);
|
|
506
|
+
const title = firstOf(nodes.filter(isRecord), (node) => typeof node.title === 'string' ? node.title : undefined);
|
|
507
|
+
const markdown = held.some((node) => node.contentMediaType === MEDIA_TYPES.markdown);
|
|
424
508
|
return {
|
|
425
509
|
...(type === undefined ? {} : { type }),
|
|
426
510
|
...(format === undefined ? {} : { format }),
|
|
@@ -428,9 +512,13 @@ function factsOf(nodes, defs, ancestry) {
|
|
|
428
512
|
...(reference === undefined ? {} : { reference }),
|
|
429
513
|
...(reference !== undefined && crossRoom ? { crossRoom: true } : {}),
|
|
430
514
|
prose,
|
|
515
|
+
...(title === undefined ? {} : { title }),
|
|
516
|
+
...(markdown ? { markdown: true } : {}),
|
|
517
|
+
...(writtenAsJson(held, defs, ancestry) ? { json: true } : {}),
|
|
431
518
|
...(prefix === undefined ? {} : { prefix }),
|
|
432
519
|
...(items === undefined ? {} : { items }),
|
|
433
520
|
...(properties === undefined ? {} : { properties }),
|
|
521
|
+
...(required.length === 0 ? {} : { required }),
|
|
434
522
|
...(patterns.length === 0 ? {} : { patterns }),
|
|
435
523
|
...(additional === undefined ? {} : { additional }),
|
|
436
524
|
};
|
|
@@ -457,7 +545,7 @@ export function fieldFacts(definition, key) {
|
|
|
457
545
|
return definition.fields[key];
|
|
458
546
|
if (Object.hasOwn(HOUSE_KEYS, key))
|
|
459
547
|
return undefined;
|
|
460
|
-
return memberFacts(definition.
|
|
548
|
+
return memberFacts(definition.root, key);
|
|
461
549
|
}
|
|
462
550
|
function stepped({ facts, through, conditional }, token) {
|
|
463
551
|
if (facts.type === 'array' && ARRAY_INDEX.test(token)) {
|
|
@@ -515,87 +603,60 @@ function reachedDefs(value, defs, reached) {
|
|
|
515
603
|
reachedDefs(held, defs, reached);
|
|
516
604
|
}
|
|
517
605
|
}
|
|
518
|
-
function
|
|
519
|
-
|
|
520
|
-
|
|
521
|
-
|
|
522
|
-
const
|
|
523
|
-
|
|
524
|
-
const where = `${at}/${escapePointer(name)}`;
|
|
525
|
-
if (!isRecord(spec) || (spec.kind !== 'text' && spec.kind !== 'list'))
|
|
526
|
-
return failed('sections', where);
|
|
527
|
-
const allowed = spec.kind === 'list' ? ['kind', 'required', 'items'] : ['kind', 'required'];
|
|
528
|
-
const extra = Object.keys(spec).find((key) => !allowed.includes(key));
|
|
529
|
-
if (extra !== undefined)
|
|
530
|
-
return failed('sections', `${where}/${escapePointer(extra)}`);
|
|
531
|
-
if (spec.required !== undefined && typeof spec.required !== 'boolean')
|
|
532
|
-
return failed('sections', `${where}/required`);
|
|
533
|
-
const required = spec.required === true;
|
|
534
|
-
if (spec.kind === 'text') {
|
|
535
|
-
sections[name] = { kind: 'text', required };
|
|
606
|
+
function untitledSchema(node) {
|
|
607
|
+
if (!isRecord(node))
|
|
608
|
+
return node;
|
|
609
|
+
const kept = {};
|
|
610
|
+
for (const [key, held] of Object.entries(node)) {
|
|
611
|
+
if (key === 'title' && typeof held === 'string')
|
|
536
612
|
continue;
|
|
537
|
-
|
|
538
|
-
if (
|
|
539
|
-
|
|
540
|
-
|
|
541
|
-
|
|
542
|
-
|
|
543
|
-
|
|
544
|
-
|
|
545
|
-
|
|
546
|
-
sections[name] = { kind: 'list', required, items };
|
|
547
|
-
}
|
|
548
|
-
return { sections };
|
|
549
|
-
}
|
|
550
|
-
function branchSectionsFailure(sections, declared, where) {
|
|
551
|
-
if (!isRecord(sections))
|
|
552
|
-
return refuse('sections', where);
|
|
553
|
-
for (const [name, spec] of Object.entries(sections)) {
|
|
554
|
-
const place = `${where}/${escapePointer(name)}`;
|
|
555
|
-
const own = isRecord(declared) && Object.hasOwn(declared, name) ? declared[name] : undefined;
|
|
556
|
-
if (!isRecord(spec) || !isRecord(own))
|
|
557
|
-
return refuse('sections', place);
|
|
558
|
-
const { required, ...kind } = spec;
|
|
559
|
-
const { required: _required, ...ownKind } = own;
|
|
560
|
-
if (required !== undefined && typeof required !== 'boolean')
|
|
561
|
-
return refuse('sections', `${place}/required`);
|
|
562
|
-
if (!equalValue(kind, ownKind))
|
|
563
|
-
return refuse('sections', place);
|
|
613
|
+
const check = Object.hasOwn(KEYWORDS, key) ? KEYWORDS[key] : undefined;
|
|
614
|
+
if (check === SCHEMA)
|
|
615
|
+
kept[key] = untitledSchema(held);
|
|
616
|
+
else if (check === SCHEMA_LIST && Array.isArray(held))
|
|
617
|
+
kept[key] = held.map(untitledSchema);
|
|
618
|
+
else if (check === SCHEMA_MAP && isRecord(held))
|
|
619
|
+
kept[key] = untitledMap(held);
|
|
620
|
+
else
|
|
621
|
+
kept[key] = held;
|
|
564
622
|
}
|
|
565
|
-
return
|
|
623
|
+
return kept;
|
|
566
624
|
}
|
|
567
|
-
function
|
|
568
|
-
|
|
569
|
-
|
|
570
|
-
|
|
571
|
-
|
|
572
|
-
|
|
573
|
-
|
|
574
|
-
|
|
575
|
-
|
|
576
|
-
|
|
577
|
-
|
|
578
|
-
|
|
579
|
-
|
|
580
|
-
|
|
581
|
-
|
|
582
|
-
|
|
583
|
-
|
|
584
|
-
|
|
585
|
-
|
|
586
|
-
|
|
587
|
-
|
|
588
|
-
|
|
589
|
-
|
|
590
|
-
|
|
591
|
-
|
|
592
|
-
|
|
593
|
-
|
|
594
|
-
|
|
595
|
-
|
|
596
|
-
|
|
597
|
-
|
|
598
|
-
|
|
625
|
+
function untitledMap(map) {
|
|
626
|
+
return Object.fromEntries(Object.entries(map).map(([key, held]) => [key, untitledSchema(held)]));
|
|
627
|
+
}
|
|
628
|
+
function untitledFacts(facts) {
|
|
629
|
+
const { title: _title, prefix, items, properties, patterns, additional, ...kept } = facts;
|
|
630
|
+
return {
|
|
631
|
+
...kept,
|
|
632
|
+
...(prefix === undefined ? {} : { prefix: prefix.map(untitledFacts) }),
|
|
633
|
+
...(items === undefined ? {} : { items: untitledFacts(items) }),
|
|
634
|
+
...(properties === undefined
|
|
635
|
+
? {}
|
|
636
|
+
: {
|
|
637
|
+
properties: Object.fromEntries(Object.entries(properties).map(([key, held]) => [key, untitledFacts(held)])),
|
|
638
|
+
}),
|
|
639
|
+
...(patterns === undefined
|
|
640
|
+
? {}
|
|
641
|
+
: {
|
|
642
|
+
patterns: patterns.map(({ pattern, facts: held }) => ({
|
|
643
|
+
pattern,
|
|
644
|
+
facts: untitledFacts(held),
|
|
645
|
+
})),
|
|
646
|
+
}),
|
|
647
|
+
...(additional === undefined ? {} : { additional: untitledFacts(additional) }),
|
|
648
|
+
};
|
|
649
|
+
}
|
|
650
|
+
export function untitled(definition) {
|
|
651
|
+
return {
|
|
652
|
+
...definition,
|
|
653
|
+
root: untitledFacts(definition.root),
|
|
654
|
+
fields: Object.fromEntries(Object.entries(definition.fields).map(([key, held]) => [key, untitledFacts(held)])),
|
|
655
|
+
shape: {
|
|
656
|
+
schema: untitledSchema(definition.shape.schema),
|
|
657
|
+
defs: untitledMap(definition.shape.defs),
|
|
658
|
+
},
|
|
659
|
+
};
|
|
599
660
|
}
|
|
600
661
|
function deepFreeze(value) {
|
|
601
662
|
if (value !== null && typeof value === 'object' && !Object.isFrozen(value)) {
|
|
@@ -729,22 +790,16 @@ function readType(name, value, context) {
|
|
|
729
790
|
const at = `/${escapePointer(name)}`;
|
|
730
791
|
if (!isRecord(value))
|
|
731
792
|
return refuse('schema', at);
|
|
732
|
-
const {
|
|
793
|
+
const { member_document: mark, create_roles: createRoles, delete_roles: deleteRoles, indexed, ...ruled } = value;
|
|
733
794
|
if (mark !== undefined && typeof mark !== 'boolean')
|
|
734
795
|
return refuse('member_document', `${at}/member_document`);
|
|
735
796
|
if (createRoles !== undefined && !roleNames(createRoles))
|
|
736
797
|
return refuse('create_roles', `${at}/create_roles`);
|
|
737
798
|
if (deleteRoles !== undefined && !roleNames(deleteRoles))
|
|
738
799
|
return refuse('delete_roles', `${at}/delete_roles`);
|
|
739
|
-
|
|
740
|
-
|
|
741
|
-
|
|
742
|
-
if ('failure' in read)
|
|
743
|
-
return read.failure;
|
|
744
|
-
const unbranched = withoutBranchSections(ruled, declared, at);
|
|
745
|
-
if ('failure' in unbranched)
|
|
746
|
-
return unbranched.failure;
|
|
747
|
-
const { schema, written } = unruled(unbranched.schema);
|
|
800
|
+
if (indexed !== undefined && !strings(indexed))
|
|
801
|
+
return refuse('indexed', `${at}/indexed`);
|
|
802
|
+
const { schema, written } = unruled(ruled);
|
|
748
803
|
const failure = schemaFailure(schema, at, context);
|
|
749
804
|
if (failure !== undefined)
|
|
750
805
|
return failure;
|
|
@@ -764,16 +819,16 @@ function readType(name, value, context) {
|
|
|
764
819
|
fields[MEMBER_FIELD] = { type: 'string', prose: false };
|
|
765
820
|
const defs = Object.create(null);
|
|
766
821
|
reachedDefs(value, context.defs, defs);
|
|
767
|
-
const { create_roles: _create, delete_roles: _delete, ...shaped } = value;
|
|
822
|
+
const { create_roles: _create, delete_roles: _delete, indexed: _indexed, ...shaped } = value;
|
|
768
823
|
return {
|
|
769
824
|
name,
|
|
770
825
|
memberDocument,
|
|
771
|
-
|
|
826
|
+
root: { ...root, properties: { ...HOUSE_KEYS, ...fields } },
|
|
772
827
|
fields,
|
|
773
|
-
sections: read.sections,
|
|
774
828
|
rules,
|
|
775
829
|
...(createRoles === undefined ? {} : { createRoles }),
|
|
776
830
|
...(deleteRoles === undefined ? {} : { deleteRoles }),
|
|
831
|
+
...(indexed === undefined ? {} : { indexed }),
|
|
777
832
|
shape: {
|
|
778
833
|
schema: written.size === 0 ? shaped : { ...shaped, properties: schema.properties },
|
|
779
834
|
defs,
|
package/dist/document.d.ts
CHANGED
|
@@ -1,17 +1,23 @@
|
|
|
1
|
+
import { type Body, type Naming } from './body.js';
|
|
1
2
|
import { type Definition } from './definition.js';
|
|
2
|
-
import { type
|
|
3
|
-
import type { ApplyResult, BodyResult,
|
|
4
|
-
|
|
5
|
-
export declare function
|
|
6
|
-
export declare function
|
|
7
|
-
export declare function
|
|
3
|
+
import { type HrefOccurrence, type Reading } from './markdown.js';
|
|
4
|
+
import type { ApplyResult, BodyResult, Change, DefinitionOf, Document, Link, ParseResult, Refusal, Span, UnlinkedBody } from './types.js';
|
|
5
|
+
export declare function readingOf(document: Document): Reading;
|
|
6
|
+
export declare function bodyOf(document: Document): Body | null;
|
|
7
|
+
export declare function linkDestinations(document: Document): readonly HrefOccurrence[];
|
|
8
|
+
export declare function textSpans(document: Document): readonly Span[];
|
|
9
|
+
export declare function parse(content: string, file?: string, definition?: Definition | DefinitionOf): ParseResult;
|
|
10
|
+
export declare function create(type: string | undefined, definition?: Definition): Document;
|
|
8
11
|
export declare function relativize(document: Document, file: string, handle: string, definition?: Definition, kept?: ReadonlySet<string>): ApplyResult;
|
|
9
12
|
export declare function relativizeBody(body: string, file: string, handle: string): BodyResult;
|
|
10
13
|
export declare function relinkBody(body: string, file: string, moves: ReadonlyMap<string, string>): BodyResult;
|
|
11
14
|
export declare function unlinkBody(body: string, hrefs: ReadonlySet<string>): UnlinkedBody;
|
|
12
15
|
export declare function links(document: Document, file: string): readonly Link[];
|
|
13
16
|
export declare function bodyLinks(body: string, file: string): readonly Link[];
|
|
14
|
-
export declare function
|
|
17
|
+
export declare function bodyWith(document: Document, definition: Definition | undefined): Body | null | Refusal;
|
|
18
|
+
export declare function partText(part: string): string;
|
|
19
|
+
export declare function apply(document: Document, changes: readonly Change[], definition?: Definition, nameOf?: Naming): ApplyResult;
|
|
20
|
+
export declare function relabel(document: Document, before: Definition, after: Definition): string;
|
|
21
|
+
export declare function relabels(before: Definition, after: Definition): boolean;
|
|
15
22
|
export declare function serialize(document: Document): string;
|
|
16
|
-
export declare function frontmatter(document: Document): YamlMap | null;
|
|
17
23
|
//# sourceMappingURL=document.d.ts.map
|
package/dist/document.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"document.d.ts","sourceRoot":"","sources":["../src/document.ts"],"names":[],"mappings":"AAAA,OAAO,
|
|
1
|
+
{"version":3,"file":"document.d.ts","sourceRoot":"","sources":["../src/document.ts"],"names":[],"mappings":"AAAA,OAAO,EAUL,KAAK,IAAI,EACT,KAAK,MAAM,EAGZ,MAAM,WAAW,CAAC;AACnB,OAAO,EAKL,KAAK,UAAU,EAEhB,MAAM,iBAAiB,CAAC;AAGzB,OAAO,EASL,KAAK,cAAc,EACnB,KAAK,OAAO,EAEb,MAAM,eAAe,CAAC;AAevB,OAAO,KAAK,EACV,WAAW,EACX,UAAU,EACV,MAAM,EACN,YAAY,EACZ,QAAQ,EAER,IAAI,EACJ,WAAW,EACX,OAAO,EACP,IAAI,EACJ,YAAY,EACb,MAAM,YAAY,CAAC;AAoDpB,wBAAgB,SAAS,CAAC,QAAQ,EAAE,QAAQ,GAAG,OAAO,CAKrD;AAeD,wBAAgB,MAAM,CAAC,QAAQ,EAAE,QAAQ,GAAG,IAAI,GAAG,IAAI,CAGtD;AAED,wBAAgB,gBAAgB,CAAC,QAAQ,EAAE,QAAQ,GAAG,SAAS,cAAc,EAAE,CAQ9E;AAiCD,wBAAgB,SAAS,CAAC,QAAQ,EAAE,QAAQ,GAAG,SAAS,IAAI,EAAE,CAM7D;AA6FD,wBAAgB,KAAK,CACnB,OAAO,EAAE,MAAM,EACf,IAAI,SAAK,EACT,UAAU,CAAC,EAAE,UAAU,GAAG,YAAY,GACrC,WAAW,CA8Cb;AAED,wBAAgB,MAAM,CAAC,IAAI,EAAE,MAAM,GAAG,SAAS,EAAE,UAAU,CAAC,EAAE,UAAU,GAAG,QAAQ,CAQlF;AA2CD,wBAAgB,UAAU,CACxB,QAAQ,EAAE,QAAQ,EAClB,IAAI,EAAE,MAAM,EACZ,MAAM,EAAE,MAAM,EACd,UAAU,CAAC,EAAE,UAAU,EACvB,IAAI,GAAE,WAAW,CAAC,MAAM,CAA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