UserPreferencesManager
See source codeTable of contents
class UserPreferencesManager {}
Constructor
Constructs a new instance of the UserPreferencesManager
class
Parameters
Name | Description |
---|---|
| |
|
|
Properties
disposables
disposables: Set<() => void>
systemColorScheme
systemColorScheme: import('@tldraw/state').Atom<'dark' | 'light', unknown>
Methods
dispose( )
dispose(): void
getAnimationSpeed( )
getAnimationSpeed(): number
getAreKeyboardShortcutsEnabled( )
getAreKeyboardShortcutsEnabled(): boolean
getColor( )
getColor(): string
getEdgeScrollSpeed( )
The speed at which the user can scroll by dragging toward the edge of the screen.
getEdgeScrollSpeed(): number
getEnhancedA11yMode( )
getEnhancedA11yMode(): boolean
getId( )
getId(): string
getInputMode( )
getInputMode(): 'mouse' | 'trackpad' | null
getIsDarkMode( )
getIsDarkMode(): boolean
getIsDynamicResizeMode( )
getIsDynamicResizeMode(): boolean
getIsPasteAtCursorMode( )
getIsPasteAtCursorMode(): boolean
getIsSnapMode( )
getIsSnapMode(): boolean
getIsWrapMode( )
getIsWrapMode(): boolean
getLocale( )
getLocale(): string
getName( )
getName(): string
getUserPreferences( )
getUserPreferences(): {
animationSpeed: number
areKeyboardShortcutsEnabled: boolean
color: string
colorScheme: 'dark' | 'light' | 'system' | undefined
enhancedA11yMode: boolean
id: string
inputMode: 'mouse' | 'trackpad' | null
isDarkMode: boolean
isDynamicResizeMode: boolean
isSnapMode: boolean
isWrapMode: boolean
locale: string
name: string
}
updateUserPreferences( )
updateUserPreferences(userPreferences: Partial<TLUserPreferences>): void
Parameters
Name | Description |
---|---|
|
|
Returns
void
Prev
TransformedGeometry2dNext
Vec