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

Makes rectangleTooltip fontSize bigger #1018

Merged
merged 2 commits into from
Nov 2, 2021
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 5 additions & 2 deletions src/components/SponsorTimeEditComponent.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -288,11 +288,14 @@ class SponsorTimeEditComponent extends React.Component<SponsorTimeEditProps, Spo
referenceNode: element.parentElement,
prependElement: element,
timeout: 15,
bottomOffset: 75 + "px",
bottomOffset: 0 + "px",
ajayyy marked this conversation as resolved.
Show resolved Hide resolved
leftOffset: -318 + "px",
backgroundColor: "rgba(28, 28, 28, 1.0)",
htmlId: "sponsorTimesContainer" + this.idSuffix,
buttonFunction: () => {Config.config.scrollToEditTimeUpdate = true}
buttonFunction: () => {Config.config.scrollToEditTimeUpdate = true},
fontSize: "14px",
maxHeight: "200px"

});
}
}
Expand Down
5 changes: 4 additions & 1 deletion src/render/RectangleTooltip.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ export interface RectangleTooltipProps {
maxHeight?: string,
maxWidth?: string,
backgroundColor?: string,
fontSize?: string,
buttonFunction?: () => void;
}

Expand All @@ -29,6 +30,7 @@ export class RectangleTooltip {
props.maxWidth ??= "300px";
props.backgroundColor ??= "rgba(28, 28, 28, 0.7)";
this.text = props.text;
props.fontSize ??= "10px";

this.container = document.createElement('div');
props.htmlId ??= props.text;
Expand All @@ -51,7 +53,8 @@ export class RectangleTooltip {
left: props.leftOffset,
maxHeight: props.maxHeight,
maxWidth: props.maxWidth,
backgroundColor: props.backgroundColor}}
backgroundColor: props.backgroundColor,
fontSize: props.fontSize}}
className="sponsorBlockRectangleTooltip" >
<div>
<img className="sponsorSkipLogo sponsorSkipObject"
Expand Down