Skip to content

Commit

Permalink
feat(Input): disable controls for type="number" (#5607)
Browse files Browse the repository at this point in the history
  • Loading branch information
inomdzhon authored Aug 11, 2023
1 parent fdf9a83 commit 4753a6c
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions packages/vkui/src/components/Input/Input.module.css
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,20 @@
background: transparent;
}

/*
* Отключаем нативные элементы для <input type="number" />
*
* см. https://www.w3schools.com/howto/howto_css_hide_arrow_number.asp
*/
.Input__el::-webkit-outer-spin-button,
.Input__el::-webkit-inner-spin-button {
-webkit-appearance: none;
}

.Input__el[type='number'] {
-moz-appearance: textfield;
}

.Input--sizeY-compact .Input__el {
height: var(--vkui--size_field_height--compact);
}
Expand Down

0 comments on commit 4753a6c

Please sign in to comment.