Skip to content

Commit aba2957

Browse files
committed
Fix gradient color of tray icon and make it more visible
1 parent e683655 commit aba2957

File tree

2 files changed

+9
-11
lines changed

2 files changed

+9
-11
lines changed

tray/src/svg.rs

+9-10
Original file line numberDiff line numberDiff line change
@@ -1,27 +1,26 @@
11
const MARK_WHITE_24: &'static str = r##"
22
<svg width="32" height="32" viewBox="0 0 32 32" fill="none" xmlns="http://www.w3.org/2000/svg">
3-
<defs><linearGradient id="Gradient1" x1="0" x2="0" y1="0" y2="32">
4-
<stop offset="0%" stop-color="#242424"/>
5-
<stop offset="50%" stop-color="#202020"/>
6-
<stop offset="100%" stop-color="#1c1c1c"/>
3+
<defs><linearGradient id="Gradient1" x1="0%" x2="0%" y1="0%" y2="100%">
4+
<stop offset="0%" style="stop-color:#777;stop-opacity:1" />
5+
<stop offset="100%" style="stop-color:#222;stop-opacity:1" />
76
</linearGradient></defs>
87
<rect x="1" y="1" width="30" height="30" rx="7.7" fill="url(#Gradient1)" />
9-
<circle opacity="0.2" cx="7.9" cy="7.30" r="2.7" fill="white" />
10-
<circle opacity="0.2" cx="16.0" cy="7.30" r="2.7" fill="white" />
11-
<circle opacity="0.2" cx="24.0" cy="7.30" r="2.7" fill="white" />
8+
<circle opacity="0.4" cx="7.9" cy="7.30" r="2.7" fill="white" />
9+
<circle opacity="0.4" cx="16.0" cy="7.30" r="2.7" fill="white" />
10+
<circle opacity="0.4" cx="24.0" cy="7.30" r="2.7" fill="white" />
1211
<circle opacity="1.0" cx="7.9" cy="15.8" r="2.7" fill="white" />
1312
<circle opacity="1.0" cx="16.0" cy="15.8" r="2.7" fill="white" />
1413
<circle opacity="1.0" cx="24.0" cy="15.8" r="2.7" fill="white" />
15-
<circle opacity="0.2" cx="7.9" cy="24.0" r="2.7" fill="white" />
14+
<circle opacity="0.4" cx="7.9" cy="24.0" r="2.7" fill="white" />
1615
<circle opacity="1.0" cx="16.0" cy="24.0" r="2.7" fill="white" />
17-
<circle opacity="0.2" cx="24.0" cy="24.0" r="2.7" fill="white" />
16+
<circle opacity="0.4" cx="24.0" cy="24.0" r="2.7" fill="white" />
1817
</svg>
1918
"##;
2019

2120
pub fn load_icon(enabled: bool) -> Vec<ksni::Icon> {
2221
match enabled {
2322
true => vec![to_icon(MARK_WHITE_24)],
24-
false => vec![to_icon(&MARK_WHITE_24.replace("1.0", "0.2"))],
23+
false => vec![to_icon(&MARK_WHITE_24.replace("1.0", "0.4"))],
2524
}
2625
}
2726
fn to_icon(svg_str: &str) -> ksni::Icon {

tray/src/tailscale.rs

-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
use serde::{Deserialize, Serialize};
2-
use serde_json::Value;
32
use std::{
43
collections::HashMap,
54
fmt::{Display, Formatter},

0 commit comments

Comments
 (0)