Преглед на файлове

Fix: 首页 banner 课程名改为课程标签(胶囊样式),不再是副标题

liaoxg преди 2 седмици
родител
ревизия
e6ebd07e33
променени са 1 файла, в които са добавени 18 реда и са изтрити 3 реда
  1. 18 3
      train-frontend/pages/index/index.vue

+ 18 - 3
train-frontend/pages/index/index.vue

@@ -3,7 +3,9 @@
     <view class="banner">
     <view class="banner">
       <text class="banner-icon">🚀</text>
       <text class="banner-icon">🚀</text>
       <text class="banner-title">爱伴·AI之旅</text>
       <text class="banner-title">爱伴·AI之旅</text>
-      <text class="banner-sub">{{ courseLabel }}</text>
+      <view class="course-tag">
+        <text class="course-tag-text">{{ courseLabel }}</text>
+      </view>
       <button v-if="!isLoggedIn" class="login-entry-btn" @click="showLoginSheet">点击登录</button>
       <button v-if="!isLoggedIn" class="login-entry-btn" @click="showLoginSheet">点击登录</button>
     </view>
     </view>
 
 
@@ -220,8 +222,21 @@ export default {
 .home-page { min-height: 100vh; background: #F5F5F5; padding: 0 32rpx 32rpx; }
 .home-page { min-height: 100vh; background: #F5F5F5; padding: 0 32rpx 32rpx; }
 .banner { background: linear-gradient(135deg, #F97316, #EA580C); border-radius: 0 0 32rpx 32rpx; padding: 60rpx 32rpx 48rpx; text-align: center; margin: 0 -32rpx 24rpx; position: relative; }
 .banner { background: linear-gradient(135deg, #F97316, #EA580C); border-radius: 0 0 32rpx 32rpx; padding: 60rpx 32rpx 48rpx; text-align: center; margin: 0 -32rpx 24rpx; position: relative; }
 .banner-icon { font-size: 72rpx; display: block; margin-bottom: 16rpx; }
 .banner-icon { font-size: 72rpx; display: block; margin-bottom: 16rpx; }
-.banner-title { display: block; font-size: 40rpx; font-weight: 700; color: #FFF; margin-bottom: 8rpx; }
-.banner-sub { display: block; font-size: 26rpx; color: rgba(255,255,255,0.85); margin-bottom: 24rpx; }
+.banner-title { display: block; font-size: 40rpx; font-weight: 700; color: #FFF; margin-bottom: 16rpx; }
+.course-tag {
+  display: inline-block;
+  background: rgba(255,255,255,0.18);
+  border: 2rpx solid rgba(255,255,255,0.4);
+  border-radius: 100rpx;
+  padding: 8rpx 24rpx;
+  margin-bottom: 28rpx;
+}
+.course-tag-text {
+  font-size: 28rpx;
+  font-weight: 600;
+  color: #FFF;
+  line-height: 1.4;
+}
 .login-entry-btn { 
 .login-entry-btn { 
   background: #FFF; 
   background: #FFF; 
   color: #EA580C; 
   color: #EA580C;