def viewport.dimension
import gralha-svg-render@0.1.0.1/svg.bend as Svgimport Base
import gralha-text-scan@0.1.0.1/scan.bend as U
import gralha-xml-doc@0.1.0.1/xml.bend as XML
2716def viewport.dimension(+as: List<&2, XML.Attr>, key: String, +ref: F32) -> F32:
2717 +value = XML.attr.get(as, key, "auto")
2718 U.branch(F32, U.string.equal(value, "auto"), _ => ref, _ => U.unit(U.number(value), ref))