🌐 AI搜索 & 代理 主页
Skip to content

Conversation

@kktam
Copy link

@kktam kktam commented Mar 27, 2018

add support for boxModelAdjustment() to support svg element.

Summary

Checklist

add support for boxModelAdjustment() to support svg element.
Copy link
Member

@gibson042 gibson042 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a good start.

// Assuming integer scroll gutter, subtract the rest and round down
delta += Math.max( 0, Math.ceil(
elem[ "offset" + dimension[ 0 ].toUpperCase() + dimension.slice( 1 ) ] -
( elem[ "offset" + dimension[ 0 ].toUpperCase() + dimension.slice( 1 ) ] || 0 ) -
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I was anticipating the || 0 being farther out in this expression, and there may be problems from assuming that all SVG elements have no width or height. But that will all be resolved by unit tests covering SVG dimension getters, which this PR still needs.

@gibson042
Copy link
Member

@kktam Do you think you'll be able to add the changes?

@timmywil
Copy link
Member

Closing in favor of #4096. Thanks

@timmywil timmywil closed this Jun 11, 2018
@lock lock bot locked as resolved and limited conversation to collaborators Dec 8, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Development

Successfully merging this pull request may close these issues.

3 participants