feat(doctor): open the first location on load
Every address started collapsed, so a doctor with one office made the visitor click before seeing where that office is — the thing they came to the section for. The first entry now renders expanded; the rest stay closed so a long list does not push the page down. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -11,8 +11,8 @@ import RoutingC from "@/components/icons/RoutingC";
|
||||
// Leaflet به window نیاز دارد → فقط کلاینت
|
||||
const MapView = dynamic(() => import("@/components/common/MapView"), { ssr: false });
|
||||
|
||||
function Item({ data, bookable = true }) {
|
||||
const [isOpen, setIsOpen] = useState(false);
|
||||
function Item({ data, bookable = true, defaultOpen = false }) {
|
||||
const [isOpen, setIsOpen] = useState(defaultOpen);
|
||||
|
||||
const [open, setOpen] = useState(false);
|
||||
const handleOpen = () => setOpen(true);
|
||||
|
||||
Reference in New Issue
Block a user