mirror of
https://github.com/monkeytypegame/monkeytype.git
synced 2026-01-12 02:14:34 +08:00
fix: themes ui list shows clipped when selected or hovered
closes #7318
This commit is contained in:
parent
4da82d0f2b
commit
1294499d0f
2 changed files with 9 additions and 6 deletions
|
|
@ -50,7 +50,6 @@
|
|||
.settingsGroup {
|
||||
display: grid;
|
||||
gap: 2rem;
|
||||
overflow: hidden;
|
||||
&.quickNav {
|
||||
justify-content: center;
|
||||
.links {
|
||||
|
|
|
|||
|
|
@ -753,26 +753,30 @@ function toggleSettingsGroup(groupName: string): void {
|
|||
|
||||
const groupEl = qs(`.pageSettings .settingsGroup.${groupName}`);
|
||||
if (!groupEl?.hasClass("slideup")) {
|
||||
groupEl?.animate({
|
||||
groupEl?.setStyle({ overflow: "hidden" })?.animate({
|
||||
height: 0,
|
||||
duration: 250,
|
||||
onComplete: () => {
|
||||
groupEl?.hide();
|
||||
groupEl
|
||||
?.hide()
|
||||
.setStyle({ height: "", overflow: "" })
|
||||
.addClass("slideup");
|
||||
},
|
||||
});
|
||||
groupEl?.addClass("slideup");
|
||||
$(`.pageSettings .sectionGroupTitle[group=${groupName}]`).addClass(
|
||||
"rotateIcon",
|
||||
);
|
||||
} else {
|
||||
groupEl?.show();
|
||||
groupEl?.setStyle({ height: "" });
|
||||
groupEl?.setStyle({ height: "", overflow: "hidden" });
|
||||
const height = groupEl.getOffsetHeight();
|
||||
groupEl?.animate({
|
||||
height: [0, height],
|
||||
duration: 250,
|
||||
onComplete: () => {
|
||||
groupEl?.setStyle({ height: "", overflow: "" }).removeClass("slideup");
|
||||
},
|
||||
});
|
||||
groupEl?.removeClass("slideup");
|
||||
$(`.pageSettings .sectionGroupTitle[group=${groupName}]`).removeClass(
|
||||
"rotateIcon",
|
||||
);
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue