fedwiki / wiki-client

Federated wiki client-side javascript as a npm module.
Other
117 stars 38 forks source link

display flex for native scrolling #327

Closed WardCunningham closed 2 weeks ago

WardCunningham commented 3 weeks ago

@baldurbjarnason has guided me through this modest improvement styling the lineup using flex for native scrolling. This is expected to work better on mobile. (Test this before merging.)

Note: this and related work is more about investing in the longevity of our codebase than adding mobile as a feature. I once referred to this as "chronological scaling" before we had a clear notion of what that would require. post

paul90 commented 3 weeks ago

Only thing I've spotted so far is that the horizontal scrollbar on the lineup needs hiding, and page being opened no longer is scrolled into view. No auto scrolling the lineup to bring the new page into view is most likely a fault in the JS conversion!, looks to be something jQuery related that get broken here.

WardCunningham commented 3 weeks ago

@paul90 recommended this simple fix, bfa2e8b, and adds, "if we were not moving away from browserify it could be fixed by adding browserify-optional into the mix."

Rendering on older iPad. IMG_0053

Rendered on old iPhone. IMG_9404

WardCunningham commented 2 weeks ago

Direct positioning within the lineup happens when a specific page is made active. This is handled by code in active.coffee. Changes here have thrown off these calculations.

Various places in the code will expose a particular page and make it active with idiomatic code that looks like:

active.set($('.page').last())

We see calls like this in these modules:

paul90 commented 2 weeks ago

Cherry picking the change here to the new decaffeinated main branch added a bunch of commits from the migration. Restored by force-push, this PR will be closed and reopened on the new main branch.

paul90 commented 2 weeks ago

Closed in favour of #328, based on the JavaScript main branch.