19136808282 3 сар өмнө
parent
commit
95fe137df7
63 өөрчлөгдсөн 2557 нэмэгдсэн , 74 устгасан
  1. 35 0
      .history/soul-app/src/app/consult-picture/consult-picture.component_20241210113940.html
  2. 67 0
      .history/soul-app/src/app/consult-picture/consult-picture.component_20241210113940.ts
  3. 67 0
      .history/soul-app/src/app/consult-picture/consult-picture.component_20241216083858.ts
  4. 68 0
      .history/soul-app/src/app/consult-picture/consult-picture.component_20241216083900.html
  5. 67 0
      .history/soul-app/src/app/consult-picture/consult-picture.component_20241216085303.ts
  6. 35 0
      .history/soul-app/src/app/consult-picture/consult-picture.component_20241216085448.html
  7. 19 0
      .history/soul-app/src/app/page-consult/page-consult.component_20241210113940.html
  8. 51 0
      .history/soul-app/src/app/page-consult/page-consult.component_20241210113940.scss
  9. 57 0
      .history/soul-app/src/app/page-consult/page-consult.component_20241210113940.ts
  10. 63 0
      .history/soul-app/src/app/page-consult/page-consult.component_20241216084014.ts
  11. 58 0
      .history/soul-app/src/app/page-consult/page-consult.component_20241216084016.scss
  12. 58 0
      .history/soul-app/src/app/page-consult/page-consult.component_20241216084021.scss
  13. 34 0
      .history/soul-app/src/app/page-consult/page-consult.component_20241216084024.html
  14. 17 0
      .history/soul-app/src/app/tab3/tab3.page_20241210113940.html
  15. 0 0
      .history/soul-app/src/app/tab3/tab3.page_20241210113940.scss
  16. 14 0
      .history/soul-app/src/app/tab3/tab3.page_20241210113940.ts
  17. 65 0
      .history/soul-app/src/app/tab3/tab3.page_20241216094604.html
  18. 53 0
      .history/soul-app/src/app/tab3/tab3.page_20241216094616.scss
  19. 62 0
      .history/soul-app/src/app/tab3/tab3.page_20241216094631.ts
  20. 18 0
      .history/soul-app/src/app/tabs/tabs.page_20241210113940.html
  21. 1 0
      .history/soul-app/src/app/tabs/tabs.page_20241210113940.scss
  22. 19 0
      .history/soul-app/src/app/tabs/tabs.page_20241210113940.ts
  23. 21 0
      .history/soul-app/src/app/tabs/tabs.page_20241216084220.ts
  24. 7 0
      .history/soul-app/src/app/tabs/tabs.page_20241216084242.scss
  25. 18 0
      .history/soul-app/src/app/tabs/tabs.page_20241216092203.html
  26. 61 0
      .history/soul-app/src/app/tabs/tabs.routes_20241210113940.ts
  27. 61 0
      .history/soul-app/src/app/tabs/tabs.routes_20241216084229.ts
  28. 72 0
      .history/soul-app/src/app/topic-detail/topic-detail.component_20241210113940.html
  29. 28 0
      .history/soul-app/src/app/topic-detail/topic-detail.component_20241210113940.scss
  30. 84 0
      .history/soul-app/src/app/topic-detail/topic-detail.component_20241210113940.ts
  31. 81 0
      .history/soul-app/src/app/topic-detail/topic-detail.component_20241216084316.html
  32. 38 0
      .history/soul-app/src/app/topic-detail/topic-detail.component_20241216084335.scss
  33. 89 0
      .history/soul-app/src/app/topic-detail/topic-detail.component_20241216084741.ts
  34. 72 0
      .history/soul-app/src/app/topic-detail2/topic-detail2.component_20241210113940.html
  35. 28 0
      .history/soul-app/src/app/topic-detail2/topic-detail2.component_20241210113940.scss
  36. 77 0
      .history/soul-app/src/app/topic-detail2/topic-detail2.component_20241210113940.ts
  37. 81 0
      .history/soul-app/src/app/topic-detail2/topic-detail2.component_20241216084802.html
  38. 35 0
      .history/soul-app/src/app/topic-detail2/topic-detail2.component_20241216084811.scss
  39. 80 0
      .history/soul-app/src/app/topic-detail2/topic-detail2.component_20241216084823.ts
  40. 72 0
      .history/soul-app/src/app/topic-detail3/topic-detail3.component_20241210113940.html
  41. 28 0
      .history/soul-app/src/app/topic-detail3/topic-detail3.component_20241210113940.scss
  42. 79 0
      .history/soul-app/src/app/topic-detail3/topic-detail3.component_20241210113940.ts
  43. 81 0
      .history/soul-app/src/app/topic-detail3/topic-detail3.component_20241216084835.html
  44. 34 0
      .history/soul-app/src/app/topic-detail3/topic-detail3.component_20241216084841.scss
  45. 82 0
      .history/soul-app/src/app/topic-detail3/topic-detail3.component_20241216084847.ts
  46. 15 0
      soul-app/src/app/page-consult/page-consult.component.html
  47. 8 1
      soul-app/src/app/page-consult/page-consult.component.scss
  48. 9 3
      soul-app/src/app/page-consult/page-consult.component.ts
  49. 55 7
      soul-app/src/app/tab3/tab3.page.html
  50. 53 0
      soul-app/src/app/tab3/tab3.page.scss
  51. 53 5
      soul-app/src/app/tab3/tab3.page.ts
  52. 1 1
      soul-app/src/app/tabs/tabs.page.html
  53. 7 1
      soul-app/src/app/tabs/tabs.page.scss
  54. 6 4
      soul-app/src/app/tabs/tabs.page.ts
  55. 10 1
      soul-app/src/app/topic-detail/topic-detail.component.html
  56. 26 16
      soul-app/src/app/topic-detail/topic-detail.component.scss
  57. 7 2
      soul-app/src/app/topic-detail/topic-detail.component.ts
  58. 10 1
      soul-app/src/app/topic-detail2/topic-detail2.component.html
  59. 20 13
      soul-app/src/app/topic-detail2/topic-detail2.component.scss
  60. 5 2
      soul-app/src/app/topic-detail2/topic-detail2.component.ts
  61. 10 1
      soul-app/src/app/topic-detail3/topic-detail3.component.html
  62. 20 14
      soul-app/src/app/topic-detail3/topic-detail3.component.scss
  63. 5 2
      soul-app/src/app/topic-detail3/topic-detail3.component.ts

+ 35 - 0
.history/soul-app/src/app/consult-picture/consult-picture.component_20241210113940.html

@@ -0,0 +1,35 @@
+<ion-header [translucent]="true">
+  <ion-toolbar>
+    <ion-title>
+      示例:logo生成{{imagineWork?.progress || 0}}
+    </ion-title> 
+  </ion-toolbar>
+</ion-header>
+
+<ion-content [fullscreen]="true">
+  <!-- 生成提示词 -->
+  <ion-textarea [value]="userPrompt" (ionInput)="promptInput($event)" placeholder="图片提示词" autoGrow="true"></ion-textarea>
+  <ion-button (click)="createImage()" expand="block">生成logo</ion-button>
+  <!--logo画面提示词-->
+
+  <div>
+    {{PictureDescResult}}
+  </div>
+
+  <!-- 生成结果 -->
+  @if(images.length) {
+    @for(imageUrl of images;track imageUrl){
+      <img [src]="imageUrl" alt="" srcset="">
+    }
+  }
+  <!-- 生成状态 -->
+  @if(!images.length){
+    @if(imagineWork){
+      <h1>生成中</h1>
+    }
+    @if(!imagineWork){
+      <h1>未开始</h1>
+    }
+  }
+
+</ion-content>

+ 67 - 0
.history/soul-app/src/app/consult-picture/consult-picture.component_20241210113940.ts

@@ -0,0 +1,67 @@
+import { Component, OnInit } from '@angular/core';
+import { IonHeader, IonToolbar, IonTitle, IonContent } from '@ionic/angular/standalone';
+import { IonTextarea, IonButton,IonInput } from "@ionic/angular/standalone";
+import { DalleOptions, ImagineWork,FmodeChatCompletion } from 'fmode-ng';
+
+@Component({
+  selector: 'app-consult-picture',
+  templateUrl: './consult-picture.component.html',
+  styleUrls: ['./consult-picture.component.scss'],
+  standalone: true,
+  imports: [
+    IonHeader, IonToolbar, IonTitle, IonContent, 
+    IonButton,IonInput,
+    IonTextarea
+  ],
+})
+export class ConsultPictureComponent  implements OnInit {
+
+  userPrompt:string = "app名称为...的logo,一个爱心,聊天气泡,易于识别,颜色方案应体现温暖感和清晰感,建议使用...色和...色等色调,极具美观性,可爱风格"
+  promptInput(ev:any){
+    this.userPrompt = ev.detail.value;
+  }
+  imagineWork:ImagineWork|undefined
+  images:Array<string> = []
+  constructor(
+  ){
+    // 示例任务,自己生成图片后请存储新的ID
+    this.imagineWork = new ImagineWork("lpJGiFwWeA");
+    this.imagineWork.fetchTask().then(work=>{
+      this.images = this.imagineWork?.images || [];
+    })
+  }
+  PictureDescResult:string = `` // 画面描述结果
+  async createImage(){
+    this.imagineWork = new ImagineWork();
+    //文本生成
+    let PromptTemplate = `请你作为一名专业的设计师,结合logo的基础设计元素帮我设计一个贴切我项目的logo
+    要求如下:
+    ${this.userPrompt}
+    `
+    let completion = new FmodeChatCompletion([
+      {role:"system",content:""},
+      {role:"user",content:PromptTemplate}
+    ])
+    completion.sendCompletion().subscribe((message:any)=>{
+      // 打印消息体
+      console.log(message.content)
+      // 赋值消息内容给组件内属性
+      this.PictureDescResult = message.content
+      if(message?.complete){ // 判断message为完成状态,则设置isComplete为完成
+      //图片生成
+      let PicturePrompt = `${this.PictureDescResult}`
+      //\n风格:科技风。画面不带任何文字。突出色彩。
+      let options:DalleOptions = {prompt:PicturePrompt}
+      this.imagineWork?.draw(options).subscribe(work=>{
+        console.log("imagineWork",work?.toJSON())
+        console.log("images",work?.get("images"))
+        if(work?.get("images")?.length){
+          this.images = work?.get("images");
+        }
+      })
+    }
+  })
+}
+    ngOnInit() {
+    }
+}

+ 67 - 0
.history/soul-app/src/app/consult-picture/consult-picture.component_20241216083858.ts

@@ -0,0 +1,67 @@
+import { Component, OnInit } from '@angular/core';
+import { IonHeader, IonToolbar, IonTitle, IonContent } from '@ionic/angular/standalone';
+import { IonTextarea, IonButton,IonInput } from "@ionic/angular/standalone";
+import { DalleOptions, ImagineWork,FmodeChatCompletion } from 'fmode-ng';
+
+@Component({
+  selector: 'app-consult-picture',
+  templateUrl: './consult-picture.component.html',
+  styleUrls: ['./consult-picture.component.scss'],
+  standalone: true,
+  imports: [
+    IonHeader, IonToolbar, IonTitle, IonContent, 
+    IonButton,IonInput,
+    IonTextarea
+  ],
+})
+export class ConsultPictureComponent  implements OnInit {
+
+  userPrompt:string = "app名称为...的logo,一个爱心,聊天气泡,易于识别,颜色方案应体现温暖感和清晰感,建议使用...色和...色等色调,极具美观性,可爱风格"
+  promptInput(ev:any){
+    this.userPrompt = ev.detail.value;
+  }
+  imagineWork:ImagineWork|undefined
+  images:Array<string> = []
+  constructor(
+  ){
+    // 示例任务,自己生成图片后请存储新的ID
+    this.imagineWork = new ImagineWork("lpJGiFwWeA");
+    this.imagineWork.fetchTask().then(work=>{
+      this.images = this.imagineWork?.images || [];
+    })
+  }
+  PictureDescResult:string = `` // 画面描述结果
+  async createImage(){
+    this.imagineWork = new ImagineWork();
+    //文本生成
+    let PromptTemplate = `请你作为一名专业的设计师,结合logo的基础设计元素帮我设计一个贴切我项目的logo
+    要求如下:
+    ${this.userPrompt}
+    `
+    let completion = new FmodeChatCompletion([
+      {role:"system",content:""},
+      {role:"user",content:PromptTemplate}
+    ])
+    completion.sendCompletion().subscribe((message:any)=>{
+      // 打印消息体
+      console.log(message.content)
+      // 赋值消息内容给组件内属性
+      this.PictureDescResult = message.content
+      if(message?.complete){ // 判断message为完成状态,则设置isComplete为完成
+      //图片生成
+      let PicturePrompt = `${this.PictureDescResult}`
+      //\n风格:科技风。画面不带任何文字。突出色彩。
+      let options:DalleOptions = {prompt:PicturePrompt}
+      this.imagineWork?.draw(options).subscribe(work=>{
+        console.log("imagineWork",work?.toJSON())
+        console.log("images",work?.get("images"))
+        if(work?.get("images")?.length){
+          this.images = work?.get("images");
+        }
+      })
+    }
+  })
+}
+    ngOnInit() {
+    }
+}

+ 68 - 0
.history/soul-app/src/app/consult-picture/consult-picture.component_20241216083900.html

