diff --git a/packages/vant-cli/site/common/style/vars.less b/packages/vant-cli/site/common/style/vars.less index d0601ebb0..ca81ab0c0 100644 --- a/packages/vant-cli/site/common/style/vars.less +++ b/packages/vant-cli/site/common/style/vars.less @@ -1,6 +1,6 @@ body { // colors - --van-doc-black: #1a1a1a; + --van-doc-black: #000; --van-doc-white: #fff; --van-doc-gray-1: #f7f8fa; --van-doc-gray-2: #f2f3f5; @@ -32,11 +32,11 @@ body { --van-doc-link-color: var(--van-doc-blue); // background - --van-doc-background: #f7f8fa; - --van-doc-background-light: var(--van-doc-white); + --van-doc-background: #eeeff2; + --van-doc-background-2: var(--van-doc-white); + --van-doc-background-3: var(--van-doc-white); --van-doc-header-background: #011f3c; --van-doc-border-color: var(--van-doc-gray-2); - --van-doc-shadow-color: var(--van-doc-gray-3); // code --van-doc-code-color: #58727e; @@ -58,10 +58,10 @@ body { // background --van-doc-background: #202124; - --van-doc-background-light: rgba(255, 255, 255, 0.06); + --van-doc-background-2: rgba(255, 255, 255, 0.06); + --van-doc-background-3: rgba(255, 255, 255, 0.1); --van-doc-header-background: rgba(1, 31, 60, 0.3); --van-doc-border-color: #3a3a3c; - --van-doc-shadow-color: transparent; // code --van-doc-code-color: rgba(200, 200, 200, 0.85); diff --git a/packages/vant-cli/site/desktop/components/Content.vue b/packages/vant-cli/site/desktop/components/Content.vue index 9ee3b0352..c09032a12 100644 --- a/packages/vant-cli/site/desktop/components/Content.vue +++ b/packages/vant-cli/site/desktop/components/Content.vue @@ -44,9 +44,8 @@ export default { .van-doc-card { margin-bottom: 24px; padding: 24px; - background-color: var(--van-doc-background-light); + background-color: var(--van-doc-background-2); border-radius: var(--van-doc-border-radius); - box-shadow: 0 8px 12px var(--van-doc-shadow-color); > p a, > ul a, diff --git a/packages/vant-cli/site/desktop/components/Nav.vue b/packages/vant-cli/site/desktop/components/Nav.vue index addaa8d2e..596736f09 100644 --- a/packages/vant-cli/site/desktop/components/Nav.vue +++ b/packages/vant-cli/site/desktop/components/Nav.vue @@ -79,8 +79,7 @@ export default { max-width: var(--van-doc-nav-width); padding: 8px 0; overflow-y: scroll; - background-color: var(--van-doc-background-light); - box-shadow: 0 8px 12px var(--van-doc-shadow-color); + background-color: var(--van-doc-background-2); @media (min-width: var(--van-doc-row-max-width)) { left: 50%; diff --git a/packages/vant-cli/site/desktop/components/Simulator.vue b/packages/vant-cli/site/desktop/components/Simulator.vue index 2bf132239..163e649e7 100644 --- a/packages/vant-cli/site/desktop/components/Simulator.vue +++ b/packages/vant-cli/site/desktop/components/Simulator.vue @@ -53,9 +53,8 @@ export default { width: var(--van-doc-simulator-width); min-width: var(--van-doc-simulator-width); overflow: hidden; - background: var(--van-doc-background-light); + background: var(--van-doc-background-2); border-radius: var(--van-doc-border-radius); - box-shadow: 0 8px 12px var(--van-doc-shadow-color); @media (max-width: 1100px) { right: auto; diff --git a/packages/vant-cli/site/mobile/App.vue b/packages/vant-cli/site/mobile/App.vue index 84fa98292..84c524680 100644 --- a/packages/vant-cli/site/mobile/App.vue +++ b/packages/vant-cli/site/mobile/App.vue @@ -45,8 +45,12 @@ body { min-width: 100vw; } +.van-doc-theme-light { + background-color: var(--van-doc-gray-1); +} + .van-doc-theme-dark { - background-color: #000; + background-color: var(--van-doc-black); } ::-webkit-scrollbar { diff --git a/packages/vant-cli/site/mobile/components/DemoHomeNav.vue b/packages/vant-cli/site/mobile/components/DemoHomeNav.vue index 5a5e80406..5d26a469d 100644 --- a/packages/vant-cli/site/mobile/components/DemoHomeNav.vue +++ b/packages/vant-cli/site/mobile/components/DemoHomeNav.vue @@ -59,7 +59,7 @@ export default { font-weight: 600; font-size: 14px; line-height: 40px; - background-color: var(--van-doc-background-light); + background-color: var(--van-doc-background-3); border-radius: 99px; transition: opacity 0.3s; diff --git a/packages/vant-cli/site/mobile/components/DemoNav.vue b/packages/vant-cli/site/mobile/components/DemoNav.vue index aebc2dd29..54a88d7d8 100644 --- a/packages/vant-cli/site/mobile/components/DemoNav.vue +++ b/packages/vant-cli/site/mobile/components/DemoNav.vue @@ -42,7 +42,7 @@ export default { align-items: center; justify-content: center; height: 56px; - background-color: var(--van-doc-background-light); + background-color: var(--van-doc-background-2); &__title { font-weight: 600; diff --git a/packages/vant/src/button/demo/index.vue b/packages/vant/src/button/demo/index.vue index 4613486d7..44d707da0 100644 --- a/packages/vant/src/button/demo/index.vue +++ b/packages/vant/src/button/demo/index.vue @@ -144,8 +144,6 @@ const t = useTranslate({