Skip to content

Commit

Permalink
BREAKING CHANGE(web-twig): Toast JS Plugin docs updated
Browse files Browse the repository at this point in the history
- `isUnderlined` changed to `underlined` in documentation of `Toast` JS
plugin to better reflect changes in react and twig `Link` component and
changes in web plugin
- Removed isUnderlined prop from ToastBarLink test fixture because
this prop does not exist on this component

- solves #DS-1509
  • Loading branch information
pavelklibani committed Oct 16, 2024
1 parent 84d30b3 commit 3e00871
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 13 deletions.
8 changes: 8 additions & 0 deletions docs/migrations/web-twig/MIGRATION-v4.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,14 @@ We've removed this default to encourage developers to explicitly choose a more a

- `<Heading … />``<Heading elementType="{/* Your semantic HTML element here */}" … />`

### Link `isUnderlined`

The `isUnderlined` property was removed, please use `underlined` instead.

#### Migration Guide

- `<Link isUnderlined … />``<Link underlined="always" … />`

---

Please refer back to this guide or reach out to our team if you encounter any issues during migration.
Expand Down
13 changes: 2 additions & 11 deletions packages/web-twig/DEPRECATIONS.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,17 +6,8 @@ This document lists all deprecations that will be removed in the next major vers
## Deprecations

👉 [What are deprecations?][readme-deprecations]

### Link `isUnderlined`

`isUnderlined` property will be replaced in the next major version. Please use `underlined` instead.
Nothing here right now! 🎉

#### Migration Guide

```diff
- <Link isUnderlined … />
+ <Link underlined="always" … />
```
👉 [What are deprecations?][readme-deprecations]

[readme-deprecations]: https://github.com/lmc-eu/spirit-design-system/blob/main/packages/web-twig/README.md#deprecations
2 changes: 1 addition & 1 deletion packages/web-twig/src/Resources/components/Toast/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -370,7 +370,7 @@ const toast = new Toast(null, {
linkProps: {
href: 'https://example.com', // Link URL
target: '_blank', // Optional link target attribute
isUnderlined: false, // Optional link underlining, default: true
underlined: 'never', // Optional link underlining, Optional link underlining, one of ['always' (default), 'hover', 'never']
isDisabled: false, // Optional link disabling, default: false
elementType: 'a', // Optional link element type, default: 'a'
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@
<ToastBarLink
href="https://www.google.com"
target="_blank"
isUnderlined={false}
isDisabled={false}
UNSAFE_className="custom-class"
UNSAFE_style="outline: 5px solid blue; outline-offset: -5px;"
Expand Down

0 comments on commit 3e00871

Please sign in to comment.