@@ -0,0 +1,68 @@
+<ion-header [translucent]="true">
+  <ion-toolbar>
+    <ion-title>
+      示例:logo生成{{imagineWork?.progress || 0}}
+    </ion-title> 
+  </ion-toolbar>
+</ion-header><ion-header>
+  <ion-toolbar>
+    <div class="toolbar-content">
+      <div class="button-container">
+        <ion-button (click)="goTab1()" fill="clear">
+          <ion-icon name="chevron-back" slot="start"></ion-icon>返回
+        </ion-button>
+      </div>
+      <ion-title class="title-text">
+        心理咨询
+      </ion-title>
+    </div>
+  </ion-toolbar>
+</ion-header>
+
+<ion-content>
+    <h1>类型</h1>
+    <ion-input [value]="leixing" (ionInput)="leixingInput($event)"></ion-input>
+<!-- 文本域:生成提示词 -->
+ <h1>心理状况的描述</h1>
+<ion-textarea [value]="userPrompt" (ionInput)="promptInput($event)" placeholder="文本提示词" autoGrow="true"></ion-textarea>
+
+<!-- 按钮:执行消息生成函数 -->
+<ion-button (click)="sendMessage()" expand="block">初步判断</ion-button>
+
+@if(!isComplete){
+    <div>{{responseMsg}}</div>
+  }
+  <!-- 消息传输完成后,实时预览Markdown格式 -->
+@if(isComplete){
+    <fm-markdown-preview class="content-style" [content]="responseMsg"></fm-markdown-preview>
+  }
+
+</ion-content>
+
+<ion-content [fullscreen]="true">
+  <!-- 生成提示词 -->
+  <ion-textarea [value]="userPrompt" (ionInput)="promptInput($event)" placeholder="图片提示词" autoGrow="true"></ion-textarea>
+  <ion-button (click)="createImage()" expand="block">生成logo</ion-button>
+  <!--logo画面提示词-->
+
+  <div>
+    {{PictureDescResult}}
+  </div>
+
+  <!-- 生成结果 -->
+  @if(images.length) {
+    @for(imageUrl of images;track imageUrl){
+      <img [src]="imageUrl" alt="" srcset="">
+    }
+  }
+  <!-- 生成状态 -->
+  @if(!images.length){
+    @if(imagineWork){
+      <h1>生成中</h1>
+    }
+    @if(!imagineWork){
+      <h1>未开始</h1>
+    }
+  }
+
+</ion-content>

+ 67 - 0
.history/soul-app/src/app/consult-picture/consult-picture.component_20241216085303.ts

@@ -0,0 +1,67 @@
+import { Component, OnInit } from '@angular/core';
+import { IonHeader, IonToolbar, IonTitle, IonContent } from '@ionic/angular/standalone';
+import { IonTextarea, IonButton,IonInput } from "@ionic/angular/standalone";
+import { DalleOptions, ImagineWork,FmodeChatCompletion } from 'fmode-ng';
+
+@Component({
+  selector: 'app-consult-picture',
+  templateUrl: './consult-picture.component.html',
+  styleUrls: ['./consult-picture.component.scss'],
+  standalone: true,
+  imports: [
+    IonHeader, IonToolbar, IonTitle, IonContent, 
+    IonButton,IonInput,
+    IonTextarea
+  ],
+})
+export class ConsultPictureComponent  implements OnInit {
+
+  userPrompt:string = "app名称为...的logo,一个爱心,聊天气泡,易于识别,颜色方案应体现温暖感和清晰感,建议使用...色和...色等色调,极具美观性,可爱风格"
+  promptInput(ev:any){
+    this.userPrompt = ev.detail.value;
+  }
+  imagineWork:ImagineWork|undefined
+  images:Array<string> = []
+  constructor(
+  ){
+    // 示例任务,自己生成图片后请存储新的ID
+    this.imagineWork = new ImagineWork("lpJGiFwWeA");
+    this.imagineWork.fetchTask().then(work=>{
+      this.images = this.imagineWork?.images || [];
+    })
+  }
+  PictureDescResult:string = `` // 画面描述结果
+  async createImage(){
+    this.imagineWork = new ImagineWork();
+    //文本生成
+    let PromptTemplate = `请你作为一名专业的设计师,结合logo的基础设计元素帮我设计一个贴切我项目的logo
+    要求如下:
+    ${this.userPrompt}
+    `
+    let completion = new FmodeChatCompletion([
+      {role:"system",content:""},
+      {role:"user",content:PromptTemplate}
+    ])
+    completion.sendCompletion().subscribe((message:any)=>{
+      // 打印消息体
+      console.log(message.content)
+      // 赋值消息内容给组件内属性
+      this.PictureDescResult = message.content
+      if(message?.complete){ // 判断message为完成状态,则设置isComplete为完成
+      //图片生成
+      let PicturePrompt = `${this.PictureDescResult}`
+      //\n风格:科技风。画面不带任何文字。突出色彩。
+      let options:DalleOptions = {prompt:PicturePrompt}
+      this.imagineWork?.draw(options).subscribe(work=>{
+        console.log("imagineWork",work?.toJSON())
+        console.log("images",work?.get("images"))
+        if(work?.get("images")?.length){
+          this.images = work?.get("images");
+        }
+      })
+    }
+  })
+}
+    ngOnInit() {
+    }
+}

+ 35 - 0
.history/soul-app/src/app/consult-picture/consult-picture.component_20241216085448.html

@@ -0,0 +1,35 @@
+<ion-header [translucent]="true">
+  <ion-toolbar>
+    <ion-title>
+      示例:logo生成{{imagineWork?.progress || 0}}
+    </ion-title> 
+  </ion-toolbar>
+</ion-header>
+
+<ion-content [fullscreen]="true">
+  <!-- 生成提示词 -->
+  <ion-textarea [value]="userPrompt" (ionInput)="promptInput($event)" placeholder="图片提示词" autoGrow="true"></ion-textarea>
+  <ion-button (click)="createImage()" expand="block">生成logo</ion-button>
+  <!--logo画面提示词-->
+
+  <div>
+    {{PictureDescResult}}
+  </div>
+
+  <!-- 生成结果 -->
+  @if(images.length) {
+    @for(imageUrl of images;track imageUrl){
+      <img [src]="imageUrl" alt="" srcset="">
+    }
+  }
+  <!-- 生成状态 -->
+  @if(!images.length){
+    @if(imagineWork){
+      <h1>生成中</h1>
+    }
+    @if(!imagineWork){
+      <h1>未开始</h1>
+    }
+  }
+
+</ion-content>

+ 19 - 0
.history/soul-app/src/app/page-consult/page-consult.component_20241210113940.html

@@ -0,0 +1,19 @@
+<ion-content>
+    <h1>类型</h1>
+    <ion-input [value]="leixing" (ionInput)="leixingInput($event)"></ion-input>
+<!-- 文本域:生成提示词 -->
+ <h1>心理状况的描述</h1>
+<ion-textarea [value]="userPrompt" (ionInput)="promptInput($event)" placeholder="文本提示词" autoGrow="true"></ion-textarea>
+
+<!-- 按钮:执行消息生成函数 -->
+<ion-button (click)="sendMessage()" expand="block">初步判断</ion-button>
+
+@if(!isComplete){
+    <div>{{responseMsg}}</div>
+  }
+  <!-- 消息传输完成后,实时预览Markdown格式 -->
+@if(isComplete){
+    <fm-markdown-preview class="content-style" [content]="responseMsg"></fm-markdown-preview>
+  }
+
+</ion-content>

+ 51 - 0
.history/soul-app/src/app/page-consult/page-consult.component_20241210113940.scss

@@ -0,0 +1,51 @@
+/* 设置页面背景色 */
+ion-content {
+    --background: #f9f9f9; /* 设置内容背景色 */
+    margin: 0;
+    padding: 0;
+    font-family: Arial, sans-serif;
+  }
+/* 设置头部标题样式 */
+h1 {
+    color: #333333;
+    text-align: center;
+    margin: 20px 0;
+}
+ 
+/* 输入框和文本域的样式 */
+ion-input, ion-textarea {
+    width: 100%;
+    margin: 0 auto;
+    padding: 10px;
+    border: 1px solid #cccccc0c;
+    border-radius: 5px;
+    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
+    margin-bottom: 20px;
+}
+ 
+/* 按钮样式 */
+ion-button {
+    color: white;
+    border: none;
+    border-radius: 5px;
+    margin: 0 auto;
+    display: block;
+    width: 60%;
+    padding: 10px;
+    font-size: 16px;
+    text-transform: uppercase;
+    letter-spacing: 1px;
+    box-shadow: 0 4px 6px rgba(255, 255, 255, 0.904);
+}
+ 
+/* 特别为Markdown预览设置样式 */
+fm-markdown-preview {
+    font-size: 16px;
+    line-height: 1.5;
+    color: #333333;
+}
+ 
+/* 可选:增加一些过渡效果 */
+ion-input, ion-textarea, ion-button, div.response-msg, fm-markdown-preview {
+    transition: all 0.3s ease;
+}

+ 57 - 0
.history/soul-app/src/app/page-consult/page-consult.component_20241210113940.ts

@@ -0,0 +1,57 @@
+import { Component, OnInit } from '@angular/core';
+import {IonHeader, IonToolbar, IonTitle, IonContent, IonButton,
+  IonTextarea,IonInput} from '@ionic/angular/standalone';
+  /** 引用:从fmode-ng库引用FmodeChatCompletion类 */
+import { FmodeChatCompletion,MarkdownPreviewModule } from 'fmode-ng';
+@Component({
+  selector: 'app-page-consult',
+  templateUrl: './page-consult.component.html',
+  styleUrls: ['./page-consult.component.scss'],
+  standalone: true,
+  imports: [IonHeader, IonToolbar, IonTitle, IonContent, IonButton,
+    IonTextarea,IonInput,
+    MarkdownPreviewModule
+    ],
+})
+export class PageConsultComponent  implements OnInit {
+  constructor() {}
+  ngOnInit(): void {
+  }
+  // 用户输入提示词
+  leixing:string = "  心理问题类型:"
+  leixingInput(ev:any){
+    this.leixing = ev.detail.value;
+  }
+  // 用户输入提示词
+   userPrompt:string = "请详细描述你的情况:"
+  promptInput(ev:any){
+    this.userPrompt = ev.detail.value;
+  }
+  // 属性:组件内用于展示消息内容的变量
+  responseMsg:any = ""
+  // 方法:实例化completion对象,传入消息数组,并订阅生成的可观察对象。
+  isComplete:boolean = false; // 定义完成状态属性,用来标记是否补全完成
+  sendMessage(){
+    console.log("create")
+
+    let PromptTemplate = `
+    您作为一名专业的${this.leixing}智能心理咨询师,请您根据用户描述的情况,给出初步的判断,并给出一些详细的建议。'
+    以下是用户的口述:${this.userPrompt}
+    `
+
+    let completion = new FmodeChatCompletion([
+      {role:"system",content:""},
+      {role:"user",content:this.userPrompt}
+    ])
+    completion.sendCompletion().subscribe((message:any)=>{
+      // 打印消息体
+      console.log(message.content)
+      // 赋值消息内容给组件内属性
+      this.responseMsg = message.content
+      if(message?.complete){ // 判断message为完成状态,则设置isComplete为完成
+        this.isComplete = true
+      }
+    })
+  }
+
+}

+ 63 - 0
.history/soul-app/src/app/page-consult/page-consult.component_20241216084014.ts

@@ -0,0 +1,63 @@
+import { Component, OnInit } from '@angular/core';
+import {IonHeader, IonToolbar, IonTitle, IonContent, IonButton,
+  IonTextarea,IonInput,IonIcon} from '@ionic/angular/standalone';
+  /** 引用:从fmode-ng库引用FmodeChatCompletion类 */
+import { FmodeChatCompletion,MarkdownPreviewModule } from 'fmode-ng';
+import { Router } from '@angular/router';
+
+@Component({
+  selector: 'app-page-consult',
+  templateUrl: './page-consult.component.html',
+  styleUrls: ['./page-consult.component.scss'],
+  standalone: true,
+  imports: [IonHeader, IonToolbar, IonTitle, IonContent, IonButton,
+    IonTextarea,IonInput,IonIcon,
+    MarkdownPreviewModule
+    ],
+})
+
+export class PageConsultComponent  implements OnInit {
+  constructor(private router: Router) {}
+  ngOnInit(): void {
+  }
+  // 用户输入提示词
+  leixing:string = "  心理问题类型:"
+  leixingInput(ev:any){
+    this.leixing = ev.detail.value;
+  }
+  // 用户输入提示词
+   userPrompt:string = "请详细描述你的情况:"
+  promptInput(ev:any){
+    this.userPrompt = ev.detail.value;
+  }
+  // 属性:组件内用于展示消息内容的变量
+  responseMsg:any = ""
+  // 方法:实例化completion对象,传入消息数组,并订阅生成的可观察对象。
+  isComplete:boolean = false; // 定义完成状态属性,用来标记是否补全完成
+  sendMessage(){
+    console.log("create")
+
+    let PromptTemplate = `
+    您作为一名专业的${this.leixing}智能心理咨询师,请您根据用户描述的情况,给出初步的判断,并给出一些详细的建议。'
+    以下是用户的口述:${this.userPrompt}
+    `
+
+    let completion = new FmodeChatCompletion([
+      {role:"system",content:""},
+      {role:"user",content:this.userPrompt}
+    ])
+    completion.sendCompletion().subscribe((message:any)=>{
+      // 打印消息体
+      console.log(message.content)
+      // 赋值消息内容给组件内属性
+      this.responseMsg = message.content
+      if(message?.complete){ // 判断message为完成状态,则设置isComplete为完成
+        this.isComplete = true
+      }
+    })
+  }
+
+goTab1(){
+ this.router.navigate(['tabs/tab1']);
+}
+}

