Skip to content

Commit cc1fd2d

Browse files
committed
updates brand and icons
1 parent 7d25117 commit cc1fd2d

File tree

18 files changed

+62
-48
lines changed

18 files changed

+62
-48
lines changed

.lintstagedrc.mjs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,5 +8,5 @@ export default {
88
],
99
"*.py": ["ruff format --check", "ruff check"],
1010
"*.{ts,js,tsx,jsx,mjs}": "prettier --check",
11-
"!(*test*)*": "typos --config .typos.toml",
11+
"*.{rs,ts,js,tsx,jsx,mjs,md,toml,json}": "typos --config .typos.toml",
1212
};

.typos.toml

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,17 @@
11
[files]
2+
extend-exclude = [
3+
"*.png",
4+
"*.jpg",
5+
"*.jpeg",
6+
"*.gif",
7+
"*.ico",
8+
"*.svg",
9+
"*.woff",
10+
"*.woff2",
11+
"*.ttf",
12+
"*.eot",
13+
"crates/fig_desktop/icons/**"
14+
]
215

316
[default.extend-words]
417
mmaped = "mmaped"
27.3 KB
Loading
68.4 KB
Loading

crates/fig_desktop/icons/32x32.png

2.97 KB
Loading
44 Bytes
Loading
27 Bytes
Loading
-691 Bytes
Binary file not shown.
-658 Bytes
Binary file not shown.

crates/fig_desktop/src/tray.rs

Lines changed: 8 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
use std::borrow::Cow;
22

3-
use cfg_if::cfg_if;
43
use fig_install::{
54
InstallComponents,
65
UpdateOptions,
@@ -354,25 +353,16 @@ pub async fn build_tray(
354353
.build()
355354
}
356355

357-
pub fn get_icon(is_logged_in: bool) -> Icon {
356+
pub fn get_icon(_is_logged_in: bool) -> Icon {
358357
let (icon_rgba, icon_width, icon_height) = {
359-
let bytes = if is_logged_in {
360-
cfg_if! {
361-
if #[cfg(target_os = "linux")] {
362-
include_bytes!("../icons/icon-monochrome-light.png").to_vec()
363-
} else {
364-
include_bytes!("../icons/icon-monochrome.png").to_vec()
365-
}
358+
let bytes = {
359+
#[cfg(target_os = "linux")]
360+
{
361+
include_bytes!("../icons/icon-monochrome-light.png").to_vec()
366362
}
367-
} else {
368-
cfg_if! {
369-
if #[cfg(target_os = "linux")] {
370-
// This is intentionally the same as when logged in since Linux tray icons
371-
// don't really seem to work that well when multiple choices are available.
372-
include_bytes!("../icons/icon-monochrome-light.png").to_vec()
373-
} else {
374-
include_bytes!("../icons/not-logged-in.png").to_vec()
375-
}
363+
#[cfg(not(target_os = "linux"))]
364+
{
365+
include_bytes!("../icons/icon-monochrome.png").to_vec()
376366
}
377367
};
378368
let image = image::load_from_memory(&bytes)

0 commit comments

Comments
 (0)