Skip to content

Commit 4c51a2c

Browse files
desig9steinsimeonoffrkaraivanov
authored
fix(chat): Replace hardcoded ig-size (#1975)
--------- Co-authored-by: Simeon Simeonoff <[email protected]> Co-authored-by: Radoslav Karaivanov <[email protected]>
1 parent 89fd04c commit 4c51a2c

File tree

6 files changed

+9
-34
lines changed

6 files changed

+9
-34
lines changed

src/components/chat/themes/chat.base.scss

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -12,10 +12,6 @@ $inline-inset: rem(24px);
1212
display: flex;
1313
flex-direction: column;
1414
container-type: inline-size;
15-
16-
::part(text-input) {
17-
--textarea-height: #{rem(48px)};
18-
}
1915
}
2016

2117
[part='chat-container'] {
@@ -134,7 +130,8 @@ slot[name='prefix'] {
134130
}
135131

136132
igc-list {
137-
--ig-size: 3;
133+
--default-size: 3;
134+
--list-size: var(--component-size);
138135

139136
padding-block-end: rem(24px);
140137
min-height: fit-content;
@@ -143,6 +140,8 @@ igc-list {
143140
}
144141

145142
igc-list-item {
143+
--ig-icon-default-size: var(--list-size);
144+
146145
cursor: pointer;
147146
}
148147

src/components/chat/themes/input.base.scss

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -52,10 +52,6 @@
5252
min-width: rem(90px);
5353
max-width: fit-content;
5454
flex: 1 1;
55-
56-
igc-chip {
57-
--ig-size: 2;
58-
}
5955
}
6056

6157
igc-textarea::part(input) {
@@ -64,9 +60,8 @@ igc-textarea::part(input) {
6460
overflow-y: auto;
6561
}
6662

67-
igc-icon-button,
68-
igc-textarea {
69-
--ig-size: 2;
63+
igc-icon-button {
64+
--default-size: 2;
7065
}
7166

7267
@container (max-width: 400px) {

src/components/chat/themes/shared/chat.bootstrap.scss

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -3,12 +3,6 @@
33

44
$theme: $bootstrap;
55

6-
:host {
7-
::part(text-input) {
8-
--textarea-height: #{rem(38px)};
9-
}
10-
}
11-
126
[part='header'] {
137
box-shadow: none;
148
border-block-end: rem(1px) solid var-get($theme, 'header-border');
Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,5 @@
11
@use 'styles/utilities' as *;
22

3-
:host {
4-
::part(text-input) {
5-
--textarea-height: #{rem(40px)};
6-
}
7-
}
8-
93
slot[name='title'] {
104
@include type-style('subtitle-2') {
115
margin: 0;
@@ -14,4 +8,4 @@ slot[name='title'] {
148

159
slot[name='prefix'] {
1610
margin-inline-end: rem(16px);
17-
}
11+
}

src/components/chat/themes/shared/chat.indigo.scss

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -3,12 +3,6 @@
33

44
$theme: $indigo;
55

6-
:host {
7-
::part(text-input) {
8-
--textarea-height: #{rem(28px)};
9-
}
10-
}
11-
126
[part='header'] {
137
box-shadow: none;
148
border-block-end: rem(1px) solid var-get($theme, 'header-border');
@@ -29,5 +23,5 @@ slot[name='actions'] {
2923
}
3024

3125
igc-list {
32-
--ig-size: 2;
33-
}
26+
--default-size: 2;
27+
}

src/components/textarea/themes/textarea.base.scss

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,6 @@ textarea {
5757

5858
&::placeholder {
5959
opacity: 1;
60-
line-height: normal;
6160
}
6261
}
6362

0 commit comments

Comments
 (0)