index.tsx 21 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529
  1. import React, { useEffect, useState } from 'react'
  2. import styles from './index.module.scss'
  3. import A2main from '../A2main'
  4. const scriptArr = [
  5. './js/manage.js',
  6. './js/Hot.js?m=1',
  7. './js/main_2020_show.js',
  8. './CAD/bundle.js',
  9. './showa/js/loadCAD.js'
  10. ]
  11. function A1home() {
  12. // 动态加载 js
  13. const [lodingJs, setLodingJs] = useState(0)
  14. useEffect(() => {
  15. if (lodingJs < scriptArr.length) {
  16. let script = document.createElement('script')
  17. script.type = 'text/javascript'
  18. script.src = scriptArr[lodingJs]
  19. document.head.appendChild(script)
  20. script.onload = () => {
  21. setLodingJs(lodingJs + 1)
  22. }
  23. }
  24. }, [lodingJs])
  25. return (
  26. <div className={styles.A1home}>
  27. <div id='hot'> </div>
  28. <div className='widgets-doll-labels'> </div>
  29. <div id='popup'>
  30. <div className='popup-wrap'>
  31. <div className='popup-content'></div>
  32. <div id='closepop'>close</div>
  33. </div>
  34. </div>
  35. <div className='sidecontent' style={{ width: '35%' }}>
  36. <h1>
  37. <span className='side-client-close'>关闭</span>
  38. </h1>
  39. <img src='' alt='' id='sideimg' style={{ width: '90%' }} />
  40. <br />
  41. <p id='text'></p>
  42. </div>
  43. <div id='gui-thumb' style={{ display: 'none' }}></div>
  44. <div id='player' style={{ display: 'none' }}></div>
  45. <div id='gui-parent'>
  46. <div id='memory-info'>
  47. GPU memory used: <span id='memory-gpu'></span>
  48. </div>
  49. <div id='gui-loading' className='message-outer darkGlass' style={{ display: 'none' }}>
  50. <h2 className='model-title'> </h2>
  51. <div className='message-inner'>
  52. <div className='loadingLogo'>
  53. <div className='img'></div>
  54. </div>
  55. <div className='progressbar' data-perc='100'>
  56. <div className='label'>
  57. <div className='perc'>0%</div>
  58. </div>
  59. <div className='bar'>
  60. <span></span>
  61. </div>
  62. </div>
  63. <div id='loaderCoBrand'>
  64. <div className='vert-align'></div>
  65. </div>
  66. <div className='bottom-logo'>
  67. <div className='img'></div>
  68. </div>
  69. <div className='specialPower'>
  70. <span className='powered-by'>{'{[{ POWERED_BY }]}'}</span>
  71. &#xA0;<div className='img'></div>
  72. </div>
  73. </div>
  74. </div>
  75. {/* 主要内容 */}
  76. <A2main />
  77. <div className='webvr-popup' style={{ display: 'none' }}>
  78. <div className='messaging'>
  79. <div className='page p1'>
  80. <div className='title'>{'{[{ WEBVR_FOR_DAYDREAM }]}'}</div>
  81. <img className='image device-headset-side' alt='' />
  82. <div className='enter-button'>{'{[{ WEBVR_ENTER_WEBVR }]}'}</div>
  83. <span className='hrule'></span>
  84. <div className='alt-help'>
  85. <span className='open-with-app'>{'{[{ VR_APP_OPEN }]}'}</span>
  86. </div>
  87. </div>
  88. <div className='page p2 hidden'>
  89. <div className='title'>{'{[{ VR_WHAT_YOU_NEED }]}'}</div>
  90. <ul className='tabs'>
  91. <li className='tabbutton' id='tabcardboard'>
  92. {'{[{ VR_GOOGLE_CARDBOARD }]}'}
  93. </li>
  94. <li className='tabbutton' id='tabdaydream'>
  95. {'{[{ VR_GOOGLE_DAYDREAM }]}'}
  96. </li>
  97. <li className='tabbutton' id='tabnative'>
  98. {'{[{ VR_APP }]}'}
  99. </li>
  100. </ul>
  101. <div className='tab-content webvr'>
  102. <img className='image device-headset' alt='' />
  103. <span className='detail headset'>
  104. <u>{'{[{ VR_GOOGLE_CARDBOARD }]}'}</u>
  105. </span>
  106. <img className='image device-phone' alt='' />
  107. <span className='detail phone'>
  108. <p>
  109. <b>
  110. <u>{'{[{ VR_COMPATIBLE_ANDROID }]}'}</u>
  111. </b>
  112. </p>
  113. <p>{'{[{ VR_ANDROID_DETAIL }]}'}</p>
  114. </span>
  115. <div className='detail daydream-label'>{'{[{ VR_NEED_DAYDREAM }]}'}</div>
  116. </div>
  117. <div className='tab-content native hidden'>
  118. <div className='badge-label'>{'{[{ VR_APP_FOR_ANDROID }]}'}</div>
  119. <span>
  120. <img className='image badge-cardboard' alt='' />
  121. <img className='image badge-oculus' alt='' />
  122. </span>
  123. </div>
  124. </div>
  125. </div>
  126. <div className='close'>
  127. {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */}
  128. <a>
  129. <i className='icon icon-close'></i>
  130. </a>
  131. </div>
  132. <div className='footer'>
  133. <div className='help'>
  134. {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */}
  135. <a>{'{[{ HELP }]}'}</a>
  136. </div>
  137. <div>|</div>
  138. <div className='terms'>
  139. {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */}
  140. <a>{'{[{ MATTERPORT_TERMS }]}'}</a>
  141. </div>
  142. </div>
  143. </div>
  144. <div id='gui-spinner' style={{ display: 'none' }}>
  145. <div className='gui-spinner-icon'></div>
  146. </div>
  147. <div id='gui-message' className='message-outer darkGlass' style={{ display: 'none' }}>
  148. <h2 className='model-title'> </h2>
  149. <div className='message-inner'>
  150. <div className='message-content'>
  151. {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */}
  152. <a id='button-play'>
  153. <i className='icon icon-play'></i>
  154. </a>
  155. <div className='explore'>{'{[{ EXPLORE_3D_SPACE }]}'}</div>
  156. </div>
  157. </div>
  158. </div>
  159. <div id='share-modal' style={{ display: 'none' }}>
  160. <div className='title'>{'{[{ SOCIAL_SHARING }]}'}</div>
  161. <div id='share-outer'>
  162. <div className='share-to'>{'{[{ SHARE_TO }]}'}</div>
  163. <div className='share-images'>
  164. {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */}
  165. <a id='facebook-share'>
  166. <div className='share-button'>
  167. <span className='faceBookLink'>
  168. <i className='icon icon-facebook'></i>
  169. </span>
  170. </div>
  171. </a>
  172. {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */}
  173. <a id='twitter-share'>
  174. <div className='share-button'>
  175. <span className='twitterLink'>
  176. <i className='icon icon-twitter'></i>
  177. </span>
  178. </div>
  179. </a>
  180. {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */}
  181. <a id='mail-share'>
  182. <div className='share-button'>
  183. <span className='mailLink'>
  184. <i className='icon icon-email'></i>
  185. </span>
  186. </div>
  187. </a>
  188. </div>
  189. <div className='direct-link'>{'{[{ SHARE_LINK }]}'}</div>
  190. <div id='share-url'>
  191. <span id='share-url-text'></span>
  192. </div>
  193. <div id='copy-success' className='hidden'>
  194. <span id='copy-success-text'>{'{[{ SHARE_COPIED }]}'}</span>
  195. </div>
  196. </div>
  197. <div id='share-close' className='close'>
  198. <i className='icon icon-close'></i>
  199. </div>
  200. </div>
  201. <div id='terms-modal' className='fadeOut' style={{ display: 'none' }}>
  202. <div id='terms-text'></div>
  203. <div className='close'>
  204. {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */}
  205. <a>
  206. <i className='icon icon-close'></i>
  207. </a>
  208. </div>
  209. </div>
  210. <div className='gui-error message-outer' style={{ display: 'none' }}>
  211. <div className='message-inner'>
  212. <div className='message-content'>
  213. <div className='error-problem-text'></div>
  214. <div className='error-solution-text'></div>
  215. <div className='error-explanation'></div>
  216. <div className='error-actions'></div>
  217. </div>
  218. </div>
  219. </div>
  220. <div id='help-dialog' className='nav-help-dialog' style={{ display: 'none' }}>
  221. <div className='nav-help-elements'>
  222. <div className='help-tabs'>
  223. <div className='navigation-tab'>
  224. <span>{'{[{ HELP_NAVIGATION_TAB }]}'}</span>
  225. </div>
  226. <div className='more-help-tab'>
  227. <span>{'{[{ HELP_MORE_HELP_TAB }]}'}</span>
  228. </div>
  229. </div>
  230. </div>
  231. <div id='navigation-help-wrapper'>
  232. <div id='navigation-help' className='help outer'>
  233. <div className='interactions left'>
  234. <h2 className='top-info'> </h2>
  235. <img className='big-image' alt='' />
  236. <hr />
  237. <div className='bottom-info'></div>
  238. <img className='keyboard' alt='' />
  239. </div>
  240. <div className='interactions middle'>
  241. <h2 className='top-info'> </h2>
  242. <img className='big-image' alt='' />
  243. <hr />
  244. <div className='bottom-info'></div>
  245. <img className='keyboard' alt='' />
  246. </div>
  247. <div className='interactions right'>
  248. <h2 className='top-info'> </h2>
  249. <img className='big-image' alt='' />
  250. <hr />
  251. <div className='bottom-info'></div>
  252. <img className='keyboard' alt='' />
  253. </div>
  254. </div>
  255. </div>
  256. <div id='more-help-wrapper'>
  257. <div id='more-help'>
  258. <div className='ui-instructions more-help-hlr'>
  259. <h2 className='top-info'> </h2>
  260. <img className='big-image' alt='' />
  261. <div className='bottom-info'></div>
  262. </div>
  263. <div className='ui-instructions more-help-tour'>
  264. <h2 className='top-info'> </h2>
  265. <img className='big-image' alt='' />
  266. <div className='bottom-info'></div>
  267. </div>
  268. <div className='ui-instructions more-help-dollhouse'>
  269. <h2 className='top-info'> </h2>
  270. <img className='big-image' alt='' />
  271. <div className='bottom-info'></div>
  272. </div>
  273. <div className='ui-instructions more-help-inside'>
  274. <h2 className='top-info'> </h2>
  275. <img className='big-image' alt='' />
  276. <div className='bottom-info'></div>
  277. </div>
  278. <div className='ui-instructions more-help-360'>
  279. <h2 className='top-info'> </h2>
  280. <img className='big-image' alt='' />
  281. <div className='bottom-info'></div>
  282. </div>
  283. <div className='ui-instructions more-help-floors'>
  284. <h2 className='top-info'> </h2>
  285. <img className='big-image' alt='' />
  286. <div className='bottom-info'></div>
  287. </div>
  288. <div className='ui-instructions more-help-tag'>
  289. <h2 className='top-info'> </h2>
  290. <img className='big-image' alt='' />
  291. <div className='bottom-info'></div>
  292. </div>
  293. <div className='ui-instructions more-help-vr'>
  294. <h2 className='top-info'> </h2>
  295. <img className='big-image' alt='' />
  296. <div className='bottom-info'></div>
  297. </div>
  298. <div className='ui-instructions more-help-fullscreen'>
  299. <h2 className='top-info'> </h2>
  300. <img className='big-image' alt='' />
  301. <div className='bottom-info'></div>
  302. </div>
  303. <div className='ui-instructions more-help-zoom'>
  304. <h2 className='top-info'> </h2>
  305. <img className='big-image' alt='' />
  306. <div className='bottom-info'></div>
  307. </div>
  308. </div>
  309. </div>
  310. <div className='close'>
  311. {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */}
  312. <a>
  313. <i className='icon icon-close'></i>
  314. </a>
  315. </div>
  316. </div>
  317. <div id='vr-modal' className='vr-popup' style={{ display: 'none' }}>
  318. <div className='title'>{'{[{ VR_VIEW_SPACE }]}'}</div>
  319. <div className='outer'>
  320. <div className='inner'>
  321. <h3 className='vr-popup-title'>
  322. <span className='show-supported p1'>
  323. <p className='center'>{'{[{ VR_SHOW_SUPPORTED }]}'}</p>
  324. </span>
  325. <span className='show-unsupported p1'>{'{[{ VR_SHOW_UNSUPPORTED }]}'}</span>
  326. <span className='show-ios p1'>
  327. {'{[{ VR_SHOW_IOS_1 }]}'}
  328. <br />
  329. <br />
  330. </span>
  331. <span className='show-ios p2'>{'{[{ VR_WHAT_YOU_NEED }]}'}</span>
  332. </h3>
  333. <div className='vr-images'>
  334. <div className='img-container cardboard first'>
  335. <img className='vr-sm-image first' alt='' />
  336. <div className='vr-img-caption first'>
  337. <span className='show-supported show-desktop show-ios p1'>
  338. <b className='cardboard'>{'{[{ VR_GOOGLE_CARDBOARD }]}'}</b>
  339. <b className='gearvr hidden'>{'{[{ VR_SAMSUNG_GEAR_VR }]}'}</b>
  340. </span>
  341. <span className='show-supported show-unsupported show-desktop p2'>
  342. {'{[{ VR_NEED_CARDBOARD}]}'}
  343. </span>
  344. <span className='show-supported show-unsupported show-desktop p3'>
  345. {'{[{ VR_NEED_SAMSUNG}]}'}
  346. </span>
  347. <span className='show-ios p2'>
  348. <b>{'{[{ VR_GOOGLE_CARDBOARD }]}'}</b>
  349. <br />
  350. <br />
  351. </span>
  352. </div>
  353. </div>
  354. <div className='front-close'>
  355. <span className='front-close-x'>&#x2715;</span>
  356. </div>
  357. <div className='img-container gearvr second'>
  358. <img className='vr-sm-image second' alt='' />
  359. <div className='vr-img-caption second'>
  360. <span className='show-supported show-desktop p1'>
  361. <b>{'{[{ VR_SAMSUNG_GEAR_VR }]}'}</b>
  362. </span>
  363. <span className='show-supported p2'>
  364. <p>
  365. <b>{'{[{ VR_COMPATIBLE_ANDROID }]}'}</b>
  366. </p>
  367. <p>{'{[{ VR_ANDROID_DETAIL }]}'}</p>
  368. </span>
  369. <span className='show-desktop p2'>
  370. <p>
  371. <b>{'{[{ VR_COMPATIBLE_IPHONES_1 }]}'}</b>
  372. </p>
  373. <p>{'{[{ VR_COMPATIBLE_IPHONES_2 }]}'}</p>
  374. </span>
  375. <span className='show-ios p2'>
  376. <p>
  377. <b id='vr-compatible-iphones-3'>{'{[{ VR_COMPATIBLE_IPHONES_3 }]}'}</b>
  378. </p>
  379. <p id='vr-compatible-iphones-2b'>{'{[{ VR_COMPATIBLE_IPHONES_2 }]}'}</p>
  380. </span>
  381. <span className='show-unsupported p1 p2'>
  382. <p>
  383. <b>{'{[{ VR_COMPATIBLE_ANDROID }]}'}</b>
  384. </p>
  385. <p>{'{[{ VR_ANDROID_DETAIL }]}'}</p>
  386. </span>
  387. <span className='show-supported show-unsupported show-desktop p3'>
  388. <p>
  389. <b>{'{[{ VR_COMPATIBLE_SAMSUNG }]}'}</b>
  390. </p>
  391. <p>{'{[{ VR_SAMSUNG_DETAIL }]}'}</p>
  392. </span>
  393. </div>
  394. </div>
  395. <div className='img-container third'>
  396. <img className='vr-sm-image third' alt='' />
  397. <div className='vr-img-caption third'>
  398. <span className='show-supported show-unsupported show-ios p2'>
  399. <p>
  400. <b>{'{[{ VR_APP_FOR_CARDBOARD }]}'}</b>
  401. </p>
  402. <p>
  403. {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */}
  404. <a className='cardboardLink'>{'{[{ VR_DOWNLOAD_HERE }]}'}</a>
  405. </p>
  406. </span>
  407. <span className='show-desktop p2'>
  408. <p>
  409. <b>{'{[{ VR_ANDROID_DVICES }]}'}</b>
  410. </p>
  411. <p>{'{[{ VR_ANDROID_DETAIL }]}'}</p>
  412. </span>
  413. <span className='show-supported show-unsupported p3'>
  414. <p>
  415. <b>{'{[{ VR_APP_FOR_SAMSUNG }]}'}</b>
  416. </p>
  417. <p>
  418. {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */}
  419. <a className='gearLink'>{'{[{ VR_DOWNLOAD_HERE }]}'}</a>
  420. </p>
  421. </span>
  422. </div>
  423. </div>
  424. </div>
  425. <div className='vr-popup-body'>
  426. <span className='show-supported p1'>
  427. <p>
  428. <i>{'{[{ VR_REQUIRE_HEADSET }]}'}</i>
  429. </p>
  430. <br />
  431. <p>
  432. <i>{'{[{ VR_REDIRECT_TO_STORE }]}'}</i>
  433. </p>
  434. <br />
  435. <p className='improper-embed hidden'>
  436. <i>{'{[{ VR_IMPROPER_EMBED }]}'}</i>
  437. </p>
  438. </span>
  439. <span className='show-ios p1'>
  440. <p>
  441. <i id='show-ios-2'>{'{[{ VR_SHOW_IOS_2 }]}'}</i>
  442. </p>
  443. </span>
  444. <span className='show-desktop p1'>
  445. <p></p>
  446. <h3>{'{[{ VR_OPEN_ANDROID_LINK }]}'}</h3>
  447. <p>
  448. <br />
  449. </p>
  450. <p className='logo-button'>
  451. <span className='modelLink'></span>
  452. </p>
  453. <br />
  454. <br />
  455. <p></p>
  456. <h3>{'{[{ VR_ANDROID_OPTIONS }]}'}</h3>
  457. <p></p>
  458. </span>
  459. </div>
  460. </div>
  461. <div className='vr-buttons'>
  462. <div className='next-button'></div>
  463. <div className='prev-button'>{'{[{ VR_PREVIOUS_CAPS }]}'}</div>
  464. <div className='vr-arrows prev-container'></div>
  465. <div className='vr-arrows next-container'></div>
  466. </div>
  467. <div className='vr-page'></div>
  468. <div className='close'>
  469. {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */}
  470. <a>
  471. <i className='icon icon-close'></i>
  472. </a>
  473. </div>
  474. </div>
  475. </div>
  476. <div id='quick-blackout' className='quick' style={{ display: 'none' }}></div>
  477. <div id='quick-logo' className='quick-brand' style={{ display: 'none' }}></div>
  478. <div id='hover-top' className='hover-row' style={{ display: 'none' }}></div>
  479. <div id='hover-bottom' className='hover-row' style={{ display: 'none' }}></div>
  480. <div id='call-to-action'>
  481. <div id='pause-overlay' style={{ display: 'none' }}>
  482. <div id='pause-icon'>
  483. {/* eslint-disable-next-line jsx-a11y/anchor-is-valid */}
  484. <a>
  485. <i className='icon icon-pause'></i>
  486. </a>
  487. </div>
  488. </div>
  489. <div id='interaction-modal'>
  490. <div id='interaction-modal-inner'>
  491. <div className='nav-icon'>
  492. <img src='images/pc_step1.png' className='icon' title='导览' data-page='1' alt='' />
  493. <div className='nav-help-button'>
  494. <div className='next-button nav-help-page' data-id='plus'></div>
  495. <div className='prev-button nav-help-page'></div>
  496. </div>
  497. </div>
  498. </div>
  499. </div>
  500. </div>
  501. <div id='tag-billboards' style={{ display: 'none' }}></div>
  502. </div>
  503. </div>
  504. )
  505. }
  506. const MemoA1home = React.memo(A1home)
  507. export default MemoA1home