Remove .p-unselectable-text

This commit is contained in:
tugcekucukoglu 2024-05-13 17:26:45 +03:00
parent d06ef16b81
commit 4455d6ec59
5 changed files with 10 additions and 13 deletions

View file

@ -1231,7 +1231,7 @@ export default {
let containerLeft = DomHandler.getOffset(this.$el).left;
this.$el.setAttribute('data-p-unselectable-text', 'true');
!this.isUnstyled && DomHandler.addClass(this.$el, 'p-unselectable-text');
!this.isUnstyled && DomHandler.addStyles(this.$el, { 'user-select': 'none' });
this.$refs.resizeHelper.style.height = this.$el.offsetHeight + 'px';
this.$refs.resizeHelper.style.top = 0 + 'px';
this.$refs.resizeHelper.style.left = event.pageX - containerLeft + this.$el.scrollLeft + 'px';
@ -1281,7 +1281,7 @@ export default {
this.$refs.resizeHelper.style.display = 'none';
this.resizeColumn = null;
this.$el.removeAttribute('data-p-unselectable-text');
!this.isUnstyled && DomHandler.removeClass(this.$el, 'p-unselectable-text');
!this.isUnstyled && (this.$el.style['user-select'] = '');
this.unbindColumnResizeEvents();