Model4.html 6.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252
  1. <!DOCTYPE html>
  2. <html lang="en">
  3. <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
  4. <meta name="viewport"
  5. content="width=device-width,initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=no">
  6. <link rel="shortcut icon" href="./img/favicon.ico" type="image/x-icon">
  7. <link rel="stylesheet" href="css/index.css">
  8. <script src="https://res.wx.qq.com/open/js/jweixin-1.4.0.js"></script>
  9. <head>
  10. <title>-</title>
  11. <script src="js/4dage.js"></script>
  12. <script src="./info.js"></script>
  13. <script>
  14. document.title = titleInfo
  15. </script>
  16. <style>
  17. html {
  18. overflow: hidden;
  19. }
  20. .outerImg {
  21. transition: all 1s;
  22. opacity: 1;
  23. position: absolute;
  24. z-index: 998;
  25. top: 0;
  26. left: 0;
  27. width: 100%;
  28. height: 100%;
  29. background-color: #1a1b20;
  30. }
  31. .outerImg img {
  32. position: absolute;
  33. width: 100%;
  34. height: 100%;
  35. object-fit: cover;
  36. }
  37. /* ---------------按钮和文字介绍------------- */
  38. body {
  39. user-select: none;
  40. }
  41. .topButn {
  42. opacity: 0;
  43. pointer-events: none;
  44. z-index: 999;
  45. position: absolute;
  46. top: 50px;
  47. left: 10px;
  48. }
  49. .topButn div {
  50. padding: 0 5px;
  51. margin-bottom: 10px;
  52. width: 100%;
  53. height: 40px;
  54. line-height: 40px;
  55. border-radius: 20px;
  56. font-size: 18px;
  57. color: #fff;
  58. cursor: pointer;
  59. text-align: center;
  60. /* background-color: #f2cd83; */
  61. background-color: #ccc;
  62. border-radius: 5px;
  63. }
  64. .con::-webkit-scrollbar {
  65. /*滚动条整体样式*/
  66. width: 3px;
  67. /*高宽分别对应横竖滚动条的尺寸*/
  68. height: 1px;
  69. }
  70. .con::-webkit-scrollbar-thumb {
  71. /*滚动条里面小方块*/
  72. border-radius: 10px;
  73. box-shadow: inset 0 0 5px rgba(0, 0, 0, 0.2);
  74. background: #f2cd83;
  75. }
  76. .con::-webkit-scrollbar-track {
  77. /*滚动条里面轨道*/
  78. box-shadow: inset 0 0 5px rgba(0, 0, 0, 0.2);
  79. border-radius: 10px;
  80. background: #ededed;
  81. }
  82. .txtOne {
  83. opacity: 0;
  84. pointer-events: none;
  85. padding: 30px 15px 30px 30px;
  86. z-index: 1000;
  87. position: absolute;
  88. top: 150px;
  89. left: 10px;
  90. background-image: url('./img/divBac.png');
  91. background-color: rgba(0, 0, 0, .6);
  92. background-size: 100% 100%;
  93. width: 400px;
  94. height: 500px;
  95. z-index: 9999;
  96. color: #a08742;
  97. }
  98. .txtOne .con {
  99. text-align: justify;
  100. padding-right: 28px;
  101. line-height: 30px;
  102. margin-bottom: 30px;
  103. overflow-y: auto;
  104. height: 100%;
  105. }
  106. .txtOne .con>h3 {
  107. margin-left: -5px;
  108. font-size: 18px;
  109. font-weight: 700;
  110. margin-bottom: 15px;
  111. }
  112. .txtOne .close {
  113. cursor: pointer;
  114. position: absolute;
  115. right: 24px;
  116. top: 20px;
  117. width: 20px;
  118. height: 20px;
  119. }
  120. .txtOne .close img {
  121. width: 100%;
  122. height: 100%;
  123. }
  124. /* 手机端的样式 */
  125. @media screen and (max-width: 600px) {
  126. .topButn {
  127. width: 220px;
  128. display: flex;
  129. justify-content: center;
  130. margin: 0;
  131. top: 5px;
  132. left: 50%;
  133. transform: translateX(-50%);
  134. pointer-events: auto;
  135. }
  136. .topButn div {
  137. width: 90px;
  138. font-size: 14px;
  139. background-color: #f2cd83;
  140. }
  141. .txtOne {
  142. display: none;
  143. box-sizing: border-box;
  144. width: 100vw;
  145. height: 100vh;
  146. top: 0;
  147. left: 0;
  148. transform: translate(0, 0);
  149. max-height: 100vh;
  150. color: #fff;
  151. }
  152. .txtOne .con {
  153. color: #fff;
  154. height: calc(100vh - 100px);
  155. }
  156. }
  157. </style>
  158. </head>
  159. <body>
  160. <!-- 新加的按钮 -->
  161. <div class="topButn">
  162. <div class="topButnOne">文物介绍</div>
  163. </div>
  164. <!-- 专家鉴定意见的文字 -->
  165. <div class="txtOne">
  166. <div class="close">
  167. <img src="./img/close.png" alt="">
  168. </div>
  169. <p class="con"></p>
  170. </div>
  171. <div class="outerImg">
  172. <img src="./img/bg.jpg" alt="">
  173. </div>
  174. <div id="ui">
  175. </div>
  176. <script src="js/jquery.js"></script>
  177. <script src="./txt.js"></script>
  178. <script>
  179. var number = getQueryVariable("m");
  180. if (spinInfo) window.autoRotate = true;
  181. fdage.embed('4dage/' + number + '.4dage', {
  182. width: 800,
  183. height: 600,
  184. autoStart: true,
  185. fullFrame: true,
  186. pagePreset: false
  187. });
  188. $('.outerImg img').attr('src', `./images/${number}.jpg`)
  189. // 获取文字介绍
  190. if (txtShow && txtObj[number]) {
  191. const btnDom = document.querySelector('.topButn')
  192. btnDom.style.opacity = 1
  193. // btnDom.style.pointerEvents = 'auto'
  194. const txtDom = document.querySelector('.txtOne')
  195. txtDom.style.opacity = 1
  196. txtDom.style.pointerEvents = 'auto'
  197. const txtButton = document.querySelector('.topButnOne')
  198. // 获取文本
  199. const txtInfo = txtObj[number] || '(空)'
  200. $('.txtOne .con').html(txtInfo)
  201. // 点击关闭
  202. $('.txtOne .close').click(() => {
  203. $('.txtOne').hide()
  204. btnDom.style.pointerEvents = 'auto'
  205. txtButton.style.backgroundColor = '#f2cd83'
  206. })
  207. $('.topButnOne').click(() => {
  208. $('.txtOne').show()
  209. btnDom.style.pointerEvents = 'none'
  210. txtButton.style.backgroundColor = '#ccc'
  211. })
  212. }
  213. </script>
  214. </body>
  215. </html>