From 2d53ddc94318afacaa2a4e1c7bccf702d4f0b268 Mon Sep 17 00:00:00 2001 From: qiuxiang <394405259@qq.com> Date: Fri, 20 Nov 2026 09:37:30 +0800 Subject: [PATCH] =?UTF-8?q?feat(=E8=B4=A6=E6=88=B7=E4=BD=99=E9=A2=9D):=20?= =?UTF-8?q?=E6=89=A9=E5=B1=95=E6=80=BB=E8=A7=88=E9=A1=B5=E9=9D=A2=E5=AE=BD?= =?UTF-8?q?=E5=B1=8F=E5=B8=83=E5=B1=80=20(#1291)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../business/StoreReceivingBalanceOverview.vue | 16 ++++++++-------- .../View/StoreReceivingBalanceOverviewTest.php | 10 ++++++++++ 2 files changed, 18 insertions(+), 8 deletions(-) diff --git a/resources/assets/js/components/business/StoreReceivingBalanceOverview.vue b/resources/assets/js/components/business/StoreReceivingBalanceOverview.vue index a0c6e4d3..91e4e64b 100644 --- a/resources/assets/js/components/business/StoreReceivingBalanceOverview.vue +++ b/resources/assets/js/components/business/StoreReceivingBalanceOverview.vue @@ -671,12 +671,12 @@ export default { return this.fullTrendRows; }, chart() { - const width = 1000; - const height = 330; + const width = 1400; + const height = 360; const plotLeft = 72; - const plotRight = 978; + const plotRight = 1378; const plotTop = 26; - const plotBottom = 262; + const plotBottom = 292; const rows = this.visibleRows; if (!rows.length) { @@ -1093,9 +1093,9 @@ export default { --trend-blue-soft: #eff6ff; --trend-green: #16a34a; --trend-red: #dc2626; - width: min(100%, 1080px); + width: min(100%, 1920px); margin: 0 auto; - padding: 1.25rem 1rem 2rem; + padding: 1.25rem 1.15rem 2rem; color: var(--trend-ink); font-family: "JetBrains Mono", "Microsoft YaHei", "PingFang SC", monospace; } @@ -1290,13 +1290,13 @@ export default { .trend-cards { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); - gap: .75rem; + gap: .9rem; margin-top: 1rem; } .trend-card { min-width: 0; min-height: 7.3rem; - padding: .9rem 1rem .85rem; + padding: 1rem 1.15rem .9rem; border: 1px solid var(--trend-line); border-radius: .6875rem; background: var(--trend-surface); diff --git a/tests/Unit/View/StoreReceivingBalanceOverviewTest.php b/tests/Unit/View/StoreReceivingBalanceOverviewTest.php index e26d6c01..2e9fee9d 100644 --- a/tests/Unit/View/StoreReceivingBalanceOverviewTest.php +++ b/tests/Unit/View/StoreReceivingBalanceOverviewTest.php @@ -98,6 +98,16 @@ class StoreReceivingBalanceOverviewTest extends TestCase $this->assertStringContainsString('{{ dailyNote }}', $source); } + public function test_overview_uses_the_available_content_width_for_the_wide_dashboard(): void + { + $source = $this->overviewSource(); + + $this->assertStringContainsString('width: min(100%, 1920px);', $source); + $this->assertStringContainsString('const width = 1400;', $source); + $this->assertStringContainsString('const height = 360;', $source); + $this->assertStringContainsString('padding: 1.25rem 1.15rem 2rem;', $source); + } + public function test_overview_tab_is_placed_before_taobao_alipay_navigation(): void { $navigation = file_get_contents(__DIR__ . '/../../../config/business_navigation.php');