+ 58 - 0
.history/soul-app/src/app/page-consult/page-consult.component_20241216084016.scss

@@ -0,0 +1,58 @@
+/* 设置页面背景色 */
+ion-content {
+    --background: #f9f9f9; /* 设置内容背景色 */
+    margin: 0;
+    padding: 0;
+    font-family: Arial, sans-serif;
+  }
+/* 设置头部标题样式 */
+h1 {
+    color: #333333;
+    text-align: center;
+    margin: 20px 0;
+}
+ 
+/* 输入框和文本域的样式 */
+ion-input, ion-textarea {
+    width: 100%;
+    margin: 0 auto;
+    padding: 10px;
+    border: 1px solid #cccccc0c;
+    border-radius: 5px;
+    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
+    margin-bottom: 20px;
+}
+ 
+/* 按钮样式 */
+ion-button {
+    color: white;
+    border: none;
+    border-radius: 5px;
+    margin: 0 auto;
+    display: block;
+    width: 60%;
+    padding: 10px;
+    font-size: 16px;
+    text-transform: uppercase;
+    letter-spacing: 1px;
+    box-shadow: 0 4px 6px rgba(255, 255, 255, 0.904);
+}
+ 
+/* 特别为Markdown预览设置样式 */
+fm-markdown-preview {
+    font-size: 16px;
+    line-height: 1.5;
+    color: #333333;
+}
+ 
+/* 可选:增加一些过渡效果 */
+ion-input, ion-textarea, ion-button, div.response-msg, fm-markdown-preview {
+    transition: all 0.3s ease;
+}
+.title-text{
+    position: absolute;
+    display: flex;
+    left: 65px;
+    margin: auto;
+    top: 10px;
+  }

+ 58 - 0
.history/soul-app/src/app/page-consult/page-consult.component_20241216084021.scss

@@ -0,0 +1,58 @@
+/* 设置页面背景色 */
+ion-content {
+    --background: #f9f9f9; /* 设置内容背景色 */
+    margin: 0;
+    padding: 0;
+    font-family: Arial, sans-serif;
+  }
+/* 设置头部标题样式 */
+h1 {
+    color: #333333;
+    text-align: center;
+    margin: 20px 0;
+}
+ 
+/* 输入框和文本域的样式 */
+ion-input, ion-textarea {
+    width: 100%;
+    margin: 0 auto;
+    padding: 10px;
+    border: 1px solid #cccccc0c;
+    border-radius: 5px;
+    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
+    margin-bottom: 20px;
+}
+ 
+/* 按钮样式 */
+ion-button {
+    color: white;
+    border: none;
+    border-radius: 5px;
+    margin: 0 auto;
+    display: block;
+    width: 60%;
+    padding: 10px;
+    font-size: 16px;
+    text-transform: uppercase;
+    letter-spacing: 1px;
+    box-shadow: 0 4px 6px rgba(255, 255, 255, 0.904);
+}
+ 
+/* 特别为Markdown预览设置样式 */
+fm-markdown-preview {
+    font-size: 16px;
+    line-height: 1.5;
+    color: #333333;
+}
+ 
+/* 可选:增加一些过渡效果 */
+ion-input, ion-textarea, ion-button, div.response-msg, fm-markdown-preview {
+    transition: all 0.3s ease;
+}
+.title-text{
+    position: absolute;
+    display: flex;
+    left: 65px;
+    margin: auto;
+    top: 10px;
+  }

+ 34 - 0
.history/soul-app/src/app/page-consult/page-consult.component_20241216084024.html

@@ -0,0 +1,34 @@
+<ion-header>
+  <ion-toolbar>
+    <div class="toolbar-content">
+      <div class="button-container">
+        <ion-button (click)="goTab1()" fill="clear">
+          <ion-icon name="chevron-back" slot="start"></ion-icon>返回
+        </ion-button>
+      </div>
+      <ion-title class="title-text">
+        心理咨询
+      </ion-title>
+    </div>
+  </ion-toolbar>
+</ion-header>
+
+<ion-content>
+    <h1>类型</h1>
+    <ion-input [value]="leixing" (ionInput)="leixingInput($event)"></ion-input>
+<!-- 文本域:生成提示词 -->
+ <h1>心理状况的描述</h1>
+<ion-textarea [value]="userPrompt" (ionInput)="promptInput($event)" placeholder="文本提示词" autoGrow="true"></ion-textarea>
+
+<!-- 按钮:执行消息生成函数 -->
+<ion-button (click)="sendMessage()" expand="block">初步判断</ion-button>
+
+@if(!isComplete){
+    <div>{{responseMsg}}</div>
+  }
+  <!-- 消息传输完成后,实时预览Markdown格式 -->
+@if(isComplete){
+    <fm-markdown-preview class="content-style" [content]="responseMsg"></fm-markdown-preview>
+  }
+
+</ion-content>

+ 17 - 0
.history/soul-app/src/app/tab3/tab3.page_20241210113940.html

@@ -0,0 +1,17 @@
+<ion-header [translucent]="true">
+  <ion-toolbar>
+    <ion-title>
+      我的
+    </ion-title>
+  </ion-toolbar>
+</ion-header>
+
+<ion-content [fullscreen]="true">
+  <ion-header collapse="condense">
+    <ion-toolbar>
+      <ion-title size="large">Tab 3</ion-title>
+    </ion-toolbar>
+  </ion-header>
+
+  <app-explore-container name="Tab 3 page"></app-explore-container>
+</ion-content>

+ 0 - 0
.history/soul-app/src/app/tab3/tab3.page_20241210113940.scss


+ 14 - 0
.history/soul-app/src/app/tab3/tab3.page_20241210113940.ts

@@ -0,0 +1,14 @@
+import { Component } from '@angular/core';
+import { IonHeader, IonToolbar, IonTitle, IonContent } from '@ionic/angular/standalone';
+import { ExploreContainerComponent } from '../explore-container/explore-container.component';
+
+@Component({
+  selector: 'app-tab3',
+  templateUrl: 'tab3.page.html',
+  styleUrls: ['tab3.page.scss'],
+  standalone: true,
+  imports: [IonHeader, IonToolbar, IonTitle, IonContent, ExploreContainerComponent],
+})
+export class Tab3Page {
+  constructor() {}
+}

+ 65 - 0
.history/soul-app/src/app/tab3/tab3.page_20241216094604.html

@@ -0,0 +1,65 @@
+<ion-header [translucent]="true">
+  <ion-toolbar>
+    <ion-title>
+      我的
+    </ion-title>
+  </ion-toolbar>
+</ion-header>
+
+<ion-content [fullscreen]="true">
+  <!-- 用户信息区域 -->
+  <div class="user-info">
+    <ion-avatar>
+      <img src="assets/avatar-default.png" alt="头像">
+    </ion-avatar>
+    <div class="user-details">
+      <h2>用户名</h2>
+      <p>ID: 12345678</p>
+    </div>
+  </div>
+
+  <!-- 功能列表 -->
+  <ion-list>
+    <!-- 个人信息设置 -->
+    <ion-item>
+      <ion-icon name="person-outline" slot="start"></ion-icon>
+      <ion-label>个人信息</ion-label>
+      <ion-icon name="chevron-forward-outline" slot="end"></ion-icon>
+    </ion-item>
+
+    <!-- 我的收藏 -->
+    <ion-item>
+      <ion-icon name="heart-outline" slot="start"></ion-icon>
+      <ion-label>我的收藏</ion-label>
+      <ion-icon name="chevron-forward-outline" slot="end"></ion-icon>
+    </ion-item>
+
+    <!-- 消息通知 -->
+    <ion-item>
+      <ion-icon name="notifications-outline" slot="start"></ion-icon>
+      <ion-label>消息通知</ion-label>
+      <ion-icon name="chevron-forward-outline" slot="end"></ion-icon>
+    </ion-item>
+
+    <!-- 系统设置 -->
+    <ion-item>
+      <ion-icon name="settings-outline" slot="start"></ion-icon>
+      <ion-label>系统设置</ion-label>
+      <ion-icon name="chevron-forward-outline" slot="end"></ion-icon>
+    </ion-item>
+
+    <!-- 关于我们 -->
+    <ion-item>
+      <ion-icon name="information-circle-outline" slot="start"></ion-icon>
+      <ion-label>关于我们</ion-label>
+      <ion-icon name="chevron-forward-outline" slot="end"></ion-icon>
+    </ion-item>
+  </ion-list>
+
+  <!-- 退出登录按钮 -->
+  <div class="logout-button">
+    <ion-button expand="block" color="danger">
+      退出登录
+    </ion-button>
+  </div>
+</ion-content>

+ 53 - 0
.history/soul-app/src/app/tab3/tab3.page_20241216094616.scss

@@ -0,0 +1,53 @@
+.user-info {
+    padding: 20px;
+    display: flex;
+    align-items: center;
+    background: #ffffff;
+    margin-bottom: 10px;
+  
+    ion-avatar {
+      width: 80px;
+      height: 80px;
+      margin-right: 20px;
+    }
+  
+    .user-details {
+      h2 {
+        margin: 0;
+        font-size: 20px;
+        font-weight: bold;
+      }
+      p {
+        margin: 5px 0 0;
+        color: #666;
+        font-size: 14px;
+      }
+    }
+  }
+  
+  ion-list {
+    margin-bottom: 20px;
+    
+    ion-item {
+      --padding-start: 16px;
+      --padding-end: 16px;
+      
+      ion-icon[slot="start"] {
+        margin-right: 16px;
+        color: #666;
+      }
+      
+      ion-icon[slot="end"] {
+        color: #999;
+      }
+    }
+  }
+  
+  .logout-button {
+    padding: 0 20px;
+    margin-top: 30px;
+    
+    ion-button {
+      --border-radius: 4px;
+    }
+  }

+ 62 - 0
.history/soul-app/src/app/tab3/tab3.page_20241216094631.ts

@@ -0,0 +1,62 @@
+import { Component, CUSTOM_ELEMENTS_SCHEMA } from '@angular/core';
+import { 
+  IonHeader, 
+  IonToolbar, 
+  IonTitle, 
+  IonContent, 
+  IonList,
+  IonItem,
+  IonIcon,
+  IonLabel,
+  IonButton,
+  IonAvatar
+} from '@ionic/angular/standalone';
+import { ExploreContainerComponent } from '../explore-container/explore-container.component';
+import { addIcons } from 'ionicons';
+import { 
+  personOutline, 
+  heartOutline, 
+  notificationsOutline, 
+  settingsOutline, 
+  informationCircleOutline,
+  chevronForwardOutline 
+} from 'ionicons/icons';
+
+@Component({
+  selector: 'app-tab3',
+  templateUrl: 'tab3.page.html',
+  styleUrls: ['tab3.page.scss'],
+  standalone: true,
+  imports: [
+    IonHeader, 
+    IonToolbar, 
+    IonTitle, 
+    IonContent, 
+    IonList,
+    IonItem,
+    IonIcon,
+    IonLabel,
+    IonButton,
+    IonAvatar,
+    ExploreContainerComponent
+  ],
+  schemas: [CUSTOM_ELEMENTS_SCHEMA]
+})
+export class Tab3Page {
+  constructor() {
+    // 注册图标
+    addIcons({
+      personOutline, 
+      heartOutline, 
+      notificationsOutline, 
+      settingsOutline, 
+      informationCircleOutline,
+      chevronForwardOutline
+    });
+  }
+
+  // 退出登录方法
+  logout() {
+    console.log('退出登录');
+  }
+}

+ 18 - 0
.history/soul-app/src/app/tabs/tabs.page_20241210113940.html

@@ -0,0 +1,18 @@
+<ion-tabs>
+  <ion-tab-bar slot="bottom">
+    <ion-tab-button tab="tab1" href="/tabs/tab1">
+      <ion-icon aria-hidden="true" name="home"></ion-icon>
+      <ion-label>首页</ion-label>
+    </ion-tab-button>
+
+    <ion-tab-button tab="tab2" href="/tabs/tab2">
+      <ion-icon aria-hidden="true" name="chatbubbles"></ion-icon>
+      <ion-label>聊天</ion-label>
+    </ion-tab-button>
+
+    <ion-tab-button tab="tab3" href="/tabs/tab3">
+      <ion-icon aria-hidden="true" name="person"></ion-icon>
+      <ion-label>我的</ion-label>
+    </ion-tab-button>
+  </ion-tab-bar>
+</ion-tabs>

+ 1 - 0
.history/soul-app/src/app/tabs/tabs.page_20241210113940.scss

@@ -0,0 +1 @@
+

+ 19 - 0
.history/soul-app/src/app/tabs/tabs.page_20241210113940.ts

