@wippy-fe/types-global-proxy 0.0.41 → 0.0.43
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/index.d.ts +54 -0
- package/package.json +1 -1
package/index.d.ts
CHANGED
|
@@ -410,9 +410,61 @@ interface AppAuthConfig {
|
|
|
410
410
|
token: string;
|
|
411
411
|
expiresAt: string;
|
|
412
412
|
}
|
|
413
|
+
/** One @font-face source file for a `faces`-sourced font. */
|
|
414
|
+
interface FontFaceDef {
|
|
415
|
+
/** Font file URL (woff2 preferred). */
|
|
416
|
+
url: string;
|
|
417
|
+
/** Format hint for the src descriptor, e.g. 'woff2'. */
|
|
418
|
+
format?: string;
|
|
419
|
+
/** font-weight descriptor — single ('600') or variable range ('100 900'). */
|
|
420
|
+
weight?: string;
|
|
421
|
+
/** font-style descriptor, e.g. 'italic'. */
|
|
422
|
+
style?: string;
|
|
423
|
+
unicodeRange?: string;
|
|
424
|
+
}
|
|
425
|
+
/**
|
|
426
|
+
* Declarative font loading + per-font metric control. Compiled host-side by
|
|
427
|
+
* `buildFontCss()` and folded into the distributed customCSS, so child iframes
|
|
428
|
+
* of any version apply it with no client-side support. @font-face is
|
|
429
|
+
* document-scoped: shadow-root content (web components) inherits usable
|
|
430
|
+
* families from its document automatically.
|
|
431
|
+
*/
|
|
432
|
+
interface FontConfig {
|
|
433
|
+
/** Family name, as later used by font-family / the role vars. */
|
|
434
|
+
family: string;
|
|
435
|
+
/**
|
|
436
|
+
* 'google' — load via the Google Fonts css2 API, keeping only `weights`;
|
|
437
|
+
* 'faces' — declare @font-face rules from `faces` (required for the
|
|
438
|
+
* metric-override descriptors below).
|
|
439
|
+
*/
|
|
440
|
+
source: 'google' | 'faces';
|
|
441
|
+
/** For 'google': the weights to KEEP (all others are dropped from the request). */
|
|
442
|
+
weights?: number[];
|
|
443
|
+
/** For 'google': also request italics for the kept weights. */
|
|
444
|
+
italics?: boolean;
|
|
445
|
+
/** font-display for the css2 request / generated faces. Default 'swap'. */
|
|
446
|
+
display?: 'auto' | 'block' | 'swap' | 'fallback' | 'optional';
|
|
447
|
+
/** For 'faces': the font files to declare. */
|
|
448
|
+
faces?: FontFaceDef[];
|
|
449
|
+
/** 'faces' only — horizontal footprint: scales every glyph, e.g. '95%'. */
|
|
450
|
+
sizeAdjust?: string;
|
|
451
|
+
/** 'faces' only — vertical position of text within the line box, e.g. '90%'. */
|
|
452
|
+
ascentOverride?: string;
|
|
453
|
+
/** 'faces' only. */
|
|
454
|
+
descentOverride?: string;
|
|
455
|
+
/** 'faces' only. */
|
|
456
|
+
lineGapOverride?: string;
|
|
457
|
+
/**
|
|
458
|
+
* Assign the family to font roles: sets --p-font-<role>-family (and, for
|
|
459
|
+
* 'body', an applying rule — body text has no default token consumer).
|
|
460
|
+
*/
|
|
461
|
+
roles?: Array<'heading' | 'body' | 'mono'>;
|
|
462
|
+
}
|
|
413
463
|
interface ThemingScope {
|
|
414
464
|
cssVariables?: CssVariablesMap;
|
|
415
465
|
customCSS?: string;
|
|
466
|
+
/** Declarative font loading; compiled into customCSS at distribution time. */
|
|
467
|
+
fonts?: FontConfig[];
|
|
416
468
|
/** @deprecated Use `iconSets` instead */
|
|
417
469
|
icons?: Record<string, IconDef>;
|
|
418
470
|
/** Named icon collections. Each key is an Iconify prefix. */
|
|
@@ -424,6 +476,8 @@ interface HostThemingScope extends ThemingScope {
|
|
|
424
476
|
interface ChildrenThemingScope {
|
|
425
477
|
cssVariables?: CssVariablesMap;
|
|
426
478
|
customCSS?: string;
|
|
479
|
+
/** Declarative font loading; compiled into customCSS at distribution time. */
|
|
480
|
+
fonts?: FontConfig[];
|
|
427
481
|
}
|
|
428
482
|
interface AppCustomization {
|
|
429
483
|
customCSS?: string;
|
package/package.json
CHANGED