fix: build EB Garamond from fontsource instead of Bunny (MAN-139)
Vite was fetching fonts.bunny.net at build time; the feature CI job timed out on that host. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
11
package-lock.json
generated
11
package-lock.json
generated
@@ -5,6 +5,7 @@
|
|||||||
"packages": {
|
"packages": {
|
||||||
"": {
|
"": {
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
|
"@fontsource/eb-garamond": "^5.2.7",
|
||||||
"@tailwindcss/vite": "^4.0.0",
|
"@tailwindcss/vite": "^4.0.0",
|
||||||
"concurrently": "^9.0.1",
|
"concurrently": "^9.0.1",
|
||||||
"daisyui": "^5.7.16",
|
"daisyui": "^5.7.16",
|
||||||
@@ -49,6 +50,16 @@
|
|||||||
"tslib": "^2.4.0"
|
"tslib": "^2.4.0"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
"node_modules/@fontsource/eb-garamond": {
|
||||||
|
"version": "5.3.0",
|
||||||
|
"resolved": "https://registry.npmjs.org/@fontsource/eb-garamond/-/eb-garamond-5.3.0.tgz",
|
||||||
|
"integrity": "sha512-VplwHpB8FLuzl+4G5LDci1b3Z4SghiuXH8XEgaxjnOb5aue5mEt1njmDKeO6iyLeGa73LffU7PC7hzncLRx0ZA==",
|
||||||
|
"dev": true,
|
||||||
|
"license": "OFL-1.1",
|
||||||
|
"funding": {
|
||||||
|
"url": "https://github.com/sponsors/ayuhito"
|
||||||
|
}
|
||||||
|
},
|
||||||
"node_modules/@jridgewell/gen-mapping": {
|
"node_modules/@jridgewell/gen-mapping": {
|
||||||
"version": "0.3.13",
|
"version": "0.3.13",
|
||||||
"resolved": "https://registry.npmjs.org/@jridgewell/gen-mapping/-/gen-mapping-0.3.13.tgz",
|
"resolved": "https://registry.npmjs.org/@jridgewell/gen-mapping/-/gen-mapping-0.3.13.tgz",
|
||||||
|
|||||||
@@ -8,6 +8,7 @@
|
|||||||
"prepare": "husky"
|
"prepare": "husky"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
|
"@fontsource/eb-garamond": "^5.2.7",
|
||||||
"@tailwindcss/vite": "^4.0.0",
|
"@tailwindcss/vite": "^4.0.0",
|
||||||
"concurrently": "^9.0.1",
|
"concurrently": "^9.0.1",
|
||||||
"daisyui": "^5.7.16",
|
"daisyui": "^5.7.16",
|
||||||
|
|||||||
@@ -72,7 +72,9 @@ class HeritageEditorialTokensTest extends TestCase
|
|||||||
{
|
{
|
||||||
$vite = (string) file_get_contents(base_path('vite.config.js'));
|
$vite = (string) file_get_contents(base_path('vite.config.js'));
|
||||||
|
|
||||||
$this->assertStringContainsString("bunny('EB Garamond'", $vite);
|
$this->assertStringContainsString("fontsource('EB Garamond'", $vite);
|
||||||
|
$this->assertStringNotContainsString("bunny(", $vite);
|
||||||
|
$this->assertStringNotContainsString('google(', $vite);
|
||||||
$this->assertStringNotContainsString('Instrument Sans', $vite);
|
$this->assertStringNotContainsString('Instrument Sans', $vite);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
import { defineConfig } from 'vite';
|
import { defineConfig } from 'vite';
|
||||||
import laravel from 'laravel-vite-plugin';
|
import laravel from 'laravel-vite-plugin';
|
||||||
import { bunny } from 'laravel-vite-plugin/fonts';
|
import { fontsource } from 'laravel-vite-plugin/fonts';
|
||||||
import tailwindcss from '@tailwindcss/vite';
|
import tailwindcss from '@tailwindcss/vite';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -76,7 +76,9 @@ export default defineConfig({
|
|||||||
],
|
],
|
||||||
refresh: true,
|
refresh: true,
|
||||||
fonts: [
|
fonts: [
|
||||||
bunny('EB Garamond', {
|
// fontsource reads node_modules so `vite build` stays offline.
|
||||||
|
// bunny() timed out on fonts.bunny.net in CI (run 31, job feature).
|
||||||
|
fontsource('EB Garamond', {
|
||||||
weights: [400, 500, 600],
|
weights: [400, 500, 600],
|
||||||
}),
|
}),
|
||||||
],
|
],
|
||||||
|
|||||||
Reference in New Issue
Block a user