diff --git a/projects/addon-mobile/styles/common/badge.less b/projects/addon-mobile/styles/common/badge.less index 5720b67786f7..69817235e01f 100644 --- a/projects/addon-mobile/styles/common/badge.less +++ b/projects/addon-mobile/styles/common/badge.less @@ -15,7 +15,7 @@ tui-badge, font: var(--tui-font-text-s); font-weight: bold; - --t-padding: 0 0.625rem 0 0.375rem; + --t-padding: 0 0.625rem; --t-size: 1.75rem; } } diff --git a/projects/core/styles/mixins/mixins.less b/projects/core/styles/mixins/mixins.less index d0c375245dc3..0d5cd13bf12f 100644 --- a/projects/core/styles/mixins/mixins.less +++ b/projects/core/styles/mixins/mixins.less @@ -65,8 +65,9 @@ text-decoration: none; } -.chip() { +.button-base() { .clearbtn(); + position: relative; display: inline-flex; align-items: center; flex-shrink: 0; @@ -75,7 +76,21 @@ overflow: hidden; vertical-align: middle; max-width: 100%; - font: var(--tui-font-text-s); + gap: calc(var(--t-gap) - 2 * var(--t-margin)); + + > img, + > tui-svg, + > tui-icon, + > tui-avatar, + > tui-badge, + > [tuiBadge], + > [tuiRadio], + > [tuiToggle], + > [tuiCheckbox], + &._icon-left:before, + &._icon-right:after { + margin: var(--t-margin); + } } .autofill(@mode:default) { diff --git a/projects/core/styles/mixins/mixins.scss b/projects/core/styles/mixins/mixins.scss index f9a1d43d8cb9..d95ee8a37913 100644 --- a/projects/core/styles/mixins/mixins.scss +++ b/projects/core/styles/mixins/mixins.scss @@ -64,9 +64,10 @@ line-height: inherit; } -@mixin chip() { +@mixin button-base() { @include clearbtn(); + position: relative; display: inline-flex; align-items: center; flex-shrink: 0; @@ -75,9 +76,21 @@ overflow: hidden; vertical-align: middle; max-width: 100%; - padding: var(--t-padding); - height: var(--t-size); - font: var(--tui-font-text-s); + gap: calc(var(--t-gap) - 2 * var(--t-margin)); + + > img, + > tui-svg, + > tui-icon, + > tui-avatar, + > tui-badge, + > [tuiBadge], + > [tuiRadio], + > [tuiToggle], + > [tuiCheckbox], + &._icon-left:before, + &._icon-right:after { + margin: var(--t-margin); + } } @mixin autofill($mode: default) { diff --git a/projects/core/styles/theme/appearance/icon.less b/projects/core/styles/theme/appearance/icon.less index e33b44af7f4f..ea2e8f0033e2 100644 --- a/projects/core/styles/theme/appearance/icon.less +++ b/projects/core/styles/theme/appearance/icon.less @@ -18,6 +18,7 @@ [tuiAppearance][data-appearance='floating'] { &:before, &:after { + .transition(color); color: var(--tui-text-03); } diff --git a/projects/demo/src/modules/app/pages.ts b/projects/demo/src/modules/app/pages.ts index 4d7523f9d472..179fbd41ac56 100644 --- a/projects/demo/src/modules/app/pages.ts +++ b/projects/demo/src/modules/app/pages.ts @@ -953,7 +953,7 @@ export const pages: TuiDocPages = [ }, { section: `Experimental`, - title: `Tooltip`, + title: `Tooltip `, keywords: `tooltip, тултип, hint, подсказка, помощь, help`, route: `/experimental/tooltip`, }, diff --git a/projects/demo/src/modules/experimental/badge/badge.component.ts b/projects/demo/src/modules/experimental/badge/badge.component.ts index 22c5848d339c..4cc0ef9d3ba2 100644 --- a/projects/demo/src/modules/experimental/badge/badge.component.ts +++ b/projects/demo/src/modules/experimental/badge/badge.component.ts @@ -19,7 +19,6 @@ export class ExampleTuiBadgeComponent { readonly example1: TuiDocExample = { HTML: import('./examples/1/index.html?raw'), - LESS: import('./examples/1/index.less?raw'), }; readonly example2: TuiDocExample = { diff --git a/projects/demo/src/modules/experimental/badge/examples/1/index.html b/projects/demo/src/modules/experimental/badge/examples/1/index.html index 48fd3addcb4c..c967a164f061 100644 --- a/projects/demo/src/modules/experimental/badge/examples/1/index.html +++ b/projects/demo/src/modules/experimental/badge/examples/1/index.html @@ -10,7 +10,7 @@

Use CSS for support colors

Taiga diff --git a/projects/demo/src/modules/experimental/badge/examples/1/index.less b/projects/demo/src/modules/experimental/badge/examples/1/index.less index a11c3840af21..c16dfe297f00 100644 --- a/projects/demo/src/modules/experimental/badge/examples/1/index.less +++ b/projects/demo/src/modules/experimental/badge/examples/1/index.less @@ -1,13 +1,3 @@ tui-badge { margin: 0.5rem; } - -@iterations: 20; - -.loop (@i) when (@i > 0) { - .support-@{i} { - background-color: ~'var(--tui-support-@{i}, var(--tui-support-0@{i}))'; - } - .loop(@i - 1); -} -.loop (@iterations); diff --git a/projects/demo/src/modules/experimental/chip/chip.module.ts b/projects/demo/src/modules/experimental/chip/chip.module.ts index fe3d866f7737..e669e524fd11 100644 --- a/projects/demo/src/modules/experimental/chip/chip.module.ts +++ b/projects/demo/src/modules/experimental/chip/chip.module.ts @@ -13,7 +13,6 @@ import { TuiCheckboxModule, TuiChipModule, TuiFadeModule, - TuiIconModule, } from '@taiga-ui/experimental'; import {ExampleTuiChipComponent} from './chip.component'; @@ -28,7 +27,6 @@ import {TuiChipExample4} from './examples/4'; FormsModule, TuiChipModule, TuiRepeatTimesModule, - TuiIconModule, TuiFadeModule, TuiNotificationModule, TuiButtonModule, diff --git a/projects/demo/src/modules/experimental/sensitive/examples/1/index.html b/projects/demo/src/modules/experimental/sensitive/examples/1/index.html index 06ee02aebed4..e6d5e81f2cb3 100644 --- a/projects/demo/src/modules/experimental/sensitive/examples/1/index.html +++ b/projects/demo/src/modules/experimental/sensitive/examples/1/index.html @@ -1,7 +1,7 @@ -
+

Balance: 100 000$ -

+