feat: TASK-112 - implement PrescriptionUploadModal and Header direct prescription order button
This commit is contained in:
1 parent
72c126b9ca
commit
201aebd2f5
4 files changed
+205
-2
No files matched your search
@@ -10,6 +10,7 @@ import { useSettingsStore } from "../lib/store/settingsStore";
|
||||
import { toast } from "sonner";
|
||||
import HeaderButton from "./HeaderButton";
|
||||
import AuthModal from "./AuthModal";
|
||||
import PrescriptionUploadModal from "./PrescriptionUploadModal";
|
||||
import { cn } from "../lib/utils";
|
||||
import { productService } from "../lib/services/productService";
|
||||
|
||||
@@ -38,6 +39,7 @@ export default function Header({
|
||||
const [isMegaMenuOpen, setIsMegaMenuOpen] = useState(false);
|
||||
const [isSearchFocused, setIsSearchFocused] = useState(false);
|
||||
const [isAuthModalOpen, setIsAuthModalOpen] = useState(false);
|
||||
const [isPrescriptionModalOpen, setIsPrescriptionModalOpen] = useState(false);
|
||||
const [isPetSwitcherOpen, setIsPetSwitcherOpen] = useState(false);
|
||||
const [searchQuery, setSearchQuery] = useState("");
|
||||
const [isMobileMenuOpen, setIsMobileMenuOpen] = useState(false);
|
||||
@@ -123,6 +125,7 @@ export default function Header({
|
||||
return (
|
||||
<>
|
||||
<AuthModal isOpen={isAuthModalOpen} onClose={() => setIsAuthModalOpen(false)} />
|
||||
<PrescriptionUploadModal isOpen={isPrescriptionModalOpen} onClose={() => setIsPrescriptionModalOpen(false)} />
|
||||
|
||||
<div className="sticky top-0 z-50 w-full shadow-sm">
|
||||
<div className="bg-canina-gold text-canina-dark text-xs font-black py-2 text-center font-vazir tracking-wider flex items-center justify-center gap-2">
|
||||
@@ -247,6 +250,15 @@ export default function Header({
|
||||
{/* Action Area */}
|
||||
<div className="flex items-center gap-2 sm:gap-4 flex-shrink-0 justify-end h-auto md:h-16 pl-1 sm:pl-2">
|
||||
|
||||
{/* Quick Prescription Upload Button */}
|
||||
<button
|
||||
onClick={() => setIsPrescriptionModalOpen(true)}
|
||||
className="hidden lg:flex items-center gap-1.5 px-3 py-2 bg-emerald-50 text-emerald-700 border border-emerald-200 hover:bg-emerald-100 rounded-xl text-xs font-black transition-all shadow-xs"
|
||||
>
|
||||
<FileHeart className="w-4 h-4 text-emerald-600" />
|
||||
<span>ثبت نسخه دامپزشک</span>
|
||||
</button>
|
||||
|
||||
{/* Elastic Search */}
|
||||
{/* Elastic Search */}
|
||||
<div className="relative flex items-center justify-end z-30">
|
||||
|
||||
Reference in new issue
Block a user