Infinite Scroll Block

描述

Adds an infinite scroll block to the full site editor that can be placed inside a Query Loop to replace classic pagination.

The blocks frontend script will detect when the user is 1200px (default value) from the infinite scroll block before fetching more posts so it is best to place it right after your theme template block. In addition to the Infinite Scroll Block, 2 optional blocks also are included:

  • Loading Posts Block: Container that will display its content while more posts are loading
  • No More Posts Block: Container that will display when there are no more posts to load in

Additional Note

While you can add more than one Infinite Scroll Block inside of a Query Loop Block, you should not. The block was originally constrained to only one per page (multiple = false) but was removed in order to support multiple query blocks on the same page.

区块

该插件提供了3个区块.

  • Infinite Scroll Implements inifnite scroll functionality. The number of posts loaded when triggered is equivalent to the Query Loops 'Items Per Page' setting.
  • Loading Posts Contains the elements that are displayed while loading posts (optional block).
  • No More Posts Contains the elements that are displayed when there are no more posts to fetch (optional block).

评价

2022年12月14日 1 回复
Very good extension, works well in most cases, but I found an issue with list blocks. Some times, the list flows out of the post article. I have a blog page, with 2 columns and 4 items per page. When there is a list block in post number 5, the list flows out. It's ok if there is a list block in post number 4. I hope this will help you. Thanks
2022年11月21日
Love the simplicity of this plugin. Works perfectly within Site Editor themes. Nice work 🚀
阅读所有2条评价

贡献者及开发者

“Infinite Scroll Block” 是开源软件。 以下人员对此插件做出了贡献。

贡献者

将“Infinite Scroll Block”翻译成您的语言。

对开发感兴趣吗?

您可以浏览代码,查看SVN仓库,或通过RSS订阅开发日志

更新日志

1.0.1

  • Fixed issue where a list element inside of a posts content would be stripped out and placed into the query block list