-
Notifications
You must be signed in to change notification settings - Fork 60
Highlight unique components of overloaded declarations [alternate approach] #847
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Highlight unique components of overloaded declarations [alternate approach] #847
Conversation
…nents-of-overloaded-declarations
…nents-of-overloaded-declarations
…nents-of-overloaded-declarations
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The implementation here looks cleaner than in #841 in my opinion, but both are great.
I tested this one too and it works as expected.
I left a minor suggestion.
Thanks!
src/components/DocumentationTopic/PrimaryContent/DeclarationSource.vue
Outdated
Show resolved
Hide resolved
Dang, this does look a lot nicer than the |
|
||
<script> | ||
// This component is an optimization that allows us to emit raw text DOM nodes |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
RIP 🥲
@swift-ci test |
@mportiz08 I've merged swiftlang/swift-docc#928 with the |
Sorry yes. We are anticipating needing to update this PR due to major refactoring of declaration components as part of #832 . I was hoping we could sync this change across both repos at the same time, but we can prioritize updating this PR now to try and avoid issues now that it has been merged in DocC. |
@mportiz08 FYI I'm working on resolving conflicts. |
Replacing this PR with #875 |
This implements the same rendering of highlighted tokens as #841 but using an alternate Render JSON schema where each token may possibly have a
highlightDiff
boolean flag instead of introducing a new token kind to represent highlights.I'm not sure yet which approach the DocC team is going to decide on yet, so I'm opening a draft PR for both options and will close one depending on what they decide on.
Testing
Same instructions as #841 except make sure to use the older commit
33388c3c7987904e0aec58e4035fea14bcd19965
from the swift-docc branch when building DocC instead of the latest commit from the mentioned branch.