Skip to content

fix: show concise bucket usage states and update Next.js - #316

Merged
cxymds merged 1 commit into
mainfrom
cxymds/fix/bucket-statistics-status
Nov 23, 2026
Merged

cxymds merged 1 commit into
mainfrom
cxymds/fix/bucket-statistics-status

Conversation

@cxymds

@cxymds cxymds commented Nov 23, 2026

Copy link
Copy Markdown
Member

Pull Request

Description

Buckets without measured usage now show a concise Awaiting statistics state instead of Unknown and placeholder metrics. Loading and unavailable states remain distinct; existing measurements, measured subtotals, visible bucket counts and real empty-namespace zeros stay visible. Bucket-list refresh propagates its loading state into the overview to avoid briefly reporting statistics as unavailable.

Upgrade Next.js and eslint-config-next from 16.4.1 to 16.4.6, with matching Next package lock entries. Official npm audit reports zero Next.js advisories after the upgrade, down from seven.

Type of Change

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Documentation update
  • Code refactoring
  • Performance improvement
  • Test improvements
  • Security fix

Testing

  • Unit tests added/updated
  • Manual testing completed

Passed with Node 22: frozen-lockfile install, type-check, lint, format:check, all 1,241 tests (zero skips), production static build, and git diff --check.

pnpm install --frozen-lockfile
pnpm type-check
pnpm lint
pnpm format:check
pnpm test:run
pnpm build

Controlled local component previews cover pending, loading, unavailable, empty and measured states, desktop/mobile layouts, English/Chinese, and light/dark themes. Browser logs contain no errors or warnings. These captures verify the UI with controlled props; they are not live scanner or VM acceptance.

Checklist

  • Code follows the project's style guidelines
  • Self-review completed
  • TypeScript types are properly defined
  • All commit messages are in English (Conventional Commits)
  • All existing tests pass
  • No new dependencies added, or they are justified

Independent correctness/simplification, test and UX reviews completed with no remaining findings.

Related Issues

None.

Screenshots (if applicable)

Same controlled pending state at 1280 × 900:

Before After
Unknown usage Concise pending status

Mobile and Chinese dark-mode captures:

Mobile, English Desktop, Chinese dark mode
Mobile pending state Chinese pending state in dark mode

Additional loading, failure, empty and measured captures and their viewport/theme metadata are under docs/ui-review/bucket-statistics-status/manifest.json.

Additional Notes

The full official npm audit continues to report 151 pre-existing findings in other dependencies (16 low, 80 moderate, 54 high, 1 critical). This PR resolves the seven Next.js findings; the remaining packages require separate remediation. No audit policy is relaxed.

Copilot AI balanced review requested due to automatic review settings November 23, 2026 11:14

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟢 Approval recommended

No active review issues were identified for the bucket usage reporting changes and dependency updates.

No open issues 🎉

1 file not reviewed
  • pnpm-lock.yaml: Generated file
What changed in this PR

This PR simplifies bucket usage reporting in the console, replacing unknown values and placeholders with concise status messages. It also updates Next.js and its ESLint configuration to 16.4.6.

Changes:

  • Distinguishes pending, loading, and unavailable statistics while preserving measured values, visible bucket counts, and empty-namespace zeros.
  • Adds localized status labels, regression tests, and metadata for controlled UI previews.
  • Updates Next.js dependencies and matching lockfile entries.
File Description
tests/​lib/​bucket-usage-overview.test.ts Covers pending, loading, unavailable, empty, and refresh states.
pnpm-lock.yaml Aligns Next.js package resolutions with 16.4.6.
package.json Updates Next.js and eslint-config-next to 16.4.6.
i18n/​locales/​zh-TW.json Adds Traditional Chinese statistics labels.
i18n/​locales/​zh-CN.json Adds Simplified Chinese statistics labels.
i18n/​locales/​vi-VN.json Adds Vietnamese statistics labels.
i18n/​locales/​tr-TR.json Adds Turkish statistics labels.
i18n/​locales/​ru-RU.json Adds Russian statistics labels.
i18n/​locales/​pt-BR.json Adds Brazilian Portuguese statistics labels.
i18n/​locales/​ko-KR.json Adds Korean statistics labels.
i18n/​locales/​ja-JP.json Adds Japanese statistics labels.
i18n/​locales/​it-IT.json Adds Italian statistics labels.
i18n/​locales/​id-ID.json Adds Indonesian statistics labels.
i18n/​locales/​fr-FR.json Adds French statistics labels.
i18n/​locales/​es-ES.json Adds Spanish statistics labels.
i18n/​locales/​en-US.json Adds English statistics labels, including “Awaiting statistics.”
i18n/​locales/​de-DE.json Adds German statistics labels.
i18n/​locales/​ar-MA.json Adds Arabic statistics labels.
docs/​ui-review/​bucket-statistics-status/​manifest.json Records controlled preview scenarios and screenshot metadata.
components/​buckets/​usage-overview.tsx Replaces placeholder metrics with concise statuses while retaining available values.
app/​(dashboard)/​browser/​page.tsx Propagates bucket-list loading into the usage overview.

Review effort: Balanced

@cxymds
cxymds merged commit 60d2121 into main Nov 23, 2026
11 checks passed
@cxymds
cxymds deleted the cxymds/fix/bucket-statistics-status branch November 23, 2026 12:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants