Skip to content

Commit

Permalink
Merge pull request #622 from nextcloud/stable10-fix-searchbox-background
Browse files Browse the repository at this point in the history
[stable10] fix searchbox background
  • Loading branch information
MorrisJobke authored Jul 28, 2016
2 parents e184e4a + c9b4a2b commit b1830b7
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 7 deletions.
4 changes: 2 additions & 2 deletions apps/theming/lib/controller/themingcontroller.php
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ public function __construct(
IRootFolder $rootFolder
) {
parent::__construct($appName, $request);

$this->template = $template;
$this->l = $l;
$this->config = $config;
Expand Down Expand Up @@ -216,7 +216,7 @@ public function getStylesheet() {
$color = $this->config->getAppValue($this->appName, 'color');
if($color !== '') {
$responseCss .= sprintf(
'#body-user #header,#body-settings #header,#body-public #header {background-color: %s}',
'#body-user #header,#body-settings #header,#body-public #header,#body-login,.searchbox input[type="search"]:focus,.searchbox input[type="search"]:active,.searchbox input[type="search"]:valid {background-color: %s}',
$color
);
}
Expand Down
8 changes: 4 additions & 4 deletions apps/theming/tests/lib/controller/ThemingControllerTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -327,7 +327,7 @@ public function testGetStylesheetWithOnlyColor() {
->with('theming', 'backgroundMime', '')
->willReturn('');

$expected = new Http\DataDownloadResponse('#body-user #header,#body-settings #header,#body-public #header {background-color: #000}', 'style', 'text/css');
$expected = new Http\DataDownloadResponse('#body-user #header,#body-settings #header,#body-public #header,#body-login,.searchbox input[type="search"]:focus,.searchbox input[type="search"]:active,.searchbox input[type="search"]:valid {background-color: #000}', 'style', 'text/css');
$expected->cacheFor(3600);
@$this->assertEquals($expected, $this->themingController->getStylesheet());
}
Expand All @@ -354,7 +354,7 @@ public function testGetStylesheetWithOnlyColorInvert() {
->with('theming', 'backgroundMime', '')
->willReturn('');

$expected = new Http\DataDownloadResponse('#body-user #header,#body-settings #header,#body-public #header {background-color: #fff}#header .header-appname, #expandDisplayName { color: #000000; } #header .icon-caret { background-image: url(\'' . \OC::$WEBROOT . '/core/img/actions/caret-dark.svg\'); } .searchbox input[type="search"] { background: transparent url(\'' . \OC::$WEBROOT . '/core/img/actions/search.svg\') no-repeat 6px center; color: #000; }.searchbox input[type="search"]:focus,.searchbox input[type="search"]:active,.searchbox input[type="search"]:valid { color: #000; border: 1px solid rgba(0, 0, 0, .5); }', 'style', 'text/css');
$expected = new Http\DataDownloadResponse('#body-user #header,#body-settings #header,#body-public #header,#body-login,.searchbox input[type="search"]:focus,.searchbox input[type="search"]:active,.searchbox input[type="search"]:valid {background-color: #fff}#header .header-appname, #expandDisplayName { color: #000000; } #header .icon-caret { background-image: url(\'' . \OC::$WEBROOT . '/core/img/actions/caret-dark.svg\'); } .searchbox input[type="search"] { background: transparent url(\'' . \OC::$WEBROOT . '/core/img/actions/search.svg\') no-repeat 6px center; color: #000; }.searchbox input[type="search"]:focus,.searchbox input[type="search"]:active,.searchbox input[type="search"]:valid { color: #000; border: 1px solid rgba(0, 0, 0, .5); }', 'style', 'text/css');
$expected->cacheFor(3600);
@$this->assertEquals($expected, $this->themingController->getStylesheet());
}
Expand Down Expand Up @@ -444,7 +444,7 @@ public function testGetStylesheetWithAllCombined() {
->with('theming', 'backgroundMime', '')
->willReturn('image/png');

$expected = new Http\DataDownloadResponse('#body-user #header,#body-settings #header,#body-public #header {background-color: #000}#header .logo {
$expected = new Http\DataDownloadResponse('#body-user #header,#body-settings #header,#body-public #header,#body-login,.searchbox input[type="search"]:focus,.searchbox input[type="search"]:active,.searchbox input[type="search"]:valid {background-color: #000}#header .logo {
background-image: url(\'./logo?v=0\');
background-size: contain;
}
Expand Down Expand Up @@ -479,7 +479,7 @@ public function testGetStylesheetWithAllCombinedInverted() {
->with('theming', 'backgroundMime', '')
->willReturn('image/png');

$expected = new Http\DataDownloadResponse('#body-user #header,#body-settings #header,#body-public #header {background-color: #fff}#header .logo {
$expected = new Http\DataDownloadResponse('#body-user #header,#body-settings #header,#body-public #header,#body-login,.searchbox input[type="search"]:focus,.searchbox input[type="search"]:active,.searchbox input[type="search"]:valid {background-color: #fff}#header .logo {
background-image: url(\'./logo?v=0\');
background-size: contain;
}
Expand Down
2 changes: 1 addition & 1 deletion core/css/styles.css
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ a.two-factor-cancel {
width: 155px;
max-width: 50%;
cursor: text;
background-color: transparent;
background-color: #0082c9;
border: 1px solid rgba(255, 255, 255, .5);
}

Expand Down

0 comments on commit b1830b7

Please sign in to comment.