Added PostFeedLayout and PostCategoryLayout#64
Conversation
|
✔️ Deploy Preview for stackbit-components ready! 🔨 Explore the source changes: 0750814 🔍 Inspect the deploy log: https://app.netlify.com/sites/stackbit-components/deploys/61a6858d35ea0f0008a448c7 😎 Browse the preview: https://deploy-preview-64--stackbit-components.netlify.app |
| ); | ||
| } | ||
|
|
||
| function PageLinks({ pageIndex, baseUrlPath, numOfPages, numOfTotalItems }) { |
There was a problem hiding this comment.
@smnh I tested the pagination in Studio and it worked. Nice!
- I tested changing the "Number of Posts per page" to 3 (of 4) and pagination just worked.
- I tested adding new post pages and they worked.
|
@smnh @TomasBankauskas couple of missing pieces?
Also see my comment in the content pack PR about category pages being empty and some other issues stackbit/stackbit-content-packs#15 (comment) @smnh |
You mean from UI perspective, yes. Any post that has a category, should show a link to that category. <Link href={category.__metadata.pageUrl}>{category.title}</Link> |
e8b2f2d to
f8d71fa
Compare
renamed PostCategoryLayout to PostFeedCategoryLayout
8bd04ac to
5bf6434
Compare
5bf6434 to
ccf3b20
Compare
Two new models and matching components:
PostCategoryLayout extends the PostFeedLayout, both in model and in component. They are exactly the same. The difference is their urlPath that is configured in stackbit.yaml in nextjs-starter.
Related PRs:
stackbit/stackbit-nextjs-starter#21
stackbit/stackbit-content-packs#15