@sypnia/ui 0.1.0 → 0.2.1

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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sypnia/ui",
3
- "version": "0.1.0",
3
+ "version": "0.2.1",
4
4
  "description": "The component library of Sypnia: tokens, CSS, React and Astro components.",
5
5
  "license": "MIT",
6
6
  "homepage": "https://ui.sypnia.com",
@@ -28,6 +28,7 @@
28
28
  "icons/sprite.svg",
29
29
  "tokens/tokens.json",
30
30
  "src/icons/data.ts",
31
+ "src/icons/brands.ts",
31
32
  "src/i18n/index.ts",
32
33
  "src/characters",
33
34
  "src/dom/search.ts",
@@ -41,6 +42,10 @@
41
42
  "types": "./dist/react/index.d.ts",
42
43
  "import": "./dist/react/index.js"
43
44
  },
45
+ "./react/code-editor": {
46
+ "types": "./dist/react/code-editor.d.ts",
47
+ "import": "./dist/react/code-editor.js"
48
+ },
44
49
  "./dom": {
45
50
  "types": "./dist/dom/index.d.ts",
46
51
  "import": "./dist/dom/index.js"
@@ -87,7 +92,14 @@
87
92
  }
88
93
  },
89
94
  "dependencies": {
95
+ "@codemirror/autocomplete": "^6.18.3",
96
+ "@codemirror/commands": "^6.7.1",
97
+ "@codemirror/lang-sql": "^6.8.0",
98
+ "@codemirror/language": "^6.10.6",
99
+ "@codemirror/state": "^6.4.1",
100
+ "@codemirror/view": "^6.35.0",
90
101
  "@internationalized/date": "^3.12.4",
102
+ "@lezer/highlight": "^1.2.1",
91
103
  "@tanstack/react-virtual": "^3.14.26",
92
104
  "react-aria-components": "^1.22.1"
93
105
  },
package/src/dom/search.ts CHANGED
@@ -18,12 +18,20 @@ export interface SearchHit extends SearchEntry { score: number }
18
18
  export const fold = (s: string) => s.normalize('NFD').replace(/\p{Diacritic}/gu, '').toLowerCase();
19
19
  export const terms = (q: string) => fold(q).split(/[^\p{L}\p{N}_.-]+/u).filter((t) => t.length > 0);
20
20
 
