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

BREAKING CHANGE: Remove feature class for bordered Alert #DS-1230 #1382

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 0 additions & 5 deletions packages/web-react/src/components/Alert/demo/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -23,11 +23,6 @@ ReactDOM.createRoot(document.getElementById('root') as HTMLElement).render(
<DocsSection title="Alert Icons" stackAlignment="stretch">
<AlertIcons />
</DocsSection>
<div className="spirit-feature-alert-enable-bordered">
<DocsSection title="Feature Flag: Bordered Alert" stackAlignment="stretch">
<AlertColors />
</DocsSection>
</div>
</IconsProvider>
</React.StrictMode>,
);
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,4 @@
{% include '@components/Alert/stories/AlertIcons.twig' %}
</DocsSection>

<div class="spirit-feature-alert-enable-bordered">
<DocsSection title="Feature Flag: Bordered Alert" stackAlignment="stretch">
{% include '@components/Alert/stories/AlertColors.twig' %}
</DocsSection>
</div>

{% endblock %}
11 changes: 1 addition & 10 deletions packages/web/DEPRECATIONS-v2.md
Original file line number Diff line number Diff line change
@@ -1,20 +1,11 @@
# Deprecations List

Following deprecations and feature flags will be removed in version 2 of the _spirit-web_ package.
Following deprecations will be removed in version 2 of the _spirit-web_ package.

> Please follow these steps to safely upgrade your design system to Spirit Design System v2 components.

[What are deprecations?][readme-deprecations]

[What are feature flags?][readme-feature-flags]

## Feature Flags

### Alert Bordered

The feature flag enabling the bordered variant of alert will be removed and the bordered variant will
be enabled by default.

## Deprecations

### Tooltip and Dropdown Placements
Expand Down
17 changes: 0 additions & 17 deletions packages/web/src/scss/components/Alert/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -67,20 +67,3 @@ Variants:
<div>Data update failed due to missing internet connection</div>
</div>
```

## Feature Flag: Bordered Alert

The Alert border feature flag is not disabled by default. To enable it, either set the
`$alert-enable-bordered` Sass feature flag to `true` or use the `spirit-feature-alert-enable-bordered`
CSS class on any parent of the Alert.

For more info, see main [README][readme-feature-flags].

### ⚠️ DEPRECATION NOTICE

The Alert will be bordered by default in the next major release.

[What are deprecations?][readme-deprecations]

[readme-deprecations]: https://github.com/lmc-eu/spirit-design-system/tree/main/packages/web/README.md#deprecations
[readme-feature-flags]: https://github.com/lmc-eu/spirit-design-system/tree/main/packages/web/README.md#feature-flags
14 changes: 1 addition & 13 deletions packages/web/src/scss/components/Alert/_Alert.scss
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
@use 'theme';
@use '../../settings/feature-flags';
@use '../../tools/dictionaries';
@use '../../tools/typography';

Expand All @@ -12,19 +11,8 @@
justify-content: flex-start;
width: 100%;
padding: theme.$padding;
border-radius: theme.$border-radius;

// @deprecated The feature flag will be removed in the next major version.
// Migration: delete this feature flag and make the bordered version the default.
@if feature-flags.$alert-enable-bordered {
border: theme.$border-width theme.$border-style var(--alert-color);
curdaj marked this conversation as resolved.
Show resolved Hide resolved
}
}

// @deprecated The feature flag will be removed in the next major version.
// Migration: delete this feature flag and make the bordered version the default.
.spirit-feature-alert-enable-bordered .Alert {
border: theme.$border-width theme.$border-style var(--alert-color);
border-radius: theme.$border-radius;
}

.Alert strong {
Expand Down
43 changes: 0 additions & 43 deletions packages/web/src/scss/components/Alert/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -123,47 +123,4 @@ <h2 class="docs-Heading">Alert Icons</h2>

</section>

<div class="spirit-feature-alert-enable-bordered">
<section class="docs-Section">
<h2 class="docs-Heading">Feature Flag: Bordered Alert</h2>

<div class="docs-Stack docs-Stack--stretch">

<div class="Alert Alert--success" role="alert">
<svg width="24" height="24">
<use xlink:href="/assets/icons/svg/sprite.svg#check-plain" />
</svg>
<div>We sent you an activation link to email <strong>[email protected]</strong>. See <a href="./" class="link-underlined">FAQ</a> for more info.</div>
</div>

<div class="Alert Alert--informative" role="alert">
<svg width="24" height="24">
<use xlink:href="/assets/icons/svg/sprite.svg#info" />
</svg>
<div>
Lorem ipsum dolor sit amet, consectetur adipisicing elit. Aliquam at excepturi laudantium magnam mollitia
perferendis reprehenderit, voluptate. Cum delectus dicta ducimus eligendi excepturi natus perferendis
provident unde. Eveniet, iste, molestiae? See <a href="./" class="link-underlined">FAQ</a> for more info.
</div>
</div>

<div class="Alert Alert--warning" role="alert">
<svg width="24" height="24">
<use xlink:href="/assets/icons/svg/sprite.svg#warning" />
</svg>
<div><strong>Warning!</strong> Data update failed due to missing internet connection. See <a href="./" class="link-underlined">FAQ</a> for more info.</div>
</div>

<div class="Alert Alert--danger" role="alert">
<svg width="24" height="24">
<use xlink:href="/assets/icons/svg/sprite.svg#danger" />
</svg>
<div>Data update failed due to missing internet connection. See <a href="./" class="link-underlined">FAQ</a> for more info.</div>
</div>

</div>

</section>
</div>

{{/layout/web-plain }}
1 change: 0 additions & 1 deletion packages/web/src/scss/components/Dropdown/_Dropdown.scss
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
@use 'sass:map';
@use '../../settings/feature-flags';
@use '../../tools/breakpoint';
@use '../../tools/dictionaries';
@use '../../tools/placement';
Expand Down
1 change: 0 additions & 1 deletion packages/web/src/scss/components/Modal/_ModalDialog.scss
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@
// 4. Override bottom padding of parent `.Modal` in the docked variant.

@use 'sass:map';
@use '../../settings/feature-flags';
@use '../../tools/breakpoint';
@use '../../tools/typography';
@use 'theme';
Expand Down
1 change: 0 additions & 1 deletion packages/web/src/scss/components/Tooltip/_Tooltip.scss
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@
// 2. Reuse already generated custom properties to allow overriding the arrow appearance live in the browser.

@use 'sass:math';
@use '../../settings/feature-flags';
@use '../../tools/dictionaries';
@use '../../tools/placement';
@use '../../tools/reset';
Expand Down
1 change: 0 additions & 1 deletion packages/web/src/scss/settings/_feature-flags.scss

This file was deleted.

Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading