Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update npf-renderer to 0.12.0 #9

Merged
merged 12 commits into from
Feb 6, 2024
Merged

Update npf-renderer to 0.12.0 #9

merged 12 commits into from
Feb 6, 2024

Conversation

syeopite
Copy link
Owner

@syeopite syeopite commented Dec 13, 2023

npf-renderer's next release is set to add a bunch of new features such as support for videos (finally) and a new photoset layout system.

Some changes however are needed on Priviblur's side.

Closes #16

In server-side rendering, as posts are rendered one by one sequentially
the results for polls must also be fetched sequentially.

This results in a lengthy load time as Priviblur has to send dozens of
requests one-by-one before the page can be returned.

By populating the polls client side, this lengthy fetch process can be
avoided entirely.

For JS-disabled users, a fetch_polls URL parameter is provided as a
fallback to allow for server-side fetching of poll results. However,
due to the aforementioned reasons above, this is only available on
individual posts.
Prior to this commit, it was naively assumed that a poll can only appear
once on a page and as such each poll choice was assigned an HTML id
of their given answer ID.

However, due to the presence of reblogs, polls can in fact appear more
than once on a single page and as such the logic in the poll
filling JS fails due to the presence of duplicate IDs.
Trail polls should be fetched with the current post's blog name and ID
Fixes issue where polls would cover up the dropdown menus
@syeopite syeopite marked this pull request as ready for review February 6, 2024 06:57
@syeopite syeopite merged commit 32a12c7 into master Feb 6, 2024
@syeopite syeopite deleted the update-npf branch February 6, 2024 07:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Post caption overlaps with text
1 participant