Skip to content

Commit

Permalink
Simpler try
Browse files Browse the repository at this point in the history
  • Loading branch information
john-science committed Jan 30, 2025
1 parent beb7f1d commit 8991109
Showing 1 changed file with 12 additions and 15 deletions.
27 changes: 12 additions & 15 deletions doc/.static/dochelpers.py
Original file line number Diff line number Diff line change
Expand Up @@ -142,15 +142,14 @@ def generateParamTable(klass, fwParams, app=None):
defs[plugin] = pDefs

headerContent = """
.. container:: break_before ssp-landscape
.. list-table:: {} Parameters from {{}}
:widths: 25 50 25
:class: ssp-tiny
:header-rows: 1
* - Name
- Description
- Units
.. list-table:: {} Parameters from {{}}
:class: ssp-tiny
:widths: 30 40 30
:header-rows: 1
* - Name
- Description
- Units
""".format(
klass.__name__
)
Expand All @@ -162,12 +161,10 @@ def generateParamTable(klass, fwParams, app=None):
content.append(f".. _{srcName}-{klass.__name__}-param-table:")
pluginContent = headerContent.format(srcName)
for pd in pdefs:
pluginContent += f" * - {pd.name}\n"
pluginContent += (
f" - {escapeSpecialCharacters(str(pd.description))}\n"
)
pluginContent += f" - {escapeSpecialCharacters(pd.units)}\n"

pluginContent += f""" * - {pd.name}
- {escapeSpecialCharacters(str(pd.description))}
- {escapeSpecialCharacters(pd.units)}
"""
content.append(pluginContent + "\n")

return "\n".join(content)

0 comments on commit 8991109

Please sign in to comment.