About.vue 6.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288
  1. <template>
  2. <div class="about" style="overflow:hidden">
  3. <div class="imgarea">
  4. <img :src="img1" alt class="widthimg" />
  5. <div class="imgtext">
  6. <h1>专注</h1>
  7. <div class="righttext">
  8. <h2>互联网项目技术服务</h2>
  9. </div>
  10. </div>
  11. </div>
  12. <div class="aboutus">
  13. <div class="head">
  14. <p>关于我们</p>
  15. <hr />
  16. </div>
  17. <div class="content">
  18. <div class="leftmenu" :class="navBarFixed == true ? 'navBarWrap' :''">
  19. <img :src="img2" alt />
  20. <div class="leftbutton">
  21. <a href="#block1">
  22. <button>公司概述</button>
  23. </a>
  24. <a href="#block2">
  25. <button>发展历程</button>
  26. </a>
  27. <a href="#block3">
  28. <button>公司荣誉</button>
  29. </a>
  30. </div>
  31. </div>
  32. <div class="rightcontent">
  33. <div class="block1" id="block1">
  34. <div class="row">
  35. <img :src="img3" />
  36. <div class="imgright">
  37. <div class="headline">
  38. <p>西安芝麻开花网络科技有限公司</p>
  39. </div>
  40. <div>
  41. <ul>
  42. <li v-for="(item,index) in list" :key="index">
  43. <p class="listtext">{{item}}</p>
  44. </li>
  45. </ul>
  46. </div>
  47. </div>
  48. </div>
  49. <div class="imgrow">
  50. <img :src="img4" />
  51. <img :src="img5" />
  52. <img :src="img6" />
  53. </div>
  54. </div>
  55. <div class="block2" id="block2">
  56. <div class="headline short">
  57. <p>发展历程</p>
  58. </div>
  59. <img :src="img7" alt />
  60. </div>
  61. <div class="block3" id="block3">
  62. <div class="headline short">
  63. <p>公司荣誉</p>
  64. </div>
  65. <img :src="img8" alt />
  66. <img :src="img9" alt />
  67. <img :src="img10" alt />
  68. </div>
  69. </div>
  70. </div>
  71. </div>
  72. </div>
  73. </template>
  74. <script>
  75. import img1 from "./images/u431.jpg";
  76. import img2 from "./images/20190830132652.png";
  77. import img3 from "./images/u472.png";
  78. import img4 from "./images/u473.png";
  79. import img5 from "./images/u474.png";
  80. import img6 from "./images/u475.png";
  81. import img7 from "./images/u462.png";
  82. import img8 from "./images/u466.jpg";
  83. import img9 from "./images/u467.jpg";
  84. import img10 from "./images/u468.jpg";
  85. export default {
  86. name: "About",
  87. // props: {
  88. // msg: String
  89. // }
  90. data() {
  91. return {
  92. img1: img1,
  93. img2: img2,
  94. img3: img3,
  95. img4: img4,
  96. img5: img5,
  97. img6: img6,
  98. img7: img7,
  99. img8: img8,
  100. img9: img9,
  101. img10: img10,
  102. navBarFixed: false,
  103. list: [
  104. "西安芝麻开花网络科技有限公司成立于2016年,多年来专注于互联网技术开发和数据服务。",
  105. "我们的服务分为四大部分:为创业企业提供互联网技术支持;为传统企业互联网转型提供专业的全程解决方案;为政府事业单位提供信息化策略支持,为硬件技术企业提供互联网技术结合方案。",
  106. "公司采用全职+兼职+实习的管理模式,办公环境良好,位于西安曲江新区顶级写字楼。"
  107. ]
  108. };
  109. },
  110. mounted() {
  111. // 事件监听滚动条
  112. window.addEventListener("scroll", this.watchScroll);
  113. },
  114. methods: {
  115. watchScroll() {
  116. var scrollTop =
  117. window.pageYOffset ||
  118. document.documentElement.scrollTop ||
  119. document.body.scrollTop;
  120. // 当滚动超过 50 时,实现吸顶效果
  121. if (scrollTop > 549) {
  122. this.navBarFixed = true;
  123. } else {
  124. this.navBarFixed = false;
  125. }
  126. }
  127. }
  128. };
  129. </script>
  130. <style>
  131. .navBarWrap {
  132. position: fixed;
  133. top: 0;
  134. z-index: 999;
  135. }
  136. .imgarea {
  137. position: relative;
  138. width: 100%;
  139. height: 400px;
  140. }
  141. .block1,
  142. .block2,
  143. .block3 {
  144. padding-left: 30px;
  145. padding-top: 30px;
  146. padding-right: 30px;
  147. padding-bottom: 30px;
  148. border: 1px solid rgb(242, 242, 242);
  149. margin-bottom: 30px;
  150. }
  151. .short {
  152. width: 150px;
  153. margin: auto;
  154. }
  155. .headline {
  156. border-bottom: 1px solid rgb(0, 102, 153);
  157. }
  158. .listtext {
  159. font-size: 16px;
  160. color: rgb(154, 154, 154);
  161. }
  162. .headline p {
  163. color: rgb(0, 102, 153);
  164. font-weight: 600;
  165. margin-top: 0px;
  166. margin-bottom: 15px;
  167. text-align: center;
  168. }
  169. .imgright {
  170. margin-top: 20px;
  171. margin-left: 20px;
  172. width: 50%;
  173. }
  174. .block3 img {
  175. display: block;
  176. width: 450px;
  177. height: 300px;
  178. text-align: center;
  179. margin: auto;
  180. }
  181. .block2 img {
  182. margin: auto;
  183. display: block;
  184. }
  185. .block2 img,
  186. .block3 img {
  187. margin-top: 25px;
  188. }
  189. .content {
  190. display: flex;
  191. flex-direction: row;
  192. }
  193. .widthimg {
  194. display: flex;
  195. position: absolute;
  196. width: 100%;
  197. height: 100%;
  198. }
  199. .head p {
  200. width: 90px;
  201. padding-left: 18px;
  202. display: flex;
  203. justify-content: flex-start;
  204. border-bottom: 1px solid rgb(121, 121, 121);
  205. margin-bottom: -7px;
  206. }
  207. .imgrow {
  208. margin-top: 30px;
  209. display: flex;
  210. flex-direction: row;
  211. justify-content: space-between;
  212. }
  213. .row {
  214. display: flex;
  215. flex-direction: row;
  216. justify-content: space-between;
  217. }
  218. .row img {
  219. width: 322px;
  220. height: 310px;
  221. }
  222. .leftmenu {
  223. width: 20%;
  224. /* margin-left: 20px; */
  225. margin-top: 60px;
  226. display: flex;
  227. flex-direction: row;
  228. justify-content: space-evenly;
  229. }
  230. .rightcontent {
  231. padding-left: 50px;
  232. margin-top: 60px;
  233. margin-left: 60px;
  234. width: 50%;
  235. position: absolute;
  236. margin-left: 20%;
  237. }
  238. .leftmenu img {
  239. height: 300px;
  240. }
  241. .leftbutton {
  242. display: flex;
  243. flex-direction: column;
  244. justify-content: space-between;
  245. }
  246. p {
  247. font-size: 21px;
  248. padding-left: 10px;
  249. padding-right: 10px;
  250. }
  251. .imgrow img {
  252. width: 200px;
  253. height: 250px;
  254. }
  255. .imgtext {
  256. position: absolute;
  257. text-align: center;
  258. vertical-align: middle;
  259. width: 100%;
  260. height: 100%;
  261. display: flex;
  262. flex-direction: column;
  263. justify-content: center;
  264. }
  265. button {
  266. margin-top: 10px;
  267. }
  268. h1 {
  269. color: rgb(0, 102, 255);
  270. font-size: 50px;
  271. }
  272. h2 {
  273. color: rgb(22, 102, 255);
  274. font-weight: 100;
  275. font-size: 40px;
  276. }
  277. .righttext {
  278. padding-left: 400px;
  279. margin-top: -32px;
  280. }
  281. hr {
  282. color: rgb(215, 215, 215);
  283. }
  284. </style>