Parcourir la source

chore(release): bump version to v7.7

QLHazyCoder il y a 4 mois
Parent
commit
6ff6960d97
3 fichiers modifiés avec 18 ajouts et 7 suppressions
  1. 1 1
      manifest.json
  2. 3 4
      sidepanel/sidepanel.html
  3. 14 2
      sidepanel/sidepanel.js

+ 1 - 1
manifest.json

@@ -1,7 +1,7 @@
 {
   "manifest_version": 3,
   "name": "多页面自动化",
-  "version": "7.6.0",
+  "version": "7.7",
   "description": "用于自动执行多步骤 OAuth 注册流程",
   "permissions": [
     "sidePanel",

+ 3 - 4
sidepanel/sidepanel.html

@@ -201,14 +201,13 @@
       <div class="data-row">
         <span class="data-label">自动重试</span>
         <div class="data-inline fallback-inline">
-          <label class="toggle-switch" for="input-auto-skip-failures" title="Auto retry restarts the current round from step 1 after a step failure.">
-            <input type="checkbox" id="input-auto-skip-failures" checked />
+          <label class="toggle-switch" for="input-auto-skip-failures">
+            <input type="checkbox" id="input-auto-skip-failures" />
             <span class="toggle-switch-track" aria-hidden="true">
               <span class="toggle-switch-thumb"></span>
             </span>
           </label>
-          <span class="auto-delay-caption">Retry the current round from step 1 after a short delay.</span>
-          <div class="fallback-thread-interval" style="display:none;">
+          <div class="fallback-thread-interval">
             <span class="auto-delay-caption">线程间隔</span>
             <div class="auto-delay-controls">
               <input type="number" id="input-auto-skip-failures-thread-interval-minutes" class="data-input auto-delay-input" value="0"

+ 14 - 2
sidepanel/sidepanel.js

@@ -671,7 +671,7 @@ function updateFallbackThreadIntervalInputState() {
     return;
   }
 
-  inputAutoSkipFailuresThreadIntervalMinutes.disabled = true;
+  inputAutoSkipFailuresThreadIntervalMinutes.disabled = !(inputAutoSkipFailures.checked && getRunCountValue() > 1);
 }
 
 function updateAutoDelayInputState() {
@@ -2970,8 +2970,20 @@ inputRunCount.addEventListener('blur', () => {
 });
 
 inputAutoSkipFailures.addEventListener('change', async () => {
-  inputAutoSkipFailures.checked = true;
+  if (inputAutoSkipFailures.checked && !isAutoSkipFailuresPromptDismissed()) {
+    const result = await openAutoSkipFailuresConfirmModal();
+    if (!result.confirmed) {
+      inputAutoSkipFailures.checked = false;
+      updateFallbackThreadIntervalInputState();
+      return;
+    }
+    if (result.dismissPrompt) {
+      setAutoSkipFailuresPromptDismissed(true);
+    }
+  }
   updateFallbackThreadIntervalInputState();
+  markSettingsDirty(true);
+  saveSettings({ silent: true }).catch(() => { });
 });
 
 inputAutoSkipFailuresThreadIntervalMinutes.addEventListener('input', () => {