Viewbox减少隐藏图标



我有如下svg文件:

<svg height="50px" viewBox="0 0 500 500" width="50px"><g><path d="M355.295,269.514L325.36,179h27.68c1.122,0,1.999-0.957,1.862-2.071c-1.032-8.427-8.214-14.929-16.92-14.929h-18.289    l-0.187-0.562L319.327,162h-17.501c-9.415,0-24.68-17-34.095-17H231.89c-9.415,0-24.68,17-34.095,17H179.15l-0.187-0.562    L178.784,162h-16.744c-8.706,0-15.888,6.502-16.92,14.929c-0.136,1.114,0.74,2.071,1.862,2.071h26.38l-28.658,90.584l0.121,0.273    c0.225,9.521,15.766,17.323,34.914,17.323c19.2,0,34.775-7.667,34.918-17.224l0.094-0.471L184.817,179H240v160.947    c-29,1.034-54.235,6.303-59.104,13.938c-0.784,1.229,0.47,2.115,1.928,2.115h134.376c1.458,0,1.7-0.886,0.916-2.115    C313.246,346.25,291,340.981,258,339.947V179h55.906l-28.658,90.584l0.121,0.273c0.225,9.521,15.766,17.323,34.914,17.323    c19.2,0,34.775-7.902,34.918-17.458L355.295,269.514z M156.553,269l22.648-71.214L202.875,269H156.553z M297.096,269    l22.647-71.214L343.417,269H297.096z"/></g></svg>

但是,我试图将视图框减少到0 0 64 64,它不起作用。(隐藏图标)不知道这里有什么问题

任何帮助都将是非常感激的。

SVG的默认大小为500,传递宽度和高度道具足以改变SVG的大小,除非您想做其他事情而不是改变大小

相关内容

  • 没有找到相关文章

最新更新