Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Increase active area on one-field-blocks #132 #155

Merged
merged 2 commits into from
Apr 4, 2016

Conversation

drigz
Copy link
Collaborator

@drigz drigz commented Mar 31, 2016

If a block only has one field, the mouseup event (which triggers editing
of editable fields) will be bound to the block instead of the field.

Fixes #132.

The test breaks from the style of the existing tests by requiring a lot of infrastructure to work, as we have to actually create the whole SVG workspace before we can install the click handler on an SVG element. If you don't like this, I could cut the test or maybe try to mock enough to test just the event handling? Let me know.

If a block only has one field, the mouseup event (which triggers editing
of editable fields) will be bound to the block instead of the field.

Fixes #132.
@tmickel
Copy link
Contributor

tmickel commented Apr 1, 2016

This seems to me like a fine solution at least in the interim until we start doing vertical rendering and/or refactor/rethink the way we drew fields.

Can you think of any way to fix the mouse cursor?

When you get a chance, please go ahead and merge!

We do this by applying the style to the same element we apply the click
target to, ie the whole block if it only has one field.
@drigz drigz merged commit 46ed2fa into scratchfoundation:develop Apr 4, 2016
@drigz drigz deleted the bugfix/field-active-area branch April 4, 2016 09:10
picklesrus pushed a commit to picklesrus/scratch-blocks that referenced this pull request Aug 4, 2017
SpriteInfo: Design + refactor pass
* Updated SVG icons
* Added tab indexes, related scratchfoundation#88. Still no tab on radio buttons
* Removed outline on dropdown focus
* Radio icons: fixed redirecting issue, using `div` instead of `a`. Temporary, until radio buttons. Related scratchfoundation#156
* All icons: unselectable to prevent highlighting. Radio icons clickable
* SpriteSelector: fixed bottom padding in scroll wrapper
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants