@eturnity/eturnity_reusable_components 8.31.6-EPDM-16401.1-test → 8.31.6-EPDM-16401.4
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
|
@@ -161,19 +161,24 @@
|
|
|
161
161
|
},
|
|
162
162
|
computed: {
|
|
163
163
|
selectDropdownParent() {
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
164
|
+
// Search up the component hierarchy for the dropdown component
|
|
165
|
+
let parent = this.$parent
|
|
166
|
+
let iterations = 0
|
|
167
|
+
const maxIterations = 5
|
|
168
|
+
|
|
169
|
+
while (parent && iterations < maxIterations) {
|
|
170
|
+
if (parent.$attrs.class == 'rc-select-dropdown') {
|
|
171
|
+
return parent
|
|
172
|
+
}
|
|
173
|
+
parent = parent.$parent
|
|
174
|
+
iterations++
|
|
175
|
+
}
|
|
176
|
+
|
|
177
|
+
return this.$parent
|
|
167
178
|
},
|
|
168
179
|
},
|
|
169
180
|
methods: {
|
|
170
181
|
clickHandler(e) {
|
|
171
|
-
console.log(
|
|
172
|
-
'clicked:',
|
|
173
|
-
this.isDisabled,
|
|
174
|
-
!!this.$attrs?.onClick,
|
|
175
|
-
this.selectDropdownParent
|
|
176
|
-
)
|
|
177
182
|
if (this.isDisabled || !!this.$attrs?.onClick) {
|
|
178
183
|
// prevent emitter if the option is disabled
|
|
179
184
|
return
|