@classic-homes/maps-core 0.7.3 → 0.7.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -2,8 +2,8 @@
2
2
  * MapLibre GL Control Overrides
3
3
  *
4
4
  * Applies the Classic Theme "CAD/drafter aesthetic" to MapLibre's built-in controls.
5
- * Uses hard black borders (light mode) or gray-400 borders (dark mode) to match
6
- * Dialog and DropdownMenu component styling.
5
+ * Uses the theme border token (Black, the CAD rule) to match Dialog and
6
+ * DropdownMenu component styling.
7
7
  *
8
8
  * Note: Uses !important to override Tailwind's high-specificity CSS reset.
9
9
  */
@@ -14,7 +14,7 @@
14
14
 
15
15
  .maplibregl-ctrl-group {
16
16
  background: hsl(var(--card)) !important;
17
- border: 1px solid black !important;
17
+ border: 1px solid hsl(var(--border)) !important;
18
18
  border-radius: 0.375rem !important; /* rounded-md */
19
19
  box-shadow:
20
20
  0 4px 6px -1px rgb(0 0 0 / 0.1),
@@ -41,19 +41,21 @@
41
41
  background-color: hsl(var(--muted)) !important;
42
42
  }
43
43
 
44
+ /* Inset ring (Heritage Teal on the card, 12.68:1): an outer ring is clipped by
45
+ the group's overflow and covered by the next button's background */
44
46
  .maplibregl-ctrl-group button:focus {
45
47
  outline: none !important;
46
- box-shadow: 0 0 0 2px hsl(var(--ring)) !important;
48
+ box-shadow: inset 0 0 0 2px hsl(var(--ring)) !important;
47
49
  }
48
50
 
49
51
  .maplibregl-ctrl-group button:focus-visible {
50
52
  outline: none !important;
51
- box-shadow: 0 0 0 2px hsl(var(--ring)) !important;
53
+ box-shadow: inset 0 0 0 2px hsl(var(--ring)) !important;
52
54
  }
53
55
 
54
56
  /* Dividers between buttons */
55
57
  .maplibregl-ctrl-group button + button {
56
- border-top: 1px solid black !important;
58
+ border-top: 1px solid hsl(var(--border)) !important;
57
59
  }
58
60
 
