polarvo-layout 1.0.63 → 1.0.64
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
|
@@ -43,8 +43,9 @@
|
|
|
43
43
|
:rootId="item.id"
|
|
44
44
|
:ref="setRef"
|
|
45
45
|
v-bind="item"
|
|
46
|
+
:isHovable="isHovable"
|
|
46
47
|
class="hover:opacity-80"
|
|
47
|
-
:class="activeEditMode ? `pointer-events-auto ` : `pointer-events-none`"
|
|
48
|
+
:class="activeEditMode || isHovable ? `pointer-events-auto ` : `pointer-events-none`"
|
|
48
49
|
@set:defaultStyle="setDefaultStyle"
|
|
49
50
|
/>
|
|
50
51
|
</div>
|
|
@@ -59,6 +60,7 @@ const props = defineProps({
|
|
|
59
60
|
item: { type: Object, required: true },
|
|
60
61
|
polarvo: { type: Object, required: true },
|
|
61
62
|
sectionKey: { type: String, required: true },
|
|
63
|
+
isHovable: { type: Boolean, required: true },
|
|
62
64
|
});
|
|
63
65
|
|
|
64
66
|
const { activeId, handles, activeElement } = toRefs(props.polarvo.freeDrop.state);
|
|
@@ -6,6 +6,7 @@
|
|
|
6
6
|
:item="item"
|
|
7
7
|
:polarvo="props.polarvo"
|
|
8
8
|
:sectionKey="props.sectionKey"
|
|
9
|
+
:isHovable="isHovable(item)"
|
|
9
10
|
></FreeItem>
|
|
10
11
|
|
|
11
12
|
<!-- 오버레이 -->
|
|
@@ -68,6 +69,11 @@ const filteredElements = computed(() => {
|
|
|
68
69
|
const selectedElement = inject('selectedElement');
|
|
69
70
|
const activeEditMode = inject('activeEditMode');
|
|
70
71
|
|
|
72
|
+
const isHovable = (item) => {
|
|
73
|
+
if (!item || props.preview) return true;
|
|
74
|
+
return activeElement.value?.id === item.id && ['chart'].includes(item.type);
|
|
75
|
+
};
|
|
76
|
+
|
|
71
77
|
let _isElementSwitching = false;
|
|
72
78
|
import { omit, cloneDeep } from 'lodash-es';
|
|
73
79
|
|
|
@@ -79,7 +85,7 @@ watch(
|
|
|
79
85
|
if (newId && activeElement.value?.section !== props.sectionKey) return;
|
|
80
86
|
|
|
81
87
|
if (!newId) {
|
|
82
|
-
console.l
|
|
88
|
+
console.l;
|
|
83
89
|
setActiveDesign(null);
|
|
84
90
|
setActiveMenu(null);
|
|
85
91
|
}
|
|
@@ -41,11 +41,11 @@
|
|
|
41
41
|
:rootId="item.id"
|
|
42
42
|
:ref="setRef"
|
|
43
43
|
v-bind="item"
|
|
44
|
+
:isHovable="isHovable"
|
|
44
45
|
class="hover:opacity-80"
|
|
45
|
-
:class="activeEditMode ? `pointer-events-auto ` : `pointer-events-none`"
|
|
46
|
-
|
|
46
|
+
:class="activeEditMode || isHovable ? `pointer-events-auto ` : `pointer-events-none`"
|
|
47
|
+
@set:defaultStyle="setDefaultStyle"
|
|
47
48
|
/>
|
|
48
|
-
|
|
49
49
|
<!-- 오버레이 -->
|
|
50
50
|
<div v-if="activeEditMode && item.id !== activeId" class="absolute inset-0 bg-black opacity-50 z-30"></div>
|
|
51
51
|
</template>
|
|
@@ -69,6 +69,7 @@ const props = defineProps({
|
|
|
69
69
|
item: { type: Object, required: true },
|
|
70
70
|
polarvo: { type: Object, required: true },
|
|
71
71
|
sectionKey: { type: String, required: true },
|
|
72
|
+
isHovable: { type: Boolean, required: true },
|
|
72
73
|
});
|
|
73
74
|
|
|
74
75
|
const { activeId } = toRefs(props.polarvo.gridDrop.state);
|
|
@@ -6,6 +6,7 @@
|
|
|
6
6
|
:item="item"
|
|
7
7
|
:polarvo="props.polarvo"
|
|
8
8
|
:sectionKey="props.sectionKey"
|
|
9
|
+
:isHovable="isHovable(item)"
|
|
9
10
|
></GridItem>
|
|
10
11
|
|
|
11
12
|
<!-- 행 크기 조절 -->
|
|
@@ -107,6 +108,11 @@ const { activeDesign } = toRefs(props.polarvo.display.state);
|
|
|
107
108
|
const selectedElement = inject('selectedElement');
|
|
108
109
|
const activeEditMode = inject('activeEditMode');
|
|
109
110
|
|
|
111
|
+
const isHovable = (item) => {
|
|
112
|
+
if (!item || props.preview) return true;
|
|
113
|
+
return activeElement.value?.id === item.id && ['chart'].includes(item.type);
|
|
114
|
+
};
|
|
115
|
+
|
|
110
116
|
import { omit, cloneDeep, debounce } from 'lodash-es';
|
|
111
117
|
|
|
112
118
|
const gridColumns = ref(3); // 동적으로 계산
|