feat(segmented-control): добавить view skeleton [DS-14045]#2028
feat(segmented-control): добавить view skeleton [DS-14045]#2028
Conversation
🦋 Changeset detectedLatest commit: 4ad9316 The changes in this PR will be included in the next version bump. This PR includes changesets to release 2 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
Pull Request Test Coverage Report for Build 21747315753Warning: This coverage report may be inaccurate.This pull request's base commit is no longer the HEAD commit of its target branch. This means it includes changes from outside the original pull request, including, potentially, unrelated coverage changes.
Details
💛 - Coveralls |
| * Показывает скелетон вместо контента | ||
| * @default false | ||
| */ | ||
| showSkeleton?: boolean; |
There was a problem hiding this comment.
Обсудим потом вариант объеденения пропса?
Например
skeleton: {show: boolean, props: {}}
|
|
||
| const skeletonBorderRadius = (() => { | ||
| if (shape === 'rounded') { | ||
| return sizeClassName === 'size-40' ? 20 : 16; |
There was a problem hiding this comment.
тут и в остальных местах идет проверка на size-40. в принципе можно сразу вывести функцию:
size === 40 || size === 'xs'.
Demo build (default) |
Demo build (alfasans) |
| className={cn(className, skeleton.className)} | ||
| style={{ | ||
| ...skeleton.style, | ||
| height: isSize40 ? '40px' : '32px', |
| style={{ | ||
| ...skeleton.style, | ||
| height: isSize40 ? '40px' : '32px', | ||
| width: '100%', |
There was a problem hiding this comment.
width: '100%' через className задать можно?
skeletonдля компонентаSegmentedControl.Чек лист
Если есть визуальные изменения
Код для песочницы: