mirror of
https://github.com/gristlabs/grist-core.git
synced 2026-03-02 04:09:24 +00:00
(core) Add dark mode CSS for Swagger UI
Summary: Adds CSS to support dark mode in Swagger UI. Test Plan: Manual. Reviewers: jarek Reviewed By: jarek Differential Revision: https://phab.getgrist.com/D4199
This commit is contained in:
@@ -16,7 +16,12 @@ import type SwaggerUI from 'swagger-ui';
|
||||
* We load dynamically only to avoid maintaining a separate html file ust for these tags.
|
||||
*/
|
||||
function loadExternal() {
|
||||
return Promise.all([loadScript('swagger-ui-bundle.js'), loadCssFile('swagger-ui.css')]);
|
||||
return Promise.all([
|
||||
loadScript('swagger-ui-bundle.js'),
|
||||
loadCssFile('swagger-ui.css'),
|
||||
// Stylesheet that's only applied when prefers-color-scheme is dark.
|
||||
loadCssFile('swagger-ui-dark.css'),
|
||||
]);
|
||||
}
|
||||
|
||||
// Start loading scripts early (before waiting for AppModel to get initialized).
|
||||
|
||||
Reference in New Issue
Block a user