CSSFontLoadingAPI
Types
fontDisplay
type fontDisplay = | @as("auto") Auto | @as("block") Block | @as("fallback") Fallback | @as("optional") Optional | @as("swap") Swap
fontFace
type fontFace = { mutable family: string, mutable style: string, mutable weight: string, mutable stretch: string, mutable unicodeRange: string, mutable featureSettings: string, mutable display: fontDisplay, mutable ascentOverride: string, mutable descentOverride: string, mutable lineGapOverride: string, status: fontFaceLoadStatus, loaded: promise<fontFace>,}
Record fields
Module
There are methods and helpers defined in FontFace .
fontFaceDescriptors
type fontFaceDescriptors = { mutable style?: string, mutable weight?: string, mutable stretch?: string, mutable unicodeRange?: string, mutable featureSettings?: string, mutable display?: fontDisplay, mutable ascentOverride?: string, mutable descentOverride?: string, mutable lineGapOverride?: string,}
Record fields
style
option< string >
weight
option< string >
stretch
option< string >
unicodeRange
option< string >
featureSettings
option< string >
display
option< fontDisplay >
ascentOverride
option< string >
descentOverride
option< string >
lineGapOverride
option< string >
fontFaceLoadStatus
type fontFaceLoadStatus = | @as("error") Error | @as("loaded") Loaded | @as("loading") Loading | @as("unloaded") Unloaded
fontFaceSet
type fontFaceSet = { ready: promise<fontFaceSet>, status: fontFaceSetLoadStatus,}
Record fields
Module
There are methods and helpers defined in FontFaceSet .
fontFaceSetLoadStatus
type fontFaceSetLoadStatus = | @as("loaded") Loaded | @as("loading") Loading