浏览代码

fix: card modal blink when switching to the next card

Tienson Qin 4 月之前
父节点
当前提交
f9cf6adcff
共有 3 个文件被更改,包括 7 次插入2 次删除
  1. 1 1
      resources/css/shui.css
  2. 5 0
      src/main/frontend/components/cards.css
  3. 1 1
      src/main/frontend/extensions/fsrs.cljs

+ 1 - 1
resources/css/shui.css

@@ -246,7 +246,7 @@ div[data-radix-popper-content-wrapper] {
 }
 
 .ui__dialog-content {
-  @apply outline-none;
+  @apply outline-none m-4;
 
   &[data-auto-width] {
     @apply max-w-[90vw] w-max sm:max-w-[960px];

+ 5 - 0
src/main/frontend/components/cards.css

@@ -3,3 +3,8 @@
         min-height: 60vh;
     }
 }
+
+#cards-modal {
+    height: 70vh;
+    max-height: 1024px;
+}

+ 1 - 1
src/main/frontend/extensions/fsrs.cljs

@@ -259,7 +259,7 @@
         *card-index (::card-index state)
         *phase (atom :init)]
     (when (false? loading?)
-      [:div#cards-modal.flex.flex-col.gap-8.h-full.flex-1
+      [:div#cards-modal.flex.flex-col.gap-8.flex-1
        [:div.flex.flex-row.items-center.gap-2.flex-wrap
         (shui/select
          {:on-value-change (fn [v]