From 1676d721310f58a9593cff3fac3d1d9ad4a704fd Mon Sep 17 00:00:00 2001 From: Blake Niemyjski Date: Fri, 10 Jan 2025 20:24:24 -0600 Subject: [PATCH] next: switch to lucide icons --- .../components/extended-data-item.svelte | 8 +++--- .../summary/event-error-summary.svelte | 4 +-- .../summary/event-simple-summary.svelte | 4 +-- .../summary/stack-error-summary.svelte | 4 +-- .../summary/stack-simple-summary.svelte | 4 +-- .../events-bulk-actions-dropdown-menu.svelte | 2 +- .../events/components/views/Overview.svelte | 14 +++++----- .../events/components/views/Request.svelte | 6 ++--- .../events/components/views/overview.svelte | 14 +++++----- .../events/components/views/request.svelte | 6 ++--- .../copy-to-clipboard-button.svelte | 4 +-- .../shared/components/dark-mode-button.svelte | 8 +++--- .../data-table-column-header.svelte | 22 +++++++--------- .../data-table/data-table-pagination.svelte | 12 ++++----- .../data-table/data-table-view-options.svelte | 4 +-- .../faceted-filter-builder.svelte | 4 +-- .../filters/clickable-boolean-filter.svelte | 4 +-- .../filters/clickable-date-filter.svelte | 4 +-- .../filters/clickable-number-filter.svelte | 4 +-- .../clickable-organization-filter.svelte | 4 +-- .../filters/clickable-project-filter.svelte | 4 +-- .../filters/clickable-reference-filter.svelte | 4 +-- .../filters/clickable-session-filter.svelte | 4 +-- .../filters/clickable-status-filter.svelte | 4 +-- .../filters/clickable-string-filter.svelte | 4 +-- .../filters/clickable-type-filter.svelte | 4 +-- .../filters/clickable-version-filter.svelte | 4 +-- .../base/drop-down-faceted-filter.svelte | 4 +-- .../base/multiselect-faceted-filter.svelte | 4 +-- .../shared/components/search-input.svelte | 4 +-- .../mark-stack-fixed-in-version-dialog.svelte | 6 ++--- .../stacks/components/stack-card.svelte | 26 +++++++++---------- .../stack-options-dropdown-menu.svelte | 16 ++++++------ .../stacks/components/stack-references.svelte | 12 ++++----- .../stack-status-dropdown-menu.svelte | 2 +- .../stacks-bulk-actions-dropdown-menu.svelte | 2 +- .../(app)/(components)/layouts/Footer.svelte | 16 ++++++------ .../(app)/(components)/layouts/Navbar.svelte | 4 +-- .../(app)/(components)/layouts/footer.svelte | 16 ++++++------ .../(app)/(components)/layouts/navbar.svelte | 4 +-- .../ClientApp/src/routes/(app)/+page.svelte | 4 +-- .../src/routes/(app)/account/routes.ts | 24 ++++++++--------- .../(app)/account/security/+page.svelte | 16 ++++++------ .../(app)/account/sessions/+page.svelte | 8 +++--- .../src/routes/(app)/issues/+page.svelte | 4 +-- .../ClientApp/src/routes/(app)/routes.ts | 12 ++++----- .../src/routes/(app)/stream/+page.svelte | 4 +-- .../src/routes/(auth)/login/+page.svelte | 16 ++++++------ .../ClientApp/src/routes/(auth)/routes.ts | 8 +++--- .../ClientApp/src/routes/routes.ts | 3 ++- .../ClientApp/src/routes/status/routes.ts | 4 +-- 51 files changed, 188 insertions(+), 195 deletions(-) diff --git a/src/Exceptionless.Web/ClientApp/src/lib/features/events/components/extended-data-item.svelte b/src/Exceptionless.Web/ClientApp/src/lib/features/events/components/extended-data-item.svelte index 1af3449614..df84c2aa6f 100644 --- a/src/Exceptionless.Web/ClientApp/src/lib/features/events/components/extended-data-item.svelte +++ b/src/Exceptionless.Web/ClientApp/src/lib/features/events/components/extended-data-item.svelte @@ -3,8 +3,8 @@ import ObjectDump from '$comp/object-dump.svelte'; import { Code, H4 } from '$comp/typography'; import { Button } from '$comp/ui/button'; - import IconArrowDown from '~icons/mdi/arrow-down'; - import IconArrowUp from '~icons/mdi/arrow-up'; + import ArrowDown from 'lucide-svelte/icons/arrow-down'; + import ArrowUp from 'lucide-svelte/icons/arrow-up'; interface Props { canPromote?: boolean; @@ -70,11 +70,11 @@ {#if canPromote} {#if !isPromoted} Promote to Tab {:else} Demote Tab {/if} {/if} diff --git a/src/Exceptionless.Web/ClientApp/src/lib/features/events/components/summary/event-error-summary.svelte b/src/Exceptionless.Web/ClientApp/src/lib/features/events/components/summary/event-error-summary.svelte index 91ddfec4d8..c72ef8598f 100644 --- a/src/Exceptionless.Web/ClientApp/src/lib/features/events/components/summary/event-error-summary.svelte +++ b/src/Exceptionless.Web/ClientApp/src/lib/features/events/components/summary/event-error-summary.svelte @@ -1,6 +1,6 @@ @@ -32,16 +32,16 @@ diff --git a/src/Exceptionless.Web/ClientApp/src/routes/(app)/(components)/layouts/Navbar.svelte b/src/Exceptionless.Web/ClientApp/src/routes/(app)/(components)/layouts/Navbar.svelte index 695466629b..dcf97a65c7 100644 --- a/src/Exceptionless.Web/ClientApp/src/routes/(app)/(components)/layouts/Navbar.svelte +++ b/src/Exceptionless.Web/ClientApp/src/routes/(app)/(components)/layouts/Navbar.svelte @@ -9,8 +9,8 @@ import * as Sidebar from '$comp/ui/sidebar'; import { getGravatarFromCurrentUser } from '$features/users/gravatar.svelte'; import logoSmall from '$lib/assets/exceptionless-48.png'; + import Search from 'lucide-svelte/icons/search'; import { MediaQuery } from 'svelte/reactivity'; - import IconSearch from '~icons/mdi/search'; interface Props { isCommandOpen: boolean; @@ -42,7 +42,7 @@
diff --git a/src/Exceptionless.Web/ClientApp/src/routes/(app)/(components)/layouts/footer.svelte b/src/Exceptionless.Web/ClientApp/src/routes/(app)/(components)/layouts/footer.svelte index ae5d3fe726..d47d71bff7 100644 --- a/src/Exceptionless.Web/ClientApp/src/routes/(app)/(components)/layouts/footer.svelte +++ b/src/Exceptionless.Web/ClientApp/src/routes/(app)/(components)/layouts/footer.svelte @@ -1,9 +1,9 @@ @@ -32,16 +32,16 @@
diff --git a/src/Exceptionless.Web/ClientApp/src/routes/(app)/(components)/layouts/navbar.svelte b/src/Exceptionless.Web/ClientApp/src/routes/(app)/(components)/layouts/navbar.svelte index 695466629b..dcf97a65c7 100644 --- a/src/Exceptionless.Web/ClientApp/src/routes/(app)/(components)/layouts/navbar.svelte +++ b/src/Exceptionless.Web/ClientApp/src/routes/(app)/(components)/layouts/navbar.svelte @@ -9,8 +9,8 @@ import * as Sidebar from '$comp/ui/sidebar'; import { getGravatarFromCurrentUser } from '$features/users/gravatar.svelte'; import logoSmall from '$lib/assets/exceptionless-48.png'; + import Search from 'lucide-svelte/icons/search'; import { MediaQuery } from 'svelte/reactivity'; - import IconSearch from '~icons/mdi/search'; interface Props { isCommandOpen: boolean; @@ -42,7 +42,7 @@
diff --git a/src/Exceptionless.Web/ClientApp/src/routes/(app)/+page.svelte b/src/Exceptionless.Web/ClientApp/src/routes/(app)/+page.svelte index 106f429248..78c0f526bd 100644 --- a/src/Exceptionless.Web/ClientApp/src/routes/(app)/+page.svelte +++ b/src/Exceptionless.Web/ClientApp/src/routes/(app)/+page.svelte @@ -19,9 +19,9 @@ import { isTableEmpty, removeTableData, removeTableSelection } from '$shared/table'; import { type FetchClientResponse, useFetchClient } from '@exceptionless/fetchclient'; import { createTable } from '@tanstack/svelte-table'; + import ExternalLink from 'lucide-svelte/icons/external-link'; import { PersistedState, useEventListener } from 'runed'; import { throttle } from 'throttle-debounce'; - import IconOpenInNew from '~icons/mdi/open-in-new'; let selectedEventId: null | string = $state(null); function rowclick(row: EventSummaryModel) { @@ -145,7 +145,7 @@ Event Details Event Details diff --git a/src/Exceptionless.Web/ClientApp/src/routes/(app)/account/routes.ts b/src/Exceptionless.Web/ClientApp/src/routes/(app)/account/routes.ts index a3f43dcfe5..9ea389ea94 100644 --- a/src/Exceptionless.Web/ClientApp/src/routes/(app)/account/routes.ts +++ b/src/Exceptionless.Web/ClientApp/src/routes/(app)/account/routes.ts @@ -1,9 +1,9 @@ -import IconAccount from '~icons/mdi/account'; -import IconSessions from '~icons/mdi/account-multiple'; -import IconNotifications from '~icons/mdi/bell'; -import IconPassword from '~icons/mdi/form-textbox-password'; -import IconVerify from '~icons/mdi/shield-check'; -import IconAppearance from '~icons/mdi/theme-light-dark'; +import Notifications from 'lucide-svelte/icons/bell'; +import Password from 'lucide-svelte/icons/key-round'; +import Verify from 'lucide-svelte/icons/shield-check'; +import Appearance from 'lucide-svelte/icons/sun-moon'; +import Account from 'lucide-svelte/icons/user'; +import Sessions from 'lucide-svelte/icons/users'; import type { NavigationItem } from '../../routes'; @@ -11,40 +11,40 @@ export const routes: NavigationItem[] = [ { group: 'My Account', href: '/next/account/manage', - icon: IconAccount, + icon: Account, title: 'Account' }, { group: 'My Account', href: '/next/account/appearance', - icon: IconAppearance, + icon: Appearance, title: 'Appearance' }, { group: 'My Account', href: '/next/account/notifications', - icon: IconNotifications, + icon: Notifications, show: () => false, title: 'Notifications' }, { group: 'My Account', href: '/next/account/security', - icon: IconPassword, + icon: Password, show: () => false, title: 'Password and authentication' }, { group: 'My Account', href: '/next/account/sessions', - icon: IconSessions, + icon: Sessions, show: () => false, title: 'Sessions' }, { group: 'My Account', href: '/next/account/verify', - icon: IconVerify, + icon: Verify, show: () => false, title: 'Verify' } diff --git a/src/Exceptionless.Web/ClientApp/src/routes/(app)/account/security/+page.svelte b/src/Exceptionless.Web/ClientApp/src/routes/(app)/account/security/+page.svelte index 37f582887a..2eb6080bda 100644 --- a/src/Exceptionless.Web/ClientApp/src/routes/(app)/account/security/+page.svelte +++ b/src/Exceptionless.Web/ClientApp/src/routes/(app)/account/security/+page.svelte @@ -19,10 +19,10 @@ import { User } from '$features/users/models'; import { useFetchClientStatus } from '$shared/api/api.svelte'; import { ProblemDetails, useFetchClient } from '@exceptionless/fetchclient'; - import IconFacebook from '~icons/mdi/facebook'; - import IconGitHub from '~icons/mdi/github'; - import IconGoogle from '~icons/mdi/google'; - import IconMicrosoft from '~icons/mdi/microsoft'; + import Facebook from 'lucide-svelte/icons/facebook'; + import GitHub from 'lucide-svelte/icons/github'; + import Google from '~icons/mdi/google'; + import Microsoft from '~icons/mdi/microsoft'; const data = $state(new User()); @@ -115,7 +115,7 @@ {#if !microsoftClientId}
  • - +
    Microsoft account
    {#if true} @@ -132,7 +132,7 @@ {#if !googleClientId}
  • - +
    Google account
    {#if false} @@ -149,7 +149,7 @@ {#if !facebookClientId}
  • - +
    Facebook account
    {#if false} @@ -166,7 +166,7 @@ {#if !gitHubClientId}
  • - +
    GitHub account
    {#if true} diff --git a/src/Exceptionless.Web/ClientApp/src/routes/(app)/account/sessions/+page.svelte b/src/Exceptionless.Web/ClientApp/src/routes/(app)/account/sessions/+page.svelte index 950693310b..9124068c9c 100644 --- a/src/Exceptionless.Web/ClientApp/src/routes/(app)/account/sessions/+page.svelte +++ b/src/Exceptionless.Web/ClientApp/src/routes/(app)/account/sessions/+page.svelte @@ -3,8 +3,8 @@ import { H3, Muted, P } from '$comp/typography'; import { Button } from '$comp/ui/button'; import { Separator } from '$comp/ui/separator'; - import IconCellphone from '~icons/mdi/cellphone'; - import IconLaptop from '~icons/mdi/laptop'; + import Laptop from 'lucide-svelte/icons/laptop'; + import Smartphone from 'lucide-svelte/icons/smartphone';
    @@ -17,7 +17,7 @@
    • - +

      Wisconsin

      Signed in on @@ -29,7 +29,7 @@
    • - +

      Texas

      Signed in on diff --git a/src/Exceptionless.Web/ClientApp/src/routes/(app)/issues/+page.svelte b/src/Exceptionless.Web/ClientApp/src/routes/(app)/issues/+page.svelte index b4ae9e8f46..83f36b7c28 100644 --- a/src/Exceptionless.Web/ClientApp/src/routes/(app)/issues/+page.svelte +++ b/src/Exceptionless.Web/ClientApp/src/routes/(app)/issues/+page.svelte @@ -20,9 +20,9 @@ import { isTableEmpty, removeTableData, removeTableSelection } from '$shared/table'; import { type FetchClientResponse, useFetchClient } from '@exceptionless/fetchclient'; import { createTable } from '@tanstack/svelte-table'; + import ExternalLink from 'lucide-svelte/icons/external-link'; import { PersistedState, useEventListener } from 'runed'; import { throttle } from 'throttle-debounce'; - import IconOpenInNew from '~icons/mdi/open-in-new'; // TODO: Update this page to use StackSummaryModel instead of EventSummaryModel. let selectedStackId = $state(); @@ -162,7 +162,7 @@ Event Details Event Details (selectedStackId = undefined)}> diff --git a/src/Exceptionless.Web/ClientApp/src/routes/(app)/routes.ts b/src/Exceptionless.Web/ClientApp/src/routes/(app)/routes.ts index ea490d9f45..af15dbc524 100644 --- a/src/Exceptionless.Web/ClientApp/src/routes/(app)/routes.ts +++ b/src/Exceptionless.Web/ClientApp/src/routes/(app)/routes.ts @@ -1,6 +1,6 @@ -import IconEvents from '~icons/mdi/calendar-month-outline'; -import IconStacks from '~icons/mdi/checkbox-multiple-marked-outline'; -import IconEventLog from '~icons/mdi/sort-clock-descending-outline'; +import EventStream from 'lucide-svelte/icons/calendar-arrow-down'; +import Events from 'lucide-svelte/icons/calendar-days'; +import Stacks from 'lucide-svelte/icons/list-checks'; import type { NavigationItem } from '../routes'; @@ -10,19 +10,19 @@ export const routes: NavigationItem[] = [ { group: 'Dashboards', href: '/next/', - icon: IconEvents, + icon: Events, title: 'Events' }, { group: 'Dashboards', href: '/next/issues', - icon: IconStacks, + icon: Stacks, title: 'Issues' }, { group: 'Dashboards', href: '/next/stream', - icon: IconEventLog, + icon: EventStream, title: 'Event Stream' }, ...accountRoutes diff --git a/src/Exceptionless.Web/ClientApp/src/routes/(app)/stream/+page.svelte b/src/Exceptionless.Web/ClientApp/src/routes/(app)/stream/+page.svelte index 5866fd619f..7e02f781cf 100644 --- a/src/Exceptionless.Web/ClientApp/src/routes/(app)/stream/+page.svelte +++ b/src/Exceptionless.Web/ClientApp/src/routes/(app)/stream/+page.svelte @@ -18,10 +18,10 @@ import { isTableEmpty, removeTableData } from '$shared/table'; import { type FetchClientResponse, useFetchClient } from '@exceptionless/fetchclient'; import { createTable } from '@tanstack/svelte-table'; + import ExternalLink from 'lucide-svelte/icons/external-link'; import { PersistedState } from 'runed'; import { useEventListener } from 'runed'; import { debounce } from 'throttle-debounce'; - import IconOpenInNew from '~icons/mdi/open-in-new'; let selectedEventId: null | string = $state(null); function rowclick(row: EventSummaryModel) { @@ -159,7 +159,7 @@ Event Details Event Details diff --git a/src/Exceptionless.Web/ClientApp/src/routes/(auth)/login/+page.svelte b/src/Exceptionless.Web/ClientApp/src/routes/(auth)/login/+page.svelte index 7027d8a080..df3c8ed199 100644 --- a/src/Exceptionless.Web/ClientApp/src/routes/(auth)/login/+page.svelte +++ b/src/Exceptionless.Web/ClientApp/src/routes/(auth)/login/+page.svelte @@ -24,12 +24,12 @@ } from '$features/auth/index.svelte'; import { Login } from '$features/auth/models'; import { applyServerSideErrors } from '$shared/validation'; + import Facebook from 'lucide-svelte/icons/facebook'; + import GitHub from 'lucide-svelte/icons/github'; import { defaults, superForm } from 'sveltekit-superforms'; import { classvalidatorClient } from 'sveltekit-superforms/adapters'; - import IconFacebook from '~icons/mdi/facebook'; - import IconGitHub from '~icons/mdi/github'; - import IconGoogle from '~icons/mdi/google'; - import IconMicrosoft from '~icons/mdi/microsoft'; + import Google from '~icons/mdi/google'; + import Microsoft from '~icons/mdi/microsoft'; const redirectUrl = page.url.searchParams.get('redirect') ?? '/next'; @@ -119,22 +119,22 @@
      {#if microsoftClientId} {/if} {#if googleClientId} {/if} {#if facebookClientId} {/if} {#if gitHubClientId} {/if}
      diff --git a/src/Exceptionless.Web/ClientApp/src/routes/(auth)/routes.ts b/src/Exceptionless.Web/ClientApp/src/routes/(auth)/routes.ts index a635009a1b..bea35ee86d 100644 --- a/src/Exceptionless.Web/ClientApp/src/routes/(auth)/routes.ts +++ b/src/Exceptionless.Web/ClientApp/src/routes/(auth)/routes.ts @@ -1,5 +1,5 @@ -import IconLogin from '~icons/mdi/login'; -import IconLogout from '~icons/mdi/logout'; +import LogIn from 'lucide-svelte/icons/log-in'; +import LogOut from 'lucide-svelte/icons/log-out'; import type { NavigationItem, NavigationItemContext } from '../routes'; @@ -7,14 +7,14 @@ export const routes: NavigationItem[] = [ { group: 'Session', href: '/next/login', - icon: IconLogin, + icon: LogIn, show: (context: NavigationItemContext) => !context.authenticated, title: 'Log in' }, { group: 'Session', href: '/next/logout', - icon: IconLogout, + icon: LogOut, show: (context: NavigationItemContext) => context.authenticated, title: 'Log out' } diff --git a/src/Exceptionless.Web/ClientApp/src/routes/routes.ts b/src/Exceptionless.Web/ClientApp/src/routes/routes.ts index eb489c7a0a..8a13bd9754 100644 --- a/src/Exceptionless.Web/ClientApp/src/routes/routes.ts +++ b/src/Exceptionless.Web/ClientApp/src/routes/routes.ts @@ -1,4 +1,5 @@ import type { User } from '$features/users/models'; +import type { Icon } from 'lucide-svelte'; import type { Component } from 'svelte'; import { routes as appRoutes } from './(app)/routes'; @@ -7,7 +8,7 @@ import { routes as authRoutes } from './(auth)/routes'; export type NavigationItem = { group: string; href: string; - icon: Component; + icon: Component | typeof Icon; show?: (context: NavigationItemContext) => boolean; title: string; }; diff --git a/src/Exceptionless.Web/ClientApp/src/routes/status/routes.ts b/src/Exceptionless.Web/ClientApp/src/routes/status/routes.ts index 526b0741bc..df75b1ea43 100644 --- a/src/Exceptionless.Web/ClientApp/src/routes/status/routes.ts +++ b/src/Exceptionless.Web/ClientApp/src/routes/status/routes.ts @@ -1,4 +1,4 @@ -import StatusLogin from '~icons/mdi/status'; +import Activity from 'lucide-svelte/icons/activity'; import type { NavigationItem } from '../routes'; @@ -6,7 +6,7 @@ export const routes: NavigationItem[] = [ { group: 'status', href: '/next/status', - icon: StatusLogin, + icon: Activity, show: () => false, title: 'Service Status' }