Skip to content

Commit

Permalink
doc: boards: exensions: add board name to side box
Browse files Browse the repository at this point in the history
This adds the board name (displayed as a code literal) to the "Wikipedia
card" for quick reference.

Fixes #81652.

Signed-off-by: Benjamin Cabé <[email protected]>
  • Loading branch information
kartben committed Nov 22, 2024
1 parent da713a2 commit baba3ad
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion doc/_extensions/zephyr/domain/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -253,6 +253,7 @@ def convert_node(self, node):
sidebar += field_list

details = [
("Name", nodes.literal(text=node["id"])),
("Vendor", node["vendor"]),
("Architecture", ", ".join(node["archs"])),
("SoC", ", ".join(node["socs"])),
Expand All @@ -262,7 +263,10 @@ def convert_node(self, node):
field = nodes.field()
field_name = nodes.field_name(text=property_name)
field_body = nodes.field_body()
field_body += nodes.paragraph(text=value)
if isinstance(value, nodes.Node):
field_body += value
else:
field_body += nodes.paragraph(text=value)
field += field_name
field += field_body
field_list += field
Expand Down

0 comments on commit baba3ad

Please sign in to comment.