Skip to content

Commit

Permalink
remove the caret from the SeekbarLabel
Browse files Browse the repository at this point in the history
  • Loading branch information
stonko1994 committed Jan 14, 2025
1 parent f1a05ec commit 3f2bcce
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 22 deletions.
14 changes: 0 additions & 14 deletions src/scss/components/labels/_seekbarlabel.scss
Original file line number Diff line number Diff line change
Expand Up @@ -26,20 +26,6 @@
padding-right: 1em;
}

// bottom arrow from http://www.cssarrowplease.com/
.#{$prefix}-seekbar-label-caret {
border: solid transparent;
border-color: transparent;
border-top-color: $color-primary;
border-width: .5em;
height: 0;
margin-left: -.5em;
pointer-events: none;
position: absolute;
top: 100%;
width: 0;
}

.#{$prefix}-seekbar-label-inner {
border: solid $color-primary .0625em;
border-radius: .5em;
Expand Down
9 changes: 1 addition & 8 deletions src/ts/components/seekbar/SeekBarLabel.ts
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,6 @@ export class SeekBarLabel extends Container<SeekBarLabelConfig> {
private player: PlayerAPI;
private uiManager: UIInstanceManager;
private readonly container: Container<ContainerConfig>;
private readonly caret: Label<LabelConfig>;

constructor(config: SeekBarLabelConfig = {}) {
super(config);
Expand All @@ -58,11 +57,9 @@ export class SeekBarLabel extends Container<SeekBarLabelConfig> {
cssClass: 'seekbar-label-inner',
});

this.caret = new Label({ cssClasses: ['seekbar-label-caret'] });

this.config = this.mergeConfig(config, {
cssClass: 'ui-seekbar-label',
components: [this.container, this.caret],
components: [this.container],
hidden: true,
}, this.config);
}
Expand Down Expand Up @@ -151,10 +148,6 @@ export class SeekBarLabel extends Container<SeekBarLabelConfig> {

if (preventOverflowOffset !== 0) {
this.getDomElement().css('left', seekPositionPx - preventOverflowOffset + 'px');

this.caret.getDomElement().css('transform', `translateX(${preventOverflowOffset}px)`);
} else {
this.caret.getDomElement().css('transform', null);
}
}

Expand Down

0 comments on commit 3f2bcce

Please sign in to comment.