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.
 
 
 
 
 
 

79 lines
1.6 KiB

  1. <template>
  2. <view class="customlist-banner-action">
  3. <view
  4. v-if="showButton"
  5. @click="$emit('join')"
  6. class="customlist-banner-action-btn line-yellow text-sm"
  7. style="border: currentColor 1px solid"
  8. >
  9. <l-icon :type="icontype" />
  10. {{ buttonText }}
  11. </view>
  12. <view
  13. v-if="showDelete"
  14. @click="$emit('delete')"
  15. class="customlist-banner-action-btn line-red text-sm"
  16. style="border: currentColor 1px solid"
  17. >
  18. <l-icon type="delete" />
  19. 删除
  20. </view>
  21. <view
  22. v-if="showEdit"
  23. @click="$emit('edit')"
  24. class="customlist-banner-action-btn line-blue text-sm"
  25. style="border: currentColor 1px solid"
  26. >
  27. <l-icon type="edit" />
  28. {{ editText ?editText:"编辑" }}
  29. </view>
  30. <view
  31. v-if="!hideView"
  32. @click="$emit('view')"
  33. class="customlist-banner-action-btn line-blue text-sm"
  34. style="border: currentColor 1px solid; min-width: 160rpx"
  35. >
  36. 查看
  37. <l-icon type="right" />
  38. </view>
  39. </view>
  40. </template>
  41. <script>
  42. export default {
  43. name: "l-customlist-banner",
  44. props: {
  45. showDelete: {},
  46. showEdit: {},
  47. showButton: {},
  48. buttonText: "",
  49. icontype: "",
  50. editText:"",
  51. hideView:{},
  52. },
  53. };
  54. </script>
  55. <style lang="less" scoped>
  56. .customlist-banner-action {
  57. margin-top: 20rpx;
  58. text-align: right;
  59. .customlist-banner-action-btn {
  60. display: inline-block;
  61. padding: 4px 6px;
  62. margin: 0 3px;
  63. border-radius: 3px;
  64. text-align: center;
  65. }
  66. }
  67. </style>
  68. <style lang="less">
  69. :host {
  70. display: block;
  71. }
  72. </style>