From 7c0a5af4bf0742e4929f8f3ca324e522f0772a42 Mon Sep 17 00:00:00 2001 From: AlliotTech <24980252+AlliotTech@users.noreply.github.com> Date: Fri, 6 Feb 2026 14:29:51 +0800 Subject: [PATCH 1/2] feat: colorize mobile device last-updated age --- components/dashboard/device-list-mobile.tsx | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/components/dashboard/device-list-mobile.tsx b/components/dashboard/device-list-mobile.tsx index 0f98e89..958045e 100644 --- a/components/dashboard/device-list-mobile.tsx +++ b/components/dashboard/device-list-mobile.tsx @@ -25,7 +25,8 @@ import { import { useI18n } from "@/lib/i18n"; import { performDeviceAction } from "@/lib/device-actions"; import { AppConfig, DeviceSummaryModel, MetricsStatusThreshold } from "@/lib/types"; -import { formatDateTime, formatTemperature } from "@/lib/format"; +import { formatDateTime, formatTemperature, summaryAgeClass } from "@/lib/format"; +import { cn } from "@/lib/utils"; import { deviceHref, getDeviceCardData, @@ -125,9 +126,9 @@ export function DeviceListMobile({ summary, settings, showArchived, onAction }:
{t("dashboard.devices.last_updated")}
-- {formatDateTime(deviceSummary.smart?.collector_date)} -
++ {formatDateTime(deviceSummary.smart?.collector_date)} +
{t("dashboard.devices.temp")}
From 560784e92b7487724a13b12e3b3ee2ef5625e3c5 Mon Sep 17 00:00:00 2001 From: AlliotTech <24980252+AlliotTech@users.noreply.github.com> Date: Fri, 6 Feb 2026 14:33:22 +0800 Subject: [PATCH 2/2] chore(ci): workflow optimize --- .github/workflows/ci-pages.yml | 36 ++++++++++++++++++++++++++-------- 1 file changed, 28 insertions(+), 8 deletions(-) diff --git a/.github/workflows/ci-pages.yml b/.github/workflows/ci-pages.yml index 3867782..a10e9f9 100644 --- a/.github/workflows/ci-pages.yml +++ b/.github/workflows/ci-pages.yml @@ -6,6 +6,9 @@ on: - master tags: - "v*" + pull_request: + branches: + - master workflow_dispatch: permissions: @@ -18,8 +21,8 @@ concurrency: cancel-in-progress: true jobs: - build_pages: - if: github.ref == 'refs/heads/master' + ci: + if: github.event_name == 'pull_request' || github.ref == 'refs/heads/master' || startsWith(github.ref, 'refs/tags/') runs-on: ubuntu-latest steps: - name: Checkout @@ -45,6 +48,28 @@ jobs: - name: Test run: pnpm test -- --run + build_pages: + if: github.ref == 'refs/heads/master' + needs: ci + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@v4 + + - name: Setup pnpm + uses: pnpm/action-setup@v4 + with: + version: 9 + + - name: Setup Node + uses: actions/setup-node@v4 + with: + node-version: 20 + cache: pnpm + + - name: Install + run: pnpm install --frozen-lockfile + - name: Set base path run: | if [[ "${{ github.event.repository.name }}" == *.github.io ]]; then @@ -80,6 +105,7 @@ jobs: build_release: if: startsWith(github.ref, 'refs/tags/') + needs: ci runs-on: ubuntu-latest steps: - name: Checkout @@ -99,12 +125,6 @@ jobs: - name: Install run: pnpm install --frozen-lockfile - - name: Lint - run: pnpm lint - - - name: Test - run: pnpm test -- --run - - name: Set release env run: | echo "NEXT_PUBLIC_BASE_PATH=/web" >> $GITHUB_ENV