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

fix(ui5-slider): show tooltips when component has focus #3899

Merged
merged 2 commits into from Sep 14, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
9 changes: 0 additions & 9 deletions packages/main/src/SliderBase.js
Expand Up @@ -3,7 +3,6 @@ import litRender from "@ui5/webcomponents-base/dist/renderer/LitRenderer.js";
import Float from "@ui5/webcomponents-base/dist/types/Float.js";
import Integer from "@ui5/webcomponents-base/dist/types/Integer.js";
import ResizeHandler from "@ui5/webcomponents-base/dist/delegate/ResizeHandler.js";
import { isPhone } from "@ui5/webcomponents-base/dist/Device.js";
import {
isEscape, isHome, isEnd, isUp, isDown, isRight, isLeft, isUpCtrl, isDownCtrl, isRightCtrl, isLeftCtrl, isPlus, isMinus, isPageUp, isPageDown,
} from "@ui5/webcomponents-base/dist/Keys.js";
Expand Down Expand Up @@ -415,10 +414,6 @@ class SliderBase extends UI5Element {
const step = this._effectiveStep;
const newValue = SliderBase.getValueFromInteraction(event, step, min, max, domRect, directionStart);

if (isPhone() && this.showTooltip) {
this._tooltipVisibility = SliderBase.TOOLTIP_VISIBILITY.VISIBLE;
}

// Mark start of a user interaction
this._isUserInteraction = true;
// Only allow one type of move event to be listened to (the first one registered after the down event)
Expand Down Expand Up @@ -452,10 +447,6 @@ class SliderBase extends UI5Element {
* @protected
*/
handleUpBase(valueType) {
if (isPhone() && this.showTooltip) {
this._tooltipVisibility = SliderBase.TOOLTIP_VISIBILITY.HIDDEN;
}

SliderBase.UP_EVENTS.forEach(upEventType => window.removeEventListener(upEventType, this._upHandler));
window.removeEventListener(this._moveEventType, this._moveHandler);

Expand Down