多租户商城-商户端
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

85 lines
2.0 KiB

2 years ago
1 year ago
2 years ago
1 year ago
2 years ago
1 year ago
2 years ago
  1. <template>
  2. <div class="text warp" :class="['text-'+componentContent.textPos,{'show-more':componentContent.showMore},'terminal' + terminal]" :style="{backgroundColor:componentContent.bgColor}">
  3. <div class="line-warp" :class="{'borderBot':componentContent.showLine}">
  4. <h3 class="h3" :style="{fontSize:componentContent.fontSizeNum+'px',fontWeight:componentContent.textFontW,color:componentContent.titColor}">{{componentContent.title}}</h3>
  5. <p class="p" :style="{fontSize:componentContent.describeSizeNum+'px',fontWeight:componentContent.describeFontW,color:componentContent.describeColor}">{{componentContent.describe}}</p>
  6. <div class="btn-more" v-show="componentContent.showMore" :class="'style'+componentContent.styleValue" @click="jumpLink(item.linkObj)"><span>{{ $t('common.more') }}</span><i class="iconfont icon-arrow-right"></i></div>
  7. </div>
  8. </div>
  9. </template>
  10. <script>
  11. export default {
  12. name: 'textComponent',
  13. data () {
  14. return {
  15. }
  16. },
  17. props: {
  18. terminal: {
  19. type: Number,
  20. default: 4
  21. },
  22. componentContent: {
  23. type: Object
  24. }
  25. }
  26. }
  27. </script>
  28. <style lang="scss" scoped>
  29. .text{
  30. padding: 0px 20px;
  31. position: relative;
  32. .line-warp{
  33. padding: 10px 0;
  34. display: flex;
  35. flex-direction: row;
  36. flex-wrap: nowrap;
  37. align-content: center;
  38. justify-content: flex-start;
  39. align-items: center;
  40. }
  41. .borderBot{
  42. border-bottom: 1px solid #cccc;
  43. }
  44. .h3{
  45. line-height: 1.5;
  46. flex:1;
  47. }
  48. .p{
  49. line-height: 1.5;
  50. margin-top: 5px;
  51. }
  52. .style1{
  53. }
  54. .style2{
  55. .iconfont{
  56. display: none;
  57. }
  58. }
  59. .style3{
  60. span{
  61. display: none;
  62. }
  63. }
  64. &.text-left{
  65. text-align: left;
  66. &.show-more{
  67. position: relative;
  68. padding-right: 20px;
  69. .btn-more{
  70. position: absolute;
  71. right: 0;
  72. }
  73. }
  74. }
  75. &.text-center{
  76. text-align: center;
  77. }
  78. &.text-right{
  79. text-align: right;
  80. }
  81. }
  82. </style>