Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Modal.Block instead of Modal.Header and Modal.Footer #2522

Closed
eirikbacker opened this issue Sep 26, 2024 · 0 comments · Fixed by #2583
Closed

Modal.Block instead of Modal.Header and Modal.Footer #2522

eirikbacker opened this issue Sep 26, 2024 · 0 comments · Fixed by #2583
Labels
css @digdir/designsystemet-css react @digdir/designsystemet-react

Comments

@eirikbacker
Copy link
Contributor

To match Card API, see: #2509

@eirikbacker eirikbacker converted this from a draft issue Sep 26, 2024
@eirikbacker eirikbacker moved this from 🔵 Inbox to 📄 Todo in Team Design System Sep 26, 2024
@eirikbacker eirikbacker added react @digdir/designsystemet-react css @digdir/designsystemet-css labels Sep 26, 2024
eirikbacker added a commit that referenced this issue Oct 1, 2024
- Implements `Card.Block` to simplify API and make it more robust
- Allows putting content directly inside `<Card>`
- Allows putting `<a>` inside a heading instead of using `isLink` -
following
https://adrianroselli.com/2020/02/block-links-cards-clickable-regions-etc.html
for better accessibility
- Supports `<Card asChild><a></a></Card>` as an escape hatch for those
who really needs the whole card to be a link
- Supports `<Card asChild><button></button></Card>`
- Have verified new concept with Øyvind - and will replicate this API
for Modal: #2522
- Have verified that Card should have same border color regardless of
link or not with Lasse
@github-project-automation github-project-automation bot moved this from 📄 Todo to ✅ Done in Team Design System Oct 8, 2024
@github-project-automation github-project-automation bot moved this from 📄 Todo to ✅ Done in Team Design System Oct 8, 2024
unekinn pushed a commit that referenced this issue Oct 10, 2024
Fixes #2522

---------

Co-authored-by: Tobias Barsnes <[email protected]>
unekinn pushed a commit that referenced this issue Oct 11, 2024
- Implements `Card.Block` to simplify API and make it more robust
- Allows putting content directly inside `<Card>`
- Allows putting `<a>` inside a heading instead of using `isLink` -
following
https://adrianroselli.com/2020/02/block-links-cards-clickable-regions-etc.html
for better accessibility
- Supports `<Card asChild><a></a></Card>` as an escape hatch for those
who really needs the whole card to be a link
- Supports `<Card asChild><button></button></Card>`
- Have verified new concept with Øyvind - and will replicate this API
for Modal: #2522
- Have verified that Card should have same border color regardless of
link or not with Lasse
unekinn pushed a commit that referenced this issue Oct 11, 2024
Fixes #2522

---------

Co-authored-by: Tobias Barsnes <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
css @digdir/designsystemet-css react @digdir/designsystemet-react
Projects
Status: ✅ Done
Development

Successfully merging a pull request may close this issue.

1 participant