From e229b2ebdacdc5395b7aced5c731763a67a34bf5 Mon Sep 17 00:00:00 2001 From: Pavel Ivannikov Date: Thu, 19 Sep 2024 15:00:12 +0300 Subject: [PATCH 1/2] fix(layout): changed name of t-gap variable for CardLarge --- projects/addon-mobile/styles/common/card-large.less | 4 ++-- .../components/card-large/examples/1/index.html | 10 ++++++++++ .../modules/components/card-large/examples/1/index.ts | 2 ++ projects/layout/components/card/card.styles.less | 8 ++++---- 4 files changed, 18 insertions(+), 6 deletions(-) diff --git a/projects/addon-mobile/styles/common/card-large.less b/projects/addon-mobile/styles/common/card-large.less index f495bdafb7e3..102fa4876a4c 100644 --- a/projects/addon-mobile/styles/common/card-large.less +++ b/projects/addon-mobile/styles/common/card-large.less @@ -1,12 +1,12 @@ [tuiCardLarge][data-space] { &[data-space='normal'] { --t-padding: 1.25rem; - --t-gap: 1.25rem; + --t-space: 1.25rem; } &[data-space='compact'] { --t-padding: 1rem; - --t-gap: 1rem; + --t-space: 1rem; --t-comp: -0.125rem; } } diff --git a/projects/demo/src/modules/components/card-large/examples/1/index.html b/projects/demo/src/modules/components/card-large/examples/1/index.html index a700adde4bbd..bcac80c15781 100644 --- a/projects/demo/src/modules/components/card-large/examples/1/index.html +++ b/projects/demo/src/modules/components/card-large/examples/1/index.html @@ -30,6 +30,16 @@

Header

>

Header

+ +
Replace me
diff --git a/projects/demo/src/modules/components/card-large/examples/1/index.ts b/projects/demo/src/modules/components/card-large/examples/1/index.ts index d8b1f8137780..39f10effa644 100644 --- a/projects/demo/src/modules/components/card-large/examples/1/index.ts +++ b/projects/demo/src/modules/components/card-large/examples/1/index.ts @@ -3,6 +3,7 @@ import {changeDetection} from '@demo/emulate/change-detection'; import {encapsulation} from '@demo/emulate/encapsulation'; import {TuiPlatform} from '@taiga-ui/cdk'; import {TuiButton, TuiLink, TuiSurface, TuiTitle} from '@taiga-ui/core'; +import {TuiBadge} from '@taiga-ui/kit'; import {TuiCardLarge, TuiHeader} from '@taiga-ui/layout'; @Component({ @@ -15,6 +16,7 @@ import {TuiCardLarge, TuiHeader} from '@taiga-ui/layout'; TuiPlatform, TuiSurface, TuiTitle, + TuiBadge, ], templateUrl: './index.html', styleUrls: ['./index.less'], diff --git a/projects/layout/components/card/card.styles.less b/projects/layout/components/card/card.styles.less index dd076a027130..e1c1ae330442 100644 --- a/projects/layout/components/card/card.styles.less +++ b/projects/layout/components/card/card.styles.less @@ -49,7 +49,7 @@ } [tuiCardLarge][data-space] { - --t-gap: 0.75rem; + --t-space: 0.75rem; --t-radius: var(--tui-radius-l); --t-comp: -0.25rem; --t-padding: 0.75rem; @@ -63,18 +63,18 @@ &[data-space='normal'] { --t-radius: 1.5rem; --t-padding: 1.5rem; - --t-gap: 1.5rem; + --t-space: 1.5rem; } &[data-space='compact'] { --t-radius: 1rem; --t-padding: 1.25rem; - --t-gap: 1.25rem; + --t-space: 1.25rem; } &:not([tuiCell], [tuiHeader]) { flex-direction: column; - gap: var(--t-gap); + gap: var(--t-space); align-items: stretch; > :last-child:not([tuiCell]) { From 4a1f547bac22b36f3ca3f6d21620eea1d05660c9 Mon Sep 17 00:00:00 2001 From: Pavel Ivannikov Date: Thu, 19 Sep 2024 16:17:15 +0300 Subject: [PATCH 2/2] fix(layout): changed imports order for CardLarge example --- .../demo/src/modules/components/card-large/examples/1/index.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/projects/demo/src/modules/components/card-large/examples/1/index.ts b/projects/demo/src/modules/components/card-large/examples/1/index.ts index 39f10effa644..168cca75c72a 100644 --- a/projects/demo/src/modules/components/card-large/examples/1/index.ts +++ b/projects/demo/src/modules/components/card-large/examples/1/index.ts @@ -9,6 +9,7 @@ import {TuiCardLarge, TuiHeader} from '@taiga-ui/layout'; @Component({ standalone: true, imports: [ + TuiBadge, TuiButton, TuiCardLarge, TuiHeader, @@ -16,7 +17,6 @@ import {TuiCardLarge, TuiHeader} from '@taiga-ui/layout'; TuiPlatform, TuiSurface, TuiTitle, - TuiBadge, ], templateUrl: './index.html', styleUrls: ['./index.less'],