This commit is contained in:
Vanessa 2023-04-18 19:35:31 +08:00
parent 9a760026b7
commit 9f75163c2e
2 changed files with 9 additions and 4 deletions

View file

@ -183,7 +183,7 @@
&-bazaar__readme {
position: absolute;
transition: var(--b3-transition);
transition: transform .2s cubic-bezier(0, 0, .2, 1) 0ms, opacity .3s cubic-bezier(0, 0, .2, 1) 0ms;
right: -100%;
top: 0;
width: 100%;
@ -192,6 +192,12 @@
display: flex;
padding: 16px;
box-sizing: border-box;
opacity: 0;
&--show {
opacity: 1;
transform: translateX(-100%);
}
.item {
&__side {

View file

@ -339,7 +339,7 @@ export const bazaar = {
highlightRender(mdElement);
});
}
readmeElement.style.right = "0";
readmeElement.classList.add("config-bazaar__readme--show")
},
bindEvent() {
fetchPost("/api/bazaar/getBazaarTheme", {}, response => {
@ -377,8 +377,7 @@ export const bazaar = {
event.stopPropagation();
break;
} else if (type === "goBack") {
const readmeElement = bazaar.element.querySelector("#configBazaarReadme") as HTMLElement;
readmeElement.style.right = "-100%";
bazaar.element.querySelector("#configBazaarReadme").classList.remove("config-bazaar__readme--show")
event.preventDefault();
event.stopPropagation();
break;