1
0

2 Incheckningar 96d12ba62e ... a51ca5a2cf

Upphovsman SHA1 Meddelande Datum
  0225263 a51ca5a2cf Merge branch 'master' of http://git.fmode.cn:3000/0225273/APPmy 4 månader sedan
  0225263 81925f361a tab4 4 månader sedan
3 ändrade filer med 11 tillägg och 4 borttagningar
  1. 2 2
      src/app/tab4/tab4.page.html
  2. 3 0
      src/app/tab4/tab4.page.scss
  3. 6 2
      src/app/tab4/tab4.page.ts

+ 2 - 2
src/app/tab4/tab4.page.html

@@ -69,14 +69,14 @@
     </ion-card-content>
   </ion-card>
   
-  <ion-card>
+  
     <ion-card-content style="justify-content: space-around">
       <p (click)="showContent('发布')">发布</p>
       <p (click)="showContent('收藏')">收藏</p>
       <p (click)="showContent('点赞')">点赞</p>
       <p (click)="showContent('浏览')">浏览</p>
     </ion-card-content>
-  </ion-card>
+  
 
   <div class="content-area">
     {{ selectedContent }}

+ 3 - 0
src/app/tab4/tab4.page.scss

@@ -34,4 +34,7 @@ ion-segment {
 
 p {
   font-size: 20px; /* 设置文字大小为20px */
+}
+p:active {
+  color: blue; /* 点击后文本颜色变为蓝色 */
 }

+ 6 - 2
src/app/tab4/tab4.page.ts

@@ -8,11 +8,15 @@ import { NavController } from '@ionic/angular';
 })
 export class Tab4Page implements OnInit {
 
-  constructor(private navCtrl: NavController) {}
+  constructor(private navCtrl: NavController) {this.selectedContent = '发布';}
   selectedContent: string = '';
 
   showContent(content: string) {
-    this.selectedContent = content;
+    if (content === '收藏') {
+      this.selectedContent = '一个作品都没有';
+    } else {
+      this.selectedContent = content;
+    }
   }
 
   openFeedbackPage() {