Răsfoiți Sursa

make <em> italics in the documentation

Rodja Trappe 1 an în urmă
părinte
comite
d2b5e02275
3 a modificat fișierele cu 7 adăugiri și 3 ștergeri
  1. 1 1
      website/documentation/rendering.py
  2. 5 1
      website/static/style.css
  3. 1 1
      website/style.py

+ 1 - 1
website/documentation/rendering.py

@@ -30,7 +30,7 @@ def render_page(documentation: DocumentationPage, *, with_menu: bool = True) ->
             ui.markdown(f'**{documentation.heading.replace("*", "")}**').classes('mt-4')
 
     # content
-    with ui.column().classes('w-full p-8 lg:p-16 max-w-[1250px] mx-auto'):
+    with ui.column().classes('w-full p-8 lg:p-16 max-w-[1250px] mx-auto documentation'):
 
         # heading
         section_heading(documentation.subtitle or '', documentation.heading)

+ 5 - 1
website/static/style.css

@@ -20,7 +20,11 @@ html:not(.has-dialog) {
   font-family: "Fira Mono", ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New",
     monospace;
 }
-em:not(.browser-window *) {
+em:not(.browser-window *):not(.documentation *) {
+  font-style: normal;
+  color: #5898d4;
+}
+.documentation .title em {
   font-style: normal;
   color: #5898d4;
 }

+ 1 - 1
website/style.py

@@ -19,7 +19,7 @@ def link_target(name: str, offset: str = '0') -> ui.link_target:
 def section_heading(subtitle_: str, title_: str) -> None:
     """Render a section heading with a subtitle."""
     ui.label(subtitle_).classes('md:text-lg font-bold')
-    ui.markdown(title_).classes('text-3xl md:text-5xl font-medium mt-[-12px]')
+    ui.markdown(title_).classes('text-3xl md:text-5xl font-medium mt-[-12px] title')
 
 
 def heading(title_: str) -> ui.markdown: