myStar.vue 21 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895
  1. <template>
  2. <view class="star-container">
  3. <PageHeader title="" class="PageHeader" v-if="state == 1">
  4. <template v-slot:center> </template>
  5. </PageHeader>
  6. <!-- 星灵基因重组仓弹窗 -->
  7. <view class="gender-popup" v-if="state == 0">
  8. <NicknamePopup :closeOnClickOverlay="false" title="星灵基因重组仓" subtitle="" class="openContentPopUpWindow"
  9. ref="openContentPopUpWindow" @close="goBack()">
  10. <template v-slot:content>
  11. <uv-textarea v-model="noteContent" maxlength="200" count autoHeight
  12. placeholder="可描述你想要重新赋予Ta的形象、性别、性格、身份、兴趣爱好等(不会展示给其他人,仅你自己知道),示例:有一头波浪状的橙色头发,喜欢运动的阳光男孩..."></uv-textarea>
  13. <view class="btn-box blick-btn-animation" @tap="confirmGender">创建星灵</view>
  14. </template>
  15. </NicknamePopup>
  16. </view>
  17. <!-- 加载动画区域 -->
  18. <view class="loading-area" v-if="state == 2 || isLoading">
  19. <image src="../../static/me/loadAnimation.gif" mode="widthFix"></image>
  20. </view>
  21. <!-- 角色展示页面 -->
  22. <view class="character-page" v-else-if="state == 1">
  23. <view class="character-container">
  24. <image :src="starInfo.image || ''" mode="widthFix" class="character-image">
  25. </image>
  26. </view>
  27. <view class="bottom-button" @tap="goToSetProfile"> 设置星灵简介 </view>
  28. </view>
  29. <!-- 表单页面 -->
  30. <view class="form-page" v-else-if="state == 4">
  31. <PageHeader title="设置星灵简介" class="PageHeader">
  32. <template v-slot:center> </template>
  33. </PageHeader>
  34. <view class="reserveASeat"></view>
  35. <form @submit="submitForm">
  36. <view class="form-group">
  37. <view class="label">
  38. <text class="required">*</text>
  39. <text>昵称</text>
  40. </view>
  41. <input class="input" v-model="formData.nickname" placeholder="给星灵取个名字"
  42. :class="{ error: showError && !formData.nickname }" />
  43. </view>
  44. <view class="form-group">
  45. <view class="label">性别</view>
  46. <view class="gender-options">
  47. <view class="gender-option" :class="sex == 'male' ? 'selected' : ''"
  48. @tap="selectGender('male')">
  49. <view class="gender-icon male">
  50. <image src="../../static/me/wd_icon_nan.png" mode="aspectFit"></image>
  51. 男性
  52. </view>
  53. </view>
  54. <view class="gender-option" :class="sex == 'female' ? 'selected' : ''"
  55. @tap="selectGender('female')">
  56. <view class="gender-icon female">
  57. <image src="../../static/me/wd_icon_nv.png" mode="aspectFit"></image>
  58. 女性
  59. </view>
  60. </view>
  61. <view class="gender-option" :class="sex == 'other' ? 'selected' : ''"
  62. @tap="selectGender('other')">
  63. <view class="gender-icon other">
  64. <image src="../../static/me/wd_icon_qita.png" mode="aspectFit"></image>
  65. 其它
  66. </view>
  67. </view>
  68. </view>
  69. </view>
  70. <view class="form-group">
  71. <view class="label">
  72. <text class="required">*</text>
  73. <text>人物简介</text>
  74. </view>
  75. <view class="textarea-container">
  76. <textarea class="textarea" v-model="formData.description"
  77. placeholder="填写这个角色的人物介绍,例如性格、身份、背景与历程..." :maxlength="500"
  78. :class="{ error: showError && !formData.description }" autoHeight />
  79. <text class="word-count">{{ formData.description.length }}/500</text>
  80. </view>
  81. </view>
  82. <view class="form-group">
  83. <view class="label">人物标签</view>
  84. <!-- <scroll-view class="tags-scroll" scroll-x="true" show-scrollbar="false">
  85. <view class="tags-container">
  86. <view class="tag" v-for="tag in predefinedTags" :key="tag">
  87. {{ tag }}
  88. </view>
  89. </view>
  90. </scroll-view> -->
  91. <view class="tags-container">
  92. <!-- <view class="tag" :class="{ active: tagSet.has(tag) }" v-for="tag in predefinedTags" :key="tag"
  93. @tap="switchTag(tag)">
  94. {{ tag }}
  95. </view> -->
  96. <uni-data-checkbox mode="tag" multiple v-model="selectTags"
  97. :localdata="predefinedTags"></uni-data-checkbox>
  98. </view>
  99. </view>
  100. </form>
  101. <view class="submit-button" @tap="submitStar"> 确定并提交 </view>
  102. </view>
  103. <!-- 角色信息展示页面 -->
  104. <view class="character-info" v-else-if="state == 5 || state == 6">
  105. <view class="custom-navbar">
  106. <view class="navbar-left" @click="goBack">
  107. <text class="fa fa-angle-left" style="color: #000;"></text>
  108. </view>
  109. <view class="navbar-right" @click="showShare = true">
  110. <text class="fa fa-ellipsis-h"></text>
  111. </view>
  112. </view>
  113. <view class="info-container">
  114. <!-- 角色立绘区域 -->
  115. <view class="character-portrait">
  116. <image :src="starInfo.image" mode="widthFix" class="portrait-image"></image>
  117. </view>
  118. <!-- 角色信息板块 -->
  119. <view class="info-section">
  120. <view class="character-name">
  121. <uv-input v-if="state == 5" v-model="starInfo.nickname" placeholder="请输入昵称" border="none" />
  122. <text v-else>{{ starInfo.nickname }}</text>
  123. <image class="male" v-if="starInfo.sex_id == 1" src="../../static/me/wd_icon_nan.png"
  124. mode="aspectFit">
  125. </image>
  126. <image class="female" v-else-if="starInfo.sex_id == 2" src="../../static/me/wd_icon_nv.png"
  127. mode="aspectFit">
  128. </image>
  129. <image class="other" v-else-if="starInfo.sex_id == 3" src="../../static/me/wd_icon_qita.png"
  130. mode="aspectFit"></image>
  131. </view>
  132. <!-- 人物简介 -->
  133. <view class="description-box">
  134. <view class="description-title">
  135. <view>Ta的设定</view>
  136. <view v-if="state == 5" class="edit-button" @click="showEditPopup">
  137. 编辑<text class="fa fa-angle-right" style="color: #000;"></text>
  138. </view>
  139. </view>
  140. <view class="description-text">
  141. <text>{{ starInfo.content }}</text>
  142. </view>
  143. </view>
  144. <!-- 标签展示 -->
  145. <view class="description-box">
  146. <view class="description-title">
  147. <view>人物标签</view>
  148. </view>
  149. <view class="tags-box">
  150. <view class="tag-item" v-for="tag in starInfo.tags" :key="tag">
  151. {{ tag }}
  152. </view>
  153. </view>
  154. </view>
  155. </view>
  156. </view>
  157. <!-- 底部按钮 -->
  158. <view class="join-button blick-btn-animation" @tap="handleJoin(1)" v-if="state == 5"> 入驻星球 </view>
  159. <view class="join-button blick-btn-animation" @tap="handleJoin(0)" v-if="state == 6"> 已入驻星球(点击进入星球) </view>
  160. </view>
  161. <!-- 编辑弹窗 -->
  162. <uni-popup ref="editPopup" type="center">
  163. <view class="edit-popup">
  164. <view class="popup-title">修改设定</view>
  165. <view class="popup-content">
  166. <uv-textarea v-model="editContent" :maxlength="500" count autoHeight placeholder="输入Ta的设定"
  167. class="edit-textarea" />
  168. </view>
  169. <view class="popup-buttons">
  170. <view class="cancel-btn" @click="closeEditPopup">再考虑一下</view>
  171. <view class="confirm-btn" @click="saveEdit">确认添加</view>
  172. </view>
  173. </view>
  174. </uni-popup>
  175. <SharePopup :visible="showShare" :userId="userId" :share-title="shareTitle" :share-desc="shareDesc"
  176. :share-img="shareImg" view="makeDetail" @close="showShare = false" />
  177. </view>
  178. </template>
  179. <script>
  180. import tabbarView from "@/components/tabbar/tabbar.vue";
  181. import value from '../../uni_modules/uv-text/components/uv-text/value';
  182. import {
  183. mapMutations
  184. } from 'vuex'
  185. export default {
  186. components: {
  187. tabbarView,
  188. },
  189. data() {
  190. return {
  191. isLoading: false,
  192. selectedGender: null,
  193. tempGender: null,
  194. tabbars: [],
  195. ballColors: [
  196. "#FF6B6B", // 红色
  197. "#4ECDC4", // 青色
  198. "#45B7D1", // 蓝色
  199. "#96CEB4", // 绿色
  200. "#FFEEAD", // 黄色
  201. "#D4A5A5", // 粉色
  202. "#9A8194", // 紫色
  203. "#FF9F1C", // 橙色
  204. ],
  205. showError: false,
  206. formData: {
  207. nickname: "",
  208. sex: "其他",
  209. description: "",
  210. tags: [],
  211. },
  212. predefinedTags: [],
  213. showInfo: false,
  214. starImg: "",
  215. noteContent: "",
  216. starInfo: {},
  217. state: 2, //0 是用户输入星灵基因重组仓的状态 1 是用户已经完成了匹星灵展示页面 2是用户匹配中加载的状态 3是匹配到了待点击进入设置界面 (根据其它字段判断是否失败) 4是用户设置星灵信息的页面 5是用户查看星灵信息的页面 待入驻 6是用户已经已经入驻星球了
  218. sex: "",
  219. selectTags: [],
  220. info: {
  221. "id": 0,
  222. "sso_id": 0,
  223. "image_id": 0,
  224. "image": "",
  225. "nickname": "",
  226. "user_content": "",
  227. "content": "",
  228. "sex_id": 0,
  229. "tags": "",
  230. "status": 0
  231. },
  232. timeoutId: 0,
  233. showShare: false,
  234. shareTitle: "分享标题",
  235. shareDesc: "",
  236. shareImg: "",
  237. userId: 0,
  238. maxRetries: 10, // 最大重试次数
  239. retryCount: 0, // 当前重试次数
  240. pollingInterval: 30000, // 轮询间隔时间(毫秒)
  241. editContent: '',
  242. };
  243. },
  244. onLoad() {
  245. this.aIpipeiGetinfo("get");
  246. this.loadInfo()
  247. },
  248. methods: {
  249. ...mapMutations('switchingModule', ['setInformation', 'deleteInformation']),
  250. // 返回上一页
  251. goBack() {
  252. console.log(66);
  253. uni.navigateBack({
  254. delta: 1
  255. });
  256. },
  257. confirmGender() {
  258. // if (!this.noteContent) {
  259. // uni.showToast({
  260. // title: "请输入匹配条件",
  261. // icon: "none",
  262. // });
  263. // return;
  264. // }
  265. // this.selectedGender = this.noteContent;
  266. this.isLoading = true;
  267. this.closeContentPopUpWindow();
  268. this.state = 2
  269. this.apiPeiStar();
  270. },
  271. goToSetProfile() {
  272. this.state = 4;
  273. this.formData.nickname = ''
  274. this.formData.sex = ''
  275. this.formData.tags = ''
  276. },
  277. toggleTag(tag) {
  278. const index = this.formData.tags.indexOf(tag);
  279. if (index > -1) {
  280. this.formData.tags.splice(index, 1);
  281. } else {
  282. this.formData.tags.push(tag);
  283. }
  284. },
  285. handleJoin(type) {
  286. if (type === 1) {
  287. // 保存修改后的信息到服务器
  288. uni.request({
  289. url: this.$apiHost + "/AIpipei/gogogo",
  290. data: {
  291. uuid: getApp().globalData.uuid,
  292. nickname: this.starInfo.nickname,
  293. content: this.starInfo.content,
  294. },
  295. header: {
  296. "content-type": "application/x-www-form-urlencoded",
  297. sign: getApp().globalData.headerSign,
  298. },
  299. method: "POST",
  300. success: (res) => {
  301. console.log("res.data", res.data);
  302. uni.showToast({
  303. title: res.data.str,
  304. icon: "none",
  305. duration: 2000,
  306. });
  307. if (res.data.success === "yes") {
  308. this.aIpipeiGetinfo({
  309. polling: false
  310. });
  311. }
  312. }
  313. });
  314. } else {
  315. // 已入驻状态,直接跳转
  316. uni.navigateTo({
  317. url: '/pages/isLand/homeLand'
  318. });
  319. }
  320. },
  321. // 提交用户 开始创建的命令
  322. apiPeiStar() {
  323. uni.request({
  324. url: this.$apiHost + "/AIpipei/start",
  325. data: {
  326. uuid: getApp().globalData.uuid,
  327. content: this.noteContent,
  328. },
  329. header: {
  330. "content-type": "application/x-www-form-urlencoded",
  331. sign: getApp().globalData.headerSign,
  332. },
  333. // 设置60秒超时
  334. timeout: 60000,
  335. method: 'POST',
  336. success: (res) => {
  337. setTimeout(() => {
  338. if (res.data.str != "开始匹配") {
  339. uni.showToast({
  340. title: res.data.str,
  341. icon: "none",
  342. duration: 2000,
  343. });
  344. }
  345. if (res.data.success == "no") {
  346. setTimeout(() => {
  347. this.state = 0
  348. this.isLoading = false;
  349. this.aIpipeiGetinfo("get");
  350. this.loadInfo()
  351. }, 2000);
  352. // this.apiPeiStar();
  353. }
  354. if (res.data.str == "开始匹配") {
  355. this.aIpipeiGetinfo({
  356. polling: true
  357. })
  358. }
  359. }, 3000);
  360. },
  361. fail: (err) => {
  362. console.error("请求失败:", err);
  363. // 显示错误提示
  364. uni.showToast({
  365. title: "网络请求失败,请重试",
  366. icon: "none",
  367. duration: 2000,
  368. });
  369. // 重置加载状态
  370. },
  371. complete: () => {
  372. },
  373. });
  374. },
  375. loadInfo() {
  376. console.log({
  377. uuid: getApp().globalData.uuid,
  378. skey: getApp().globalData.skey,
  379. });
  380. uni.request({
  381. url: this.$apiHost + "/User/getinfo",
  382. data: {
  383. uuid: getApp().globalData.uuid,
  384. skey: getApp().globalData.skey,
  385. },
  386. header: {
  387. "content-type": "application/json",
  388. sign: getApp().globalData.headerSign,
  389. },
  390. success: (res) => {
  391. console.log("----:", JSON.parse(JSON.stringify(res.data)));
  392. if (res.data) {
  393. this.userId = res.data.user_id
  394. }
  395. },
  396. complete: (com) => {
  397. // uni.hideLoading();
  398. },
  399. fail: (e) => {
  400. console.log("----e:", e);
  401. },
  402. });
  403. },
  404. // 查询Ai匹配信息
  405. aIpipeiGetinfo({
  406. polling
  407. }) {
  408. // 清除之前的定时器
  409. if (this.timeoutId) {
  410. clearTimeout(this.timeoutId);
  411. this.timeoutId = 0;
  412. }
  413. // 检查是否超过最大重试次数
  414. if (polling && this.retryCount >= this.maxRetries) {
  415. uni.showToast({
  416. title: '匹配超时,请重新尝试',
  417. icon: 'none',
  418. duration: 2000
  419. });
  420. this.retryCount = 0;
  421. this.state = 0;
  422. return;
  423. }
  424. // 发起请求
  425. uni.request({
  426. url: this.$apiHost + "/AIpipei/getinfo",
  427. data: {
  428. uuid: getApp().globalData.uuid,
  429. },
  430. header: {
  431. "content-type": "application/json",
  432. sign: getApp().globalData.headerSign,
  433. },
  434. timeout: 60000,
  435. success: (res) => {
  436. console.log("查询到生成信息", res.data);
  437. // 重置重试计数
  438. this.retryCount = 0;
  439. if (res && res.data && res.data.info) {
  440. if (res.data.info.content) {
  441. res.data.info.content = res.data.info.content.replace(/^\n+/, '')
  442. console.log(res.data.info.content);
  443. }
  444. if (res.data.info && res.data.info.tags != "") {
  445. res.data.info.tags = res.data.info.tags.split(",");
  446. this.predefinedTags = res.data.info.tags.map(tag => {
  447. return {
  448. text: tag,
  449. value: tag
  450. }
  451. })
  452. console.log(666, res);
  453. this.setInformation(res.data.info)
  454. this.shareTitle = res.data.info.nickname
  455. this.shareDesc = res.data.info.content
  456. this.shareImg = res.data.info.image
  457. // this.userId = res.data.user_id
  458. } else {
  459. res.data.info.tags = []
  460. this.deleteInformation()
  461. }
  462. // 实现状态的判断
  463. // 更改状态为 用户还未匹配过 待输入匹配内容
  464. if (res.data.str == "没有匹配过" && res.data.info) {
  465. this.state = 0
  466. setTimeout(() => {
  467. this.openContentPopUpWindow();
  468. }, 300);
  469. }
  470. if (res.data.success == "no") {
  471. uni.showToast({
  472. title: res.data.str,
  473. icon: "none",
  474. duration: 2000,
  475. });
  476. setTimeout(() => {
  477. this.state = 0
  478. setTimeout(() => {
  479. this.openContentPopUpWindow();
  480. }, 300);
  481. }, 2000);
  482. }
  483. // 更改状态为 用户还匹配成功时 待点击设置心灵简介
  484. if (res.data.info.image && res.data.info.status == 2) {
  485. this.state = 1
  486. this.isLoading = false
  487. // this.openContentPopUpWindow();
  488. }
  489. if (res.data.info.image && res.data.info.status == 1) {
  490. this.state = 6
  491. this.isLoading = false
  492. }
  493. if (res.data.info.image && res.data.info.status == 3) {
  494. this.state = 5
  495. this.isLoading = false
  496. }
  497. this.starInfo = res.data.info;
  498. if (res.data.info.content) {
  499. this.formData.description = res.data.info.content;
  500. }
  501. }
  502. },
  503. fail: (err) => {
  504. console.error("请求失败:", err);
  505. // 增加重试计数
  506. this.retryCount++;
  507. // 显示错误提示
  508. uni.showToast({
  509. title: `网络请求失败,第${this.retryCount}次重试`,
  510. icon: "none",
  511. duration: 2000,
  512. });
  513. // 如果是网络超时,自动重试
  514. if (err.errMsg.includes("timeout")) {
  515. setTimeout(() => {
  516. console.log("请求超时,正在重试...");
  517. this.aIpipeiGetinfo({
  518. polling: true
  519. });
  520. }, 6000);
  521. }
  522. },
  523. complete: () => {
  524. // 如果需要继续轮询,设置下一次请求
  525. if (polling) {
  526. this.timeoutId = setTimeout(() => {
  527. this.aIpipeiGetinfo({
  528. polling: true
  529. });
  530. }, this.pollingInterval);
  531. }
  532. }
  533. });
  534. },
  535. // 保存表单信息
  536. submitStar() {
  537. this.formData.tags = this.selectTags.join(",");
  538. let that = this;
  539. uni.showLoading({
  540. mask: true,
  541. });
  542. if (this.formData.sex) {
  543. this.formData.sex = this.genderScreeningId(this.formData.sex);
  544. }
  545. console.log({
  546. uuid: getApp().globalData.uuid,
  547. sex: this.formData.sex,
  548. name: this.formData.nickname,
  549. content: this.formData.description,
  550. tags: this.formData.tags,
  551. }, 2000);
  552. uni.request({
  553. url: this.$apiHost + "/AIpipei/save",
  554. data: {
  555. uuid: getApp().globalData.uuid,
  556. sex: this.formData.sex,
  557. nickname: this.formData.nickname,
  558. content: this.formData.description,
  559. tags: this.formData.tags,
  560. },
  561. header: {
  562. "content-type": "application/x-www-form-urlencoded",
  563. sign: getApp().globalData.headerSign,
  564. },
  565. method: 'POST',
  566. // 设置60秒超时
  567. timeout: 10000,
  568. success: (res) => {
  569. console.log("res.data", res.data);
  570. uni.showToast({
  571. title: res.data.str,
  572. icon: "none",
  573. duration: 2000,
  574. });
  575. if (res.data.success === "yes") {
  576. setTimeout(() => {
  577. that.aIpipeiGetinfo({
  578. polling: false
  579. });
  580. }, 300);
  581. }
  582. },
  583. fail: (err) => {
  584. console.error("请求失败:", err);
  585. // 显示错误提示
  586. uni.showToast({
  587. title: "网络请求失败,请重试",
  588. icon: "none",
  589. duration: 2000,
  590. });
  591. },
  592. complete: () => {
  593. uni.hideLoading();
  594. },
  595. });
  596. },
  597. selectGender(option) {
  598. this.formData.sex = option;
  599. this.sex = option;
  600. },
  601. openContentPopUpWindow() {
  602. if (this.$refs.openContentPopUpWindow) {
  603. console.log(9999, "打开");
  604. this.$refs.openContentPopUpWindow.open();
  605. }
  606. },
  607. closeContentPopUpWindow() {
  608. if (this.$refs.openContentPopUpWindow) {
  609. this.$refs.openContentPopUpWindow.close();
  610. }
  611. },
  612. genderScreening(str) {
  613. switch (str) {
  614. case '0':
  615. return '男'
  616. case '1':
  617. return '女'
  618. case '2':
  619. return '其它'
  620. }
  621. },
  622. genderScreeningId(str) {
  623. switch (str) {
  624. case 'male':
  625. return 0
  626. case 'female':
  627. return 1
  628. case 'other':
  629. return 2
  630. }
  631. },
  632. // 显示编辑弹窗
  633. showEditPopup() {
  634. this.editContent = this.starInfo.content;
  635. this.$refs.editPopup.open();
  636. },
  637. // 关闭编辑弹窗
  638. closeEditPopup() {
  639. this.$refs.editPopup.close();
  640. },
  641. // 保存编辑内容
  642. saveEdit() {
  643. this.starInfo.content = this.editContent;
  644. this.closeEditPopup();
  645. },
  646. },
  647. };
  648. </script>
  649. <style lang="scss">
  650. @import "./myStar.scss";
  651. .openContentPopUpWindow {
  652. ::v-deep.uv-textarea {
  653. width: 694rpx !important;
  654. border-radius: 20rpx !important;
  655. border: 1rpx solid #000000 !important;
  656. margin: 0 auto;
  657. margin-bottom: 44rpx;
  658. min-height: 300rpx;
  659. padding-bottom: 40rpx;
  660. .uv-textarea__field {
  661. min-height: 200rpx !important;
  662. font-weight: 400;
  663. font-size: 28rpx;
  664. color: #1f1f1f;
  665. }
  666. }
  667. }
  668. .textarea-container {
  669. .textarea {
  670. background: #f2f6f2 !important;
  671. min-height: 100rpx;
  672. }
  673. }
  674. .tags-container {
  675. ::v-deep.checklist-box {
  676. border-radius: 16rpx !important;
  677. border: 2rpx solid #1f1f1f !important;
  678. background-color: #fff !important;
  679. display: flex;
  680. align-items: center;
  681. justify-content: center;
  682. .checklist-text {
  683. font-size: 28rpx;
  684. color: #1f1f1f;
  685. font-family: "PingFang SC-Bold" !important;
  686. }
  687. &.is-checked {
  688. background: #f7ffea !important;
  689. border-color: #7ebc00 !important;
  690. .checklist-text {
  691. color: #1f1f1f !important;
  692. }
  693. }
  694. }
  695. }
  696. .star-container {
  697. /* 自定义导航栏样式 */
  698. .custom-navbar {
  699. display: flex;
  700. flex-direction: row;
  701. align-items: center;
  702. justify-content: space-between;
  703. width: 100%;
  704. height: calc(90rpx + var(--status-bar-height));
  705. padding: 0 20rpx;
  706. padding-top: var(--status-bar-height);
  707. background-color: transparent;
  708. position: fixed;
  709. top: 0;
  710. left: 0;
  711. z-index: 100;
  712. background: transparent;
  713. &::before {
  714. content: '';
  715. position: absolute;
  716. top: 0;
  717. left: 0;
  718. width: 100%;
  719. height: var(--status-bar-height);
  720. background-color: #fff;
  721. z-index: -1;
  722. }
  723. .navbar-left {
  724. width: 80rpx;
  725. height: 80rpx;
  726. display: flex;
  727. align-items: center;
  728. justify-content: center;
  729. .fa-angle-left {
  730. font-size: 48rpx;
  731. color: #333;
  732. }
  733. }
  734. .navbar-right {
  735. width: 80rpx;
  736. height: 80rpx;
  737. display: flex;
  738. justify-content: center;
  739. align-items: center;
  740. .fa-ellipsis-h {
  741. font-size: 36rpx;
  742. color: #333;
  743. }
  744. }
  745. }
  746. }
  747. .edit-popup {
  748. width: 600rpx;
  749. background: #fff;
  750. border-radius: 24rpx;
  751. padding: 40rpx 32rpx;
  752. .popup-title {
  753. font-size: 32rpx;
  754. font-weight: bold;
  755. text-align: center;
  756. margin-bottom: 32rpx;
  757. color: #000;
  758. }
  759. .popup-content {
  760. margin-bottom: 32rpx;
  761. .edit-textarea {
  762. background: #F7F7F7;
  763. border-radius: 16rpx;
  764. padding: 24rpx;
  765. min-height: 160rpx;
  766. ::v-deep .uv-textarea__field {
  767. font-size: 28rpx;
  768. color: #333;
  769. }
  770. }
  771. }
  772. .popup-buttons {
  773. display: flex;
  774. justify-content: space-between;
  775. gap: 24rpx;
  776. .cancel-btn,
  777. .confirm-btn {
  778. flex: 1;
  779. height: 88rpx;
  780. line-height: 88rpx;
  781. text-align: center;
  782. border-radius: 44rpx;
  783. font-size: 32rpx;
  784. font-weight: 500;
  785. }
  786. .cancel-btn {
  787. background: #fff;
  788. color: #333;
  789. border: 2rpx solid #E5E5E5;
  790. }
  791. .confirm-btn {
  792. background: #000;
  793. color: #fff;
  794. }
  795. }
  796. }
  797. .description-title {
  798. display: flex;
  799. justify-content: space-between;
  800. align-items: center;
  801. .edit-button {
  802. color: #7ebc00;
  803. font-size: 28rpx;
  804. display: flex;
  805. align-items: center;
  806. .fa-angle-right {
  807. margin-left: 10rpx;
  808. }
  809. }
  810. }
  811. </style>