@@ -0,0 +1,19 @@
+import { Component, EnvironmentInjector, inject } from '@angular/core';
+import { IonTabs, IonTabBar, IonTabButton, IonIcon, IonLabel } from '@ionic/angular/standalone';
+import { addIcons } from 'ionicons';
+import { home, chatbubbles, person } from 'ionicons/icons';
+
+@Component({
+  selector: 'app-tabs',
+  templateUrl: 'tabs.page.html',
+  styleUrls: ['tabs.page.scss'],
+  standalone: true,
+  imports: [IonTabs, IonTabBar, IonTabButton, IonIcon, IonLabel],
+})
+export class TabsPage {
+  public environmentInjector = inject(EnvironmentInjector);
+
+  constructor() {
+    addIcons({ home, chatbubbles, person });
+  }
+}

+ 21 - 0
.history/soul-app/src/app/tabs/tabs.page_20241216084220.ts

@@ -0,0 +1,21 @@
+import { Component, EnvironmentInjector, inject } from '@angular/core';
+import { IonTabs, IonTabBar, IonTabButton, IonTitle,IonIcon, IonLabel } from '@ionic/angular/standalone';
+import { addIcons } from 'ionicons';
+import { home, chatbubbles, person,chevronBack } from 'ionicons/icons';
+
+
+@Component({
+  selector: 'app-tabs',
+  templateUrl: 'tabs.page.html',
+  styleUrls: ['tabs.page.scss'],
+  standalone: true,
+  imports: [IonTabs, IonTabBar, IonTabButton, IonIcon, IonLabel,IonTitle],
+})
+export class TabsPage {
+  public environmentInjector = inject(EnvironmentInjector);
+
+  constructor() {
+    addIcons({ home, chatbubbles, person ,chevronBack});
+  }
+
+}

+ 7 - 0
.history/soul-app/src/app/tabs/tabs.page_20241216084242.scss

@@ -0,0 +1,7 @@
+.button-container {
+    position: absolute;
+    display: flex; /* 使用flexbox布局 */
+    padding: 0px 0px;
+    left: 0px;
+  }
+ 

+ 18 - 0
.history/soul-app/src/app/tabs/tabs.page_20241216092203.html

@@ -0,0 +1,18 @@
+<ion-tabs>
+  <ion-tab-bar slot="bottom">
+    <ion-tab-button tab="tab1" href="/tabs/tab1">
+      <ion-icon aria-hidden="true" name="home"></ion-icon>
+      <ion-label>社区</ion-label>
+    </ion-tab-button>
+
+    <ion-tab-button tab="tab2" href="/tabs/tab2">
+      <ion-icon aria-hidden="true" name="chatbubbles"></ion-icon>
+      <ion-label>聊天</ion-label>
+    </ion-tab-button>
+
+    <ion-tab-button tab="tab3" href="/tabs/tab3">
+      <ion-icon aria-hidden="true" name="person"></ion-icon>
+      <ion-label>我的</ion-label>
+    </ion-tab-button>
+  </ion-tab-bar>
+</ion-tabs>

+ 61 - 0
.history/soul-app/src/app/tabs/tabs.routes_20241210113940.ts

@@ -0,0 +1,61 @@
+import { Routes } from '@angular/router';
+import { TabsPage } from './tabs.page';
+
+export const routes: Routes = [
+  {
+    path: 'tabs',
+    component: TabsPage,
+    children: [
+      {
+        path: 'tab1',
+        loadComponent: () =>
+          import('../tab1/tab1.page').then((m) => m.Tab1Page),
+      },
+      {
+        path: 'tab2',
+        loadComponent: () =>
+          import('../tab2/tab2.page').then((m) => m.Tab2Page),
+      },
+      {
+        path: 'tab3',
+        loadComponent: () =>
+          import('../tab3/tab3.page').then((m) => m.Tab3Page),
+      },
+      {
+        path: 'topic-detail',
+        loadComponent: () =>
+          import('../topic-detail/topic-detail.component').then((m) => m.TopicDetailComponent),
+      },
+      {
+        path: 'topic-detail2',
+        loadComponent: () =>
+          import('../topic-detail2/topic-detail2.component').then((m) => m.TopicDetail2Component),
+      },
+      {
+        path: 'topic-detail3',
+        loadComponent: () =>
+          import('../topic-detail3/topic-detail3.component').then((m) => m.TopicDetail3Component),
+      },
+      {
+        path: 'page-consult',
+        loadComponent: () =>
+          import('../page-consult/page-consult.component').then((m) => m.PageConsultComponent),
+      },
+      {
+        path: 'consult-picture',
+        loadComponent: () =>
+          import('../consult-picture/consult-picture.component').then((m) => m.ConsultPictureComponent),
+      },
+      {
+        path: '',
+        redirectTo: '/tabs/tab1',
+        pathMatch: 'full',
+      },
+    ],
+  },
+  {
+    path: '',
+    redirectTo: '/tabs/tab1',
+    pathMatch: 'full',
+  },
+];

+ 61 - 0
.history/soul-app/src/app/tabs/tabs.routes_20241216084229.ts

@@ -0,0 +1,61 @@
+import { Routes } from '@angular/router';
+import { TabsPage } from './tabs.page';
+
+export const routes: Routes = [
+  {
+    path: 'tabs',
+    component: TabsPage,
+    children: [
+      {
+        path: 'tab1',
+        loadComponent: () =>
+          import('../tab1/tab1.page').then((m) => m.Tab1Page),
+      },
+      {
+        path: 'tab2',
+        loadComponent: () =>
+          import('../tab2/tab2.page').then((m) => m.Tab2Page),
+      },
+      {
+        path: 'tab3',
+        loadComponent: () =>
+          import('../tab3/tab3.page').then((m) => m.Tab3Page),
+      },
+      {
+        path: 'topic-detail',
+        loadComponent: () =>
+          import('../topic-detail/topic-detail.component').then((m) => m.TopicDetailComponent),
+      },
+      {
+        path: 'topic-detail2',
+        loadComponent: () =>
+          import('../topic-detail2/topic-detail2.component').then((m) => m.TopicDetail2Component),
+      },
+      {
+        path: 'topic-detail3',
+        loadComponent: () =>
+          import('../topic-detail3/topic-detail3.component').then((m) => m.TopicDetail3Component),
+      },
+      {
+        path: 'page-consult',
+        loadComponent: () =>
+          import('../page-consult/page-consult.component').then((m) => m.PageConsultComponent),
+      },
+      {
+        path: 'consult-picture',
+        loadComponent: () =>
+          import('../consult-picture/consult-picture.component').then((m) => m.ConsultPictureComponent),
+      },
+      {
+        path: '',
+        redirectTo: '/tabs/tab1',
+        pathMatch: 'full',
+      },
+    ],
+  },
+  {
+    path: '',
+    redirectTo: '/tabs/tab1',
+    pathMatch: 'full',
+  },
+];

+ 72 - 0
.history/soul-app/src/app/topic-detail/topic-detail.component_20241210113940.html

@@ -0,0 +1,72 @@
+<ion-header>
+  <ion-toolbar>
+    <ion-title>管理焦虑情绪的指南</ion-title>
+  </ion-toolbar>
+</ion-header>
+
+<ion-content>
+  <!-- 管理焦虑的技巧区 -->
+  <section>
+    <ion-list>
+      <ion-list-header>
+        <ion-label>管理焦虑的技巧</ion-label>
+      </ion-list-header>
+      <ion-item *ngFor="let tip of tips">
+        <ion-label>
+          <h2>{{ tip.title }}</h2>
+          <p>{{ tip.description }}</p>
+        </ion-label>
+        <ion-icon name="chevron-down" slot="end" (click)="tip.expanded = !tip.expanded"></ion-icon>
+        <ion-item *ngIf="tip.expanded">
+          <ion-label>{{ tip.details }}</ion-label>
+        </ion-item>
+      </ion-item>
+    </ion-list>
+  </section>
+
+  <!-- 实用工具区 -->
+  <section>
+    <ion-list>
+      <ion-list-header>
+        <ion-label>实用工具</ion-label>
+      </ion-list-header>
+      <ion-item *ngFor="let tool of tools">
+        <ion-label>
+          <h2>{{ tool.name }}</h2>
+          <p>{{ tool.description }}</p>
+        </ion-label>
+        <ion-button slot="end" [href]="tool.link">{{ tool.buttonText }}</ion-button>
+      </ion-item>
+    </ion-list>
+  </section>
+
+  <!-- 资源区 -->
+  <section>
+    <ion-list>
+      <ion-list-header>
+        <ion-label>相关文章和视频</ion-label>
+      </ion-list-header>
+      <ion-item *ngFor="let resource of resources">
+        <ion-label>
+          <h2>{{ resource.title }}</h2>
+        </ion-label>
+        <ion-button slot="end" [href]="resource.link">{{ resource.buttonText }}</ion-button>
+      </ion-item>
+    </ion-list>
+  </section>
+
+  <!-- 社区支持区 -->
+  <section>
+    <ion-list>
+      <ion-list-header>
+        <ion-label>社区讨论</ion-label>
+      </ion-list-header>
+      <ion-item *ngFor="let discussion of discussions">
+        <ion-label>
+          <h2>{{ discussion.title }}</h2>
+        </ion-label>
+        <ion-button slot="end" [href]="discussion.link">参与讨论</ion-button>
+      </ion-item>
+    </ion-list>
+  </section>
+</ion-content>

+ 28 - 0
.history/soul-app/src/app/topic-detail/topic-detail.component_20241210113940.scss

@@ -0,0 +1,28 @@
+/* 设置页面背景色 */
+ion-content {
+    --background: #ffffff; /* 白色背景 */
+}
+ion-title {
+    font-size: 24px; /* 增大字体大小 */
+    font-weight: bold; /* 加粗 */
+}
+/* 设置卡片的样式 */
+ion-list {
+    margin: 10px; /* 卡片之间的间距 */
+    border-radius: 10px; /* 圆角效果 */
+    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1); /* 阴影效果 */
+  }
+
+/* 设置列表项的样式 */
+ion-item {
+    margin: 5px 0; /* 列表项之间的间距 */
+  }
+
+/* 设置按钮的样式(如果按钮不在顶部方框内) */
+ion-button {
+    font-size: 15px; /* 增大字体大小 */
+    padding: 8px 16px; /* 内边距 */
+    margin-top: 8px; /* 上间距,仅在需要时添加 */
+    text-transform: none; /* 按钮文字不变形 */
+    height: 50px;
+}

+ 84 - 0
.history/soul-app/src/app/topic-detail/topic-detail.component_20241210113940.ts

@@ -0,0 +1,84 @@
+import { CommonModule } from '@angular/common';
+import { Component, OnInit } from '@angular/core';
+import { IonHeader,IonButton, IonContent, IonIcon, IonItem, IonLabel, IonList, 
+  IonListHeader, IonTitle, IonToolbar,IonInput,IonSearchbar } from '@ionic/angular/standalone';
+import { ExploreContainerComponent } from '../explore-container/explore-container.component';
+
+@Component({
+  selector: 'app-topic-detail',
+  templateUrl: './topic-detail.component.html',
+  styleUrls: ['./topic-detail.component.scss'],
+  standalone: true,
+  imports: [IonHeader,IonToolbar,IonTitle,IonContent,ExploreContainerComponent,
+    IonList,IonListHeader,IonItem,
+    IonLabel,IonIcon,IonButton,
+    IonInput,IonSearchbar,
+    CommonModule
+  ]
+})
+export class TopicDetailComponent  implements OnInit {
+  tips = [
+    {
+      title: '深呼吸',
+      description: '通过深呼吸来放松身心,缓解焦虑',
+      details: '深呼吸可以帮助你放慢心率,增加氧气摄入,改善心理状态',
+      expanded: false,
+    },
+    {
+      title: '运动',
+      description: '规律的运动有助于释放压力和焦虑',
+      details: '运动可以释放内啡肽,提升你的情绪',
+      expanded: false,
+    },
+    {
+      title: '正念冥想',
+      description: '通过正念练习来关注当下,减少焦虑',
+      details: '正念冥想可以帮助你更好地管理情绪,提升专注力',
+      expanded: false,
+    },
+  ];
+
+  tools = [
+    {
+      name: '焦虑管理APP',
+      description: '帮助你记录情绪,提供放松练习',
+      link: 'https://www.18183.com/down/2968763.html',
+      buttonText: '下载APP',
+    },
+    {
+      name: '在线冥想课程',
+      description: '提供多种冥想练习,帮助你减轻焦虑',
+      link: 'https://www.bilibili.com/video/BV1gdUpYyEiw/',
+      buttonText: '查看视频',
+    },
+  ];
+
+  resources = [
+    {
+      title: '控制焦虑的方法',
+      link: 'https://m.baidu.com/bh/m/detail/ar_13481633186713755563',
+      buttonText: '查看更多',
+    },
+    {
+      title: '克服焦虑的方法',
+      link: 'https://m.baidu.com/bh/m/detail/ar_4824212419687234431',
+      buttonText: '阅读更多',
+    },
+    {
+      title: '焦虑管理技巧',
+      link: 'https://www.bilibili.com/video/BV1Kj2KYJEYU/',
+      buttonText: '观看视频',
+    },
+  ];
+
+  discussions = [
+    {
+      title: '分享你的焦虑管理经验',
+      link: 'https://example.com/community',
+    },
+  ];
+  constructor() { }
+
+  ngOnInit() {}
+
+}

+ 81 - 0
.history/soul-app/src/app/topic-detail/topic-detail.component_20241216084316.html

