hookehuyr

refactor(ShareButton): 将内联样式提取为CSS类并移除注释代码

style(ActivitiesCover): 移除位置获取失败的重试按钮和注释代码
...@@ -13,7 +13,7 @@ ...@@ -13,7 +13,7 @@
13 <view class="popover-arrow"></view> 13 <view class="popover-arrow"></view>
14 <view class="popover-content"> 14 <view class="popover-content">
15 <view class="popover-item" style="padding: 0; padding-top: 8rpx;"> 15 <view class="popover-item" style="padding: 0; padding-top: 8rpx;">
16 - <button id="share" data-name="shareBtn" open-type="share" style="font-size: 28rpx;padding: 0; background-color: white; line-height: 2;">活动</button> 16 + <button id="share" data-name="shareBtn" open-type="share" class="share-native-button">活动</button>
17 </view> 17 </view>
18 <view class="popover-divider"></view> 18 <view class="popover-divider"></view>
19 <view @tap="handleSharePoster" class="popover-item"> 19 <view @tap="handleSharePoster" class="popover-item">
...@@ -164,6 +164,31 @@ const handleSharePoster = () => { ...@@ -164,6 +164,31 @@ const handleSharePoster = () => {
164 z-index: 9998; 164 z-index: 9998;
165 } 165 }
166 166
167 +// 原生button样式重置
168 +.share-native-button {
169 + border: none !important;
170 + outline: none !important;
171 + background: transparent !important;
172 + padding: 0 !important;
173 + margin: 0 !important;
174 + font-size: 28rpx !important;
175 + line-height: 2 !important;
176 + color: #333 !important;
177 + width: 100% !important;
178 + height: auto !important;
179 + text-align: center !important;
180 +
181 + // 去除微信小程序button的默认样式
182 + &::after {
183 + border: none !important;
184 + }
185 +
186 + // 去除点击态样式
187 + &:active {
188 + background: transparent !important;
189 + }
190 +}
191 +
167 // 动画 192 // 动画
168 @keyframes popoverFadeIn { 193 @keyframes popoverFadeIn {
169 from { 194 from {
......
This diff is collapsed. Click to expand it.