refactor: #7090 for PickList
parent
78e1d46340
commit
ba5cad39f5
|
@ -168,7 +168,6 @@
|
||||||
<script>
|
<script>
|
||||||
import { find, scrollInView, setAttribute } from '@primeuix/utils/dom';
|
import { find, scrollInView, setAttribute } from '@primeuix/utils/dom';
|
||||||
import { findIndexInList, isEmpty } from '@primeuix/utils/object';
|
import { findIndexInList, isEmpty } from '@primeuix/utils/object';
|
||||||
import { UniqueComponentId } from '@primevue/core/utils';
|
|
||||||
import AngleDoubleDownIcon from '@primevue/icons/angledoubledown';
|
import AngleDoubleDownIcon from '@primevue/icons/angledoubledown';
|
||||||
import AngleDoubleLeftIcon from '@primevue/icons/angledoubleleft';
|
import AngleDoubleLeftIcon from '@primevue/icons/angledoubleleft';
|
||||||
import AngleDoubleRightIcon from '@primevue/icons/angledoubleright';
|
import AngleDoubleRightIcon from '@primevue/icons/angledoubleright';
|
||||||
|
@ -194,15 +193,11 @@ export default {
|
||||||
mediaChangeListener: null,
|
mediaChangeListener: null,
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
id: this.$attrs.id,
|
|
||||||
d_selection: this.selection,
|
d_selection: this.selection,
|
||||||
viewChanged: false
|
viewChanged: false
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
watch: {
|
watch: {
|
||||||
'$attrs.id': function (newValue) {
|
|
||||||
this.id = newValue || UniqueComponentId();
|
|
||||||
},
|
|
||||||
selection(newValue) {
|
selection(newValue) {
|
||||||
this.d_selection = newValue;
|
this.d_selection = newValue;
|
||||||
},
|
},
|
||||||
|
@ -223,8 +218,6 @@ export default {
|
||||||
this.destroyMedia();
|
this.destroyMedia();
|
||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
this.id = this.id || UniqueComponentId();
|
|
||||||
|
|
||||||
if (this.responsive) {
|
if (this.responsive) {
|
||||||
this.createStyle();
|
this.createStyle();
|
||||||
this.initMedia();
|
this.initMedia();
|
||||||
|
@ -597,10 +590,10 @@ export default {
|
||||||
},
|
},
|
||||||
computed: {
|
computed: {
|
||||||
idSource() {
|
idSource() {
|
||||||
return `${this.id}_source`;
|
return `${this.$id}_source`;
|
||||||
},
|
},
|
||||||
idTarget() {
|
idTarget() {
|
||||||
return `${this.id}_target`;
|
return `${this.$id}_target`;
|
||||||
},
|
},
|
||||||
sourceList() {
|
sourceList() {
|
||||||
return this.modelValue && this.modelValue[0] ? this.modelValue[0] : null;
|
return this.modelValue && this.modelValue[0] ? this.modelValue[0] : null;
|
||||||
|
|
Loading…
Reference in New Issue