Compare commits

..

1 commit

Author SHA1 Message Date
Adam Moussa
009ce7b6f8
Merge e319e4a0d3 into 57a6412811 2026-07-30 00:12:12 +00:00
3 changed files with 2 additions and 12 deletions

View file

@ -38,13 +38,8 @@ def latest_menu() -> dict:
def _json_for_script(value) -> str:
"""Serialize for embedding in a <script> tag; escape < and JS line separators."""
return (
json.dumps(value, separators=(",", ":"))
.replace("<", "\\u003c")
.replace("\u2028", "\\u2028")
.replace("\u2029", "\\u2029")
)
"""Serialize for embedding in a <script> tag; escape </ to avoid early close."""
return json.dumps(value, separators=(",", ":")).replace("</", "<\\/")
def generate_form(

View file

@ -1,5 +1,4 @@
/* ADMIN_JS_MARKER */
(() => {
const ADMIN_URL = window.ADMIN_URL;
const ADMIN_PDF_URL = window.ADMIN_PDF_URL;
const MEALS = window.MEALS;
@ -445,4 +444,3 @@ function adminInit() {
}
adminInit();
})();

View file

@ -259,9 +259,6 @@ class TestGenerateFormPlaywright:
yield page
browser.close()
def test_admin_bundle_loads(self, browser_page):
assert browser_page.evaluate("typeof window.loadWeekOrders") == "function"
def test_qty_plus_updates_total_without_list_teardown(self, browser_page):
page = browser_page
card = page.locator('[data-meal-index="0"]')