-
Notifications
You must be signed in to change notification settings - Fork 64
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
🔗 Enable external MyST project cross-references (#1180)
* 🚨 Warn on duplicate identifiers across project pages * 🔧 Write myst.xref.json file to site * 🔧 Improve frontmatter reference validation * 🦋 Change loadIntersphinx -> loadReferences and include MyST xrefs * 🔧 Add kind and /content to myst.xref.json * 🔧 Old MystTransformer -> SphinxTransformer with some additional deprecation warnings * 🔗 Add link transform for myst xrefs * 🔗 Split out function for getting link text from target node * 🔗 Add transform to add link text from myst xrefs * 🔗 Add identifiers for page slugs to myst xrefs * 🏷 Alias name/label in project/page frontmatter and respect as identifiers * 🔗 Add check for empty link text * 🔧 Remove reserved reference keys, add regex * 🔧 Only allow label in page frontmatter, not project * 🔗 Update xref link transformer for <xref:id/path#target> format * 📚 Update docs for myst xrefs * 🔗 Fill enumerator strings for external project xrefs * 🐛 Ignore unwanted identifier nodes in myst xref transform --------- Co-authored-by: Rowan Cockett <rowanc1@gmail.com> Co-authored-by: Chris Holdgraf <choldgraf@berkeley.edu>
- Loading branch information
1 parent
7a04910
commit ab863c8
Showing
55 changed files
with
1,604 additions
and
283 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
--- | ||
'myst-transforms': patch | ||
'myst-cli': patch | ||
--- | ||
|
||
Change loadIntersphinx -> loadReferences and include MyST xrefs |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
--- | ||
'myst-frontmatter': patch | ||
'myst-cli': patch | ||
--- | ||
|
||
Alias name/label in prjoect/page frontmatter and respect as identifiers |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
'myst-transforms': patch | ||
--- | ||
|
||
Split out function for getting link text from target node |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
'myst-cli': patch | ||
--- | ||
|
||
Write myst.xref.json file to site |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
"myst-spec-ext": patch | ||
--- | ||
|
||
Add CrossReference |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
'myst-cli': patch | ||
--- | ||
|
||
Fill enumerator strings for external project xrefs |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
'myst-cli': patch | ||
--- | ||
|
||
Add transform to add link text from myst xrefs |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
--- | ||
'myst-transforms': patch | ||
'myst-cli': patch | ||
--- | ||
|
||
Warn on duplicate identifiers across project pages |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
--- | ||
'myst-transforms': patch | ||
'myst-common': patch | ||
'myst-cli': patch | ||
--- | ||
|
||
Add check for empty link text |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
"myst-cli": patch | ||
--- | ||
|
||
Do not build pages that do not exist for static html export |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
'myst-frontmatter': patch | ||
--- | ||
|
||
Improve frontmatter reference validation |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
'myst-transforms': patch | ||
--- | ||
|
||
Add link transform for myst xrefs |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.