-
Notifications
You must be signed in to change notification settings - Fork 196
V4 #665
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
V4 #665
Conversation
src/helpers/inputUtils.ts
Outdated
| @@ -0,0 +1,35 @@ | |||
| import { IS_PLATFORM_IOS } from '../lib/platform'; | |||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
весь этот файл ломает концепцию SSR. IS_PLATFORM_IOS будет неправильно определяться на сервере. Вот тут можно почитать подробнее
https://vkcom.github.io/vkui-styleguide/#!/Utils
https://vkcom.github.io/vkui-styleguide/#!/Server%20Side%20Rendering
src/components/View/View.css
Outdated
| .View--animated .View__panel, | ||
| .View--swiping-back .View__panel { | ||
| position: fixed; | ||
| position: absolute; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Уверены, что ничего не оторвет на мобилке?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Оторвало. Нужно было для анимации на десктопе, но так как её пока нет, то верну.
| /** | ||
| * Обработчик событий mouseenter | ||
| * | ||
| * @param {Object} e Браузерное событие |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
кажется, что JSDoc не нужно, учитывая, что мы используем TS. Максимум, что можно оставлять — это текстовое описание метода. Но и оно тут не нужно, и так понятно.
| } | ||
|
|
||
| const Separator: FunctionComponent<SeparatorProps> = ({ className, wide, ...restProps }: SeparatorProps) => { | ||
| let Separator: FunctionComponent<SeparatorProps> = ({ className, wide, expanded, ...restProps }: SeparatorProps) => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
зачем поменяли const на let?
src/components/Checkbox/Checkbox.css
Outdated
|
|
||
| .Checkbox--ios { | ||
| padding: 12px; | ||
| padding: 12px 0; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
|
|
||
| return ( | ||
| <Input | ||
| top={top} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
FormLayout цепляет top у дочерних компонентов. Сюда его прокидывать нет смысла, кажется, потому что это дочерний компонент дочернего компонента DatePicker
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| } | ||
|
|
||
| componentDidMount() { | ||
| this.onMountResizeTimeout = setTimeout(() => this.doResize()); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
выглядит, как плохой хак для ожидания отрисовки
| Используется для создания модальных окон. Содержимое `Root` – это коллекция `View`. У каждой `View` должен быть `id`. | ||
| Свойство `activeView` определяет, какая `View` сейчас активна. | ||
|
|
||
| При смене значения свойства `activeView` плавный происходит переход от одной `View` к другой. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
плавный происходит
нужно поменять слова
INFRA: Deploy PRs to github pages
👀 Styleguide deployedSee the styleguide for this PR at https://vkcom.github.io/VKUI/pull/665/ |
…ulation Calculate sizeX/sizeY from viewWidth/viewHeight
Adaptive Epic
INFRA: Faster CI install
Add before prop for Search
Proposal: Fix File nested labels and wrong paddings
Gallery: scrollable и left/right arrows
CardScroll & CardGrid
#148: Состояние скролла сохраняется для всех вкладок Epic
- 3 integration modes for VKUI: full, embedded and partial - new AppRoot component
…github.com:VKCOM/VKUI into edzhumak/popout-backdrop-desktop-height
…height Edzhumak/popout backdrop desktop height
Заметка дополняется
Breaking changes
Button
size. Былоm, l, xl, стало —s, m, llтеперь автоматически не растягиваются на всю ширину. Для достижения эффекта растягивания нужно передатьstreteched={true}Cell
size. Теперь чтобы отрисоватьCell size="l"нужно использоватьRichCellasideContentпереименовано вafterActionSheet
toggleRef(desktop only) иiosCloseItem(ios only)Panel
separator, отвечавшее за отрисовку разделителя после шапки. Свойство перекочевало вPanelHeaderMiniInfoCell
multiline. Вместо него нужно использоватьtextWrap="short".Формы
FormLayoutТеперь просто оборачиваетchildrenвform. Никакой итерации по детям внутри него нет.top,bottomиstatus. Компоненты нужно оборачивать вFormItem, передавая ему эти свойства.FormLayoutGroupтак же лишен свойствtop,bottomиstatus. Он теперь предназначен только для группировкиFormItem.New
Адаптивность
Основные инструменты адаптивности:
<AdaptivityProvider><SplitLayout>,<SplitCol>,<SplitFixedCol>withAdaptivityHOC иSizeTypeтипВ будущем будет добавлены абстракции инкапсулирующие самые популярные лаяуты адаптивности, сейчас это нужно делать вручную через
<SplitLayout>.Пример:
Создание адаптивного компонента
Для создания адаптивного компонента, его нужно обернуть в
withAdpativityHOC.