diff --git a/packages/vkui/src/components/Clickable/Clickable.module.css b/packages/vkui/src/components/Clickable/Clickable.module.css index 3ff1e5e231..2b64c002d4 100644 --- a/packages/vkui/src/components/Clickable/Clickable.module.css +++ b/packages/vkui/src/components/Clickable/Clickable.module.css @@ -1,20 +1,22 @@ .realClickable { cursor: pointer; + -webkit-tap-highlight-color: transparent; } -.resetButtonStyle { +/* stylelint-disable selector-max-type */ +button.realClickable { appearance: none; user-select: none; - -webkit-tap-highlight-color: transparent; -webkit-touch-callout: none; -webkit-user-drag: none; } -.resetLinkStyle { +a.realClickable { appearance: none; -webkit-tap-highlight-color: transparent; text-decoration: none; } +/* stylelint-enable selector-max-type */ .host:focus, .host:focus-visible { diff --git a/packages/vkui/src/components/Clickable/Clickable.tsx b/packages/vkui/src/components/Clickable/Clickable.tsx index 6ca6924e28..5e3cc181cd 100644 --- a/packages/vkui/src/components/Clickable/Clickable.tsx +++ b/packages/vkui/src/components/Clickable/Clickable.tsx @@ -175,16 +175,6 @@ function component({ return {}; } -const getUserAgentResetClassName = (Component?: React.ElementType) => { - if (Component === 'a') { - return styles.resetLinkStyle; - } - if (Component === 'button') { - return styles.resetButtonStyle; - } - return; -}; - /** * Базовый кликабельный корневой компонент. * @@ -204,11 +194,7 @@ export const Clickable = ({ }: ClickableProps): React.ReactNode => { const commonProps = component(restProps); const isClickable = checkClickable(restProps); - const baseClassName = classNames( - baseClassNameProp, - getUserAgentResetClassName(commonProps.Component), - styles.host, - ); + const baseClassName = classNames(baseClassNameProp, styles.host); if (isClickable) { return (