Skip to content

♻️ Move block lexicon defs to reusable namespace#48

Open
nokome wants to merge 5 commits intomainfrom
atproto-blocks-lexicon
Open

♻️ Move block lexicon defs to reusable namespace#48
nokome wants to merge 5 commits intomainfrom
atproto-blocks-lexicon

Conversation

@nokome
Copy link
Copy Markdown
Collaborator

@nokome nokome commented Mar 25, 2026

Place block type definitions in pub.oxa.blocks.defs and generate them at lexicon/blocks/defs.json instead of nesting them under the document lexicon. Update generated refs, conversion code, tests, docs, and examples to use the new block namespace.

This makes the block schema easier to reuse from other document lexicons rather than tying it to pub.oxa.document. For example, pub.oxa.blocks.defs#block can be referenced from an open content property in another record schema such as site.standard.document.

By moving blocks out of the document schema it also allows us to simplify the main document id from pub.oxa.document.document to pub.oxa.document

nokome added 2 commits March 25, 2026 20:17
Place block type definitions in `pub.oxa.blocks.defs` and generate them at `lexicon/blocks/defs.json` instead of nesting them under the document lexicon. Update generated refs, conversion code, tests, docs, and examples to use the new block namespace.\n\nThis makes the block schema easier to reuse from other document lexicons rather than tying it to `pub.oxa.document.document`. For example, `pub.oxa.blocks.defs#block` can be referenced from an open `content` property in another record schema such as `site.standard.document`.\n\nCo-authored-by: Stencila <47797644+stencila[bot]@users.noreply.github.com>
@nokome nokome requested a review from rowanc1 March 25, 2026 07:21
@changeset-bot
Copy link
Copy Markdown

changeset-bot bot commented Mar 25, 2026

⚠️ No Changeset found

Latest commit: 54ab91a

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Mar 25, 2026

Curvenote Preview

Directory Preview Checks Updated (UTC)
docs 🔍 Inspect 1 checks passed Mar 25, 2026, 8:58 PM

nokome and others added 2 commits March 26, 2026 08:55
Simplify the document record NSID from `pub.oxa.document.document` to
`pub.oxa.document`, consistent with the naming convention used by
`site.standard.document` and others. This is possible now that block
type definitions have been moved to their own `pub.oxa.blocks.defs`
namespace.

Co-authored-by: Stencila <47797644+stencila[bot]@users.noreply.github.com>
Copy link
Copy Markdown
Member

@rowanc1 rowanc1 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants