From b6501ae966582047a65b22b93f45c5bab049426d Mon Sep 17 00:00:00 2001 From: Julius Härtl Date: Mon, 26 Mar 2018 18:20:18 +0200 Subject: Show UI when using a custom theme MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Do not hide the theming app UI when using a custom theme besides it, but warn the users about some settings being overwritten by that. Signed-off-by: Julius Härtl --- apps/theming/lib/Settings/Admin.php | 2 +- apps/theming/templates/settings-admin.php | 3 +-- apps/theming/tests/Settings/AdminTest.php | 6 +++--- 3 files changed, 5 insertions(+), 6 deletions(-) (limited to 'apps/theming') diff --git a/apps/theming/lib/Settings/Admin.php b/apps/theming/lib/Settings/Admin.php index 708bf1914ea..d26a5680637 100644 --- a/apps/theming/lib/Settings/Admin.php +++ b/apps/theming/lib/Settings/Admin.php @@ -67,7 +67,7 @@ class Admin implements ISettings { $theme = $this->config->getSystemValue('theme', ''); if ($theme !== '') { $themable = false; - $errorMessage = $this->l->t('You are already using a custom theme'); + $errorMessage = $this->l->t('You are already using a custom theme. Theming app settings might be overwritten by that.'); } $parameters = [ diff --git a/apps/theming/templates/settings-admin.php b/apps/theming/templates/settings-admin.php index 1dfa5cdc1db..7e489199927 100644 --- a/apps/theming/templates/settings-admin.php +++ b/apps/theming/templates/settings-admin.php @@ -37,7 +37,7 @@ style('theming', 'settings-admin');

- +
- diff --git a/apps/theming/tests/Settings/AdminTest.php b/apps/theming/tests/Settings/AdminTest.php index bb68651d143..ee49cf0f1f6 100644 --- a/apps/theming/tests/Settings/AdminTest.php +++ b/apps/theming/tests/Settings/AdminTest.php @@ -118,8 +118,8 @@ class AdminTest extends TestCase { $this->l10n ->expects($this->once()) ->method('t') - ->with('You are already using a custom theme') - ->willReturn('You are already using a custom theme'); + ->with('You are already using a custom theme. Theming app settings might be overwritten by that.') + ->willReturn('You are already using a custom theme. Theming app settings might be overwritten by that.'); $this->themingDefaults ->expects($this->once()) ->method('getEntity') @@ -143,7 +143,7 @@ class AdminTest extends TestCase { ->willReturn('/my/route'); $params = [ 'themable' => false, - 'errorMessage' => 'You are already using a custom theme', + 'errorMessage' => 'You are already using a custom theme. Theming app settings might be overwritten by that.', 'name' => 'MyEntity', 'url' => 'https://example.com', 'slogan' => 'MySlogan', -- cgit v1.2.3