diff --git a/packages/frontend/mobile/src/views/drawer.rs b/packages/frontend/mobile/src/views/drawer.rs index 0e7309db67..d5225f02da 100644 --- a/packages/frontend/mobile/src/views/drawer.rs +++ b/packages/frontend/mobile/src/views/drawer.rs @@ -8,6 +8,7 @@ use ui::{ StatefulInteractiveElement, Styled, div, px, svg, }; use ui_kit::LogicalStyled; +use ui_tokens::icons; use crate::{ state::{MobileAppState, MobileSheet}, @@ -15,9 +16,7 @@ use crate::{ }; use super::{ - A11yBoundsMap, CHEVRON_LEFT_SVG, CHEVRON_RIGHT_SVG, CLOSE_ICON_SVG, MobileFlexExt, - MobilePalette, MobileShellView, PLUS_ICON_SVG, SEARCH_ICON_SVG, STAR_ICON_SVG, - a11y_bounds_probe, row_dir, + A11yBoundsMap, MobileFlexExt, MobilePalette, MobileShellView, a11y_bounds_probe, row_dir, }; /// Format the localized sync status badge label and indicator color. @@ -117,11 +116,11 @@ pub(super) fn render_workspace_drawer( .child( svg() .data(if is_tablet { - CLOSE_ICON_SVG + icons::CLOSE.svg.as_bytes() } else if dir.is_rtl() { - CHEVRON_RIGHT_SVG + icons::ARROW_RIGHT_SMALL.svg.as_bytes() } else { - CHEVRON_LEFT_SVG + icons::ARROW_LEFT_SMALL.svg.as_bytes() }) .w(px(16.0)) .h(px(16.0)) @@ -254,7 +253,7 @@ pub(super) fn render_workspace_drawer( .overflow_hidden() .child( svg() - .data(SEARCH_ICON_SVG) + .data(icons::SEARCH.svg.as_bytes()) .w(px(15.0)) .h(px(15.0)) .text_color(palette.text_muted), @@ -287,7 +286,7 @@ pub(super) fn render_workspace_drawer( )) .child( svg() - .data(PLUS_ICON_SVG) + .data(icons::PLUS.svg.as_bytes()) .w(px(16.0)) .h(px(16.0)) .text_color(ui::white()), @@ -349,7 +348,7 @@ pub(super) fn render_workspace_drawer( if show_star { row = row.child( svg() - .data(STAR_ICON_SVG) + .data(icons::FAVORITED.svg.as_bytes()) .w(px(13.0)) .h(px(13.0)) .text_color(palette.accent), diff --git a/packages/frontend/mobile/src/views/explorer.rs b/packages/frontend/mobile/src/views/explorer.rs index 38a8a679a5..e70a74b817 100644 --- a/packages/frontend/mobile/src/views/explorer.rs +++ b/packages/frontend/mobile/src/views/explorer.rs @@ -10,6 +10,7 @@ use ui::{ Styled, div, px, svg, }; use ui_kit::{LogicalStyled, VirtualWindow}; +use ui_tokens::icons; use crate::{ explorer_model::{ @@ -21,8 +22,7 @@ use crate::{ }; use super::{ - A11yBoundsMap, EXPLORER_ICON_SVG, MobileFlexExt, MobilePalette, MobileShellView, - a11y_bounds_probe, + A11yBoundsMap, MobileFlexExt, MobilePalette, MobileShellView, a11y_bounds_probe, explorer_rows::{ ExplorerEnv, drilldown_header, explorer_compact_meta_cell, explorer_doc_row, explorer_meta_row, explorer_scroll_viewport, new_doc_button, @@ -197,7 +197,7 @@ fn folder_row( })) .child( svg() - .data(EXPLORER_ICON_SVG) + .data(icons::FOLDER.svg.as_bytes()) .mirror_in_rtl(true) .w(px(16.0)) .h(px(16.0)) diff --git a/packages/frontend/mobile/src/views/explorer_rows.rs b/packages/frontend/mobile/src/views/explorer_rows.rs index c7c3ea786b..eab957495e 100644 --- a/packages/frontend/mobile/src/views/explorer_rows.rs +++ b/packages/frontend/mobile/src/views/explorer_rows.rs @@ -6,12 +6,12 @@ use ui::{ Styled, div, px, svg, }; use ui_kit::LogicalStyled; +use ui_tokens::icons; use crate::{a11y::derive_explorer_doc_origin, strings::MobileStrings}; use super::{ - A11yBoundsMap, CHEVRON_LEFT_SVG, MobileFlexExt, MobilePalette, MobileShellView, PLUS_ICON_SVG, - a11y_bounds_probe, row_dir, + A11yBoundsMap, MobileFlexExt, MobilePalette, MobileShellView, a11y_bounds_probe, row_dir, }; #[derive(Clone, Copy)] @@ -51,7 +51,7 @@ pub(super) fn new_doc_button( )) .child( svg() - .data(PLUS_ICON_SVG) + .data(icons::PLUS.svg.as_bytes()) .w(px(18.0)) .h(px(18.0)) .text_color(palette.accent), @@ -172,7 +172,7 @@ pub(super) fn drilldown_header( )) .child( svg() - .data(CHEVRON_LEFT_SVG) + .data(icons::ARROW_LEFT_SMALL.svg.as_bytes()) .mirror_in_rtl(true) .w(px(15.0)) .h(px(15.0)) diff --git a/packages/frontend/mobile/src/views/journals.rs b/packages/frontend/mobile/src/views/journals.rs index a91dcefd25..6306bd0fc2 100644 --- a/packages/frontend/mobile/src/views/journals.rs +++ b/packages/frontend/mobile/src/views/journals.rs @@ -6,12 +6,13 @@ use ui::{ Styled, div, px, svg, }; use ui_kit::LogicalStyled; +use ui_tokens::icons; use crate::{state::MobileAppState, strings::MobileStrings}; use super::{ - A11yBoundsMap, CHEVRON_LEFT_SVG, CHEVRON_RIGHT_SVG, MobileFlexExt, MobilePalette, - MobileShellView, a11y_bounds_probe, a11y_bounds_probe_border, row_dir, + A11yBoundsMap, MobileFlexExt, MobilePalette, MobileShellView, a11y_bounds_probe, + a11y_bounds_probe_border, row_dir, }; #[allow(clippy::too_many_arguments)] @@ -82,7 +83,7 @@ pub(super) fn render_journals( )) .child( svg() - .data(CHEVRON_LEFT_SVG) + .data(icons::ARROW_LEFT_SMALL.svg.as_bytes()) .mirror_in_rtl(true) .w(px(15.0)) .h(px(15.0)) @@ -120,7 +121,7 @@ pub(super) fn render_journals( )) .child( svg() - .data(CHEVRON_RIGHT_SVG) + .data(icons::ARROW_RIGHT_SMALL.svg.as_bytes()) .mirror_in_rtl(true) .w(px(15.0)) .h(px(15.0)) diff --git a/packages/frontend/mobile/src/views/mod.rs b/packages/frontend/mobile/src/views/mod.rs index 1f1dd2846d..ca7e729e74 100644 --- a/packages/frontend/mobile/src/views/mod.rs +++ b/packages/frontend/mobile/src/views/mod.rs @@ -44,20 +44,6 @@ use crate::{ state::{MobileAppState, MobileRoute, MobileSheet}, }; -pub(super) const HOME_ICON_SVG: &[u8] = br#""#; -pub(super) const EXPLORER_ICON_SVG: &[u8] = br#""#; -pub(super) const JOURNALS_ICON_SVG: &[u8] = br#""#; -pub(super) const SEARCH_ICON_SVG: &[u8] = br#""#; -pub(super) const SETTINGS_ICON_SVG: &[u8] = br#""#; -pub(super) const PLUS_ICON_SVG: &[u8] = br#""#; -pub(super) const CHEVRON_LEFT_SVG: &[u8] = br#""#; -pub(super) const CHEVRON_RIGHT_SVG: &[u8] = br#""#; -pub(super) const CHEVRON_DOWN_SVG: &[u8] = br#""#; -pub(super) const CLOSE_ICON_SVG: &[u8] = br#""#; -pub(super) const MORE_ICON_SVG: &[u8] = br#""#; -pub(super) const STAR_ICON_SVG: &[u8] = br#""#; -pub(super) const MENU_ICON_SVG: &[u8] = br#""#; - pub(super) trait MobileFlexExt: Styled { fn justify_between(mut self) -> Self { self.style().justify_content = Some(ui::JustifyContent::SpaceBetween); diff --git a/packages/frontend/mobile/src/views/page.rs b/packages/frontend/mobile/src/views/page.rs index aece982641..33c6524385 100644 --- a/packages/frontend/mobile/src/views/page.rs +++ b/packages/frontend/mobile/src/views/page.rs @@ -10,7 +10,7 @@ use ui_kit::{ BreadcrumbBarConfig, BreadcrumbBarLayout, BreadcrumbItem, BreadcrumbItemKind, BreadcrumbSlotKind, LogicalStyled, MIN_TOUCH_WIDTH, layout_breadcrumb_bar_with_measurer, }; -use ui_tokens::FONT_SANS; +use ui_tokens::{FONT_SANS, icons}; use crate::{ state::{MobileAppState, MobileBackCoordinator, MobileSheet}, @@ -18,8 +18,7 @@ use crate::{ }; use super::{ - A11yBoundsMap, CHEVRON_DOWN_SVG, CHEVRON_LEFT_SVG, CHEVRON_RIGHT_SVG, MENU_ICON_SVG, - MORE_ICON_SVG, MobileFlexExt, MobilePalette, MobileShellView, a11y_bounds_probe, + A11yBoundsMap, MobileFlexExt, MobilePalette, MobileShellView, a11y_bounds_probe, a11y_bounds_probe_border, drawer::sync_status_badge, row_dir, }; @@ -78,7 +77,7 @@ pub(super) fn render_page( )) .child( svg() - .data(CHEVRON_LEFT_SVG) + .data(icons::ARROW_LEFT_SMALL.svg.as_bytes()) .mirror_in_rtl(true) .w(px(15.0)) .h(px(15.0)) @@ -136,7 +135,8 @@ pub(super) fn render_page( )) .child( svg() - .data(MENU_ICON_SVG) + .data(icons::SIDEBAR.svg.as_bytes()) + .mirror_in_rtl(true) .w(px(18.0)) .h(px(18.0)) .text_color(palette.text_secondary), @@ -168,7 +168,7 @@ pub(super) fn render_page( )) .child( svg() - .data(MORE_ICON_SVG) + .data(icons::MORE_HORIZONTAL.svg.as_bytes()) .w(px(18.0)) .h(px(18.0)) .text_color(palette.text_secondary), @@ -278,7 +278,7 @@ pub(super) fn render_page( .justify_center() .child( svg() - .data(CHEVRON_RIGHT_SVG) + .data(icons::ARROW_RIGHT_SMALL.svg.as_bytes()) .mirror_in_rtl(true) .w(px(12.0)) .h(px(12.0)) @@ -351,7 +351,7 @@ pub(super) fn render_page( if slot.kind == BreadcrumbSlotKind::Switcher { pill = pill.child( svg() - .data(CHEVRON_DOWN_SVG) + .data(icons::ARROW_DOWN_SMALL.svg.as_bytes()) .w(px(12.0)) .h(px(12.0)) .text_color(text_color), @@ -589,7 +589,7 @@ pub(super) fn render_page( if !is_ready || !backlinks.items.is_empty() { bl_pill = bl_pill.child( svg() - .data(CHEVRON_RIGHT_SVG) + .data(icons::ARROW_RIGHT_SMALL.svg.as_bytes()) .mirror_in_rtl(true) .w(px(14.0)) .h(px(14.0)) diff --git a/packages/frontend/mobile/src/views/search.rs b/packages/frontend/mobile/src/views/search.rs index 626cab0f93..114d7c5e2c 100644 --- a/packages/frontend/mobile/src/views/search.rs +++ b/packages/frontend/mobile/src/views/search.rs @@ -7,12 +7,13 @@ use ui::{ ParentElement, StatefulInteractiveElement, Styled, canvas, div, px, svg, }; use ui_kit::LogicalStyled; +use ui_tokens::icons; use crate::{state::MobileAppState, strings::MobileStrings}; use super::{ - A11yBoundsMap, CLOSE_ICON_SVG, MobileFlexExt, MobilePalette, MobileShellView, SEARCH_ICON_SVG, - a11y_bounds_probe, row_dir, utf16_to_byte, + A11yBoundsMap, MobileFlexExt, MobilePalette, MobileShellView, a11y_bounds_probe, row_dir, + utf16_to_byte, }; #[allow(clippy::too_many_arguments)] @@ -157,7 +158,7 @@ pub(super) fn render_search( .gap(px(8.0)) .child( svg() - .data(SEARCH_ICON_SVG) + .data(icons::SEARCH.svg.as_bytes()) .mirror_in_rtl(true) .w(px(16.0)) .h(px(16.0)) @@ -191,7 +192,7 @@ pub(super) fn render_search( )) .child( svg() - .data(CLOSE_ICON_SVG) + .data(icons::CLOSE.svg.as_bytes()) .w(px(14.0)) .h(px(14.0)) .text_color(palette.text_secondary), @@ -336,7 +337,7 @@ pub(super) fn render_search( .gap(px(10.0)) .child( svg() - .data(SEARCH_ICON_SVG) + .data(icons::SEARCH.svg.as_bytes()) .mirror_in_rtl(true) .w(px(28.0)) .h(px(28.0)) diff --git a/packages/frontend/mobile/src/views/settings.rs b/packages/frontend/mobile/src/views/settings.rs index 2e1b3790bc..49cd4a4774 100644 --- a/packages/frontend/mobile/src/views/settings.rs +++ b/packages/frontend/mobile/src/views/settings.rs @@ -6,6 +6,7 @@ use ui::{ Styled, div, px, svg, }; use ui_kit::{LogicalStyled, bidi_isolate}; +use ui_tokens::icons; use crate::{ state::{ @@ -16,8 +17,7 @@ use crate::{ }; use super::{ - A11yBoundsMap, CHEVRON_LEFT_SVG, MobileFlexExt, MobilePalette, MobileShellView, - a11y_bounds_probe, row_dir, + A11yBoundsMap, MobileFlexExt, MobilePalette, MobileShellView, a11y_bounds_probe, row_dir, }; pub(super) fn render_settings( @@ -52,7 +52,7 @@ pub(super) fn render_settings( )) .child( svg() - .data(CHEVRON_LEFT_SVG) + .data(icons::ARROW_LEFT_SMALL.svg.as_bytes()) .mirror_in_rtl(true) .w(px(15.0)) .h(px(15.0)) diff --git a/packages/frontend/mobile/src/views/tabs.rs b/packages/frontend/mobile/src/views/tabs.rs index 8c9f5bca64..670d61eb48 100644 --- a/packages/frontend/mobile/src/views/tabs.rs +++ b/packages/frontend/mobile/src/views/tabs.rs @@ -7,6 +7,7 @@ use ui::{ StatefulInteractiveElement, Styled, div, px, svg, }; use ui_kit::{LogicalStyled, MicroIconKind, evaluate_micro_icon}; +use ui_tokens::icons; use crate::{ explorer_model::{fully_visible, row_window_overscan}, @@ -16,9 +17,7 @@ use crate::{ }; use super::{ - A11yBoundsMap, CHEVRON_DOWN_SVG, EXPLORER_ICON_SVG, HOME_ICON_SVG, JOURNALS_ICON_SVG, - MobileFlexExt, MobilePalette, MobileShellView, PLUS_ICON_SVG, SEARCH_ICON_SVG, - SETTINGS_ICON_SVG, STAR_ICON_SVG, a11y_bounds_probe, row_dir, + A11yBoundsMap, MobileFlexExt, MobilePalette, MobileShellView, a11y_bounds_probe, row_dir, }; pub(super) fn render_home( @@ -98,7 +97,7 @@ pub(super) fn render_home( ) .child( svg() - .data(CHEVRON_DOWN_SVG) + .data(icons::ARROW_DOWN_SMALL.svg.as_bytes()) .w(px(14.0)) .h(px(14.0)) .flex_shrink(0.0) @@ -132,7 +131,7 @@ pub(super) fn render_home( )) .child( svg() - .data(PLUS_ICON_SVG) + .data(icons::PLUS.svg.as_bytes()) .w(px(18.0)) .h(px(18.0)) .text_color(palette.accent), @@ -160,7 +159,7 @@ pub(super) fn render_home( )) .child( svg() - .data(SETTINGS_ICON_SVG) + .data(icons::SETTINGS.svg.as_bytes()) .w(px(18.0)) .h(px(18.0)) .text_color(palette.text_secondary), @@ -201,7 +200,7 @@ pub(super) fn render_home( .child(a11y_bounds_probe(node_id, a11y_bounds.clone())) .child( svg() - .data(STAR_ICON_SVG) + .data(icons::FAVORITED.svg.as_bytes()) .w(px(14.0)) .h(px(14.0)) .flex_shrink(0.0) @@ -446,11 +445,11 @@ pub(super) fn render_bottom_tabbar( MobileTab::Search => strings.tab_search, }; let icon_bytes = match tab.micro_icon() { - MicroIconKind::Home => HOME_ICON_SVG, - MicroIconKind::Explorer => EXPLORER_ICON_SVG, - MicroIconKind::Journals => JOURNALS_ICON_SVG, - MicroIconKind::Search => SEARCH_ICON_SVG, - MicroIconKind::SyncSpinner => SETTINGS_ICON_SVG, + MicroIconKind::Home => icons::HOME.svg.as_bytes(), + MicroIconKind::Explorer => icons::ALL_DOCS.svg.as_bytes(), + MicroIconKind::Journals => icons::TODAY.svg.as_bytes(), + MicroIconKind::Search => icons::SEARCH.svg.as_bytes(), + MicroIconKind::SyncSpinner => icons::SETTINGS.svg.as_bytes(), }; let icon_color = if active { Hsla { diff --git a/packages/ui/tokens/extract-tokens.mjs b/packages/ui/tokens/extract-tokens.mjs index c01309d72c..0d55e3a992 100644 --- a/packages/ui/tokens/extract-tokens.mjs +++ b/packages/ui/tokens/extract-tokens.mjs @@ -95,6 +95,22 @@ const CORE_ICONS = [ ['DONE', 'DoneIcon'], ['SEARCH', 'SearchIcon'], ['COMMENT', 'CommentIcon'], + // Shell navigation & workspace icons + ['ARROW_LEFT_SMALL', 'ArrowLeftSmallIcon'], + ['ARROW_RIGHT_SMALL', 'ArrowRightSmallIcon'], + ['CLOSE', 'CloseIcon'], + ['FAVORITED', 'FavoritedIcon'], + ['FAVORITE', 'FavoriteIcon'], + ['SIDEBAR', 'SidebarIcon'], + ['TODAY', 'TodayIcon'], + ['FOLDER', 'FolderIcon'], + ['VIEW_LAYERS', 'ViewLayersIcon'], + ['TAG', 'TagIcon'], + ['SETTINGS', 'SettingsIcon'], + ['SPLIT_VIEW', 'SplitViewIcon'], + ['EXPAND_FULL', 'ExpandFullIcon'], + ['HOME', 'HomeIcon'], + ['ALL_DOCS', 'AllDocsIcon'], ]; /** @@ -1081,6 +1097,16 @@ mod tests { assert_eq!(icon_by_name("MoveLeftIcon"), Some(&MOVE_LEFT)); assert_eq!(icon_by_name("MoveRightIcon"), Some(&MOVE_RIGHT)); assert_eq!(icon_by_name("InvisibleIcon"), Some(&INVISIBLE)); + assert_eq!(icon_by_name("ArrowLeftSmallIcon"), Some(&ARROW_LEFT_SMALL)); + assert_eq!(icon_by_name("ArrowRightSmallIcon"), Some(&ARROW_RIGHT_SMALL)); + assert_eq!(icon_by_name("AllDocsIcon"), Some(&ALL_DOCS)); + assert_eq!(icon_by_name("FavoriteIcon"), Some(&FAVORITE)); + assert_eq!(icon_by_name("FavoritedIcon"), Some(&FAVORITED)); + assert_eq!(icon_by_name("FolderIcon"), Some(&FOLDER)); + assert_eq!(icon_by_name("HomeIcon"), Some(&HOME)); + assert_eq!(icon_by_name("SettingsIcon"), Some(&SETTINGS)); + assert_eq!(icon_by_name("SidebarIcon"), Some(&SIDEBAR)); + assert_eq!(icon_by_name("TodayIcon"), Some(&TODAY)); } #[test] diff --git a/packages/ui/tokens/icons.rs b/packages/ui/tokens/icons.rs index de02905484..3de1c04bbb 100644 --- a/packages/ui/tokens/icons.rs +++ b/packages/ui/tokens/icons.rs @@ -408,11 +408,89 @@ pub const COMMENT: IconDef = IconDef { svg: "", }; +pub const ARROW_LEFT_SMALL: IconDef = IconDef { + name: "ArrowLeftSmallIcon", + svg: "", +}; + +pub const ARROW_RIGHT_SMALL: IconDef = IconDef { + name: "ArrowRightSmallIcon", + svg: "", +}; + +pub const CLOSE: IconDef = IconDef { + name: "CloseIcon", + svg: "", +}; + +pub const FAVORITED: IconDef = IconDef { + name: "FavoritedIcon", + svg: "", +}; + +pub const FAVORITE: IconDef = IconDef { + name: "FavoriteIcon", + svg: "", +}; + +pub const SIDEBAR: IconDef = IconDef { + name: "SidebarIcon", + svg: "", +}; + +pub const TODAY: IconDef = IconDef { + name: "TodayIcon", + svg: "", +}; + +pub const FOLDER: IconDef = IconDef { + name: "FolderIcon", + svg: "", +}; + +pub const VIEW_LAYERS: IconDef = IconDef { + name: "ViewLayersIcon", + svg: "", +}; + +pub const TAG: IconDef = IconDef { + name: "TagIcon", + svg: "", +}; + +pub const SETTINGS: IconDef = IconDef { + name: "SettingsIcon", + svg: "", +}; + +pub const SPLIT_VIEW: IconDef = IconDef { + name: "SplitViewIcon", + svg: "", +}; + +pub const EXPAND_FULL: IconDef = IconDef { + name: "ExpandFullIcon", + svg: "", +}; + +pub const HOME: IconDef = IconDef { + name: "HomeIcon", + svg: "", +}; + +pub const ALL_DOCS: IconDef = IconDef { + name: "AllDocsIcon", + svg: "", +}; + pub const ALL_ICONS: &[IconDef] = &[ ADD_TEXT, + ALL_DOCS, ARROW_DOWN_BIG_BOTTOM, ARROW_DOWN_BIG, ARROW_DOWN_SMALL, + ARROW_LEFT_SMALL, + ARROW_RIGHT_SMALL, ARROW_UP_BIG, ARROW_UP_BIG_TOP, ATTACHMENT, @@ -425,6 +503,7 @@ pub const ALL_ICONS: &[IconDef] = &[ CHECKBOX_CHECKED_LINEAR, CHECKBOX_CHECKED_SOLID, CHECKBOX_UNCHECKED, + CLOSE, CODE_BLOCK, INLINE_CODE, COLLAPSE, @@ -441,7 +520,11 @@ pub const ALL_ICONS: &[IconDef] = &[ DRAG_HANDLE, DUPLICATE, EDGELESS, + EXPAND_FULL, EXPAND, + FAVORITE, + FAVORITED, + FOLDER, FRAME, HAND, HEADING_1, @@ -450,6 +533,7 @@ pub const ALL_ICONS: &[IconDef] = &[ HEADING_4, HEADING_5, HEADING_6, + HOME, IMAGE, INFORMATION, INVISIBLE, @@ -474,17 +558,23 @@ pub const ALL_ICONS: &[IconDef] = &[ ROUNDED_RECTANGLE, SEARCH, SELECT, + SETTINGS, SHAPE, + SIDEBAR, + SPLIT_VIEW, SQUARE, STRIKETHROUGH, + TAG, TEX, TEXT, + TODAY, TOGGLE_DOWN, TOGGLE_RIGHT, TRIANGLE, UNDERLINE, UNDO, UNLOCK, + VIEW_LAYERS, WARNING, WRAP, ZOOM_OUT, @@ -524,6 +614,16 @@ mod tests { assert_eq!(icon_by_name("MoveLeftIcon"), Some(&MOVE_LEFT)); assert_eq!(icon_by_name("MoveRightIcon"), Some(&MOVE_RIGHT)); assert_eq!(icon_by_name("InvisibleIcon"), Some(&INVISIBLE)); + assert_eq!(icon_by_name("ArrowLeftSmallIcon"), Some(&ARROW_LEFT_SMALL)); + assert_eq!(icon_by_name("ArrowRightSmallIcon"), Some(&ARROW_RIGHT_SMALL)); + assert_eq!(icon_by_name("AllDocsIcon"), Some(&ALL_DOCS)); + assert_eq!(icon_by_name("FavoriteIcon"), Some(&FAVORITE)); + assert_eq!(icon_by_name("FavoritedIcon"), Some(&FAVORITED)); + assert_eq!(icon_by_name("FolderIcon"), Some(&FOLDER)); + assert_eq!(icon_by_name("HomeIcon"), Some(&HOME)); + assert_eq!(icon_by_name("SettingsIcon"), Some(&SETTINGS)); + assert_eq!(icon_by_name("SidebarIcon"), Some(&SIDEBAR)); + assert_eq!(icon_by_name("TodayIcon"), Some(&TODAY)); } #[test]