You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
While using @nuxt/icon with the Ant Design icon collection, I noticed that the icon sizes don’t quite match those on the Ant Design website. The issue is that icons on the Ant Design website have viewBox="64 64 896 896", whereas icons from the collection have viewBox="0 0 1024 1024" in the svg element.
How can I change the viewBox attribute value? I tried using the customize function and setting the viewBox attribute on the <Icon /> component, but it doesn’t work.
The text was updated successfully, but these errors were encountered:
mshornikov
changed the title
Is there a way to change svg element viewBox attribute?
Is there a way to change svg element viewBox attribute?
Mar 5, 2025
mshornikov
changed the title
Is there a way to change svg element viewBox attribute?
Is there a way to change the viewBox attribute of an SVG element?
Mar 5, 2025
While using
@nuxt/icon
with the Ant Design icon collection, I noticed that the icon sizes don’t quite match those on the Ant Design website. The issue is that icons on the Ant Design website haveviewBox="64 64 896 896"
, whereas icons from the collection haveviewBox="0 0 1024 1024"
in thesvg
element.How can I change the
viewBox
attribute value? I tried using thecustomize
function and setting theviewBox
attribute on the<Icon />
component, but it doesn’t work.The text was updated successfully, but these errors were encountered: