WordPress将插件URL附加到样式属性URL()
我正在用十几个块制作此Gutenberg块插件。 其中一个是给我这种奇怪的行为。
SCSS中的任何地方都有一个带有锚定目标的属性的地方,例如:
.mao1-d {
mask: url(#mao1-c);
}
浏览器正在呈现:
.mao1-d {
mask: url(/wp-content/plugins/cora-plugin-22/blocks/block15/build/#mao1-c);;
}
我在同一插件中的其他块中也有类似的代码,但行不通。 构建.CSS就像.scss一样,没有插件路径:
.mao1-d {
mask: url(#mao1-c);
}
如何解决此问题的任何想法?
I'm making this gutenberg blocks plugin with a dozen of blocks.
One of them is giving me this weird behaviour.
Everywhere in the style.scss where there's a property with an anchor target, say, this one:
.mao1-d {
mask: url(#mao1-c);
}
The browser is rendering as this:
.mao1-d {
mask: url(/wp-content/plugins/cora-plugin-22/blocks/block15/build/#mao1-c);;
}
I have similar code within other blocks in the same plugin and that doesn't work.
The build .css is just like the .scss, without the plugin path:
.mao1-d {
mask: url(#mao1-c);
}
Any ideas on how to solve this?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论