@bloxwap/font 0.1.1 → 0.1.3
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/README.md +82 -1
- package/bloxwap-font.css +156 -10
- package/css/mono-arabic.css +27 -0
- package/css/mono-armenian.css +34 -0
- package/css/mono-core.css +68 -0
- package/css/mono-full.css +18 -0
- package/css/mono-georgian.css +34 -0
- package/css/mono-hebrew.css +27 -0
- package/css/mono-jp.css +27 -0
- package/css/mono-kr.css +27 -0
- package/css/mono-sc.css +27 -0
- package/css/mono.css +243 -0
- package/css/pixel-core.css +68 -0
- package/css/pixel-full.css +18 -0
- package/css/pixel.css +68 -0
- package/css/sans-arabic.css +27 -0
- package/css/sans-armenian.css +34 -0
- package/css/sans-core.css +68 -0
- package/css/sans-full.css +18 -0
- package/css/sans-georgian.css +34 -0
- package/css/sans-hebrew.css +27 -0
- package/css/sans-jp.css +27 -0
- package/css/sans-kr.css +27 -0
- package/css/sans-sc.css +27 -0
- package/css/sans.css +243 -0
- package/fonts/BloxwapMono/BloxwapMono-Italic-Variable.cyrillic.woff2 +0 -0
- package/fonts/BloxwapMono/BloxwapMono-Italic-Variable.greek.woff2 +0 -0
- package/fonts/BloxwapMono/BloxwapMono-Italic-Variable.latin.woff2 +0 -0
- package/fonts/BloxwapMono/BloxwapMono-Italic-Variable.other.woff2 +0 -0
- package/fonts/BloxwapMono/BloxwapMono-Variable.cyrillic.woff2 +0 -0
- package/fonts/BloxwapMono/BloxwapMono-Variable.greek.woff2 +0 -0
- package/fonts/BloxwapMono/BloxwapMono-Variable.latin.woff2 +0 -0
- package/fonts/BloxwapMono/BloxwapMono-Variable.other.woff2 +0 -0
- package/fonts/BloxwapMono/LICENSE +93 -0
- package/fonts/BloxwapMonoArabic/LICENSE +93 -0
- package/fonts/BloxwapMonoArmenian/LICENSE +93 -0
- package/fonts/BloxwapMonoGeorgian/LICENSE +93 -0
- package/fonts/BloxwapMonoHebrew/LICENSE +93 -0
- package/fonts/BloxwapMonoJP/LICENSE +93 -0
- package/fonts/BloxwapMonoKR/LICENSE +93 -0
- package/fonts/BloxwapMonoSC/LICENSE +93 -0
- package/fonts/BloxwapPixel/BloxwapPixel-Italic-Variable.cyrillic.woff2 +0 -0
- package/fonts/BloxwapPixel/BloxwapPixel-Italic-Variable.greek.woff2 +0 -0
- package/fonts/BloxwapPixel/BloxwapPixel-Italic-Variable.latin.woff2 +0 -0
- package/fonts/BloxwapPixel/BloxwapPixel-Italic-Variable.other.woff2 +0 -0
- package/fonts/BloxwapPixel/BloxwapPixel-Variable.cyrillic.woff2 +0 -0
- package/fonts/BloxwapPixel/BloxwapPixel-Variable.greek.woff2 +0 -0
- package/fonts/BloxwapPixel/BloxwapPixel-Variable.latin.woff2 +0 -0
- package/fonts/BloxwapPixel/BloxwapPixel-Variable.other.woff2 +0 -0
- package/fonts/BloxwapPixel/LICENSE +93 -0
- package/fonts/BloxwapSans/BloxwapSans-Italic-Variable.cyrillic.woff2 +0 -0
- package/fonts/BloxwapSans/BloxwapSans-Italic-Variable.greek.woff2 +0 -0
- package/fonts/BloxwapSans/BloxwapSans-Italic-Variable.latin.woff2 +0 -0
- package/fonts/BloxwapSans/BloxwapSans-Italic-Variable.other.woff2 +0 -0
- package/fonts/BloxwapSans/BloxwapSans-Variable.cyrillic.woff2 +0 -0
- package/fonts/BloxwapSans/BloxwapSans-Variable.greek.woff2 +0 -0
- package/fonts/BloxwapSans/BloxwapSans-Variable.latin.woff2 +0 -0
- package/fonts/BloxwapSans/BloxwapSans-Variable.other.woff2 +0 -0
- package/fonts/BloxwapSans/LICENSE +93 -0
- package/fonts/BloxwapSansArabic/LICENSE +93 -0
- package/fonts/BloxwapSansArmenian/LICENSE +93 -0
- package/fonts/BloxwapSansGeorgian/LICENSE +93 -0
- package/fonts/BloxwapSansHebrew/LICENSE +93 -0
- package/fonts/BloxwapSansJP/LICENSE +93 -0
- package/fonts/BloxwapSansKR/LICENSE +93 -0
- package/fonts/BloxwapSansSC/LICENSE +93 -0
- package/manifest.json +7373 -0
- package/package.json +13 -5
- package/src/manifest.d.ts +35 -0
- package/src/mono-italic.js +19 -0
- package/src/mono.d.ts +4 -0
- package/src/mono.js +11 -5
- package/src/pixel-italic.js +19 -0
- package/src/pixel.d.ts +4 -0
- package/src/pixel.js +9 -5
- package/src/sans-italic.js +19 -0
- package/src/sans.d.ts +4 -0
- package/src/sans.js +11 -5
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@bloxwap/font",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.3",
|
|
4
4
|
"description": "Bloxwap Sans, Mono and Pixel: rounded variable web fonts with Arabic, Hebrew, Armenian, Georgian, Japanese, Korean and Chinese companions. next/font exports and a plain CSS stylesheet.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "OFL-1.1",
|
|
@@ -59,7 +59,12 @@
|
|
|
59
59
|
"default": "./src/pixel.js"
|
|
60
60
|
},
|
|
61
61
|
"./fonts/*": "./fonts/*",
|
|
62
|
-
"./package.json": "./package.json"
|
|
62
|
+
"./package.json": "./package.json",
|
|
63
|
+
"./css/*": "./css/*.css",
|
|
64
|
+
"./manifest": {
|
|
65
|
+
"types": "./src/manifest.d.ts",
|
|
66
|
+
"default": "./manifest.json"
|
|
67
|
+
}
|
|
63
68
|
},
|
|
64
69
|
"files": [
|
|
65
70
|
"src",
|
|
@@ -68,14 +73,17 @@
|
|
|
68
73
|
"sans-scripts.css",
|
|
69
74
|
"mono-scripts.css",
|
|
70
75
|
"LICENSE",
|
|
71
|
-
"README.md"
|
|
76
|
+
"README.md",
|
|
77
|
+
"css",
|
|
78
|
+
"manifest.json"
|
|
72
79
|
],
|
|
73
80
|
"scripts": {
|
|
74
81
|
"build": "node scripts/build.mjs",
|
|
75
|
-
"prepack": "node scripts/build.mjs"
|
|
82
|
+
"prepack": "node scripts/build.mjs",
|
|
83
|
+
"test": "node --test scripts/package.test.mjs scripts/check-publish-auth.test.mjs && ${FONT_PYTHON:-python3} scripts/test_faces.py"
|
|
76
84
|
},
|
|
77
85
|
"peerDependencies": {
|
|
78
|
-
"next": ">=
|
|
86
|
+
"next": ">=15.0.0"
|
|
79
87
|
},
|
|
80
88
|
"peerDependenciesMeta": {
|
|
81
89
|
"next": {
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
/** Content-addressed inventory of the built package. Scripts use ISO 15924 tags. */
|
|
2
|
+
export interface FontFace {
|
|
3
|
+
/** Native asset paths are package-qualified; web paths are relative to @bloxwap/font. */
|
|
4
|
+
readonly path: string;
|
|
5
|
+
readonly package?: `@bloxwap/font-native${string}`;
|
|
6
|
+
readonly family: string;
|
|
7
|
+
readonly weight: number | readonly [number, number];
|
|
8
|
+
readonly style: 'normal' | 'italic';
|
|
9
|
+
readonly scripts: readonly string[];
|
|
10
|
+
readonly version: string;
|
|
11
|
+
readonly packageVersion: string;
|
|
12
|
+
readonly bytes: number;
|
|
13
|
+
readonly sha256: string;
|
|
14
|
+
readonly format: 'woff2' | 'ttf';
|
|
15
|
+
readonly subset?: 'latin' | 'greek' | 'cyrillic' | 'other';
|
|
16
|
+
readonly axes: Readonly<Record<string, number | { min: number; default: number; max: number }>>;
|
|
17
|
+
readonly registrationName?: string;
|
|
18
|
+
/** Pinned release source: <asset>.zip:<family>/woff2/<file>.woff2@<tag>. */
|
|
19
|
+
readonly source?: string;
|
|
20
|
+
readonly sourceWeight?: number;
|
|
21
|
+
readonly variableSource?: string;
|
|
22
|
+
readonly variableSourceSha256?: string;
|
|
23
|
+
readonly generation?: 'decode-static-woff2-and-register';
|
|
24
|
+
readonly sourceSha256?: string;
|
|
25
|
+
}
|
|
26
|
+
export interface FontManifest {
|
|
27
|
+
readonly schemaVersion: 1;
|
|
28
|
+
readonly package: '@bloxwap/font';
|
|
29
|
+
readonly version: string;
|
|
30
|
+
readonly license: 'OFL-1.1';
|
|
31
|
+
readonly generator: string;
|
|
32
|
+
readonly faces: readonly FontFace[];
|
|
33
|
+
}
|
|
34
|
+
declare const manifest: FontManifest;
|
|
35
|
+
export default manifest;
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import localFont from 'next/font/local';
|
|
2
|
+
|
|
3
|
+
// The italic face of Bloxwap Mono, imported for its side effect by ./mono.js. It is a separate next/font call so that it
|
|
4
|
+
// can opt out of preloading: `preload` applies to every file in a call, and a page that never renders italic text
|
|
5
|
+
// would otherwise download the italic as well. Without a preload, the browser fetches this face only when text uses it.
|
|
6
|
+
//
|
|
7
|
+
// From Next.js 15, next/font/local names the family after the const the call is assigned to (Next 13.2-14 hashed it
|
|
8
|
+
// per call, hence the `next >=15` peer range), so this const must stay `BloxwapMono`:
|
|
9
|
+
// that adds the italic to the same family as the normal face in ./mono.js, and <em> gets the real italic, not a
|
|
10
|
+
// synthesized slant.
|
|
11
|
+
const BloxwapMono = localFont({
|
|
12
|
+
src: [{ path: '../fonts/BloxwapMono/BloxwapMono-Italic-Variable.woff2', weight: '100 900', style: 'italic' }],
|
|
13
|
+
display: 'swap',
|
|
14
|
+
preload: false,
|
|
15
|
+
// Like ./mono.js, no metric-adjusted fallback face.
|
|
16
|
+
adjustFontFallback: false,
|
|
17
|
+
});
|
|
18
|
+
|
|
19
|
+
export default BloxwapMono;
|
package/src/mono.d.ts
CHANGED
|
@@ -1,3 +1,7 @@
|
|
|
1
1
|
import type { BloxwapFont } from './font';
|
|
2
2
|
|
|
3
|
+
/**
|
|
4
|
+
* Bloxwap Mono (`next/font/local`): `variable` sets --font-bloxwap-mono. Only the normal face is preloaded; the real
|
|
5
|
+
* italic is in the same family and downloads only when a page renders italic text.
|
|
6
|
+
*/
|
|
3
7
|
export declare const BloxwapMono: BloxwapFont;
|
package/src/mono.js
CHANGED
|
@@ -1,13 +1,19 @@
|
|
|
1
1
|
import localFont from 'next/font/local';
|
|
2
|
+
// next/font/local cannot set unicode-range per src. Keep the complete core font
|
|
3
|
+
// here; import @bloxwap/font/css/mono for automatic core subsets instead.
|
|
2
4
|
// The companion scripts (Arabic, Hebrew, Armenian, Georgian, CJK) as one fallback family with unicode-range.
|
|
3
5
|
import '../mono-scripts.css';
|
|
6
|
+
// The italic face: the same family, not preloaded, so it downloads only when a page renders italic text.
|
|
7
|
+
import './mono-italic.js';
|
|
4
8
|
|
|
5
|
-
/**
|
|
9
|
+
/**
|
|
10
|
+
* Bloxwap Mono for Next.js: variable weight 100–900 with italics; `variable` sets --font-bloxwap-mono.
|
|
11
|
+
* Next.js preloads the normal face; the italic loads only when a page renders italic text.
|
|
12
|
+
*/
|
|
6
13
|
export const BloxwapMono = localFont({
|
|
7
|
-
src:
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
],
|
|
14
|
+
// No `style` on this src: with a single file next/font copies its style onto className and .style, and a
|
|
15
|
+
// `font-style: normal` there would cancel inherited italics (<em><code className>) and fall back to the normal face.
|
|
16
|
+
src: [{ path: '../fonts/BloxwapMono/BloxwapMono-Variable.woff2', weight: '100 900' }],
|
|
11
17
|
variable: '--font-bloxwap-mono',
|
|
12
18
|
display: 'swap',
|
|
13
19
|
adjustFontFallback: false,
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import localFont from 'next/font/local';
|
|
2
|
+
|
|
3
|
+
// The italic face of Bloxwap Pixel, imported for its side effect by ./pixel.js. It is a separate next/font call so that it
|
|
4
|
+
// can opt out of preloading: `preload` applies to every file in a call, and a page that never renders italic text
|
|
5
|
+
// would otherwise download the italic as well. Without a preload, the browser fetches this face only when text uses it.
|
|
6
|
+
//
|
|
7
|
+
// From Next.js 15, next/font/local names the family after the const the call is assigned to (Next 13.2-14 hashed it
|
|
8
|
+
// per call, hence the `next >=15` peer range), so this const must stay `BloxwapPixel`:
|
|
9
|
+
// that adds the italic to the same family as the normal face in ./pixel.js, and <em> gets the real italic, not a
|
|
10
|
+
// synthesized slant.
|
|
11
|
+
const BloxwapPixel = localFont({
|
|
12
|
+
src: [{ path: '../fonts/BloxwapPixel/BloxwapPixel-Italic-Variable.woff2', weight: '100 900', style: 'italic' }],
|
|
13
|
+
display: 'swap',
|
|
14
|
+
preload: false,
|
|
15
|
+
// Like ./pixel.js, no metric-adjusted fallback face.
|
|
16
|
+
adjustFontFallback: false,
|
|
17
|
+
});
|
|
18
|
+
|
|
19
|
+
export default BloxwapPixel;
|
package/src/pixel.d.ts
CHANGED
|
@@ -1,3 +1,7 @@
|
|
|
1
1
|
import type { BloxwapFont } from './font';
|
|
2
2
|
|
|
3
|
+
/**
|
|
4
|
+
* Bloxwap Pixel (`next/font/local`): `variable` sets --font-bloxwap-pixel. Only the normal face is preloaded; the real
|
|
5
|
+
* italic is in the same family and downloads only when a page renders italic text.
|
|
6
|
+
*/
|
|
3
7
|
export declare const BloxwapPixel: BloxwapFont;
|
package/src/pixel.js
CHANGED
|
@@ -1,14 +1,18 @@
|
|
|
1
1
|
import localFont from 'next/font/local';
|
|
2
|
+
// next/font/local cannot set unicode-range per src. Keep the complete core font
|
|
3
|
+
// here; import @bloxwap/font/css/pixel for automatic core subsets instead.
|
|
4
|
+
// The italic face: the same family, not preloaded, so it downloads only when a page renders italic text.
|
|
5
|
+
import './pixel-italic.js';
|
|
2
6
|
|
|
3
7
|
/**
|
|
4
8
|
* Bloxwap Pixel for Next.js: variable weight 100–900 and roundness (set `font-variation-settings: "ROND" 0–100`),
|
|
5
|
-
* with italics; `variable` sets --font-bloxwap-pixel.
|
|
9
|
+
* with italics; `variable` sets --font-bloxwap-pixel. Next.js preloads the normal face; the italic loads only when a
|
|
10
|
+
* page renders italic text.
|
|
6
11
|
*/
|
|
7
12
|
export const BloxwapPixel = localFont({
|
|
8
|
-
src:
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
],
|
|
13
|
+
// No `style` on this src: with a single file next/font copies its style onto className and .style, and a
|
|
14
|
+
// `font-style: normal` there would cancel inherited italics (<em><code className>) and fall back to the normal face.
|
|
15
|
+
src: [{ path: '../fonts/BloxwapPixel/BloxwapPixel-Variable.woff2', weight: '100 900' }],
|
|
12
16
|
variable: '--font-bloxwap-pixel',
|
|
13
17
|
display: 'swap',
|
|
14
18
|
adjustFontFallback: false,
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import localFont from 'next/font/local';
|
|
2
|
+
|
|
3
|
+
// The italic face of Bloxwap Sans, imported for its side effect by ./sans.js. It is a separate next/font call so that it
|
|
4
|
+
// can opt out of preloading: `preload` applies to every file in a call, and a page that never renders italic text
|
|
5
|
+
// would otherwise download the italic as well. Without a preload, the browser fetches this face only when text uses it.
|
|
6
|
+
//
|
|
7
|
+
// From Next.js 15, next/font/local names the family after the const the call is assigned to (Next 13.2-14 hashed it
|
|
8
|
+
// per call, hence the `next >=15` peer range), so this const must stay `BloxwapSans`:
|
|
9
|
+
// that adds the italic to the same family as the normal face in ./sans.js, and <em> gets the real italic, not a
|
|
10
|
+
// synthesized slant.
|
|
11
|
+
const BloxwapSans = localFont({
|
|
12
|
+
src: [{ path: '../fonts/BloxwapSans/BloxwapSans-Italic-Variable.woff2', weight: '100 900', style: 'italic' }],
|
|
13
|
+
display: 'swap',
|
|
14
|
+
preload: false,
|
|
15
|
+
// Like ./sans.js, no metric-adjusted fallback face.
|
|
16
|
+
adjustFontFallback: false,
|
|
17
|
+
});
|
|
18
|
+
|
|
19
|
+
export default BloxwapSans;
|
package/src/sans.d.ts
CHANGED
|
@@ -1,3 +1,7 @@
|
|
|
1
1
|
import type { BloxwapFont } from './font';
|
|
2
2
|
|
|
3
|
+
/**
|
|
4
|
+
* Bloxwap Sans (`next/font/local`): `variable` sets --font-bloxwap-sans. Only the normal face is preloaded; the real
|
|
5
|
+
* italic is in the same family and downloads only when a page renders italic text.
|
|
6
|
+
*/
|
|
3
7
|
export declare const BloxwapSans: BloxwapFont;
|
package/src/sans.js
CHANGED
|
@@ -1,13 +1,19 @@
|
|
|
1
1
|
import localFont from 'next/font/local';
|
|
2
|
+
// next/font/local cannot set unicode-range per src. Keep the complete core font
|
|
3
|
+
// here; import @bloxwap/font/css/sans for automatic core subsets instead.
|
|
2
4
|
// The companion scripts (Arabic, Hebrew, Armenian, Georgian, CJK) as one fallback family with unicode-range.
|
|
3
5
|
import '../sans-scripts.css';
|
|
6
|
+
// The italic face: the same family, not preloaded, so it downloads only when a page renders italic text.
|
|
7
|
+
import './sans-italic.js';
|
|
4
8
|
|
|
5
|
-
/**
|
|
9
|
+
/**
|
|
10
|
+
* Bloxwap Sans for Next.js: variable weight 100–900 with italics; `variable` sets --font-bloxwap-sans.
|
|
11
|
+
* Next.js preloads the normal face; the italic loads only when a page renders italic text.
|
|
12
|
+
*/
|
|
6
13
|
export const BloxwapSans = localFont({
|
|
7
|
-
src:
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
],
|
|
14
|
+
// No `style` on this src: with a single file next/font copies its style onto className and .style, and a
|
|
15
|
+
// `font-style: normal` there would cancel inherited italics (<em><code className>) and fall back to the normal face.
|
|
16
|
+
src: [{ path: '../fonts/BloxwapSans/BloxwapSans-Variable.woff2', weight: '100 900' }],
|
|
11
17
|
variable: '--font-bloxwap-sans',
|
|
12
18
|
display: 'swap',
|
|
13
19
|
// A metric-adjusted Arial fallback would sit before the companions and draw Arabic and Hebrew in Arial.
|