@@ -0,0 +1,81 @@
+<ion-header>
+  <ion-toolbar>
+    <div class="toolbar-content">
+      <div class="button-container">
+        <ion-button (click)="goTab1()" fill="clear">
+          <ion-icon name="chevron-back" slot="start"></ion-icon>返回
+        </ion-button>
+      </div>
+      <ion-title class="title-text">
+        管理焦虑情绪的指南
+      </ion-title>
+    </div>
+  </ion-toolbar>
+</ion-header>
+
+<ion-content>
+  <!-- 管理焦虑的技巧区 -->
+  <section>
+    <ion-list>
+      <ion-list-header>
+        <ion-label>管理焦虑的技巧</ion-label>
+      </ion-list-header>
+      <ion-item *ngFor="let tip of tips">
+        <ion-label>
+          <h2>{{ tip.title }}</h2>
+          <p>{{ tip.description }}</p>
+        </ion-label>
+        <ion-icon name="chevron-down" slot="end" (click)="tip.expanded = !tip.expanded"></ion-icon>
+        <ion-item *ngIf="tip.expanded">
+          <ion-label>{{ tip.details }}</ion-label>
+        </ion-item>
+      </ion-item>
+    </ion-list>
+  </section>
+
+  <!-- 实用工具区 -->
+  <section>
+    <ion-list>
+      <ion-list-header>
+        <ion-label>实用工具</ion-label>
+      </ion-list-header>
+      <ion-item *ngFor="let tool of tools">
+        <ion-label>
+          <h2>{{ tool.name }}</h2>
+          <p>{{ tool.description }}</p>
+        </ion-label>
+        <ion-button slot="end" [href]="tool.link">{{ tool.buttonText }}</ion-button>
+      </ion-item>
+    </ion-list>
+  </section>
+
+  <!-- 资源区 -->
+  <section>
+    <ion-list>
+      <ion-list-header>
+        <ion-label>相关文章和视频</ion-label>
+      </ion-list-header>
+      <ion-item *ngFor="let resource of resources">
+        <ion-label>
+          <h2>{{ resource.title }}</h2>
+        </ion-label>
+        <ion-button slot="end" [href]="resource.link">{{ resource.buttonText }}</ion-button>
+      </ion-item>
+    </ion-list>
+  </section>
+
+  <!-- 社区支持区 -->
+  <section>
+    <ion-list>
+      <ion-list-header>
+        <ion-label>社区讨论</ion-label>
+      </ion-list-header>
+      <ion-item *ngFor="let discussion of discussions">
+        <ion-label>
+          <h2>{{ discussion.title }}</h2>
+        </ion-label>
+        <ion-button slot="end" [href]="discussion.link">参与讨论</ion-button>
+      </ion-item>
+    </ion-list>
+  </section>
+</ion-content>

+ 38 - 0
.history/soul-app/src/app/topic-detail/topic-detail.component_20241216084335.scss

@@ -0,0 +1,38 @@
+/* 设置页面背景色 */
+ion-content {
+  --background: #ffffff; /* 白色背景 */
+}
+ion-title {
+  font-size: 24px; /* 增大字体大小 */
+  font-weight: bold; /* 加粗 */
+}
+/* 设置卡片的样式 */
+ion-list {
+  margin: 10px; /* 卡片之间的间距 */
+  border-radius: 10px; /* 圆角效果 */
+  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1); /* 阴影效果 */
+}
+ion-button {
+  font-size: 15px; /* 增大字体大小 */
+  margin-top: 8px; /* 上间距,仅在需要时添加 */
+  text-transform: none; /* 按钮文字不变形 */
+  height: 35px;
+}
+
+/* 设置列表项的样式 */
+ion-item {
+  margin: 5px 0; /* 列表项之间的间距 */
+}
+
+/* 设置按钮的样式(如果按钮不在顶部方框内) */
+
+ion-toolbar {
+margin: auto;
+}
+.title-text{
+position: absolute;
+display: flex;
+left: 65px;
+margin: auto;
+top: 10px;
+}

+ 89 - 0
.history/soul-app/src/app/topic-detail/topic-detail.component_20241216084741.ts

@@ -0,0 +1,89 @@
+import { CommonModule } from '@angular/common';
+import { Component, OnInit } from '@angular/core';
+import { IonHeader,IonButton, IonContent, IonIcon, IonItem, IonLabel, IonList, 
+  IonListHeader, IonTitle, IonToolbar,IonInput,IonSearchbar } from '@ionic/angular/standalone';
+import { ExploreContainerComponent } from '../explore-container/explore-container.component';
+import { Router } from '@angular/router';
+
+@Component({
+  selector: 'app-topic-detail',
+  templateUrl: './topic-detail.component.html',
+  styleUrls: ['./topic-detail.component.scss'],
+  standalone: true,
+  imports: [IonHeader,IonToolbar,IonTitle,IonContent,ExploreContainerComponent,
+    IonList,IonListHeader,IonItem,
+    IonLabel,IonIcon,IonButton,
+    IonInput,IonSearchbar,
+    CommonModule
+  ]
+})
+export class TopicDetailComponent  implements OnInit {
+  tips = [
+    {
+      title: '深呼吸',
+      description: '通过深呼吸来放松身心,缓解焦虑',
+      details: '深呼吸可以帮助你放慢心率,增加氧气摄入,改善心理状态',
+      expanded: false,
+    },
+    {
+      title: '运动',
+      description: '规律的运动有助于释放压力和焦虑',
+      details: '运动可以释放内啡肽,提升你的情绪',
+      expanded: false,
+    },
+    {
+      title: '正念冥想',
+      description: '通过正念练习来关注当下,减少焦虑',
+      details: '正念冥想可以帮助你更好地管理情绪,提升专注力',
+      expanded: false,
+    },
+  ];
+
+  tools = [
+    {
+      name: '焦虑管理APP',
+      description: '帮助你记录情绪,提供放松练习',
+      link: 'https://www.18183.com/down/2968763.html',
+      buttonText: '下载APP',
+    },
+    {
+      name: '在线冥想课程',
+      description: '提供多种冥想练习,帮助你减轻焦虑',
+      link: 'https://www.bilibili.com/video/BV1gdUpYyEiw/',
+      buttonText: '查看视频',
+    },
+  ];
+
+  resources = [
+    {
+      title: '控制焦虑的方法',
+      link: 'https://m.baidu.com/bh/m/detail/ar_13481633186713755563',
+      buttonText: '查看更多',
+    },
+    {
+      title: '克服焦虑的方法',
+      link: 'https://m.baidu.com/bh/m/detail/ar_4824212419687234431',
+      buttonText: '阅读更多',
+    },
+    {
+      title: '焦虑管理技巧',
+      link: 'https://www.bilibili.com/video/BV1Kj2KYJEYU/',
+      buttonText: '观看视频',
+    },
+  ];
+
+  discussions = [
+    {
+      title: '分享你的焦虑管理经验',
+      link: 'https://example.com/community',
+    },
+  ];
+  constructor(private router: Router) {
+    
+   }
+   goTab1(){
+    this.router.navigate(['tabs/tab1']);
+   }
+  ngOnInit() {}
+
+}

+ 72 - 0
.history/soul-app/src/app/topic-detail2/topic-detail2.component_20241210113940.html

@@ -0,0 +1,72 @@
+<ion-header>
+  <ion-toolbar>
+    <ion-title>克服抑郁的有效方法</ion-title>
+  </ion-toolbar>
+</ion-header>
+
+<ion-content>
+  <!-- 克服抑郁的方法区 -->
+  <section>
+    <ion-list>
+      <ion-list-header>
+        <ion-label>克服抑郁的方法</ion-label>
+      </ion-list-header>
+      <ion-item *ngFor="let method of methods">
+        <ion-label>
+          <h2>{{ method.title }}</h2>
+          <p>{{ method.description }}</p>
+        </ion-label>
+        <ion-icon name="chevron-down" slot="end" (click)="method.expanded = !method.expanded"></ion-icon>
+        <ion-item *ngIf="method.expanded">
+          <ion-label>{{ method.details }}</ion-label>
+        </ion-item>
+      </ion-item>
+    </ion-list>
+  </section>
+
+  <!-- 自助工具区 -->
+  <section>
+    <ion-list>
+      <ion-list-header>
+        <ion-label>自助工具推荐</ion-label>
+      </ion-list-header>
+      <ion-item *ngFor="let tool of tools">
+        <ion-label>
+          <h2>{{ tool.name }}</h2>
+          <p>{{ tool.description }}</p>
+        </ion-label>
+        <ion-button slot="end" [href]="tool.link">{{ tool.buttonText }}</ion-button>
+      </ion-item>
+    </ion-list>
+  </section>
+
+  <!-- 资源区 -->
+  <section>
+    <ion-list>
+      <ion-list-header>
+        <ion-label>相关文章和视频</ion-label>
+      </ion-list-header>
+      <ion-item *ngFor="let resource of resources">
+        <ion-label>
+          <h2>{{ resource.title }}</h2>
+        </ion-label>
+        <ion-button slot="end" [href]="resource.link">{{ resource.buttonText }}</ion-button>
+      </ion-item>
+    </ion-list>
+  </section>
+
+  <!-- 社区支持区 -->
+  <section>
+    <ion-list>
+      <ion-list-header>
+        <ion-label>社区讨论</ion-label>
+      </ion-list-header>
+      <ion-item *ngFor="let discussion of discussions">
+        <ion-label>
+          <h2>{{ discussion.title }}</h2>
+        </ion-label>
+        <ion-button slot="end" [href]="discussion.link">参与讨论</ion-button>
+      </ion-item>
+    </ion-list>
+  </section>
+</ion-content>

+ 28 - 0
.history/soul-app/src/app/topic-detail2/topic-detail2.component_20241210113940.scss

@@ -0,0 +1,28 @@
+/* 设置页面背景色 */
+ion-content {
+    --background: #ffffff; /* 白色背景 */
+}
+
+/* 设置卡片的样式 */
+ion-list {
+    margin: 10px; /* 卡片之间的间距 */
+    border-radius: 10px; /* 圆角效果 */
+    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1); /* 阴影效果 */
+  }
+
+/* 设置列表项的样式 */
+ion-item {
+    margin: 5px 0; /* 列表项之间的间距 */
+  }
+
+/* 设置按钮的样式(如果按钮不在顶部方框内) */
+ion-button {
+    font-size: 15px; /* 增大字体大小 */
+    margin-top: 8px; /* 上间距,仅在需要时添加 */
+    text-transform: none; /* 按钮文字不变形 */
+    height: 35px;
+}
+ion-title {
+  font-size: 24px; /* 增大字体大小 */
+  font-weight: bold; /* 加粗 */
+}

+ 77 - 0
.history/soul-app/src/app/topic-detail2/topic-detail2.component_20241210113940.ts

@@ -0,0 +1,77 @@
+import { CommonModule } from '@angular/common';
+import { Component, OnInit } from '@angular/core';
+import { IonButton, IonContent, IonHeader, IonIcon, IonInput, IonItem, IonLabel,
+   IonList, IonListHeader, IonSearchbar, IonTitle, IonToolbar } from '@ionic/angular/standalone';
+import { ExploreContainerComponent } from '../explore-container/explore-container.component';
+
+@Component({
+  selector: 'app-topic-detail2',
+  templateUrl: './topic-detail2.component.html',
+  styleUrls: ['./topic-detail2.component.scss'],
+  standalone: true,
+  imports:[IonHeader,IonToolbar,IonTitle,IonContent,ExploreContainerComponent,
+    IonList,IonListHeader,IonLabel,IonItem,IonIcon,
+  IonButton,IonInput,IonSearchbar,
+  CommonModule]
+})
+export class TopicDetail2Component  implements OnInit {
+  methods = [
+    {
+      title: '寻求专业帮助',
+      description: '咨询心理医生或心理治疗师,获得专业的支持和指导',
+      details: '专业的心理咨询可以帮助你更好地理解自己的情绪,并提供有效的应对策略',
+      expanded: false,
+    },
+    {
+      title: '建立健康的生活方式',
+      description: '保持规律的作息、均衡的饮食和适量的运动',
+      details: '健康的生活方式可以显著改善你的心理状态,增强抵抗抑郁的能力',
+      expanded: false,
+    },
+    {
+      title: '与他人交流',
+      description: '与朋友和家人分享你的感受,建立支持网络',
+      details: '交流可以减轻孤独感,增强社会支持,帮助你更好地应对抑郁',
+      expanded: false,
+    },
+  ];
+
+  tools = [
+    {
+      name: '抑郁管理APP',
+      description: '帮助你记录情绪变化,提供自助练习',
+      link: 'https://bbs.51766.com/soft/712244.html',
+      buttonText: '下载APP',
+    },
+    {
+      name: '在线支持小组',
+      description: '与其他抑郁症患者交流,分享经验',
+      link: 'https://www.douban.com/group/739850/',
+      buttonText: '加入小组',
+    },
+  ];
+
+  resources = [
+    {
+      title: '克服抑郁的十大技巧',
+      link: 'https://m.baidu.com/bh/m/detail/ar_6218671750317725196',
+      buttonText: '阅读更多',
+    },
+    {
+      title: '如何面对抑郁',
+      link: 'https://m.baidu.com/bh/m/detail/ar_12253741886669041142',
+      buttonText: '查看更多',
+    },
+  ];
+
+  discussions = [
+    {
+      title: '分享你的抑郁克服故事',
+      link: 'https://example.com/community',
+    },
+  ];
+  constructor() { }
+
+  ngOnInit() {}
+
+}

+ 81 - 0
.history/soul-app/src/app/topic-detail2/topic-detail2.component_20241216084802.html

