unit.vue 1.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859
  1. <template>
  2. <div class="section unit">
  3. <div class="box">
  4. <div class="wwintrobox wwintrobox1">
  5. <div class="wwtitle">{{props.title}}</div>
  6. <div class="wwintro1">{{props.years}}</div>
  7. </div>
  8. <div class="wwmap hide">
  9. <img :src="request(`/img/map/${props.img}.webp`)/img/map/${}.webp" alt="" />
  10. </div>
  11. <div class="wwbox fadeIn">
  12. <img
  13. :src="request(`/img/webp/${props.img}.webp`)"
  14. alt=""
  15. style="transform: translateY(-13.9579px) translateX(40.2477px)"
  16. />
  17. </div>
  18. <div class="wwinfobox">
  19. <div class="wwinfo">陕西省考古研究院藏</div>
  20. <div class="wwinfo">
  21. 1991年陕西省长安区南里王村<br />贞观元年(627)窦皦墓出土
  22. </div>
  23. </div>
  24. </div>
  25. </div>
  26. </template>
  27. <script setup>
  28. // ts写法
  29. const props = withDefaults(defineProps<{
  30. title?: string, // 是否必传
  31. years?: string, // 是否必传
  32. position?: string, // 是否必传
  33. address?: string, // 是否必传
  34. img?: string, // 是否必传
  35. map?: string // 是否必传
  36. }>(), {
  37. title:'玉梁金宝钿带',
  38. years:'北朝至唐早期',
  39. address:'陕西省考古研究院藏',
  40. position:'1991年陕西省长安区南里王村',
  41. map: 'map-yljbxd',
  42. img: 'yljbdd-1',
  43. })
  44. </script>
  45. <style lang="scss" scoped>
  46. @import "/src/assets/style/index.css";
  47. .section {
  48. position: relative;
  49. position: relative;
  50. -webkit-box-sizing: border-box;
  51. -moz-box-sizing: border-box;
  52. box-sizing: border-box;
  53. background: no-repeat center/cover;
  54. justify-content: flex-start;
  55. }
  56. </style>