summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSimon L <szaimen@e.mail.de>2022-09-28 20:35:07 +0200
committerGitHub <noreply@github.com>2022-09-28 20:35:07 +0200
commitfafc1ee8076fe4124c50869b0a7422896666931d (patch)
treef8007c4d7aa91a08d92755229547697b1d49caa4
parent1aa76e5968d8881daa4b9e72c0b9b0d4966ef934 (diff)
parentc9a372034f9aafcc074ac6b34d2af264c3f58ee4 (diff)
downloadnextcloud-server-fafc1ee8076fe4124c50869b0a7422896666931d.tar.gz
nextcloud-server-fafc1ee8076fe4124c50869b0a7422896666931d.zip
Merge pull request #34287 from nextcloud/enh/33836/fix-theme
fix highcontrast theme
-rw-r--r--apps/theming/lib/Themes/HighContrastTheme.php2
-rw-r--r--apps/theming/tests/Controller/UserThemeControllerTest.php4
-rw-r--r--apps/theming/tests/Service/ThemesServiceTest.php10
-rw-r--r--apps/theming/tests/Settings/PersonalTest.php4
4 files changed, 10 insertions, 10 deletions
diff --git a/apps/theming/lib/Themes/HighContrastTheme.php b/apps/theming/lib/Themes/HighContrastTheme.php
index c7d3b2e8c7f..fda02058446 100644
--- a/apps/theming/lib/Themes/HighContrastTheme.php
+++ b/apps/theming/lib/Themes/HighContrastTheme.php
@@ -29,7 +29,7 @@ use OCA\Theming\ITheme;
class HighContrastTheme extends DefaultTheme implements ITheme {
public function getId(): string {
- return 'highcontrast';
+ return 'light-highcontrast';
}
public function getMediaQuery(): string {
diff --git a/apps/theming/tests/Controller/UserThemeControllerTest.php b/apps/theming/tests/Controller/UserThemeControllerTest.php
index ffacf5108a5..a6f73a087fc 100644
--- a/apps/theming/tests/Controller/UserThemeControllerTest.php
+++ b/apps/theming/tests/Controller/UserThemeControllerTest.php
@@ -72,7 +72,7 @@ class UserThemeControllerTest extends TestCase {
'default' => $this->createMock(DefaultTheme::class),
'light' => $this->createMock(LightTheme::class),
'dark' => $this->createMock(DarkTheme::class),
- 'highcontrast' => $this->createMock(HighContrastTheme::class),
+ 'light-highcontrast' => $this->createMock(HighContrastTheme::class),
'dark-highcontrast' => $this->createMock(DarkHighContrastTheme::class),
'opendyslexic' => $this->createMock(DyslexiaFont::class),
];
@@ -102,7 +102,7 @@ class UserThemeControllerTest extends TestCase {
['default'],
['light'],
['dark'],
- ['highcontrast'],
+ ['light-highcontrast'],
['dark-highcontrast'],
['opendyslexic'],
['', OCSBadRequestException::class],
diff --git a/apps/theming/tests/Service/ThemesServiceTest.php b/apps/theming/tests/Service/ThemesServiceTest.php
index 90816ae2328..3be8881669a 100644
--- a/apps/theming/tests/Service/ThemesServiceTest.php
+++ b/apps/theming/tests/Service/ThemesServiceTest.php
@@ -84,7 +84,7 @@ class ThemesServiceTest extends TestCase {
'default',
'light',
'dark',
- 'highcontrast',
+ 'light-highcontrast',
'dark-highcontrast',
'opendyslexic',
];
@@ -98,7 +98,7 @@ class ThemesServiceTest extends TestCase {
['dark', [], ['dark']],
['dark', ['dark'], ['dark']],
['opendyslexic', ['dark'], ['dark', 'opendyslexic']],
- ['dark', ['highcontrast', 'opendyslexic'], ['opendyslexic', 'dark']],
+ ['dark', ['light-highcontrast', 'opendyslexic'], ['opendyslexic', 'dark']],
];
}
@@ -132,7 +132,7 @@ class ThemesServiceTest extends TestCase {
['dark', [], []],
['dark', ['dark'], []],
['opendyslexic', ['dark', 'opendyslexic'], ['dark'], ],
- ['highcontrast', ['opendyslexic'], ['opendyslexic']],
+ ['light-highcontrast', ['opendyslexic'], ['opendyslexic']],
];
}
@@ -167,7 +167,7 @@ class ThemesServiceTest extends TestCase {
['dark', [], false],
['dark', ['dark'], true],
['opendyslexic', ['dark', 'opendyslexic'], true],
- ['highcontrast', ['opendyslexic'], false],
+ ['light-highcontrast', ['opendyslexic'], false],
];
}
@@ -302,7 +302,7 @@ class ThemesServiceTest extends TestCase {
$this->config,
$l10n,
),
- 'highcontrast' => new HighContrastTheme(
+ 'light-highcontrast' => new HighContrastTheme(
$util,
$this->themingDefaults,
$urlGenerator,
diff --git a/apps/theming/tests/Settings/PersonalTest.php b/apps/theming/tests/Settings/PersonalTest.php
index 3051a210353..8e121c0a057 100644
--- a/apps/theming/tests/Settings/PersonalTest.php
+++ b/apps/theming/tests/Settings/PersonalTest.php
@@ -83,7 +83,7 @@ class PersonalTest extends TestCase {
$this->formatThemeForm('default'),
$this->formatThemeForm('light'),
$this->formatThemeForm('dark'),
- $this->formatThemeForm('highcontrast'),
+ $this->formatThemeForm('light-highcontrast'),
$this->formatThemeForm('dark-highcontrast'),
$this->formatThemeForm('opendyslexic'),
]],
@@ -162,7 +162,7 @@ class PersonalTest extends TestCase {
$config,
$l10n,
),
- 'highcontrast' => new HighContrastTheme(
+ 'light-highcontrast' => new HighContrastTheme(
$util,
$themingDefaults,
$urlGenerator,