feature: add filters for providers and font subsets
Some checks failed
Lint / Lint Code (push) Has been cancelled
Test / Svelte Checks (push) Has been cancelled

This commit is contained in:
Ilia Mashkov
2026-01-02 20:06:35 +03:00
parent 949c7c1b48
commit ff665e1d26
7 changed files with 106 additions and 61 deletions

View File

@@ -5,73 +5,12 @@ import type { Category } from '$shared/store/createFilterStore';
*/
export type FontCategory = 'sans-serif' | 'serif' | 'display' | 'handwriting' | 'monospace';
export const FONT_CATEGORIES: Category[] = [
{
id: 'sans-serif',
name: 'Sans-serif',
},
{
id: 'serif',
name: 'Serif',
},
{
id: 'display',
name: 'Display',
},
{
id: 'handwriting',
name: 'Handwriting',
},
{
id: 'monospace',
name: 'Monospace',
},
] as const;
/**
* Font provider
*/
export type FontProvider = 'google' | 'fontshare';
export const FONT_PROVIDERS: Category[] = [
{
id: 'google',
name: 'Google Fonts',
},
{
id: 'fontshare',
name: 'Fontshare',
},
] as const;
/**
* Font subset
*/
export type FontSubset = 'latin' | 'latin-ext' | 'cyrillic' | 'greek' | 'arabic' | 'devanagari';
export const FONT_SUBSETS: Category[] = [
{
id: 'latin',
name: 'Latin',
},
{
id: 'latin-ext',
name: 'Latin Extended',
},
{
id: 'cyrillic',
name: 'Cyrillic',
},
{
id: 'greek',
name: 'Greek',
},
{
id: 'arabic',
name: 'Arabic',
},
{
id: 'devanagari',
name: 'Devanagari',
},
] as const;