app.vue 22 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754
  1. <template>
  2. <LoadingLogo v-if="hadVideo" :thumb="true" />
  3. <OpenVideo v-else @close="hadVideo = true" />
  4. <Guide />
  5. <div class="ui-view-layout" :class="{ show: show }" is-mobile="true">
  6. <div class="scene" ref="scene$"></div>
  7. <template v-if="dataLoaded">
  8. <Information v-if="!isshoppingguide" />
  9. <Control />
  10. <teleport v-if="refMiniMap && player.showWidgets" :to="refMiniMap">
  11. <span :class="{ gudieDisabled: isshoppingguide && role != 'leader' }" class="button-switch" @click.stop="toggleMap">
  12. <ui-icon type="show_map_collect"></ui-icon>
  13. </span>
  14. <p class="change" :class="{ gudieDisabled: isshoppingguide && role != 'leader' }" @click="changeMode('dollhouse', $event, 'focus3d')">
  15. <ui-icon type="show_3d_normal"></ui-icon>
  16. 3D模型
  17. </p>
  18. </teleport>
  19. <template v-if="refMiniMap && player.showWidgets">
  20. <div
  21. :class="{ disabled: flying, gudieDisabled: isshoppingguide && role != 'leader' }"
  22. v-show="mode != 'panorama'"
  23. v-if="controls.showFloorplan && controls.showDollhouse"
  24. class="tab-layer"
  25. >
  26. <div class="tabs" v-if="controls.showMap">
  27. <span :class="{ active: mode === 'floorplan' }" @click="changeMode('floorplan', $event)">
  28. <ui-icon :type="mode == 'floorplan' ? 'show_plane_selected' : 'show_plane_normal'"></ui-icon>
  29. 二維
  30. </span>
  31. <span :class="{ active: mode === 'dollhouse' }" @click="changeMode('dollhouse', $event)">
  32. <ui-icon :type="mode == 'dollhouse' ? 'show_3d_selected' : 'show_3d_normal'"></ui-icon>
  33. 三維
  34. </span>
  35. <div class="background" ref="background"></div>
  36. </div>
  37. </div>
  38. </template>
  39. </template>
  40. <!-- <UiTags /> -->
  41. </div>
  42. <GoodsList @close="closetagtype" />
  43. <Treasure @close="closetagtype" />
  44. <Waterfall @close="closetagtype" />
  45. </template>
  46. <script setup>
  47. import { useMusicPlayer } from "@/utils/sound";
  48. // import UiTags from "@/components/Tags";
  49. import GoodsList from "@/components/Tags/goods-list.vue";
  50. import Treasure from "@/components/Tags/treasure.vue";
  51. import Waterfall from "@/components/Tags/waterfall.vue";
  52. import Information from "@/components/Information";
  53. import Control from "@/components/Controls/Control.Mobile.vue";
  54. import LoadingLogo from "@/components/shared/Loading.vue";
  55. import OpenVideo from "@/components/openVideo/";
  56. import Guide from "@/components/shared/Guide.vue";
  57. import { Dialog } from "@/global_components/";
  58. import { createApp } from "@/app";
  59. import { ref, onMounted, computed, nextTick, watch } from "vue";
  60. import { useStore } from "vuex";
  61. import browser from "@/utils/browser";
  62. import { useApp, getApp } from "@/app";
  63. import common from "@/utils/common";
  64. import { Cache } from "@/utils/index";
  65. import * as apis from "@/apis/index.js";
  66. const store = useStore();
  67. let jumpNewScene = (sceneFirstView) => {
  68. let url = window.location.href;
  69. if (!browser.hasURLParam("pose")) {
  70. url += `&${sceneFirstView.sceneview}`;
  71. } else {
  72. url = browser.replaceQueryString(url, "pose", sceneFirstView.sceneview.replace("pose=", ""));
  73. }
  74. url = browser.replaceQueryString(url, "m", sceneFirstView.num);
  75. return url;
  76. };
  77. let visibilitychangeFn = () => {
  78. if (browser.isTabHidden()) {
  79. apis.burying_point({ type: 1 });
  80. }
  81. };
  82. let hashchangefn = () => {
  83. if (window.location.hash.indexOf("#showpage") >= 0) {
  84. window.history.go(-1);
  85. }
  86. };
  87. const musicPlayer = useMusicPlayer();
  88. let app = null;
  89. let tagid = browser.getURLParam("tagid");
  90. const role = computed(() => store.getters["rtc/role"]);
  91. const closetagtype = () => {
  92. store.commit("tag/setTagClickType", {
  93. type: "",
  94. data: {},
  95. });
  96. if (isshoppingguide.value) {
  97. if (role.value == "leader") {
  98. socket.value &&
  99. socket.value.emit("action", {
  100. type: "tagclose",
  101. });
  102. }
  103. }
  104. };
  105. const socket = computed(() => store.getters["rtc/socket"]);
  106. const tags = computed(() => {
  107. return store.getters["tag/tags"] || [];
  108. });
  109. const isshoppingguide = computed(() => store.getters["shoppingguide"]);
  110. const player = computed(() => store.getters["player"]);
  111. const flying = computed(() => store.getters["flying"]);
  112. const metadata = computed(() => store.getters["scene/metadata"]);
  113. const controls = computed(() => {
  114. return metadata.value.controls;
  115. });
  116. const mode = computed(() => store.getters["mode"]);
  117. const showNavigations = computed(() => store.getters["showNavigations"]);
  118. const scene$ = ref(null);
  119. const hadVideo = ref(true);
  120. if (!Cache.get("HIDENVIDEOEXPIRES")) {
  121. if (browser.getURLParam("m") == "eur-KJ-z5ZEV22AeU" && browser.getURLParam("pose") == "pano:408,qua:-0.006,0.6299,0.0049,0.7766") {
  122. Cache.set("HIDENVIDEOEXPIRES", "yes", 60 * 8 * 60);
  123. hadVideo.value = false;
  124. } else {
  125. hadVideo.value = true;
  126. }
  127. }
  128. if (role.value) {
  129. hadVideo.value = true;
  130. }
  131. const show = ref(false);
  132. const dataLoaded = ref(false);
  133. const refMiniMap = ref(null);
  134. const isCollapse = ref(false);
  135. const background = ref(null);
  136. const resize = () => {
  137. if (this.$refs.background && (this.mode == "floorplan" || this.mode == "dollhouse")) {
  138. this.$nextTick(() => {
  139. let $active = $(this.$el).find(".tabs .active");
  140. background.value.style.width = $active[0].getBoundingClientRect().width + "px";
  141. background.value.style.left = $active.position().left + "px";
  142. });
  143. }
  144. };
  145. watch(
  146. () => isshoppingguide.value,
  147. (val, old) => {
  148. console.log(isshoppingguide.value, "isshoppingguide.value,isshoppingguide.value,isshoppingguide.value,");
  149. let $minmap = document.querySelector("[xui_min_map]");
  150. if ($minmap) {
  151. setTimeout(async () => {
  152. if (role.value == "leader" || !role.value) {
  153. return;
  154. }
  155. await nextTick();
  156. if (isshoppingguide.value) {
  157. $minmap.classList.add("gudieDisabled");
  158. } else {
  159. $minmap.classList.remove("gudieDisabled");
  160. }
  161. });
  162. }
  163. },
  164. {
  165. deep: true,
  166. }
  167. );
  168. watch(
  169. () => player.value.showMap,
  170. (val, old) => {
  171. if (!isCollapse.value) {
  172. let $minmap = document.querySelector("[xui_min_map]");
  173. if ($minmap) {
  174. if (val) {
  175. $minmap.classList.remove("collapse");
  176. } else {
  177. $minmap.classList.add("collapse");
  178. }
  179. }
  180. }
  181. },
  182. {
  183. deep: true,
  184. }
  185. );
  186. watch(
  187. () => player.value.showWidgets,
  188. (val, old) => {
  189. let $minmap = document.querySelector("[xui_min_map]");
  190. if ($minmap) {
  191. if (val) {
  192. $minmap.classList.remove("collapse");
  193. } else {
  194. $minmap.classList.add("collapse");
  195. }
  196. }
  197. },
  198. {
  199. deep: true,
  200. }
  201. );
  202. const changeMode = (name, e, focus3d = false) => {
  203. if (!flying.value) {
  204. let width, left;
  205. store.commit("setMode", name);
  206. nextTick(() => {
  207. if (focus3d) {
  208. let $active = document.querySelector(".tabs>span:last-of-type");
  209. background.value.style.width = $active.getBoundingClientRect().width + "px";
  210. background.value.style.left = $active.offsetLeft + "px";
  211. } else {
  212. background.value.style.width = width || e.srcElement.getBoundingClientRect().width + "px";
  213. background.value.style.left = left || e.srcElement.offsetLeft + "px";
  214. }
  215. });
  216. }
  217. // console.dir(document.querySelector(".tabs>span:last-of-type"));
  218. };
  219. const toggleMap = () => {
  220. isCollapse.value = !isCollapse.value;
  221. let $minmap = document.querySelector("[xui_min_map]");
  222. if ($minmap) {
  223. if (!isCollapse.value) {
  224. $minmap.classList.remove("collapse");
  225. } else {
  226. $minmap.classList.add("collapse");
  227. }
  228. }
  229. };
  230. const onClickTagInfo = (el) => {
  231. el.stopPropagation();
  232. let item = tags.value.find((item) => item.sid == el.target.dataset.id);
  233. if (item.type == "commodity") {
  234. guideclicktag(item);
  235. store.commit("tag/setTagClickType", {
  236. type: "goodlist",
  237. data: item,
  238. });
  239. } else if (item.type == "link_scene") {
  240. guideclicktag(item);
  241. let sceneFirstView = item.hotContent.sceneFirstView;
  242. window.location.href = jumpNewScene(sceneFirstView);
  243. }
  244. };
  245. const guideclicktag = (tag) => {
  246. if (isshoppingguide.value) {
  247. if (role.value == "leader") {
  248. socket.value &&
  249. socket.value.emit("action", {
  250. type: "tagclick",
  251. data: {
  252. sid: tag.sid,
  253. },
  254. });
  255. console.log(tag, "触发--------------");
  256. }
  257. }
  258. return;
  259. };
  260. onMounted(async () => {
  261. apis.burying_point({ type: 0 });
  262. app = createApp({
  263. num: browser.getURLParam("m"),
  264. dom: scene$.value,
  265. mobile: true,
  266. isLoadTags: false,
  267. sceneKind: "tiles",
  268. scene: {
  269. markerOpacity: 1,
  270. markerURL: "https://eurs3.4dkankan.com/cdf/file/43aa29799bfd472298a47cc6370b10cc.png",
  271. pathEndColor: "#FF4641",
  272. },
  273. });
  274. app.use("MinMap", { theme: { camera_fillStyle: "#ED5D18" } });
  275. app.use("Tag");
  276. app
  277. .use("TagView", {
  278. render(data) {
  279. if (data.type == "waterfall") {
  280. return `<span class="tag-icon waterfall animate" style="background-image:url({{icon}})"></span>`;
  281. } else if (data.type == "coupon") {
  282. return `<span class="tag-icon coupon animate" style="background-image:url({{icon}})"></span>`;
  283. } else if (data.type == "applet_link") {
  284. try {
  285. data.hotContent = JSON.parse(data.hotContent);
  286. } catch (error) {}
  287. return `<span class="tag-icon applet_link animate" style="background-image:url(${
  288. data.hotContent.liveIcon.src ? common.changeUrl(data.hotContent.liveIcon.src) : "{{icon}}"
  289. })"></span>`;
  290. } else if (data.type == "link_scene") {
  291. return `<span class="tag-icon animate" style="background-image:url({{icon}})"></span>
  292. <div class="tag-body">
  293. <div data-id="${data.sid}" class="tag-commodity tag-link_scene">
  294. <p class="tag-title">點擊前往下一個區域</p>
  295. </div>
  296. </div>
  297. `;
  298. } else if (data.type == "commodity") {
  299. let arr = data.products.map((item) => item.price);
  300. let priceMin = isFinite(Math.min.apply(null, arr)) ? Math.min.apply(null, arr) : 0;
  301. let priceMax = isFinite(Math.max.apply(null, arr)) ? Math.max.apply(null, arr) : 0;
  302. let price = priceMin == priceMax ? priceMax : `${priceMin}-${priceMax}`;
  303. let range = `${data.products[0] ? data.products[0].symbol : "MOP$"} ${price}`;
  304. return `<span class="tag-icon animate" style="background-image:url({{icon}})"></span>
  305. <div class="tag-body">
  306. <div data-id="${data.sid}" class="tag-commodity">
  307. <div style="background-image:url(${data.products[0] ? data.products[0].pic : ""})" class='tag-avatar'>
  308. </div>
  309. <p class="tag-title">${data.title}</p>
  310. <p class="tag-info">${range} | 查看 ></p>
  311. </div>
  312. </div>
  313. `;
  314. } else {
  315. return `<span class="tag-icon animate" style="background-image:url({{icon}})"></span>`;
  316. }
  317. },
  318. })
  319. .then((view) => {
  320. view.on("click", (e) => {
  321. var tag = e.data;
  322. // 聚焦當前點擊的熱點
  323. view.focus(tag.sid).then(() => {
  324. if (tag.type == "coupon") {
  325. try {
  326. document.querySelector(`[data-tag-id="${tag.sid}"] .tag-icon`).style.display = "none";
  327. let hotcontent = typeof tag.hotContent == "string" ? JSON.parse(tag.hotContent) : tag.hotContent;
  328. browser.openLink(
  329. "/subPackage/pages/activity/activity?pageId=" + hotcontent.couponLink,
  330. `https://m.cdfmembers.com/shop/600667208/showactivity?pageId=${hotcontent.couponLink}`,
  331. `/pages/showactivity/showactivity?pageId=${hotcontent.couponLink}`
  332. );
  333. apis.burying_point({ type: 2 });
  334. } catch (error) {}
  335. } else if (tag.type == "waterfall") {
  336. store.commit("tag/setTagClickType", {
  337. type: "waterfall",
  338. data: tag,
  339. });
  340. guideclicktag(tag);
  341. } else if (tag.type == "applet_link") {
  342. try {
  343. let hotcontent = typeof tag.hotContent == "string" ? JSON.parse(tag.hotContent) : tag.hotContent;
  344. browser.openLink(
  345. "/subPackage/pages/home/home?pageType=2&pageId=" + hotcontent.liveLink,
  346. `https://m.cdfmembers.com/shop/600667208/showactivity?pageId=${hotcontent.liveLink}`,
  347. `/pages/showactivity/showactivity?pageId=${hotcontent.liveLink}`
  348. );
  349. } catch (error) {}
  350. } else if (tag.type == "link_scene") {
  351. guideclicktag(tag);
  352. setTimeout(() => {
  353. let sceneFirstView = tag.hotContent.sceneFirstView;
  354. window.location.href = jumpNewScene(sceneFirstView);
  355. }, 100);
  356. }
  357. });
  358. });
  359. view.on("focus", (e) => {
  360. document.querySelectorAll("[xui_tags_view] >div").forEach((el) => {
  361. if (el.getAttribute("data-tag-type") == "link_scene" || el.getAttribute("data-tag-type") == "commodity") {
  362. el.querySelector(".tag-body").classList.remove("show");
  363. el.style.zIndex = "auto";
  364. }
  365. });
  366. if (e.data.type == "commodity" || e.data.type == "link_scene") {
  367. e.target.style.zIndex = "999";
  368. e.target.querySelector(".tag-body").classList.add("show");
  369. e.target.querySelector(".tag-commodity").removeEventListener("click", onClickTagInfo);
  370. e.target.querySelector(".tag-commodity").addEventListener("click", onClickTagInfo);
  371. if (tagid) {
  372. document.querySelector(`[data-id="${tagid}"]`) && document.querySelector(`[data-id="${tagid}"]`).click();
  373. tagid = null;
  374. }
  375. }
  376. });
  377. view.on("rendered", (e) => {
  378. tagid && view.focus(tagid);
  379. }); //dom渲染完成
  380. });
  381. app.use("TourPlayer");
  382. // if (!hadVideo.value) {
  383. // app.Scene.lock();
  384. // }
  385. app.Scene.on("ready", () => {
  386. show.value = true;
  387. });
  388. app.Scene.on("error", (data) => {
  389. switch (data.code) {
  390. case 5033:
  391. Dialog.alert("该场景正在计算中,请稍后再试");
  392. break;
  393. case 5034:
  394. Dialog.alert("服务端开小差,请稍后再试");
  395. break;
  396. case 5009:
  397. Dialog.alert("服务端开小差,请稍后再试");
  398. break;
  399. case 5005:
  400. Dialog.alert("服务端开小差,请稍后再试");
  401. break;
  402. }
  403. });
  404. app.Scene.on("loaded", (pano) => {
  405. refMiniMap.value = "[xui_min_map]";
  406. store.commit("setFloorId", pano.floorIndex);
  407. store.commit("rtc/setShowdaogou", true);
  408. if (browser.getURLParam("roomId")) {
  409. store.commit("showShoppingguide", true);
  410. } else {
  411. if (!localStorage.getItem("user_guide")) {
  412. Dialog.confirm({
  413. showCloseIcon: false,
  414. okText: "我知道了",
  415. content:
  416. "<span style='font-size: 16px; line-height: 1.5;'>開發者已遵守收集、使用最終用戶個人信息有關的所有可適用法律、政策和法規,保護用戶個人信息安全。<span/>",
  417. title: "隱私條款:",
  418. single: true,
  419. func: (state) => {
  420. if (state == "ok") {
  421. localStorage.setItem("user_guide", Date.now());
  422. }
  423. },
  424. });
  425. }
  426. }
  427. app.resource.tags(`${process.env.VUE_APP_RESOURCE_URL}cdf/hot/${browser.getURLParam("m")}/hot.json?rnd=${Math.random()}`);
  428. useMusicPlayer();
  429. });
  430. app.Scene.on("panorama.videorenderer.resumerender", () => {
  431. musicPlayer.pause(true);
  432. });
  433. app.Scene.on("panorama.videorenderer.suspendrender", async () => {
  434. let player = await getApp().TourManager.player;
  435. if (!player.isPlaying) {
  436. musicPlayer.resume();
  437. }
  438. });
  439. app.store.on("metadata", (metadata) => {
  440. store.commit("scene/load", metadata);
  441. if (!metadata.controls.showMap) {
  442. app.MinMap.hide(true);
  443. }
  444. dataLoaded.value = true;
  445. });
  446. app.store.on("tags", (tags) => {
  447. store.commit("tag/load", tags);
  448. });
  449. app.Camera.on("mode.beforeChange", ({ fromMode, toMode, floorIndex }) => {
  450. if (fromMode) {
  451. store.commit("setFlying", true);
  452. }
  453. });
  454. app.Camera.on("mode.afterChange", ({ toMode, floorIndex }) => {
  455. store.commit("setFlying", false);
  456. });
  457. app.Camera.on("flying.started", (pano) => {
  458. store.commit("setFlying", true);
  459. });
  460. app.Camera.on("flying.ended", ({ targetPano }) => {
  461. store.commit("setFlying", false);
  462. store.commit("setPanoId", targetPano.id);
  463. if (app.Scene.isCurrentPanoHasVideo) {
  464. apis.burying_point({ type: 5 });
  465. }
  466. });
  467. app.Camera.on("pano.chosen", (pano) => {
  468. apis.burying_point({ type: 4 });
  469. });
  470. app.store.on("tour", async (tour) => {
  471. app.TourManager.load(tour);
  472. store.commit("tour/setData", {
  473. tours: JSON.parse(
  474. JSON.stringify(app.TourManager.tours, (key, val) => {
  475. if (key === "audio") {
  476. return null;
  477. } else {
  478. return val;
  479. }
  480. })
  481. ),
  482. });
  483. store.commit("tour/setBackUp", {
  484. tours: JSON.parse(
  485. JSON.stringify(app.TourManager.tours, (key, val) => {
  486. if (key === "audio") {
  487. return null;
  488. } else {
  489. return val;
  490. }
  491. })
  492. ),
  493. });
  494. });
  495. app.store.on("floorcad", (floor) => store.commit("scene/loadFloorData", floor));
  496. app.render();
  497. document.removeEventListener("visibilitychange", visibilitychangeFn);
  498. document.addEventListener("visibilitychange", visibilitychangeFn);
  499. if (browser.detectWeixin()) {
  500. //ios的ua中无miniProgram,但都有MicroMessenger(表示是微信浏览器)
  501. wx.miniProgram.getEnv((res) => {
  502. if (res.miniprogram) {
  503. window.removeEventListener("hashchange", hashchangefn);
  504. window.addEventListener("hashchange", hashchangefn);
  505. }
  506. });
  507. }
  508. });
  509. </script>
  510. <style lang="scss">
  511. .tab-layer {
  512. width: 100%;
  513. text-align: center;
  514. display: flex;
  515. justify-content: center;
  516. align-items: center;
  517. z-index: 10;
  518. position: fixed;
  519. left: 50%;
  520. transform: translateX(-50%);
  521. top: 2.3rem;
  522. pointer-events: none;
  523. }
  524. .tabs {
  525. pointer-events: auto;
  526. position: relative;
  527. display: flex;
  528. background: #222222;
  529. border-radius: 6px;
  530. padding: 2px;
  531. justify-content: center;
  532. align-items: center;
  533. border: 1px solid rgba(255, 255, 255, 0.1);
  534. box-shadow: inset 0px 0px 6px 0px rgba(0, 0, 0, 0.5);
  535. .background {
  536. position: absolute;
  537. left: 2px;
  538. top: 2px;
  539. bottom: 2px;
  540. width: 50%;
  541. border-radius: 4px;
  542. background: #444444;
  543. box-shadow: 2px 0px 4px 0px rgba(0, 0, 0, 0.3);
  544. z-index: 0;
  545. transition: left 0.3s;
  546. }
  547. span {
  548. flex: 1;
  549. color: #fff;
  550. opacity: 0.5;
  551. border-radius: 6px;
  552. height: 0.94737rem;
  553. font-size: 0.36842rem;
  554. transition: all 0.3s ease;
  555. display: flex;
  556. align-items: center;
  557. justify-content: center;
  558. padding-left: 10px;
  559. padding-right: 10px;
  560. white-space: nowrap;
  561. z-index: 1;
  562. i {
  563. font-size: 0.47368rem;
  564. margin-right: 4px;
  565. pointer-events: none;
  566. }
  567. }
  568. span.active {
  569. opacity: 1;
  570. }
  571. }
  572. [xui_tags_view] {
  573. .tag-body {
  574. /* display: none; */
  575. position: absolute;
  576. left: 50%;
  577. bottom: 50px;
  578. transform: translateX(-50%) scale(0);
  579. transform-origin: bottom;
  580. transition: all 0.3s cubic-bezier(0.35, 0.32, 0.65, 0.63);
  581. // pointer-events: none;
  582. .tag-commodity,
  583. .tag-link_scene {
  584. min-width: 230px;
  585. height: 76px;
  586. background: rgba(255, 255, 255, 0.8);
  587. box-shadow: 0px 3px 6px 0px rgba(0, 0, 0, 0.16);
  588. border-radius: 2px;
  589. position: relative;
  590. margin-bottom: 30px;
  591. &::before {
  592. content: "";
  593. display: inline-block;
  594. left: 50%;
  595. transform: translateX(-50%);
  596. width: 2px;
  597. height: 28px;
  598. bottom: -30px;
  599. background: linear-gradient(145deg, rgba(255, 255, 255, 0.8), rgba(255, 255, 255, 0));
  600. position: absolute;
  601. }
  602. .tag-avatar {
  603. position: absolute;
  604. z-index: 99;
  605. width: 80px;
  606. height: 80px;
  607. background: #ffffff;
  608. box-shadow: 0px 3px 6px 0px rgb(0 0 0 / 16%);
  609. border-radius: 2px;
  610. top: -14px;
  611. left: -12px;
  612. background-size: cover;
  613. pointer-events: none;
  614. }
  615. > p {
  616. color: #131d34;
  617. font-size: 16px;
  618. pointer-events: none;
  619. }
  620. .tag-title {
  621. padding: 10px 10px 10px 76px;
  622. overflow: hidden;
  623. text-overflow: ellipsis;
  624. white-space: nowrap;
  625. width: 240px;
  626. }
  627. .tag-info {
  628. padding: 0 20px 0 76px;
  629. font-size: 12px;
  630. overflow: hidden;
  631. text-overflow: ellipsis;
  632. white-space: nowrap;
  633. }
  634. }
  635. &.show {
  636. transform: translateX(-50%) scale(1);
  637. }
  638. .tag-link_scene {
  639. height: auto;
  640. min-width: unset;
  641. .tag-title {
  642. padding: 10px;
  643. width: auto;
  644. text-align: center;
  645. }
  646. }
  647. }
  648. .coupon {
  649. width: 84px !important;
  650. height: 84px !important;
  651. &::after {
  652. content: "發現好禮";
  653. width: 100%;
  654. color: #ed5d18;
  655. position: absolute;
  656. bottom: -24px;
  657. text-align: center;
  658. font-size: 14px;
  659. }
  660. }
  661. .waterfall {
  662. width: 90px !important;
  663. height: 90px !important;
  664. }
  665. .applet_link {
  666. width: 64px !important;
  667. height: 64px !important;
  668. border-radius: 50%;
  669. background-color: #fff;
  670. border: 1px solid #ed5d18;
  671. position: relative;
  672. overflow: hidden;
  673. &::after {
  674. content: "直播中";
  675. width: 100%;
  676. height: 20px;
  677. background: #ed5d18;
  678. position: absolute;
  679. bottom: 0;
  680. text-align: center;
  681. line-height: 1.2;
  682. font-size: 12px;
  683. border-radius: 26%;
  684. }
  685. }
  686. }
  687. .gudieDisabled {
  688. pointer-events: none !important;
  689. * {
  690. pointer-events: none !important;
  691. }
  692. }
  693. @media (orientation: landscape) {
  694. .tab-layer {
  695. top: 1.2rem;
  696. .tabs {
  697. height: 0.7rem;
  698. > span {
  699. height: 0.7rem;
  700. font-size: 0.25rem;
  701. }
  702. }
  703. }
  704. }
  705. </style>