fix: All 6 issues - WC notices, terminology, tax optional, context

##  Issue #1: WooCommerce Admin Notices
- Added proper CSS styling for .woocommerce-message/error/info
- Border-left color coding (green/red/blue)
- Proper padding, margins, and backgrounds
- Now displays correctly in SPA

##  Issue #2: No Flag Emojis
- Keeping regions as text only (cleaner, more professional)
- Avoids rendering issues and political sensitivities
- Matches Shopify/marketplace approach

##  Issue #3: Added "Available to:" Context
- Zone regions now show: "Available to: Indonesia"
- Makes it clear what the regions mean
- Better UX - no ambiguity

##  Issue #4: Terminology Fixed - "Delivery Option"
- Changed ALL "Shipping Method" → "Delivery Option"
- Matches Shopify/marketplace terminology
- Consistent across desktop and mobile
- "4 delivery options" instead of "4 methods"

##  Issue #5: Tax is Optional
- Tax menu only appears if wc_tax_enabled()
- Matches WooCommerce behavior (appears after enabling)
- Dynamic navigation based on store settings
- Cleaner menu for stores without tax

##  Issue #6: Shipping Method Investigation
- Checked flexible-shipping-ups plugin
- Its a live rates plugin (UPS API)
- Does NOT require subdistrict - only needs:
  - Country, State, City, Postal Code
- Issue: Create Order may be requiring subdistrict for ALL methods
- Need to make address fields conditional based on shipping method type

## Next: Fix Create Order address fields to be conditional
This commit is contained in:
dwindown
2025-11-10 10:46:01 +07:00
parent 93e5a9a3bc
commit e502dcc807
3 changed files with 47 additions and 16 deletions

View File

@@ -169,7 +169,7 @@ class NavigationRegistry {
private static function get_settings_children(): array {
$admin = admin_url('admin.php');
return [
$children = [
// WooNooW Settings
['label' => __('WooNooW', 'woonoow'), 'mode' => 'spa', 'path' => '/settings'],
@@ -177,7 +177,14 @@ class NavigationRegistry {
['label' => __('Store Details', 'woonoow'), 'mode' => 'spa', 'path' => '/settings/store'],
['label' => __('Payments', 'woonoow'), 'mode' => 'spa', 'path' => '/settings/payments'],
['label' => __('Shipping & Delivery', 'woonoow'), 'mode' => 'spa', 'path' => '/settings/shipping'],
['label' => __('Taxes', 'woonoow'), 'mode' => 'spa', 'path' => '/settings/taxes'],
];
// Only show Tax if enabled in WooCommerce
if (wc_tax_enabled()) {
$children[] = ['label' => __('Tax', 'woonoow'), 'mode' => 'spa', 'path' => '/settings/tax'];
}
$children = array_merge($children, [
['label' => __('Checkout', 'woonoow'), 'mode' => 'spa', 'path' => '/settings/checkout'],
['label' => __('Customer Accounts', 'woonoow'), 'mode' => 'spa', 'path' => '/settings/customers'],
['label' => __('Notifications', 'woonoow'), 'mode' => 'spa', 'path' => '/settings/notifications'],
@@ -188,7 +195,9 @@ class NavigationRegistry {
['label' => __('Integrations', 'woonoow'), 'mode' => 'bridge', 'href' => $admin . '?page=wc-settings&tab=integration'],
['label' => __('System Status', 'woonoow'), 'mode' => 'bridge', 'href' => $admin . '?page=wc-status'],
['label' => __('Extensions', 'woonoow'), 'mode' => 'bridge', 'href' => $admin . '?page=wc-addons'],
];
]);
return $children;
}
/**