@scalar/api-client
Version:
the open source API testing client
16 lines • 717 B
TypeScript
/**
* Applies a custom Scalar theme to the Monaco editor.
*
* This function loads CSS variables for either dark or light mode, maps the colors to Monaco's editor theme keys,
* and then applies the new theme. Theme color tokens are resolved from CSS custom properties.
*
* Example usage:
*
* await applyScalarTheme('scalar', true); // Apply dark mode
* await applyScalarTheme('scalar', false); // Apply light mode
*
* @param theme - The theme string key to load variables for (e.g. 'scalar').
* @param isDarkMode - Whether to use dark or light variables.
*/
export declare const applyScalarTheme: (theme: string, isDarkMode: boolean) => Promise<void>;
//# sourceMappingURL=apply-scalar-theme.d.ts.map