@ohmykreee/dsh-remote-control 0.0.0-stage → 1.0.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/AGENTS.md +556 -0
- package/INSTALLATION.md +310 -0
- package/LICENSE +21 -0
- package/README.md +195 -2
- package/client.js +3 -0
- package/components.json +20 -0
- package/cordis.patch.yml +3 -0
- package/docs/README.en.md +196 -0
- package/docs/screenshots/en/overview.png +0 -0
- package/docs/screenshots/en/question.png +0 -0
- package/docs/screenshots/zh/overview.png +0 -0
- package/docs/screenshots/zh/question.png +0 -0
- package/icon.svg +24 -0
- package/index.js +2 -0
- package/lib/account.js +1 -0
- package/lib/app-mapping.js +1 -0
- package/lib/i18n.js +1 -0
- package/lib/media-enrich.js +1 -0
- package/lib/notifications.js +1 -0
- package/lib/performance.js +1 -0
- package/lib/platform/index.js +1 -0
- package/lib/probe-adapter.js +1 -0
- package/lib/probe-daemon.js +1 -0
- package/lib/probe.js +1 -0
- package/lib/qr.js +1 -0
- package/lib/runtime.js +1 -0
- package/lib/service.js +1 -0
- package/lib/sessions.js +1 -0
- package/lib/settings.js +1 -0
- package/lib/types.js +1 -0
- package/lib/util.js +1 -0
- package/lib/weather.js +1 -0
- package/lib/ws.js +1 -0
- package/locale/en.json +6 -0
- package/locale/zh.json +6 -0
- package/package.json +118 -4
- package/scripts/browser-shot.mjs +217 -0
- package/scripts/build-dsh.mjs +228 -0
- package/scripts/build-rust.mjs +319 -0
- package/scripts/build-web.mjs +17 -0
- package/scripts/check-npm-package.mjs +322 -0
- package/scripts/mock-preview.py +574 -0
- package/scripts/screenshot-compose.py +89 -0
- package/scripts/screenshot-device.sh +75 -0
- package/src/dsh/client/api.ts +68 -0
- package/src/dsh/client/i18n.ts +573 -0
- package/src/dsh/client/icons.ts +56 -0
- package/src/dsh/client/index.ts +95 -0
- package/src/dsh/client/logic.ts +310 -0
- package/src/dsh/client/panel.ts +483 -0
- package/src/dsh/client/sections/apps.ts +40 -0
- package/src/dsh/client/sections/balance.ts +38 -0
- package/src/dsh/client/sections/connection.ts +97 -0
- package/src/dsh/client/sections/notifications.ts +43 -0
- package/src/dsh/client/sections/pomodoro.ts +184 -0
- package/src/dsh/client/sections/preferences.ts +138 -0
- package/src/dsh/client/sections/system.ts +120 -0
- package/src/dsh/client/sections/weather.ts +276 -0
- package/src/dsh/client/styles.ts +1119 -0
- package/src/dsh/client/types.ts +366 -0
- package/src/dsh/client/ui.ts +142 -0
- package/src/dsh/index.ts +108 -0
- package/src/dsh/lib/account.ts +520 -0
- package/src/dsh/lib/app-mapping.ts +366 -0
- package/src/dsh/lib/i18n.ts +82 -0
- package/src/dsh/lib/media-enrich.ts +202 -0
- package/src/dsh/lib/notifications.ts +322 -0
- package/src/dsh/lib/performance.ts +279 -0
- package/src/dsh/lib/platform/index.ts +43 -0
- package/src/dsh/lib/probe-adapter.ts +275 -0
- package/src/dsh/lib/probe-daemon.ts +359 -0
- package/src/dsh/lib/probe.ts +395 -0
- package/src/dsh/lib/qr.ts +42 -0
- package/src/dsh/lib/runtime.ts +126 -0
- package/src/dsh/lib/service.ts +1645 -0
- package/src/dsh/lib/sessions.ts +907 -0
- package/src/dsh/lib/settings.ts +468 -0
- package/src/dsh/lib/types.ts +231 -0
- package/src/dsh/lib/util.ts +115 -0
- package/src/dsh/lib/weather.ts +532 -0
- package/src/dsh/lib/ws.ts +328 -0
- package/src/dsh/types/qrcode-generator.d.ts +16 -0
- package/src/rust/Cargo.lock +1431 -0
- package/src/rust/Cargo.toml +68 -0
- package/src/rust/src/cli.rs +233 -0
- package/src/rust/src/daemon.rs +140 -0
- package/src/rust/src/location/linux.rs +118 -0
- package/src/rust/src/location/macos.rs +26 -0
- package/src/rust/src/location/mod.rs +170 -0
- package/src/rust/src/location/windows.rs +205 -0
- package/src/rust/src/main.rs +42 -0
- package/src/rust/src/media/catalog.rs +454 -0
- package/src/rust/src/media/linux.rs +350 -0
- package/src/rust/src/media/macos/accessibility.rs +59 -0
- package/src/rust/src/media/macos.rs +366 -0
- package/src/rust/src/media/mod.rs +298 -0
- package/src/rust/src/media/vendor/apple_music.rs +90 -0
- package/src/rust/src/media/vendor/common.rs +186 -0
- package/src/rust/src/media/vendor/kugou.rs +52 -0
- package/src/rust/src/media/vendor/kuwo.rs +49 -0
- package/src/rust/src/media/vendor/mod.rs +75 -0
- package/src/rust/src/media/vendor/netease.rs +1715 -0
- package/src/rust/src/media/vendor/qishui.rs +36 -0
- package/src/rust/src/media/vendor/qqmusic.rs +33 -0
- package/src/rust/src/media/vendor/spotify.rs +46 -0
- package/src/rust/src/media/vendor/wesing.rs +39 -0
- package/src/rust/src/media/vendor/youtube_music.rs +49 -0
- package/src/rust/src/media/windows/accessibility.rs +85 -0
- package/src/rust/src/media/windows/audio.rs +116 -0
- package/src/rust/src/media/windows/private.rs +291 -0
- package/src/rust/src/media/windows.rs +775 -0
- package/src/rust/src/notifications/linux.rs +276 -0
- package/src/rust/src/notifications/macos.rs +382 -0
- package/src/rust/src/notifications/mod.rs +244 -0
- package/src/rust/src/notifications/windows.rs +565 -0
- package/src/rust/src/perf/common.rs +109 -0
- package/src/rust/src/perf/linux.rs +282 -0
- package/src/rust/src/perf/macos.rs +28 -0
- package/src/rust/src/perf/mod.rs +157 -0
- package/src/rust/src/perf/windows.rs +981 -0
- package/src/rust/src/util.rs +360 -0
- package/src/rust/src/volume/linux.rs +195 -0
- package/src/rust/src/volume/macos.rs +54 -0
- package/src/rust/src/volume/mod.rs +116 -0
- package/src/rust/src/volume/windows.rs +75 -0
- package/src/rust/tests/cli.rs +79 -0
- package/src/rust/tests/daemon.rs +107 -0
- package/src/svelte/App.svelte +385 -0
- package/src/svelte/index.html +18 -0
- package/src/svelte/lib/billing.svelte.ts +228 -0
- package/src/svelte/lib/components/BalanceCard.svelte +173 -0
- package/src/svelte/lib/components/ClockCard.svelte +183 -0
- package/src/svelte/lib/components/CountdownCard.svelte +261 -0
- package/src/svelte/lib/components/CpuMemoryCard.svelte +238 -0
- package/src/svelte/lib/components/EmptyState.svelte +34 -0
- package/src/svelte/lib/components/GpuCard.svelte +245 -0
- package/src/svelte/lib/components/HomePage.svelte +34 -0
- package/src/svelte/lib/components/MusicControls.svelte +256 -0
- package/src/svelte/lib/components/MusicCover.svelte +88 -0
- package/src/svelte/lib/components/MusicPage.svelte +116 -0
- package/src/svelte/lib/components/NotificationsCard.svelte +109 -0
- package/src/svelte/lib/components/Panel.svelte +22 -0
- package/src/svelte/lib/components/PerformancePage.svelte +55 -0
- package/src/svelte/lib/components/PomodoroCard.svelte +250 -0
- package/src/svelte/lib/components/QuestionSheet.svelte +354 -0
- package/src/svelte/lib/components/RadialGauge.svelte +99 -0
- package/src/svelte/lib/components/Rail.svelte +217 -0
- package/src/svelte/lib/components/SectionHeader.svelte +40 -0
- package/src/svelte/lib/components/SeekBar.svelte +421 -0
- package/src/svelte/lib/components/SessionList.svelte +364 -0
- package/src/svelte/lib/components/SessionStats.svelte +98 -0
- package/src/svelte/lib/components/SessionsPage.svelte +61 -0
- package/src/svelte/lib/components/SpendCard.svelte +105 -0
- package/src/svelte/lib/components/ThermalCard.svelte +249 -0
- package/src/svelte/lib/components/Toast.svelte +32 -0
- package/src/svelte/lib/components/WeatherIcon.svelte +40 -0
- package/src/svelte/lib/components/WeatherPanel.svelte +420 -0
- package/src/svelte/lib/components/ui/alert/alert-action.svelte +20 -0
- package/src/svelte/lib/components/ui/alert/alert-description.svelte +23 -0
- package/src/svelte/lib/components/ui/alert/alert-title.svelte +23 -0
- package/src/svelte/lib/components/ui/alert/alert.svelte +43 -0
- package/src/svelte/lib/components/ui/alert/index.ts +17 -0
- package/src/svelte/lib/components/ui/avatar/avatar-badge.svelte +26 -0
- package/src/svelte/lib/components/ui/avatar/avatar-fallback.svelte +20 -0
- package/src/svelte/lib/components/ui/avatar/avatar-group-count.svelte +23 -0
- package/src/svelte/lib/components/ui/avatar/avatar-group.svelte +23 -0
- package/src/svelte/lib/components/ui/avatar/avatar-image.svelte +17 -0
- package/src/svelte/lib/components/ui/avatar/avatar.svelte +26 -0
- package/src/svelte/lib/components/ui/avatar/index.ts +22 -0
- package/src/svelte/lib/components/ui/badge/badge.svelte +49 -0
- package/src/svelte/lib/components/ui/badge/index.ts +2 -0
- package/src/svelte/lib/components/ui/button/button.svelte +82 -0
- package/src/svelte/lib/components/ui/button/index.ts +17 -0
- package/src/svelte/lib/components/ui/card/card-action.svelte +23 -0
- package/src/svelte/lib/components/ui/card/card-content.svelte +20 -0
- package/src/svelte/lib/components/ui/card/card-description.svelte +20 -0
- package/src/svelte/lib/components/ui/card/card-footer.svelte +20 -0
- package/src/svelte/lib/components/ui/card/card-header.svelte +23 -0
- package/src/svelte/lib/components/ui/card/card-title.svelte +20 -0
- package/src/svelte/lib/components/ui/card/card.svelte +22 -0
- package/src/svelte/lib/components/ui/card/index.ts +25 -0
- package/src/svelte/lib/components/ui/dialog/dialog-close.svelte +11 -0
- package/src/svelte/lib/components/ui/dialog/dialog-content.svelte +48 -0
- package/src/svelte/lib/components/ui/dialog/dialog-description.svelte +17 -0
- package/src/svelte/lib/components/ui/dialog/dialog-footer.svelte +32 -0
- package/src/svelte/lib/components/ui/dialog/dialog-header.svelte +20 -0
- package/src/svelte/lib/components/ui/dialog/dialog-overlay.svelte +17 -0
- package/src/svelte/lib/components/ui/dialog/dialog-portal.svelte +7 -0
- package/src/svelte/lib/components/ui/dialog/dialog-title.svelte +17 -0
- package/src/svelte/lib/components/ui/dialog/dialog-trigger.svelte +11 -0
- package/src/svelte/lib/components/ui/dialog/dialog.svelte +7 -0
- package/src/svelte/lib/components/ui/dialog/index.ts +34 -0
- package/src/svelte/lib/components/ui/empty/empty-content.svelte +23 -0
- package/src/svelte/lib/components/ui/empty/empty-description.svelte +23 -0
- package/src/svelte/lib/components/ui/empty/empty-header.svelte +20 -0
- package/src/svelte/lib/components/ui/empty/empty-media.svelte +41 -0
- package/src/svelte/lib/components/ui/empty/empty-title.svelte +20 -0
- package/src/svelte/lib/components/ui/empty/empty.svelte +23 -0
- package/src/svelte/lib/components/ui/empty/index.ts +22 -0
- package/src/svelte/lib/components/ui/input/index.ts +7 -0
- package/src/svelte/lib/components/ui/input/input.svelte +48 -0
- package/src/svelte/lib/components/ui/progress/index.ts +7 -0
- package/src/svelte/lib/components/ui/progress/progress.svelte +27 -0
- package/src/svelte/lib/components/ui/scroll-area/index.ts +10 -0
- package/src/svelte/lib/components/ui/scroll-area/scroll-area-scrollbar.svelte +30 -0
- package/src/svelte/lib/components/ui/scroll-area/scroll-area.svelte +43 -0
- package/src/svelte/lib/components/ui/separator/index.ts +7 -0
- package/src/svelte/lib/components/ui/separator/separator.svelte +21 -0
- package/src/svelte/lib/components/ui/sheet/index.ts +34 -0
- package/src/svelte/lib/components/ui/sheet/sheet-close.svelte +7 -0
- package/src/svelte/lib/components/ui/sheet/sheet-content.svelte +55 -0
- package/src/svelte/lib/components/ui/sheet/sheet-description.svelte +17 -0
- package/src/svelte/lib/components/ui/sheet/sheet-footer.svelte +20 -0
- package/src/svelte/lib/components/ui/sheet/sheet-header.svelte +20 -0
- package/src/svelte/lib/components/ui/sheet/sheet-overlay.svelte +20 -0
- package/src/svelte/lib/components/ui/sheet/sheet-portal.svelte +7 -0
- package/src/svelte/lib/components/ui/sheet/sheet-title.svelte +17 -0
- package/src/svelte/lib/components/ui/sheet/sheet-trigger.svelte +7 -0
- package/src/svelte/lib/components/ui/sheet/sheet.svelte +7 -0
- package/src/svelte/lib/components/ui/skeleton/index.ts +7 -0
- package/src/svelte/lib/components/ui/skeleton/skeleton.svelte +17 -0
- package/src/svelte/lib/components/ui/slider/index.ts +7 -0
- package/src/svelte/lib/components/ui/slider/slider.svelte +52 -0
- package/src/svelte/lib/components/ui/tooltip/index.ts +19 -0
- package/src/svelte/lib/components/ui/tooltip/tooltip-content.svelte +51 -0
- package/src/svelte/lib/components/ui/tooltip/tooltip-portal.svelte +7 -0
- package/src/svelte/lib/components/ui/tooltip/tooltip-provider.svelte +7 -0
- package/src/svelte/lib/components/ui/tooltip/tooltip-trigger.svelte +7 -0
- package/src/svelte/lib/components/ui/tooltip/tooltip.svelte +7 -0
- package/src/svelte/lib/countdown.svelte.ts +252 -0
- package/src/svelte/lib/format.ts +199 -0
- package/src/svelte/lib/i18n.svelte.ts +583 -0
- package/src/svelte/lib/media.ts +32 -0
- package/src/svelte/lib/pages.ts +18 -0
- package/src/svelte/lib/pomodoro.svelte.ts +223 -0
- package/src/svelte/lib/session-tree.ts +80 -0
- package/src/svelte/lib/state.svelte.ts +359 -0
- package/src/svelte/lib/timer-alarm.svelte.ts +319 -0
- package/src/svelte/lib/types.ts +306 -0
- package/src/svelte/lib/utils.ts +8 -0
- package/src/svelte/lib/weather.ts +84 -0
- package/src/svelte/lib/ws.ts +104 -0
- package/src/svelte/main.ts +13 -0
- package/src/svelte/styles/global.css +315 -0
- package/src/svelte/vite-env.d.ts +12 -0
- package/static/fonts/LICENSE.txt +287 -0
- package/static/icon.svg +24 -0
- package/static/manifest.webmanifest +18 -0
- package/svelte.config.js +5 -0
- package/tsconfig.dsh-client.json +18 -0
- package/tsconfig.dsh.json +21 -0
- package/tsconfig.json +20 -0
- package/vite.config.js +31 -0
- package/web/assets/index-DLdSfnJ3.css +1 -0
- package/web/assets/index-YNE8X0Uy.js +6 -0
- package/web/assets/inter-cyrillic-ext-wght-normal-BOeWTOD4.woff2 +0 -0
- package/web/assets/inter-cyrillic-wght-normal-DqGufNeO.woff2 +0 -0
- package/web/assets/inter-greek-ext-wght-normal-DlzME5K_.woff2 +0 -0
- package/web/assets/inter-greek-wght-normal-CkhJZR-_.woff2 +0 -0
- package/web/assets/inter-latin-ext-wght-normal-DO1Apj_S.woff2 +0 -0
- package/web/assets/inter-latin-wght-normal-Dx4kXJAl.woff2 +0 -0
- package/web/assets/inter-vietnamese-wght-normal-CBcvBZtf.woff2 +0 -0
- package/web/assets/jetbrains-mono-cyrillic-ext-wght-normal-EocZY2iu.woff2 +0 -0
- package/web/assets/jetbrains-mono-cyrillic-wght-normal-D73BlboJ.woff2 +0 -0
- package/web/assets/jetbrains-mono-greek-wght-normal-Bw9x6K1M.woff2 +0 -0
- package/web/assets/jetbrains-mono-latin-ext-wght-normal-DBQx-q_a.woff2 +0 -0
- package/web/assets/jetbrains-mono-latin-wght-normal-B9CIFXIH.woff2 +0 -0
- package/web/assets/jetbrains-mono-vietnamese-wght-normal-Bt-aOZkq.woff2 +0 -0
- package/web/assets/noto-sans-sc-100-wght-normal-DluiXYzi.woff2 +0 -0
- package/web/assets/noto-sans-sc-101-wght-normal-CPkZHnw0.woff2 +0 -0
- package/web/assets/noto-sans-sc-102-wght-normal-gzIulUH6.woff2 +0 -0
- package/web/assets/noto-sans-sc-103-wght-normal-CJfSBxFo.woff2 +0 -0
- package/web/assets/noto-sans-sc-104-wght-normal-B3QMglgE.woff2 +0 -0
- package/web/assets/noto-sans-sc-105-wght-normal-xXh_OMfk.woff2 +0 -0
- package/web/assets/noto-sans-sc-106-wght-normal-B9n3jMjP.woff2 +0 -0
- package/web/assets/noto-sans-sc-107-wght-normal-D7fvVprN.woff2 +0 -0
- package/web/assets/noto-sans-sc-108-wght-normal-J0_LhxVo.woff2 +0 -0
- package/web/assets/noto-sans-sc-109-wght-normal-Dsp-De_0.woff2 +0 -0
- package/web/assets/noto-sans-sc-110-wght-normal-DE_6NUrb.woff2 +0 -0
- package/web/assets/noto-sans-sc-111-wght-normal-C4S-TlTn.woff2 +0 -0
- package/web/assets/noto-sans-sc-112-wght-normal-BcFuP3w6.woff2 +0 -0
- package/web/assets/noto-sans-sc-113-wght-normal-Dk932kmj.woff2 +0 -0
- package/web/assets/noto-sans-sc-114-wght-normal-CO_5Xo-i.woff2 +0 -0
- package/web/assets/noto-sans-sc-115-wght-normal-BWy07H14.woff2 +0 -0
- package/web/assets/noto-sans-sc-116-wght-normal-B4HVAfHo.woff2 +0 -0
- package/web/assets/noto-sans-sc-117-wght-normal-siZzFqgK.woff2 +0 -0
- package/web/assets/noto-sans-sc-118-wght-normal-xhBB7f6V.woff2 +0 -0
- package/web/assets/noto-sans-sc-119-wght-normal-Ck_g2FGz.woff2 +0 -0
- package/web/assets/noto-sans-sc-21-wght-normal-D0x9-yBt.woff2 +0 -0
- package/web/assets/noto-sans-sc-22-wght-normal-BBUVTShg.woff2 +0 -0
- package/web/assets/noto-sans-sc-23-wght-normal-Du1oYWkE.woff2 +0 -0
- package/web/assets/noto-sans-sc-24-wght-normal-CmWjJ0gt.woff2 +0 -0
- package/web/assets/noto-sans-sc-25-wght-normal-BFHiqilg.woff2 +0 -0
- package/web/assets/noto-sans-sc-26-wght-normal-C0sF2Z2f.woff2 +0 -0
- package/web/assets/noto-sans-sc-27-wght-normal-COFdrquJ.woff2 +0 -0
- package/web/assets/noto-sans-sc-28-wght-normal-DMgdNu1o.woff2 +0 -0
- package/web/assets/noto-sans-sc-29-wght-normal-Cmq8em30.woff2 +0 -0
- package/web/assets/noto-sans-sc-30-wght-normal-CZWqZ3yU.woff2 +0 -0
- package/web/assets/noto-sans-sc-31-wght-normal-Wfi_lutW.woff2 +0 -0
- package/web/assets/noto-sans-sc-32-wght-normal-BRJQ4PY5.woff2 +0 -0
- package/web/assets/noto-sans-sc-33-wght-normal-CUVQXNAJ.woff2 +0 -0
- package/web/assets/noto-sans-sc-34-wght-normal-Bspba0wC.woff2 +0 -0
- package/web/assets/noto-sans-sc-35-wght-normal-K8fX_YPG.woff2 +0 -0
- package/web/assets/noto-sans-sc-36-wght-normal-CkITyjoT.woff2 +0 -0
- package/web/assets/noto-sans-sc-37-wght-normal-WCZ2zfEe.woff2 +0 -0
- package/web/assets/noto-sans-sc-38-wght-normal-DeM7CUce.woff2 +0 -0
- package/web/assets/noto-sans-sc-39-wght-normal-BMZNLWQU.woff2 +0 -0
- package/web/assets/noto-sans-sc-4-wght-normal-AR5bdDjz.woff2 +0 -0
- package/web/assets/noto-sans-sc-40-wght-normal-BQ5xpS5j.woff2 +0 -0
- package/web/assets/noto-sans-sc-41-wght-normal-Hthm7FFi.woff2 +0 -0
- package/web/assets/noto-sans-sc-42-wght-normal-eaS2gKds.woff2 +0 -0
- package/web/assets/noto-sans-sc-43-wght-normal-o-T53XXV.woff2 +0 -0
- package/web/assets/noto-sans-sc-44-wght-normal-BJH5J4Ez.woff2 +0 -0
- package/web/assets/noto-sans-sc-45-wght-normal-BKuxSCOJ.woff2 +0 -0
- package/web/assets/noto-sans-sc-46-wght-normal-BR_5Mu6e.woff2 +0 -0
- package/web/assets/noto-sans-sc-47-wght-normal-CyY7gKNX.woff2 +0 -0
- package/web/assets/noto-sans-sc-48-wght-normal-BNMfTR6k.woff2 +0 -0
- package/web/assets/noto-sans-sc-49-wght-normal-DX-0y7wg.woff2 +0 -0
- package/web/assets/noto-sans-sc-5-wght-normal-CfWugllB.woff2 +0 -0
- package/web/assets/noto-sans-sc-50-wght-normal-DAOGW-Dr.woff2 +0 -0
- package/web/assets/noto-sans-sc-51-wght-normal-BlFLOjcP.woff2 +0 -0
- package/web/assets/noto-sans-sc-52-wght-normal-OZjrybnw.woff2 +0 -0
- package/web/assets/noto-sans-sc-53-wght-normal-CwyWNT6x.woff2 +0 -0
- package/web/assets/noto-sans-sc-54-wght-normal-DM0nRe18.woff2 +0 -0
- package/web/assets/noto-sans-sc-55-wght-normal-DBK2wUOR.woff2 +0 -0
- package/web/assets/noto-sans-sc-56-wght-normal-C-VKK1LS.woff2 +0 -0
- package/web/assets/noto-sans-sc-57-wght-normal-Cdbfh5kq.woff2 +0 -0
- package/web/assets/noto-sans-sc-58-wght-normal-CflMKARZ.woff2 +0 -0
- package/web/assets/noto-sans-sc-59-wght-normal-BS4Kwzxx.woff2 +0 -0
- package/web/assets/noto-sans-sc-6-wght-normal-ChnZIQfQ.woff2 +0 -0
- package/web/assets/noto-sans-sc-60-wght-normal-B7QOYsXJ.woff2 +0 -0
- package/web/assets/noto-sans-sc-61-wght-normal-C8JjQS7w.woff2 +0 -0
- package/web/assets/noto-sans-sc-62-wght-normal-bS4wq1Gg.woff2 +0 -0
- package/web/assets/noto-sans-sc-63-wght-normal-BJr8P-OB.woff2 +0 -0
- package/web/assets/noto-sans-sc-64-wght-normal-DVB11t7j.woff2 +0 -0
- package/web/assets/noto-sans-sc-65-wght-normal-DMPCXBvK.woff2 +0 -0
- package/web/assets/noto-sans-sc-66-wght-normal-BobaG10V.woff2 +0 -0
- package/web/assets/noto-sans-sc-67-wght-normal-Dzk7WhCR.woff2 +0 -0
- package/web/assets/noto-sans-sc-68-wght-normal-DGbCD9xu.woff2 +0 -0
- package/web/assets/noto-sans-sc-69-wght-normal-Ctrv1EqA.woff2 +0 -0
- package/web/assets/noto-sans-sc-70-wght-normal-RgTO941D.woff2 +0 -0
- package/web/assets/noto-sans-sc-71-wght-normal-D9sG-CWv.woff2 +0 -0
- package/web/assets/noto-sans-sc-72-wght-normal-C4oWy3ul.woff2 +0 -0
- package/web/assets/noto-sans-sc-73-wght-normal-B1ZoOTgM.woff2 +0 -0
- package/web/assets/noto-sans-sc-74-wght-normal-F7dH_rZJ.woff2 +0 -0
- package/web/assets/noto-sans-sc-75-wght-normal-Cp2wp4si.woff2 +0 -0
- package/web/assets/noto-sans-sc-76-wght-normal-B494D7xS.woff2 +0 -0
- package/web/assets/noto-sans-sc-77-wght-normal-B3MVY9Ax.woff2 +0 -0
- package/web/assets/noto-sans-sc-78-wght-normal-5jX7iNMC.woff2 +0 -0
- package/web/assets/noto-sans-sc-79-wght-normal-BIoZy8fr.woff2 +0 -0
- package/web/assets/noto-sans-sc-80-wght-normal-Bje1Fxy1.woff2 +0 -0
- package/web/assets/noto-sans-sc-81-wght-normal-B2NN7Qi3.woff2 +0 -0
- package/web/assets/noto-sans-sc-82-wght-normal-CUggNZi4.woff2 +0 -0
- package/web/assets/noto-sans-sc-83-wght-normal-99rD8YO-.woff2 +0 -0
- package/web/assets/noto-sans-sc-84-wght-normal-zMBmUocm.woff2 +0 -0
- package/web/assets/noto-sans-sc-85-wght-normal-CjI3qdxG.woff2 +0 -0
- package/web/assets/noto-sans-sc-86-wght-normal-BHY8TVEH.woff2 +0 -0
- package/web/assets/noto-sans-sc-87-wght-normal-DioZSHnU.woff2 +0 -0
- package/web/assets/noto-sans-sc-88-wght-normal-BXYxwf2t.woff2 +0 -0
- package/web/assets/noto-sans-sc-89-wght-normal-ClMFrFaL.woff2 +0 -0
- package/web/assets/noto-sans-sc-90-wght-normal-BnOlPreP.woff2 +0 -0
- package/web/assets/noto-sans-sc-91-wght-normal-DTr9RQcS.woff2 +0 -0
- package/web/assets/noto-sans-sc-97-wght-normal-9u6Aiav-.woff2 +0 -0
- package/web/assets/noto-sans-sc-98-wght-normal-BR-H2C0V.woff2 +0 -0
- package/web/assets/noto-sans-sc-99-wght-normal-BI6XPoxp.woff2 +0 -0
- package/web/assets/noto-sans-sc-cyrillic-wght-normal-BGmsQlw-.woff2 +0 -0
- package/web/assets/noto-sans-sc-latin-ext-wght-normal-DuJTpTg_.woff2 +0 -0
- package/web/assets/noto-sans-sc-latin-wght-normal-DDW8mKAR.woff2 +0 -0
- package/web/assets/noto-sans-sc-vietnamese-wght-normal-Bi3ATJ76.woff2 +0 -0
- package/web/fonts/LICENSE.txt +287 -0
- package/web/icon.svg +24 -0
- package/web/index.html +19 -0
- package/web/manifest.webmanifest +18 -0
|
@@ -0,0 +1,238 @@
|
|
|
1
|
+
<script lang="ts">
|
|
2
|
+
import { app } from '../state.svelte';
|
|
3
|
+
import { formatBytes, formatUptime } from '../format';
|
|
4
|
+
import { t } from '../i18n.svelte';
|
|
5
|
+
import { Badge } from '$lib/components/ui/badge/index.js';
|
|
6
|
+
import Cpu from '@lucide/svelte/icons/cpu';
|
|
7
|
+
import Panel from './Panel.svelte';
|
|
8
|
+
import RadialGauge from './RadialGauge.svelte';
|
|
9
|
+
|
|
10
|
+
const data = $derived(app.performance);
|
|
11
|
+
const loaded = $derived(data !== null);
|
|
12
|
+
const cpu = $derived(data?.cpu || {});
|
|
13
|
+
const memory = $derived(data?.memory || {});
|
|
14
|
+
|
|
15
|
+
const cpuUsage = $derived(Number(cpu.usage));
|
|
16
|
+
const cpuPercent = $derived(Number.isFinite(cpuUsage) ? Math.max(0, Math.min(100, cpuUsage)) : 0);
|
|
17
|
+
const cpuModel = $derived(String(cpu.model || '').trim());
|
|
18
|
+
const cpuHeader = $derived(loaded ? cpuModel || t('currentStatus') : t('sessionLoading'));
|
|
19
|
+
|
|
20
|
+
const speed = $derived.by(() => {
|
|
21
|
+
const value = Number(cpu.speed);
|
|
22
|
+
return Number.isFinite(value) && value > 0 ? `${(value / 1000).toFixed(2)} GHz` : '—';
|
|
23
|
+
});
|
|
24
|
+
const uptime = $derived(loaded ? formatUptime(cpu.uptime) : '—');
|
|
25
|
+
const threadChip = $derived.by(() => {
|
|
26
|
+
const cores = Number(cpu.cores);
|
|
27
|
+
if (!Number.isFinite(cores) || cores <= 0) return '—';
|
|
28
|
+
return cores === 1 ? t('threadCountOne') : t('threadCount', { count: cores });
|
|
29
|
+
});
|
|
30
|
+
|
|
31
|
+
const memoryPercent = $derived(Number(memory.percent));
|
|
32
|
+
const percentShown = $derived(
|
|
33
|
+
Number.isFinite(memoryPercent) ? Math.max(0, Math.min(100, Math.round(memoryPercent))) : 0,
|
|
34
|
+
);
|
|
35
|
+
const memoryTotal = $derived(formatBytes(memory.total));
|
|
36
|
+
const memoryFree = $derived(formatBytes(memory.free));
|
|
37
|
+
const memoryUsed = $derived(formatBytes(memory.used));
|
|
38
|
+
</script>
|
|
39
|
+
|
|
40
|
+
<Panel class="system-card relative flex min-h-0 flex-col overflow-hidden p-4">
|
|
41
|
+
<div class="perf-glow" aria-hidden="true"></div>
|
|
42
|
+
|
|
43
|
+
<header class="relative z-10 flex items-center gap-3">
|
|
44
|
+
<span class="grid size-11 shrink-0 place-items-center rounded-[13px] border border-border bg-secondary text-brand">
|
|
45
|
+
<Cpu class="size-[24px]" strokeWidth={1.7} />
|
|
46
|
+
</span>
|
|
47
|
+
<div class="min-w-0">
|
|
48
|
+
<p class="eyebrow">SYSTEM</p>
|
|
49
|
+
<h2 class="mt-0.5 truncate text-[24px] leading-tight font-semibold tracking-[-0.03em] text-foreground">
|
|
50
|
+
{t('cpuMemory')}
|
|
51
|
+
</h2>
|
|
52
|
+
</div>
|
|
53
|
+
<p class="ml-auto max-w-[46%] truncate text-right text-[14px] text-muted-foreground" title={cpuModel}>
|
|
54
|
+
{cpuHeader}
|
|
55
|
+
</p>
|
|
56
|
+
</header>
|
|
57
|
+
|
|
58
|
+
<div class="pane-grid relative z-10">
|
|
59
|
+
<section class="usage-pane">
|
|
60
|
+
<div class="pane-head flex items-center justify-between gap-2.5">
|
|
61
|
+
<span class="eyebrow">CPU</span>
|
|
62
|
+
<Badge
|
|
63
|
+
variant="outline"
|
|
64
|
+
class="h-6 border-border bg-secondary px-2 text-[11px] font-medium text-muted-foreground"
|
|
65
|
+
>
|
|
66
|
+
{threadChip}
|
|
67
|
+
</Badge>
|
|
68
|
+
</div>
|
|
69
|
+
|
|
70
|
+
<div class="pane-body">
|
|
71
|
+
<RadialGauge value={cpuPercent} color="var(--brand)" />
|
|
72
|
+
<div class="grid w-full grid-cols-2 gap-2">
|
|
73
|
+
<div class="fact-tile">
|
|
74
|
+
<span>{t('currentFrequency')}</span>
|
|
75
|
+
<b class="numeric">{speed}</b>
|
|
76
|
+
</div>
|
|
77
|
+
<div class="fact-tile">
|
|
78
|
+
<span>{t('runningTime')}</span>
|
|
79
|
+
<b class="numeric">{uptime}</b>
|
|
80
|
+
</div>
|
|
81
|
+
</div>
|
|
82
|
+
</div>
|
|
83
|
+
</section>
|
|
84
|
+
|
|
85
|
+
<section class="usage-pane is-right">
|
|
86
|
+
<div class="pane-head flex items-center justify-between gap-2.5">
|
|
87
|
+
<span class="eyebrow">MEMORY</span>
|
|
88
|
+
<Badge
|
|
89
|
+
variant="outline"
|
|
90
|
+
class="h-6 border-border bg-secondary px-2 text-[11px] font-medium text-muted-foreground"
|
|
91
|
+
>
|
|
92
|
+
{memoryTotal}
|
|
93
|
+
</Badge>
|
|
94
|
+
</div>
|
|
95
|
+
|
|
96
|
+
<div class="pane-body">
|
|
97
|
+
<RadialGauge value={percentShown} color="var(--success)" />
|
|
98
|
+
<div class="grid w-full grid-cols-2 gap-2">
|
|
99
|
+
<div class="fact-tile">
|
|
100
|
+
<span>{t('memoryUsed')}</span>
|
|
101
|
+
<b class="numeric">{memoryUsed}</b>
|
|
102
|
+
</div>
|
|
103
|
+
<div class="fact-tile">
|
|
104
|
+
<span>{t('memoryFree')}</span>
|
|
105
|
+
<b class="numeric">{memoryFree}</b>
|
|
106
|
+
</div>
|
|
107
|
+
</div>
|
|
108
|
+
</div>
|
|
109
|
+
</section>
|
|
110
|
+
</div>
|
|
111
|
+
</Panel>
|
|
112
|
+
|
|
113
|
+
<style>
|
|
114
|
+
:global(.system-card) {
|
|
115
|
+
background:
|
|
116
|
+
radial-gradient(90% 110% at 100% 0%, color-mix(in srgb, var(--brand) 8%, transparent), transparent 57%),
|
|
117
|
+
var(--card);
|
|
118
|
+
}
|
|
119
|
+
|
|
120
|
+
.perf-glow {
|
|
121
|
+
position: absolute;
|
|
122
|
+
right: -70px;
|
|
123
|
+
bottom: -110px;
|
|
124
|
+
width: 210px;
|
|
125
|
+
height: 210px;
|
|
126
|
+
border-radius: 50%;
|
|
127
|
+
border: 1px solid color-mix(in srgb, var(--brand) 11%, transparent);
|
|
128
|
+
pointer-events: none;
|
|
129
|
+
}
|
|
130
|
+
|
|
131
|
+
.pane-grid {
|
|
132
|
+
display: grid;
|
|
133
|
+
grid-template-columns: repeat(2, minmax(0, 1fr));
|
|
134
|
+
flex: 1;
|
|
135
|
+
min-height: 0;
|
|
136
|
+
margin-top: 10px;
|
|
137
|
+
border-top: 1px solid var(--border);
|
|
138
|
+
}
|
|
139
|
+
|
|
140
|
+
.usage-pane {
|
|
141
|
+
display: flex;
|
|
142
|
+
min-width: 0;
|
|
143
|
+
min-height: 0;
|
|
144
|
+
flex-direction: column;
|
|
145
|
+
padding-top: 8px;
|
|
146
|
+
padding-right: 12px;
|
|
147
|
+
}
|
|
148
|
+
|
|
149
|
+
.usage-pane.is-right {
|
|
150
|
+
margin-left: 0;
|
|
151
|
+
padding-right: 0;
|
|
152
|
+
padding-left: 12px;
|
|
153
|
+
border-left: 1px solid var(--border);
|
|
154
|
+
}
|
|
155
|
+
|
|
156
|
+
.pane-body {
|
|
157
|
+
display: flex;
|
|
158
|
+
flex: 1;
|
|
159
|
+
min-height: 0;
|
|
160
|
+
flex-direction: column;
|
|
161
|
+
align-items: center;
|
|
162
|
+
justify-content: center;
|
|
163
|
+
gap: 7px;
|
|
164
|
+
padding-top: 2px;
|
|
165
|
+
}
|
|
166
|
+
|
|
167
|
+
.fact-tile {
|
|
168
|
+
display: flex;
|
|
169
|
+
min-width: 0;
|
|
170
|
+
flex-direction: column;
|
|
171
|
+
align-items: center;
|
|
172
|
+
gap: 1px;
|
|
173
|
+
padding: 6px 7px;
|
|
174
|
+
border: 1px solid var(--border);
|
|
175
|
+
border-radius: 10px;
|
|
176
|
+
background: color-mix(in srgb, var(--secondary) 48%, transparent);
|
|
177
|
+
text-align: center;
|
|
178
|
+
}
|
|
179
|
+
|
|
180
|
+
.fact-tile span {
|
|
181
|
+
color: var(--muted-foreground);
|
|
182
|
+
font-size: 11px;
|
|
183
|
+
white-space: nowrap;
|
|
184
|
+
}
|
|
185
|
+
|
|
186
|
+
.fact-tile b {
|
|
187
|
+
overflow: hidden;
|
|
188
|
+
max-width: 100%;
|
|
189
|
+
color: var(--foreground);
|
|
190
|
+
font-size: clamp(13px, 1.6vw, 16px);
|
|
191
|
+
font-weight: 550;
|
|
192
|
+
text-overflow: ellipsis;
|
|
193
|
+
white-space: nowrap;
|
|
194
|
+
}
|
|
195
|
+
|
|
196
|
+
@media (max-height: 760px) {
|
|
197
|
+
:global(.system-card) {
|
|
198
|
+
padding: 12px;
|
|
199
|
+
}
|
|
200
|
+
|
|
201
|
+
.pane-grid {
|
|
202
|
+
margin-top: 7px;
|
|
203
|
+
}
|
|
204
|
+
|
|
205
|
+
.usage-pane {
|
|
206
|
+
padding-top: 6px;
|
|
207
|
+
padding-right: 10px;
|
|
208
|
+
}
|
|
209
|
+
|
|
210
|
+
.usage-pane.is-right {
|
|
211
|
+
margin-left: 0;
|
|
212
|
+
padding-right: 0;
|
|
213
|
+
padding-left: 10px;
|
|
214
|
+
}
|
|
215
|
+
|
|
216
|
+
.pane-body {
|
|
217
|
+
gap: 5px;
|
|
218
|
+
}
|
|
219
|
+
|
|
220
|
+
.fact-tile {
|
|
221
|
+
padding: 5px 7px;
|
|
222
|
+
}
|
|
223
|
+
|
|
224
|
+
.fact-tile span {
|
|
225
|
+
font-size: 12px;
|
|
226
|
+
}
|
|
227
|
+
|
|
228
|
+
.fact-tile b {
|
|
229
|
+
font-size: 14px;
|
|
230
|
+
}
|
|
231
|
+
}
|
|
232
|
+
|
|
233
|
+
@media (orientation: portrait) {
|
|
234
|
+
:global(.system-card) {
|
|
235
|
+
min-height: 320px;
|
|
236
|
+
}
|
|
237
|
+
}
|
|
238
|
+
</style>
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
<script lang="ts">
|
|
2
|
+
import type { Component } from 'svelte';
|
|
3
|
+
import {
|
|
4
|
+
Empty,
|
|
5
|
+
EmptyDescription,
|
|
6
|
+
EmptyHeader,
|
|
7
|
+
EmptyMedia,
|
|
8
|
+
EmptyTitle,
|
|
9
|
+
} from '$lib/components/ui/empty/index.js';
|
|
10
|
+
import { cn } from '$lib/utils.js';
|
|
11
|
+
import Inbox from '@lucide/svelte/icons/inbox';
|
|
12
|
+
|
|
13
|
+
let {
|
|
14
|
+
icon: Icon = Inbox,
|
|
15
|
+
title = '',
|
|
16
|
+
text = '',
|
|
17
|
+
class: className = '',
|
|
18
|
+
}: {
|
|
19
|
+
icon?: Component<{ class?: string; strokeWidth?: number }>;
|
|
20
|
+
title?: string;
|
|
21
|
+
text?: string;
|
|
22
|
+
class?: string;
|
|
23
|
+
} = $props();
|
|
24
|
+
</script>
|
|
25
|
+
|
|
26
|
+
<Empty class={cn('gap-4 border-0 p-6 text-center', className)}>
|
|
27
|
+
<EmptyMedia variant="icon" class="mb-0 size-14 rounded-[16px] border border-border bg-secondary text-brand">
|
|
28
|
+
<Icon class="size-[26px]" strokeWidth={1.7} />
|
|
29
|
+
</EmptyMedia>
|
|
30
|
+
<EmptyHeader class="max-w-none gap-1.5">
|
|
31
|
+
<EmptyTitle class="text-[20px] font-medium text-foreground">{title}</EmptyTitle>
|
|
32
|
+
{#if text}<EmptyDescription class="text-[15px] leading-relaxed">{text}</EmptyDescription>{/if}
|
|
33
|
+
</EmptyHeader>
|
|
34
|
+
</Empty>
|
|
@@ -0,0 +1,245 @@
|
|
|
1
|
+
<script lang="ts">
|
|
2
|
+
import { app } from '../state.svelte';
|
|
3
|
+
import { formatBytes } from '../format';
|
|
4
|
+
import { t } from '../i18n.svelte';
|
|
5
|
+
import { Badge } from '$lib/components/ui/badge/index.js';
|
|
6
|
+
import Monitor from '@lucide/svelte/icons/monitor';
|
|
7
|
+
import Panel from './Panel.svelte';
|
|
8
|
+
import RadialGauge from './RadialGauge.svelte';
|
|
9
|
+
|
|
10
|
+
const data = $derived(app.performance);
|
|
11
|
+
const loaded = $derived(data !== null);
|
|
12
|
+
const gpu = $derived(data?.gpu || {});
|
|
13
|
+
const gpuModel = $derived(String(gpu.name || '').trim());
|
|
14
|
+
const unavailable = $derived(loaded && gpu.ok === false);
|
|
15
|
+
const gpuHeader = $derived(!loaded
|
|
16
|
+
? t('sessionLoading')
|
|
17
|
+
: unavailable
|
|
18
|
+
? t('unavailableShort')
|
|
19
|
+
: gpuModel || t('noDiscreteGpu'));
|
|
20
|
+
|
|
21
|
+
const usage = $derived(Number(gpu.utilization));
|
|
22
|
+
const usagePercent = $derived(Number.isFinite(usage) ? Math.max(0, Math.min(100, usage)) : 0);
|
|
23
|
+
|
|
24
|
+
function clock(value: unknown): string {
|
|
25
|
+
if (value === null || value === undefined) return '—';
|
|
26
|
+
const number = Number(value);
|
|
27
|
+
if (!Number.isFinite(number) || number < 0) return '—';
|
|
28
|
+
return number >= 1000 ? `${(number / 1000).toFixed(2)} GHz` : `${Math.round(number)} MHz`;
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
const coreClock = $derived(clock(gpu.coreClockMhz));
|
|
32
|
+
const memoryClock = $derived(clock(gpu.memoryClockMhz));
|
|
33
|
+
const vramTotal = $derived(gpu.memoryTotal ? formatBytes(gpu.memoryTotal) : '—');
|
|
34
|
+
const vramUsed = $derived(gpu.memoryUsed ? formatBytes(gpu.memoryUsed) : '—');
|
|
35
|
+
const vramFree = $derived(
|
|
36
|
+
Number(gpu.memoryTotal) > 0 && Number(gpu.memoryUsed) >= 0
|
|
37
|
+
? formatBytes(Math.max(0, Number(gpu.memoryTotal) - Number(gpu.memoryUsed)))
|
|
38
|
+
: '—',
|
|
39
|
+
);
|
|
40
|
+
const vramPercent = $derived(
|
|
41
|
+
Number.isFinite(Number(gpu.memoryPercent)) ? Math.max(0, Math.min(100, Math.round(Number(gpu.memoryPercent)))) : 0,
|
|
42
|
+
);
|
|
43
|
+
const driver = $derived(typeof gpu.driver === 'string' && gpu.driver.trim() ? gpu.driver.trim() : '');
|
|
44
|
+
</script>
|
|
45
|
+
|
|
46
|
+
<Panel class="graphics-card relative flex min-h-0 flex-col overflow-hidden p-4">
|
|
47
|
+
<div class="perf-glow" aria-hidden="true"></div>
|
|
48
|
+
|
|
49
|
+
<header class="relative z-10 flex items-center gap-3">
|
|
50
|
+
<span class="grid size-11 shrink-0 place-items-center rounded-[13px] border border-border bg-secondary text-brand">
|
|
51
|
+
<Monitor class="size-[24px]" strokeWidth={1.7} />
|
|
52
|
+
</span>
|
|
53
|
+
<div class="min-w-0">
|
|
54
|
+
<p class="eyebrow">GRAPHICS</p>
|
|
55
|
+
<h2 class="mt-0.5 truncate text-[24px] leading-tight font-semibold tracking-[-0.03em] text-foreground">
|
|
56
|
+
{t('gpuMemory')}
|
|
57
|
+
</h2>
|
|
58
|
+
</div>
|
|
59
|
+
<p class="ml-auto max-w-[40%] truncate text-right text-[14px] text-muted-foreground" title={gpuModel}>
|
|
60
|
+
{gpuHeader}
|
|
61
|
+
</p>
|
|
62
|
+
</header>
|
|
63
|
+
|
|
64
|
+
<div class="pane-grid relative z-10">
|
|
65
|
+
<section class="usage-pane">
|
|
66
|
+
<div class="pane-head flex items-center justify-between gap-2.5">
|
|
67
|
+
<span class="eyebrow">GPU</span>
|
|
68
|
+
<Badge
|
|
69
|
+
variant="outline"
|
|
70
|
+
class="h-6 max-w-[72%] border-border bg-secondary px-2 text-[11px] font-medium text-muted-foreground"
|
|
71
|
+
title={driver ? t('driverValue', { name: driver }) : t('driverUnknown')}
|
|
72
|
+
>
|
|
73
|
+
<span class="truncate">{driver ? t('driverValue', { name: driver }) : t('driverNone')}</span>
|
|
74
|
+
</Badge>
|
|
75
|
+
</div>
|
|
76
|
+
|
|
77
|
+
<div class="pane-body">
|
|
78
|
+
<RadialGauge value={usagePercent} color="var(--chart-4)" />
|
|
79
|
+
<div class="grid w-full grid-cols-2 gap-2">
|
|
80
|
+
<div class="fact-tile">
|
|
81
|
+
<span>{t('coreClock')}</span>
|
|
82
|
+
<b class="numeric">{coreClock}</b>
|
|
83
|
+
</div>
|
|
84
|
+
<div class="fact-tile">
|
|
85
|
+
<span>{t('memoryClock')}</span>
|
|
86
|
+
<b class="numeric">{memoryClock}</b>
|
|
87
|
+
</div>
|
|
88
|
+
</div>
|
|
89
|
+
</div>
|
|
90
|
+
</section>
|
|
91
|
+
|
|
92
|
+
<section class="usage-pane is-right">
|
|
93
|
+
<div class="pane-head flex items-center justify-between gap-2.5">
|
|
94
|
+
<span class="eyebrow">VRAM</span>
|
|
95
|
+
<Badge
|
|
96
|
+
variant="outline"
|
|
97
|
+
class="h-6 border-border bg-secondary px-2 text-[11px] font-medium text-muted-foreground"
|
|
98
|
+
>
|
|
99
|
+
{vramTotal}
|
|
100
|
+
</Badge>
|
|
101
|
+
</div>
|
|
102
|
+
|
|
103
|
+
<div class="pane-body">
|
|
104
|
+
<RadialGauge value={vramPercent} color="var(--chart-2)" />
|
|
105
|
+
<div class="grid w-full grid-cols-2 gap-2">
|
|
106
|
+
<div class="fact-tile">
|
|
107
|
+
<span>{t('memoryUsed')}</span>
|
|
108
|
+
<b class="numeric">{vramUsed}</b>
|
|
109
|
+
</div>
|
|
110
|
+
<div class="fact-tile">
|
|
111
|
+
<span>{t('memoryFree')}</span>
|
|
112
|
+
<b class="numeric">{vramFree}</b>
|
|
113
|
+
</div>
|
|
114
|
+
</div>
|
|
115
|
+
</div>
|
|
116
|
+
</section>
|
|
117
|
+
</div>
|
|
118
|
+
</Panel>
|
|
119
|
+
|
|
120
|
+
<style>
|
|
121
|
+
:global(.graphics-card) {
|
|
122
|
+
background:
|
|
123
|
+
radial-gradient(90% 110% at 100% 0%, color-mix(in srgb, var(--chart-4) 7%, transparent), transparent 57%),
|
|
124
|
+
var(--card);
|
|
125
|
+
}
|
|
126
|
+
|
|
127
|
+
.perf-glow {
|
|
128
|
+
position: absolute;
|
|
129
|
+
right: -70px;
|
|
130
|
+
bottom: -110px;
|
|
131
|
+
width: 210px;
|
|
132
|
+
height: 210px;
|
|
133
|
+
border-radius: 50%;
|
|
134
|
+
border: 1px solid color-mix(in srgb, var(--chart-4) 11%, transparent);
|
|
135
|
+
pointer-events: none;
|
|
136
|
+
}
|
|
137
|
+
|
|
138
|
+
.pane-grid {
|
|
139
|
+
display: grid;
|
|
140
|
+
grid-template-columns: repeat(2, minmax(0, 1fr));
|
|
141
|
+
flex: 1;
|
|
142
|
+
min-height: 0;
|
|
143
|
+
margin-top: 10px;
|
|
144
|
+
border-top: 1px solid var(--border);
|
|
145
|
+
}
|
|
146
|
+
|
|
147
|
+
.usage-pane {
|
|
148
|
+
display: flex;
|
|
149
|
+
min-width: 0;
|
|
150
|
+
min-height: 0;
|
|
151
|
+
flex-direction: column;
|
|
152
|
+
padding-top: 8px;
|
|
153
|
+
padding-right: 12px;
|
|
154
|
+
}
|
|
155
|
+
|
|
156
|
+
.usage-pane.is-right {
|
|
157
|
+
margin-left: 0;
|
|
158
|
+
padding-right: 0;
|
|
159
|
+
padding-left: 12px;
|
|
160
|
+
border-left: 1px solid var(--border);
|
|
161
|
+
}
|
|
162
|
+
|
|
163
|
+
.pane-body {
|
|
164
|
+
display: flex;
|
|
165
|
+
flex: 1;
|
|
166
|
+
min-height: 0;
|
|
167
|
+
flex-direction: column;
|
|
168
|
+
align-items: center;
|
|
169
|
+
justify-content: center;
|
|
170
|
+
gap: 7px;
|
|
171
|
+
padding-top: 2px;
|
|
172
|
+
}
|
|
173
|
+
|
|
174
|
+
.fact-tile {
|
|
175
|
+
display: flex;
|
|
176
|
+
min-width: 0;
|
|
177
|
+
flex-direction: column;
|
|
178
|
+
align-items: center;
|
|
179
|
+
gap: 1px;
|
|
180
|
+
padding: 6px 7px;
|
|
181
|
+
border: 1px solid var(--border);
|
|
182
|
+
border-radius: 10px;
|
|
183
|
+
background: color-mix(in srgb, var(--secondary) 48%, transparent);
|
|
184
|
+
text-align: center;
|
|
185
|
+
}
|
|
186
|
+
|
|
187
|
+
.fact-tile span {
|
|
188
|
+
color: var(--muted-foreground);
|
|
189
|
+
font-size: 11px;
|
|
190
|
+
white-space: nowrap;
|
|
191
|
+
}
|
|
192
|
+
|
|
193
|
+
.fact-tile b {
|
|
194
|
+
overflow: hidden;
|
|
195
|
+
max-width: 100%;
|
|
196
|
+
color: var(--foreground);
|
|
197
|
+
font-size: clamp(13px, 1.6vw, 16px);
|
|
198
|
+
font-weight: 550;
|
|
199
|
+
text-overflow: ellipsis;
|
|
200
|
+
white-space: nowrap;
|
|
201
|
+
}
|
|
202
|
+
|
|
203
|
+
@media (max-height: 760px) {
|
|
204
|
+
:global(.graphics-card) {
|
|
205
|
+
padding: 12px;
|
|
206
|
+
}
|
|
207
|
+
|
|
208
|
+
.pane-grid {
|
|
209
|
+
margin-top: 7px;
|
|
210
|
+
}
|
|
211
|
+
|
|
212
|
+
.usage-pane {
|
|
213
|
+
padding-top: 6px;
|
|
214
|
+
padding-right: 10px;
|
|
215
|
+
}
|
|
216
|
+
|
|
217
|
+
.usage-pane.is-right {
|
|
218
|
+
margin-left: 0;
|
|
219
|
+
padding-right: 0;
|
|
220
|
+
padding-left: 10px;
|
|
221
|
+
}
|
|
222
|
+
|
|
223
|
+
.pane-body {
|
|
224
|
+
gap: 5px;
|
|
225
|
+
}
|
|
226
|
+
|
|
227
|
+
.fact-tile {
|
|
228
|
+
padding: 5px 7px;
|
|
229
|
+
}
|
|
230
|
+
|
|
231
|
+
.fact-tile span {
|
|
232
|
+
font-size: 12px;
|
|
233
|
+
}
|
|
234
|
+
|
|
235
|
+
.fact-tile b {
|
|
236
|
+
font-size: 14px;
|
|
237
|
+
}
|
|
238
|
+
}
|
|
239
|
+
|
|
240
|
+
@media (orientation: portrait) {
|
|
241
|
+
:global(.graphics-card) {
|
|
242
|
+
min-height: 320px;
|
|
243
|
+
}
|
|
244
|
+
}
|
|
245
|
+
</style>
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
<script lang="ts">
|
|
2
|
+
import ClockCard from './ClockCard.svelte';
|
|
3
|
+
import NotificationsCard from './NotificationsCard.svelte';
|
|
4
|
+
</script>
|
|
5
|
+
|
|
6
|
+
<div class="home-grid">
|
|
7
|
+
<ClockCard />
|
|
8
|
+
<NotificationsCard />
|
|
9
|
+
</div>
|
|
10
|
+
|
|
11
|
+
<style>
|
|
12
|
+
.home-grid {
|
|
13
|
+
display: grid;
|
|
14
|
+
grid-template-columns: minmax(0, 1fr) clamp(360px, 42%, 440px);
|
|
15
|
+
gap: 12px;
|
|
16
|
+
height: 100%;
|
|
17
|
+
min-height: 0;
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
@media (max-height: 760px) {
|
|
21
|
+
.home-grid {
|
|
22
|
+
gap: 10px;
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
@media (orientation: portrait) {
|
|
27
|
+
.home-grid {
|
|
28
|
+
grid-template-columns: 1fr;
|
|
29
|
+
height: auto;
|
|
30
|
+
min-height: 100%;
|
|
31
|
+
gap: 12px;
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
</style>
|