Skip to content

Commit 24f93d8

Browse files
authored
Merge pull request #275 from glanceapp/release/v0.6.3
Release/v0.6.3
2 parents 448c795 + 01016e0 commit 24f93d8

File tree

3 files changed

+15
-5
lines changed

3 files changed

+15
-5
lines changed

internal/assets/static/main.css

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -514,6 +514,7 @@ kbd:active {
514514
list-style: none;
515515
position: relative;
516516
display: flex;
517+
z-index: 1;
517518
}
518519

519520
.details[open] .summary {
@@ -535,6 +536,10 @@ kbd:active {
535536
opacity: 1;
536537
}
537538

539+
.details:not([open]) .list-with-transition {
540+
display: none;
541+
}
542+
538543
.summary::after {
539544
content: "◀";
540545
font-size: 1.2em;
@@ -707,6 +712,7 @@ details[open] .summary::after {
707712
justify-content: space-between;
708713
position: relative;
709714
margin-bottom: 1.8rem;
715+
z-index: 1;
710716
}
711717

712718
.widget-error-header::before {
@@ -1095,7 +1101,6 @@ details[open] .summary::after {
10951101

10961102
.dns-stats-graph-gridlines-container {
10971103
position: absolute;
1098-
z-index: -1;
10991104
inset: 0;
11001105
}
11011106

@@ -1122,7 +1127,6 @@ details[open] .summary::after {
11221127
content: '';
11231128
position: absolute;
11241129
inset: 1px 0;
1125-
z-index: -1;
11261130
opacity: 0;
11271131
background: var(--color-text-base);
11281132
transition: opacity .2s;
@@ -1264,7 +1268,6 @@ details[open] .summary::after {
12641268
overflow: hidden;
12651269
mask-image: linear-gradient(0deg, transparent 40%, #000);
12661270
-webkit-mask-image: linear-gradient(0deg, transparent 40%, #000);
1267-
z-index: -1;
12681271
}
12691272

12701273
.weather-column-rain::before {

internal/feed/openmeteo.go

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -189,12 +189,19 @@ func FetchWeatherForPlace(place *PlaceJson, units string) (*Weather, error) {
189189
minT := slices.Min(temperatures)
190190
maxT := slices.Max(temperatures)
191191

192+
temperaturesRange := float64(maxT - minT)
193+
192194
for i := 0; i < 12; i++ {
193195
bars = append(bars, weatherColumn{
194196
Temperature: temperatures[i],
195-
Scale: float64(temperatures[i]-minT) / float64(maxT-minT),
196197
HasPrecipitation: precipitations[i],
197198
})
199+
200+
if temperaturesRange > 0 {
201+
bars[i].Scale = float64(temperatures[i]-minT) / temperaturesRange
202+
} else {
203+
bars[i].Scale = 1
204+
}
198205
}
199206
}
200207

internal/widget/fields.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -162,7 +162,7 @@ func toSimpleIconIfPrefixed(icon string) (string, bool) {
162162
}
163163

164164
icon = strings.TrimPrefix(icon, "si:")
165-
icon = "https://cdnjs.cloudflare.com/ajax/libs/simple-icons/11.14.0/" + icon + ".svg"
165+
icon = "https://cdn.jsdelivr.net/npm/simple-icons@latest/icons/" + icon + ".svg"
166166

167167
return icon, true
168168
}

0 commit comments

Comments
 (0)