Index.vue 14 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578
  1. <template>
  2. <div
  3. class="bottomIndex"
  4. >
  5. <div
  6. tabindex="0"
  7. aria-label
  8. data-aria-viewport-area
  9. aria-description="You've reached the content area of the Site Index, please use the tab key to navigate through the content."
  10. >
  11. <img
  12. src="/data/Index/1.jpg"
  13. alt=""
  14. tabindex="0"
  15. aria-label=""
  16. aria-description="Site Index"
  17. />
  18. <div class="home" title="Home" >
  19. <img
  20. src="/data/Index/home.jpg"
  21. alt=""
  22. @click="skip('/')"
  23. @keydown.enter.passive="skip('/')"
  24. tabindex="0"
  25. aria-label="Link"
  26. aria-description="Home"
  27. />
  28. </div>
  29. <div class="main" >
  30. <img v-if="themeIdx === 0" src="@/assets/images/site-index-default.png" alt="" />
  31. <img v-if="themeIdx === 1" src="@/assets/images/site-index-white.png" alt="" />
  32. <img v-if="themeIdx === 2" src="@/assets/images/site-index-blue.png" alt="" />
  33. <img v-if="themeIdx === 3" src="@/assets/images/site-index-yellow.png" alt="" />
  34. <img v-if="themeIdx === 4" src="@/assets/images/site-index-black.png" alt="" />
  35. <!-- <img src="/data/Index/main.jpg" alt="" /> -->
  36. <!-- 定位的盒子 -->
  37. <div class="loc aria-theme-independent">
  38. <div class="one aria-theme-independent">
  39. <div
  40. class="one aria-theme-independent"
  41. :class="{ active: item.path !== '' }"
  42. @click="skip(item.path, item.sroll)"
  43. @keydown.enter.passive="skip(item.path, item.sroll)"
  44. :title="item.title"
  45. v-for="(item, index) in data1"
  46. :key="index"
  47. :style="`width:${item.width};top:${item.top * 45}px;left:${
  48. item.left
  49. }`"
  50. tabindex="0"
  51. aria-label="Link"
  52. :aria-description="item.title"
  53. ></div>
  54. </div>
  55. <div class="tow aria-theme-independent">
  56. <div
  57. class="one aria-theme-independent"
  58. :class="{ active: item.path !== '' }"
  59. @click="skip(item.path, item.sroll)"
  60. @keydown.enter.passive="skip(item.path, item.sroll)"
  61. :title="item.title"
  62. v-for="(item, index) in data2"
  63. :key="index"
  64. :style="`width:${item.width};top:${item.top * 45}px;left:${
  65. item.left
  66. }`"
  67. tabindex="0"
  68. aria-label="Link"
  69. :aria-description="item.title"
  70. ></div>
  71. </div>
  72. <div class="three aria-theme-independent">
  73. <div
  74. class="one aria-theme-independent"
  75. :class="{ active: item.path !== '' }"
  76. @click="skip(item.path, item.sroll)"
  77. @keydown.enter.passive="skip(item.path, item.sroll)"
  78. :title="item.title"
  79. v-for="(item, index) in data3"
  80. :key="index"
  81. :style="`width:${item.width};top:${item.top * 45}px;left:${
  82. item.left
  83. }`"
  84. tabindex="0"
  85. aria-label="Link"
  86. :aria-description="item.title"
  87. ></div>
  88. </div>
  89. </div>
  90. </div>
  91. </div>
  92. </div>
  93. </template>
  94. <script>
  95. import accessibilityMixin from "/src/views/accessibilityMixin.js"
  96. export default {
  97. name: "bottomIndex",
  98. components: {},
  99. mixins: [accessibilityMixin],
  100. data() {
  101. //这里存放数据
  102. return {
  103. data1: [
  104. {
  105. title: "Visit",
  106. width: "110px",
  107. top: 0,
  108. left: "0px",
  109. path: "/Layout/Visit/1",
  110. },
  111. {
  112. title: "Hours,Direction & Admission",
  113. width: "250px",
  114. top: 1,
  115. left: "0px",
  116. path: "/Layout/Visit/1",
  117. },
  118. {
  119. title: "Reservation",
  120. width: "110px",
  121. top: 2,
  122. left: "0px",
  123. path: "/Layout/Visit/2",
  124. },
  125. // {
  126. // title: "Reservation System",
  127. // width: "180px",
  128. // top: 3,
  129. // left: "0px",
  130. // path: "",
  131. // },
  132. {
  133. title: "Floor Plans",
  134. width: "110px",
  135. top: 3,
  136. left: "0px",
  137. path: "/Layout/Visit/3",
  138. },
  139. {
  140. title: "Audio Guide & Tour",
  141. width: "175px",
  142. top: 4,
  143. left: "0px",
  144. path: "/Layout/Visit/4",
  145. },
  146. {
  147. title: "Accessibility",
  148. width: "120px",
  149. top: 5,
  150. left: "0px",
  151. path: "/Layout/Visit/5",
  152. },
  153. {
  154. title: "Café & Shop",
  155. width: "120px",
  156. top: 6,
  157. left: "0px",
  158. path: "/Layout/Visit/6",
  159. },
  160. {
  161. title: "Visitor Guidelines",
  162. width: "160px",
  163. top: 7,
  164. left: "0px",
  165. path: "/Layout/Visit/7",
  166. },
  167. //
  168. {
  169. title: "Exhibitions",
  170. width: "200px",
  171. top: 0,
  172. left: "290px",
  173. path: "/Layout/Exhibitions/1",
  174. },
  175. {
  176. title: "Current Exhibitions",
  177. width: "170px",
  178. top: 1,
  179. left: "290px",
  180. path: "/Layout/Exhibitions/1",
  181. },
  182. {
  183. title: "Permanent Exhibitions",
  184. width: "200px",
  185. top: 2,
  186. left: "290px",
  187. path: "/Layout/Exhibitions/2",
  188. },
  189. {
  190. title: "Past Exhibitions",
  191. width: "155px",
  192. top: 3,
  193. left: "290px",
  194. path: "/Layout/Exhibitions/3",
  195. },
  196. {
  197. title: "Overseas Exhibitions",
  198. width: "200px",
  199. top: 4,
  200. left: "290px",
  201. path: "/Layout/Exhibitions/4",
  202. },
  203. //
  204. {
  205. title: "Collections",
  206. width: "200px",
  207. top: 0,
  208. left: "588px",
  209. path: "/Layout/Collections/Bronzes",
  210. },
  211. {
  212. title: "Bronzes",
  213. width: "95px",
  214. top: 1,
  215. left: "588px",
  216. path: "/Layout/Collections/Bronzes",
  217. },
  218. {
  219. title: "Ceramics",
  220. width: "95px",
  221. top: 2,
  222. left: "588px",
  223. path: "/Layout/Collections/Ceramics",
  224. },
  225. {
  226. title: "Buddhist Statues",
  227. width: "155px",
  228. top: 3,
  229. left: "588px",
  230. path: "/Layout/Collections/Buddhist",
  231. },
  232. {
  233. title: "Jadewares",
  234. width: "115px",
  235. top: 4,
  236. left: "588px",
  237. path: "/Layout/Collections/Jadewares",
  238. },
  239. {
  240. title: "Calligraphies",
  241. width: "120px",
  242. top: 5,
  243. left: "588px",
  244. path: "/Layout/Collections/Calligraphies",
  245. },
  246. {
  247. title: "Paintings",
  248. width: "95px",
  249. top: 6,
  250. left: "588px",
  251. path: "/Layout/Collections/Paintings",
  252. },
  253. {
  254. title: "Gold & Silverwares",
  255. width: "170px",
  256. top: 7,
  257. left: "588px",
  258. path: "/Layout/Collections/Gold",
  259. },
  260. {
  261. title: "Coins & Banknotes",
  262. width: "170px",
  263. top: 8,
  264. left: "588px",
  265. path: "/Layout/Collections/Coins",
  266. },
  267. {
  268. title: "Brocades & Embroideries",
  269. width: "210px",
  270. top: 8.9,
  271. left: "588px",
  272. path: "/Layout/Collections/Brocades",
  273. },
  274. {
  275. title: "Cultural Supplies",
  276. width: "150px",
  277. top: 9.8,
  278. left: "588px",
  279. path: "/Layout/Collections/Cultural",
  280. },
  281. {
  282. title: "Miscellaneous",
  283. width: "140px",
  284. top: 10.8,
  285. left: "588px",
  286. path: "/Layout/Collections/Miscellaneous",
  287. },
  288. //
  289. {
  290. title: "Learn & Engage",
  291. width: "265px",
  292. top: 0,
  293. left: "880px",
  294. path: "/Layout/LearnEngage/Students",
  295. },
  296. {
  297. title: "For Students",
  298. width: "130px",
  299. top: 1,
  300. left: "880px",
  301. path: "/Layout/LearnEngage/Students",
  302. },
  303. {
  304. title: "For Adults",
  305. width: "120px",
  306. top: 2,
  307. left: "880px",
  308. path: "/Layout/LearnEngage/Adults",
  309. },
  310. {
  311. title: "For Families & Children",
  312. width: "210px",
  313. top: 3,
  314. left: "880px",
  315. path: "/Layout/LearnEngage/Families",
  316. },
  317. ],
  318. data2: [
  319. {
  320. title: "Preservation & Publications",
  321. width: "430px",
  322. top: 0,
  323. left: "0px",
  324. path: "/Layout/Publications/2",
  325. },
  326. {
  327. title: "Preservation",
  328. width: "118px",
  329. top: 1,
  330. left: "0px",
  331. path: "/Layout/Publications/3",
  332. },
  333. {
  334. title: "Publications",
  335. width: "118px",
  336. top: 2,
  337. left: "0px",
  338. path: "/Layout/Publications/1",
  339. },
  340. //
  341. {
  342. title: "Join & Support",
  343. width: "250px",
  344. top: 0,
  345. left: "588px",
  346. path: "/Layout/JoinSupport/Volunteer",
  347. },
  348. {
  349. title: "Ways to Volunteer",
  350. width: "160px",
  351. top: 1,
  352. left: "588px",
  353. path: "/Layout/JoinSupport/Volunteer",
  354. },
  355. {
  356. title: "Volunteer Team Introduction",
  357. width: "270px",
  358. top: 2,
  359. left: "588px",
  360. path: "/Layout/JoinSupport/VolunteerInfo?id=1",
  361. },
  362. {
  363. title: "Volunteer Apply",
  364. width: "160px",
  365. top: 3,
  366. left: "588px",
  367. path: "/Layout/JoinSupport/VolunteerInfo?id=2",
  368. },
  369. {
  370. title: "Volunteer Program",
  371. width: "205px",
  372. top: 4,
  373. left: "588px",
  374. path: "/Layout/JoinSupport/VolunteerInfo?id=3",
  375. },
  376. {
  377. title: "Feedbacks",
  378. width: "120px",
  379. top: 5,
  380. left: "588px",
  381. path: "/Layout/JoinSupport/VolunteerInfo?id=4",
  382. },
  383. {
  384. title: "Ways to Give",
  385. width: "120px",
  386. top: 6,
  387. left: "588px",
  388. path: "/Layout/JoinSupport/Give",
  389. },
  390. {
  391. title: "Individuals",
  392. width: "120px",
  393. top: 7,
  394. left: "588px",
  395. path: "/Layout/JoinSupport/GiveInfo?id=4",
  396. },
  397. {
  398. title: "Corporations & Institutions",
  399. width: "250px",
  400. top: 8,
  401. left: "588px",
  402. path: "/Layout/JoinSupport/GiveInfo?id=5",
  403. },
  404. //
  405. {
  406. title: "About",
  407. width: "130px",
  408. top: 0,
  409. left: "880px",
  410. path: "/Layout/About",
  411. },
  412. {
  413. title: "From the Director",
  414. width: "175px",
  415. top: 1,
  416. left: "880px",
  417. path: "/Layout/About",
  418. sroll: 338,
  419. },
  420. {
  421. title: "History",
  422. width: "75px",
  423. top: 2,
  424. left: "880px",
  425. path: "/Layout/About",
  426. sroll: 805,
  427. },
  428. {
  429. title: "Partners & Connections",
  430. width: "210px",
  431. top: 3,
  432. left: "880px",
  433. path: "/Layout/About",
  434. sroll: 1307,
  435. },
  436. {
  437. title: "Contact",
  438. width: "75px",
  439. top: 4,
  440. left: "880px",
  441. path: "/Layout/About",
  442. sroll: 1515,
  443. },
  444. ],
  445. data3: [
  446. {
  447. title: "Auxiliary Functions",
  448. width: "310px",
  449. top: 0,
  450. left: "0px",
  451. path: "",
  452. },
  453. {
  454. title: "Moblie Site",
  455. width: "105px",
  456. top: 1,
  457. left: "0px",
  458. path: "https://zzbbh.4dage.com/shouBoM/index.html#/Layout/Home",
  459. },
  460. {
  461. title: "Terms of Use",
  462. width: "120px",
  463. top: 2,
  464. left: "0px",
  465. path: "/Layout/Use",
  466. },
  467. // { title: "News", width: "55px", top: 3, left: "0px", path: "" },
  468. // {
  469. // title: "Upcoming Events",
  470. // width: "155px",
  471. // top: 4,
  472. // left: "0px",
  473. // path: "/Layout/Events",
  474. // },
  475. {
  476. title: "Employment",
  477. width: "110px",
  478. top: 3,
  479. left: "0px",
  480. path: "/Layout/Employment",
  481. },
  482. ],
  483. };
  484. },
  485. //监听属性 类似于data概念
  486. computed: {},
  487. //监控data中的数据变化
  488. watch: {},
  489. //方法集合
  490. methods: {
  491. skip(url, sroll) {
  492. if(url==='https://zzbbh.4dage.com/shouBoM/index.html#/Layout/Home') {
  493. window.open(url)
  494. return
  495. }
  496. this.$router.push(url).catch(() => {});
  497. if (sroll) {
  498. setTimeout(() => {
  499. window.scrollTo({ top: sroll, behavior: "smooth" });
  500. }, 100);
  501. }
  502. },
  503. },
  504. //生命周期 - 创建完成(可以访问当前this实例)
  505. created() {},
  506. //生命周期 - 挂载完成(可以访问DOM元素)
  507. mounted() {
  508. this.$eventBus.$emit(
  509. "request-read",
  510. ` You've reached the Site Index page. This page contains one navigation section, three window sections, and one interactive section. To choose an area, please hit the shortcut key.`
  511. );
  512. },
  513. beforeCreate() {}, //生命周期 - 创建之前
  514. beforeMount() {}, //生命周期 - 挂载之前
  515. beforeUpdate() {}, //生命周期 - 更新之前
  516. updated() {}, //生命周期 - 更新之后
  517. beforeDestroy() {}, //生命周期 - 销毁之前
  518. destroyed() {}, //生命周期 - 销毁完成
  519. activated() {}, //如果页面有keep-alive缓存功能,这个函数会触发
  520. };
  521. </script>
  522. <style lang='less' scoped>
  523. .bottomIndex {
  524. clear: both;
  525. width: 1186px;
  526. margin: 0 auto 55px;
  527. font-size: 18px;
  528. color: #333;
  529. line-height: 30px;
  530. padding-top: 75px;
  531. .home {
  532. padding: 30px 0;
  533. border-bottom: solid 1px #000;
  534. & > img {
  535. cursor: pointer;
  536. }
  537. }
  538. .main {
  539. position: relative;
  540. padding-top: 30px;
  541. .loc {
  542. position: absolute;
  543. width: 100%;
  544. height: 100%;
  545. top: 30px;
  546. left: 0;
  547. & > div {
  548. width: 100%;
  549. position: absolute;
  550. opacity: 0.3;
  551. top: 0;
  552. left: 0;
  553. & > div {
  554. width: 110px;
  555. height: 35px;
  556. position: absolute;
  557. }
  558. }
  559. .active {
  560. cursor: pointer;
  561. }
  562. .one {
  563. height: 520px;
  564. }
  565. .tow {
  566. height: 400px;
  567. top: 570px;
  568. }
  569. .three {
  570. height: 260px;
  571. top: 1025px;
  572. }
  573. }
  574. }
  575. }
  576. </style>