leftSkeleton.vue 770 B

123456789101112131415161718192021222324252627282930313233343536373839404142434445
  1. <template>
  2. <div class="imgEditor">
  3. <slot></slot>
  4. <div class="btngroup">
  5. <el-button type="primary" round @click.stop="save">保 存</el-button>
  6. <el-button type="danger" round @click.stop="deleteFunc">删 除</el-button>
  7. </div>
  8. </div>
  9. </template>
  10. <script setup>
  11. import { defineEmits } from 'vue';
  12. const emits = defineEmits(['save', 'deleteFunc']);
  13. const save = () => {
  14. emits('save');
  15. };
  16. const deleteFunc = () => {
  17. emits('deleteFunc');
  18. }
  19. </script>
  20. <style>
  21. .imgEditor {
  22. width: 100%;
  23. height: 100%;
  24. padding: 1em;
  25. position: relative;
  26. }
  27. .btngroup {
  28. text-align: center;
  29. padding: 0.5em 0;
  30. position: absolute;
  31. bottom: 1.5em;
  32. left: 0;
  33. width: 100%;
  34. z-index: 1;
  35. }
  36. .btngroup .el-button {
  37. width: 8em;
  38. }
  39. </style>