style3.php 1.5 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253
  1. <template id="title-block-style3">
  2. <div class="title-block-style3" flex="cross:center">
  3. <!-- 图片位置 -->
  4. <div class="title-block-line" :style="{background: computedStyle.titleColor}"></div>
  5. <div class="title-block-icon cust-icon icon-sijiaoxing" style="margin-left: 4px;"></div>
  6. <div class="title" :style="{color: computedStyle.titleColor}">{{title}}</div>
  7. <div class="title-block-icon cust-icon icon-sijiaoxing" style="margin-right: 4px;"></div>
  8. <div class="title-block-line" :style="{background: computedStyle.titleColor}"></div>
  9. </div>
  10. </template>
  11. <script>
  12. Vue.component('title-block-style3', {
  13. name: "title-block-style3",
  14. props: {
  15. title: {
  16. type: String,
  17. default () {
  18. return "标题"
  19. }
  20. },
  21. computedStyle: {
  22. type: Object,
  23. default () {
  24. return {}
  25. }
  26. }
  27. },
  28. template: '#title-block-style3',
  29. });
  30. </script>
  31. <style scoped lang="scss">
  32. .title-block-style3 {
  33. height: 33px;
  34. justify-content: center;
  35. .title-block-line {
  36. width: 29px;
  37. height: 1px;
  38. background-color: #EB3534;
  39. }
  40. .title-block-icon {
  41. font-size: 10px;
  42. transform: scale(0.8, 0.8);
  43. color: #EB3534;
  44. }
  45. .title {
  46. margin: 0 10px;
  47. font-size: 14px;
  48. }
  49. }
  50. </style>