Repository navigation
chore: Adds internal style api v2 to action card - #5247
Merged
Merged
Conversation
Contributor
There was a problem hiding this comment.
🟡 Changes recommended
The internal-only styleClassNames prop lacks the required __ prefix and must be renamed while preserving the public styling entry point.
1 open issue
What changed in this PR
Adds internal Style API v2 support to Action Card, allowing custom styling of its root and header without expanding the public props interface.
Changes:
- Adds root and header style slots with border, radius, and focus-ring customization.
- Adds unit tests for slot classes, conditional headers, and DOM prop filtering.
- Adds a styled demo page; style-docs snapshots and visual regression registration remain deferred.
| File | Description |
|---|---|
src/action-card/styles.scss |
Registers style slots and applies customizable borders, corners, and focus styling. |
src/action-card/mixins.scss |
Resolves style tokens for state-dependent borders and radii. |
src/action-card/internal.tsx |
Applies internal root and header class names. |
src/action-card/__tests__/style-api.test.tsx |
Tests slot assignment and prop handling. |
pages/action-card/style-api-v2.scss |
Defines example root and header customizations. |
pages/action-card/style-api-v2.page.tsx |
Demonstrates styling across card variants and states. |
Review effort: Balanced
| export type InternalActionCardProps = ActionCardProps & InternalBaseComponentProps; | ||
| export type InternalActionCardProps = ActionCardProps & | ||
| InternalBaseComponentProps & { | ||
| styleClassNames?: StyleClassNames; |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #5247 +/- ##
=======================================
Coverage 97.82% 97.83%
=======================================
Files 1006 1008 +2
Lines 32621 32585 -36
Branches 12117 12095 -22
=======================================
- Hits 31913 31881 -32
+ Misses 666 663 -3
+ Partials 42 41 -1 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
vvaliyev
force-pushed
the
style-v2-action-card
branch
from
November 5, 2026 06:55
59bf277 to
c3fab2c
Compare
vvaliyev
marked this pull request as ready for review
November 5, 2026 10:38
vvaliyev
requested review from
pan-kot and
srungta08
and removed request for
a team
November 5, 2026 10:38
vvaliyev
force-pushed
the
style-v2-action-card
branch
from
November 6, 2026 13:32
c3fab2c to
52f7ab6
Compare
vvaliyev
force-pushed
the
style-v2-action-card
branch
from
November 6, 2026 13:38
52f7ab6 to
6b7ae56
Compare
vvaliyev
force-pushed
the
style-v2-action-card
branch
3 times, most recently
from
November 6, 2026 14:36
9fde8ef to
58fc8be
Compare
vvaliyev
force-pushed
the
style-v2-action-card
branch
from
November 6, 2026 14:44
58fc8be to
b9ddab2
Compare
pan-kot
approved these changes
Nov 6, 2026
This branch was successfully deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.

Description
Adds the internal Style API v2 to Action card:
rootandheader(rendered whenheaderordescriptionis set).With a top-aligned
icon, the header spans the icon column; with a centeredicon, the icon column stays outside the header.A top-aligned
iconwith adescriptionand noheadernow renders in the header row, so the content runs the full card width under the icon.The style-docs snapshot and the VR registration of the dev page follow in one PR for all components.
Tracker section: P3d34KdbCd6o.
Related links, issue #, if available: n/a
How has this been tested?
Unit tests for every slot, dev page
action-card/style-api-v2, build and lint green.Review checklist
The following items are to be evaluated by the author(s) and the reviewer(s).
Correctness
CONTRIBUTING.md.CONTRIBUTING.md.Security
checkSafeUrlfunction.Testing
By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.