Skip to content

Commit

Permalink
feat(select): changed size L (72 → 64), added size XL (72)
Browse files Browse the repository at this point in the history
BREAKING CHANGE: size L changed to size XL
  • Loading branch information
SiebenSieben committed Mar 2, 2021
1 parent f5fda56 commit af5dc6a
Show file tree
Hide file tree
Showing 6 changed files with 19 additions and 9 deletions.
2 changes: 1 addition & 1 deletion packages/select/src/Component.stories.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ export const POSITION_OPTIONS = [
<Story name='Select'>
<Select
block={boolean('block', false)}
size={selectKnob('size', ['s', 'm', 'l'], 's')}
size={selectKnob('size', ['s', 'm', 'l', 'xl'], 's')}
disabled={boolean('disabled', false)}
error={text('error', '')}
hint={text('hint', '')}
Expand Down
3 changes: 2 additions & 1 deletion packages/select/src/components/optgroup/index.module.css
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,8 @@
min-height: 48px;
}

.l {
.l,
.xl {
min-height: 56px;

padding-left: var(--select-optgroup-l-left-padding);
Expand Down
7 changes: 7 additions & 0 deletions packages/select/src/components/option/index.module.css
Original file line number Diff line number Diff line change
Expand Up @@ -46,8 +46,15 @@
}

.l {
min-height: 64px;
}

.xl {
min-height: 72px;
}

.l,
.xl {
padding-left: var(--select-option-l-left-padding);
padding-right: var(--select-option-l-right-padding);

Expand Down
3 changes: 2 additions & 1 deletion packages/select/src/components/options-list/index.module.css
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
color: var(--select-options-list-empty-placeholder-color);
}

.l .emptyPlaceholder {
.l .emptyPlaceholder,
.xl .emptyPlaceholder {
padding: var(--gap-xl) var(--gap-m);
}
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,7 @@
color: var(--select-options-list-empty-placeholder-color);
}

.l .emptyPlaceholder {
.l .emptyPlaceholder,
.xl .emptyPlaceholder {
padding: var(--gap-xl) var(--gap-m);
}
10 changes: 5 additions & 5 deletions packages/select/src/typings.ts
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ export type BaseSelectProps = {
/**
* Размер компонента
*/
size?: 's' | 'm' | 'l';
size?: 's' | 'm' | 'l' | 'xl';

/**
* Растягивает компонент на ширину контейнера
Expand Down Expand Up @@ -272,7 +272,7 @@ export type FieldProps = {
/**
* Размер компонента
*/
size?: 's' | 'm' | 'l';
size?: 's' | 'm' | 'l' | 'xl';

/**
* Выбранный пункт
Expand Down Expand Up @@ -373,7 +373,7 @@ export type OptionsListProps = {
/**
* Размер компонента
*/
size?: 's' | 'm' | 'l';
size?: 's' | 'm' | 'l' | 'xl';

/**
* Компонент пункта меню
Expand Down Expand Up @@ -425,7 +425,7 @@ export type OptgroupProps = {
/**
* Размер компонента
*/
size?: 's' | 'm' | 'l';
size?: 's' | 'm' | 'l' | 'xl';

/**
* Заголовок группы
Expand All @@ -447,7 +447,7 @@ export type OptionProps = {
/**
* Размер компонента
*/
size?: 's' | 'm' | 'l';
size?: 's' | 'm' | 'l' | 'xl';

/**
* Контент пункта меню
Expand Down

0 comments on commit af5dc6a

Please sign in to comment.