Redesign orders/cart/search flows and fix RTL/auth edge cases in user-app
- Fix silent redirect-to-home for unauthenticated users on protected routes; now redirects to login with a return path - Restyle OrderCard, SearchInput, Filters, DropDown, and product card image sizing/centering to match the app's LESS-token design language - Fix ant-design Slider handle placement/drag under RTL and seed a valid default range so handles actually render - Fix chip-row edge padding and top spacing across Orders/Cart/Search lists - Add pull-to-refresh to the dashboard and fix its header/padding to match the fixed PageBar pattern - Remove the floating WhatsApp button from index.html
This commit is contained in:
@@ -1,14 +1,14 @@
|
||||
// Ported from legacy henza_pwa/src/store/navStore.ts (a hand-rolled reactive
|
||||
// class) to a real Pinia store, preserving the exact same state shape and
|
||||
// setter behavior — including the pre-existing path/route-name mismatch on
|
||||
// the "home" entry (path: '/' vs. the app's actual /home route), which is
|
||||
// unused dead data since navigation uses `name`, not `path`. Ported as-is.
|
||||
// class) to a real Pinia store, preserving the same state shape and setter
|
||||
// behavior. The route list itself was redesigned to a 5-tab bottom nav
|
||||
// (Home, Search, Cart, Orders, Profile) — see components/ui/Navigation.vue.
|
||||
import { defineStore } from 'pinia'
|
||||
|
||||
interface NavItem {
|
||||
name: string
|
||||
path: string
|
||||
icon: string
|
||||
label: string
|
||||
index: number
|
||||
}
|
||||
|
||||
@@ -23,12 +23,13 @@ interface NavState {
|
||||
export const useNavStore = defineStore('nav', {
|
||||
state: (): NavState => ({
|
||||
navBarRoutes: [
|
||||
{ name: 'userPage::hasSubRoute', path: '/user', icon: 'vuesax-linear:user', index: 1 },
|
||||
{ name: 'cart', path: '/cart', icon: 'vuesax-linear:bag-happy', index: 2 },
|
||||
{ name: 'search', path: '/search', icon: 'vuesax-linear:search-normal-1', index: 3 },
|
||||
{ name: 'home', path: '/', icon: 'vuesax-linear:home-2', index: 4 },
|
||||
{ name: 'home', path: '/home', icon: 'vuesax-linear:home-2', label: 'خانه', index: 1 },
|
||||
{ name: 'search', path: '/search', icon: 'vuesax-linear:search-normal-1', label: 'جستجو', index: 2 },
|
||||
{ name: 'cart', path: '/cart', icon: 'vuesax-linear:bag-happy', label: 'سبد خرید', index: 3 },
|
||||
{ name: 'ordersList', path: '/orders', icon: 'vuesax-linear:receipt-text', label: 'سفارشات', index: 4 },
|
||||
{ name: 'userPage::hasSubRoute', path: '/user', icon: 'vuesax-linear:user', label: 'پروفایل', index: 5 },
|
||||
],
|
||||
activeLink: 4,
|
||||
activeLink: 1,
|
||||
showNav: true,
|
||||
pageTransition: 'right',
|
||||
}),
|
||||
|
||||
Reference in New Issue
Block a user