# Fix Workspace Flow Tab Scroll Direction

**URL:** <https://discourse.nodered.org/t/fix-workspace-flow-tab-scroll-direction/65250>\
**Category:** Feature Requests\
**Created:** [18 July 2022 07:49 UTC](https://discourse.nodered.org/t/fix-workspace-flow-tab-scroll-direction/65250 "2022-07-18T07:49:49Z")\
**Posts on this page:** 16\
**Page:** 1

<div class="post-metadata">

**Author:** ![bjpw](https://avatars.discourse-cdn.com/v4/letter/b/3bc359/32.png) [@bjpw](https://discourse.nodered.org/u/bjpw)\
**Post date:** [18 July 2022 07:49 UTC](https://discourse.nodered.org/t/fix-workspace-flow-tab-scroll-direction/65250/1 "2022-07-18T07:49:49Z")

</div>

Currently, the workspace Flow tabs scroll in the "wrong" direction when using the mousewheel - one has to scroll _down_ to get to the first Flow tab and _up_ to get to the end of the list.

This _could_ be something that "feels" different based on different OSes - I know for example that Macs use inverted scrolling by default.

The fix for me is to change the:

```auto
sl -= evt.originalEvent.deltaY;

```

line in `@node-red/editor-client/src/js/ui/common/tabs.js` to:

```auto
sl += evt.originalEvent.deltaY;

```

(Or rather the equivalent spot in `red.min.js`.)

Posting here first rather than just making a PR in case I missed something and there's an option floating around somewhere to change the behaviour.

---

<div class="post-metadata">

**Author:** ![Colin](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/colin/32/17040_2.png) [@Colin](https://discourse.nodered.org/u/Colin)\
**Post date:** [18 July 2022 09:19 UTC](https://discourse.nodered.org/t/fix-workspace-flow-tab-scroll-direction/65250/2 "2022-07-18T09:19:41Z")

</div>

Welcome to the forum @bjpw

That does seem non-intuitive to me too.

---

<div class="post-metadata">

**Author:** ![HaroldPetersInskipp](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/haroldpetersinskipp/32/42319_2.png) [@HaroldPetersInskipp](https://discourse.nodered.org/u/HaroldPetersInskipp)\
**Post date:** [18 July 2022 15:13 UTC](https://discourse.nodered.org/t/fix-workspace-flow-tab-scroll-direction/65250/3 "2022-07-18T15:13:57Z")

</div>

It feels so wrong the way it is now. I have a lot of flows, so I've just reverted to using the information sidebar to scroll through a vertical list to select them.

---

<div class="post-metadata">

**Author:** ![knolleary](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/knolleary/32/3_2.png) [@knolleary](https://discourse.nodered.org/u/knolleary)\
**Post date:** [18 July 2022 15:25 UTC](https://discourse.nodered.org/t/fix-workspace-flow-tab-scroll-direction/65250/4 "2022-07-18T15:25:19Z")

</div>

> [@bjpw](#):
>
> I know for example that Macs use inverted scrolling by default.

And therein lies the problem. Whichever direction it scrolls will feel 'wrong' to some users. So a PR that simply flips the direction wouldn't actually solve it properly.

I'm not sure if simple detecting Mac is sufficient to picking the right scroll direction - but could be good enough.

If someone wants to a PR an appropriate fix along these lines we'd certainly look at it.

---

<div class="post-metadata">

**Author:** ![zenofmud](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/zenofmud/32/316_2.png) [@zenofmud](https://discourse.nodered.org/u/zenofmud)\
**Post date:** [18 July 2022 15:36 UTC](https://discourse.nodered.org/t/fix-workspace-flow-tab-scroll-direction/65250/5 "2022-07-18T15:36:21Z")

</div>

@bjpw in addition there is a setting on the Mac that allow you to inverse the direction of the scroll.

---

<div class="post-metadata">

**Author:** ![bjpw](https://avatars.discourse-cdn.com/v4/letter/b/3bc359/32.png) [@bjpw](https://discourse.nodered.org/u/bjpw)\
**Post date:** [18 July 2022 18:43 UTC](https://discourse.nodered.org/t/fix-workspace-flow-tab-scroll-direction/65250/6 "2022-07-18T18:43:19Z")

</div>

Note that I don't _know_ that it currently feels "right" to Mac users, so - Mac users - does it currently seem to scroll in the correct direction for you when using wheel or trackpad?

Would be good to resolve this before doing a PR.

---

<div class="post-metadata">

**Author:** ![zenofmud](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/zenofmud/32/316_2.png) [@zenofmud](https://discourse.nodered.org/u/zenofmud)\
**Post date:** [18 July 2022 19:15 UTC](https://discourse.nodered.org/t/fix-workspace-flow-tab-scroll-direction/65250/7 "2022-07-18T19:15:03Z")

</div>

> [@bjpw](#):
>
> Mac users - does it currently seem to scroll in the correct direction for you when using wheel or trackpad?

I'm a Mac user. When I push the mouse sheel from bact to front of mouse, the flow window scrolls up, just as it does looking t a thread on this forum. To me it is like I put my finger on the screen and pushed the window up. Same effect using my iPad.

If I invert my mouse scroll direction it feels unnatural.

---

<div class="post-metadata">

**Author:** ![TotallyInformation](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/totallyinformation/32/31_2.png) [@TotallyInformation](https://discourse.nodered.org/u/TotallyInformation)\
**Post date:** [18 July 2022 19:37 UTC](https://discourse.nodered.org/t/fix-workspace-flow-tab-scroll-direction/65250/8 "2022-07-18T19:37:02Z")

</div>

How about a flag in settings.js? Then people can choose for themselves. In fact, I thought there was a flag somewhere but perhaps that was just an idea?

---

<div class="post-metadata">

**Author:** ![Colin](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/colin/32/17040_2.png) [@Colin](https://discourse.nodered.org/u/Colin)\
**Post date:** [18 July 2022 19:42 UTC](https://discourse.nodered.org/t/fix-workspace-flow-tab-scroll-direction/65250/9 "2022-07-18T19:42:41Z")

</div>

> [@zenofmud](#):
>
> When I push the mouse sheel from bact to front of mouse, the flow window scrolls up

I thought we were talking about the sideways scroll when you hover over the flow tab headers.

---

<div class="post-metadata">

**Author:** ![bjpw](https://avatars.discourse-cdn.com/v4/letter/b/3bc359/32.png) [@bjpw](https://discourse.nodered.org/u/bjpw)\
**Post date:** [18 July 2022 19:51 UTC](https://discourse.nodered.org/t/fix-workspace-flow-tab-scroll-direction/65250/10 "2022-07-18T19:51:44Z")

</div>

Correct - the horizontal scrolling of workspace Flow tabs.

---

<div class="post-metadata">

**Author:** ![bjpw](https://avatars.discourse-cdn.com/v4/letter/b/3bc359/32.png) [@bjpw](https://discourse.nodered.org/u/bjpw)\
**Post date:** [18 July 2022 19:55 UTC](https://discourse.nodered.org/t/fix-workspace-flow-tab-scroll-direction/65250/11 "2022-07-18T19:55:00Z")

</div>

> [@TotallyInformation](#):
>
> How about a flag in settings.js? Then people can choose for themselves. In fact, I thought there was a flag somewhere but perhaps that was just an idea?

That's where my head is at too. A combination of a `settings.js` flag and perhaps using `event.webkitDirectionInvertedFromDevice` (relates to "natural scroll" on OS X) if nothing set in `settings.js` to provide a reasonable default.

---

<div class="post-metadata">

**Author:** ![zenofmud](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/zenofmud/32/316_2.png) [@zenofmud](https://discourse.nodered.org/u/zenofmud)\
**Post date:** [18 July 2022 21:06 UTC](https://discourse.nodered.org/t/fix-workspace-flow-tab-scroll-direction/65250/12 "2022-07-18T21:06:47Z")

</div>

That doesn’t do anything in safari…

---

<div class="post-metadata">

**Author:** ![bjpw](https://avatars.discourse-cdn.com/v4/letter/b/3bc359/32.png) [@bjpw](https://discourse.nodered.org/u/bjpw)\
**Post date:** [18 July 2022 21:58 UTC](https://discourse.nodered.org/t/fix-workspace-flow-tab-scroll-direction/65250/13 "2022-07-18T21:58:10Z")

</div>

What do you mean? It's _primarily_ meant for Safari - but it has to be inside a "wheel" event.

---

<div class="post-metadata">

**Author:** ![zenofmud](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/zenofmud/32/316_2.png) [@zenofmud](https://discourse.nodered.org/u/zenofmud)\
**Post date:** [18 July 2022 23:04 UTC](https://discourse.nodered.org/t/fix-workspace-flow-tab-scroll-direction/65250/14 "2022-07-18T23:04:42Z")

</div>

Sorry, I needed more tabs on tm screen.

So when I push the scroll wheel to the front, the tabs scroll left to right and right to left when I pull the wheel towards my hand. It feels natural to me.

---

<div class="post-metadata">

**Author:** ![scubanarc](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/scubanarc/32/65456_2.png) [@scubanarc](https://discourse.nodered.org/u/scubanarc)\
**Post date:** [30 July 2022 23:12 UTC](https://discourse.nodered.org/t/fix-workspace-flow-tab-scroll-direction/65250/15 "2022-07-30T23:12:53Z")

</div>

I would also like this setting. The way it currently works for me, in Vivaldi on Windows, is definitely backwards.

If I scroll in the direction that should be "down", I expect the tabs to scroll to the end. Instead they scroll to the beginning.

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/1X/d073cd938eafa2e558d7c2cd59003b3ef4963033.png) [@system](https://discourse.nodered.org/u/system)\
**Post date:** [28 September 2022 23:13 UTC](https://discourse.nodered.org/t/fix-workspace-flow-tab-scroll-direction/65250/16 "2022-09-28T23:13:43Z")

</div>

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.