@@ -0,0 +1,81 @@
+<ion-header>
+  <ion-toolbar>
+    <div class="toolbar-content">
+      <div class="button-container">
+        <ion-button (click)="goTab1()" fill="clear">
+          <ion-icon name="chevron-back" slot="start"></ion-icon>返回
+        </ion-button>
+      </div>
+      <ion-title class="title-text">
+        克服抑郁的有效方法
+      </ion-title>
+    </div>
+  </ion-toolbar>
+</ion-header>
+
+<ion-content>
+  <!-- 克服抑郁的方法区 -->
+  <section>
+    <ion-list>
+      <ion-list-header>
+        <ion-label>克服抑郁的方法</ion-label>
+      </ion-list-header>
+      <ion-item *ngFor="let method of methods">
+        <ion-label>
+          <h2>{{ method.title }}</h2>
+          <p>{{ method.description }}</p>
+        </ion-label>
+        <ion-icon name="chevron-down" slot="end" (click)="method.expanded = !method.expanded"></ion-icon>
+        <ion-item *ngIf="method.expanded">
+          <ion-label>{{ method.details }}</ion-label>
+        </ion-item>
+      </ion-item>
+    </ion-list>
+  </section>
+
+  <!-- 自助工具区 -->
+  <section>
+    <ion-list>
+      <ion-list-header>
+        <ion-label>自助工具推荐</ion-label>
+      </ion-list-header>
+      <ion-item *ngFor="let tool of tools">
+        <ion-label>
+          <h2>{{ tool.name }}</h2>
+          <p>{{ tool.description }}</p>
+        </ion-label>
+        <ion-button slot="end" [href]="tool.link">{{ tool.buttonText }}</ion-button>
+      </ion-item>
+    </ion-list>
+  </section>
+
+  <!-- 资源区 -->
+  <section>
+    <ion-list>
+      <ion-list-header>
+        <ion-label>相关文章和视频</ion-label>
+      </ion-list-header>
+      <ion-item *ngFor="let resource of resources">
+        <ion-label>
+          <h2>{{ resource.title }}</h2>
+        </ion-label>
+        <ion-button slot="end" [href]="resource.link">{{ resource.buttonText }}</ion-button>
+      </ion-item>
+    </ion-list>
+  </section>
+
+  <!-- 社区支持区 -->
+  <section>
+    <ion-list>
+      <ion-list-header>
+        <ion-label>社区讨论</ion-label>
+      </ion-list-header>
+      <ion-item *ngFor="let discussion of discussions">
+        <ion-label>
+          <h2>{{ discussion.title }}</h2>
+        </ion-label>
+        <ion-button slot="end" [href]="discussion.link">参与讨论</ion-button>
+      </ion-item>
+    </ion-list>
+  </section>
+</ion-content>

+ 35 - 0
.history/soul-app/src/app/topic-detail2/topic-detail2.component_20241216084811.scss

@@ -0,0 +1,35 @@
+/* 设置页面背景色 */
+ion-content {
+  --background: #ffffff; /* 白色背景 */
+}
+
+/* 设置卡片的样式 */
+ion-list {
+  margin: 10px; /* 卡片之间的间距 */
+  border-radius: 10px; /* 圆角效果 */
+  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1); /* 阴影效果 */
+}
+
+/* 设置列表项的样式 */
+ion-item {
+  margin: 5px 0; /* 列表项之间的间距 */
+}
+
+/* 设置按钮的样式(如果按钮不在顶部方框内) */
+ion-button {
+  font-size: 15px; /* 增大字体大小 */
+  margin-top: 8px; /* 上间距,仅在需要时添加 */
+  text-transform: none; /* 按钮文字不变形 */
+  height: 35px;
+}
+ion-title {
+font-size: 24px; /* 增大字体大小 */
+font-weight: bold; /* 加粗 */
+}
+.title-text{
+position: absolute;
+display: flex;
+left: 65px;
+margin: auto;
+top: 10px;
+}

+ 80 - 0
.history/soul-app/src/app/topic-detail2/topic-detail2.component_20241216084823.ts

@@ -0,0 +1,80 @@
+import { CommonModule } from '@angular/common';
+import { Component, OnInit } from '@angular/core';
+import { IonButton, IonContent, IonHeader, IonIcon, IonInput, IonItem, IonLabel,
+   IonList, IonListHeader, IonSearchbar, IonTitle, IonToolbar } from '@ionic/angular/standalone';
+import { ExploreContainerComponent } from '../explore-container/explore-container.component';
+import { Router } from '@angular/router';
+
+@Component({
+  selector: 'app-topic-detail2',
+  templateUrl: './topic-detail2.component.html',
+  styleUrls: ['./topic-detail2.component.scss'],
+  standalone: true,
+  imports:[IonHeader,IonToolbar,IonTitle,IonContent,ExploreContainerComponent,
+    IonList,IonListHeader,IonLabel,IonItem,IonIcon,
+  IonButton,IonInput,IonSearchbar,
+  CommonModule]
+})
+export class TopicDetail2Component  implements OnInit {
+  methods = [
+    {
+      title: '寻求专业帮助',
+      description: '咨询心理医生或心理治疗师,获得专业的支持和指导',
+      details: '专业的心理咨询可以帮助你更好地理解自己的情绪,并提供有效的应对策略',
+      expanded: false,
+    },
+    {
+      title: '建立健康的生活方式',
+      description: '保持规律的作息、均衡的饮食和适量的运动',
+      details: '健康的生活方式可以显著改善你的心理状态,增强抵抗抑郁的能力',
+      expanded: false,
+    },
+    {
+      title: '与他人交流',
+      description: '与朋友和家人分享你的感受,建立支持网络',
+      details: '交流可以减轻孤独感,增强社会支持,帮助你更好地应对抑郁',
+      expanded: false,
+    },
+  ];
+
+  tools = [
+    {
+      name: '抑郁管理APP',
+      description: '帮助你记录情绪变化,提供自助练习',
+      link: 'https://bbs.51766.com/soft/712244.html',
+      buttonText: '下载APP',
+    },
+    {
+      name: '在线支持小组',
+      description: '与其他抑郁症患者交流,分享经验',
+      link: 'https://www.douban.com/group/739850/',
+      buttonText: '加入小组',
+    },
+  ];
+
+  resources = [
+    {
+      title: '克服抑郁的十大技巧',
+      link: 'https://m.baidu.com/bh/m/detail/ar_6218671750317725196',
+      buttonText: '阅读更多',
+    },
+    {
+      title: '如何面对抑郁',
+      link: 'https://m.baidu.com/bh/m/detail/ar_12253741886669041142',
+      buttonText: '查看更多',
+    },
+  ];
+
+  discussions = [
+    {
+      title: '分享你的抑郁克服故事',
+      link: 'https://example.com/community',
+    },
+  ];
+  constructor(private router: Router) { }
+  goTab1(){
+    this.router.navigate(['tabs/tab1']);
+   }
+  ngOnInit() {}
+
+}

+ 72 - 0
.history/soul-app/src/app/topic-detail3/topic-detail3.component_20241210113940.html

@@ -0,0 +1,72 @@
+<ion-header>
+  <ion-toolbar>
+    <ion-title>提升自信心的技巧</ion-title>
+  </ion-toolbar>
+</ion-header>
+
+<ion-content>
+  <!-- 提升自信心的技巧区 -->
+  <section>
+    <ion-list>
+      <ion-list-header>
+        <ion-label>提升自信心的技巧</ion-label>
+      </ion-list-header>
+      <ion-item *ngFor="let tip of tips">
+        <ion-label>
+          <h2>{{ tip.title }}</h2>
+          <p>{{ tip.description }}</p>
+        </ion-label>
+        <ion-icon name="chevron-down" slot="end" (click)="tip.expanded = !tip.expanded"></ion-icon>
+        <ion-item *ngIf="tip.expanded">
+          <ion-label>{{ tip.details }}</ion-label>
+        </ion-item>
+      </ion-item>
+    </ion-list>
+  </section>
+
+  <!-- 实用工具区 -->
+  <section>
+    <ion-list>
+      <ion-list-header>
+        <ion-label>实用工具推荐</ion-label>
+      </ion-list-header>
+      <ion-item *ngFor="let tool of tools">
+        <ion-label>
+          <h2>{{ tool.name }}</h2>
+          <p>{{ tool.description }}</p>
+        </ion-label>
+        <ion-button slot="end" [href]="tool.link">{{ tool.buttonText }}</ion-button>
+      </ion-item>
+    </ion-list>
+  </section>
+
+  <!-- 资源区 -->
+  <section>
+    <ion-list>
+      <ion-list-header>
+        <ion-label>相关文章和视频</ion-label>
+      </ion-list-header>
+      <ion-item *ngFor="let resource of resources">
+        <ion-label>
+          <h2>{{ resource.title }}</h2>
+        </ion-label>
+        <ion-button slot="end" [href]="resource.link">{{ resource.buttonText }}</ion-button>
+      </ion-item>
+    </ion-list>
+  </section>
+
+  <!-- 社区支持区 -->
+  <section>
+    <ion-list>
+      <ion-list-header>
+        <ion-label>社区讨论</ion-label>
+      </ion-list-header>
+      <ion-item *ngFor="let discussion of discussions">
+        <ion-label>
+          <h2>{{ discussion.title }}</h2>
+        </ion-label>
+        <ion-button slot="end" [href]="discussion.link">参与讨论</ion-button>
+      </ion-item>
+    </ion-list>
+  </section>
+</ion-content>

+ 28 - 0
.history/soul-app/src/app/topic-detail3/topic-detail3.component_20241210113940.scss

@@ -0,0 +1,28 @@
+/* 设置页面背景色 */
+ion-content {
+    --background: #ffffff; /* 白色背景 */
+}
+ion-title {
+    font-size: 24px; /* 增大字体大小 */
+    font-weight: bold; /* 加粗 */
+}
+/* 设置卡片的样式 */
+ion-list {
+    margin: 10px; /* 卡片之间的间距 */
+    border-radius: 10px; /* 圆角效果 */
+    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1); /* 阴影效果 */
+  }
+
+/* 设置列表项的样式 */
+ion-item {
+    margin: 5px 0; /* 列表项之间的间距 */
+  }
+
+/* 设置按钮的样式(如果按钮不在顶部方框内) */
+ion-button {
+    font-size: 15px; /* 增大字体大小 */
+    padding: 8px 16px; /* 内边距 */
+    margin-top: 8px; /* 上间距,仅在需要时添加 */
+    text-transform: none; /* 按钮文字不变形 */
+    height: 50px;
+}

+ 79 - 0
.history/soul-app/src/app/topic-detail3/topic-detail3.component_20241210113940.ts

@@ -0,0 +1,79 @@
+import { Component, OnInit } from '@angular/core';
+import { IonButton, IonContent, IonHeader, IonIcon, IonInput, IonItem, IonLabel, IonList, IonListHeader, 
+  IonSearchbar, IonTitle, IonToolbar } from '@ionic/angular/standalone';
+import { ExploreContainerComponent } from '../explore-container/explore-container.component';
+import { CommonModule } from '@angular/common';
+
+@Component({
+  selector: 'app-topic-detail3',
+  templateUrl: './topic-detail3.component.html',
+  styleUrls: ['./topic-detail3.component.scss'],
+  standalone: true,
+  imports:[IonHeader,IonToolbar,IonTitle,IonContent,ExploreContainerComponent,
+    IonList,IonListHeader,IonLabel,IonItem,IonIcon,IonButton,
+    IonInput,IonSearchbar,
+    CommonModule
+  ],
+})
+export class TopicDetail3Component  implements OnInit {
+  tips = [
+    {
+      title: '设定小目标',
+      description: '通过设定并完成小目标来增强自信心。',
+      details: '每完成一个小目标,都会增强你的成就感。',
+      expanded: false,
+    },
+    {
+      title: '积极自我对话',
+      description: '通过积极的自我对话来改变消极思维。',
+      details: '用积极的语言鼓励自己,提升自我肯定感。',
+      expanded: false,
+    },
+    {
+      title: '练习身体语言',
+      description: '通过开放的身体语言来传达自信。',
+      details: '站直、微笑和保持眼神接触可以帮助你感到更自信。',
+      expanded: false,
+    },
+  ];
+
+  tools = [
+    {
+      name: '自信心提升APP',
+      description: '提供每日自信心练习和积极的提醒。',
+      link: 'https://www.liqucn.com/rj/9679961013722.shtml',
+      buttonText: '下载APP',
+    },
+    {
+      name: '在线视频',
+      description: '学习更多关于自信心提升的技巧。',
+      link: 'https://www.bilibili.com/video/BV1GQBsYfECG/',
+      buttonText: '查看视频',
+    },
+  ];
+
+  resources = [
+    {
+      title: '提升自信心的有效方法',
+      link: 'https://m.baidu.com/bh/m/detail/ar_4782723165528593464',
+      buttonText: '阅读更多',
+    },
+    {
+      title: '如何在公众面前自信演讲',
+      link: 'https://www.bilibili.com/video/BV1eH4y1f7d1/',
+      buttonText: '观看视频',
+    },
+  ];
+
+  discussions = [
+    {
+      title: '分享你的自信提升故事',
+      link: 'https://example.com/community',
+    },
+  ];
+
+  constructor() { }
+
+  ngOnInit() {}
+
+}

+ 81 - 0
.history/soul-app/src/app/topic-detail3/topic-detail3.component_20241216084835.html

@@ -0,0 +1,81 @@
+<ion-header>
+  <ion-toolbar>
+    <div class="toolbar-content">
+      <div class="button-container">
+        <ion-button (click)="goTab1()" fill="clear">
+          <ion-icon name="chevron-back" slot="start"></ion-icon>返回
+        </ion-button>
+      </div>
+      <ion-title class="title-text">
+        提升自信心的技巧
+      </ion-title>
+    </div>
+  </ion-toolbar>
+</ion-header>
+
+<ion-content>
+  <!-- 提升自信心的技巧区 -->
+  <section>
+    <ion-list>
+      <ion-list-header>
+        <ion-label>提升自信心的技巧</ion-label>
+      </ion-list-header>
+      <ion-item *ngFor="let tip of tips">
+        <ion-label>
+          <h2>{{ tip.title }}</h2>
+          <p>{{ tip.description }}</p>
+        </ion-label>
+        <ion-icon name="chevron-down" slot="end" (click)="tip.expanded = !tip.expanded"></ion-icon>
+        <ion-item *ngIf="tip.expanded">
+          <ion-label>{{ tip.details }}</ion-label>
+        </ion-item>
+      </ion-item>
+    </ion-list>
+  </section>
+
+  <!-- 实用工具区 -->
+  <section>
+    <ion-list>
+      <ion-list-header>
+        <ion-label>实用工具推荐</ion-label>
+      </ion-list-header>
+      <ion-item *ngFor="let tool of tools">
+        <ion-label>
+          <h2>{{ tool.name }}</h2>
+          <p>{{ tool.description }}</p>
+        </ion-label>
+        <ion-button slot="end" [href]="tool.link">{{ tool.buttonText }}</ion-button>
+      </ion-item>
+    </ion-list>
+  </section>
+
+  <!-- 资源区 -->
+  <section>
+    <ion-list>
+      <ion-list-header>
+        <ion-label>相关文章和视频</ion-label>
+      </ion-list-header>
+      <ion-item *ngFor="let resource of resources">
+        <ion-label>
+          <h2>{{ resource.title }}</h2>
+        </ion-label>
+        <ion-button slot="end" [href]="resource.link">{{ resource.buttonText }}</ion-button>
+      </ion-item>
+    </ion-list>
+  </section>
+
+  <!-- 社区支持区 -->
+  <section>
+    <ion-list>
+      <ion-list-header>
+        <ion-label>社区讨论</ion-label>
+      </ion-list-header>
+      <ion-item *ngFor="let discussion of discussions">
+        <ion-label>
+          <h2>{{ discussion.title }}</h2>
+        </ion-label>
+        <ion-button slot="end" [href]="discussion.link">参与讨论</ion-button>
+      </ion-item>
+    </ion-list>
+  </section>
+</ion-content>

+ 34 - 0
.history/soul-app/src/app/topic-detail3/topic-detail3.component_20241216084841.scss

@@ -0,0 +1,34 @@
+/* 设置页面背景色 */
+ion-content {
+  --background: #ffffff; /* 白色背景 */
+}
+ion-title {
+  font-size: 24px; /* 增大字体大小 */
+  font-weight: bold; /* 加粗 */
+}
+/* 设置卡片的样式 */
+ion-list {
+  margin: 10px; /* 卡片之间的间距 */
+  border-radius: 10px; /* 圆角效果 */
+  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1); /* 阴影效果 */
+}
+
+/* 设置列表项的样式 */
+ion-item {
+  margin: 5px 0; /* 列表项之间的间距 */
+}
+
+/* 设置按钮的样式(如果按钮不在顶部方框内) */
+ion-button {
+  font-size: 15px; /* 增大字体大小 */
+  margin-top: 8px; /* 上间距,仅在需要时添加 */
+  text-transform: none; /* 按钮文字不变形 */
+  height: 35px;
+}
+.title-text{
+position: absolute;
+display: flex;
+left: 85px;
+margin: auto;
+top: 10px;
+}

+ 82 - 0
.history/soul-app/src/app/topic-detail3/topic-detail3.component_20241216084847.ts

@@ -0,0 +1,82 @@
+import { Component, OnInit } from '@angular/core';
+import { IonButton, IonContent, IonHeader, IonIcon, IonInput, IonItem, IonLabel, IonList, IonListHeader, 
+  IonSearchbar, IonTitle, IonToolbar } from '@ionic/angular/standalone';
+import { ExploreContainerComponent } from '../explore-container/explore-container.component';
+import { CommonModule } from '@angular/common';
+import { Router } from '@angular/router';
+
+@Component({
+  selector: 'app-topic-detail3',
+  templateUrl: './topic-detail3.component.html',
+  styleUrls: ['./topic-detail3.component.scss'],
+  standalone: true,
+  imports:[IonHeader,IonToolbar,IonTitle,IonContent,ExploreContainerComponent,
+    IonList,IonListHeader,IonLabel,IonItem,IonIcon,IonButton,
+    IonInput,IonSearchbar,
+    CommonModule
+  ],
+})
+export class TopicDetail3Component  implements OnInit {
+  tips = [
+    {
+      title: '设定小目标',
+      description: '通过设定并完成小目标来增强自信心。',
+      details: '每完成一个小目标,都会增强你的成就感。',
+      expanded: false,
+    },
+    {
+      title: '积极自我对话',
+      description: '通过积极的自我对话来改变消极思维。',
+      details: '用积极的语言鼓励自己,提升自我肯定感。',
+      expanded: false,
+    },
+    {
+      title: '练习身体语言',
+      description: '通过开放的身体语言来传达自信。',
+      details: '站直、微笑和保持眼神接触可以帮助你感到更自信。',
+      expanded: false,
+    },
+  ];
+
+  tools = [
+    {
+      name: '自信心提升APP',
+      description: '提供每日自信心练习和积极的提醒。',
+      link: 'https://www.liqucn.com/rj/9679961013722.shtml',
+      buttonText: '下载APP',
+    },
+    {
+      name: '在线视频',
+      description: '学习更多关于自信心提升的技巧。',
+      link: 'https://www.bilibili.com/video/BV1GQBsYfECG/',
+      buttonText: '查看视频',
+    },
+  ];
+
+  resources = [
+    {
+      title: '提升自信心的有效方法',
+      link: 'https://m.baidu.com/bh/m/detail/ar_4782723165528593464',
+      buttonText: '阅读更多',
+    },
+    {
+      title: '如何在公众面前自信演讲',
+      link: 'https://www.bilibili.com/video/BV1eH4y1f7d1/',
+      buttonText: '观看视频',
+    },
+  ];
+
+  discussions = [
+    {
+      title: '分享你的自信提升故事',
+      link: 'https://example.com/community',
+    },
+  ];
+
+  constructor(private router: Router) { }
+  goTab1(){
+    this.router.navigate(['tabs/tab1']);
+   }
+  ngOnInit() {}
+
+}

+ 15 - 0
soul-app/src/app/page-consult/page-consult.component.html

@@ -1,3 +1,18 @@
+<ion-header>
+  <ion-toolbar>
+    <div class="toolbar-content">
+      <div class="button-container">
+        <ion-button (click)="goTab1()" fill="clear">
+          <ion-icon name="chevron-back" slot="start"></ion-icon>返回
+        </ion-button>
+      </div>
+      <ion-title class="title-text">
+        心理咨询
+      </ion-title>
+    </div>
+  </ion-toolbar>
+</ion-header>
+
 <ion-content>
     <h1>类型</h1>
     <ion-input [value]="leixing" (ionInput)="leixingInput($event)"></ion-input>

+ 8 - 1
soul-app/src/app/page-consult/page-consult.component.scss

@@ -48,4 +48,11 @@ fm-markdown-preview {
 /* 可选:增加一些过渡效果 */
 ion-input, ion-textarea, ion-button, div.response-msg, fm-markdown-preview {
     transition: all 0.3s ease;
-}
+}
+.title-text{
+    position: absolute;
+    display: flex;
+    left: 65px;
+    margin: auto;
+    top: 10px;
+  }

+ 9 - 3
soul-app/src/app/page-consult/page-consult.component.ts

@@ -1,20 +1,23 @@
 import { Component, OnInit } from '@angular/core';
 import {IonHeader, IonToolbar, IonTitle, IonContent, IonButton,
-  IonTextarea,IonInput} from '@ionic/angular/standalone';
+  IonTextarea,IonInput,IonIcon} from '@ionic/angular/standalone';
   /** 引用:从fmode-ng库引用FmodeChatCompletion类 */
 import { FmodeChatCompletion,MarkdownPreviewModule } from 'fmode-ng';
+import { Router } from '@angular/router';
+
 @Component({
   selector: 'app-page-consult',
   templateUrl: './page-consult.component.html',
   styleUrls: ['./page-consult.component.scss'],
   standalone: true,
   imports: [IonHeader, IonToolbar, IonTitle, IonContent, IonButton,
-    IonTextarea,IonInput,
+    IonTextarea,IonInput,IonIcon,
     MarkdownPreviewModule
     ],
 })
+
 export class PageConsultComponent  implements OnInit {
-  constructor() {}
+  constructor(private router: Router) {}
   ngOnInit(): void {
   }
   // 用户输入提示词
@@ -54,4 +57,7 @@ export class PageConsultComponent  implements OnInit {
     })
   }
 
+goTab1(){
+ this.router.navigate(['tabs/tab1']);
+}
 }

+ 55 - 7
soul-app/src/app/tab3/tab3.page.html

@@ -7,11 +7,59 @@
 </ion-header>
 
 <ion-content [fullscreen]="true">
-  <ion-header collapse="condense">
-    <ion-toolbar>
-      <ion-title size="large">Tab 3</ion-title>
-    </ion-toolbar>
-  </ion-header>
+  <!-- 用户信息区域 -->
+  <div class="user-info">
+    <ion-avatar>
+      <img src="assets/avatar-default.png" alt="头像">
+    </ion-avatar>
+    <div class="user-details">
+      <h2>用户名</h2>
+      <p>ID: 12345678</p>
+    </div>
+  </div>
 
-  <app-explore-container name="Tab 3 page"></app-explore-container>
-</ion-content>
+  <!-- 功能列表 -->
+  <ion-list>
+    <!-- 个人信息设置 -->
+    <ion-item>
+      <ion-icon name="person-outline" slot="start"></ion-icon>
+      <ion-label>个人信息</ion-label>
+      <ion-icon name="chevron-forward-outline" slot="end"></ion-icon>
+    </ion-item>
+
+    <!-- 我的收藏 -->
+    <ion-item>
+      <ion-icon name="heart-outline" slot="start"></ion-icon>
+      <ion-label>我的收藏</ion-label>
+      <ion-icon name="chevron-forward-outline" slot="end"></ion-icon>
+    </ion-item>
+
+    <!-- 消息通知 -->
+    <ion-item>
+      <ion-icon name="notifications-outline" slot="start"></ion-icon>
+      <ion-label>消息通知</ion-label>
+      <ion-icon name="chevron-forward-outline" slot="end"></ion-icon>
+    </ion-item>
+
+    <!-- 系统设置 -->
+    <ion-item>
+      <ion-icon name="settings-outline" slot="start"></ion-icon>
+      <ion-label>系统设置</ion-label>
+      <ion-icon name="chevron-forward-outline" slot="end"></ion-icon>
+    </ion-item>
+
+    <!-- 关于我们 -->
+    <ion-item>
+      <ion-icon name="information-circle-outline" slot="start"></ion-icon>
+      <ion-label>关于我们</ion-label>
+      <ion-icon name="chevron-forward-outline" slot="end"></ion-icon>
+    </ion-item>
+  </ion-list>
+
+  <!-- 退出登录按钮 -->
+  <div class="logout-button">
+    <ion-button expand="block" color="danger">
+      退出登录
+    </ion-button>
+  </div>
+</ion-content>

+ 53 - 0
soul-app/src/app/tab3/tab3.page.scss

@@ -0,0 +1,53 @@
+.user-info {
+    padding: 20px;
+    display: flex;
+    align-items: center;
+    background: #ffffff;
+    margin-bottom: 10px;
+  
+    ion-avatar {
+      width: 80px;
+      height: 80px;
+      margin-right: 20px;
+    }
+  
+    .user-details {
+      h2 {
+        margin: 0;
+        font-size: 20px;
+        font-weight: bold;
+      }
+      p {
+        margin: 5px 0 0;
+        color: #666;
+        font-size: 14px;
+      }
+    }
+  }
+  
+  ion-list {
+    margin-bottom: 20px;
+    
+    ion-item {
+      --padding-start: 16px;
+      --padding-end: 16px;
+      
+      ion-icon[slot="start"] {
+        margin-right: 16px;
+        color: #666;
+      }
+      
+      ion-icon[slot="end"] {
+        color: #999;
+      }
+    }
+  }
+  
+  .logout-button {
+    padding: 0 20px;
+    margin-top: 30px;
+    
+    ion-button {
+      --border-radius: 4px;
+    }
+  }

+ 53 - 5
soul-app/src/app/tab3/tab3.page.ts

@@ -1,14 +1,62 @@
-import { Component } from '@angular/core';
-import { IonHeader, IonToolbar, IonTitle, IonContent } from '@ionic/angular/standalone';
+import { Component, CUSTOM_ELEMENTS_SCHEMA } from '@angular/core';
+import { 
+  IonHeader, 
+  IonToolbar, 
+  IonTitle, 
+  IonContent, 
+  IonList,
+  IonItem,
+  IonIcon,
+  IonLabel,
+  IonButton,
+  IonAvatar
+} from '@ionic/angular/standalone';
 import { ExploreContainerComponent } from '../explore-container/explore-container.component';
