Repository navigation
Conversation
c5b1061 to
b729b82
Compare
|
Hello! I believe that I am ready for the workflows to be run and for a review. :) I successfully ran the linter, unit tests, and documentation locally. However, I am sure that I made a mistake somewhere as this is my first contribution. I don't understand how the Also, are you happy with the referencing of the terms? Here is an example of what it looks like: The source to produce this is: |
| patch = publish_msgstr(self.app, parts[0], source, | ||
| node.line, self.config, settings) | ||
| patch = make_glossary_term(self.env, patch, parts[1], | ||
| patch = make_glossary_term(self.env, patch, '', parts[1], |
|
Hello @AA-Turner, gentle ping. I noticed that you have been making most of the merges recently, and I was wondering if I could get approval for running the workflows and a review? 🙏 Thanks! |
|
Hello @AA-Turner, gentle ping. Would I be able to get some feedback on these changes? 🙏 Thanks! |
|
I can review the change, but I want to review the discussion on the overall design first. A |
| The whole characters in "key" is used instead of a first character; it is | ||
| used for "Combining Character Sequence" and "Surrogate Pairs" grouping key. | ||
|
|
||
| If you want to specify a "glossary key" to make glossaries unique even if |
There was a problem hiding this comment.
I feel "key" is a bit functional wording. It would be better to use more semantic words (ex. classifier, category, glossary type, and so on).
In my understanding, this PR improves Sphinx to be able to have multiple "kinds" of glossaries. So this document should describe the design as possible. It's an advantage of multiple glossaries. But it's not a main goal.
There was a problem hiding this comment.
Thanks for the review! 🙏
I will change the term "key" to "classifier", and improve the document.
|
|
||
| std = cast(StandardDomain, env.get_domain('std')) | ||
| std._note_term(termtext, node_id, location=term) | ||
| std._note_term(term_reference, node_id, location=term) |
There was a problem hiding this comment.
It's better to separate the glossary key and term in the domain database. It might cause conflict with a term having colon and a term having a key. No reason to store them in concatenated form.
.. glossary::
key:term
.. glossary:: key
term
There was a problem hiding this comment.
I don't exactly understand what you mean, could you please clarify? I am confused by the code block that you added, and why you don't want them to be stored in concatenated form.
What I am understanding is you would like me to do the following:
std._note_term(termtext, node_id, location=term)where
termtext = "Term1"| # add an index entry too | ||
| indexnode = addnodes.index() | ||
| indexnode['entries'] = [('single', termtext, node_id, 'main', index_key)] | ||
| indexnode['entries'] = [('single', term_reference, node_id, 'main', index_key)] |
There was a problem hiding this comment.
Do you check how a term having a key is shown on the index? Is it better to prepend the key here?
| required_arguments = 0 | ||
| optional_arguments = 0 | ||
| optional_arguments = 1 | ||
| final_argument_whitespace = False |
There was a problem hiding this comment.
Enabling this allows users to use phrases to glossary key.
.. glossary:: document writing
There was a problem hiding this comment.
@tk0miya What do you suggest I do here?
Should I allow this behavior?
Or, check for spaces, and if there are spaces, throw an error?
|
I think a title of reference and an index entry should be bare "Term1". |
|
Here is a summary of my opinion.
In the index, for example, or pair style as: |
|
Thanks for the feedback @tk0miya @shimizukawa I would like to summarize the requested changes before I make them:
Thanks again for your feedback, I greatly appreciate it. |
Whenever you say "title of reference" do you mean when you do Alternatively, are you okay with it being rendered as "page2:Term2" by default and require the user to do |
IMO the pair style would be perfect. This would also generate these entries: But I would like to be able to translate |
I'd also like to voice support for "Term2" by default instead of "page2:Term2". My usecase is building documentation for several teams working in the same monorepo. Some terms are used differently by different teams. If terms were rendered with category prefixes by default, it means we'd always have to override the reference text. |





Feature or Bugfix
Purpose
Detail
Relates