update welcome tour to show 24 hours account review messages and premium animations

This commit is contained in:
vickytechkey 2026-08-09 12:41:11 +05:30
parent 3bc0c3fe67
commit 6906d30ed0
4 changed files with 62 additions and 15 deletions

View file

@ -63,8 +63,8 @@ describe('Supplier Portal Onboarding & Feature E2E Flow', () => {
cy.contains('Submit Supplier Profile').click(); cy.contains('Submit Supplier Profile').click();
// 6. Setup Welcome Tour Stepper // 6. Setup Welcome Tour Stepper
cy.contains('Welcome to Global Artisans Hub! 🎉').should('be.visible'); cy.contains('Supplier Account Under Review ⏳').should('be.visible');
cy.contains('Start Tour').click(); cy.contains('Start Guided Tour 🎬').click();
cy.contains('📦 Products & Inventory Management').should('be.visible'); cy.contains('📦 Products & Inventory Management').should('be.visible');
cy.contains('Next: Order Management').click(); cy.contains('Next: Order Management').click();
cy.contains('🚚 Order Acceptance Control').should('be.visible'); cy.contains('🚚 Order Acceptance Control').should('be.visible');
@ -72,7 +72,7 @@ describe('Supplier Portal Onboarding & Feature E2E Flow', () => {
cy.contains('🏷️ Barcode Identification & Tracking').should('be.visible'); cy.contains('🏷️ Barcode Identification & Tracking').should('be.visible');
cy.contains('Next: Earnings & Wallet').click(); cy.contains('Next: Earnings & Wallet').click();
cy.contains('💼 Wallet & Payout Withdrawals').should('be.visible'); cy.contains('💼 Wallet & Payout Withdrawals').should('be.visible');
cy.contains('Launch Dashboard 🚀').click(); cy.contains('Explore Dashboard 🚀').click();
// 7. Check Active Dashboard Tab // 7. Check Active Dashboard Tab
cy.contains('Performance Analytics').should('be.visible'); cy.contains('Performance Analytics').should('be.visible');

View file

@ -121,11 +121,11 @@ describe('Supplier Portal Onboarding & Active Dashboard Tests', () => {
const submitBtn = screen.getByRole('button', { name: /Submit Supplier Profile/i }) const submitBtn = screen.getByRole('button', { name: /Submit Supplier Profile/i })
fireEvent.click(submitBtn) fireEvent.click(submitBtn)
// Welcome Page & Setup Tour // Welcome Page & Setup Tour (Account Under Review)
expect(screen.getByText(/Welcome to Global Artisans Hub!/i)).toBeInTheDocument() expect(screen.getByText(/Supplier Account Under Review/i)).toBeInTheDocument()
// Complete tour steps // Complete tour steps
const startTourBtn = screen.getByRole('button', { name: /Start Tour/i }) const startTourBtn = screen.getByRole('button', { name: /Start Guided Tour/i })
fireEvent.click(startTourBtn) fireEvent.click(startTourBtn)
const next1 = screen.getByRole('button', { name: /Next: Order Management/i }) const next1 = screen.getByRole('button', { name: /Next: Order Management/i })
@ -137,7 +137,7 @@ describe('Supplier Portal Onboarding & Active Dashboard Tests', () => {
const next3 = screen.getByRole('button', { name: /Next: Earnings & Wallet/i }) const next3 = screen.getByRole('button', { name: /Next: Earnings & Wallet/i })
fireEvent.click(next3) fireEvent.click(next3)
const finishBtn = screen.getByRole('button', { name: /Launch Dashboard 🚀/i }) const finishBtn = screen.getByRole('button', { name: /Explore Dashboard 🚀/i })
fireEvent.click(finishBtn) fireEvent.click(finishBtn)
// Redirects to Dashboard Page // Redirects to Dashboard Page

View file

@ -2029,10 +2029,10 @@ function WelcomeTourWizard({ onComplete, storeName }: { onComplete: () => void;
const [tourStep, setTourStep] = useState(1) const [tourStep, setTourStep] = useState(1)
const steps = [ const steps = [
{ {
title: "Welcome to Global Artisans Hub! 🎉", title: "Supplier Account Under Review ⏳",
description: `Congratulations ${storeName}! Your supplier profile is verified and complete. Let's take a 1-minute tour to get you familiar with your active workspace so you can begin selling immediately.`, description: `Thank you for completing your profile! Your GSTIN, PAN, and Aadhaar card details have been submitted. Our compliance team is verifying your documents. This review is typically completed within the next 24 hours. While we verify your credentials, let's take a quick animated tour to get you familiar with your dashboard!`,
icon: "🎉", icon: "",
action: "Start Tour" action: "Start Guided Tour 🎬"
}, },
{ {
title: "📦 Products & Inventory Management", title: "📦 Products & Inventory Management",
@ -2056,17 +2056,17 @@ function WelcomeTourWizard({ onComplete, storeName }: { onComplete: () => void;
title: "💼 Wallet & Payout Withdrawals", title: "💼 Wallet & Payout Withdrawals",
description: "Monitor outstanding payouts and withdraw your earnings directly to your bank account anytime. Keep track of transaction receipts directly inside the Wallet tab.", description: "Monitor outstanding payouts and withdraw your earnings directly to your bank account anytime. Keep track of transaction receipts directly inside the Wallet tab.",
icon: "💼", icon: "💼",
action: "Launch Dashboard 🚀" action: "Explore Dashboard 🚀"
} }
] ]
const current = steps[tourStep - 1] const current = steps[tourStep - 1]
return ( return (
<div className="form-card" style={{ maxWidth: '640px', margin: '2rem auto', textAlign: 'center', padding: '2.5rem' }}> <div key={tourStep} className="form-card tour-card-animated" style={{ maxWidth: '640px', margin: '2rem auto', textAlign: 'center', padding: '2.5rem' }}>
<div style={{ fontSize: '4rem', marginBottom: '1rem' }}>{current.icon}</div> <div className="tour-icon-animated" style={{ fontSize: '4.5rem', marginBottom: '1rem' }}>{current.icon}</div>
<h2 className="form-card-title">{current.title}</h2> <h2 className="form-card-title">{current.title}</h2>
<p style={{ color: 'var(--text-muted)', fontSize: '1.05rem', margin: '1.5rem 0 2rem' }}> <p style={{ color: 'var(--text-muted)', fontSize: '1.05rem', margin: '1.5rem 0 2rem', lineHeight: '1.6' }}>
{current.description} {current.description}
</p> </p>
@ -2074,6 +2074,7 @@ function WelcomeTourWizard({ onComplete, storeName }: { onComplete: () => void;
{steps.map((_, idx) => ( {steps.map((_, idx) => (
<div <div
key={idx} key={idx}
className={tourStep === idx + 1 ? 'tour-dot-active' : ''}
style={{ style={{
width: '12px', width: '12px',
height: '12px', height: '12px',

View file

@ -1093,3 +1093,49 @@ body {
} }
} }
/* Animated Tour Keyframes */
@keyframes tourCardEntrance {
0% {
opacity: 0;
transform: translateY(20px) scale(0.98);
}
100% {
opacity: 1;
transform: translateY(0) scale(1);
}
}
@keyframes tourIconBounce {
0%, 100% {
transform: translateY(0) scale(1);
}
50% {
transform: translateY(-8px) scale(1.05);
}
}
@keyframes tourDotPulse {
0%, 100% {
transform: scale(1);
opacity: 0.8;
}
50% {
transform: scale(1.25);
opacity: 1;
}
}
.tour-card-animated {
animation: tourCardEntrance 0.5s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}
.tour-icon-animated {
animation: tourIconBounce 2s infinite ease-in-out;
display: inline-block;
}
.tour-dot-active {
animation: tourDotPulse 1.5s infinite ease-in-out;
}