Skip to content

Commit

Permalink
fix(components): fix render context issues in the post-collapsible
Browse files Browse the repository at this point in the history
…component (#4478)
  • Loading branch information
oliverschuerch authored Jan 21, 2025
1 parent b72d300 commit 61ef1b4
Show file tree
Hide file tree
Showing 5 changed files with 20 additions and 9 deletions.
5 changes: 5 additions & 0 deletions .changeset/angry-eagles-appear.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'@swisspost/design-system-components': patch
---

Positioned the `post-collapsible` host relative so every not static positioned element within uses it as its base render context and therefore gets clipped as it should.
5 changes: 5 additions & 0 deletions .changeset/cold-bags-chew.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'@swisspost/design-system-styles': patch
---

Positioned `ul.list-bullet > li::before` elements statically, so they can't cause render context issues anymore.
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
:host {
display: block;
position: relative;
overflow: hidden;
}
2 changes: 1 addition & 1 deletion packages/styles/src/mixins/_list.scss
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
display: block;
content: '';
box-sizing: content-box;
position: absolute;
float: inline-start;
margin-block-start: calc(
(#{tokens.get('body-line-height', elements.$post-body)} * 0.5em) -
(#{tokens.get('list-bullet-item-icon-bullet-size', elements.$post-listbullet)} * 0.5)
Expand Down
16 changes: 8 additions & 8 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 61ef1b4

Please sign in to comment.