Repository navigation
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Review
1.
border-l!— version-dependent, and likely a specificity hack!(important modifier) is Tailwind CSS v4 syntax (and UnoCSS). In Tailwind v3 it's the prefix form!border-l. If this project is on v3, the class silently does nothing. Verify the Tailwind version before merging.!is only needed to win against Element Plus styles, that's a smell: Element's border rules target.el-table--border .el-table__cell(specificity 0,2,0) which beats a plain utility class (0,1,0). Forcing important instead of fixing the selector will bite you later when the theme changes.border-lonly setsborder-left-width. It relies on Element/Tailwind preflight forborder-styleand a saneborder-color. Withborder-collapse: collapseon the table, the rendered width can be inconsistent (collapsed border resolution picks the widest border on the shared edge), so you may get a double or invisible line depending on the neighbouring cell. Use an explicit pair:border-l border-gray-200(or your design token) rather than a bareborder-l!.2. Header cells won't get the border → visual misalignment
class-nameonel-table-columnapplies only to body cells (<td>). The header cell needs the separatelabel-class-nameprop, otherwise the vertical divider stops at the header row.<el-table-column ... class-name="border-l border-gray-200" label-class-name="border-l border-gray-200" />3. Scoped styles / CSS isolation
class-nameinjects classes that must resolve globally, on cells rendered outside this component's scoped-CSS scope. If you use<style scoped>, CSS Modules, a Tailwindprefix, or a build that only scans template files, the class may never apply. Tailwind's content scanning usually covers.vuetemplates, but a prefix would requiretw-border-l!.4. Presentational logic in the template + hard-coded string
const DIVIDER = 'border-l ...') or a helper that returns{ class: ... }.:cell-styleor adividerflag in a column config array.v-if), so for non-admins it may be the first visible column — a left border on the leftmost cell often looks like a stray 1px line. Considerborder-ron the preceding column instead, or a container-level style.5. Prefer Element's own APIs for table borders
If the goal is a simple vertical separator:
borderprop onel-tablefor full grids, or:cell-style/:header-cell-stylefunction so the border is theme-driven (CSS variables likevar(--el-border-color)) and respects dark mode automatically. Hard-coded utility colors won't followel-table's dark-mode variables.6. Minor nits
v-if="currentRole.type !== ROLE_TYPE.ADMIN"— fine, but ifcurrentRolecan be null/undefined during async load, this throws. PrefercurrentRole?.type !== ROLE_TYPE.ADMINor a computed.prop="workspace_name"mixessnake_casewith thecamelCaseused elsewhere (currentRole). Not a bug, just inconsistent with typical Vue/JS naming.min-width="180"works (Vue coerces), but:min-width="180"is explicit and avoids the string→number coercion path.Suggested version
…or, if you only need a divider between column groups, drop the utility classes entirely and set it once via
:cell-styleon the column, or via a container class targetingtd:nth-child(n).