完善会话草稿恢复与附件保留,统一人工服务时区
This commit is contained in:
@@ -1,5 +1,17 @@
|
||||
// Shared controls for the customer page and service workspace.
|
||||
var SupportUI = {
|
||||
initAttachments(container, label){
|
||||
container.addEventListener('error', function(event){
|
||||
const image = event.target;
|
||||
if(!image || image.tagName !== 'IMG' || !image.classList.contains('message-image') || image.dataset.unavailable) return;
|
||||
image.dataset.unavailable = '1';
|
||||
image.hidden = true;
|
||||
const hint = document.createElement('span');
|
||||
hint.className = 'attachment-unavailable';
|
||||
hint.textContent = typeof label === 'function' ? label() : label;
|
||||
image.after(hint);
|
||||
}, true);
|
||||
},
|
||||
async enableNotifications(button){
|
||||
if(!('Notification' in window)) return;
|
||||
try{
|
||||
|
||||
Reference in New Issue
Block a user