ijohn07 commited on
Commit
c248ea4
Β·
verified Β·
1 Parent(s): e1bbcaf

Upload 6 files

Browse files
Files changed (4) hide show
  1. index.html +6 -0
  2. scripts/app.js +43 -0
  3. scripts/feeds-config.js +64 -1
  4. styles/main.css +36 -0
index.html CHANGED
@@ -328,6 +328,12 @@
328
  </div>
329
  <p class="hint" id="auto-refresh-status">Auto-refresh is disabled</p>
330
  </section>
 
 
 
 
 
 
331
  </div>
332
  </div>
333
 
 
328
  </div>
329
  <p class="hint" id="auto-refresh-status">Auto-refresh is disabled</p>
330
  </section>
331
+
332
+ <section class="modal-section reset-section">
333
+ <h3>πŸ—‘οΈ Reset Data</h3>
334
+ <p class="hint">Clear all stored data (settings, custom feeds, bookmarks, and cache).</p>
335
+ <button class="btn-danger" id="btn-reset-all">Reset Everything</button>
336
+ </section>
337
  </div>
338
  </div>
339
 
scripts/app.js CHANGED
@@ -435,6 +435,11 @@ class RSSHubApp {
435
  this.setLanguage(btn.dataset.lang);
436
  });
437
  });
 
 
 
 
 
438
  }
439
 
440
  /**
@@ -1274,6 +1279,44 @@ class RSSHubApp {
1274
  return feeds;
1275
  }
1276
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1277
  /**
1278
  * Save settings to localStorage with quota handling
1279
  */
 
435
  this.setLanguage(btn.dataset.lang);
436
  });
437
  });
438
+
439
+ // Reset all data button
440
+ document.getElementById("btn-reset-all")?.addEventListener("click", () => {
441
+ this.resetAllData();
442
+ });
443
  }
444
 
445
  /**
 
1279
  return feeds;
1280
  }
1281
 
1282
+ /**
1283
+ * Reset all data (localStorage + IndexedDB)
1284
+ */
1285
+ async resetAllData() {
1286
+ if (
1287
+ !confirm(
1288
+ "Are you sure you want to reset ALL data?\n\nThis will delete:\nβ€’ All settings\nβ€’ Custom feeds\nβ€’ Bookmarks\nβ€’ Cached data\n\nThis action cannot be undone."
1289
+ )
1290
+ ) {
1291
+ return;
1292
+ }
1293
+
1294
+ try {
1295
+ // Clear localStorage entries for this app
1296
+ localStorage.removeItem("ivy-rss-hub-settings");
1297
+ localStorage.removeItem("ivy-rss-hub-theme");
1298
+ localStorage.removeItem("ivy-rss-hub-bookmarks");
1299
+ localStorage.removeItem("ivy-rss-hub-favorites");
1300
+ localStorage.removeItem("ivy-rss-hub-sidebar");
1301
+
1302
+ // Clear IndexedDB (Dexie cache)
1303
+ if (this.parser && this.parser.db) {
1304
+ await this.parser.db.delete();
1305
+ console.log("πŸ—‘οΈ IndexedDB cleared");
1306
+ }
1307
+
1308
+ this.showToast("All data cleared! Reloading...", "success");
1309
+
1310
+ // Reload page after a short delay
1311
+ setTimeout(() => {
1312
+ window.location.reload();
1313
+ }, 1000);
1314
+ } catch (e) {
1315
+ console.error("Reset failed:", e);
1316
+ this.showToast("Reset failed: " + e.message, "error");
1317
+ }
1318
+ }
1319
+
1320
  /**
1321
  * Save settings to localStorage with quota handling
1322
  */
scripts/feeds-config.js CHANGED
@@ -46,7 +46,7 @@ const DEFAULT_FEEDS = [
46
  icon: "πŸ€–",
47
  category: "ai",
48
  lang: "en",
49
- enabled: true
50
  },
51
  {
52
  id: "deepmind",
@@ -55,8 +55,71 @@ const DEFAULT_FEEDS = [
55
  icon: "πŸ”·",
56
  category: "ai",
57
  lang: "en",
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
58
  enabled: true
59
  },
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
60
  // NOTE: Anthropic doesn't have a public RSS feed β€” disabled
61
  // {
62
  // id: "anthropic",
 
46
  icon: "πŸ€–",
47
  category: "ai",
48
  lang: "en",
49
+ enabled: false // NOTE: 404 - OpenAI doesn't have public RSS (tested 27 Dec 2025)
50
  },
