Skip to content

Commit

Permalink
fix: restore hidden node handling
Browse files Browse the repository at this point in the history
  • Loading branch information
agoose77 committed Jan 14, 2025
1 parent 5f58972 commit b257932
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions packages/myst-cli/src/transforms/outputs.ts
Original file line number Diff line number Diff line change
Expand Up @@ -261,6 +261,11 @@ export function reduceOutputs(
const outputs = outputsNode.children as GenericNode[];

outputs.forEach((outputNode) => {
if (outputNode.visibility === 'remove' || outputNode.visibility === 'hide') {
// Hidden nodes should not show up in simplified outputs for static export
outputNode.type = '__delete__';
return;
}
// TODO: output-refactoring -- drop to single output in future
if (!outputNode.jupyter_data && !outputNode.children?.length) {
outputNode.type = '__delete__';
Expand Down

0 comments on commit b257932

Please sign in to comment.