diff --git a/src/common/components/product-info/__stories__/05-not-enough.stories.tsx b/src/common/components/product-info/__stories__/05-not-enough.stories.tsx index 11fdeae8..adee8550 100644 --- a/src/common/components/product-info/__stories__/05-not-enough.stories.tsx +++ b/src/common/components/product-info/__stories__/05-not-enough.stories.tsx @@ -47,7 +47,7 @@ export function NotEnough() { price={250.48} oldPrice={320.96} currencyGrapheme='₽' - unavailableReason='Товара нет в наличии' + unavailableReason='Нет в наличии' /> diff --git a/src/common/components/product-info/__stories__/06-not-enough-waited.stories.tsx b/src/common/components/product-info/__stories__/06-not-enough-waited.stories.tsx index 99d78b64..687cd869 100644 --- a/src/common/components/product-info/__stories__/06-not-enough-waited.stories.tsx +++ b/src/common/components/product-info/__stories__/06-not-enough-waited.stories.tsx @@ -47,7 +47,7 @@ export function NotEnoughWaited() { price={250.48} oldPrice={320.96} currencyGrapheme='₽' - unavailableReason='Товара нет в наличии' + unavailableReason='Нет в наличии' /> diff --git a/src/common/components/product-info/__stories__/08-mature-content.stories.tsx b/src/common/components/product-info/__stories__/08-mature-content.stories.tsx index 4ed20acd..8d123ecf 100644 --- a/src/common/components/product-info/__stories__/08-mature-content.stories.tsx +++ b/src/common/components/product-info/__stories__/08-mature-content.stories.tsx @@ -47,7 +47,7 @@ export function Adult() { price={250.48} oldPrice={320.96} currencyGrapheme='₽' - unavailableReason='Товар доступен только для юридических лиц' + unavailableReason='Товар для взрослых' /> diff --git a/src/common/components/product-info/__test__/product-info.test.tsx b/src/common/components/product-info/__test__/product-info.test.tsx index 5de06442..6958d440 100644 --- a/src/common/components/product-info/__test__/product-info.test.tsx +++ b/src/common/components/product-info/__test__/product-info.test.tsx @@ -187,7 +187,7 @@ describe('ProductInfo', () => { expect(queryAllByTestId('product-image')).toHaveLength(1); expect(queryAllByTestId('badge')).toHaveLength(0); - expect(queryAllByTestId('product-info:price')).toHaveLength(1); + expect(queryAllByTestId('product-info:price')).toHaveLength(0); expect(queryAllByTestId('product-info:old-price')).toHaveLength(0); expect(queryAllByTestId('product-info:name-link')).toHaveLength(0); expect(queryAllByTestId('product-info:trademark-link')).toHaveLength(0); diff --git a/src/common/components/product-info/parts/parts.m.scss b/src/common/components/product-info/parts/parts.m.scss index 857b245e..0841e2d3 100644 --- a/src/common/components/product-info/parts/parts.m.scss +++ b/src/common/components/product-info/parts/parts.m.scss @@ -1,15 +1,11 @@ @use 'node_modules/@sima-land/ui-nucleons/breakpoints'; .text-button { - font-size: 16px; - line-height: 24px; + font-size: 14px; + line-height: 20px; font-weight: 600; &:hover, &:active { font-weight: 600; } - @include breakpoints.down('ml') { - font-size: 14px; - line-height: 20px; - } } diff --git a/src/common/components/product-info/parts/prices.tsx b/src/common/components/product-info/parts/prices.tsx index e85fbe78..713c17d0 100644 --- a/src/common/components/product-info/parts/prices.tsx +++ b/src/common/components/product-info/parts/prices.tsx @@ -19,12 +19,12 @@ export function ProductInfoPrices({ const { restriction } = useContext(ProductInfoContext); const rootClassName = classNames(styles.root, { - [styles['height-limit']]: !restriction || restriction === 'adult', + [styles['height-limit']]: !restriction, }); return (
- {(!restriction || restriction === 'adult') && ( + {!restriction && ( <> )} - {restriction === 'unavailable' && unavailableReason} + {restriction && unavailableReason}
); } diff --git a/src/common/components/product-info/parts/rating-counter.m.scss b/src/common/components/product-info/parts/rating-counter.m.scss index bd2cd4c6..59b8df51 100644 --- a/src/common/components/product-info/parts/rating-counter.m.scss +++ b/src/common/components/product-info/parts/rating-counter.m.scss @@ -3,10 +3,5 @@ .root { margin-top: 8px; - @include breakpoints.down('mm') { - @include rating-counter-util.size-s; - } - @include breakpoints.up('mm') { - @include rating-counter-util.size-m; - } + @include rating-counter-util.size-s; } diff --git a/src/common/components/product-info/parts/wait-list-added-link.m.scss b/src/common/components/product-info/parts/wait-list-added-link.m.scss index 9c13e9da..8182cb86 100644 --- a/src/common/components/product-info/parts/wait-list-added-link.m.scss +++ b/src/common/components/product-info/parts/wait-list-added-link.m.scss @@ -2,12 +2,8 @@ @use 'node_modules/@sima-land/ui-nucleons/breakpoints'; .root { - font-size: 16px; - line-height: 24px; + font-size: 14px; + line-height: 20px; font-weight: 600; color: colors.$basic-gray24; - @include breakpoints.down('ml') { - font-size: 14px; - line-height: 20px; - } } diff --git a/src/common/components/product-info/product-info.tsx b/src/common/components/product-info/product-info.tsx index e136e3ee..df3c480e 100644 --- a/src/common/components/product-info/product-info.tsx +++ b/src/common/components/product-info/product-info.tsx @@ -8,6 +8,7 @@ export const UNAVAILABLE_REASON = { notEnough: 'Нет в наличии', unavailableInRegion: 'Товар недоступен в вашем регионе', onlyForLegalEntities: 'Товар доступен только для юридических лиц', + adult: 'Товар для взрослых', } as const; /**