[codex] fix today top news tag layout - #9
Conversation
There was a problem hiding this comment.
Code Review
This pull request removes an unused import in RankList.vue and refactors the layout of .news-title-group from flexbox to grid, adding text truncation and responsive styling for tags and titles. The feedback suggests wrapping the -webkit-box-orient property with Autoprefixer ignore comments to prevent it from being stripped during production builds.
Important
The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.
| display: -webkit-box; | ||
| -webkit-box-orient: vertical; | ||
| -webkit-line-clamp: 2; |
There was a problem hiding this comment.
In many build environments (especially Vue 2 projects using Webpack and Autoprefixer), Autoprefixer will automatically strip the -webkit-box-orient: vertical property during the production build because it considers it redundant or non-standard.
To prevent Autoprefixer from removing this property and breaking the multi-line truncation, you should wrap it with Autoprefixer control comments.
display: -webkit-box;
/* autoprefixer: ignore next */
-webkit-box-orient: vertical;
-webkit-line-clamp: 2;
Summary
setimport fromRankList.vueWhy
The API currently returns some
hot_tagvalues that are much longer than the intended 4-character label. In the existing flex layout, a long tag could grow horizontally and force the headline to become extremely narrow and ellipsized.Validation
npm run builddistvia Playwright onhttp://127.0.0.1:4174/tagWidth=96,titleWidth=602Notes
eslint src/views/RankList.vuestill reports long-standing style violations across the whole file. Fixing those would require a wholesale file reformat, so this PR keeps the scope to the functional layout bug only.