Skip to content

Commit

Permalink
fix(ui5-slider): show tooltips when component has focus (#3899)
Browse files Browse the repository at this point in the history
  • Loading branch information
Maxi Dietz committed Sep 14, 2021
1 parent 015e3ef commit 952445d
Showing 1 changed file with 0 additions and 9 deletions.
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

0 comments on commit 952445d

Please sign in to comment.