Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(calendar-range): fix divider margin #315

Closed
wants to merge 1 commit into from
Closed

Conversation

KoVaL0
Copy link

@KoVaL0 KoVaL0 commented Oct 21, 2022

Опишите проблему

Divider в CalendarRange уплывает вверх при наличии label у CalendarInput

Шаги для воспроизведения

  1. Добавить label в пропсы inputFromProps и inputToProps
  2. Так же указать label внешним = labelView: 'outer'

Ожидаемое поведение

Ожидается что Divider будет находится по середине с инпутом

Чек лист

  • Тесты
  • Документация

Внешний вид

Ожидаемый
Снимок экрана 2022-10-20 в 21 15 24
Фактический
Снимок экрана 2022-10-20 в 21 36 38

Дополнительная информация

Реализация не идеальна, можно подумать над более элегантной реализацией

@changeset-bot
Copy link

changeset-bot bot commented Oct 21, 2022

⚠️ No Changeset found

Latest commit: c8efc14

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@coveralls
Copy link

Pull Request Test Coverage Report for Build 3295778725

  • 6 of 8 (75.0%) changed or added relevant lines in 2 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage decreased (-0.05%) to 81.488%

Changes Missing Coverage Covered Lines Changed/Added Lines %
packages/calendar-range/src/views/popover.tsx 3 4 75.0%
packages/calendar-range/src/views/static.tsx 3 4 75.0%
Totals Coverage Status
Change from base Build 3275596116: -0.05%
Covered Lines: 6787
Relevant Lines: 7626

💛 - Coveralls

@core-ds-bot
Copy link
Collaborator

Собрана новая демка.

@@ -34,6 +34,10 @@
}
}

.outerLabel {
margin-top: 24px;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Надо подумать, как сделать так, чтобы учитывался размер инпута, иначе опять съедет

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@KoVaL0 будет возможность дотащить?

@@ -169,6 +169,18 @@ export const CalendarRangePopover: FC<CalendarRangePopoverProps> = ({
// eslint-disable-next-line react-hooks/exhaustive-deps
}, [hasValidateError]);

const checkForLabel = () => {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Стоит вынести в хелпер

@reme3d2y
Copy link
Contributor

#379

@reme3d2y reme3d2y closed this Nov 23, 2022
@v-gevak v-gevak deleted the fix/calendar-range branch December 14, 2022 09:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

6 participants