index.vue 18 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846
  1. <template>
  2. <mobile-frame>
  3. <view class="main">
  4. <!-- <view class="one">
  5. <text>{{type==0?'短信验证码登录':'手机号密码登录'}}</text>
  6. </view>
  7. <view class="two">
  8. <uni-forms ref="form" :model="form" :rules="rules" label-width="auto">
  9. <uni-forms-item label="手机号" name="phone">
  10. <uni-easyinput type="number" v-model="form.phone" />
  11. </uni-forms-item>
  12. <uni-forms-item label="验证码" name="code" v-if="type==0">
  13. <view class="yzm">
  14. <view class="l">
  15. <uni-easyinput type="number" v-model="form.code" placeholder="请输入验证码" />
  16. </view>
  17. <view class="r">
  18. <button type="default" size="mini" @tap="oneSms">{{sms_1==0?'验证码':sms_1}}</button>
  19. </view>
  20. </view>
  21. </uni-forms-item>
  22. <uni-forms-item label="登录密码" name="password" v-if="type==1">
  23. <uni-easyinput type="text" v-model="form.password" placeholder="请输入登录密码" />
  24. </uni-forms-item>
  25. <view class="type">
  26. <button type="default" size="mini" @tap="passLogin">{{type==0?'密码登录':'短信登录'}}</button>
  27. </view>
  28. <view class="agree">
  29. <checkbox-group @change="changeAgree">
  30. <label>
  31. <checkbox :checked="agree" />
  32. <text @tap.stop="toAgree()">我已阅读并同意“用户协议”和“隐私政策”</text>
  33. </label>
  34. </checkbox-group>
  35. </view>
  36. <view class="btn">
  37. <button type="default" size="mini" @click="onSubmit('form')">登录</button>
  38. </view>
  39. </uni-forms>
  40. </view>
  41. <view class="thr">
  42. <view class="thr_1">
  43. <text>其他登录方式</text>
  44. </view>
  45. <view class="thr_2">
  46. <view class="thr_2_1" @tap="otherLogin('wx')">
  47. <text class="iconfont icon-weixin"></text>
  48. </view>
  49. </view>
  50. </view> -->
  51. <view class="wx">
  52. <view class="wx_1">
  53. <text class="iconfont icon-weixin"></text>
  54. </view>
  55. <view class="wx_2">
  56. <button size="mini" @tap="otherLogin('wx')">微信信任登录</button>
  57. </view>
  58. <view class="wx_3">
  59. <checkbox-group @change="changeAgree">
  60. <label>
  61. <checkbox :checked="agree" />
  62. <text @tap.stop="toAgree()">我已阅读并同意“用户协议”和“隐私政策”</text>
  63. </label>
  64. </checkbox-group>
  65. </view>
  66. </view>
  67. </view>
  68. <uni-popup ref="dialogShow" type="center" :mask-click="false" background-color="#ffffff">
  69. <view class="popup">
  70. <view class="title">
  71. <text>绑定手机号</text>
  72. </view>
  73. <view class="wx_1">
  74. <text>确定获取微信绑定手机号吗?</text>
  75. </view>
  76. <view class="wx_2">
  77. <button size="mini" @tap="diaClose">取消</button>
  78. <button size="mini" open-type="getPhoneNumber" @getphonenumber="getUserPhone">确定</button>
  79. </view>
  80. </view>
  81. </uni-popup>
  82. <!-- <uni-popup ref="dialogShow" type="dialog">
  83. <uni-popup-dialog :title="dialog.title" mode="base" :before-close="true" @confirm="diaSubmit(dialog)" @close="diaReset(dialog)">
  84. <view class="dialog dialog_1" v-if="dialog.type=='1'">
  85. <uni-forms ref="phoneForm" :model="phoneForm" label-width="auto">
  86. <uni-forms-item label="方式">
  87. <uni-data-checkbox v-model="phoneForm.type" :localdata="typeList" />
  88. </uni-forms-item>
  89. <uni-forms-item label="微信" v-if="phoneForm.type==0">
  90. <button type="default" size="mini" open-type="getPhoneNumber" @getphonenumber="getUserPhone">获取微信绑定手机</button>
  91. </uni-forms-item>
  92. <uni-forms-item label="手机号" v-if="phoneForm.type==0">
  93. <uni-easyinput type="number" v-model="phoneForm.phone" disabled />
  94. </uni-forms-item>
  95. <uni-forms-item label="手机号" v-if="phoneForm.type==1">
  96. <view class="yzm">
  97. <view class="l">
  98. <uni-easyinput type="number" v-model="phoneForm.phone" placeholder="请输入手机号" />
  99. </view>
  100. <view class="r">
  101. <button type="default" size="mini" @tap="twoSms">{{sms_1==0?'验证码':sms_1}}</button>
  102. </view>
  103. </view>
  104. </uni-forms-item>
  105. <uni-forms-item label="验证码" v-if="phoneForm.type==1">
  106. <uni-easyinput type="number" v-model="phoneForm.code" placeholder="请输入验证码" />
  107. </uni-forms-item>
  108. </uni-forms>
  109. </view>
  110. </uni-popup-dialog>
  111. </uni-popup> -->
  112. </mobile-frame>
  113. </template>
  114. <script>
  115. export default {
  116. data() {
  117. return {
  118. // 平台信息
  119. system: {},
  120. openid: '',
  121. // 登录类型
  122. type: 0,
  123. form: {},
  124. rules: {
  125. phone: {
  126. rules: [ //
  127. {
  128. required: true,
  129. errorMessage: '请输入手机号',
  130. },
  131. {
  132. minLength: 11,
  133. maxLength: 11,
  134. errorMessage: '账号长度在{maxLength}个字符',
  135. }
  136. ]
  137. }
  138. },
  139. sms_1: 0,
  140. // 用戶协议
  141. agree: true,
  142. // 注册账号信息
  143. user: {},
  144. // 弹框
  145. dialog: {
  146. title: '绑定手机号',
  147. type: '1'
  148. },
  149. // 绑定手机号
  150. phoneForm: {
  151. type: 0,
  152. },
  153. typeList: [ //
  154. {
  155. text: '微信',
  156. value: 0
  157. },
  158. {
  159. text: '短信验证',
  160. value: 1
  161. }
  162. ],
  163. };
  164. },
  165. onShow: function() {
  166. const that = this;
  167. // 查询平台信息
  168. that.searchSystem();
  169. },
  170. methods: {
  171. // 查询平台信息
  172. searchSystem() {
  173. const that = this;
  174. uni.getStorage({
  175. key: 'system',
  176. success: function(res) {
  177. that.$set(that, `system`, res.data);
  178. that.searchOpenid();
  179. },
  180. fail: function(err) {
  181. let system = that.$config.system;
  182. that.$set(that, `system`, system);
  183. that.searchOpenid();
  184. }
  185. })
  186. },
  187. // 查询openid
  188. searchOpenid() {
  189. const that = this;
  190. let system = that.system;
  191. if (system.uniPlatform == "mp-weixin") {
  192. uni.login({
  193. provider: 'weixin',
  194. success: async function(res) {
  195. const aee = await that.$api(`/wechat/api/login/app`, 'GET', {
  196. config: that.$config.wx_projectkey,
  197. js_code: res.code
  198. })
  199. if (aee.errcode == '0') {
  200. that.$set(that, `openid`, aee.data.openid);
  201. }
  202. }
  203. })
  204. } else if (system.uniPlatform == "app") {
  205. console.log('app');
  206. }
  207. },
  208. // 选择登录类型
  209. typeChange(e) {
  210. const that = this;
  211. that.$set(that, `type`, e.detail.value);
  212. },
  213. // 短信登录/密码登录
  214. passLogin() {
  215. const that = this;
  216. let type = 0;
  217. if (that.type == 0) type = 1;
  218. that.$set(that, `type`, type)
  219. },
  220. // 短信登录-发送验证码
  221. async oneSms() {
  222. const that = this;
  223. let form = that.form;
  224. if (form && form.phone) {
  225. let res = await that.$api(`/user/toLoginByCode`, 'POST', {
  226. phone: form.phone
  227. })
  228. if (res.errcode == '0') {
  229. uni.showToast({
  230. title: '发送成功',
  231. icon: 'none'
  232. })
  233. that.$set(that, `sms_1`, 60);
  234. that.timeDown();
  235. } else {
  236. uni.showToast({
  237. title: res.errmsg,
  238. icon: 'none'
  239. })
  240. }
  241. } else {
  242. uni.showToast({
  243. title: '输入错误,请重新输入!',
  244. icon: 'none'
  245. })
  246. }
  247. },
  248. // 登录
  249. onSubmit(ref) {
  250. const that = this;
  251. let agree = that.agree;
  252. let system = that.system;
  253. let type = that.type;
  254. that.$refs[ref].validate().then(async params => {
  255. if (agree) {
  256. if (type == 0 && system.uniPlatform == 'app') {
  257. // app,短信验证码登录
  258. that.appSmsLogin(params);
  259. } else if (type == 1 && system.uniPlatform == 'app') {
  260. // app,密码登录
  261. that.appPassLogin(params);
  262. } else if (type == 0 && system.uniPlatform == 'mp-weixin') {
  263. // wx,短信验证码登录
  264. that.wxSmsLogin(params)
  265. } else if (type == 1 && system.uniPlatform == 'mp-weixin') {
  266. // wx,密码登录
  267. that.wxPassLogin(params)
  268. }
  269. } else {
  270. uni.showToast({
  271. title: '请阅读并同意用户协议和隐私政策',
  272. icon: 'none'
  273. })
  274. }
  275. }).catch(err => {
  276. console.log(err);
  277. })
  278. },
  279. // app,短信验证码登录
  280. async appSmsLogin(e) {
  281. const that = this;
  282. if (e.code) {
  283. const res = await that.$api(`/user/checkLoginCode`, 'POST', e);
  284. if (res.errcode == '0') {
  285. uni.setStorage({
  286. key: 'token',
  287. data: res.data,
  288. success: function() {
  289. uni.navigateBack({
  290. delta: 1
  291. })
  292. }
  293. });
  294. } else {
  295. if (res.errcode == '-5') {
  296. uni.showToast({
  297. title: '用户不存在',
  298. icon: 'none'
  299. })
  300. // todo:验证码登录用户不存在可自动注册账号,并跳转
  301. } else {
  302. uni.showToast({
  303. title: res.errmsg || '信息错误',
  304. icon: 'none'
  305. })
  306. }
  307. }
  308. } else {
  309. uni.showToast({
  310. title: '请输入验证码',
  311. icon: 'none'
  312. })
  313. }
  314. },
  315. // app,密码登录
  316. async appPassLogin(e) {
  317. const that = this;
  318. if (e.password) {
  319. const res = await that.$api(`/user/login`, 'POST', e);
  320. if (res.errcode == '0') {
  321. uni.setStorage({
  322. key: 'token',
  323. data: res.data,
  324. success: function() {
  325. uni.navigateBack({
  326. delta: 1
  327. })
  328. }
  329. });
  330. } else {
  331. uni.showToast({
  332. title: res.errmsg || '信息错误',
  333. icon: 'none'
  334. })
  335. }
  336. } else {
  337. uni.showToast({
  338. title: '请输入登录密码',
  339. icon: 'none'
  340. })
  341. }
  342. },
  343. // wx,短信验证码登录
  344. async wxSmsLogin(e) {
  345. const that = this;
  346. if (e.code) {
  347. const res = await that.$api(`/user/checkLoginCode`, 'POST', e);
  348. if (res.errcode == '0') {
  349. uni.setStorage({
  350. key: 'token',
  351. data: res.data,
  352. success: function() {
  353. uni.navigateBack({
  354. delta: 1
  355. })
  356. }
  357. });
  358. } else {
  359. if (res.errcode == '-5') {
  360. uni.showModal({
  361. title: '提示',
  362. content: '用户不存在,是否注册新账号?',
  363. success: function(res) {
  364. if (res.confirm) {
  365. // 无账号,注册账号
  366. that.wxCreate();
  367. }
  368. }
  369. });
  370. } else {
  371. uni.showToast({
  372. title: res.errmsg || '信息错误',
  373. icon: 'none'
  374. })
  375. }
  376. }
  377. } else {
  378. uni.showToast({
  379. title: '请输入验证码',
  380. icon: 'none'
  381. })
  382. }
  383. },
  384. // wx,密码登录
  385. async wxPassLogin(e) {
  386. const that = this;
  387. if (e.password) {
  388. const res = await that.$api(`/user/login`, 'POST', e);
  389. if (res.errcode == '0') {
  390. uni.setStorage({
  391. key: 'token',
  392. data: res.data,
  393. success: function() {
  394. uni.navigateBack({
  395. delta: 1
  396. })
  397. }
  398. });
  399. } else {
  400. if (res.errcode == '-5') {
  401. uni.showModal({
  402. title: '提示',
  403. content: '用户不存在,是否注册新账号?',
  404. success: function(res) {
  405. if (res.confirm) {
  406. // 无账号,注册账号
  407. that.wxCreate();
  408. }
  409. }
  410. });
  411. } else {
  412. uni.showToast({
  413. title: res.errmsg || '信息错误',
  414. icon: 'none'
  415. })
  416. }
  417. }
  418. } else {
  419. uni.showToast({
  420. title: '请输入登录密码',
  421. icon: 'none'
  422. })
  423. }
  424. },
  425. // 其他登录方式
  426. async otherLogin(e) {
  427. const that = this;
  428. let system = that.system;
  429. let agree = that.agree;
  430. if (agree) {
  431. if (system.uniPlatform == 'app') {
  432. uni.showToast({
  433. title: '暂无开通',
  434. icon: 'none'
  435. })
  436. // todo:app端,微信一键登录
  437. } else if (system.uniPlatform == 'mp-weixin') {
  438. if (e == 'wx') {
  439. const res = await that.$api(`/user/wxLogin`, 'POST', {
  440. openid: that.openid
  441. })
  442. if (res.errcode == '0') {
  443. uni.setStorage({
  444. key: 'token',
  445. data: res.data,
  446. success: function() {
  447. uni.navigateBack({
  448. delta: 1
  449. })
  450. }
  451. });
  452. } else {
  453. if (res.errcode == '-5') {
  454. uni.showModal({
  455. title: '提示',
  456. content: '用户不存在,是否注册新账号?',
  457. success: function(res) {
  458. if (res.confirm) {
  459. // 无账号,注册账号
  460. that.wxCreate();
  461. }
  462. }
  463. });
  464. } else {
  465. uni.showToast({
  466. title: res.errmsg || '信息错误',
  467. icon: 'none'
  468. })
  469. }
  470. }
  471. }
  472. }
  473. } else {
  474. uni.showToast({
  475. title: '请阅读并同意用户协议和隐私政策',
  476. icon: 'none'
  477. })
  478. }
  479. },
  480. // wx,注册账号
  481. wxCreate() {
  482. const that = this;
  483. uni.getUserProfile({
  484. desc: '用于展示',
  485. success: async function(res) {
  486. let parmas = {
  487. openid: that.openid,
  488. icon: [{
  489. url: res.userInfo.avatarUrl
  490. }],
  491. name: res.userInfo.nickName,
  492. }
  493. console.log(parmas);
  494. const arr = await that.$api(`/user`, 'POST', parmas);
  495. if (arr.errcode == '0') {
  496. that.$set(that, `user`, arr.data);
  497. // 打开弹框
  498. that.diaShow();
  499. } else {
  500. uni.showToast({
  501. title: arr.errmsg,
  502. icon: 'none'
  503. });
  504. }
  505. },
  506. fail: function(err) {
  507. console.log(err);
  508. }
  509. })
  510. },
  511. // 打开弹框,绑定手机号
  512. diaShow() {
  513. const that = this;
  514. that.$refs.dialogShow.open();
  515. },
  516. // 获取手机号
  517. async getUserPhone(e) {
  518. const that = this;
  519. let user = that.user;
  520. let detail = e.detail;
  521. let res = await that.$api(`/wechat/api/login/getPhone`, 'GET', {
  522. config: that.$config.wx_projectkey,
  523. code: detail.code
  524. })
  525. if (res.errcode == '0') {
  526. let phone = res.data && res.data.phone_info && res.data.phone_info.purePhoneNumber || '';
  527. that.updatePhone(phone, 'wx')
  528. } else {
  529. uni.showToast({
  530. title: res.errmsg,
  531. icon: 'none'
  532. })
  533. }
  534. },
  535. // 弹框关闭
  536. diaClose() {
  537. const that = this;
  538. that.$refs.dialogShow.close();
  539. that.otherLogin('wx');
  540. },
  541. async twoSms() {
  542. const that = this;
  543. let user = this.user;
  544. let form = that.phoneForm;
  545. if (form && form.phone) {
  546. let res = await that.$api(`/user/toBindPhone`, 'POST', {
  547. id: user._id,
  548. phone: form.phone
  549. })
  550. if (res.errcode == '0') {
  551. uni.showToast({
  552. title: '发送成功',
  553. icon: 'none'
  554. })
  555. that.$set(that, `sms_1`, 60);
  556. that.timeDown();
  557. } else {
  558. uni.showToast({
  559. title: res.errmsg,
  560. icon: 'none'
  561. })
  562. }
  563. } else {
  564. uni.showToast({
  565. title: '请输入手机号!',
  566. icon: 'none'
  567. })
  568. }
  569. },
  570. // 弹框确定
  571. async diaSubmit(e) {
  572. const that = this;
  573. let user = this.user;
  574. let form = that.phoneForm;
  575. if (e.type == '1') {
  576. if (form.type == 0) {
  577. if (form && form.phone) that.updatePhone(form.phone, 'wx');
  578. } else if (form.type == 1) {
  579. const res = await that.$api(`/user/checkBindPhone`, 'POST', {
  580. id: user._id,
  581. code: form.code,
  582. phone: form.phone
  583. });
  584. if (res.errcode == '0') {
  585. that.updatePhone(form.phone, 'wx');
  586. } else {
  587. uni.showToast({
  588. title: arr.errmsg,
  589. icon: 'none'
  590. })
  591. }
  592. } else {
  593. uni.showToast({
  594. title: res.errmsg,
  595. icon: 'none'
  596. })
  597. }
  598. }
  599. },
  600. // 弹框取消(关闭)
  601. diaReset(e) {
  602. const that = this;
  603. if (e.type == '1') {
  604. that.otherLogin('wx');
  605. }
  606. },
  607. async updatePhone(e, type) {
  608. const that = this;
  609. let user = that.user;
  610. let arr = await that.$api(`/user/${user._id}`, 'POST', {
  611. phone: e
  612. })
  613. if (arr.errcode == '0') {
  614. that.otherLogin(type);
  615. } else {
  616. uni.showToast({
  617. title: res.errmsg,
  618. icon: 'none'
  619. })
  620. }
  621. },
  622. // 倒计时
  623. timeDown() {
  624. const that = this;
  625. var times = setInterval(() => {
  626. that.sms_1--;
  627. if (that.sms_1 <= 0) {
  628. clearInterval(times);
  629. }
  630. }, 1000);
  631. },
  632. // 同意隐私协议
  633. changeAgree() {
  634. const that = this;
  635. let agree = true;
  636. if (that.agree) agree = false;
  637. that.$set(that, `agree`, agree);
  638. },
  639. // 查看隐私协议
  640. toAgree() {
  641. const that = this;
  642. uni.navigateTo({
  643. url: `/pages/other/agree`
  644. })
  645. },
  646. },
  647. }
  648. </script>
  649. <style lang="scss">
  650. .main {
  651. display: flex;
  652. flex-direction: column;
  653. width: 100vw;
  654. height: 100vh;
  655. .one {
  656. position: relative;
  657. flex-grow: 0.01;
  658. padding: 0 5vw;
  659. margin: 10vw 0;
  660. text {
  661. font-size: 30px;
  662. font-family: cursive;
  663. font-weight: bold;
  664. }
  665. }
  666. .two {
  667. position: relative;
  668. flex-grow: 0.3;
  669. padding: 0 5vw;
  670. .type {
  671. text-align: center;
  672. margin: 0 0 2vw 0;
  673. }
  674. .agree {
  675. text-align: center;
  676. font-size: 12px;
  677. margin: 0 0 2vw 0;
  678. }
  679. .btn {
  680. text-align: center;
  681. button {
  682. width: 80%;
  683. border-radius: 25px;
  684. font-size: 16px;
  685. color: #fff;
  686. background-color: green;
  687. }
  688. }
  689. }
  690. .thr {
  691. padding: 0 2vw;
  692. text-align: center;
  693. .thr_1 {
  694. font-size: 14px;
  695. margin: 0 0 2vw 0;
  696. color: #858585;
  697. }
  698. .thr_2 {
  699. display: flex;
  700. justify-content: center;
  701. .thr_2_1 {
  702. margin: 0 2vw;
  703. text {
  704. font-size: 40px;
  705. }
  706. }
  707. }
  708. }
  709. .wx {
  710. text-align: center;
  711. margin: 25vw 0 0 0;
  712. .wx_1 {
  713. margin: 0 0 5vw 0;
  714. text {
  715. font-size: 50px;
  716. }
  717. }
  718. .wx_2 {
  719. button {
  720. background: var(--f35BColor);
  721. color: var(--fffColor);
  722. font-size: var(--font16Size);
  723. }
  724. }
  725. .wx_3 {
  726. position: absolute;
  727. bottom: 10vw;
  728. width: 100vw;
  729. text-align: center;
  730. font-size: 12px;
  731. }
  732. }
  733. }
  734. .yzm {
  735. display: flex;
  736. flex-direction: row;
  737. justify-content: space-between;
  738. .l {
  739. flex-grow: 1;
  740. }
  741. .r {
  742. width: 18vw;
  743. button {
  744. width: 100%;
  745. line-height: 2.8;
  746. padding: 0 1vw;
  747. }
  748. }
  749. }
  750. .dialog {
  751. width: 100vw;
  752. }
  753. .dialog_1 {
  754. .uni-forms {
  755. display: flex;
  756. form {
  757. width: 100%;
  758. }
  759. }
  760. .uni-data-checklist {
  761. border: 1px solid #E5E5E5;
  762. padding: 1vw;
  763. border-radius: 5px;
  764. }
  765. .uni-forms-item {
  766. margin-bottom: 2vw !important;
  767. }
  768. }
  769. .uni-popup__wrapper {
  770. border-radius: 5px;
  771. }
  772. .popup {
  773. width: 86vw;
  774. padding: 2vw;
  775. .title {
  776. text-align: center;
  777. margin: 0 0 2vw 0;
  778. text {
  779. color: var(--ff0Color);
  780. font-size: var(--font16Size);
  781. }
  782. }
  783. .wx_1 {
  784. text-align: center;
  785. margin: 9vw 0;
  786. text {
  787. font-size: var(--font18Size);
  788. }
  789. }
  790. .wx_2 {
  791. text-align: center;
  792. button {
  793. margin: 0 2vw;
  794. font-size: var(--font16Size);
  795. padding: 0 10vw;
  796. color: var(--fffColor);
  797. background-color: var(--f35BColor);
  798. }
  799. button:nth-child(1) {
  800. background-color: var(--ff0Color);
  801. }
  802. }
  803. }
  804. </style>