galb-dai commited on
Commit
61bdf51
·
1 Parent(s): 9aaf604

CSS fixes.

Browse files
Files changed (2) hide show
  1. app.py +3 -3
  2. src/display/css_html_js.py +6 -4
app.py CHANGED
@@ -228,7 +228,7 @@ with blocks:
228
 
229
  md_warmup = gr.Markdown(
230
  value=(
231
- '<p class="f1-problem-name"><code>Union-of-Paths-and-Cycles</code></p>\n'
232
  "Given a tree-like graph $G=(V,E)$ and a weight function $w:V\\to\\mathbb{N}$, compute the sum of all weights of sets $S\\subseteq V$ such that the induced subgraph $G[S]$ is a disjoint union of paths and cycles."
233
  ),
234
  latex_delimiters=_latex,
@@ -236,7 +236,7 @@ with blocks:
236
  )
237
  md_tier1 = gr.Markdown(
238
  value=(
239
- '<p class="f1-problem-name"><code>Maximal-Union-of-Paths-and-Cycles</code></p>\n'
240
  "Given a tree-like graph $G=(V,E)$ and a weight function $w:V\\to\\mathbb{N}$, compute the sum of all weights of sets $S\\subseteq V$ such that $G[S]$ is a disjoint union of paths and cycles and $S$ is maximal with respect to this property."
241
  ),
242
  visible=False,
@@ -245,7 +245,7 @@ with blocks:
245
  )
246
  md_tier2 = gr.Markdown(
247
  value=(
248
- '<p class="f1-problem-name"><code>Maximal-Union-of-Cycles</code></p>\n'
249
  "Given a tree-like graph $G=(V,E)$ and a weight function $w:V\\to\\mathbb{N}$, compute the sum of all weights of sets $S\\subseteq V$ such that $G[S]$ is a disjoint union of cycles and $S$ is maximal with respect to this property."
250
  ),
251
  visible=False,
 
228
 
229
  md_warmup = gr.Markdown(
230
  value=(
231
+ "<p><code>Union-of-Paths-and-Cycles</code></p>\n"
232
  "Given a tree-like graph $G=(V,E)$ and a weight function $w:V\\to\\mathbb{N}$, compute the sum of all weights of sets $S\\subseteq V$ such that the induced subgraph $G[S]$ is a disjoint union of paths and cycles."
233
  ),
234
  latex_delimiters=_latex,
 
236
  )
237
  md_tier1 = gr.Markdown(
238
  value=(
239
+ "<p><code>Maximal-Union-of-Paths-and-Cycles</code></p>\n"
240
  "Given a tree-like graph $G=(V,E)$ and a weight function $w:V\\to\\mathbb{N}$, compute the sum of all weights of sets $S\\subseteq V$ such that $G[S]$ is a disjoint union of paths and cycles and $S$ is maximal with respect to this property."
241
  ),
242
  visible=False,
 
245
  )
246
  md_tier2 = gr.Markdown(
247
  value=(
248
+ "<p><code>Maximal-Union-of-Cycles</code></p>\n"
249
  "Given a tree-like graph $G=(V,E)$ and a weight function $w:V\\to\\mathbb{N}$, compute the sum of all weights of sets $S\\subseteq V$ such that $G[S]$ is a disjoint union of cycles and $S$ is maximal with respect to this property."
250
  ),
251
  visible=False,
src/display/css_html_js.py CHANGED
@@ -33,13 +33,15 @@ custom_css = """
33
  .f1-figcaption-video { margin-top: 6px; } /* a bit tighter under the video */
34
 
35
  /* Problem name — force center from first render; code bg color #f9fafb */
36
- .f1-problem-markdown p.f1-problem-name,
37
- #f1-examples .f1-problem-markdown .markdown p.f1-problem-name { text-align: center !important; margin: 0 0 8px 0; }
38
- .f1-problem-markdown p.f1-problem-name code,
39
- #f1-examples .f1-problem-markdown .markdown p.f1-problem-name code {
40
  display: inline-block; background: #f9fafb !important; padding: 2px 8px; border-radius: 6px;
41
  }
42
 
 
 
43
  /* Problem body: padding + line-height inside Markdown + small space before tabs */
44
  #f1-examples .f1-problem-markdown .markdown { background: var(--f1-bg-muted); border: 1px solid var(--f1-border); border-radius: 8px; padding: 18px; margin: 10px 14px 10px 14px; line-height: 1.75; }
45
  #f1-examples .f1-problem-markdown .markdown p { margin: 0.35rem 0; }
 
33
  .f1-figcaption-video { margin-top: 6px; } /* a bit tighter under the video */
34
 
35
  /* Problem name — force center from first render; code bg color #f9fafb */
36
+ .f1-problem-markdown > *,
37
+ #f1-examples .f1-problem-markdown .markdown p { text-align: center !important; margin: 0 0 8px 0; }
38
+ .f1-problem-markdown p code,
39
+ #f1-examples .f1-problem-markdown .markdown p code {
40
  display: inline-block; background: #f9fafb !important; padding: 2px 8px; border-radius: 6px;
41
  }
42
 
43
+ .f1-problem-markdown > * { margin-top: 7px; margin-bottom: 7px; }
44
+
45
  /* Problem body: padding + line-height inside Markdown + small space before tabs */
46
  #f1-examples .f1-problem-markdown .markdown { background: var(--f1-bg-muted); border: 1px solid var(--f1-border); border-radius: 8px; padding: 18px; margin: 10px 14px 10px 14px; line-height: 1.75; }
47
  #f1-examples .f1-problem-markdown .markdown p { margin: 0.35rem 0; }