-
-
Notifications
You must be signed in to change notification settings - Fork 60
add descriptions from spec #416
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
Open
FelixBenning
wants to merge
2
commits into
citation-style-language:master
Choose a base branch
from
FelixBenning:descriptions
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
2 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or 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
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
Thanks for doing this; we intended to, but just hadn't figured the best approach.
The only obvious question I have is why some properties have "descriptions", some "titles" and others both?
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.
Both are used for tooltips. If I remember correctly (haven't worked with json schemas for some time) vscode displays the title above the description on hover if both are there. And one or the other are displayed if only one of them are there. So in some sense they are equivalent. So I tried to use "title" for short "titley" descriptions like DOI, "Digital Object Identifier". And use "description" for longer descriptions. But there is no system behind it just rule of thumb. Basically took 10-20 min to throw as many descriptions into the file as I could find in that time. It won't be complete either. But I did not want to spend too much time before getting a reaction about it.
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.
Later on I started to split the description into a more punchy title and the remaining description. But not from the start so that is why that only happens sometimes
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 order in the documentation is not the same as in the schema, so it was sometimes hard to match the stuff. Ideally you would generate one from the other. Probably the docs from the json schema, since it is easier to read json programmatically
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.
Here's from the json schema docs:
On this:
Yes, this is what I was alluding to above on the "best approach."
But it's even more complicated, given the overlap with the csl style schema variables.
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.
As I've been using VSCode completion as part of #420 ...
Not from what I can see. It seems if a description is present, it uses that, even if there's a title.
But I can certainly imagine both being useful; for example, a title could be used to extract human-readable documentation. Or some editors might use both?