aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--assets/css/search.css25
-rw-r--r--views/instant_search_results.html2
-rw-r--r--views/list.html3
3 files changed, 28 insertions, 2 deletions
diff --git a/assets/css/search.css b/assets/css/search.css
new file mode 100644
index 0000000..94abbaf
--- /dev/null
+++ b/assets/css/search.css
@@ -0,0 +1,25 @@
1.search-results .search-result {
2 background-color: #fff;
3 line-height: 1.5rem;
4 padding: 10px 20px;
5 margin: 0;
6 border-bottom: 1px solid #e0e0e0;
7}
8
9.search-results {
10 margin: 0.5rem 0 1rem 0;
11 border: 1px solid #e0e0e0;
12 border-radius: 2px;
13 overflow: hidden;
14 position: relative;
15}
16
17.search-results .search-result.avatar {
18 min-height: 84px;
19 padding-left: 72px;
20 position: relative;
21}
22
23.search-results .search-result.avatar .title {
24 font-size: 16px;
25} \ No newline at end of file
diff --git a/views/instant_search_results.html b/views/instant_search_results.html
index 73eda26..294315c 100644
--- a/views/instant_search_results.html
+++ b/views/instant_search_results.html
@@ -1,6 +1,6 @@
1{{ define "instant_search_results" }} 1{{ define "instant_search_results" }}
2{{ range .results }} 2{{ range .results }}
3<li class="collection-item avatar hoverable"> 3<li class="search-result avatar hoverable valign-wrapper">
4 <img src="/{{ .ImagePath }}" alt="" class="circle"> 4 <img src="/{{ .ImagePath }}" alt="" class="circle">
5 <span class="title">{{ .Name }}</span> 5 <span class="title">{{ .Name }}</span>
6</li> 6</li>
diff --git a/views/list.html b/views/list.html
index 5114ab9..f7ba097 100644
--- a/views/list.html
+++ b/views/list.html
@@ -6,6 +6,7 @@
6 {{ template "materialize" }} 6 {{ template "materialize" }}
7 <title>grilist</title> 7 <title>grilist</title>
8 <link rel="stylesheet" href="/assets/css/list.css" /> 8 <link rel="stylesheet" href="/assets/css/list.css" />
9 <link rel="stylesheet" href="/assets/css/search.css" />
9 <link href="https://fonts.googleapis.com/icon?family=Material+Icons" rel="stylesheet"> 10 <link href="https://fonts.googleapis.com/icon?family=Material+Icons" rel="stylesheet">
10 <script src="/assets/js/search.js"></script> 11 <script src="/assets/js/search.js"></script>
11 <meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=no"> 12 <meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=no">
@@ -70,7 +71,7 @@
70 </form> 71 </form>
71 </div> 72 </div>
72 <div class="col s10 offset-s1"> 73 <div class="col s10 offset-s1">
73 <ul class="collection search-results" id="search-results"> 74 <ul class="search-results" id="search-results">
74 </ul> 75 </ul>
75 </div> 76 </div>
76 </div> 77 </div>