staticdash 2025.25__tar.gz → 2025.27__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: staticdash
3
- Version: 2025.25
3
+ Version: 2025.27
4
4
  Summary: A lightweight static HTML dashboard generator with Plotly and pandas support.
5
5
  Author-email: Brian Day <brian.day1@gmail.com>
6
6
  License: CC0-1.0
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
4
4
 
5
5
  [project]
6
6
  name = "staticdash"
7
- version = "2025.25"
7
+ version = "2025.27"
8
8
  description = "A lightweight static HTML dashboard generator with Plotly and pandas support."
9
9
  authors = [
10
10
  { name = "Brian Day", email = "brian.day1@gmail.com" }
@@ -533,13 +533,18 @@ class Dashboard:
533
533
  story.append(PageBreak())
534
534
 
535
535
  def render_page(page, level=0, sec_prefix=[]):
536
+ # Generate section numbering like "1", "1.2", etc.
537
+ section_number = ".".join(map(str, sec_prefix))
538
+ heading_text = f"{section_number} {page.title}"
539
+
536
540
  heading_style = styles.get(f'Heading{min(level + 1, 4)}', styles['Heading4'])
541
+ story.append(Paragraph(heading_text, heading_style))
542
+ story.append(Spacer(1, 12))
543
+
537
544
 
538
545
  # Remember where we started
539
546
  content_start = len(story)
540
547
 
541
- story.append(Paragraph(page.title, heading_style))
542
- story.append(Spacer(1, 12))
543
548
 
544
549
  for kind, content, _ in page.elements:
545
550
  try:
@@ -582,9 +587,9 @@ class Dashboard:
582
587
  fig = content
583
588
  buf = io.BytesIO()
584
589
  if hasattr(fig, "savefig"):
585
- fig.savefig(buf, format="png", bbox_inches="tight", dpi=300)
590
+ fig.savefig(buf, format="png", bbox_inches="tight", dpi=600)
586
591
  else:
587
- fig.write_image(buf, format="png", width=600, height=360, scale=2)
592
+ fig.write_image(buf, format="png", width=800, height=600, scale=3)
588
593
  buf.seek(0)
589
594
  story.append(Image(buf, width=6 * inch, height=4.5 * inch))
590
595
  story.append(Spacer(1, 12))
@@ -631,8 +636,8 @@ class Dashboard:
631
636
 
632
637
 
633
638
 
634
- for page in self.pages:
635
- render_page(page)
639
+ for i, page in enumerate(self.pages):
640
+ render_page(page, level=0, sec_prefix=[i + 1])
636
641
 
637
642
 
638
643
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: staticdash
3
- Version: 2025.25
3
+ Version: 2025.27
4
4
  Summary: A lightweight static HTML dashboard generator with Plotly and pandas support.
5
5
  Author-email: Brian Day <brian.day1@gmail.com>
6
6
  License: CC0-1.0
File without changes
File without changes