feat: product page layout toggle (flat/card), fix email shortcode rendering
- Add layout_style setting (flat default) to product appearance
- AppearanceController: sanitize & persist layout_style, add to default settings
- Admin SPA: Layout Style select in Appearance > Product
- Customer SPA: useEffect targets <main> bg-white in flat mode (full-width),
card mode uses per-section white floating cards on gray background
- Accordion sections styled per mode: flat=border-t dividers, card=white cards
- Fix email shortcode gaps (EmailRenderer, EmailManager)
- Add missing variables: return_url, contact_url, account_url (alias),
payment_error_reason, order_items_list (alias for order_items_table)
- Fix customer_note extra_data key mismatch (note → customer_note)
- Pass low_stock_threshold via extra_data in low_stock email send
This commit is contained in:
@@ -381,6 +381,7 @@ class AppearanceController
|
||||
'image_position' => sanitize_text_field($data['layout']['image_position'] ?? 'left'),
|
||||
'gallery_style' => sanitize_text_field($data['layout']['gallery_style'] ?? 'thumbnails'),
|
||||
'sticky_add_to_cart' => (bool) ($data['layout']['sticky_add_to_cart'] ?? false),
|
||||
'layout_style' => sanitize_text_field($data['layout']['layout_style'] ?? 'flat'),
|
||||
],
|
||||
'elements' => [
|
||||
'breadcrumbs' => (bool) ($data['elements']['breadcrumbs'] ?? true),
|
||||
@@ -601,7 +602,11 @@ class AppearanceController
|
||||
'show_icon' => true,
|
||||
],
|
||||
],
|
||||
'product' => [],
|
||||
'product' => [
|
||||
'layout' => [
|
||||
'layout_style' => 'flat',
|
||||
],
|
||||
],
|
||||
'cart' => [],
|
||||
'checkout' => [],
|
||||
'thankyou' => [],
|
||||
|
||||
Reference in New Issue
Block a user