mirror of
https://github.com/kuaifan/dootask.git
synced 2026-03-17 19:23:26 +00:00
no message
This commit is contained in:
parent
834bb28100
commit
82d6f0b533
@ -45,6 +45,12 @@ export default {
|
|||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
|
||||||
|
watch: {
|
||||||
|
show(s) {
|
||||||
|
this.$store.state.touchBackInProgress = s;
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
methods: {
|
methods: {
|
||||||
getXY(event) {
|
getXY(event) {
|
||||||
let touch = event.touches[0]
|
let touch = event.touches[0]
|
||||||
|
|||||||
@ -1,5 +1,5 @@
|
|||||||
<template>
|
<template>
|
||||||
<div class="chat-input-box" :class="boxClass">
|
<div class="chat-input-box" :class="boxClass" v-clickoutside="hidePopover">
|
||||||
<div class="chat-input-wrapper" @click.stop="focus">
|
<div class="chat-input-wrapper" @click.stop="focus">
|
||||||
<!-- 输入框 -->
|
<!-- 输入框 -->
|
||||||
<div
|
<div
|
||||||
@ -110,11 +110,12 @@ import "quill-mention-hi";
|
|||||||
import ChatEmoji from "./emoji";
|
import ChatEmoji from "./emoji";
|
||||||
import touchmouse from "../../../../directives/touchmouse";
|
import touchmouse from "../../../../directives/touchmouse";
|
||||||
import TransferDom from "../../../../directives/transfer-dom";
|
import TransferDom from "../../../../directives/transfer-dom";
|
||||||
|
import clickoutside from "../../../../directives/clickoutside";
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: 'ChatInput',
|
name: 'ChatInput',
|
||||||
components: {ChatEmoji},
|
components: {ChatEmoji},
|
||||||
directives: {touchmouse, TransferDom},
|
directives: {touchmouse, TransferDom, clickoutside},
|
||||||
props: {
|
props: {
|
||||||
dialogId: {
|
dialogId: {
|
||||||
type: Number,
|
type: Number,
|
||||||
@ -429,6 +430,9 @@ export default {
|
|||||||
|
|
||||||
// Mark model as touched if editor lost focus
|
// Mark model as touched if editor lost focus
|
||||||
this.quill.on('selection-change', range => {
|
this.quill.on('selection-change', range => {
|
||||||
|
if (this.timerScroll) {
|
||||||
|
clearInterval(this.timerScroll);
|
||||||
|
}
|
||||||
if (!range) {
|
if (!range) {
|
||||||
this.$emit('on-blur', this.quill)
|
this.$emit('on-blur', this.quill)
|
||||||
} else {
|
} else {
|
||||||
@ -438,11 +442,13 @@ export default {
|
|||||||
// ios11.0-11.3 对scrollTop及scrolIntoView解释有bug
|
// ios11.0-11.3 对scrollTop及scrolIntoView解释有bug
|
||||||
// 直接执行会导致输入框滚到底部被遮挡
|
// 直接执行会导致输入框滚到底部被遮挡
|
||||||
} else {
|
} else {
|
||||||
for (let i = 1; i <= 5; i++) {
|
this.timerScroll = setInterval(() => {
|
||||||
setTimeout(() => {
|
if (this.quill.hasFocus()) {
|
||||||
$A.scrollToView(this.$refs.editor, true)
|
$A.scrollToView(this.$refs.editor, true)
|
||||||
}, 200 * i);
|
} else {
|
||||||
|
clearInterval(this.timerScroll);
|
||||||
}
|
}
|
||||||
|
}, 200);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|||||||
@ -221,19 +221,19 @@ export default {
|
|||||||
dialogDrag: false,
|
dialogDrag: false,
|
||||||
groupInfoShow: false,
|
groupInfoShow: false,
|
||||||
|
|
||||||
windowScrollY: 0
|
wrapperStyle: {},
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
mounted() {
|
mounted() {
|
||||||
if ($A.isIos()) {
|
if ($A.isIos()) {
|
||||||
window.addEventListener('scroll', this.onScrollEvent);
|
window.addEventListener('scroll', this.onWindowScroll);
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
beforeDestroy() {
|
beforeDestroy() {
|
||||||
if ($A.isIos()) {
|
if ($A.isIos()) {
|
||||||
window.removeEventListener('scroll', this.onScrollEvent);
|
window.removeEventListener('scroll', this.onWindowScroll);
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
@ -321,13 +321,6 @@ export default {
|
|||||||
isMyDialog() {
|
isMyDialog() {
|
||||||
const {dialogData, userId} = this;
|
const {dialogData, userId} = this;
|
||||||
return dialogData.dialog_user && dialogData.dialog_user.userid == userId
|
return dialogData.dialog_user && dialogData.dialog_user.userid == userId
|
||||||
},
|
|
||||||
|
|
||||||
wrapperStyle() {
|
|
||||||
const {windowScrollY} = this;
|
|
||||||
return {
|
|
||||||
top: windowScrollY + 'px'
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
@ -695,8 +688,16 @@ export default {
|
|||||||
}, 100)
|
}, 100)
|
||||||
},
|
},
|
||||||
|
|
||||||
onScrollEvent() {
|
onWindowScroll() {
|
||||||
this.windowScrollY = window.scrollY
|
const {scrollE} = this.scrollInfo();
|
||||||
|
this.wrapperStyle = {
|
||||||
|
top: window.scrollY + 'px'
|
||||||
|
}
|
||||||
|
if (scrollE <= 10) {
|
||||||
|
this.$nextTick(_ => {
|
||||||
|
this.onToBottom();
|
||||||
|
})
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -92,7 +92,7 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div v-if="tabTypeActive === 'column'" class="project-column">
|
<div v-if="tabTypeActive === 'column'" class="project-column" :style="columnStyle">
|
||||||
<Draggable
|
<Draggable
|
||||||
:list="columnList"
|
:list="columnList"
|
||||||
:animation="150"
|
:animation="150"
|
||||||
@ -538,6 +538,7 @@ export default {
|
|||||||
computed: {
|
computed: {
|
||||||
...mapState([
|
...mapState([
|
||||||
'windowWidth',
|
'windowWidth',
|
||||||
|
'touchBackInProgress',
|
||||||
|
|
||||||
'userId',
|
'userId',
|
||||||
'cacheDialogs',
|
'cacheDialogs',
|
||||||
@ -557,7 +558,7 @@ export default {
|
|||||||
},
|
},
|
||||||
|
|
||||||
tabTypeStyle() {
|
tabTypeStyle() {
|
||||||
let style = {}
|
const style = {}
|
||||||
switch (this.tabTypeActive) {
|
switch (this.tabTypeActive) {
|
||||||
case 'column':
|
case 'column':
|
||||||
style.left = '0'
|
style.left = '0'
|
||||||
@ -574,6 +575,14 @@ export default {
|
|||||||
return style
|
return style
|
||||||
},
|
},
|
||||||
|
|
||||||
|
columnStyle() {
|
||||||
|
const style = {}
|
||||||
|
if (this.touchBackInProgress) {
|
||||||
|
style.overflow = 'hidden';
|
||||||
|
}
|
||||||
|
return style
|
||||||
|
},
|
||||||
|
|
||||||
userWaitRemove() {
|
userWaitRemove() {
|
||||||
const {userids, useridbak} = this.userData;
|
const {userids, useridbak} = this.userData;
|
||||||
if (!userids) {
|
if (!userids) {
|
||||||
|
|||||||
1
resources/assets/js/store/state.js
vendored
1
resources/assets/js/store/state.js
vendored
@ -11,6 +11,7 @@ const stateData = {
|
|||||||
loadUserBasic: false,
|
loadUserBasic: false,
|
||||||
loadProjects: 0,
|
loadProjects: 0,
|
||||||
loadDialogs: 0,
|
loadDialogs: 0,
|
||||||
|
touchBackInProgress: false,
|
||||||
|
|
||||||
// User
|
// User
|
||||||
cacheUserActive: {},
|
cacheUserActive: {},
|
||||||
|
|||||||
3
resources/assets/sass/components/mobile.scss
vendored
3
resources/assets/sass/components/mobile.scss
vendored
@ -232,6 +232,9 @@
|
|||||||
|
|
||||||
.mobile-dialog-leave-active {
|
.mobile-dialog-leave-active {
|
||||||
transition: all 0.3s ease;
|
transition: all 0.3s ease;
|
||||||
|
.dialog-wrapper {
|
||||||
|
bottom: -60px;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.mobile-dialog-enter,
|
.mobile-dialog-enter,
|
||||||
|
|||||||
@ -979,6 +979,7 @@
|
|||||||
.dialog-scroller {
|
.dialog-scroller {
|
||||||
padding-right: 14px;
|
padding-right: 14px;
|
||||||
padding-left: 14px;
|
padding-left: 14px;
|
||||||
|
overscroll-behavior: none;
|
||||||
}
|
}
|
||||||
.dialog-footer {
|
.dialog-footer {
|
||||||
background-color: #f8f8f8;
|
background-color: #f8f8f8;
|
||||||
|
|||||||
@ -478,6 +478,9 @@
|
|||||||
.messenger-msg {
|
.messenger-msg {
|
||||||
z-index: 49;
|
z-index: 49;
|
||||||
background-color: #f8f8f8;
|
background-color: #f8f8f8;
|
||||||
|
.msg-dialog-bg {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user