Change action order

In a chain of actions for a single button, it’s frustrating to add an action at the beginning. I have to remove all the actions, add the new action and then add the original actions back again. I even took a screenshots to make sure I made it right. It would be nice to be able to change the order of actions.

3 Likes

Agree! Although it is a good exercise for the short term memory :wink:

That’s why I put everything on paper before using Hype!
This feature would be great though.

Thanks for the feedback! My original plan in the 1.6 days was to allow reordering of actions, but I ran out of time before shipping, I’ve been hoping to get back to this at some point!

2 Likes

Just thought of another aspect; sometimes a change is about the events, e.g. change from tap to touch start, keeping the same actions. (It would be a bit of work to add reordering features to the UI, without messing it up. Its clean and simple as it is now.)

And talking about events; would it be useful to have ‘on focus’?

To support keyboard, touch and mouse interaction in the same user interface it seems to be about working with focus – and make the styling of focus to be similar as of ‘down’, ‘touch start’ etc. Are not Google Material on the way in that direction?

I’ve added external CSS for focus. Works. Except for styling the border of a circle, in my experience.

Animated effects for ‘on focus’ is harder. Would prefer to define that in timelines.

My understanding is that focus events only happen on form-style controls, which Hype doesn’t yet have as part of its built-in elements. So if you had these controls, you’d be hand coding anyways. It is a pretty popular request to help with form building, so in that case it’d also make sense if we had focus handlers.

I might be mixing up things.

In Hype, if allowing external CSS, and defining styles for the focus selector, and the class added to e.g. a button in Hype — in my experience — Hype will use this styling. If ‘include in keyboard navigation’ is turned on, the effect will be that mouse clicks, keyboard tabbing and at some occasions even taps on a touch device will render the focus styling on the button.

Would be good to be able to like that. However the styling and the effects seems a bit hard to make look good for all kinds of visual ideas for buttons. And to even animate the style change…

1 Like

Oh, I hadn’t realized that checkbox would trigger :focus events. Maybe what we’ll do in the future is make a new button style for focus (similar to normal/hover/pressed that we now have). We’ve been wanting to allow animating/transitioning those states as another feature.

1 Like

Yes, that sounds as the proper way to extend the current model!

1 Like

I moved 2 posts to a new topic: Adding a Class to an Element