File tree Expand file tree Collapse file tree 2 files changed +4
-4
lines changed
Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Original file line number Diff line number Diff line change 2020 " Experimental way of getting the bounds of unknown or complicated elements
2121 using the getBBox method.
2222 https://developer.mozilla.org/en-US/docs/Web/API/SVGGraphicsElement/getBBox"
23- [el]
24- (when (.-getBBox el)
25- (let [b (.getBBox el)
23+ [dom- el]
24+ (when (.-getBBox dom- el)
25+ (let [b (.getBBox dom- el)
2626 min-x (.-x b)
2727 min-y (.-y b)
2828 max-x (+ min-x (.-width b))
Original file line number Diff line number Diff line change 2929(m/=> multiplier [:-> string? number?])
3030(defn multiplier
3131 " Returns the multiplier by unit.
32- If the unit is invalid, it fallbacks to :px (1)"
32+ If the unit is invalid, it fallbacks to :px (1). "
3333 [s]
3434 (get unit-to-pixel-map (if (valid-unit? s)
3535 (utils.unit/->key s)
You can’t perform that action at this time.
0 commit comments