Skip to content
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

Cantera 3.0 website string rendering #1576

Closed
ischoegl opened this issue Aug 9, 2023 · 7 comments · Fixed by #1582
Closed

Cantera 3.0 website string rendering #1576

ischoegl opened this issue Aug 9, 2023 · 7 comments · Fixed by #1582

Comments

@ischoegl
Copy link
Member

ischoegl commented Aug 9, 2023

There are a couple of instances where string-entries that link to further documentation should have typewriter font.

As an example, for the YAML reference for the Phase->transport entry, 'none', 'high-pressure', and similar entries should be clearly identified as string with typewriter font (whether or not to use quotes is debatable).

image

The same applies to Phase->thermo, Phase->kinetics, SpeciesThermo->model, Reactions->type, and potentially a couple of others. Edit: One more here.

@ischoegl ischoegl transferred this issue from Cantera/cantera-website Aug 9, 2023
@bryanwweber
Copy link
Member

I haven't looked, but this is probably an unfortunately limitation of rST link formatting, which doesn't allow text formatting inside the link. See https://docutils.sourceforge.io/FAQ.html#is-nested-inline-markup-possible

@ischoegl
Copy link
Member Author

ischoegl commented Aug 9, 2023

I haven't looked, but this is probably an unfortunately limitation of rST link formatting, which doesn't allow text formatting inside the link. See https://docutils.sourceforge.io/FAQ.html#is-nested-inline-markup-possible

Interesting. When I ran into a similar issue in #1548, I was able to resolve it by placing everything in HTML <tt> ... </tt>. brackets. I had assumed this to be a quirk of the doxygen markdown flavor, but may be wrong ...

@bryanwweber
Copy link
Member

Markdown in general shouldn't have a problem with nested markup (although it may depend on the parser). For example, GitHub comment boxes allow nested markup: a tt link which is generated with

[`a tt link`](https://github.com/cantera)

I believe this is specifically a limitation of reST, as this file is written in rST: https://github.com/Cantera/cantera/blob/main/doc/sphinx/yaml/phases.rst

@bryanwweber
Copy link
Member

@ischoegl Should we close this issue as this is not fixable except by switching to an alternative markup format/parser?

@ischoegl
Copy link
Member Author

ischoegl commented Aug 9, 2023

@ischoegl Should we close this issue as this is not fixable except by switching to an alternative markup format/parser?

Does wrapping this as

<tt> [some_description](https://github.com/cantera) </tt>

work? (this was the solution in #1548, although the mechanism doxygen uses to generate links is very different)

@bryanwweber
Copy link
Member

No, because the file is reST not markdown.

@ischoegl
Copy link
Member Author

ischoegl commented Aug 9, 2023

No, because the file is reST not markdown.

Ugh ... reST, of course. I really don't like this format.

About closing this issue, I don't think that it should be closed. Unless you read the text carefully, the listed items look like links and don't indicate that these are the actual strings to be used in these instances. Perhaps the solution is to type the model name without the link, and provide the link next to it?

Edit: but it's ok to defer ... moved this to 'triage'

@ischoegl ischoegl moved this from Todo to Triage in Cantera 3.0 Release Planning Aug 9, 2023
@ischoegl ischoegl moved this from Triage to In Progress in Cantera 3.0 Release Planning Aug 11, 2023
@github-project-automation github-project-automation bot moved this from In Progress to Done in Cantera 3.0 Release Planning Aug 13, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
No open projects
Development

Successfully merging a pull request may close this issue.

2 participants