Skip to content

Commit

Permalink
feat(card): overflow hidden on cover photo for swc implementation (#2661
Browse files Browse the repository at this point in the history
)

Adds overflow hidden to the .spectrum-Card-coverPhoto class, to help
resolve an issue in the SWC implementation that uses sp-asset.

In SWC the photo could appear from behind the corners of the card. For
example, when increasing the corner rounding when setting the mod
--mod-card-corner-radius. This issue is not visible in Spectrum CSS.
  • Loading branch information
jawinn authored Apr 16, 2024
1 parent f0cdafe commit adcedb3
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions components/card/index.css
Original file line number Diff line number Diff line change
Expand Up @@ -365,6 +365,7 @@ governing permissions and limitations under the License.
var(--spectrum-card-preview-minimum-height)
);
box-sizing: border-box;
overflow: hidden;

display: flex;
align-items: center;
Expand Down

0 comments on commit adcedb3

Please sign in to comment.