21
+ // Each entry is folded once, not on every key.
22
+ const folded = new WeakMap<SearchEntry, { title: string; group: string; text: string; keys: string }>();
23
+ const foldedOf = (e: SearchEntry) => {
24
+ let f = folded.get(e);
25
+ if (!f) { f = { title: fold(e.title), group: fold(e.group ?? ''), text: fold(e.text ?? ''), keys: fold((e.keywords ?? []).join(' ')) }; folded.set(e, f); }
26
+ return f;
27
+ };
28
+
21
29
  export function searchEntries(entries: SearchEntry[], query: string, limit = 30): SearchHit[] {
22
30
  const words = terms(query);
23
31
  if (!words.length) return [];
24
32
  const hits: SearchHit[] = [];
25
33
  for (const e of entries) {
26
- const title = fold(e.title), group = fold(e.group ?? ''), text = fold(e.text ?? ''), keys = fold((e.keywords ?? []).join(' '));
34
+ const { title, group, text, keys } = foldedOf(e);
27
35
  let score = 0, all = true;
28
36
  for (const w of words) {
29
37
  const inTitle = title.includes(w), inKeys = keys.includes(w), inGroup = group.includes(w), inText = text.includes(w);
@@ -57,3 +65,14 @@ export function highlight(text: string, query: string): string {
57
65
  }
58
66
  return open ? `${out}</mark>` : out;
59
67
  }
68
+
69
+ /** A long text cut to about `size` characters around the first typed word, with «…» where it was cut. */
70
+ export function snippet(text: string, query: string, size = 170): string {
71
+ if (text.length <= size) return text;
72
+ const f = fold(text);
73
+ let first = -1;
74
+ for (const w of terms(query)) { const i = f.indexOf(w); if (i >= 0 && (first < 0 || i < first)) first = i; }
75
+ const from = first > 70 ? text.lastIndexOf(' ', first - 50) + 1 : 0;
76
+ const end = from + size;
77
+ return (from > 0 ? '… ' : '') + text.slice(from, end).trim() + (end < text.length ? ' …' : '');
78
+ }
package/src/i18n/index.ts CHANGED
@@ -7,7 +7,7 @@ export const strings = {
7
7
  unit: 'Unit', unit_seconds: 'seconds', unit_minutes: 'minutes', unit_hours: 'hours', unit_days: 'days', keyLooksWrong: 'This does not look like a key of this service. Keys start with {example}; copy it again from the service.', country: 'Country', chooseMonth: 'Choose a month', previousYear: 'Previous year', nextYear: 'Next year', chooseAnother: 'Choose another', noFileChosen: 'No file chosen', replace: 'Replace', remove: 'Remove', imageHint: 'PNG, JPG, SVG or WebP, up to {max}.', changePhoto: 'Change photo', addPhoto: 'Add a photo', pickColor: 'Pick a colour', colorFormat: 'Write the colour as # and six characters, for example #3b82f6.', runHint: 'Ctrl or ⌘ + Enter runs it', running: 'Running…', run: 'Run', jsonErrorLine: 'The JSON has a mistake on line {line}. Check the commas, quotes and brackets there.', jsonError: 'The JSON has a mistake. Check the commas, quotes and brackets.', jsonOk: 'Valid JSON', formatJson: 'Tidy up', kvName: 'Name', kvValue: 'Value', kvSecret: 'Hide the value of {name}', kvDuplicate: '{name} is written twice; only one is used. Remove one of them.', kvAdd: 'Add a variable', kvPasteHint: 'Paste several NAME=value lines into a name to fill them all.', cronEveryMinute: 'Every minute', cronEveryNMinutes: 'Every {n} minutes', cronHourly: 'Every hour, at minute {m}', cronDaily: 'Every day at {time}', cronWeekdays: 'Monday to Friday at {time}', cronWeekly: 'Every {day} at {time}', cronMonthly: 'On day {day} of each month at {time}', day0: 'Sunday', day1: 'Monday', day2: 'Tuesday', day3: 'Wednesday', day4: 'Thursday', day5: 'Friday', day6: 'Saturday', cronPresets: 'Common schedules', cronPresetDaily: 'Every day at 03:00', cronPresetHourly: 'Every hour', cronPreset15: 'Every 15 minutes', cronPresetWeekdays: 'Weekdays at 09:00', cronPresetMonthly: 'First day of each month', cronCustom: 'A custom schedule', cronInvalid: 'A schedule has five parts separated by spaces: minute, hour, day, month and weekday.', ratingOf: '{value} of {max}',
8
8
  countLabel: 'Count', fromPrevious: 'of the previous step', fromFirst: 'of the first step', starts: 'Starts', takes: 'Takes',
9
9
  live: 'Live', paused: 'Paused', healthUp: 'Working', healthDegraded: 'Slow', healthDown: 'Down', healthUnknown: 'Not checked yet', usageOf: '{used} of {limit}', usageFull: 'The limit is reached: new data is not saved.', usageNear: '{percent} used: it will soon be full.', usageResets: 'Starts again on {date}', step_done: 'done', step_running: 'running', step_waiting: 'waiting', step_failed: 'failed', step_skipped: 'skipped', countdownEnded: 'Time is up', offlineTitle: 'No connection.', offlineBody: 'What you see stays here; changes are saved when the connection comes back.', notFoundTitle: '{what} does not exist', notFoundBody: 'It may have been deleted or moved. Check the address, or go back.',
10
- signOut: 'Sign out', account: 'Account', markAllRead: 'Mark all as read', noNotifications: 'Nothing new', unreadCount: '{count} unread', unread: 'Unread', loadMore: 'Show {count} more', allShown: 'All {count} shown', backToTop: 'Back to top', night: 'Night', paper: 'Paper', density: 'Density', comfortable: 'Comfortable', compact: 'Compact', filterList: 'Filter the list', newer: 'Newer', older: 'Older', currentItem: '{label} (current)', createItem: 'Create {label}', switchItem: 'Switch {kind}', nothingFound: 'Nothing called «{query}»',
10
+ signOut: 'Sign out', account: 'Account', markAllRead: 'Mark all as read', noNotifications: 'Nothing new', unreadCount: '{count} unread', unread: 'Unread', loadMore: 'Show {count} more', allShown: 'All {count} shown', backToTop: 'Back to top', night: 'Night', paper: 'Paper', density: 'Density', comfortable: 'Comfortable', compact: 'Compact', filterList: 'Filter the list', newer: 'Newer', older: 'Older', currentItem: '{label} (current)', createItem: 'Create {label}', switcherSettings: 'Settings', orgSettings: 'Organization settings', switchItem: 'Switch {kind}', nothingFound: 'Nothing called «{query}»',
11
11
  gotIt: 'Got it', stepOf: 'Step {n} of {total}', skipTour: 'Skip the tour', finish: 'Finish', imageOf: '{n} of {total}', notifications: 'Notifications', preview: 'Preview of {label}', openMenu: 'Open the menu of {label}',
12
12
  moreOptions: 'More options', opensNewTab: '(opens in a new tab)', download: 'Download', copyValue: 'Copy {label}', copiedValue: 'Copied: {label}', pressKeys: 'Press {keys}',
13
13
  unsaved: 'You have unsaved changes', discard: 'Discard', saveChanges: 'Save changes', savedAt: 'Saved at {time}', savedNow: 'Saved', notSavedYet: 'Not saved', editField: 'Edit {label}',
@@ -32,7 +32,7 @@ export const strings = {
32
32
  deltaUp: 'Up {value}', deltaDown: 'Down {value}', deltaFlat: 'No change', itemsCount: '{count} items', keysCount: '{count} keys', itemsOne: '1 item', keysOne: '1 key', now: 'Now',
33
33
  primaryKey: 'Primary key', uniqueValue: 'Unique', nullable: 'Can be empty', pointsTo: 'Points to {target}', columnName: 'Column', columnType: 'Type', columnDefault: 'Default', columnRules: 'Rules',
34
34
  noLogs: 'No log lines yet', noActivity: 'Nothing has happened here yet', showExact: 'Show the exact date', showWhole: 'Show it whole',
35
- resize: 'Resize', onThisPage: 'On this page', docsNav: 'Documentation', openNav: 'Open the navigation', closeNav: 'Close the navigation', hideNav: 'Hide the navigation', showNav: 'Show the navigation', surface: 'Night or paper', language: 'Language', products: 'Products', searchDocs: 'Search the docs', searchHint: 'Search pages, sections and terms', noResultsFor: 'Nothing matches «{query}»', noResultsHint: 'Try fewer words, or another word for it.', toOpen: 'to open',
35
+ resize: 'Resize', onThisPage: 'On this page', docsNav: 'Documentation', pagesIn: 'Pages in {section}', openNav: 'Open the navigation', closeNav: 'Close the navigation', hideNav: 'Hide the navigation', showNav: 'Show the navigation', surface: 'Night or paper', language: 'Language', products: 'Products', searchDocs: 'Search the docs', searchHint: 'Search pages, sections and terms', noResultsFor: 'Nothing matches «{query}»', noResultsHint: 'Try fewer words, or another word for it.', toOpen: 'to open',
36
36
  breadcrumb: 'Breadcrumb', pager: 'Previous and next page', editPage: 'Edit this page', wasUseful: 'Was this page useful?', yes: 'Yes', no: 'No', thanks: 'Thank you. It helps us write better pages.', note: 'Note', tip: 'Tip', warning: 'Warning', danger: 'Danger', plainWords: 'In plain words',
37
37
  parameters: 'Parameters', noParams: 'It takes no parameters.', defaultValue: 'Default', errors: 'Errors', request: 'Request', response: 'Response', expected: 'You should see', authentication: 'Authentication', enlarge: 'Enlarge', inWords: 'This diagram in words', figure: 'Figure', glossary: 'Glossary', version: 'Version', changelog: 'Changes', added: 'Added', changed: 'Changed', fixed: 'Fixed', removed: 'Removed', install: 'Install', withAgent: 'With a coding agent', tool: 'Tool', setting: 'Setting', option: 'Option', envVar: 'Environment variable', type: 'Type', readOnly: 'Read only', changesData: 'Changes data',
38
38
  included: 'Included', notIncluded: 'Not included', recommended: 'Recommended', currentPlan: 'Your plan', imageFailed: 'The image could not be loaded.', linesAdded: '{count} lines added', linesRemoved: '{count} lines removed', lineAdded: 'added', lineRemoved: 'removed', linesHidden: 'Show {count} unchanged lines', noChanges: 'Both versions are the same', sortOrder: 'Order', peopleMore: '{count} more: {names}', openImage: 'Open {label}', exactValue: 'Exactly {value}', filesIn: '{count} files', checklistOf: '{done} of {total} done', markDone: 'Mark «{item}» as done', markTodo: 'Mark «{item}» as not done', diffBefore: 'Before', diffAfter: 'After', total: 'Total', activeDays: 'Days with activity', scaleLess: 'Less', scaleMore: 'More', selfTime: 'Self', share: 'Share', outOfMap: 'out of the map', casesMap: 'The use cases, in words', flowsTo: '{from} leads to {to}', flowsToWith: '{from} leads to {to}: {label}', messageFrom: '{n}. {from} to {to}: {label}', messageReply: '{n}. {from} answers {to}: {label}', relation: '{from} points to {to}', tablesCount: '{count} tables', columnsCount: '{count} columns',
@@ -43,7 +43,7 @@ export const strings = {
43
43
  unit: 'Unidad', unit_seconds: 'segundos', unit_minutes: 'minutos', unit_hours: 'horas', unit_days: 'días', keyLooksWrong: 'Esto no parece una clave de este servicio. Las claves empiezan con {example}; cópiala de nuevo desde el servicio.', country: 'País', chooseMonth: 'Elige un mes', previousYear: 'Año anterior', nextYear: 'Año siguiente', chooseAnother: 'Elegir otro', noFileChosen: 'Ningún archivo elegido', replace: 'Reemplazar', remove: 'Quitar', imageHint: 'PNG, JPG, SVG o WebP, hasta {max}.', changePhoto: 'Cambiar foto', addPhoto: 'Agregar una foto', pickColor: 'Elegir un color', colorFormat: 'Escribe el color como # y seis caracteres, por ejemplo #3b82f6.', runHint: 'Ctrl o ⌘ + Enter lo ejecuta', running: 'Ejecutando…', run: 'Ejecutar', jsonErrorLine: 'El JSON tiene un error en la línea {line}. Revisa ahí las comas, las comillas y los corchetes.', jsonError: 'El JSON tiene un error. Revisa las comas, las comillas y los corchetes.', jsonOk: 'JSON válido', formatJson: 'Ordenar', kvName: 'Nombre', kvValue: 'Valor', kvSecret: 'Ocultar el valor de {name}', kvDuplicate: '{name} está escrito dos veces; solo se usa uno. Quita uno de los dos.', kvAdd: 'Agregar una variable', kvPasteHint: 'Pega varias líneas NOMBRE=valor en un nombre para llenarlas todas.', cronEveryMinute: 'Cada minuto', cronEveryNMinutes: 'Cada {n} minutos', cronHourly: 'Cada hora, en el minuto {m}', cronDaily: 'Todos los días a las {time}', cronWeekdays: 'De lunes a viernes a las {time}', cronWeekly: 'Cada {day} a las {time}', cronMonthly: 'El día {day} de cada mes a las {time}', day0: 'domingo', day1: 'lunes', day2: 'martes', day3: 'miércoles', day4: 'jueves', day5: 'viernes', day6: 'sábado', cronPresets: 'Horarios comunes', cronPresetDaily: 'Todos los días a las 03:00', cronPresetHourly: 'Cada hora', cronPreset15: 'Cada 15 minutos', cronPresetWeekdays: 'Días hábiles a las 09:00', cronPresetMonthly: 'El primer día de cada mes', cronCustom: 'Un horario a la medida', cronInvalid: 'Un horario tiene cinco partes separadas por espacios: minuto, hora, día, mes y día de la semana.', ratingOf: '{value} de {max}',
44
44
  countLabel: 'Cantidad', fromPrevious: 'del paso anterior', fromFirst: 'del primer paso', starts: 'Empieza', takes: 'Dura',
45
45
  live: 'En vivo', paused: 'En pausa', healthUp: 'Funcionando', healthDegraded: 'Lento', healthDown: 'Caído', healthUnknown: 'Sin revisar aún', usageOf: '{used} de {limit}', usageFull: 'Se llegó al límite: los datos nuevos no se guardan.', usageNear: '{percent} usado: pronto estará lleno.', usageResets: 'Vuelve a empezar el {date}', step_done: 'hecho', step_running: 'en curso', step_waiting: 'en espera', step_failed: 'falló', step_skipped: 'omitido', countdownEnded: 'Se acabó el tiempo', offlineTitle: 'Sin conexión.', offlineBody: 'Lo que ves se queda aquí; los cambios se guardan cuando vuelva la conexión.', notFoundTitle: '{what} no existe', notFoundBody: 'Puede que se haya borrado o movido. Revisa la dirección o vuelve atrás.',
46
- signOut: 'Cerrar sesión', account: 'Cuenta', markAllRead: 'Marcar todo como leído', noNotifications: 'Nada nuevo', unreadCount: '{count} sin leer', unread: 'Sin leer', loadMore: 'Mostrar {count} más', allShown: 'Se muestran los {count}', backToTop: 'Volver arriba', night: 'Noche', paper: 'Papel', density: 'Densidad', comfortable: 'Cómoda', compact: 'Compacta', filterList: 'Filtrar la lista', newer: 'Más recientes', older: 'Anteriores', currentItem: '{label} (actual)', createItem: 'Crear {label}', switchItem: 'Cambiar de {kind}', nothingFound: 'Nada se llama «{query}»',
46
+ signOut: 'Cerrar sesión', account: 'Cuenta', markAllRead: 'Marcar todo como leído', noNotifications: 'Nada nuevo', unreadCount: '{count} sin leer', unread: 'Sin leer', loadMore: 'Mostrar {count} más', allShown: 'Se muestran los {count}', backToTop: 'Volver arriba', night: 'Noche', paper: 'Papel', density: 'Densidad', comfortable: 'Cómoda', compact: 'Compacta', filterList: 'Filtrar la lista', newer: 'Más recientes', older: 'Anteriores', currentItem: '{label} (actual)', createItem: 'Crear {label}', switcherSettings: 'Ajustes', orgSettings: 'Ajustes de la organización', switchItem: 'Cambiar de {kind}', nothingFound: 'Nada se llama «{query}»',
47
47
  gotIt: 'Entendido', stepOf: 'Paso {n} de {total}', skipTour: 'Saltar el recorrido', finish: 'Terminar', imageOf: '{n} de {total}', notifications: 'Notificaciones', preview: 'Vista previa de {label}', openMenu: 'Abrir el menú de {label}',
48
48
  moreOptions: 'Más opciones', opensNewTab: '(se abre en otra pestaña)', download: 'Descargar', copyValue: 'Copiar {label}', copiedValue: 'Copiado: {label}', pressKeys: 'Pulsa {keys}',
49
49
  unsaved: 'Tienes cambios sin guardar', discard: 'Descartar', saveChanges: 'Guardar cambios', savedAt: 'Guardado a las {time}', savedNow: 'Guardado', notSavedYet: 'No se guardó', editField: 'Editar {label}',
@@ -68,7 +68,7 @@ export const strings = {
68
68
  deltaUp: 'Subió {value}', deltaDown: 'Bajó {value}', deltaFlat: 'Sin cambio', itemsCount: '{count} elementos', keysCount: '{count} claves', itemsOne: '1 elemento', keysOne: '1 clave', now: 'Ahora',
69
69
  primaryKey: 'Clave primaria', uniqueValue: 'Único', nullable: 'Puede quedar vacío', pointsTo: 'Apunta a {target}', columnName: 'Columna', columnType: 'Tipo', columnDefault: 'Valor por defecto', columnRules: 'Reglas',
70
70
  noLogs: 'Aún no hay líneas de registro', noActivity: 'Aún no ha pasado nada aquí', showExact: 'Mostrar la fecha exacta', showWhole: 'Mostrarlo completo',
71
- resize: 'Cambiar tamaño', onThisPage: 'En esta página', docsNav: 'Documentación', openNav: 'Abrir la navegación', closeNav: 'Cerrar la navegación', hideNav: 'Ocultar la navegación', showNav: 'Mostrar la navegación', surface: 'Noche o papel', language: 'Idioma', products: 'Productos', searchDocs: 'Buscar en la documentación', searchHint: 'Busca páginas, secciones y términos', noResultsFor: 'Nada coincide con «{query}»', noResultsHint: 'Prueba con menos palabras, o con otra palabra.', toOpen: 'para abrir',
71
+ resize: 'Cambiar tamaño', onThisPage: 'En esta página', docsNav: 'Documentación', pagesIn: 'Páginas de {section}', openNav: 'Abrir la navegación', closeNav: 'Cerrar la navegación', hideNav: 'Ocultar la navegación', showNav: 'Mostrar la navegación', surface: 'Noche o papel', language: 'Idioma', products: 'Productos', searchDocs: 'Buscar en la documentación', searchHint: 'Busca páginas, secciones y términos', noResultsFor: 'Nada coincide con «{query}»', noResultsHint: 'Prueba con menos palabras, o con otra palabra.', toOpen: 'para abrir',
72
72
  breadcrumb: 'Ruta', pager: 'Página anterior y siguiente', editPage: 'Editar esta página', wasUseful: '¿Te sirvió esta página?', yes: 'Sí', no: 'No', thanks: 'Gracias. Nos ayuda a escribir mejores páginas.', note: 'Nota', tip: 'Consejo', warning: 'Atención', danger: 'Peligro', plainWords: 'En palabras simples',
73
73
  parameters: 'Parámetros', noParams: 'No recibe parámetros.', defaultValue: 'Por defecto', errors: 'Errores', request: 'Solicitud', response: 'Respuesta', expected: 'Deberías ver', authentication: 'Autenticación', enlarge: 'Ampliar', inWords: 'Este diagrama en palabras', figure: 'Figura', glossary: 'Glosario', version: 'Versión', changelog: 'Cambios', added: 'Nuevo', changed: 'Cambió', fixed: 'Arreglado', removed: 'Quitado', install: 'Instalar', withAgent: 'Con un agente de código', tool: 'Herramienta', setting: 'Ajuste', option: 'Opción', envVar: 'Variable de entorno', type: 'Tipo', readOnly: 'Solo lee', changesData: 'Cambia datos',
74
74
  included: 'Incluido', notIncluded: 'No incluido', recommended: 'Recomendado', currentPlan: 'Tu plan', imageFailed: 'No se pudo cargar la imagen.', linesAdded: '{count} líneas agregadas', linesRemoved: '{count} líneas quitadas', lineAdded: 'agregada', lineRemoved: 'quitada', linesHidden: 'Mostrar {count} líneas sin cambios', noChanges: 'Las dos versiones son iguales', sortOrder: 'Orden', peopleMore: '{count} más: {names}', openImage: 'Abrir {label}', exactValue: 'Exactamente {value}', filesIn: '{count} archivos', checklistOf: '{done} de {total} hechos', markDone: 'Marcar «{item}» como hecho', markTodo: 'Marcar «{item}» como pendiente', diffBefore: 'Antes', diffAfter: 'Después', total: 'Total', activeDays: 'Días con actividad', scaleLess: 'Menos', scaleMore: 'Más', selfTime: 'Propio', share: 'Parte', outOfMap: 'fuera del mapa', casesMap: 'Los casos de uso, en palabras', flowsTo: '{from} lleva a {to}', flowsToWith: '{from} lleva a {to}: {label}', messageFrom: '{n}. {from} a {to}: {label}', messageReply: '{n}. {from} responde a {to}: {label}', relation: '{from} apunta a {to}', tablesCount: '{count} tablas', columnsCount: '{count} columnas',
@@ -0,0 +1,18 @@
1
+ // Marks of other companies, for the one place a Sypnia screen shows them: the buttons that sign in with that company.
2
+ // They are not part of «lid and light» (icons/icons.mjs) and never follow its rules: each is drawn exactly as its
3
+ // owner publishes it, in its own colours, and is never recoloured, outlined or redrawn.
4
+ // google: the «G» from Google's sign-in branding guidelines, in its four colours (developers.google.com/identity/branding-guidelines).
5
+ // github: the GitHub mark (the Invertocat) from GitHub's logo guidelines, in one colour: the text colour (github.com/logos).
6
+ export const brandMarks = {
7
+ google: {
8
+ viewBox: '0 0 48 48',
9
+ svg: '<path fill="#EA4335" d="M24 9.5c3.54 0 6.71 1.22 9.21 3.6l6.85-6.85C35.9 2.38 30.47 0 24 0 14.62 0 6.51 5.38 2.56 13.22l7.98 6.19C12.43 13.72 17.74 9.5 24 9.5z"/><path fill="#4285F4" d="M46.98 24.55c0-1.57-.15-3.09-.38-4.55H24v9.02h12.94c-.58 2.96-2.26 5.48-4.78 7.18l7.73 6c4.51-4.18 7.09-10.36 7.09-17.65z"/><path fill="#FBBC05" d="M10.53 28.59c-.48-1.45-.76-2.99-.76-4.59s.27-3.14.76-4.59l-7.98-6.19C.92 16.46 0 20.12 0 24c0 3.88.92 7.54 2.56 10.78l7.97-6.19z"/><path fill="#34A853" d="M24 48c6.48 0 11.93-2.13 15.89-5.81l-7.73-6c-2.15 1.45-4.92 2.3-8.16 2.3-6.26 0-11.57-4.22-13.47-9.91l-7.98 6.19C6.51 42.62 14.62 48 24 48z"/>',
10
+ name: 'Google',
11
+ },
12
+ github: {
13
+ viewBox: '0 0 16 16',
14
+ svg: '<path fill="currentColor" fill-rule="evenodd" d="M8 0C3.58 0 0 3.58 0 8c0 3.54 2.29 6.53 5.47 7.59.4.07.55-.17.55-.38 0-.19-.01-.82-.01-1.49-2.01.37-2.53-.49-2.69-.94-.09-.23-.48-.94-.82-1.13-.28-.15-.68-.52-.01-.53.63-.01 1.08.58 1.23.82.72 1.21 1.87.87 2.33.66.07-.52.28-.87.51-1.07-1.78-.2-3.64-.89-3.64-3.95 0-.87.31-1.59.82-2.15-.08-.2-.36-1.02.08-2.12 0 0 .67-.21 2.2.82.64-.18 1.32-.27 2-.27.68 0 1.36.09 2 .27 1.53-1.04 2.2-.82 2.2-.82.44 1.1.16 1.92.08 2.12.51.56.82 1.27.82 2.15 0 3.07-1.87 3.75-3.65 3.95.29.25.54.73.54 1.48 0 1.07-.01 1.93-.01 2.2 0 .21.15.46.55.38A8.013 8.013 0 0016 8c0-4.42-3.58-8-8-8z"/>',
15
+ name: 'GitHub',
16
+ },
17
+ } as const;
18
+ export type BrandName = keyof typeof brandMarks;