@page-speed/maps 0.2.3 → 0.2.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/geo-map.cjs +9 -8
- package/dist/components/geo-map.cjs.map +1 -1
- package/dist/components/geo-map.js +9 -8
- package/dist/components/geo-map.js.map +1 -1
- package/dist/components/index.cjs +9 -8
- package/dist/components/index.cjs.map +1 -1
- package/dist/components/index.js +9 -8
- package/dist/components/index.js.map +1 -1
- package/dist/index.cjs +9 -8
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +9 -8
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/components/index.js
CHANGED
|
@@ -802,8 +802,9 @@ function MarkerActions({ actions }) {
|
|
|
802
802
|
...rest
|
|
803
803
|
} = action;
|
|
804
804
|
const buttonStyles = cn(
|
|
805
|
-
"
|
|
806
|
-
|
|
805
|
+
"gap-2 px-4 py-2 rounded-md font-medium transition-colors duration-500",
|
|
806
|
+
"flex justify-center items-center",
|
|
807
|
+
variant === "outline" ? "border border-border bg-card text-card-foreground hover:bg-primary hover:text-primary-foreground" : "bg-primary text-primary-foreground hover:bg-primary/90",
|
|
807
808
|
size === "sm" && "text-sm px-3 py-1.5",
|
|
808
809
|
size === "icon" && "p-2",
|
|
809
810
|
actionClassName
|
|
@@ -907,7 +908,7 @@ function MarkerMediaCarousel({
|
|
|
907
908
|
children: /* @__PURE__ */ jsx(IconComponent, { name: "lucide/arrow-right", size: 18 })
|
|
908
909
|
}
|
|
909
910
|
),
|
|
910
|
-
/* @__PURE__ */ jsx("div", { className: "absolute bottom-2 left-1/2 flex -translate-x-1/2 items-center gap-1.5 z-
|
|
911
|
+
/* @__PURE__ */ jsx("div", { className: "absolute bottom-2 left-1/2 flex -translate-x-1/2 items-center gap-1.5 z-2", children: mediaItems.map((item, index) => /* @__PURE__ */ jsx(
|
|
911
912
|
"button",
|
|
912
913
|
{
|
|
913
914
|
type: "button",
|
|
@@ -1136,10 +1137,10 @@ function GeoMap({
|
|
|
1136
1137
|
longitude: defaultViewState?.longitude ?? firstCoordinate.longitude,
|
|
1137
1138
|
zoom: defaultViewState?.zoom ?? calculatedZoom
|
|
1138
1139
|
});
|
|
1139
|
-
const [dynamicPanelPosition, setDynamicPanelPosition] = React3.useState(
|
|
1140
|
-
|
|
1140
|
+
const [dynamicPanelPosition, setDynamicPanelPosition] = React3.useState(panelPosition);
|
|
1141
|
+
const viewStateRef = React3.useRef(
|
|
1142
|
+
uncontrolledViewState
|
|
1141
1143
|
);
|
|
1142
|
-
const viewStateRef = React3.useRef(uncontrolledViewState);
|
|
1143
1144
|
React3.useEffect(() => {
|
|
1144
1145
|
if (!viewState && !defaultViewState) {
|
|
1145
1146
|
setUncontrolledViewState((prev) => {
|
|
@@ -1513,7 +1514,7 @@ function GeoMap({
|
|
|
1513
1514
|
{
|
|
1514
1515
|
ref: containerRef,
|
|
1515
1516
|
className: cn(
|
|
1516
|
-
"relative
|
|
1517
|
+
"relative",
|
|
1517
1518
|
// Remove overflow-hidden from outer container to allow panel to overflow
|
|
1518
1519
|
className
|
|
1519
1520
|
),
|
|
@@ -1528,7 +1529,7 @@ function GeoMap({
|
|
|
1528
1529
|
"div",
|
|
1529
1530
|
{
|
|
1530
1531
|
className: cn(
|
|
1531
|
-
"w-full
|
|
1532
|
+
"w-full",
|
|
1532
1533
|
// Only apply default height class if mapWrapperClassName not provided
|
|
1533
1534
|
!mapWrapperClassName && `h-[${calculatedHeight}px]`,
|
|
1534
1535
|
mapWrapperClassName
|