FEATURE: CTRL-SHIFT-ENTER and SHIFT-Click do not scroll on post (PR #10939)

This allows for an advanced feature where hitting control on click or CTRL-SHIFT-ENTER will lead to a post being made but the browser not to scroll to the end.


@eviltrout / @jjaffeux this works perfectly I think, but is somewhat awkward … any suggestions for cleanup here.

The gist is that if you SHIFT click while replying we do not scroll. Keyboard shortcut is the most awkward but passing of click handler is also a bit awkward.

This pull request has been mentioned on Discourse Meta. There might be relevant details there:


no optional chaining yet :slight_smile: sorry

Generally speaking I think passing the event is the thing to do, I do this for select-kit everywhere too. If you don’t do this you end up with cases where you are stuck. So I :+1: doing this.

we can’t change this sadly, but this is a very bad name for action, onSave would be much better :confused:

It’s also annoying we have an action and a fn named the same, because this kind of things will cause issue when we move to @action it would just be a regular fn, and we can’t have:

save() (}

save() {}

shouldn’t we pass the event here too ?

maybe we just go with save(force, options = {}) so we don’t have to use optional chaining

And yes I would argue the shortcut is annoying because it’s kinda hard to do ctrl+shift+enter while clicking

Oh it’s only shift click


Ctrl shift enter

Not a mix

maybe we rename / deprecate?

I don’t think so, this is deprecated, I don’t want to support it anymore.

Just pushed some refinements … how is it looking now @jjaffeux ?

I had to revert this because it broke stuff:


I think passing the event is generally not a bad thing to do, but we have to figure out a way to make it a non-breaking change.