You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit cfccafa
Browse filesBrowse the repository at this point in the historyBrowse files
Copy file name to clipboardExpand all lines: packages/astro/src/assets/fonts/types.ts
+14-14Lines changed: 14 additions & 14 deletions
Original file line number
Diff line number
Diff line change
@@ -59,9 +59,9 @@ export interface FontProvider<
59
59
60
60
exportinterfaceFamilyProperties{
61
61
/**
62
-
* @default `"swap"`
63
-
*
64
62
* Defines [how a font displays](https://developer.mozilla.org/en-US/docs/Web/CSS/@font-face/font-display) based on when it is downloaded and ready for use.
* An array of [font weights](https://developer.mozilla.org/en-US/docs/Web/CSS/font-weight). If no value is specified in your configuration, only weight `400` is
138
136
* included by default to prevent unnecessary downloads. You will need to include this property to access any other font weights.
* An array of [font styles](https://developer.mozilla.org/en-US/docs/Web/CSS/font-style).
149
+
*
150
+
* @default ["normal", "italic"]
151
151
*/
152
152
styles?: [Style, ...Array<Style>]|undefined;
153
153
/**
154
-
* @default `["latin"]`
155
-
*
156
154
* Defines a list of [font subsets](https://knaap.dev/posts/font-subsetting/).
155
+
*
156
+
* @default ["latin"]
157
157
*/
158
158
subsets?: [string, ...Array<string>]|undefined;
159
159
/**
160
-
* @default `["woff2"]`
161
-
*
162
160
* An array of [font formats](https://developer.mozilla.org/en-US/docs/Web/CSS/Reference/At-rules/@font-face/src#font_formats).
* An array of fonts to use when your chosen font is unavailable, or loading. Fallback fonts will be chosen in the order listed. The first available font will be used:
* If the last font in the `fallbacks` array is a [generic family name](https://developer.mozilla.org/en-US/docs/Web/CSS/font-family#generic-name), Astro will attempt to
181
179
* generate [optimized fallbacks](https://developer.chrome.com/blog/font-fallbacks) using font metrics will be generated. To disable this optimization, set `optimizedFallbacks` to false.
180
+
*
181
+
* @default ["sans-serif"]
182
182
*/
183
183
fallbacks?: Array<string>|undefined;
184
184
/**
185
-
* @default `true`
186
-
*
187
185
* Whether or not to enable Astro's default optimization when generating fallback fonts. You may disable this default optimization to have full control over how `fallbacks` are generated.
0 commit comments