Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
rowanc1 authored Aug 31, 2024
1 parent ed5a7f6 commit 844dbe3
Show file tree
Hide file tree
Showing 11 changed files with 383 additions and 376 deletions.
12 changes: 12 additions & 0 deletions .changeset/mighty-chefs-complain.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
---
'myst-to-react': patch
'myst-demo': patch
'@myst-theme/providers': patch
'@myst-theme/jupyter': patch
'@myst-theme/common': patch
'@myst-theme/article': patch
'@myst-theme/site': patch
'@myst-theme/book': patch
---

Updates to myst
685 changes: 340 additions & 345 deletions package-lock.json

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions packages/common/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,9 +19,9 @@
"build": "npm-run-all -l clean -p build:esm"
},
"dependencies": {
"myst-common": "^1.5.0",
"myst-common": "^1.6.0",
"myst-config": "^1.5.0",
"myst-spec-ext": "^1.5.0",
"myst-spec-ext": "^1.6.0",
"nbtx": "^0.2.3",
"unist-util-select": "^4.0.3"
}
Expand Down
6 changes: 3 additions & 3 deletions packages/jupyter/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -30,11 +30,11 @@
"buffer": "^6.0.3",
"classnames": "^2.3.2",
"jupyterlab-plotly": "^5.18.0",
"myst-common": "^1.5.0",
"myst-common": "^1.6.0",
"myst-config": "^1.5.0",
"myst-frontmatter": "^1.5.0",
"myst-frontmatter": "^1.6.0",
"myst-spec": "^0.0.5",
"myst-spec-ext": "^1.5.0",
"myst-spec-ext": "^1.6.0",
"myst-to-react": "^0.10.0",
"nanoid": "^4.0.2",
"nbtx": "^0.2.3",
Expand Down
28 changes: 14 additions & 14 deletions packages/myst-demo/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,24 +23,24 @@
"@heroicons/react": "^2.0.18",
"classnames": "^2.3.2",
"js-yaml": "^4.1.0",
"myst-common": "^1.5.0",
"myst-common": "^1.6.0",
"myst-config": "^1.5.0",
"myst-directives": "^1.5.0",
"myst-ext-card": "^1.0.6",
"myst-ext-exercise": "^1.0.6",
"myst-ext-grid": "^1.0.6",
"myst-ext-proof": "^1.0.9",
"myst-ext-tabs": "^1.0.6",
"myst-directives": "^1.5.5",
"myst-ext-card": "^1.0.7",
"myst-ext-exercise": "^1.0.7",
"myst-ext-grid": "^1.0.7",
"myst-ext-proof": "^1.0.10",
"myst-ext-tabs": "^1.0.7",
"myst-frontmatter": "^1.5.0",
"myst-parser": "^1.5.0",
"myst-parser": "^1.5.5",
"myst-spec": "^0.0.5",
"myst-to-docx": "^1.0.10",
"myst-to-html": "^1.5.0",
"myst-to-jats": "^1.0.26",
"myst-to-docx": "^1.0.11",
"myst-to-html": "^1.5.5",
"myst-to-jats": "^1.0.27",
"myst-to-react": "^0.10.0",
"myst-to-tex": "^1.0.30",
"myst-to-typst": "^0.0.17",
"myst-transforms": "^1.3.19",
"myst-to-tex": "^1.0.35",
"myst-to-typst": "^0.0.21",
"myst-transforms": "^1.3.24",
"unified": "^10.1.2",
"unist-util-remove": "^4.0.0",
"unist-util-visit": "^4.1.2",
Expand Down
2 changes: 1 addition & 1 deletion packages/myst-to-react/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
"@radix-ui/react-hover-card": "^1.0.6",
"buffer": "^6.0.3",
"classnames": "^2.3.2",
"myst-common": "^1.5.0",
"myst-common": "^1.6.0",
"myst-config": "^1.5.0",
"myst-spec": "^0.0.5",
"nanoid": "^4.0.2",
Expand Down
4 changes: 2 additions & 2 deletions packages/myst-to-react/src/MyST.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,10 @@ function DefaultComponent({ node }: { node: GenericNode }) {

export function selectRenderer(renderers: NodeRenderersValidated, node: GenericNode) {
const componentRenderers = renderers[node.type] ?? renderers['DefaultComponent'];
const SpecificComponent = Object.entries(componentRenderers)
const SpecificComponent = Object.entries(componentRenderers ?? {})
.reverse()
.find(([selector]) => selector !== 'base' && matches(selector, node))?.[1];
return SpecificComponent ?? componentRenderers.base ?? DefaultComponent;
return SpecificComponent ?? componentRenderers?.base ?? DefaultComponent;
}

export function MyST({ ast }: { ast?: GenericNode | GenericNode[] }) {
Expand Down
6 changes: 3 additions & 3 deletions packages/providers/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,9 +27,9 @@
"peerDependencies": {
"@types/react": "^16.8 || ^17.0 || ^18.0",
"@types/react-dom": "^16.8 || ^17.0 || ^18.0",
"myst-common": "^1.5.0",
"myst-config": "^1.5.0",
"myst-frontmatter": "^1.5.0",
"myst-common": "^1.6.0",
"myst-config": "^1.6.0",
"myst-frontmatter": "^1.6.0",
"react": "^16.8 || ^17.0 || ^18.0",
"react-dom": "^16.8 || ^17.0 || ^18.0"
},
Expand Down
6 changes: 3 additions & 3 deletions packages/site/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,10 +29,10 @@
"@radix-ui/react-collapsible": "^1.0.3",
"classnames": "^2.3.2",
"lodash.throttle": "^4.1.1",
"myst-common": "^1.5.0",
"myst-config": "^1.5.0",
"myst-common": "^1.6.0",
"myst-config": "^1.6.0",
"myst-demo": "^0.10.0",
"myst-spec-ext": "^1.5.0",
"myst-spec-ext": "^1.6.0",
"myst-to-react": "^0.10.0",
"nbtx": "^0.2.3",
"node-cache": "^5.1.2",
Expand Down
2 changes: 1 addition & 1 deletion themes/article/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
"@remix-run/node": "~1.17.0",
"@remix-run/react": "~1.17.0",
"@remix-run/vercel": "~1.17.0",
"myst-common": "^1.5.0",
"myst-common": "^1.6.0",
"myst-config": "^1.5.0",
"node-fetch": "^2.6.11",
"react": "^18.2.0",
Expand Down
4 changes: 2 additions & 2 deletions themes/book/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,8 @@
"@remix-run/node": "~1.17.0",
"@remix-run/react": "~1.17.0",
"@remix-run/vercel": "~1.17.0",
"myst-common": "^1.5.0",
"myst-config": "^1.5.0",
"myst-common": "^1.6.0",
"myst-config": "^1.6.0",
"node-fetch": "^2.6.11",
"react": "^18.2.0",
"react-dom": "^18.2.0"
Expand Down

0 comments on commit 844dbe3

Please sign in to comment.