You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

299 lines
6.2 KiB

4 weeks ago
4 weeks ago
4 weeks ago
4 weeks ago
4 weeks ago
4 weeks ago
4 weeks ago
4 weeks ago
4 weeks ago
4 weeks ago
4 weeks ago
4 weeks ago
4 weeks ago
4 weeks ago
4 weeks ago
4 weeks ago
4 weeks ago
4 weeks ago
4 weeks ago
4 weeks ago
4 weeks ago
4 weeks ago
4 weeks ago
4 weeks ago
4 weeks ago
4 weeks ago
4 weeks ago
4 weeks ago
4 weeks ago
4 weeks ago
4 weeks ago
4 weeks ago
4 weeks ago
4 weeks ago
4 weeks ago
4 weeks ago
4 weeks ago
4 weeks ago
  1. <template>
  2. <div class="homepage">
  3. <!-- 顶部主图背景 -->
  4. <div class="main-icon"></div>
  5. <!-- 按钮区域 -->
  6. <div class="buttons-container">
  7. <!-- 夺宝奇兵模块 -->
  8. <div class="btn-item" @click="goToDBQBmodel">
  9. <div class="btn-icon btn-dbqb"></div>
  10. <div class="btn-ball"></div>
  11. <div class="btn-text btn-text-dbqb"></div>
  12. </div>
  13. <!-- AI情绪模块 -->
  14. <div class="btn-item" @click="goToEmotionsmodel">
  15. <div class="btn-icon btn-ai"></div>
  16. <div class="btn-ball"></div>
  17. <div class="btn-text btn-text-ai"></div>
  18. </div>
  19. </div>
  20. <!-- 底部口号与说明 -->
  21. <div class="footer-wrapper">
  22. <div class="footer-text1"></div>
  23. <div class="footer-text2"></div>
  24. </div>
  25. </div>
  26. </template>
  27. <script setup>
  28. import { onMounted, ref } from 'vue'
  29. import { useRouter } from 'vue-router'
  30. import { setHeight } from '@/utils/setHeight'
  31. import { useDataStore } from "@/store/dataList.js";
  32. const { getQueryVariable, setActiveTabIndex } = useDataStore();
  33. const router = useRouter()
  34. const pageRef = ref(null)
  35. // onMounted(() => {
  36. // setHeight(pageRef.value)
  37. // })
  38. onMounted(async () => {
  39. const isPhone =
  40. /phone|pad|pod|iPhone|iPod|ios|iPad|Android|Mobile|BlackBerry|IEMobile|MQQBrowser|JUC|Fennec|wOSBrowser|BrowserNG|WebOS|Symbian|Windows Phone/i.test(
  41. navigator.userAgent
  42. );
  43. !isPhone &&
  44. localStorage.setItem(
  45. "localToken",
  46. decodeURIComponent(String(getQueryVariable("token")))
  47. );
  48. })
  49. const goToDBQBmodel = () => {
  50. router.push('/DBQBmodel')
  51. window.location.href = '/DBQBmodel'
  52. }
  53. const goToEmotionsmodel = () => {
  54. router.push('/Emotionsmodel')
  55. window.location.href = '/Emotionsmodel'
  56. }
  57. </script>
  58. <style scoped>
  59. .homepage {
  60. /* width: 100vw; */
  61. /* min-height: 100vh; */
  62. background-color: #000cfc;
  63. background-image: url('@/assets/img/Selectmodel/-s-bg.png');
  64. background-size: cover;
  65. background-position: center;
  66. background-repeat: no-repeat;
  67. overflow-x: hidden;
  68. display: flex;
  69. flex-direction: column;
  70. align-items: center;
  71. box-sizing: border-box;
  72. text-align: center;
  73. }
  74. .main-icon {
  75. width: 90vw;
  76. max-width: 280px;
  77. height: 280px;
  78. background-image: url('@/assets/img/Selectmodel/-s-机器人.png');
  79. background-size: contain;
  80. background-repeat: no-repeat;
  81. background-position: center;
  82. margin-top: 10vh;
  83. }
  84. /* ===== 默认(PC端)按钮区域 ===== */
  85. .buttons-container {
  86. margin-top: 5vh;
  87. display: flex;
  88. gap: 30vw;
  89. justify-content: center;
  90. align-items: flex-end;
  91. flex-wrap: nowrap;
  92. }
  93. .btn-item {
  94. position: relative;
  95. display: flex;
  96. flex-direction: column;
  97. align-items: center;
  98. width: 90vw;
  99. max-width: 200px;
  100. }
  101. .btn-icon {
  102. /* height: 80px;
  103. width: 100%; */
  104. background-size: contain;
  105. background-repeat: no-repeat;
  106. background-position: center;
  107. }
  108. .btn-dbqb {
  109. height: 150px;
  110. width: 100%;
  111. background-image: url('@/assets/img/Selectmodel/-s-夺宝奇兵logo.png');
  112. }
  113. .btn-ai {
  114. height: 150px;
  115. width: 100%;
  116. background-image: url('@/assets/img/Selectmodel/金轮 拷贝.png');
  117. }
  118. .btn-ball {
  119. height: 150px;
  120. width: 150%;
  121. margin-top: -30px;
  122. background-image: url('@/assets/img/Selectmodel/球.png');
  123. background-size: contain;
  124. background-repeat: no-repeat;
  125. background-position: center;
  126. position: relative;
  127. }
  128. .btn-text {
  129. height: 200px;
  130. width: 150%;
  131. position: absolute;
  132. bottom: -20px;
  133. left: 50%;
  134. transform: translateX(-50%);
  135. background-size: contain;
  136. background-repeat: no-repeat;
  137. background-position: center;
  138. }
  139. .btn-text-dbqb {
  140. background-image: url('@/assets/img/Selectmodel/-s-夺宝奇兵大模型.png');
  141. }
  142. .btn-text-ai {
  143. background-image: url('@/assets/img/Selectmodel/-s-AI情绪大模型.png');
  144. }
  145. /* ===== 底部口号区域 ===== */
  146. .footer-wrapper {
  147. margin-top: 6vh;
  148. display: flex;
  149. flex-direction: column;
  150. align-items: center;
  151. gap: 5vh;
  152. }
  153. .footer-text1 {
  154. width: 100vh;
  155. max-width: 100vh;
  156. height: 9vh;
  157. background-image: url('@/assets/img/Selectmodel/智能体.png');
  158. background-size: 100% 100%;
  159. background-size: contain;
  160. background-repeat: no-repeat;
  161. background-position: center;
  162. }
  163. .footer-text2 {
  164. width: 70vw;
  165. max-width: 360px;
  166. height: 30px;
  167. margin-bottom: 60px;
  168. background-image: url('@/assets/img/Selectmodel/-s-弘历团队.png');
  169. background-size: contain;
  170. background-repeat: no-repeat;
  171. background-position: center;
  172. }
  173. /* 手机适配 */
  174. @media screen and (max-width: 600px) {
  175. .homepage {
  176. height: auto; /* 解决底部留白 */
  177. width: 100%;
  178. overflow-x: hidden;
  179. }
  180. .main-icon {
  181. margin-top: 350px;
  182. width: 9rem;
  183. height: 10rem;
  184. }
  185. .buttons-container {
  186. margin-top: 80px;
  187. gap: 10vw;
  188. position: relative;
  189. flex-wrap: nowrap;
  190. }
  191. .btn-item {
  192. width: 40vw;
  193. display: flex;
  194. flex-direction: column;
  195. align-items: center;
  196. position: relative;
  197. padding-bottom: 20px;
  198. }
  199. .btn-icon {
  200. height: 80px;
  201. margin-bottom: -10px;
  202. }
  203. .btn-ball {
  204. height: 80px;
  205. margin-top: -10px;
  206. position: relative;
  207. z-index: 1;
  208. }
  209. .btn-text {
  210. position: absolute;
  211. bottom: 45px;
  212. width: 90%;
  213. height: 40px;
  214. z-index: 2;
  215. }
  216. .footer-text1 {
  217. width: 100vw;
  218. height: 60px;
  219. margin-top: 10px;
  220. background-size: 100% 100%; /* 保证全宽显示 */
  221. }
  222. .footer-text2 {
  223. width: 70vw;
  224. height: 24px;
  225. margin-top: 10px;
  226. }
  227. }
  228. /* 平板适配 */
  229. @media screen and (min-width: 601px) and (max-width: 1024px) {
  230. .homepage {
  231. height: 120vh;
  232. }
  233. .main-icon {
  234. margin-top: 50%;
  235. width: 50vw;
  236. height: 50vw;
  237. }
  238. .btn-item {
  239. padding-top: 20px;
  240. width: 300vw;
  241. position: relative;
  242. }
  243. .btn-icon,
  244. .btn-ball {
  245. height: 100px;
  246. width: 300px;
  247. }
  248. .btn-text {
  249. height: 90px;
  250. width: 100%;
  251. top: 70%;
  252. left: 50%;
  253. transform: translate(-50%, -50%);
  254. }
  255. .footer-text1 {
  256. width: 100vw;
  257. max-width: 900px;
  258. height: 200px;
  259. }
  260. .footer-text2 {
  261. padding-top: 30px;
  262. height: 26px;
  263. }
  264. }
  265. </style>