Quellcode durchsuchen

fix: 修复滚动条bug

banxia vor 1 Monat
Ursprung
Commit
de5edcc6e7
2 geänderte Dateien mit 8 neuen und 8 gelöschten Zeilen
  1. 2 2
      electron/main/tray.ts
  2. 6 6
      src/components/MessageModal/MessageModal.tsx

+ 2 - 2
electron/main/tray.ts

@@ -21,7 +21,7 @@ export const initTray = () => {
     icon7: handlePath("./icon-7.png"),
     icon8: handlePath("./icon-8.png"),
     icon9: handlePath("./icon-9.png"),
-    icon9plus: handlePath("./icon-9plus.png"),
+    // icon9plus: handlePath("./icon-9plus.png"),
   };
   let appIcon = new Tray(ICONS.default);
   const isFocusOpenWin: number = handeGet("isFocusOpenWin");
@@ -71,7 +71,7 @@ export const initTray = () => {
     if (msgCount <= 9) {
       appIcon.setImage(ICONS[`icon${msgCount}`]);
     } else {
-      appIcon.setImage(ICONS[`icon9plus`]);
+      appIcon.setImage(ICONS[`icon9`]);
     }
     appIcon.setToolTip(`菁苗健康-未读消息数量(${msgCount})`);
   });

+ 6 - 6
src/components/MessageModal/MessageModal.tsx

@@ -67,13 +67,13 @@ const MessageModal: React.FC<MessageModalProps> = ({
       open={visible}
       onCancel={onClose}
       footer={null}
-      width={600}
-      styles={{
-        body: { maxHeight: 'calc(90vh - 110px)', overflow: 'auto' },
-        wrapper: { top: 40, maxHeight: '90vh' }
+      style={{
+        top: 30,
+        maxWidth: "90%",
+        maxHeight: "80%",
       }}
     >
-      <div className="flex flex-col">
+      <div className="flex flex-col h-[80vh]">
         <Tabs
           activeKey={activeKey}
           items={tabItems}
@@ -82,7 +82,7 @@ const MessageModal: React.FC<MessageModalProps> = ({
             setActiveKey(key);
           }}
         />
-        <div className="space-y-4 max-h-[70vh] overflow-auto">
+        <div className="space-y-4 max-h-[100%] overflow-auto">
           {
             // .filter(
             //   (notification) =>