fix: storybook font rendering and shared fonts module #1

Merged
ilia merged 74 commits from feat/portfolio-setup into main 2026-05-18 18:45:22 +00:00
4 changed files with 5 additions and 12 deletions
Showing only changes of commit e8bf8b502e - Show all commits
-4
View File
@@ -12,10 +12,6 @@ export type SectionRecord = BaseRecord & {
* Display name of the section * Display name of the section
*/ */
title: string; title: string;
/**
* Visual numbering prefix (e.g., "01")
*/
number: string;
/** /**
* Sorting weight for section order * Sorting weight for section order
*/ */
+1 -4
View File
@@ -26,12 +26,9 @@ export type BaseRecord = {
/** /**
* PocketBase collection for simple text blocks (Intro, Bio). * PocketBase collection for simple text blocks (Intro, Bio).
* Each collection is named after its section — no slug field.
*/ */
export type PageContentRecord = BaseRecord & { export type PageContentRecord = BaseRecord & {
/**
* Slug corresponding to the parent section
*/
slug: string;
/** /**
* HTML or Markdown content string * HTML or Markdown content string
*/ */
@@ -5,9 +5,9 @@ import { SectionsAccordion } from './SectionsAccordion';
const baseRecord = { collectionId: 'c1', collectionName: 'sections', created: '', updated: '' }; const baseRecord = { collectionId: 'c1', collectionName: 'sections', created: '', updated: '' };
const sections: SectionRecord[] = [ const sections: SectionRecord[] = [
{ ...baseRecord, id: '1', slug: 'intro', title: 'Intro', number: '01', order: 1 }, { ...baseRecord, id: '1', slug: 'intro', title: 'Intro', order: 1 },
{ ...baseRecord, id: '2', slug: 'bio', title: 'Bio', number: '02', order: 2 }, { ...baseRecord, id: '2', slug: 'bio', title: 'Bio', order: 2 },
{ ...baseRecord, id: '3', slug: 'skills', title: 'Skills', number: '03', order: 3 }, { ...baseRecord, id: '3', slug: 'skills', title: 'Skills', order: 3 },
]; ];
describe('SectionsAccordion', () => { describe('SectionsAccordion', () => {
@@ -33,7 +33,7 @@ export function SectionsAccordion({ sections, activeSlug, children }: Props) {
<SectionAccordion <SectionAccordion
key={section.slug} key={section.slug}
id={section.slug} id={section.slug}
number={section.number} number={String(section.order).padStart(2, '0')}
title={section.title} title={section.title}
isActive={activeSlug === section.slug} isActive={activeSlug === section.slug}
href={`/${section.slug}`} href={`/${section.slug}`}