51
  {
52
  id: "deepmind",
 
55
  icon: "πŸ”·",
56
  category: "ai",
57
  lang: "en",
58
+ enabled: false // NOTE: 404 - DeepMind doesn't have public RSS (tested 27 Dec 2025)
59
+ },
60
+ {
61
+ id: "alignmentforum",
62
+ name: "Alignment Forum",
63
+ url: "https://www.alignmentforum.org/feed.xml",
64
+ icon: "🎯",
65
+ category: "ai",
66
+ lang: "en",
67
+ enabled: true
68
+ },
69
+ {
70
+ id: "lesswrong",
71
+ name: "LessWrong",
72
+ url: "https://www.lesswrong.com/feed.xml",
73
+ icon: "🧠",
74
+ category: "ai",
75
+ lang: "en",
76
  enabled: true
77
  },
78
+ {
79
+ id: "thegradient",
80
+ name: "The Gradient",
81
+ url: "https://thegradient.pub/rss/",
82
+ icon: "πŸ“Š",
83
+ category: "ai",
84
+ lang: "en",
85
+ enabled: true
86
+ },
87
+ {
88
+ id: "mit-tech-review",
89
+ name: "MIT Technology Review",
90
+ url: "https://www.technologyreview.com/feed/",
91
+ icon: "πŸ“°",
92
+ category: "ai",
93
+ lang: "en",
94
+ enabled: true
95
+ },
96
+ {
97
+ id: "ml-mastery",
98
+ name: "Machine Learning Mastery",
99
+ url: "https://machinelearningmastery.com/feed/",
100
+ icon: "πŸ“š",
101
+ category: "ai",
102
+ lang: "en",
103
+ enabled: true
104
+ },
105
+ {
106
+ id: "distill",
107
+ name: "Distill (Archive)",
108
+ url: "https://distill.pub/rss.xml",
109
+ icon: "✨",
110
+ category: "ai",
111
+ lang: "en",
112
+ enabled: false // NOTE: Distill is on hiatus since 2022, but archive still valuable
113
+ },
114
+ {
115
+ id: "google-ai-blog",
116
+ name: "Google AI Blog",
117
+ url: "https://blog.google/technology/ai/rss/",
118
+ icon: "πŸ”",
119
+ category: "ai",
120
+ lang: "en",
121
+ enabled: true // NOTE: Verified working 27 Dec 2025 β€” Ivy's RSS Hunt 🌿
122
+ },
123
  // NOTE: Anthropic doesn't have a public RSS feed β€” disabled
124
  // {
125
  // id: "anthropic",
styles/main.css CHANGED
@@ -807,6 +807,27 @@ a:hover {
807
  background: var(--ivy-green-dark);
808
  }
809
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
810
  /* Checkbox Labels */
811
  .checkbox-label {
812
  display: flex;
@@ -868,6 +889,21 @@ a:hover {
868
  border-color: var(--ivy-green);
869
  }
870
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
871
  .hint {
872
  font-size: 0.8rem;
873
  color: var(--text-muted);
 
807
  background: var(--ivy-green-dark);
808
  }
809
 
810
+ .btn-danger {
811
+ background: #dc2626;
812
+ border: none;
813
+ color: #fff;
814
+ padding: 10px 16px;
815
+ border-radius: var(--radius-md);
816
+ font-weight: 600;
817
+ cursor: pointer;
818
+ transition: background var(--transition-fast);
819
+ }
820
+
821
+ .btn-danger:hover {
822
+ background: #b91c1c;
823
+ }
824
+
825
+ .reset-section {
826
+ border-top: 1px solid var(--border-color);
827
+ padding-top: 16px;
828
+ margin-top: 8px;
829
+ }
830
+
831
  /* Checkbox Labels */
832
  .checkbox-label {
833
  display: flex;
 
889
  border-color: var(--ivy-green);
890
  }
891
 
892
+ .number-input-row select {
893
+ padding: 6px 10px;
894
+ background: var(--bg-tertiary);
895
+ border: 1px solid var(--border-color);
896
+ border-radius: var(--radius-sm);
897
+ color: var(--text-primary);
898
+ font-size: 0.9rem;
899
+ cursor: pointer;
900
+ }
901
+
902
+ .number-input-row select:focus {
903
+ outline: none;
904
+ border-color: var(--ivy-green);
905
+ }
906
+
907
  .hint {
908
  font-size: 0.8rem;
909
  color: var(--text-muted);