Skip to content

Commit

Permalink
fix(ARCH-720): Improve usage of info tokens and fix bootstrap button (#…
Browse files Browse the repository at this point in the history
…4850)

* fix(ARCH-720): Improve usage of info tokens and fix bootstrap button

* update changeset
  • Loading branch information
Gbacc authored Aug 30, 2023
1 parent 72b95c8 commit fbce059
Show file tree
Hide file tree
Showing 15 changed files with 36 additions and 25 deletions.
9 changes: 9 additions & 0 deletions .changeset/fresh-dolls-kneel.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
---
'@talend/design-system': patch
'@talend/react-components': patch
'@talend/bootstrap-theme': patch
---

Improve usage of design tokens for info variants


Original file line number Diff line number Diff line change
Expand Up @@ -85,11 +85,11 @@ $tc-collapsible-panel-padding-larger: $padding-larger !default;

&.info {
:global(.panel-heading) {
border-left-color: tokens.$coral-color-accent-text;
border-left-color: tokens.$coral-color-info-text;
}

:global(.tc-status-label) {
color: tokens.$coral-color-accent-text;
color: tokens.$coral-color-info-text;
}
}

Expand Down
4 changes: 2 additions & 2 deletions packages/components/src/Status/Status.module.scss
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ $tc-status-space-btn-icon-label: 5px !default;
}

&.info {
color: tokens.$coral-color-accent-icon;
color: tokens.$coral-color-info-icon;
}

&.success {
Expand All @@ -45,7 +45,7 @@ $tc-status-space-btn-icon-label: 5px !default;
font-weight: 600;

&.info {
color: tokens.$coral-color-accent-text;
color: tokens.$coral-color-info-text;
}

&.success {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,11 @@

.information {
&_withBackground {
background-color: tokens.$coral-color-accent-background;
box-shadow: tokens.$coral-elevation-shadow-accent;
background-color: tokens.$coral-color-info-background;
box-shadow: tokens.$coral-elevation-shadow-info;
}

&__icon {
color: tokens.$coral-color-accent-icon;
color: tokens.$coral-color-info-icon;
}
}
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
@use '~@talend/design-tokens/lib/tokens';

.information_border {
border-left-color: tokens.$coral-color-accent-icon;
border-left-color: tokens.$coral-color-info-icon;
}
Original file line number Diff line number Diff line change
Expand Up @@ -39,10 +39,10 @@
}

&.inProgress {
color: tokens.$coral-color-accent-text;
color: tokens.$coral-color-info-text;

.status__icon {
color: tokens.$coral-color-accent-icon;
color: tokens.$coral-color-info-icon;
}
}

Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
@use '~@talend/design-tokens/lib/tokens';

.tag {
color: tokens.$coral-color-accent-text-strong;
background: tokens.$coral-color-accent-background;
color: tokens.$coral-color-info-text-strong;
background: tokens.$coral-color-info-background;
}
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ import DefinitionListColors from './components/DefinitionList/DefinitionListColo
const colorOrder = [
'neutral',
'accent',
'info',
'success',
'warning',
'danger',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ const TokensDefinitionList = ({ tokens }: TokensProps) => {
const filteredTokens = {
neutral: tokens.filter((token: Token) => token.name.includes('ColorNeutral')),
accent: tokens.filter((token: Token) => token.name.includes('ColorAccent')),
info: tokens.filter((token: Token) => token.name.includes('ColorInfo')),
success: tokens.filter((token: Token) => token.name.includes('ColorSuccess')),
danger: tokens.filter((token: Token) => token.name.includes('ColorDanger')),
warning: tokens.filter((token: Token) => token.name.includes('ColorWarning')),
Expand Down
6 changes: 3 additions & 3 deletions packages/theme/src/theme/_labels.scss
Original file line number Diff line number Diff line change
Expand Up @@ -81,13 +81,13 @@ a.label {
}

.label-info {
color: tokens.$coral-color-accent-text;
background: tokens.$coral-color-accent-background;
color: tokens.$coral-color-info-text;
background: tokens.$coral-color-info-background;

&[href] {
&:hover,
&:focus {
background: tokens.$coral-color-accent-background;
background: tokens.$coral-color-info-background;
}
}
}
Expand Down
6 changes: 3 additions & 3 deletions packages/theme/src/theme/_panels.scss
Original file line number Diff line number Diff line change
Expand Up @@ -41,11 +41,11 @@
}

.panel-info {
border-color: tokens.$coral-color-accent-border;
border-color: tokens.$coral-color-info-border;

.panel-heading {
color: tokens.$coral-color-accent-text;
background-color: tokens.$coral-color-accent-background;
color: tokens.$coral-color-info-text;
background-color: tokens.$coral-color-info-background;
}
}

Expand Down
4 changes: 2 additions & 2 deletions packages/theme/src/theme/_tables.scss
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
> tr.info {
td {
color: tokens.$coral-color-neutral-text;
background: tokens.$coral-color-accent-background;
background: tokens.$coral-color-info-background;
}
}

Expand Down Expand Up @@ -68,7 +68,7 @@

> tr.info:hover {
td {
background: tokens.$coral-color-accent-background-hover;
background: tokens.$coral-color-info-background-hover;
}
}

Expand Down
2 changes: 1 addition & 1 deletion packages/theme/src/theme/_type.scss
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ p,
}

.text-info {
color: tokens.$coral-color-accent-text;
color: tokens.$coral-color-info-text;
}

a {
Expand Down
2 changes: 1 addition & 1 deletion packages/theme/src/theme/_variables.scss
Original file line number Diff line number Diff line change
Expand Up @@ -690,7 +690,7 @@ $progress-bar-warning-bg: tokens.$coral-color-warning-background-strong !default
//** Danger progress bar color
$progress-bar-danger-bg: tokens.$coral-color-danger-background-strong !default;
//** Info progress bar color
$progress-bar-info-bg: tokens.$coral-color-accent-background-strong !default;
$progress-bar-info-bg: tokens.$coral-color-info-background-strong !default;

//== List group
//
Expand Down
6 changes: 3 additions & 3 deletions packages/theme/src/theme/alerts.scss
Original file line number Diff line number Diff line change
Expand Up @@ -32,10 +32,10 @@

.alert-info {
color: tokens.$coral-color-neutral-text;
background-color: tokens.$coral-color-accent-background;
border-color: tokens.$coral-color-accent-border;
background-color: tokens.$coral-color-info-background;
border-color: tokens.$coral-color-info-border;

.alert-link {
color: tokens.$coral-color-accent-text;
color: tokens.$coral-color-info-text;
}
}

0 comments on commit fbce059

Please sign in to comment.