mirror of
https://github.com/go-gitea/gitea.git
synced 2026-03-02 21:55:41 +01:00
## Summary Replace combinations of `tw-flex tw-items-center` (with optional `tw-gap-*`) with semantic `flex-text-block` or `flex-text-inline` classes across 15 template files. This follows the refactoring direction outlined in #35015 ("Refactor legacy `tw-flex tw-items-center tw-gap-xx` to `flex-text-block` or `flex-text-inline`"). ## Changes ### Replacement rules applied: - `tw-flex tw-items-center tw-gap-2` → `flex-text-block` (both have `gap: 0.5rem`) - `tw-flex tw-items-center tw-gap-1` → `flex-text-inline` (both have `gap: 0.25rem`) - `tw-flex tw-items-center` (no explicit gap) → `flex-text-block` where the element is block-level and children benefit from the default gap - `tw-flex tw-items-center` (inline context, e.g. `<a>`, `<span>`) → `flex-text-inline` ### Files modified (15): - `templates/admin/config.tmpl` — config page dt elements - `templates/admin/repo/unadopted.tmpl` — unadopted repo list items - `templates/base/head_navbar.tmpl` — active stopwatch popup - `templates/org/header.tmpl` — org header action buttons - `templates/org/home.tmpl` — member/team count links - `templates/org/settings/labels.tmpl` — labels page header - `templates/repo/branch/list.tmpl` — branch list header - `templates/repo/commits_table.tmpl` — commits table header - `templates/repo/diff/box.tmpl` — diff detail box - `templates/repo/diff/new_review.tmpl` — review form header - `templates/repo/issue/card.tmpl` — issue card unpin button - `templates/repo/issue/view_content/attachments.tmpl` — attachment file size - `templates/repo/migrate/migrate.tmpl` — migration service cards - `templates/shared/user/org_profile_avatar.tmpl` — org profile header - `templates/webhook/new.tmpl` — webhook type dropdown text ### What was NOT changed: - Elements with `tw-justify-between` or `tw-justify-center` (these need additional classes) - Elements whose children use explicit margins (`tw-mr-*`, `tw-ml-*`) that would conflict with the gap from flex-text classes - Fomantic UI form elements with special layout requirements ## Notes - This PR was created with AI assistance (Claude). All changes were reviewed individually to ensure semantic correctness and zero unintended visual changes. - No functional changes — purely CSS class refactoring. Closes: part of #35015 Signed-off-by: xiaox315 <xiaox315@users.noreply.github.com> Co-authored-by: xiaox315 <xiaox315@users.noreply.github.com>