Skip to content

Commit 625bdf0

Browse files
authored
Merge pull request #9912 from nextcloud/search-standard
New search standard and user search
2 parents 7fdba6f + 259f70d commit 625bdf0

File tree

17 files changed

+718
-531
lines changed

17 files changed

+718
-531
lines changed

.drone.yml

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -20,14 +20,14 @@ pipeline:
2020
- ./build/vue-builds.sh ./settings/js/settings-vue.js
2121
when:
2222
matrix:
23-
TESTS: vue-builds
23+
TESTS: vue-build-settings
2424
vue-build-updatenotification:
2525
image: node
2626
commands:
2727
- ./build/vue-builds.sh ./apps/updatenotification/js/merged.js
2828
when:
2929
matrix:
30-
TESTS: vue-builds
30+
TESTS: vue-build-updatenotification
3131
checkers:
3232
image: nextcloudci/php7.0:php7.0-19
3333
commands:
@@ -683,7 +683,8 @@ pipeline:
683683
matrix:
684684
include:
685685
- TESTS: checkers
686-
- TESTS: vue-builds
686+
- TESTS: vue-build-settings
687+
- TESTS: vue-build-updatenotification
687688
- TESTS: nodb-codecov
688689
ENABLE_REDIS: true
689690
- TESTS: db-codecov

apps/files/css/files.scss

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -603,7 +603,7 @@ table tr.summary td {
603603
padding-top: 20px;
604604
}
605605
.summary .info {
606-
margin-left: 40px;
606+
margin-left: 35px; /* td has padding of 15, col width is 50 */
607607
}
608608

609609
table.dragshadow {

apps/files/js/search.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -139,7 +139,7 @@
139139
this.fileList = fileList;
140140
};
141141

142-
OC.Plugins.register('OCA.Search', this);
142+
OC.Plugins.register('OCA.Search.Core', this);
143143
},
144144
attach: function(search) {
145145
var self = this;

core/css/styles.scss

Lines changed: 25 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -299,32 +299,35 @@ body {
299299
overflow-x: auto;
300300
}
301301

302-
#emptycontent, .emptycontent {
302+
/* EMPTY CONTENT DISPLAY ------------------------------------------------------------ */
303+
304+
#emptycontent,
305+
.emptycontent {
303306
color: nc-lighten($color-main-text, 53%);
304307
text-align: center;
305308
margin-top: 30vh;
306309
width: 100%;
307-
}
308-
309-
#app-sidebar #emptycontent, #app-sidebar .emptycontent {
310-
margin-top: 10vh;
311-
}
312-
313-
#emptycontent.emptycontent-search, .emptycontent.emptycontent-search {
314-
position: static;
315-
}
316-
317-
#emptycontent h2, .emptycontent h2 {
318-
margin-bottom: 10px;
319-
line-height: 150%;
320-
}
321-
322-
#emptycontent [class^='icon-'], .emptycontent [class^='icon-'], #emptycontent [class*=' icon-'], .emptycontent [class*=' icon-'] {
323-
background-size: 64px;
324-
height: 64px;
325-
width: 64px;
326-
margin: 0 auto 15px;
327-
opacity: .4;
310+
#app-sidebar & {
311+
margin-top: 10vh;
312+
}
313+
.emptycontent-search {
314+
position: static;
315+
}
316+
h2 {
317+
margin-bottom: 10px;
318+
line-height: 150%;
319+
}
320+
[class^='icon-'],
321+
[class*='icon-'] {
322+
background-size: 64px;
323+
height: 64px;
324+
width: 64px;
325+
margin: 0 auto 15px;
326+
&:not([class^='icon-loading']),
327+
&:not([class*='icon-loading']) {
328+
opacity: .4;
329+
}
330+
}
328331
}
329332

330333
/* LOG IN & INSTALLATION ------------------------------------------------------------ */
Lines changed: 1 addition & 1 deletion
Loading

core/search/css/results.css

Lines changed: 0 additions & 105 deletions
This file was deleted.

core/search/css/results.scss

Lines changed: 102 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,102 @@
1+
/*
2+
* @copyright Copyright (c) 2018 Jan-Christoph Borchardt <hey@jancborchardt.net>
3+
*
4+
* @author John Molakvoæ <skjnldsv@protonmail.com>
5+
* @author Jan-Christoph Borchardt <hey@jancborchardt.net>
6+
*
7+
* @license GNU AGPL version 3 or any later version
8+
*
9+
* This program is free software: you can redistribute it and/or modify
10+
* it under the terms of the GNU Affero General Public License as
11+
* published by the Free Software Foundation, either version 3 of the
12+
* License, or (at your option) any later version.
13+
*
14+
* This program is distributed in the hope that it will be useful,
15+
* but WITHOUT ANY WARRANTY; without even the implied warranty of
16+
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17+
* GNU Affero General Public License for more details.
18+
*
19+
* You should have received a copy of the GNU Affero General Public License
20+
* along with this program. If not, see <http://www.gnu.org/licenses/>.
21+
*
22+
*/
23+
24+
#searchresults {
25+
overflow-x: hidden;
26+
text-overflow: ellipsis;
27+
padding-top: 51px; /* table row is 51px height */
28+
box-sizing: border-box;
29+
z-index: 75;
30+
/* account for margin-bottom in files list */
31+
margin-top: -250px;
32+
table {
33+
border-spacing: 0;
34+
table-layout: fixed;
35+
top: 0;
36+
width: 100%;
37+
}
38+
tr {
39+
&.result {
40+
border-bottom: 1px solid $color-border;
41+
* {
42+
cursor: pointer;
43+
}
44+
}
45+
&.template {
46+
display: none;
47+
}
48+
&:hover,
49+
&.current {
50+
background-color: nc-darken($color-main-background, 3%);
51+
}
52+
td {
53+
padding: 5px 9px;
54+
font-style: normal;
55+
vertical-align: middle;
56+
border-bottom: none;
57+
&.icon {
58+
text-align: right;
59+
width: 40px;
60+
height: 40px;
61+
padding: 5px 0;
62+
background-position: right center;
63+
background-repeat: no-repeat;
64+
}
65+
.has-selection:not(.hidden) ~ &.icon {
66+
width: 50px;
67+
padding-left: 41px;
68+
background-size: 32px;
69+
}
70+
}
71+
72+
.name,
73+
.text,
74+
.path {
75+
white-space: nowrap;
76+
overflow: hidden;
77+
text-overflow: ellipsis;
78+
}
79+
.text {
80+
white-space: normal;
81+
color: #545454;
82+
}
83+
.path {
84+
opacity: 0.5;
85+
}
86+
.text em {
87+
color: #545454;
88+
font-weight: bold;
89+
opacity: 1;
90+
}
91+
}
92+
.hidden {
93+
display: none;
94+
}
95+
&.filter-empty {
96+
/* remove whitespace on bottom when no search results, to fix layout */
97+
margin-top: 0 !important;
98+
}
99+
.status.summary .info {
100+
margin-left: 100px;
101+
}
102+
}

0 commit comments

Comments
 (0)