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

[Modal] Съезжают отступы, т.к. не работает сравнение по type вместе с react-hot-loader #1267

Closed
sergeyshmakov opened this issue Mar 21, 2019 · 4 comments · Fixed by #1311
Assignees

Comments

@sergeyshmakov
Copy link
Contributor

sergeyshmakov commented Mar 21, 2019

  • react-ui последняя версия
  • Chrome последняя версия
  • При использовании react-hot-loader в dev-режиме все компоненты приобретают hot-обертку, из-за этого сравнение элементов по type не работают. Так в режиме разработки с react-hot-loader у нас ломались отступы в лайтбоксе.

Пример кода в ModalHeader.tsx который всегда возвращал false - child.type === Header.
Абсолютно то же самое в ModalFooter.tsx - child.type === Footer

Все это относится к особенности работы react-hot-loader, которую нельзя изменить.
gaearon/react-hot-loader#304

@wKich
Copy link
Contributor

wKich commented Mar 22, 2019

А почему у тебя компоненты библиотеки оборачиваются в обертку?

zhzz added a commit that referenced this issue Apr 1, 2019
zhzz added a commit that referenced this issue Apr 1, 2019
zhzz added a commit that referenced this issue Apr 1, 2019
zhzz added a commit that referenced this issue Apr 2, 2019
zhzz added a commit that referenced this issue Apr 2, 2019
zhzz added a commit that referenced this issue Apr 2, 2019
@zhzz zhzz self-assigned this Apr 2, 2019
@lenoraart lenoraart assigned lenoraart and unassigned lenoraart Apr 5, 2019
@zhzz zhzz closed this as completed in #1311 Apr 5, 2019
@theKashey
Copy link

Да, настало время это починить.

@zhzz
Copy link
Member

zhzz commented May 31, 2019

Мы починили в 0.46.0.

@theKashey
Copy link

Вы то да, а React-Hot-Loader пока еще нет. В понедельнику авось и починится.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

Successfully merging a pull request may close this issue.

5 participants