header.vue 4.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206
  1. <template>
  2. <div class="flex w-full h-[100px] title fixed top-0 left-0 bottom-0 z-20 bg-[#fff]"
  3. style="border-bottom: 1px solid #E1E1E1;">
  4. <div class="flex-[1]"></div>
  5. <div class="h-[100px] bg-[#fff] flex items-center justify-between w-[1200px]"
  6. style="border-bottom: 1px solid #E1E1E1;">
  7. <!-- 头部title -->
  8. <div class="flex items-center">
  9. <img src="~/public/favicon.ico" class="w-[50px] h-[50px] mr-[10px]" alt="">
  10. <div class="flex flex-col">
  11. <span class="text-[#333333] text-[24px] font-medium">惠融易客</span>
  12. <span class="text-[16px] font-light">
  13. HUIRONG CRM
  14. </span>
  15. </div>
  16. </div>
  17. <!-- 右边 -->
  18. <ul class='flex items-center'>
  19. <li v-for="i in headerTitle" :key="i.go" @mouseenter="mouseenterFn(i.go)" @mouseleave="mouseleaveFn"
  20. :class="headerClass == i.go ? 'text-[#1f4df5!important]' : ''" @click="titleRight(i.go)"
  21. class="pr-[70px] text-[#999999] cursor-pointer text-[18px]">
  22. {{ i.title }}
  23. </li>
  24. <li class="px-[16px] text-[#999999] font-medium" @click="loginBtn">
  25. <!-- <n-button type="info" class="bg-[#165DFF] text-[18px] w-[130px] h-[42px]" style="border-radius: 6px;" >
  26. 登录/注册
  27. </n-button> -->
  28. <van-button type="primary"> 登录/注册</van-button>
  29. </li>
  30. </ul>
  31. </div>
  32. <div class="flex-[1]">
  33. </div>
  34. </div>
  35. </template>
  36. <script lang="ts" setup>
  37. const headerTitle = reactive([
  38. {
  39. title: '首页',
  40. go: 'home'
  41. },
  42. {
  43. title: '解决方案',
  44. go: 'solution'
  45. },
  46. {
  47. title: '联系我们',
  48. go: 'contact'
  49. },
  50. {
  51. title: '申请试用',
  52. go: 'probation'
  53. }
  54. ]
  55. )
  56. const headerClass = ref<string>('')
  57. const mouseenterFn = (i: string) => {
  58. // console.log('mouseenterFn')
  59. headerClass.value = i
  60. }
  61. const mouseleaveFn = () => {
  62. headerClass.value = ''
  63. }
  64. const titleRight = (i: string) => {
  65. if (i == 'probation') {
  66. // btn()
  67. return
  68. }
  69. document.querySelector('#' + i)?.scrollIntoView()
  70. }
  71. const loginBtn = () => {
  72. console.log('跳转')
  73. // window.location.replace('http://p.daicrm.com/#/login')
  74. window.open('http://p.daicrm.com/#/login')
  75. // window.location.href('http://p.daicrm.com/#/login')
  76. }
  77. </script>
  78. <style scoped lang="scss">
  79. .num-item {
  80. border-radius: 4px;
  81. width: 50px;
  82. height: 60px;
  83. margin: 10px;
  84. background: linear-gradient(0deg, rgb(255, 255, 255) 0%, rgba(244, 244, 255, 0.961) 50%, rgb(255, 255, 255) 100%);
  85. font-size: 36px;
  86. color: #fff;
  87. }
  88. p {
  89. color: var(--link-color)
  90. }
  91. img {
  92. height: 100%;
  93. }
  94. .text1 {
  95. display: inline-block;
  96. white-space: nowrap;
  97. width: 300px;
  98. overflow: hidden;
  99. text-overflow: ellipsis;
  100. }
  101. ::v-deep(.n-button) {
  102. border-radius: 4px !important;
  103. }
  104. // 框
  105. ::v-deep(.n-card-header__main) {
  106. flex: inherit !important;
  107. margin: 0 auto !important;
  108. }
  109. ::v-deep(.n-card-header) {
  110. padding: 0 !important;
  111. padding-top: 50px !important;
  112. }
  113. ::v-deep(.n-card__content) {
  114. flex: inherit;
  115. margin: 0 auto;
  116. margin-bottom: 50px !important;
  117. }
  118. ::v-deep(.n-form-item-label) {
  119. display: none !important;
  120. }
  121. ::v-deep(.n-form-item) {
  122. --n-label-height: 10px !important;
  123. }
  124. ::v-deep(.n-carousel__dots) {
  125. display: none !important;
  126. }
  127. ::v-deep(.n-input__input-el) {
  128. height: 55px !important;
  129. line-height: 55px !important;
  130. }
  131. ::v-deep(.n-card-header__main) {
  132. font-size: 30px;
  133. }
  134. // 按钮样式
  135. ::v-deep(.van-button--normal) {
  136. border-radius: 6px;
  137. background: #0047FF;
  138. border: 0;
  139. height: 67px;
  140. }
  141. .trial ::v-deep(.van-button--normal) {
  142. border-radius: 6px;
  143. background: #0047FF;
  144. border: 0;
  145. width: 400px;
  146. height: 67px;
  147. }
  148. ::v-deep(.van-button__content) {
  149. font-size: 24px;
  150. }
  151. .title ::v-deep(.van-button--normal) {
  152. border-radius: 6px;
  153. background: #0047FF;
  154. border: 0;
  155. width: 130px;
  156. height: 42px;
  157. }
  158. .title ::v-deep(.van-button__content) {
  159. font-size: 16px;
  160. }
  161. .message ::v-deep(.van-button--normal) {
  162. border-radius: 6px;
  163. background: #0047FF;
  164. border: 0;
  165. width: 130px;
  166. height: 42px;
  167. }
  168. .message ::v-deep(.van-button__content) {
  169. font-size: 16px;
  170. }
  171. .modalCss ::v-deep(.n-button) {
  172. border-radius: 4px !important;
  173. height: 55px !important;
  174. }
  175. .submission ::v-deep(.n-button) {
  176. width: 700px !important;
  177. }
  178. </style>