diff --git a/app/static/css/main.css b/app/static/css/main.css index 2f582c2..200bf56 100644 --- a/app/static/css/main.css +++ b/app/static/css/main.css @@ -3972,3 +3972,61 @@ table.selectable-records .expand-button:hover { position: relative; top: -0.5px; } + +/* 任务按钮悬停显示样式 */ +.task-buttons .hover-only { + opacity: 0; + transition: opacity 0.2s ease-in-out; + position: absolute; + right: 0; + visibility: hidden; +} + +/* 修改悬停触发范围到整个任务单元 */ +.task:hover .task-buttons .hover-only { + opacity: 1; + visibility: visible; + position: static; +} + +/* 确保按钮容器在悬停时保持宽度 */ +.task-buttons { + position: relative; + min-width: 160px; /* 根据按钮数量和间距调整 */ + display: flex; + justify-content: flex-end; + padding-right: 0; + margin-right: 0; +} + +/* 确保按钮在悬停时可见 */ +.task:hover .task-buttons { + z-index: 1; +} + +/* 移动模式下的任务按钮容器样式 */ +@media (max-width: 767.98px) { + .task .col-auto.task-buttons { + padding-right: 15px; /* 与添加任务按钮的右边距保持一致 */ + } +} + +@media (min-width: 992px) { + .display-setting-row > .col-lg-3 { + padding-left: 4px !important; + padding-right: 4px !important; + } + .display-setting-row { + margin-left: -4px !important; + margin-right: -4px !important; + } +} + +.display-setting-row > [class*='col-'] { + padding-left: 4px !important; + padding-right: 4px !important; +} +.display-setting-row { + margin-left: -4px !important; + margin-right: -4px !important; +} diff --git a/app/templates/index.html b/app/templates/index.html index 494aa74..a1b6fa0 100644 --- a/app/templates/index.html +++ b/app/templates/index.html @@ -440,6 +440,63 @@ +
+
+

显示设置

+ + + +
+
+
+
+
+
+ 运行此任务 +
+ +
+
+
+
+
+ 删除此任务 +
+ +
+
+
+
+
+ 刷新 Plex 媒体库 +
+ +
+
+
+
+
+ 刷新 AList 目录 +
+ +
+
+
+
@@ -483,12 +540,12 @@ #
-
- - +
+ + - - + +
@@ -1008,6 +1065,12 @@ webui: { username: "", password: "" + }, + button_display: { + run_task: "always", + delete_task: "always", + refresh_plex: "always", + refresh_alist: "always" } }, userInfoList: [], // 用户信息列表 @@ -1526,6 +1589,15 @@ if (!config_data.episode_patterns) { config_data.episode_patterns = []; } + // 确保按钮显示配置存在 + if (!config_data.button_display) { + config_data.button_display = { + run_task: "always", + delete_task: "always", + refresh_plex: "always", + refresh_alist: "always" + }; + } this.formData = config_data; setTimeout(() => { this.configModified = false;