@prismora/fonts 0.0.0-stage → 0.1.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/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 Aravind Kumar and Prismora contributors
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/README.md CHANGED
@@ -1,3 +1,15 @@
1
- # Temporary Holding Version
1
+ # @prismora/fonts
2
2
 
3
- This version is a temporary placeholder for this package. An operational version to replace this has been submitted for review and is awaiting a staged release.
3
+ Prismora font pairings: self-hosted variable fonts (Fontsource) with matching fallbacks.
4
+
5
+ ```sh
6
+ npm install @prismora/fonts
7
+ ```
8
+
9
+ ```ts
10
+ import '@prismora/fonts/pairing-inter'; // the files of one pairing
11
+ ```
12
+
13
+ Pick the pairing in your theme (`typography: { font: 'inter' }`).
14
+
15
+ Documentation: [prismora.design/docs/typography](https://prismora.design/docs/typography) · Part of [Prismora](https://github.com/axxra/prismora), one seed, every theme. MIT licence.
package/css/all.css ADDED
@@ -0,0 +1,13 @@
1
+ /* Every bundled font (docs and font pickers). Browsers still download only faces a page uses. */
2
+ @import './inter.css';
3
+ @import './figtree.css';
4
+ @import './plus-jakarta-sans.css';
5
+ @import './manrope.css';
6
+ @import './dm-sans.css';
7
+ @import './nunito.css';
8
+ @import './space-grotesk.css';
9
+ @import './fraunces.css';
10
+ @import './source-serif-4.css';
11
+ @import './lora.css';
12
+ @import './jetbrains-mono.css';
13
+ @import './fira-code.css';
@@ -0,0 +1,3 @@
1
+ /* dm-sans — SIL Open Font License 1.1 (Fontsource). Upright and italic, variable weight. */
2
+ @import '@fontsource-variable/dm-sans/index.css';
3
+ @import '@fontsource-variable/dm-sans/wght-italic.css';
@@ -0,0 +1,3 @@
1
+ /* figtree — SIL Open Font License 1.1 (Fontsource). Upright and italic, variable weight. */
2
+ @import '@fontsource-variable/figtree/index.css';
3
+ @import '@fontsource-variable/figtree/wght-italic.css';
@@ -0,0 +1,2 @@
1
+ /* fira-code — SIL Open Font License 1.1 (Fontsource). Upright, variable weight. */
2
+ @import '@fontsource-variable/fira-code/index.css';
@@ -0,0 +1,3 @@
1
+ /* fraunces — SIL Open Font License 1.1 (Fontsource). Upright and italic, variable weight. */
2
+ @import '@fontsource-variable/fraunces/index.css';
3
+ @import '@fontsource-variable/fraunces/wght-italic.css';
package/css/inter.css ADDED
@@ -0,0 +1,3 @@
1
+ /* inter — SIL Open Font License 1.1 (Fontsource). Upright and italic, variable weight. */
2
+ @import '@fontsource-variable/inter/index.css';
3
+ @import '@fontsource-variable/inter/wght-italic.css';
@@ -0,0 +1,3 @@
1
+ /* jetbrains-mono — SIL Open Font License 1.1 (Fontsource). Upright and italic, variable weight. */
2
+ @import '@fontsource-variable/jetbrains-mono/index.css';
3
+ @import '@fontsource-variable/jetbrains-mono/wght-italic.css';
package/css/lora.css ADDED
@@ -0,0 +1,3 @@
1
+ /* lora — SIL Open Font License 1.1 (Fontsource). Upright and italic, variable weight. */
2
+ @import '@fontsource-variable/lora/index.css';
3
+ @import '@fontsource-variable/lora/wght-italic.css';
@@ -0,0 +1,2 @@
1
+ /* manrope — SIL Open Font License 1.1 (Fontsource). Upright, variable weight. */
2
+ @import '@fontsource-variable/manrope/index.css';
package/css/nunito.css ADDED
@@ -0,0 +1,3 @@
1
+ /* nunito — SIL Open Font License 1.1 (Fontsource). Upright and italic, variable weight. */
2
+ @import '@fontsource-variable/nunito/index.css';
3
+ @import '@fontsource-variable/nunito/wght-italic.css';
@@ -0,0 +1,5 @@
1
+ /* Pairing "Editorial": fonts for data-font="editorial". */
2
+ @import './inter.css';
3
+ @import './fraunces.css';
4
+ @import './source-serif-4.css';
5
+ @import './jetbrains-mono.css';
@@ -0,0 +1,4 @@
1
+ /* Pairing "Figtree": fonts for data-font="figtree". */
2
+ @import './figtree.css';
3
+ @import './lora.css';
4
+ @import './jetbrains-mono.css';
@@ -0,0 +1,4 @@
1
+ /* Pairing "Friendly": fonts for data-font="friendly". */
2
+ @import './nunito.css';
3
+ @import './lora.css';
4
+ @import './fira-code.css';
@@ -0,0 +1,5 @@
1
+ /* Pairing "Grotesk": fonts for data-font="grotesk". */
2
+ @import './dm-sans.css';
3
+ @import './space-grotesk.css';
4
+ @import './lora.css';
5
+ @import './fira-code.css';
@@ -0,0 +1,4 @@
1
+ /* Pairing "Inter": fonts for data-font="inter". */
2
+ @import './inter.css';
3
+ @import './source-serif-4.css';
4
+ @import './jetbrains-mono.css';
@@ -0,0 +1,4 @@
1
+ /* Pairing "Plus Jakarta": fonts for data-font="jakarta". */
2
+ @import './plus-jakarta-sans.css';
3
+ @import './source-serif-4.css';
4
+ @import './fira-code.css';
@@ -0,0 +1,4 @@
1
+ /* Pairing "Manrope": fonts for data-font="manrope". */
2
+ @import './manrope.css';
3
+ @import './source-serif-4.css';
4
+ @import './jetbrains-mono.css';
@@ -0,0 +1,2 @@
1
+ /* Pairing "System": fonts for data-font="system". */
2
+ /* Uses system fonts only: nothing to load. */
@@ -0,0 +1,3 @@
1
+ /* plus-jakarta-sans — SIL Open Font License 1.1 (Fontsource). Upright and italic, variable weight. */
2
+ @import '@fontsource-variable/plus-jakarta-sans/index.css';
3
+ @import '@fontsource-variable/plus-jakarta-sans/wght-italic.css';
@@ -0,0 +1,3 @@
1
+ /* source-serif-4 — SIL Open Font License 1.1 (Fontsource). Upright and italic, variable weight. */
2
+ @import '@fontsource-variable/source-serif-4/index.css';
3
+ @import '@fontsource-variable/source-serif-4/wght-italic.css';
@@ -0,0 +1,2 @@
1
+ /* space-grotesk — SIL Open Font License 1.1 (Fontsource). Upright, variable weight. */
2
+ @import '@fontsource-variable/space-grotesk/index.css';
@@ -0,0 +1,112 @@
1
+ /**
2
+ * @prismora/fonts — self-hosted variable fonts (SIL Open Font License 1.1, via Fontsource) and the pairings that use
3
+ * them. Import only what you use; each file loads just the character subsets a page needs (unicode-range).
4
+ *
5
+ * import '@prismora/fonts/pairing-inter'; // every font of a pairing
6
+ * import '@prismora/fonts/fraunces'; // or a single font
7
+ * <html data-font="inter"> // apply a pairing (or set typography.font in your theme)
8
+ */
9
+ import { type FontPairingId } from '@prismora/tokens';
10
+ export { FONT_PAIRINGS, SYSTEM_STACKS, fontStack, pairingDeclarations, type FontPairing, type FontPairingId, type FontRole } from '@prismora/tokens';
11
+ export interface FontInfo {
12
+ /** CSS font-family name the files register. */
13
+ family: string;
14
+ category: 'sans' | 'serif' | 'display' | 'mono';
15
+ /** Ships a true italic (otherwise browsers slant the upright). */
16
+ italic: boolean;
17
+ /** Variable weight range. */
18
+ weights: [number, number];
19
+ license: 'OFL-1.1';
20
+ }
21
+ /** Every bundled font, by import name (`@prismora/fonts/<name>`). */
22
+ export declare const FONTS: {
23
+ readonly inter: {
24
+ readonly family: "Inter Variable";
25
+ readonly category: "sans";
26
+ readonly italic: true;
27
+ readonly weights: [100, 900];
28
+ readonly license: "OFL-1.1";
29
+ };
30
+ readonly figtree: {
31
+ readonly family: "Figtree Variable";
32
+ readonly category: "sans";
33
+ readonly italic: true;
34
+ readonly weights: [300, 900];
35
+ readonly license: "OFL-1.1";
36
+ };
37
+ readonly 'plus-jakarta-sans': {
38
+ readonly family: "Plus Jakarta Sans Variable";
39
+ readonly category: "sans";
40
+ readonly italic: true;
41
+ readonly weights: [200, 800];
42
+ readonly license: "OFL-1.1";
43
+ };
44
+ readonly manrope: {
45
+ readonly family: "Manrope Variable";
46
+ readonly category: "sans";
47
+ readonly italic: false;
48
+ readonly weights: [200, 800];
49
+ readonly license: "OFL-1.1";
50
+ };
51
+ readonly 'dm-sans': {
52
+ readonly family: "DM Sans Variable";
53
+ readonly category: "sans";
54
+ readonly italic: true;
55
+ readonly weights: [100, 1000];
56
+ readonly license: "OFL-1.1";
57
+ };
58
+ readonly nunito: {
59
+ readonly family: "Nunito Variable";
60
+ readonly category: "sans";
61
+ readonly italic: true;
62
+ readonly weights: [200, 1000];
63
+ readonly license: "OFL-1.1";
64
+ };
65
+ readonly 'space-grotesk': {
66
+ readonly family: "Space Grotesk Variable";
67
+ readonly category: "display";
68
+ readonly italic: false;
69
+ readonly weights: [300, 700];
70
+ readonly license: "OFL-1.1";
71
+ };
72
+ readonly fraunces: {
73
+ readonly family: "Fraunces Variable";
74
+ readonly category: "display";
75
+ readonly italic: true;
76
+ readonly weights: [100, 900];
77
+ readonly license: "OFL-1.1";
78
+ };
79
+ readonly 'source-serif-4': {
80
+ readonly family: "Source Serif 4 Variable";
81
+ readonly category: "serif";
82
+ readonly italic: true;
83
+ readonly weights: [200, 900];
84
+ readonly license: "OFL-1.1";
85
+ };
86
+ readonly lora: {
87
+ readonly family: "Lora Variable";
88
+ readonly category: "serif";
89
+ readonly italic: true;
90
+ readonly weights: [400, 700];
91
+ readonly license: "OFL-1.1";
92
+ };
93
+ readonly 'jetbrains-mono': {
94
+ readonly family: "JetBrains Mono Variable";
95
+ readonly category: "mono";
96
+ readonly italic: true;
97
+ readonly weights: [100, 800];
98
+ readonly license: "OFL-1.1";
99
+ };
100
+ readonly 'fira-code': {
101
+ readonly family: "Fira Code Variable";
102
+ readonly category: "mono";
103
+ readonly italic: false;
104
+ readonly weights: [300, 700];
105
+ readonly license: "OFL-1.1";
106
+ };
107
+ };
108
+ export type FontName = keyof typeof FONTS;
109
+ /** Font import names a pairing needs (none for `system`). */
110
+ export declare function pairingFonts(id: FontPairingId): FontName[];
111
+ /** Module specifiers to import for a pairing, e.g. for a code snippet or a dynamic import. */
112
+ export declare const pairingImport: (id: FontPairingId) => string;
package/dist/index.js ADDED
@@ -0,0 +1,33 @@
1
+ /**
2
+ * @prismora/fonts — self-hosted variable fonts (SIL Open Font License 1.1, via Fontsource) and the pairings that use
3
+ * them. Import only what you use; each file loads just the character subsets a page needs (unicode-range).
4
+ *
5
+ * import '@prismora/fonts/pairing-inter'; // every font of a pairing
6
+ * import '@prismora/fonts/fraunces'; // or a single font
7
+ * <html data-font="inter"> // apply a pairing (or set typography.font in your theme)
8
+ */
9
+ import { FONT_PAIRINGS } from '@prismora/tokens';
10
+ export { FONT_PAIRINGS, SYSTEM_STACKS, fontStack, pairingDeclarations } from '@prismora/tokens';
11
+ /** Every bundled font, by import name (`@prismora/fonts/<name>`). */
12
+ export const FONTS = {
13
+ inter: { family: 'Inter Variable', category: 'sans', italic: true, weights: [100, 900], license: 'OFL-1.1' },
14
+ figtree: { family: 'Figtree Variable', category: 'sans', italic: true, weights: [300, 900], license: 'OFL-1.1' },
15
+ 'plus-jakarta-sans': { family: 'Plus Jakarta Sans Variable', category: 'sans', italic: true, weights: [200, 800], license: 'OFL-1.1' },
16
+ manrope: { family: 'Manrope Variable', category: 'sans', italic: false, weights: [200, 800], license: 'OFL-1.1' },
17
+ 'dm-sans': { family: 'DM Sans Variable', category: 'sans', italic: true, weights: [100, 1000], license: 'OFL-1.1' },
18
+ nunito: { family: 'Nunito Variable', category: 'sans', italic: true, weights: [200, 1000], license: 'OFL-1.1' },
19
+ 'space-grotesk': { family: 'Space Grotesk Variable', category: 'display', italic: false, weights: [300, 700], license: 'OFL-1.1' },
20
+ fraunces: { family: 'Fraunces Variable', category: 'display', italic: true, weights: [100, 900], license: 'OFL-1.1' },
21
+ 'source-serif-4': { family: 'Source Serif 4 Variable', category: 'serif', italic: true, weights: [200, 900], license: 'OFL-1.1' },
22
+ lora: { family: 'Lora Variable', category: 'serif', italic: true, weights: [400, 700], license: 'OFL-1.1' },
23
+ 'jetbrains-mono': { family: 'JetBrains Mono Variable', category: 'mono', italic: true, weights: [100, 800], license: 'OFL-1.1' },
24
+ 'fira-code': { family: 'Fira Code Variable', category: 'mono', italic: false, weights: [300, 700], license: 'OFL-1.1' },
25
+ };
26
+ /** Font import names a pairing needs (none for `system`). */
27
+ export function pairingFonts(id) {
28
+ const byFamily = new Map(Object.entries(FONTS).map(([k, v]) => [v.family, k]));
29
+ const fams = Object.values(FONT_PAIRINGS[id].families).filter((f) => !!f);
30
+ return [...new Set(fams.map((f) => byFamily.get(f)).filter(Boolean))];
31
+ }
32
+ /** Module specifiers to import for a pairing, e.g. for a code snippet or a dynamic import. */
33
+ export const pairingImport = (id) => `@prismora/fonts/pairing-${id}`;
package/package.json CHANGED
@@ -1,6 +1,58 @@
1
1
  {
2
2
  "name": "@prismora/fonts",
3
- "version": "0.0.0-stage",
4
- "stub": true,
5
- "description": "Temporary package placeholder for staged publishing"
6
- }
3
+ "version": "0.1.1",
4
+ "description": "Self-hosted, open-licence (OFL) variable fonts and font pairings for Prismora. Import only the fonts you use.",
5
+ "keywords": [
6
+ "prismora",
7
+ "design-system",
8
+ "fonts",
9
+ "typography"
10
+ ],
11
+ "homepage": "https://prismora.design",
12
+ "bugs": {
13
+ "url": "https://github.com/axxra/prismora/issues"
14
+ },
15
+ "repository": {
16
+ "type": "git",
17
+ "url": "git+https://github.com/axxra/prismora.git",
18
+ "directory": "packages/fonts"
19
+ },
20
+ "license": "MIT",
21
+ "author": "Aravind Kumar",
22
+ "type": "module",
23
+ "main": "./dist/index.js",
24
+ "types": "./dist/index.d.ts",
25
+ "exports": {
26
+ ".": {
27
+ "types": "./dist/index.d.ts",
28
+ "default": "./dist/index.js"
29
+ },
30
+ "./all.css": "./css/all.css",
31
+ "./*": "./css/*.css"
32
+ },
33
+ "files": [
34
+ "dist",
35
+ "css"
36
+ ],
37
+ "sideEffects": [
38
+ "*.css"
39
+ ],
40
+ "dependencies": {
41
+ "@fontsource-variable/dm-sans": "^5.3.0",
42
+ "@fontsource-variable/figtree": "^5.3.0",
43
+ "@fontsource-variable/fira-code": "^5.3.0",
44
+ "@fontsource-variable/fraunces": "^5.3.0",
45
+ "@fontsource-variable/inter": "^5.3.0",
46
+ "@fontsource-variable/jetbrains-mono": "^5.3.0",
47
+ "@fontsource-variable/lora": "^5.3.0",
48
+ "@fontsource-variable/manrope": "^5.3.0",
49
+ "@fontsource-variable/nunito": "^5.3.0",
50
+ "@fontsource-variable/plus-jakarta-sans": "^5.3.0",
51
+ "@fontsource-variable/source-serif-4": "^5.3.1",
52
+ "@fontsource-variable/space-grotesk": "^5.3.0",
53
+ "@prismora/tokens": "^0.1.1"
54
+ },
55
+ "publishConfig": {
56
+ "access": "public"
57
+ }
58
+ }