CameraEditshared.vue 1.7 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182
  1. <template>
  2. <el-card v-if="props.modelValue" class="pop-card">
  3. <template #header>
  4. <div class="flex justify-between items-center pop-head">
  5. <span class="pop-head-name">编辑相机</span>
  6. <el-icon :size="16" class="mr-3" @click="updateValue"><Close /></el-icon>
  7. </div>
  8. </template>
  9. <div class="pop-content flex justify-center items-center">
  10. <EditSharedCamera @close-edit="updateValue" :form-data="props.editData" />
  11. </div>
  12. </el-card>
  13. </template>
  14. <script setup lang="ts">
  15. import { Close } from '@element-plus/icons-vue';
  16. import EditSharedCamera from './EditSharedCamera.vue';
  17. import { CameraShareType } from '@/api/camera/camera-share';
  18. const props = defineProps<{ modelValue: boolean; editData: CameraShareType }>();
  19. const emits = defineEmits(['update:modelValue']);
  20. const updateValue = () => {
  21. emits('update:modelValue', false as boolean);
  22. };
  23. </script>
  24. <style scoped lang="scss">
  25. .pop-card {
  26. position: relative;
  27. margin-left: 21px !important;
  28. }
  29. .pop-head {
  30. height: 56px;
  31. &-name {
  32. margin-left: 24px;
  33. font-size: 16px;
  34. font-weight: 500;
  35. color: #252525;
  36. }
  37. &-tabs {
  38. margin-top: 18px;
  39. :first-child {
  40. border-radius: 8px 0px 0px 0px;
  41. }
  42. :last-child {
  43. border-radius: 0px 8px 0px 0px;
  44. }
  45. }
  46. }
  47. .tab-item {
  48. width: 188px;
  49. height: 38px;
  50. background: #fafafa;
  51. border: 1px solid #d9d9d9;
  52. cursor: pointer;
  53. &-active {
  54. background: #e2eefe;
  55. border: 1px solid #1890ff;
  56. }
  57. }
  58. .pop-content {
  59. height: 566px;
  60. }
  61. :deep(.el-card__header) {
  62. padding: 0;
  63. }
  64. :deep(.el-card__body) {
  65. padding: 0;
  66. }
  67. </style>