mirror of
https://github.com/PR0M3TH3AN/bitvid.git
synced 2026-11-01 18:32:27 +00:00
fix(ai): frontend console error — double load and lint fixes (agent)
This commit is contained in:
1 parent
d2e8dc3d3c
commit
f2ab7302ab
6 files changed
+14
-38
No files matched your search
@@ -492,7 +492,7 @@
|
||||
|
||||
@media (min-width: theme("screens.md")) {
|
||||
.search-filters-panel.is-advanced-open {
|
||||
width: 40rem;
|
||||
width: var(--size-40rem);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -321,6 +321,7 @@
|
||||
--size-20rem: 20rem;
|
||||
--size-28rem: 28rem;
|
||||
--size-34rem: 34rem;
|
||||
--size-40rem: 40rem;
|
||||
--size-45rem: 45rem;
|
||||
--size-70rem: 70rem;
|
||||
|
||||
|
||||
@@ -895,36 +895,7 @@ class Application {
|
||||
);
|
||||
}) || Promise.resolve();
|
||||
|
||||
// 6) Load the default view ONLY if there's no #view= already
|
||||
if (!window.location.hash || !window.location.hash.startsWith("#view=")) {
|
||||
devLogger.log(
|
||||
"[app.init()] No #view= in the URL, loading default home view"
|
||||
);
|
||||
const defaultView = this.isUserLoggedIn()
|
||||
? "views/for-you.html"
|
||||
: "views/most-recent-videos.html";
|
||||
if (typeof this.loadView === "function") {
|
||||
await Promise.all([
|
||||
this.loadView(defaultView),
|
||||
watchHistoryInitPromise,
|
||||
]);
|
||||
} else {
|
||||
await watchHistoryInitPromise;
|
||||
}
|
||||
} else {
|
||||
devLogger.log(
|
||||
"[app.init()] Found hash:",
|
||||
window.location.hash,
|
||||
"so skipping default load"
|
||||
);
|
||||
await watchHistoryInitPromise;
|
||||
}
|
||||
|
||||
// 7. Once loaded, get a reference to #videoList
|
||||
this.mountVideoListView();
|
||||
|
||||
// 8. Subscribe or fetch videos
|
||||
await this.loadVideos();
|
||||
await watchHistoryInitPromise;
|
||||
|
||||
// 9. Check URL ?v= param
|
||||
this.checkUrlParams();
|
||||
|
||||
@@ -168,10 +168,12 @@ function toggleAdvanced(forceState = null) {
|
||||
|
||||
if (newState) {
|
||||
advancedPanel.classList.remove("hidden");
|
||||
advancedChevron.style.transform = "rotate(180deg)";
|
||||
advancedChevron.classList.add("rotate-180");
|
||||
advancedChevron.classList.remove("rotate-0");
|
||||
} else {
|
||||
advancedPanel.classList.add("hidden");
|
||||
advancedChevron.style.transform = "rotate(0deg)";
|
||||
advancedChevron.classList.add("rotate-0");
|
||||
advancedChevron.classList.remove("rotate-180");
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -1,8 +1,9 @@
|
||||
import sys
|
||||
from playwright.sync_api import sync_playwright
|
||||
import sys
|
||||
|
||||
def run():
|
||||
with sync_playwright() as p:
|
||||
# Launch browser
|
||||
browser = p.chromium.launch()
|
||||
page = browser.new_page()
|
||||
|
||||
@@ -12,12 +13,14 @@ def run():
|
||||
# Listen for uncaught exceptions
|
||||
page.on("pageerror", lambda exc: print(f"pageerror: {exc}"))
|
||||
|
||||
# Listen for failed network requests
|
||||
# Listen for failed requests
|
||||
page.on("requestfailed", lambda req: print(f"requestfailed: {req.url} {req.failure}"))
|
||||
|
||||
print("Navigating to http://localhost:8000 ...")
|
||||
try:
|
||||
page.goto("http://localhost:8000", wait_until="networkidle")
|
||||
print("Navigating to http://localhost:8000")
|
||||
page.goto("http://localhost:8000")
|
||||
# Wait for a bit to capture initial errors
|
||||
page.wait_for_timeout(5000)
|
||||
except Exception as e:
|
||||
print(f"Navigation failed: {e}")
|
||||
|
||||
|
||||
@@ -1 +0,0 @@
|
||||
127.0.0.1 - - [23/Jan/2026 18:34:01] "GET /js/ui/components/SearchFiltersPopover.js HTTP/1.1" 200 -
|
||||
Reference in new issue
Block a user