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

feat: new components: TimeInput, DateTimeInput, DateRangeInput #175

Merged
merged 18 commits into from
Sep 19, 2022

Conversation

blackraydev
Copy link
Contributor

@blackraydev blackraydev commented Aug 1, 2022

Новые компоненты: TimeInput, DateTimeInput, DateRangeInput

@core-ds-bot
Copy link
Collaborator

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

@coveralls
Copy link

coveralls commented Aug 1, 2022

Pull Request Test Coverage Report for Build 3067420534

  • 292 of 348 (83.91%) changed or added relevant lines in 8 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage decreased (-0.3%) to 81.509%

Changes Missing Coverage Covered Lines Changed/Added Lines %
packages/date-range-input/src/utils/format.ts 20 21 95.24%
packages/time-input/src/utils/format.ts 13 15 86.67%
packages/time-input/src/Component.tsx 25 28 89.29%
packages/date-time-input/src/utils/format.ts 46 60 76.67%
packages/date-time-input/src/Component.tsx 81 98 82.65%
packages/date-range-input/src/Component.tsx 104 123 84.55%
Totals Coverage Status
Change from base Build 3062023670: -0.3%
Covered Lines: 6657
Relevant Lines: 7491

💛 - Coveralls

@blackraydev blackraydev marked this pull request as ready for review August 3, 2022 09:01
@core-ds-bot
Copy link
Collaborator

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

@core-ds-bot
Copy link
Collaborator

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

@v-gevak
Copy link
Contributor

v-gevak commented Aug 4, 2022

Есть баг, что вместо точек можно цифры ввести
Снимок экрана 2022-08-04 в 12 02 35

@v-gevak
Copy link
Contributor

v-gevak commented Aug 4, 2022

Ну и также есть стандартная проблема с прыжками каретки, если очищать введенное значение не с конца или пытаться ввести что-нибудь в середину.
Это критично здесь? @SiebenSieben @Oladii что думаете?

@Oladii
Copy link
Contributor

Oladii commented Aug 4, 2022

Ну и также есть стандартная проблема с прыжками каретки, если очищать введенное значение не с конца или пытаться ввести что-нибудь в середину. Это критично здесь? @SiebenSieben @Oladii что думаете?

Кажется что стоит попробовать починить. Возможно отдельной таской.

Но в этой таске определенно нужны плейсхолдеры, без них компонент теряет смысл.

@core-ds-bot
Copy link
Collaborator

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

@@ -0,0 +1,3 @@
.component {
min-width: 328px;
Copy link
Contributor

Choose a reason for hiding this comment

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

Кажется, это случайная ширина инпута в макете, не? Зачем ему быть таким широким)

}

.input {
width: 354px;
Copy link
Contributor

Choose a reason for hiding this comment

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

Тут тоже странно, вроде у Влада в спеке ничего нет про минимальную ширину

}

.input {
width: 353px;
Copy link
Contributor

Choose a reason for hiding this comment

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

И здесь)

@SiebenSieben
Copy link
Contributor

SiebenSieben commented Aug 9, 2022

В DateTimeInput с пикером можем закрывать пикер после выбора даты?

@SiebenSieben
Copy link
Contributor

SiebenSieben commented Aug 9, 2022

Но в этой таске определенно нужны плейсхолдеры, без них компонент теряет смысл.

@blackraydev оцени, пожалуйста, такую реализацию:
https://taiga-ui.dev/components/input-date-range

(часть плейсхолдера остаётся по мере ввода)

@SiebenSieben SiebenSieben changed the title feat: new components: TimeInput, DateTimeInput, DateTimeRange feat: new components: TimeInput, DateTimeInput, DateRangeInput Aug 12, 2022
@core-ds-bot
Copy link
Collaborator

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

},
"peerDependencies": {
"react": "^16.9.0 || ^17.0.1",
"react-dom": "^16.9.0 || ^17.0.1"
Copy link
Contributor

Choose a reason for hiding this comment

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

|| ^18.0.0

"@alfalab/core-components-icon-button": "^4.2.2",
"@alfalab/core-components-calendar": "^5.5.8",
"@alfalab/core-components-popover": "^5.7.5",
"classnames": "^2.2.6"
Copy link
Contributor

Choose a reason for hiding this comment

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

2.3.1

"directory": "dist"
},
"peerDependencies": {
"react": "^16.9.0 || ^17.0.1",
Copy link
Contributor

Choose a reason for hiding this comment

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

|| ^18.0.0

@core-ds-bot
Copy link
Collaborator

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

@core-ds-bot
Copy link
Collaborator

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

@core-ds-bot
Copy link
Collaborator

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

@core-ds-bot
Copy link
Collaborator

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

@core-ds-bot
Copy link
Collaborator

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

@core-ds-bot
Copy link
Collaborator

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

@SiebenSieben
Copy link
Contributor

Надо ширину убрать (то что выше комментили) и вроде ок

@changeset-bot
Copy link

changeset-bot bot commented Sep 16, 2022

🦋 Changeset detected

Latest commit: c48078a

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 7 packages
Name Type
@alfalab/core-components-calendar Patch
@alfalab/core-components-date-range-input Minor
@alfalab/core-components-date-time-input Minor
@alfalab/core-components-time-input Minor
@alfalab/core-components-calendar-input Patch
@alfalab/core-components-calendar-range Patch
@alfalab/core-components-calendar-with-skeleton Patch

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

@core-ds-bot
Copy link
Collaborator

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

@core-ds-bot
Copy link
Collaborator

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

@@ -267,9 +267,8 @@ describe('Gallery', () => {

fireEvent.mouseOver(fullscreenButton);

await waitFor(
() => expect(getByText('Открыть в полноэкранном режиме')).toBeInTheDocument(),
{ timeout: 2000 },
Copy link
Contributor

Choose a reason for hiding this comment

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

Нужно вернуть timeout

@@ -97,7 +97,7 @@ describe('InputAutocompleteMobile', () => {
/>,
);

await waitFor(() => expect(handleEntered).toHaveBeenCalledTimes(1), { timeout: 2000 });
Copy link
Contributor

Choose a reason for hiding this comment

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

И тут нужно вернуть timeout

@core-ds-bot
Copy link
Collaborator

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

@core-ds-bot
Copy link
Collaborator

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

@core-ds-bot
Copy link
Collaborator

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

@SiebenSieben SiebenSieben merged commit 2643a1d into master Sep 19, 2022
@SiebenSieben SiebenSieben deleted the feat/time_input_implementation branch September 19, 2022 09:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

7 participants