forked from Yoko-Co/yoko-algolia-custom-map-test
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathstyle.css
140 lines (119 loc) · 2.27 KB
/
style.css
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
:root {
--bg-color: #3170b6;
--content-bg-color: #fff;
--map-control-border-color: #ccc;
--map-control-color: #fff;
--map-control-text-color: #111;
}
body {
align-items: center;
background-color: var(--bg-color);
display: flex;
font-family: system-ui, sans-serif;
font-weight: normal;
justify-content: center;
}
#algolia-search {
background-color: var(--content-bg-color);
border-radius: 4px;
box-shadow: 1px 1px 4px rgba(0,0,0,0.325);
height: clamp(400px, 90vh, 1800px);
margin: 0.5rem auto;
max-width: 1280px;
padding: 1rem;
width: 95%;
}
.ais-GeoSearch-map, #map {
height: clamp(240px, 33vh, 720px);
margin-bottom: 2rem;
}
#map:not(.leaflet-container) {
align-content: center;
align-items: center;
border: 10px dashed gray;
display: flex;
justify-content: center;
text-align: center;
}
.results-and-facets {
display: flex;
flex-wrap: wrap;
gap: 1rem;
}
#facets {
flex: 1 1 33.333333%;
max-width: 375px;
padding: 4px;
}
#hits {
flex: 1 1 66.666667%;
max-height: calc(40vh - 3rem);
overflow: auto;
padding: 4px;
}
#hits h3 {
margin: 0;
}
#hits p {
margin: 0;
}
.ais-Hits-item {
align-items: flex-start;
flex-direction: column;
padding: 0.875rem 1.25rem;
}
.ais-Hits--empty {
font-size: 1.25rem;
}
.refine-control {
box-shadow: rgba(49, 112, 182, .3) 0 1px 4px 0 inset;
display: block;
background-color: rgba(0,0,0,.05);
border-radius: 3px;
border: 1px solid #ccc;
padding: 0.5rem 0.75rem;
}
.refine-control:hover {
cursor: pointer;
}
.refine-control:has(input:checked) {
background-color: rgba(49, 112, 182, 0.175);
border-color: var(--bg-color);
box-shadow: none;
}
/* map controls */
.map-control {
background-color: var(--map-control-color);
border-radius: 3px;
border: solid 2px var(--map-control-border-color);
color: var(--map-control-text-color);
padding: 0.25rem 0.5rem;
position: absolute;
z-index: 10000;
}
.map-btn--reset {
bottom: 8px;
left: 8px;
}
/* map tooltips */
.leaflet-tooltip p {
margin: 0;
text-align: left;
white-space: wrap;
min-width: 96px;
}
.map-marker-name {
font-size: 0.875rem;
font-weight: 700;
}
.map-marker-role {
font-style: italic;
}
@media screen and (min-width: 768px) {
.ais-GeoSearch-map, #map {
height: clamp(240px, 50vh, 720px);
}
.results-and-facets {
flex-wrap: nowrap;
}
}