Chrome 121 复制 canvas 图片报 NotAllowedError 手势过期怎么改

陆零云 33 0
商品海报生成器点「复制图片」,Chrome 121 控制台抛 NotAllowedError: The request is not allowed by the user agent or the platform in the current context。同一次点击里纯文本复制是好的,换成图片一定失败。 第一反应是权限,查 permissions.query 的 clipboard-write 状态是 granted,页面也是 https。把 wr...

嵌入 iframe 的复制按钮总报 NotAllowedError 权限该怎么降级

陆零云 461 0
后台编辑器嵌在 iframe 里,复制分享链接的按钮点下去直接抛 NotAllowedError: Write permission denied。同一个页面单独打开是好的,嵌进 iframe 就废,用户只能手动选中再复制。 第一反应是安全上下文,确认顶层和 iframe 都是 https,不是 http 的问题。又试了 navigator.permissions.query 查 clipboard-write,返回 denied,说明权限确实没继承到这一...