tab2.page.html 2.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172
  1. <ion-header [translucent]="true">
  2. <ion-toolbar>
  3. <ion-item lines="none">
  4. <!-- 图片 -->
  5. <ion-avatar slot="start" class="image-container">
  6. <img src="/assets/img/3.png" alt="Your Image" class="header-image">
  7. </ion-avatar>
  8. <!-- 搜索框 -->
  9. <ion-searchbar slot="end" expand="with-icon"></ion-searchbar>
  10. </ion-item>
  11. </ion-toolbar>
  12. </ion-header>
  13. <ion-content>
  14. <!-- 智能陪聊区 -->
  15. <section>
  16. <ion-card>
  17. <ion-card-header>
  18. <ion-card-title>智能陪聊</ion-card-title>
  19. </ion-card-header>
  20. <ion-card-content>
  21. <p>以下是一些专业性的的智能心理陪聊师:</p>
  22. <ion-list>
  23. <ion-item *ngFor="let chatpartner of chatpartnerList">
  24. <ion-avatar slot="start">
  25. <img [src]="chatpartner.get('avatar') || '/assets/img/2.png'" [alt]="chatpartner.get('name')"/>
  26. </ion-avatar>
  27. <ion-label>
  28. <h2>{{ chatpartner.get('name') }}</h2>
  29. <p>专业领域:{{ chatpartner.get('expertise') }}</p>
  30. </ion-label>
  31. <ion-button slot="end" (click)="clickToConsult(chatpartner)">开始陪聊</ion-button>
  32. </ion-item>
  33. </ion-list>
  34. </ion-card-content>
  35. </ion-card>
  36. </section>
  37. <!-- 陪聊服务区 -->
  38. <section>
  39. <ion-card>
  40. <ion-card-header>
  41. <ion-card-title>普通聊天</ion-card-title>
  42. </ion-card-header>
  43. <ion-card-content>
  44. <p>在这里,无论是生活上的开心,还是工作上的糟糕,你都可以跟我分享,这里是属于你一个人的空间,你可以大胆放心的使用。</p>
  45. <ion-button expand="full" (click)="goChat()">开始聊天</ion-button>
  46. </ion-card-content>
  47. </ion-card>
  48. </section>
  49. <!--普通心理问题的小贴心建议建议区-->
  50. <section>
  51. <ion-card>
  52. <ion-card-header>
  53. <ion-card-title>小贴心建议</ion-card-title>
  54. </ion-card-header>
  55. <ion-card-content>
  56. <ion-list>
  57. <ion-item *ngFor="let question of questions" (click)="question.expanded = !question.expanded">
  58. <ion-label>
  59. <h2>{{ question.title }}</h2>
  60. <p *ngIf="question.expanded">{{ question.advice }}</p>
  61. </ion-label>
  62. <ion-icon name="chevron-down" slot="end" *ngIf="!question.expanded"></ion-icon>
  63. <ion-icon name="chevron-up" slot="end" *ngIf="question.expanded"></ion-icon>
  64. </ion-item>
  65. </ion-list>
  66. </ion-card-content>
  67. </ion-card>
  68. </section>
  69. </ion-content>