diff --git a/locales/index.d.ts b/locales/index.d.ts index 4171a41f17..9f285f08f1 100644 --- a/locales/index.d.ts +++ b/locales/index.d.ts @@ -13451,6 +13451,10 @@ export interface Locale extends ILocale { * Custom font size */ "customFontSize": string; + /** + * Hide ads + */ + "hideAds": string; } declare const locales: { [lang: string]: Locale; diff --git a/packages/frontend/src/pages/settings/preferences.vue b/packages/frontend/src/pages/settings/preferences.vue index 1c8e418182..7467439269 100644 --- a/packages/frontend/src/pages/settings/preferences.vue +++ b/packages/frontend/src/pages/settings/preferences.vue @@ -913,10 +913,10 @@ SPDX-License-Identifier: AGPL-3.0-only - + - - + + @@ -1097,6 +1097,9 @@ const trustedDomains = prefer.model( (domainsString) => domainsString.split('\n').map( d => d.trim() ).filter( x => x.length > 0), ); +// Inverted to map between "hide ads" and "force show ads" +const hideAds = prefer.model('forceShowAds', x => !x, x => !x); + watch([ hemisphere, enableInfiniteScroll, diff --git a/sharkey-locales/en-US.yml b/sharkey-locales/en-US.yml index 67d0ec694c..7218086426 100644 --- a/sharkey-locales/en-US.yml +++ b/sharkey-locales/en-US.yml @@ -675,3 +675,5 @@ clearCachedFilesOptions: keepFilesInUseDescription: "this option requires more complicated database queries, you may need to increase the value of db.extra.statement_timeout in the configuration file" customFontSize: "Custom font size" + +hideAds: "Hide ads"