MCPcopy Create free account
hub / github.com/dajie111/nodeseek-userscript / showQuickReplyDialog

Function showQuickReplyDialog

quickReply.js:755–794  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

753
754 // 显示快捷回复弹窗
755function showQuickReplyDialog() {
756 // 检查弹窗是否已存在
757 const existingDialog = document.getElementById('quick-reply-dialog');
758 if (existingDialog) {
759 existingDialog.remove();
760 return;
761 }
762
763 // 添加样式
764 addQuickReplyStyles();
765
766 // 创建弹窗
767 const dialog = document.createElement('div');
768 dialog.id = 'quick-reply-dialog';
769 dialog.className = 'quick-reply-dialog';
770 dialog.style.position = 'fixed';
771 dialog.style.top = '60px';
772 dialog.style.right = '20px';
773 dialog.style.zIndex = 10000;
774 dialog.style.background = '#fff';
775 dialog.style.border = '1px solid #ddd';
776 dialog.style.borderRadius = '12px';
777 dialog.style.boxShadow = '0 8px 32px rgba(0,0,0,0.12)';
778 dialog.style.padding = '20px';
779 dialog.style.minWidth = '400px';
780 dialog.style.maxWidth = '600px';
781
782 // 创建弹窗内容
783 createQuickReplyContent(dialog);
784
785 document.body.appendChild(dialog);
786
787 // 使用全局的 makeDraggable 函数
788 if (window.makeDraggable) {
789 window.makeDraggable(dialog, {width: 60, height: 40});
790 }
791
792 // 记录日志
793
794 }
795
796 // 创建快捷回复弹窗内容
797 function createQuickReplyContent(dialog) {

Callers

nothing calls this directly

Calls 2

addQuickReplyStylesFunction · 0.85
createQuickReplyContentFunction · 0.85

Tested by

no test coverage detected