59
61
  .dark .maplibregl-ctrl-group button + button {
@@ -87,7 +89,7 @@
87
89
 
88
90
  .maplibregl-ctrl-scale {
89
91
  background: hsl(var(--card)) !important;
90
- border: 1px solid black !important;
92
+ border: 1px solid hsl(var(--border)) !important;
91
93
  border-radius: 0.25rem !important; /* rounded */
92
94
  padding: 0 4px !important;
93
95
  font-family:
@@ -145,8 +147,9 @@
145
147
  Attribution Control
146
148
  ========================================================================== */
147
149
 
150
+ /* Solid card: at 80% over satellite or dark tiles the muted text fell to 3.6:1 */
148
151
  .maplibregl-ctrl-attrib {
149
- background: hsl(var(--card) / 0.8) !important;
152
+ background: hsl(var(--card)) !important;
150
153
  padding: 2px 5px !important;
151
154
  font-size: 0.625rem !important; /* smaller text */
152
155
  border-radius: 0.25rem !important;
@@ -164,8 +167,8 @@
164
167
 
165
168
  /* Compact attribution button */
166
169
  .maplibregl-ctrl-attrib-button {
167
- background-color: hsl(var(--card) / 0.8) !important;
168
- border: 1px solid black !important;
170
+ background-color: hsl(var(--card)) !important;
171
+ border: 1px solid hsl(var(--border)) !important;
169
172
  border-radius: 0.25rem !important;
170
173
  }
171
174
 
@@ -175,7 +178,7 @@
175
178
 
176
179
  .maplibregl-ctrl-attrib-button:focus {
177
180
  outline: none !important;
178
- box-shadow: 0 0 0 2px hsl(var(--ring)) !important;
181
+ box-shadow: inset 0 0 0 2px hsl(var(--ring)) !important;
179
182
  }
180
183
 
181
184
  /* ==========================================================================
@@ -55,7 +55,7 @@
55
55
  }
56
56
 
57
57
  .classic-layer-item:hover {
58
- background-color: hsl(var(--muted) / 0.5);
58
+ background-color: hsl(var(--muted));
59
59
  }
60
60
 
61
61
  .classic-layer-item[data-dragging='true'] {
@@ -90,11 +90,18 @@
90
90
  width: 100%;
91
91
  height: 4px;
92
92
  border-radius: 2px;
93
- background: hsl(var(--muted));
93
+ /* Fern track (3.81:1 on the panel) so the 0-100% extent is visible */
94
+ background: hsl(var(--outline, 70 9% 48%));
94
95
  outline: none;
95
96
  cursor: pointer;
96
97
  }
97
98
 
99
+ .classic-layer-opacity-slider:focus-visible {
100
+ box-shadow:
101
+ 0 0 0 2px hsl(var(--background)),
102
+ 0 0 0 4px hsl(var(--ring));
103
+ }
104
+
98
105
  .classic-layer-opacity-slider::-webkit-slider-thumb {
99
106
  -webkit-appearance: none;
100
107
  appearance: none;
@@ -124,15 +131,15 @@
124
131
  transform: scale(1.2);
125
132
  }
126
133
 
127
- /* Drag handle */
134
+ /* Drag handle: an affordance, so full strength (the icon's Muted Foreground is
135
+ 5.74:1; at 0.4 it was 1.78:1) */
128
136
  .classic-layer-drag-handle {
129
137
  cursor: grab;
130
- opacity: 0.4;
131
- transition: opacity 150ms ease;
138
+ color: hsl(var(--muted-foreground));
132
139
  }
133
140
 
134
141
  .classic-layer-drag-handle:hover {
135
- opacity: 1;
142
+ color: hsl(var(--foreground));
136
143
  }
137
144
 
138
145
  .classic-layer-drag-handle:active {
@@ -170,14 +177,12 @@
170
177
  color: hsl(var(--foreground));
171
178
  font-size: 0.875rem;
172
179
  outline: none;
173
- transition:
174
- border-color 150ms ease,
175
- box-shadow 150ms ease;
176
180
  }
177
181
 
178
- .classic-layer-search:focus {
179
- border-color: hsl(var(--primary));
180
- box-shadow: 0 0 0 2px hsl(var(--primary) / 0.2);
182
+ /* Full-strength Heritage Teal ring (12.68:1); a 20% halo was 1.46:1 */
183
+ .classic-layer-search:focus-visible {
184
+ border-color: hsl(var(--ring));
185
+ box-shadow: 0 0 0 2px hsl(var(--ring));
181
186
  }
182
187
 
183
188
  .classic-layer-search::placeholder {
@@ -189,7 +194,7 @@
189
194
  display: flex;
190
195
  gap: 0.25rem;
191
196
  padding: 0.25rem;
192
- background-color: hsl(var(--muted) / 0.5);
197
+ background-color: hsl(var(--muted));
193
198
  border-radius: 0.375rem;
194
199
  }
195
200
 
@@ -208,10 +213,18 @@
208
213
  color: hsl(var(--foreground));
209
214
  }
210
215
 
216
+ /* v2.5 selected: Linen, bold Grey 01 text (6.18:1) and a Heritage Teal bottom
217
+ edge, so it differs from the Paper strip by more than a fill */
211
218
  .classic-layer-tab[data-active='true'] {
212
- background-color: hsl(var(--background));
213
- color: hsl(var(--foreground));
214
- box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
219
+ background-color: hsl(var(--accent));
220
+ color: hsl(var(--accent-foreground));
221
+ font-weight: 600;
222
+ box-shadow: inset 0 -3px 0 hsl(var(--primary));
223
+ }
224
+
225
+ .classic-layer-tab:focus-visible {
226
+ outline: 2px solid hsl(var(--ring));
227
+ outline-offset: 1px;
215
228
  }
216
229
 
217
230
  /* Error state */
@@ -2,7 +2,7 @@
2
2
  * MapLibre GL Popup Overrides
3
3
  *
4
4
  * Applies the Classic Theme "CAD/drafter aesthetic" to MapLibre's popup component.
5
- * Uses hard black borders (light mode) or gray-400 borders (dark mode) to match
5
+ * Uses the theme border token (Black, the CAD rule) to match
6
6
  * Dialog and DropdownMenu component styling.
7
7
  *
8
8
  * Note: Uses !important to override Tailwind's high-specificity CSS reset.
@@ -15,7 +15,7 @@
15
15
  .maplibregl-popup-content {
16
16
  background: hsl(var(--popover)) !important;
17
17
  color: hsl(var(--popover-foreground)) !important;
18
- border: 1px solid black !important;
18
+ border: 1px solid hsl(var(--border)) !important;
19
19
  border-radius: 0.5rem !important; /* rounded-lg to match Dialog */
20
20
  box-shadow:
21
21
  0 10px 15px -3px rgb(0 0 0 / 0.1),
@@ -69,9 +69,10 @@
69
69
  cursor: pointer !important;
70
70
  }
71
71
 
72
+ /* v2.5 hover is Paper; Linen means selected */
72
73
  .maplibregl-popup-close-button:hover {
73
74
  color: hsl(var(--foreground)) !important;
74
- background-color: hsl(var(--accent)) !important;
75
+ background-color: hsl(var(--muted)) !important;
75
76
  }
76
77
 
77
78
  .maplibregl-popup-close-button:focus {
@@ -90,181 +91,201 @@
90
91
  position: absolute;
91
92
  inset: -8px;
92
93
  }
94
+ /* PopupContent placed first (no PopupHeader) keeps clear of the close button */
95
+ .maplibregl-popup-content:has(> .maplibregl-popup-close-button)
96
+ [data-popup-card]
97
+ > [data-popup-content]:first-child {
98
+ padding-right: 2.75rem;
99
+ }
93
100
 
94
101
  /* ==========================================================================
95
- Popup Tip/Arrow Styling
96
-
97
- MapLibre creates a tip element with CSS borders to form a triangle.
98
- We color the border to match our popup border, then use ::after to
99
- create an inner triangle that fills with the background color.
100
-
101
- Note: The tip is outside the content container, so overflow:hidden
102
- on the content doesn't affect it.
102
+ Corner anchors: the tip meets the popup at a square corner
103
103
  ========================================================================== */
104
104
 
105
- /* Base tip styling - position: relative is required for ::after positioning */
106
- .maplibregl-popup-tip {
107
- z-index: 1 !important;
108
- position: relative !important;
105
+ .maplibregl-popup-anchor-top-left .maplibregl-popup-content {
106
+ border-top-left-radius: 0 !important;
109
107
  }
110
108
 
111
- /* --- Bottom Anchored (popup above point, arrow points down) --- */
112
-
113
- .maplibregl-popup-anchor-bottom .maplibregl-popup-tip {
114
- border-top-color: black !important;
109
+ .maplibregl-popup-anchor-top-right .maplibregl-popup-content {
110
+ border-top-right-radius: 0 !important;
115
111
  }
116
112
 
117
- .dark .maplibregl-popup-anchor-bottom .maplibregl-popup-tip {
118
- border-top-color: rgb(156 163 175) !important;
113
+ .maplibregl-popup-anchor-bottom-left .maplibregl-popup-content {
114
+ border-bottom-left-radius: 0 !important;
119
115
  }
120
116
 
121
- /* Inner fill triangle */
122
- .maplibregl-popup-anchor-bottom .maplibregl-popup-tip::after {
123
- content: '' !important;
124
- position: absolute !important;
125
- left: -10px !important;
126
- top: -11px !important;
127
- border-left: 10px solid transparent !important;
128
- border-right: 10px solid transparent !important;
129
- border-top: 10px solid hsl(var(--popover)) !important;
117
+ .maplibregl-popup-anchor-bottom-right .maplibregl-popup-content {
118
+ border-bottom-right-radius: 0 !important;
130
119
  }
131
120
 
132
- /* --- Top Anchored (popup below point, arrow points up) --- */
121
+ [dir='rtl'] .maplibregl-popup-anchor-top-left .maplibregl-popup-content {
122
+ border-top-left-radius: 0.5rem !important;
123
+ border-top-right-radius: 0 !important;
124
+ }
133
125
 
134
- .maplibregl-popup-anchor-top .maplibregl-popup-tip {
135
- border-bottom-color: black !important;
126
+ [dir='rtl'] .maplibregl-popup-anchor-top-right .maplibregl-popup-content {
127
+ border-top-right-radius: 0.5rem !important;
128
+ border-top-left-radius: 0 !important;
136
129
  }
137
130
 
138
- .dark .maplibregl-popup-anchor-top .maplibregl-popup-tip {
139
- border-bottom-color: rgb(156 163 175) !important;
131
+ [dir='rtl'] .maplibregl-popup-anchor-bottom-left .maplibregl-popup-content {
132
+ border-bottom-left-radius: 0.5rem !important;
133
+ border-bottom-right-radius: 0 !important;
140
134
  }
141
135
 
142
- .maplibregl-popup-anchor-top .maplibregl-popup-tip::after {
143
- content: '' !important;
144
- position: absolute !important;
145
- left: -10px !important;
146
- bottom: -11px !important;
147
- border-left: 10px solid transparent !important;
148
- border-right: 10px solid transparent !important;
149
- border-bottom: 10px solid hsl(var(--popover)) !important;
136
+ [dir='rtl'] .maplibregl-popup-anchor-bottom-right .maplibregl-popup-content {
137
+ border-bottom-right-radius: 0.5rem !important;
138
+ border-bottom-left-radius: 0 !important;
150
139
  }
151
140
 
152
- /* --- Left Anchored (popup to right of point, arrow points left) --- */
141
+ /* ==========================================================================
142
+ Popup Tip/Arrow
143
+
144
+ MapLibre draws the tip as a CSS border triangle. We drop that and paint
145
+ two clip-path triangles instead: ::before in the border colour, ::after
146
+ in the fill colour, inset 1px (1.414px along the 45° edges). The tip
147
+ overlaps the popup by 1px, so the fill covers the popup's own border
148
+ across the tip's mouth: the outline runs round the tip, not through it.
149
+
150
+ The fill matches the part of the popup the tip touches: PopupHeader
151
+ (when it comes first) for tips above, PopupFooter (when it comes last)
152
+ for tips below, the popover colour otherwise. A header or footer with a
153
+ custom background sets --popup-tip-fill on the popup to match.
154
+ ========================================================================== */
153
155
 
154
- .maplibregl-popup-anchor-left .maplibregl-popup-tip {
155
- border-right-color: black !important;
156
+ .maplibregl-popup {
157
+ --ct-popup-tip-border: hsl(var(--border));
158
+ --ct-popup-tip-fill: var(--popup-tip-fill, hsl(var(--popover)));
156
159
  }
157
160
 
158
- .dark .maplibregl-popup-anchor-left .maplibregl-popup-tip {
159
- border-right-color: rgb(156 163 175) !important;
161
+ .dark .maplibregl-popup {
162
+ --ct-popup-tip-border: rgb(156 163 175); /* gray-400, as the popup border */
160
163
  }
161
164
 
162
- .maplibregl-popup-anchor-left .maplibregl-popup-tip::after {
163
- content: '' !important;
164
- position: absolute !important;
165
- top: -10px !important;
166
- left: -10px !important;
167
- border-top: 10px solid transparent !important;
168
- border-bottom: 10px solid transparent !important;
169
- border-right: 10px solid hsl(var(--popover)) !important;
165
+ .maplibregl-popup:is(
166
+ .maplibregl-popup-anchor-top,
167
+ .maplibregl-popup-anchor-top-left,
168
+ .maplibregl-popup-anchor-top-right
169
+ ):has([data-popup-card] > [data-popup-header]:first-child),
170
+ .maplibregl-popup:is(
171
+ .maplibregl-popup-anchor-bottom,
172
+ .maplibregl-popup-anchor-bottom-left,
173
+ .maplibregl-popup-anchor-bottom-right
174
+ ):has([data-popup-card] > [data-popup-footer]:last-child) {
175
+ --ct-popup-tip-fill: var(--popup-tip-fill, hsl(var(--muted)));
170
176
  }
171
177
 
172
- /* --- Right Anchored (popup to left of point, arrow points right) --- */
173
-
174
- .maplibregl-popup-anchor-right .maplibregl-popup-tip {
175
- border-left-color: black !important;
178
+ .maplibregl-popup-tip {
179
+ position: relative !important;
180
+ z-index: 1 !important; /* above the popup's border */
181
+ width: 22px !important;
182
+ height: 11px !important;
183
+ border: none !important;
176
184
  }
177
185
 
178
- .dark .maplibregl-popup-anchor-right .maplibregl-popup-tip {
179
- border-left-color: rgb(156 163 175) !important;
186
+ .maplibregl-popup-tip::before,
187
+ .maplibregl-popup-tip::after {
188
+ content: '';
189
+ position: absolute;
190
+ inset: 0;
191
+ clip-path: var(--ct-tip-outer);
192
+ background: var(--ct-popup-tip-border);
180
193
  }
181
194
 
182
- .maplibregl-popup-anchor-right .maplibregl-popup-tip::after {
183
- content: '' !important;
184
- position: absolute !important;
185
- top: -10px !important;
186
- right: -10px !important;
187
- border-top: 10px solid transparent !important;
188
- border-bottom: 10px solid transparent !important;
189
- border-left: 10px solid hsl(var(--popover)) !important;
195
+ .maplibregl-popup-tip::after {
196
+ clip-path: var(--ct-tip-inner);
197
+ background: var(--ct-popup-tip-fill);
190
198
  }
191
199
 
192
- /* --- Top-Left Anchored (popup below-right of point, arrow points up-left) --- */
193
-
194
- .maplibregl-popup-anchor-top-left .maplibregl-popup-tip {
195
- border-bottom-color: black !important;
200
+ /* Popup above the point: tip hangs below, mouth on top */
201
+ .maplibregl-popup-anchor-bottom .maplibregl-popup-tip {
202
+ margin-top: -1px !important;
203
+ --ct-tip-outer: polygon(0 0, 100% 0, 50% 100%);
204
+ --ct-tip-inner: polygon(1.414px 0, calc(100% - 1.414px) 0, 50% calc(100% - 1.414px));
196
205
  }
197
206
 
198
- .dark .maplibregl-popup-anchor-top-left .maplibregl-popup-tip {
199
- border-bottom-color: rgb(156 163 175) !important;
207
+ /* Popup below the point: tip sits on top, mouth at the bottom */
208
+ .maplibregl-popup-anchor-top .maplibregl-popup-tip {
209
+ margin-bottom: -1px !important;
210
+ --ct-tip-outer: polygon(50% 0, 100% 100%, 0 100%);
211
+ --ct-tip-inner: polygon(50% 1.414px, calc(100% - 1.414px) 100%, 1.414px 100%);
200
212
  }
201
213
 
202
- .maplibregl-popup-anchor-top-left .maplibregl-popup-tip::after {
203
- content: '' !important;
204
- position: absolute !important;
205
- left: -10px !important;
206
- bottom: -11px !important;
207
- border-left: 10px solid transparent !important;
208
- border-right: 10px solid transparent !important;
209
- border-bottom: 10px solid hsl(var(--popover)) !important;
214
+ /* Popup right of the point: tip on its left, mouth on the right */
215
+ .maplibregl-popup-anchor-left .maplibregl-popup-tip {
216
+ width: 11px !important;
217
+ height: 22px !important;
218
+ margin-right: -1px !important;
219
+ --ct-tip-outer: polygon(100% 0, 100% 100%, 0 50%);
220
+ --ct-tip-inner: polygon(100% 1.414px, 100% calc(100% - 1.414px), 1.414px 50%);
210
221
  }
211
222
 
212
- /* --- Top-Right Anchored (popup below-left of point, arrow points up-right) --- */
213
-
214
- .maplibregl-popup-anchor-top-right .maplibregl-popup-tip {
215
- border-bottom-color: black !important;
223
+ /* Popup left of the point: tip on its right, mouth on the left */
224
+ .maplibregl-popup-anchor-right .maplibregl-popup-tip {
225
+ width: 11px !important;
226
+ height: 22px !important;
227
+ margin-left: -1px !important;
228
+ --ct-tip-outer: polygon(0 0, 100% 50%, 0 100%);
229
+ --ct-tip-inner: polygon(0 1.414px, calc(100% - 1.414px) 50%, 0 calc(100% - 1.414px));
216
230
  }
217
231
 
218
- .dark .maplibregl-popup-anchor-top-right .maplibregl-popup-tip {
219
- border-bottom-color: rgb(156 163 175) !important;
232
+ [dir='rtl'] .maplibregl-popup-anchor-left .maplibregl-popup-tip {
233
+ margin-right: 0 !important;
234
+ margin-left: -1px !important;
235
+ --ct-tip-outer: polygon(0 0, 100% 50%, 0 100%);
236
+ --ct-tip-inner: polygon(0 1.414px, calc(100% - 1.414px) 50%, 0 calc(100% - 1.414px));
220
237
  }
221
238
 
222
- .maplibregl-popup-anchor-top-right .maplibregl-popup-tip::after {
223
- content: '' !important;
224
- position: absolute !important;
225
- left: -10px !important;
226
- bottom: -11px !important;
227
- border-left: 10px solid transparent !important;
228
- border-right: 10px solid transparent !important;
229
- border-bottom: 10px solid hsl(var(--popover)) !important;
239
+ [dir='rtl'] .maplibregl-popup-anchor-right .maplibregl-popup-tip {
240
+ margin-left: 0 !important;
241
+ margin-right: -1px !important;
242
+ --ct-tip-outer: polygon(100% 0, 100% 100%, 0 50%);
243
+ --ct-tip-inner: polygon(100% 1.414px, 100% calc(100% - 1.414px), 1.414px 50%);
230
244
  }
231
245
 
232
- /* --- Bottom-Left Anchored (popup above-right of point, arrow points down-left) --- */
233
-
234
- .maplibregl-popup-anchor-bottom-left .maplibregl-popup-tip {
235
- border-top-color: black !important;
246
+ /* Corner anchors: a right-angled tip whose straight side continues the
247
+ popup's side border down (or up) to the point */
248
+ .maplibregl-popup-anchor-top-left .maplibregl-popup-tip,
249
+ .maplibregl-popup-anchor-top-right .maplibregl-popup-tip,
250
+ .maplibregl-popup-anchor-bottom-left .maplibregl-popup-tip,
251
+ .maplibregl-popup-anchor-bottom-right .maplibregl-popup-tip {
252
+ width: 11px !important;
236
253
  }
237
254
 
238
- .dark .maplibregl-popup-anchor-bottom-left .maplibregl-popup-tip {
239
- border-top-color: rgb(156 163 175) !important;
255
+ .maplibregl-popup-anchor-top-left .maplibregl-popup-tip,
256
+ .maplibregl-popup-anchor-top-right .maplibregl-popup-tip {
257
+ margin-bottom: -1px !important;
240
258
  }
241
259
 
242
- .maplibregl-popup-anchor-bottom-left .maplibregl-popup-tip::after {
243
- content: '' !important;
244
- position: absolute !important;
245
- left: -10px !important;
246
- top: -11px !important;
247
- border-left: 10px solid transparent !important;
248
- border-right: 10px solid transparent !important;
249
- border-top: 10px solid hsl(var(--popover)) !important;
260
+ .maplibregl-popup-anchor-bottom-left .maplibregl-popup-tip,
261
+ .maplibregl-popup-anchor-bottom-right .maplibregl-popup-tip {
262
+ margin-top: -1px !important;
250
263
  }
251
264
 
252
- /* --- Bottom-Right Anchored (popup above-left of point, arrow points down-right) --- */
265
+ /* Point at the top-left corner */
266
+ .maplibregl-popup-anchor-top-left .maplibregl-popup-tip,
267
+ [dir='rtl'] .maplibregl-popup-anchor-top-right .maplibregl-popup-tip {
268
+ --ct-tip-outer: polygon(0 0, 100% 100%, 0 100%);
269
+ --ct-tip-inner: polygon(1px 2.414px, calc(100% - 1.414px) 100%, 1px 100%);
270
+ }
253
271
 
254
- .maplibregl-popup-anchor-bottom-right .maplibregl-popup-tip {
255
- border-top-color: black !important;
272
+ /* Point at the top-right corner */
273
+ .maplibregl-popup-anchor-top-right .maplibregl-popup-tip,
274
+ [dir='rtl'] .maplibregl-popup-anchor-top-left .maplibregl-popup-tip {
275
+ --ct-tip-outer: polygon(100% 0, 100% 100%, 0 100%);
276
+ --ct-tip-inner: polygon(calc(100% - 1px) 2.414px, calc(100% - 1px) 100%, 1.414px 100%);
256
277
  }
257
278
 
258
- .dark .maplibregl-popup-anchor-bottom-right .maplibregl-popup-tip {
259
- border-top-color: rgb(156 163 175) !important;
279
+ /* Point at the bottom-left corner */
280
+ .maplibregl-popup-anchor-bottom-left .maplibregl-popup-tip,
281
+ [dir='rtl'] .maplibregl-popup-anchor-bottom-right .maplibregl-popup-tip {
282
+ --ct-tip-outer: polygon(0 0, 100% 0, 0 100%);
283
+ --ct-tip-inner: polygon(1px 0, calc(100% - 1.414px) 0, 1px calc(100% - 2.414px));
260
284
  }
261
285
 
262
- .maplibregl-popup-anchor-bottom-right .maplibregl-popup-tip::after {
263
- content: '' !important;
264
- position: absolute !important;
265
- left: -10px !important;
266
- top: -11px !important;
267
- border-left: 10px solid transparent !important;
268
- border-right: 10px solid transparent !important;
269
- border-top: 10px solid hsl(var(--popover)) !important;
286
+ /* Point at the bottom-right corner */
287
+ .maplibregl-popup-anchor-bottom-right .maplibregl-popup-tip,
288
+ [dir='rtl'] .maplibregl-popup-anchor-bottom-left .maplibregl-popup-tip {
289
+ --ct-tip-outer: polygon(0 0, 100% 0, 100% 100%);
290
+ --ct-tip-inner: polygon(1.414px 0, calc(100% - 1px) 0, calc(100% - 1px) calc(100% - 2.414px));
270
291
  }