Fix nested raw! sexp errors and missing container nav in market pages
All checks were successful
Build and Deploy / build-and-deploy (push) Successful in 1m6s
All checks were successful
Build and Deploy / build-and-deploy (push) Successful in 1m6s
- Fix invalid nested (raw! a (raw! b)) patterns in market and events sexp_components — concatenate HTML strings in Python, pass single var to (raw! h) instead - Add container_nav_html fetch to market inject_post context processor so page-scoped market pages show calendar/market nav links - Add qs_filter to base_context for sexp filter URL building Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -1387,10 +1387,10 @@ async def render_market_home_page(ctx: dict) -> str:
|
||||
content = _market_landing_content(post)
|
||||
|
||||
hdr = root_header_html(ctx)
|
||||
child = _post_header_html(ctx) + _market_header_html(ctx)
|
||||
hdr += sexp(
|
||||
'(div :id "root-header-child" :class "w-full" (raw! ph (raw! mh)))',
|
||||
ph=_post_header_html(ctx),
|
||||
mh=_market_header_html(ctx),
|
||||
'(div :id "root-header-child" :class "w-full" (raw! h))',
|
||||
h=child,
|
||||
)
|
||||
menu = _mobile_nav_panel_html(ctx)
|
||||
return full_page(ctx, header_rows_html=hdr, content_html=content, menu_html=menu)
|
||||
@@ -1434,10 +1434,10 @@ async def render_browse_page(ctx: dict) -> str:
|
||||
content = f'<div class="grid grid-cols-1 sm:grid-cols-3 md:grid-cols-6 gap-3">{cards_html}</div><div class="pb-8"></div>'
|
||||
|
||||
hdr = root_header_html(ctx)
|
||||
child = _post_header_html(ctx) + _market_header_html(ctx)
|
||||
hdr += sexp(
|
||||
'(div :id "root-header-child" :class "w-full" (raw! ph (raw! mh)))',
|
||||
ph=_post_header_html(ctx),
|
||||
mh=_market_header_html(ctx),
|
||||
'(div :id "root-header-child" :class "w-full" (raw! h))',
|
||||
h=child,
|
||||
)
|
||||
menu = _mobile_nav_panel_html(ctx)
|
||||
filter_html = _mobile_filter_summary_html(ctx)
|
||||
@@ -1478,11 +1478,10 @@ async def render_product_page(ctx: dict, d: dict) -> str:
|
||||
meta = _product_meta_html(d, ctx)
|
||||
|
||||
hdr = root_header_html(ctx)
|
||||
child = _post_header_html(ctx) + _market_header_html(ctx) + _product_header_html(ctx, d)
|
||||
hdr += sexp(
|
||||
'(div :id "root-header-child" :class "w-full" (raw! ph (raw! mh (raw! prh))))',
|
||||
ph=_post_header_html(ctx),
|
||||
mh=_market_header_html(ctx),
|
||||
prh=_product_header_html(ctx, d),
|
||||
'(div :id "root-header-child" :class "w-full" (raw! h))',
|
||||
h=child,
|
||||
)
|
||||
return full_page(ctx, header_rows_html=hdr, content_html=content, meta_html=meta)
|
||||
|
||||
@@ -1507,12 +1506,11 @@ async def render_product_admin_page(ctx: dict, d: dict) -> str:
|
||||
content = _product_detail_html(d, ctx)
|
||||
|
||||
hdr = root_header_html(ctx)
|
||||
child = (_post_header_html(ctx) + _market_header_html(ctx)
|
||||
+ _product_header_html(ctx, d) + _product_admin_header_html(ctx, d))
|
||||
hdr += sexp(
|
||||
'(div :id "root-header-child" :class "w-full" (raw! ph (raw! mh (raw! prh (raw! pah)))))',
|
||||
ph=_post_header_html(ctx),
|
||||
mh=_market_header_html(ctx),
|
||||
prh=_product_header_html(ctx, d),
|
||||
pah=_product_admin_header_html(ctx, d),
|
||||
'(div :id "root-header-child" :class "w-full" (raw! h))',
|
||||
h=child,
|
||||
)
|
||||
return full_page(ctx, header_rows_html=hdr, content_html=content)
|
||||
|
||||
@@ -1551,11 +1549,10 @@ async def render_market_admin_page(ctx: dict) -> str:
|
||||
content = "market admin"
|
||||
|
||||
hdr = root_header_html(ctx)
|
||||
child = _post_header_html(ctx) + _market_header_html(ctx) + _market_admin_header_html(ctx)
|
||||
hdr += sexp(
|
||||
'(div :id "root-header-child" :class "w-full" (raw! ph (raw! mh (raw! mah))))',
|
||||
ph=_post_header_html(ctx),
|
||||
mh=_market_header_html(ctx),
|
||||
mah=_market_admin_header_html(ctx),
|
||||
'(div :id "root-header-child" :class "w-full" (raw! h))',
|
||||
h=child,
|
||||
)
|
||||
return full_page(ctx, header_rows_html=hdr, content_html=content)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user