Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bug:只读模式下无法复制文本内容 #163

Open
wjw020206 opened this issue Sep 9, 2024 · 0 comments
Open

Bug:只读模式下无法复制文本内容 #163

wjw020206 opened this issue Sep 9, 2024 · 0 comments
Assignees
Labels
bug Something isn't working

Comments

@wjw020206
Copy link
Collaborator

bug 描述

只读模式下无法复制文本内容

你预期的样子是?

只读模式下可以复制文本内容

系统和浏览器及版本号

  • 操作系统:Windows 10
  • 浏览器和版本:Chrome 128.0.6613.120

wangEditor-next 版本

@wangeditor-next/editor: 5.5.4
@wangeditor-next/editor-for-vue2: 1.0.2

demo 能否复现该 bug ?

不能,因为 demo 示例中没有只读模式的示例

在线 demo

复现示例:https://stackblitz.com/edit/vue2-vite-starter-syslwe?file=src%2Fcomponents%2FMyEditor.vue

最小成本的复现步骤

在异步设置内容后调用 this.editor.disable() 设置只读模式

 mounted() {
    // 模拟 ajax 请求,异步渲染编辑器
    setTimeout(() => {
      this.html = '<p>我是 Ajax 异步设置内容 HTML,你可以选中我,但是无法复制我</p>'
      // 回显数据后设置编辑器为只读模式
      this.editor.disable()
    }, 1500)
  },
@wjw020206 wjw020206 self-assigned this Sep 9, 2024
@wjw020206 wjw020206 added the bug Something isn't working label Sep 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant