x
This commit is contained in:
1 parent
c365add07f
commit
c449de2482
28 files changed
+694
-300
No files matched your search
@@ -0,0 +1,13 @@
|
||||
export type ThemeTone = 'warning' | 'success' | 'error' | 'info'
|
||||
|
||||
export function toneClass(tone: ThemeTone) {
|
||||
return `ui-tone-${tone}`
|
||||
}
|
||||
|
||||
export function orderStatusBadgeClass(status: string) {
|
||||
if (status === 'PENDING_PAYMENT') return 'ui-status-badge ui-status-badge-pending'
|
||||
if (status === 'PAID' || status === 'PROCESSING') return 'ui-status-badge ui-status-badge-active'
|
||||
if (status === 'SHIPPED' || status === 'DELIVERED') return 'ui-status-badge ui-status-badge-shipped'
|
||||
if (status === 'CANCELLED') return 'ui-status-badge ui-status-badge-cancelled'
|
||||
return 'ui-status-badge ui-status-badge-neutral'
|
||||
}
|
||||
Reference in new issue
Block a user