图层可视化 BTN
问题
顺便说一句,如果我更改了可见性状态——GJS会移除显示样式,然后当我点击“显示图层”时,它也无法恢复显示样式。 我觉得这是个bug。GJS 应该把当前显示器的选项保存在图层可见按钮点击恢复时。
回答(3)
我同意 👍
好了,大家,如果你们需要,我找到了一个热修复方法: “JavaScript 设 itmView = 编辑器。LayerManager.getAll(); itmView.proto.toggleVisibility = function(e) { e & & e.stopPropagation(); const model = this.model; const style = model.getStyle(); const hidden = style.display == 'none'; 如果(隐藏){ if (model.attributes.oldStyleDisplay) { st...
谢谢@h3llomoto逻辑完全正确,我也会做同样的改动,但更习惯性一点
相关问答
通过相似的问题讨论继续研究。
问题 #2774
MediaCondition:“最小宽度”断点在画布中未正确应用样式
你好, 我在移动优先的方式上遇到了一些问题。当画布在多个断点设置不同样式时,渲染出错误的样式。但生成的代码是好的,这个问题只发生在画布里。 https://codesandbox.io/s/xenodochial-shockley-s02lp?file=/index.js:49...
问题 #2771
组件,带有textable:1,自0.16.12版本起无法工作
你好, 我刚刚更新到最新版本 0.16.12,尝试将带有 'textable:1' 属性的组件迁移到文本组件时遇到了 bug。 它在之前的版本 0.16.3 上运行。 当我移动组件时,控制台会报错 '未捕获类型错误:无法读取未定义属性'属性' - ComponentView.j...
问题 #1224
媒体查询与类渲染问题
你好, 我试图做一个响应式布局,但发现设备切换器工作不稳定。这个问题可以在官方演示中复现。 开放 http://grapesjs.com/demo.html 保持“桌面”作为所选设备。 在“标题”顶部添加2个类型为“2列”的块(就在菜单上方)。 选择第一个插入的“行”,并将其填...
问题 #2681
: destroy() 方法未能完全移除事件
版本:最新:V-0.16.3。 重要:从v-0.15.9更新到v-0.16.3,保持所有内容不变,错误会在控制台显示: 这个错误显示函数 'getFrameOffset' 中存在错误,位置接近:'e.ownerDocument.defaultView.frameElement'...
与此问题匹配的付费插件
根据问题关键词和标签相关性精选,助你更快交付。
正在加载付费插件推荐……
相关教程
关于同一主题的深入指南。
教程
Vanilla GrapesJS vs GrapesJS With Plugins: What You Actually Get Out of the Box (2026)
New to GrapesJS? See exactly what the stock editor gives you, where it falls short, and which plugins close the gaps — a beginner-friendly 2026 comparison
教程
GrapesJS DevTools: A Developer Panel Inside Your Editor
If you've ever debugged GrapesJS with console.log(editor.getSelected()) and a dozen throwaway event listeners — this post is for you.
教程
How We Built Composeit in Record Time Using GrapesJS Shadcn
Bypass foundational builder boilerplate and focus on what truly matters.
浏览插件分类
直接跳转到市场上的插件分类页面。