From c72aa26fffd9970a5b39ef40c6347fdc6b6cf088 Mon Sep 17 00:00:00 2001 From: mysper Date: Wed, 31 Mar 2021 10:40:30 +0800 Subject: [PATCH] [optimize] sample rwd make button be wrap body display well in smaller width --- src/assets/scss/sponsor.scss | 112 +++++++++++++++++------------------ src/pages/Sponsor.vue | 58 +++++++++--------- 2 files changed, 86 insertions(+), 84 deletions(-) diff --git a/src/assets/scss/sponsor.scss b/src/assets/scss/sponsor.scss index 698f0b0..8a29abc 100644 --- a/src/assets/scss/sponsor.scss +++ b/src/assets/scss/sponsor.scss @@ -1,65 +1,65 @@ #sponsor { - line-height: 2em; + line-height: 2em; - h2 { - line-height: normal; - font-size: 36pt; - color: #4e4e4e; - } + h2 { + line-height: normal; + font-size: 36pt; + color: #4e4e4e; + } - .main-container { - width: 75%; - margin: 0 auto; - padding-top: 240px; - padding-bottom: 240px; - } + .main-container { + width: 75%; + margin: 0 auto; + padding-top: 240px; + padding-bottom: 240px; + } - .info-wrapper { - .content-wrapper { - display: flex; - flex-direction: row; - .info-left-button-wrapper { - padding-right: 160px; - } - .info-content { - p:not(:first-child) { - margin-top: 3em; - } - } - .info-right-button-wrapper { - padding-left: 160px; - } - } + .info-wrapper { + .content-wrapper { + display: flex; + flex-direction: row; + .info-left-button-wrapper { + padding-right: 10%; + } + .info-content { + p:not(:first-child) { + margin-top: 3em; + } + } + .info-right-button-wrapper { + padding-left: 10%; + } + } - .button-wrapper { - margin: 3em; - display: flex; - flex-direction: row; - justify-content: center; + .button-wrapper { + margin: 3em; + display: flex; + flex-direction: row; + justify-content: center; + flex-wrap: wrap; - .button { - color: white; - background: #1060ff; - margin-right: 30px; - margin-left: 30px; - padding: 0.33em 1em; - border-radius: 9487px; - box-shadow: 0px 0px 6px 0px rgba(0, 0, 0, 0.5); - } - } - } + .button { + color: white; + background: #1060ff; + margin: 15px 30px; + padding: 0.33em 1em; + border-radius: 9487px; + box-shadow: 0px 0px 6px 0px rgba(0, 0, 0, 0.5); + } + } + } - .deep-ploughing { - .image-wrapper { - margin-top: 8em; - display: flex; - flex-direction: row; - justify-content: space-between; + .deep-ploughing { + .image-wrapper { + margin-top: 8em; + display: flex; + flex-direction: row; + justify-content: space-between; - img { - width: 307px; - height: 251px; - } - } - } + img { + width: 307px; + height: 251px; + } + } + } } diff --git a/src/pages/Sponsor.vue b/src/pages/Sponsor.vue index b7d82c4..a25886d 100644 --- a/src/pages/Sponsor.vue +++ b/src/pages/Sponsor.vue @@ -1,27 +1,29 @@