diff --git a/ext/js/app/theme-controller.js b/ext/js/app/theme-controller.js index 44ff723b55..711ddfdb6c 100644 --- a/ext/js/app/theme-controller.js +++ b/ext/js/app/theme-controller.js @@ -27,9 +27,9 @@ export class ThemeController { constructor(element) { /** @type {?HTMLElement} */ this._element = element; - /** @type {'light'|'dark'|'browser'|'site'} */ + /** @type {import("settings.js").PopupTheme} */ this._theme = 'site'; - /** @type {'light'|'dark'|'browser'|'site'} */ + /** @type {import("settings.js").PopupOuterTheme} */ this._outerTheme = 'site'; /** @type {?('dark'|'light')} */ this._siteTheme = null; @@ -57,7 +57,7 @@ export class ThemeController { /** * Gets the main theme for the content. - * @type {'light'|'dark'|'browser'|'site'} + * @type {import("settings.js").PopupTheme} */ get theme() { return this._theme; @@ -65,7 +65,7 @@ export class ThemeController { /** * Sets the main theme for the content. - * @param {'light'|'dark'|'browser'|'site'} value The theme value to assign. + * @param {import("settings.js").PopupTheme} value The theme value to assign. */ set theme(value) { this._theme = value; @@ -73,7 +73,7 @@ export class ThemeController { /** * Gets the outer theme for the content. - * @type {'light'|'dark'|'browser'|'site'} + * @type {import("settings.js").PopupOuterTheme} */ get outerTheme() { return this._outerTheme; @@ -81,7 +81,7 @@ export class ThemeController { /** * Sets the outer theme for the content. - * @param {'light'|'dark'|'browser'|'site'} value The outer theme value to assign. + * @param {import("settings.js").PopupOuterTheme} value The outer theme value to assign. */ set outerTheme(value) { this._outerTheme = value; diff --git a/ext/settings.html b/ext/settings.html index 3df2e1b235..dc751d9292 100644 --- a/ext/settings.html +++ b/ext/settings.html @@ -764,6 +764,7 @@

Yomitan Settings

+ diff --git a/types/ext/settings.d.ts b/types/ext/settings.d.ts index c29c47f0e4..1dad74db16 100644 --- a/types/ext/settings.d.ts +++ b/types/ext/settings.d.ts @@ -371,9 +371,9 @@ export type PopupVerticalTextPosition = 'default' | 'before' | 'after' | 'left' export type GlossaryLayoutMode = 'default' | 'compact'; -export type PopupTheme = 'light' | 'dark' | 'browser'; +export type PopupTheme = 'light' | 'dark' | 'browser' | 'site'; -export type PopupOuterTheme = 'light' | 'dark' | 'browser' | 'site'; +export type PopupOuterTheme = 'light' | 'dark' | 'browser' | 'site' | 'none'; export type PopupCurrentIndicatorMode = 'none' | 'asterisk' | 'triangle' | 'bar-left' | 'bar-right' | 'dot-left' | 'dot-right';