editInfo.vue 19 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741
  1. <template>
  2. <view class="page">
  3. <PageHeader title="" class="PageHeader">
  4. <template slot="center">
  5. 基本资料
  6. </template>
  7. </PageHeader>
  8. <view class="reserveASeat"></view>
  9. <!-- <view style="height: 90rpx;"></view> -->
  10. <view class="list_info">
  11. <view class="bcenter">
  12. <view class="avator" @click="chooseAvatar">
  13. <!-- <image class="img" :src="avator" mode="aspectFill" /> -->
  14. <CircleAvatar class="avator" :src="avator" style="width: 200rpx; height: 200rpx;"></CircleAvatar>
  15. <image class="photo" src="../../static/me/photo.png" mode="widthFix" />
  16. </view>
  17. </view>
  18. <view class="section_title">基本信息</view>
  19. <view class="info_card">
  20. <view class="info_item" @click="openNicknamePopUpWindow">
  21. <text class="label">昵称</text>
  22. <view class="content">
  23. <text v-if="nickname" class="textContent">{{ nickname }}</text>
  24. <text v-else class="textPrompt">请输入昵称</text>
  25. <image class="arrow" src="../../static/me/arrow_right_gray.png" mode="widthFix" />
  26. </view>
  27. </view>
  28. <view class="info_item" @click="SetSex">
  29. <text class="label">性别</text>
  30. <view class="content">
  31. <input type="text" placeholder="选择你的性别" v-model="sexText" disabled="true" />
  32. <image class="arrow" src="../../static/me/arrow_right_gray.png" mode="widthFix" />
  33. </view>
  34. </view>
  35. <view class="info_item">
  36. <text class="label">生日</text>
  37. <view class="content">
  38. <picker mode="date" :value="birthday" :end="endDate" @change="onBirthdayChange">
  39. <input type="text" placeholder="选择你的生日" v-model="birthday" disabled="true" />
  40. </picker>
  41. <image class="arrow" src="../../static/me/arrow_right_gray.png" mode="widthFix" />
  42. </view>
  43. </view>
  44. <view class="info_item">
  45. <text class="label">星座</text>
  46. <view class="content">
  47. <input type="text" placeholder="根据你的生日自动匹配" :value="xinzuo_sel" disabled="true"
  48. style="padding-right: 43rpx;" />
  49. <!-- <image class="arrow" src="../../static/me/arrow_right_gray.png" mode="widthFix" /> -->
  50. </view>
  51. </view>
  52. <view class="info_item" @click="openContentPopUpWindow">
  53. <text class="label">简介</text>
  54. <view class="content">
  55. <!-- <input type="text" placeholder="做个自我介绍吧~" v-model="content" maxlength="32" /> -->
  56. <text v-if="content" class="textContent one-omit">{{ content }}</text>
  57. <text v-else class="textPrompt">做个自我介绍吧</text>
  58. <image class="arrow" src="../../static/me/arrow_right_gray.png" mode="widthFix" />
  59. </view>
  60. </view>
  61. </view>
  62. <view class="section_title">个性标签</view>
  63. <view class="info_card">
  64. <view class="item_tag">
  65. <view class="tag" v-for="(item, index) in sel_tags" :key="index">
  66. {{ item }}
  67. <image class="close" src="../../static/me/close.png" mode="widthFix" @click="delTag(item)" />
  68. </view>
  69. <view class="addNew" @click="showPop = true;">+ 添加</view>
  70. </view>
  71. </view>
  72. <view class="blankHeight"></view>
  73. </view>
  74. <view class="btn_submit" @click="submitData(true)">保存</view>
  75. <DialogBox ref="DialogBox"></DialogBox>
  76. <view class="popSel" v-if="showPop" @tap.stop="onPreview">
  77. <PageHeader title="添加标签" @back="showPop = false" :isBack="false" style="background: #f2f6f2;" />
  78. <view class="reserveASeat"></view>
  79. <view class="headLabel">
  80. <view class="avator-box">
  81. <CircleAvatar class="avator" :src="avator"></CircleAvatar>
  82. <view class="one-omit">{{ nickname }}</view>
  83. </view>
  84. <view class="tag-box">
  85. <view class="tag" v-for="(item, index) in sel_tags" :key="index">
  86. {{ item }}
  87. <image class="close" src="../../static/me/close.png" mode="widthFix" @click="delTag(item)" />
  88. </view>
  89. </view>
  90. </view>
  91. <view class="list_info">
  92. <view class="name">你的兴趣爱好是?</view>
  93. <view class="desc">提示:最多选择5个兴趣爱好标签</view>
  94. <view style="height: 700rpx; overflow-y: scroll; margin-top: 20rpx; padding-bottom: 100rpx;">
  95. <view class="add-tag-box" style="color: #000;" v-if="showAddTag">
  96. <input
  97. class="add-tag-input"
  98. v-model="newTag"
  99. placeholder="请输入标签名称"
  100. maxlength="10"
  101. @confirm="addCustomTag"
  102. />
  103. <view class="add-tag-btns">
  104. <text class="cancel-btn" @tap="cancelAddTag">取消</text>
  105. <text class="confirm-btn" @tap="addCustomTag">确定</text>
  106. </view>
  107. </view>
  108. <view class="item_tag">
  109. <view class="tag add-tag" @tap="showAddTagInput">
  110. <text>+ 自定义</text>
  111. </view>
  112. <view @tap.stop="chkTag(item)" class="tag" :class="selTags(item) ? 'active' : ''"
  113. v-for="(item, index) in list_tag" :key="index">
  114. {{ item }}
  115. </view>
  116. </view>
  117. </view>
  118. </view>
  119. <view class="btn_submit" @click="showPop = false;">提交选择</view>
  120. </view>
  121. <ToastW3 ref="ToastW3"></ToastW3>
  122. <!-- <view v-if="showRights"
  123. style="width:100%;height:300rpx;background-color: rgba(255,255,255,0.9);position: fixed;top:0;display: flex;flex-direction: column;justify-content: center;align-items: center;">
  124. <text
  125. style="width:90%;color:#000000;font-size:38rpx;text-align: left;padding:10rpx 20rpx;padding-top:10rpx;">正在获取相机、存储权限</text>
  126. <text
  127. style="width:90%;color:#666666;font-size:28rpx;text-align: left;padding:10rpx 20rpx;">该权限用于获取设备拍摄或获取本地应用相册,进行头像或图片上传。</text>
  128. </view> -->
  129. <view>
  130. <NicknamePopup title="编辑昵称" subtitle="" class="openNicknamePopUpWindow" ref="openNicknamePopUpWindow">
  131. <template slot="content">
  132. <view class="input-box">
  133. <uv-input placeholder="请输入昵称" border="surround" v-model="nickname" maxlength="20"></uv-input>
  134. <view class="length-indicator">{{ nickname.length }}/20</view>
  135. </view>
  136. <view class="btn-box" @click="submitData">保存</view>
  137. </template>
  138. </NicknamePopup>
  139. <NicknamePopup title="专属于你的简介" subtitle="好的简介让你在社区更受关注" class="openContentPopUpWindow"
  140. ref="openContentPopUpWindow">
  141. <template slot="content">
  142. <uv-textarea v-model="content" maxlength="50" count placeholder="请输入内容"></uv-textarea>
  143. <view class="btn-box" @click="submitData">保存</view>
  144. </template>
  145. </NicknamePopup>
  146. </view>
  147. </view>
  148. </template>
  149. <script>
  150. import {
  151. requestAndroidPermission,
  152. gotoAppPermissionSetting
  153. } from '../index/permission.js'
  154. import PageHeader from '@/components/PageHeader/PageHeader.vue';
  155. import CircleAvatar from '@/components/CircleAvatar/CircleAvatar.vue';
  156. import NicknamePopup from '@/components/NicknamePopup/NicknamePopup.vue';
  157. import permission from '@/common/permission.js';
  158. export default {
  159. components: {
  160. PageHeader,
  161. CircleAvatar,
  162. NicknamePopup
  163. },
  164. data() {
  165. return {
  166. showRights: false,
  167. title: '',
  168. sel: 1,
  169. info: {},
  170. showPop: false,
  171. nickname: '',
  172. content: '',
  173. sex: 1,
  174. age: 18,
  175. height: 160,
  176. weight: 50,
  177. avator: '../../static/me/avator.png',
  178. ziye: '',
  179. qianmin: '',
  180. xinzuo_sel: '',
  181. xinzuo: ['水瓶座', '双鱼座', '白羊座', '金牛座', '双子座', '巨蟹座', '狮子座', '处女座', '天秤座', '天蝎座', '射手座', '摩羯座'],
  182. list_tag: [],
  183. sel_tags: [],
  184. sexText: '',
  185. birthday: '',
  186. sexOptions: ['男', '女', '其他'],
  187. endDate: new Date().toISOString().split('T')[0],
  188. showAddTag: false,
  189. newTag: '',
  190. }
  191. },
  192. onLoad() {
  193. let tagStr =
  194. "老二次元了、coser、沉迷音乐、网游小达人、AJ控、白日梦想家、撸铁狂魔、古风汉服、爱画画、数码极客、盲盒玩家、三坑玩家、动漫达人、独立设计师、爱卡通、兜风去、爱夜跑、街头滑板、球类运动、lo娘、rapper、时尚达人、机甲狂潮、养宠物、风轻云淡、养多肉、热爱自然、赛博朋克、骨子里高冷、爱唠嗑、资深中二、天然呆、思想家、极度抽象、学院派、平平无奇、热情奔放、博古通今、labubu粉、玛特收藏家";
  195. this.list_tag = tagStr.split("、");
  196. this.getInfoData();
  197. },
  198. onShow() {},
  199. methods: {
  200. openNicknamePopUpWindow() {
  201. this.$refs.openNicknamePopUpWindow.open();
  202. },
  203. openContentPopUpWindow() {
  204. this.$refs.openContentPopUpWindow.open();
  205. },
  206. closePropUp() {
  207. this.$refs.openNicknamePopUpWindow.close();
  208. this.$refs.openContentPopUpWindow.close();
  209. },
  210. onBack() {},
  211. onPreview() {},
  212. chkSel() {
  213. if (this.sel == 1) {
  214. this.sel = 0;
  215. } else {
  216. this.sel = 1;
  217. }
  218. },
  219. chkSex(sex) {
  220. this.sex = sex;
  221. },
  222. delTag(tg) {
  223. let list_tag2 = [];
  224. for (let i = 0; i < this.sel_tags.length; i++) {
  225. if (this.sel_tags[i] != tg) {
  226. list_tag2.push(this.sel_tags[i]);
  227. }
  228. }
  229. this.sel_tags = list_tag2;
  230. },
  231. selTags(itm) {
  232. let isIn = false;
  233. for (let entry of this.sel_tags) {
  234. if (entry == itm) {
  235. isIn = true;
  236. break;
  237. }
  238. }
  239. return isIn;
  240. },
  241. chkTag(itm) {
  242. if (this.selTags(itm)) {
  243. let tmpTags = [];
  244. for (let entry of this.sel_tags) {
  245. if (entry != itm) {
  246. tmpTags.push(entry);
  247. }
  248. }
  249. this.sel_tags = tmpTags;
  250. } else {
  251. if (this.sel_tags.length <= 4) {
  252. this.sel_tags.push(itm);
  253. } else {
  254. uni.showToast({
  255. title: "最多选择5个标签",
  256. icon: "none"
  257. });
  258. }
  259. }
  260. },
  261. sliderChange1(e) {
  262. this.age = e.detail.value;
  263. },
  264. sliderChange2(e) {
  265. this.height = e.detail.value;
  266. },
  267. sliderChange3(e) {
  268. this.weight = e.detail.value;
  269. },
  270. SetSex() {
  271. let that = this;
  272. uni.showActionSheet({
  273. itemColor: '#000000',
  274. itemList: this.sexOptions,
  275. success: function(res) {
  276. that.sexText = that.sexOptions[res.tapIndex];
  277. that.sex = res.tapIndex + 1;
  278. },
  279. fail: function(res) {
  280. console.log(res.errMsg);
  281. }
  282. });
  283. },
  284. getInfoData() {
  285. uni.request({
  286. url: this.$apiHost + '/Member/getinfoData',
  287. data: {
  288. uuid: getApp().globalData.uuid
  289. },
  290. header: {
  291. 'content-type': 'application/json'
  292. },
  293. success: (res) => {
  294. console.log(res.data);
  295. this.nickname = res.data.nickname;
  296. this.wechat = res.data.wechat;
  297. this.sex = res.data.sex;
  298. this.sexText = this.sexOptions[res.data.sex - 1] || '';
  299. this.birthday = res.data.birthday;
  300. this.content = res.data.content;
  301. this.xinzuo_sel = this.getConstellation(this.birthday);
  302. if (res.data.avator != "") {
  303. this.avator = res.data.avator;
  304. }
  305. if (res.data.aihao) {
  306. this.sel_tags = res.data.aihao.split(",");
  307. }
  308. }
  309. });
  310. },
  311. submitData(isBack) {
  312. let aihao = this.sel_tags.join(',')
  313. let obj2 = {
  314. uuid: getApp().globalData.uuid,
  315. avator: this.avator,
  316. nickname: this.nickname,
  317. content: this.content,
  318. sex: this.sex,
  319. birthday: this.birthday,
  320. xinzuo: this.xinzuo_sel,
  321. ziye: this.ziye,
  322. qianmin: this.qianmin,
  323. aihao: aihao
  324. }
  325. uni.request({
  326. url: this.$apiHost + '/Member/setinfoData',
  327. data: obj2,
  328. method: 'POST',
  329. header: {
  330. 'Content-Type': 'application/x-www-form-urlencoded',
  331. 'sign': getApp().globalData.headerSign
  332. },
  333. dataType: 'json',
  334. success: (res) => {
  335. console.log("res", res.data)
  336. uni.showToast({
  337. title: res.data.str,
  338. animation: 0,
  339. icon: "none"
  340. });
  341. if (this.success == 'yes' && isBack == true) {
  342. if (this.nickname) {
  343. getApp().globalData.nickname = this.nickname
  344. uni.removeStorageSync("nickname");
  345. uni.setStorageSync("nickname", this.nickname);
  346. }
  347. if (this.avator) {
  348. getApp().globalData.avator = this.avator
  349. uni.removeStorageSync("avator");
  350. uni.setStorageSync("avator", this.avator);
  351. }
  352. setTimeout(function() {
  353. console.log('返回');
  354. uni.navigateBack()
  355. }, 800)
  356. } else {
  357. this.closePropUp()
  358. }
  359. this.getInfoData()
  360. }
  361. });
  362. },
  363. chooseAvatar() {
  364. uni.showActionSheet({
  365. itemList: ['拍照', '从相册选择'],
  366. success: (res) => {
  367. const sourceType = res.tapIndex === 0 ? 'camera' : 'album';
  368. this.chooseImage(sourceType);
  369. }
  370. });
  371. },
  372. async chooseImage(sourceType) {
  373. try {
  374. let hasPermission = false;
  375. if (sourceType === 'camera') {
  376. hasPermission = await this.checkCameraPermission();
  377. } else if (sourceType === 'album') {
  378. hasPermission = await this.checkPhotoLibraryPermission();
  379. }
  380. if (!hasPermission) {
  381. uni.showToast({
  382. title: '未获得权限',
  383. icon: 'none'
  384. });
  385. return;
  386. }
  387. uni.chooseImage({
  388. count: 1,
  389. sizeType: ['compressed'],
  390. sourceType: [sourceType],
  391. success: async (res) => {
  392. console.log('res:', res)
  393. if (res.tempFilePaths.length > 0) {
  394. const tempFilePath = res.tempFilePaths[0];
  395. console.log('tempFilePaths:', tempFilePath);
  396. await this.uploadImage(tempFilePath);
  397. }
  398. },
  399. fail: (err) => {
  400. console.error('选择图片失败:', err);
  401. uni.showToast({
  402. title: '选择图片失败',
  403. icon: 'none'
  404. });
  405. }
  406. });
  407. } catch (error) {
  408. console.error('权限检查失败:', error);
  409. uni.showToast({
  410. title: '权限检查失败',
  411. icon: 'none'
  412. });
  413. }
  414. },
  415. async checkCameraPermission() {
  416. const hasPermission = await permission.request(permission.PermissionType.CAMERA, {
  417. title: '相机权限申请',
  418. describe: '需要使用相机拍摄照片,请允许使用相机权限'
  419. });
  420. return hasPermission;
  421. },
  422. async checkPhotoLibraryPermission() {
  423. const hasPermission = await permission.request(permission.PermissionType.PHOTO_LIBRARY, {
  424. title: '相册权限申请',
  425. describe: '需要访问相册选择照片,请允许访问相册权限'
  426. });
  427. return hasPermission;
  428. },
  429. uploadImage(tempFilePath) {
  430. var _self = this;
  431. const uploadTask = uni.uploadFile({
  432. url: _self.$apiHost + '/Xweb/upload_img?skey=' + _self.skey,
  433. filePath: tempFilePath,
  434. name: 'file',
  435. success: function(uploadFileRes) {
  436. let resdata = JSON.parse(uploadFileRes.data)
  437. console.log('Success11:', uploadFileRes);
  438. console.log('Success21:', resdata);
  439. if (resdata.success == 'yes') {
  440. _self.showRights = false;
  441. _self.avator = resdata.url;
  442. }
  443. },
  444. fail: function(uploadFileFail) {
  445. console.log('Error:', uploadFileFail.data);
  446. },
  447. complete: () => {
  448. console.log('Complete:');
  449. }
  450. });
  451. },
  452. onBirthdayChange(e) {
  453. this.birthday = e.detail.value;
  454. this.xinzuo_sel = this.getConstellation(this.birthday);
  455. },
  456. getConstellation(birthday) {
  457. if (!birthday) return '';
  458. const month = parseInt(birthday.split('-')[1]);
  459. const day = parseInt(birthday.split('-')[2]);
  460. // 星座日期数组
  461. const constellationDates = [
  462. [1, 20, "水瓶座"],
  463. [2, 19, "双鱼座"],
  464. [3, 21, "白羊座"],
  465. [4, 20, "金牛座"],
  466. [5, 21, "双子座"],
  467. [6, 22, "巨蟹座"],
  468. [7, 23, "狮子座"],
  469. [8, 23, "处女座"],
  470. [9, 23, "天秤座"],
  471. [10, 24, "天蝎座"],
  472. [11, 23, "射手座"],
  473. [12, 22, "摩羯座"]
  474. ];
  475. let constellation = "";
  476. if (day < constellationDates[month - 1][1]) {
  477. constellation = constellationDates[month - 1][2];
  478. } else {
  479. constellation = constellationDates[month % 12][2];
  480. }
  481. return constellation;
  482. },
  483. showAddTagInput() {
  484. this.showAddTag = true;
  485. this.newTag = '';
  486. },
  487. cancelAddTag() {
  488. this.showAddTag = false;
  489. this.newTag = '';
  490. },
  491. addCustomTag() {
  492. if (!this.newTag.trim()) {
  493. uni.showToast({
  494. title: '请输入标签名称',
  495. icon: 'none'
  496. });
  497. return;
  498. }
  499. if (this.list_tag.includes(this.newTag)) {
  500. uni.showToast({
  501. title: '该标签已存在',
  502. icon: 'none'
  503. });
  504. return;
  505. }
  506. this.list_tag.unshift(this.newTag);
  507. this.showAddTag = false;
  508. this.newTag = '';
  509. },
  510. }
  511. }
  512. </script>
  513. <style scoped lang="scss">
  514. @import 'normal.scss';
  515. page {
  516. font-family: PingFang SC-Medium;
  517. }
  518. .popSel {
  519. position: fixed;
  520. z-index: 101;
  521. top: 0;
  522. left: 0;
  523. background-color: #f2f6f2;
  524. width: 100vh;
  525. min-height: 100vh;
  526. .headLabel {
  527. width: 686rpx;
  528. margin: 28rpx 32rpx;
  529. min-height: 222rpx;
  530. background: #fff;
  531. box-sizing: border-box;
  532. padding: 30rpx 40rpx 46rpx 20rpx;
  533. border-radius: 20rpx;
  534. .avator-box {
  535. display: flex;
  536. align-items: center;
  537. .avator {
  538. width: 80rpx;
  539. height: 80rpx;
  540. margin-right: 20rpx;
  541. }
  542. }
  543. .tag-box {
  544. display: flex;
  545. flex-direction: row;
  546. justify-content: flex-start;
  547. align-items: center;
  548. flex-wrap: wrap;
  549. font-size: 24rpx;
  550. .tag {
  551. margin-right: 16rpx;
  552. margin-top: 20rpx;
  553. padding: 6rpx 10rpx;
  554. border: 2rpx solid #DCE1DC;
  555. color: #9E9E9E;
  556. display: flex;
  557. justify-content: center;
  558. align-items: center;
  559. border-radius: 42rpx;
  560. line-height: 1;
  561. .close {
  562. width: 20rpx;
  563. margin-left: 12rpx;
  564. position: relative;
  565. }
  566. }
  567. }
  568. }
  569. }
  570. .openNicknamePopUpWindow {
  571. .length-indicator {
  572. font-size: 24rpx;
  573. color: #999;
  574. text-align: right;
  575. margin-top: 10rpx;
  576. margin-right: 20rpx;
  577. position: absolute;
  578. right: 24rpx;
  579. top: 24rpx;
  580. }
  581. }
  582. .popSel {
  583. .item_tag {
  584. display: flex;
  585. flex-direction: row;
  586. justify-content: flex-start;
  587. align-items: center;
  588. flex-wrap: wrap;
  589. width: 690rpx;
  590. padding: 20rpx;
  591. .tag {
  592. border-radius: 94rpx;
  593. margin-right: 10rpx;
  594. margin-top: 10rpx;
  595. padding: 8rpx 16rpx;
  596. font-size: 28rpx;
  597. color: #333;
  598. display: flex;
  599. flex-direction: row;
  600. justify-content: center;
  601. align-items: center;
  602. background: #fff;
  603. border-width: 0;
  604. .close {
  605. width: 28rpx;
  606. margin-left: 2rpx;
  607. position: relative;
  608. }
  609. }
  610. .active {
  611. border-width: 0;
  612. background: #ACF934;
  613. }
  614. .addNew {
  615. margin-right: 10rpx;
  616. margin-top: 10rpx;
  617. padding: 0rpx 20rpx;
  618. height: 60rpx;
  619. border-radius: 12rpx;
  620. background: #1f1f1f;
  621. color: #fff;
  622. display: flex;
  623. flex-direction: row;
  624. justify-content: center;
  625. align-items: center;
  626. }
  627. }
  628. }
  629. .reserveASeat {
  630. width: 100%;
  631. height: calc(var(--status-bar-height) + 50rpx);
  632. }
  633. .page {
  634. background: url("../../static/me/wd_bg_bianjiziliao.png") top center/ 100% auto no-repeat,
  635. #f2f6f2;
  636. }
  637. .PageHeader {
  638. background: url("../../static/me/wd_bg_bianjiziliao.png") center top / 100% auto no-repeat,
  639. #f2f6f2;
  640. background-position-y: var(--status-bar-height);
  641. }
  642. .add-tag-box {
  643. background: #fff;
  644. padding: 20rpx;
  645. margin: 20rpx;
  646. border-radius: 12rpx;
  647. .add-tag-input {
  648. width: 100%;
  649. height: 80rpx;
  650. background: #f5f5f5;
  651. border-radius: 8rpx;
  652. padding: 0 20rpx;
  653. font-size: 28rpx;
  654. margin-bottom: 20rpx;
  655. }
  656. .add-tag-btns {
  657. display: flex;
  658. justify-content: flex-end;
  659. gap: 20rpx;
  660. .cancel-btn, .confirm-btn {
  661. padding: 10rpx 30rpx;
  662. border-radius: 8rpx;
  663. font-size: 28rpx;
  664. }
  665. .cancel-btn {
  666. background: #f5f5f5;
  667. color: #666;
  668. }
  669. .confirm-btn {
  670. background: #1f1f1f;
  671. color: #fff;
  672. }
  673. }
  674. }
  675. .item_tag {
  676. .add-tag {
  677. background: #f5f5f5;
  678. color: #666;
  679. border: 2rpx dashed #ddd;
  680. &:active {
  681. background: #e5e5e5;
  682. }
  683. }
  684. }
  685. </style>