+import { addIcons } from 'ionicons';
+import { 
+  personOutline, 
+  heartOutline, 
+  notificationsOutline, 
+  settingsOutline, 
+  informationCircleOutline,
+  chevronForwardOutline 
+} from 'ionicons/icons';
 
 @Component({
   selector: 'app-tab3',
   templateUrl: 'tab3.page.html',
   styleUrls: ['tab3.page.scss'],
   standalone: true,
-  imports: [IonHeader, IonToolbar, IonTitle, IonContent, ExploreContainerComponent],
+  imports: [
+    IonHeader, 
+    IonToolbar, 
+    IonTitle, 
+    IonContent, 
+    IonList,
+    IonItem,
+    IonIcon,
+    IonLabel,
+    IonButton,
+    IonAvatar,
+    ExploreContainerComponent
+  ],
+  schemas: [CUSTOM_ELEMENTS_SCHEMA]
 })
 export class Tab3Page {
-  constructor() {}
-}
+  constructor() {
+    // 注册图标
+    addIcons({
+      personOutline, 
+      heartOutline, 
+      notificationsOutline, 
+      settingsOutline, 
+      informationCircleOutline,
+      chevronForwardOutline
+    });
+  }
+
+  // 退出登录方法
+  logout() {
+    console.log('退出登录');
+  }
+}

+ 1 - 1
soul-app/src/app/tabs/tabs.page.html

@@ -2,7 +2,7 @@
   <ion-tab-bar slot="bottom">
     <ion-tab-button tab="tab1" href="/tabs/tab1">
       <ion-icon aria-hidden="true" name="home"></ion-icon>
-      <ion-label>首页</ion-label>
+      <ion-label>社区</ion-label>
     </ion-tab-button>
 
     <ion-tab-button tab="tab2" href="/tabs/tab2">

+ 7 - 1
soul-app/src/app/tabs/tabs.page.scss

@@ -1 +1,7 @@
-
+.button-container {
+    position: absolute;
+    display: flex; /* 使用flexbox布局 */
+    padding: 0px 0px;
+    left: 0px;
+  }
+ 

+ 6 - 4
soul-app/src/app/tabs/tabs.page.ts

@@ -1,19 +1,21 @@
 import { Component, EnvironmentInjector, inject } from '@angular/core';
-import { IonTabs, IonTabBar, IonTabButton, IonIcon, IonLabel } from '@ionic/angular/standalone';
+import { IonTabs, IonTabBar, IonTabButton, IonTitle,IonIcon, IonLabel } from '@ionic/angular/standalone';
 import { addIcons } from 'ionicons';
-import { home, chatbubbles, person } from 'ionicons/icons';
+import { home, chatbubbles, person,chevronBack } from 'ionicons/icons';
+
 
 @Component({
   selector: 'app-tabs',
   templateUrl: 'tabs.page.html',
   styleUrls: ['tabs.page.scss'],
   standalone: true,
-  imports: [IonTabs, IonTabBar, IonTabButton, IonIcon, IonLabel],
+  imports: [IonTabs, IonTabBar, IonTabButton, IonIcon, IonLabel,IonTitle],
 })
 export class TabsPage {
   public environmentInjector = inject(EnvironmentInjector);
 
   constructor() {
-    addIcons({ home, chatbubbles, person });
+    addIcons({ home, chatbubbles, person ,chevronBack});
   }
+
 }

+ 10 - 1
soul-app/src/app/topic-detail/topic-detail.component.html

@@ -1,6 +1,15 @@
 <ion-header>
   <ion-toolbar>
-    <ion-title>管理焦虑情绪的指南</ion-title>
+    <div class="toolbar-content">
+      <div class="button-container">
+        <ion-button (click)="goTab1()" fill="clear">
+          <ion-icon name="chevron-back" slot="start"></ion-icon>返回
+        </ion-button>
+      </div>
+      <ion-title class="title-text">
+        管理焦虑情绪的指南
+      </ion-title>
+    </div>
   </ion-toolbar>
 </ion-header>
 

+ 26 - 16
soul-app/src/app/topic-detail/topic-detail.component.scss

@@ -1,28 +1,38 @@
 /* 设置页面背景色 */
 ion-content {
-    --background: #ffffff; /* 白色背景 */
+  --background: #ffffff; /* 白色背景 */
 }
 ion-title {
-    font-size: 24px; /* 增大字体大小 */
-    font-weight: bold; /* 加粗 */
+  font-size: 24px; /* 增大字体大小 */
+  font-weight: bold; /* 加粗 */
 }
 /* 设置卡片的样式 */
 ion-list {
-    margin: 10px; /* 卡片之间的间距 */
-    border-radius: 10px; /* 圆角效果 */
-    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1); /* 阴影效果 */
-  }
+  margin: 10px; /* 卡片之间的间距 */
+  border-radius: 10px; /* 圆角效果 */
+  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1); /* 阴影效果 */
+}
+ion-button {
+  font-size: 15px; /* 增大字体大小 */
+  margin-top: 8px; /* 上间距,仅在需要时添加 */
+  text-transform: none; /* 按钮文字不变形 */
+  height: 35px;
+}
 
 /* 设置列表项的样式 */
 ion-item {
-    margin: 5px 0; /* 列表项之间的间距 */
-  }
+  margin: 5px 0; /* 列表项之间的间距 */
+}
 
 /* 设置按钮的样式(如果按钮不在顶部方框内) */
-ion-button {
-    font-size: 15px; /* 增大字体大小 */
-    padding: 8px 16px; /* 内边距 */
-    margin-top: 8px; /* 上间距,仅在需要时添加 */
-    text-transform: none; /* 按钮文字不变形 */
-    height: 50px;
-}
+
+ion-toolbar {
+margin: auto;
+}
+.title-text{
+position: absolute;
+display: flex;
+left: 65px;
+margin: auto;
+top: 10px;
+}

+ 7 - 2
soul-app/src/app/topic-detail/topic-detail.component.ts

@@ -3,6 +3,7 @@ import { Component, OnInit } from '@angular/core';
 import { IonHeader,IonButton, IonContent, IonIcon, IonItem, IonLabel, IonList, 
   IonListHeader, IonTitle, IonToolbar,IonInput,IonSearchbar } from '@ionic/angular/standalone';
 import { ExploreContainerComponent } from '../explore-container/explore-container.component';
+import { Router } from '@angular/router';
 
 @Component({
   selector: 'app-topic-detail',
@@ -77,8 +78,12 @@ export class TopicDetailComponent  implements OnInit {
       link: 'https://example.com/community',
     },
   ];
-  constructor() { }
-
+  constructor(private router: Router) {
+    
+   }
+   goTab1(){
+    this.router.navigate(['tabs/tab1']);
+   }
   ngOnInit() {}
 
 }

+ 10 - 1
soul-app/src/app/topic-detail2/topic-detail2.component.html

@@ -1,6 +1,15 @@
 <ion-header>
   <ion-toolbar>
-    <ion-title>克服抑郁的有效方法</ion-title>
+    <div class="toolbar-content">
+      <div class="button-container">
+        <ion-button (click)="goTab1()" fill="clear">
+          <ion-icon name="chevron-back" slot="start"></ion-icon>返回
+        </ion-button>
+      </div>
+      <ion-title class="title-text">
+        克服抑郁的有效方法
+      </ion-title>
+    </div>
   </ion-toolbar>
 </ion-header>
 

+ 20 - 13
soul-app/src/app/topic-detail2/topic-detail2.component.scss

@@ -1,28 +1,35 @@
 /* 设置页面背景色 */
 ion-content {
-    --background: #ffffff; /* 白色背景 */
+  --background: #ffffff; /* 白色背景 */
 }
 
 /* 设置卡片的样式 */
 ion-list {
-    margin: 10px; /* 卡片之间的间距 */
-    border-radius: 10px; /* 圆角效果 */
-    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1); /* 阴影效果 */
-  }
+  margin: 10px; /* 卡片之间的间距 */
+  border-radius: 10px; /* 圆角效果 */
+  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1); /* 阴影效果 */
+}
 
 /* 设置列表项的样式 */
 ion-item {
-    margin: 5px 0; /* 列表项之间的间距 */
-  }
+  margin: 5px 0; /* 列表项之间的间距 */
+}
 
 /* 设置按钮的样式(如果按钮不在顶部方框内) */
 ion-button {
-    font-size: 15px; /* 增大字体大小 */
-    margin-top: 8px; /* 上间距,仅在需要时添加 */
-    text-transform: none; /* 按钮文字不变形 */
-    height: 35px;
+  font-size: 15px; /* 增大字体大小 */
+  margin-top: 8px; /* 上间距,仅在需要时添加 */
+  text-transform: none; /* 按钮文字不变形 */
+  height: 35px;
 }
 ion-title {
-  font-size: 24px; /* 增大字体大小 */
-  font-weight: bold; /* 加粗 */
+font-size: 24px; /* 增大字体大小 */
+font-weight: bold; /* 加粗 */
+}
+.title-text{
+position: absolute;
+display: flex;
+left: 65px;
+margin: auto;
+top: 10px;
 }

+ 5 - 2
soul-app/src/app/topic-detail2/topic-detail2.component.ts

@@ -3,6 +3,7 @@ import { Component, OnInit } from '@angular/core';
 import { IonButton, IonContent, IonHeader, IonIcon, IonInput, IonItem, IonLabel,
    IonList, IonListHeader, IonSearchbar, IonTitle, IonToolbar } from '@ionic/angular/standalone';
 import { ExploreContainerComponent } from '../explore-container/explore-container.component';
+import { Router } from '@angular/router';
 
 @Component({
   selector: 'app-topic-detail2',
@@ -70,8 +71,10 @@ export class TopicDetail2Component  implements OnInit {
       link: 'https://example.com/community',
     },
   ];
-  constructor() { }
-
+  constructor(private router: Router) { }
+  goTab1(){
+    this.router.navigate(['tabs/tab1']);
+   }
   ngOnInit() {}
 
 }

+ 10 - 1
soul-app/src/app/topic-detail3/topic-detail3.component.html

@@ -1,6 +1,15 @@
 <ion-header>
   <ion-toolbar>
-    <ion-title>提升自信心的技巧</ion-title>
+    <div class="toolbar-content">
+      <div class="button-container">
+        <ion-button (click)="goTab1()" fill="clear">
+          <ion-icon name="chevron-back" slot="start"></ion-icon>返回
+        </ion-button>
+      </div>
+      <ion-title class="title-text">
+        提升自信心的技巧
+      </ion-title>
+    </div>
   </ion-toolbar>
 </ion-header>
 

+ 20 - 14
soul-app/src/app/topic-detail3/topic-detail3.component.scss

@@ -1,28 +1,34 @@
 /* 设置页面背景色 */
 ion-content {
-    --background: #ffffff; /* 白色背景 */
+  --background: #ffffff; /* 白色背景 */
 }
 ion-title {
-    font-size: 24px; /* 增大字体大小 */
-    font-weight: bold; /* 加粗 */
+  font-size: 24px; /* 增大字体大小 */
+  font-weight: bold; /* 加粗 */
 }
 /* 设置卡片的样式 */
 ion-list {
-    margin: 10px; /* 卡片之间的间距 */
-    border-radius: 10px; /* 圆角效果 */
-    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1); /* 阴影效果 */
-  }
+  margin: 10px; /* 卡片之间的间距 */
+  border-radius: 10px; /* 圆角效果 */
+  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1); /* 阴影效果 */
+}
 
 /* 设置列表项的样式 */
 ion-item {
-    margin: 5px 0; /* 列表项之间的间距 */
-  }
+  margin: 5px 0; /* 列表项之间的间距 */
+}
 
 /* 设置按钮的样式(如果按钮不在顶部方框内) */
 ion-button {
-    font-size: 15px; /* 增大字体大小 */
-    padding: 8px 16px; /* 内边距 */
-    margin-top: 8px; /* 上间距,仅在需要时添加 */
-    text-transform: none; /* 按钮文字不变形 */
-    height: 50px;
+  font-size: 15px; /* 增大字体大小 */
+  margin-top: 8px; /* 上间距,仅在需要时添加 */
+  text-transform: none; /* 按钮文字不变形 */
+  height: 35px;
+}
+.title-text{
+position: absolute;
+display: flex;
+left: 85px;
+margin: auto;
+top: 10px;
 }

+ 5 - 2
soul-app/src/app/topic-detail3/topic-detail3.component.ts

@@ -3,6 +3,7 @@ import { IonButton, IonContent, IonHeader, IonIcon, IonInput, IonItem, IonLabel,
   IonSearchbar, IonTitle, IonToolbar } from '@ionic/angular/standalone';
 import { ExploreContainerComponent } from '../explore-container/explore-container.component';
 import { CommonModule } from '@angular/common';
+import { Router } from '@angular/router';
 
 @Component({
   selector: 'app-topic-detail3',
@@ -72,8 +73,10 @@ export class TopicDetail3Component  implements OnInit {
     },
   ];
 
-  constructor() { }
-
+  constructor(private router: Router) { }
+  goTab1(){
+    this.router.navigate(['tabs/tab1']);
+   }
   ngOnInit() {}
 
 }