orangeCatDeveloper opened a new pull request, #4219:
URL: https://github.com/apache/hertzbeat/pull/4219

   ## What's changed?
   
   Refactors the blog list page from the default Docusaurus list into a 
card-based
   layout, as requested in #2075.
   
   - Featured hero block (1 large + 3 side posts) above a three-column card grid
   - Category filter: Releases / Engineering / Tutorials / Community, defined in
     `blog/tags.yml` and applied to all existing posts
   - Numbered pagination, keeping scroll position when switching pages
   - Cover image for every post, with a CSS-generated fallback so `image` stays
     optional for contributors
   - Fixes `postsPerPage`, which was `1` and rendered one post per page
   
   ## Before / after
   
   <!-- 截图占位:before -->
   
   <!-- 截图占位:after -->
   
   ## How to review
   
   Please review by looking at the rendered pages rather than the diff — most 
of the
   211 files are front matter and cover images.
   
   ```shell
   git fetch https://github.com/orangeCatDeveloper/hertzbeat.git 
feat/blog-list-ui
   git checkout FETCH_HEAD
   cd home && pnpm install && pnpm start          # English
   cd home && pnpm run start-zh-cn                # Chinese
   ```
   
   Worth checking:
   
   - `/blog` — hero block, card grid, category pills, pagination
   - `/blog/tags/releases` — category filtering
   - `/blog/page/2` and onwards — pagination keeps scroll position
   - Dark mode, and narrow windows (3 / 2 / 1 columns)
   - `/zh-cn/blog` — category labels and dates are localized
   
   ## Notes
   
   - `@docusaurus/theme-common` is added as a direct dependency; it was already 
an
     indirect one, but pnpm's strict `node_modules` means swizzled components 
cannot
     import it otherwise.
   - Cover images are generated from a template, not hand-designed. See
     `home/scripts/covers/README.md` to add or regenerate one.
   - `home/docs/community/document.md` now documents the blog front matter 
fields.
   
   ## Known follow-ups
   
   - The old tag pages `/blog/tags/opensource`, `/practice` and `/release` 
disappear
     with the new category scheme. Redirects should be added before this ships.
   - The `ko` locale has no `tags.yml`, so category labels fall back to English.
   
   ## Checklist
   
   - [x] I have read the [Contributing 
Guide](https://hertzbeat.apache.org/docs/community/code_style_and_quality_guide)
   - [x] I have written the necessary doc or comment.
   - [ ] I have added the necessary unit tests and all cases have passed.
   
   ## Add or update API
   
   - [ ] I have added the necessary [e2e 
tests](https://github.com/apache/hertzbeat/tree/master/e2e) and all cases have 
passed.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to