title.vue 1.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657
  1. <template>
  2. <div class="relative">
  3. <div class="flex">
  4. <div class="_1"></div>
  5. <div class="_2"></div>
  6. <div class="_3"></div>
  7. <div class="_4"></div>
  8. </div>
  9. <div style="height: 44rpx; background: #fc5b20; position: relative; top: -1px"></div>
  10. <div class="absolute left-2 top-2 bold italic text-white fs14">{{ title }}</div>
  11. </div>
  12. </template>
  13. <script>
  14. export default {
  15. props: {
  16. title: '',
  17. },
  18. }
  19. </script>
  20. <style>
  21. ._1 {
  22. width: 60rpx;
  23. height: 24rpx;
  24. background-color: #fc5b20;
  25. border-top-left-radius: 18rpx;
  26. }
  27. ._2 {
  28. transform: skew(45deg, 0deg);
  29. width: 140rpx;
  30. height: 24rpx;
  31. background-color: #fc5b20;
  32. border-radius: 10rpx;
  33. border-bottom-right-radius: 0;
  34. border-top-right-radius: 0;
  35. position: relative;
  36. left: -30rpx;
  37. }
  38. ._3 {
  39. transform: skew(45deg, 0deg);
  40. width: 140rpx;
  41. height: 24rpx;
  42. background-color: #000;
  43. border-radius: 10rpx;
  44. position: relative;
  45. border-bottom-left-radius: 0;
  46. border-top-left-radius: 0;
  47. left: -30rpx;
  48. }
  49. ._4 {
  50. width: 60rpx;
  51. height: 24rpx;
  52. background-color: #000;
  53. border-top-right-radius: 18rpx;
  54. position: relative;
  55. left: -60rpx;
  56. }
  57. </style>