Closed noumantahir closed 3 years ago
A quick status update regarding native filters...
So far we have,
tabbedPosts
Only drawback we have in our current implementation is the fact when a list is updated, the chagne is not register thrown by reducer, to make it force throw a change callback, I am copying state Object.create(state)
and returning it back, not the most efficient solution but is done only for experimentation for now.
Status Update Log https://user-images.githubusercontent.com/6298342/113621976-cb3c5180-9675-11eb-9e2a-277a0a0a3b4a.mov
The recording is from an android phone running in debug mode, release mode performance will be even better for sure.
ref: https://github.com/ecency/ecency-mobile/tree/nt/native-filters
Status Update The feed screen is now useable with most of primary functions like,
Pending Items
@feruzm please if you get a change feel free to update the ToDo/Pending items to list of feed screens functionalities... it's a big component, very easy to miss something from tests.
@feruzm checkout this issue related to promoted posts fetch on tab change...there is a glitch when new promoted posts is rendered in place of previous post because of image height calculation. this should affect our previous builds as well...
However if user move to other tab for the first time, the glitch do not affect anything as expected.
https://user-images.githubusercontent.com/6298342/114015269-efb94900-9882-11eb-8999-d1fb3ea0cd94.mov
Suggestion 1: we keep the current structure but fix height of promoted post, it will remove the glitch in no time.
Suggestion 2: we fetch updated promotions on list end callback and stack promoted posts just like regular posts. this will make sure user get new ads as they scroll down
@noumantahir
@feruzm
Status Update
Updates
Updates
Pending
attempting to make use of this package...
skipping head-tab-view for now, documentation is very confusing and is not well written package
[x] port tabbedPosts to profile screen
Know issues
tab change issue while scrolling
Creating an issue on ScrollableTabView repo
Update: seems it's a know issue created here... https://github.com/ptomasroos/react-native-scrollable-tab-view/issues/964
Finally! fixed weird unresponsive tab change while scrolling issues by discarding nested scrollview in favour of stacked tab bars.
The final implementation is surprisingly more clean may even be more efficient as there are not nested tab bars.
Only thing I dislike the fact there are 2 tabs for each stack when viewing your own profile, that does not look as promising compared to 3 - 2 stacked tabs
https://user-images.githubusercontent.com/6298342/114520448-e0f3dd00-9c5a-11eb-8c55-ee97c70de1bb.mov
@feruzm
My suggestion: We can do non stacked 3 tabs [Posts, Blogs, Replies] for user's profile and keep other profiles stacked..
@noumantahir lets move Blog to 1st line of tabs and remove sub tabs ? My only concert is that, can these tabs if 3-4 items fit nicely in smaller screen sizes. We can of course make Wallet tab as icon so it takes lesser space when viewing other people's account.
let me try.. we can also try removing image icon perhaps... we already have images toggle button in feed screen
good point, on profile page that's (view change toggle) probably not necessary
@feruzm single profile tab bar on small to large screens, codes pushed as well..
after update from previous version, I launched app and this is what I got... For example, Top filter at first loaded posts and then showing spinner, it did stop but on other tabs it is not stopping so there is likely some bug or cache update logic that's not working.
https://user-images.githubusercontent.com/3015990/114842475-8c2e9e80-9de1-11eb-9247-4c0867466fc4.MP4
could be something introduced because editable tag update as it did required tweak to tabbedPost... will debug
Current filter system is used more like button to shift state causing posts feed to re-render posts list items. This causes a momentary lag in app performance.
Expected behavior The transition from one tab to another should be instantaneous. just like bottom navigation tabs only in this case it should change posts filter.
Additional context The idea is to replace button based filter tab with actual native tabs with built-in cache functionality.
Ideally the new system will use most of the same codebase as available postsContainer and sub components
Checklist