@anker-in/ui 0.1.2 → 0.1.3
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/index.js +26 -9
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +26 -9
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -1861,21 +1861,38 @@ var DemoRoom = ({
|
|
|
1861
1861
|
] });
|
|
1862
1862
|
};
|
|
1863
1863
|
DemoRoom.displayName = "DemoRoom";
|
|
1864
|
-
var
|
|
1864
|
+
var Navigation;
|
|
1865
|
+
var Pagination;
|
|
1866
|
+
var Autoplay;
|
|
1867
|
+
var swiperVersion = "11+";
|
|
1865
1868
|
try {
|
|
1866
|
-
|
|
1869
|
+
const modules = __require("swiper/modules");
|
|
1870
|
+
Navigation = modules.Navigation;
|
|
1871
|
+
Pagination = modules.Pagination;
|
|
1872
|
+
Autoplay = modules.Autoplay;
|
|
1873
|
+
swiperVersion = "11+";
|
|
1867
1874
|
} catch (e) {
|
|
1868
1875
|
try {
|
|
1869
1876
|
const SwiperCore = __require("swiper");
|
|
1870
|
-
|
|
1877
|
+
const SwiperNavigation = __require("swiper/modules/navigation");
|
|
1878
|
+
const SwiperPagination = __require("swiper/modules/pagination");
|
|
1879
|
+
const SwiperAutoplay = __require("swiper/modules/autoplay");
|
|
1880
|
+
const SwiperClass = SwiperCore.default || SwiperCore;
|
|
1881
|
+
if (SwiperClass && SwiperClass.use) {
|
|
1882
|
+
SwiperClass.use([
|
|
1883
|
+
SwiperNavigation.default || SwiperNavigation,
|
|
1884
|
+
SwiperPagination.default || SwiperPagination,
|
|
1885
|
+
SwiperAutoplay.default || SwiperAutoplay
|
|
1886
|
+
]);
|
|
1887
|
+
}
|
|
1888
|
+
Navigation = SwiperNavigation.default || SwiperNavigation;
|
|
1889
|
+
Pagination = SwiperPagination.default || SwiperPagination;
|
|
1890
|
+
Autoplay = SwiperAutoplay.default || SwiperAutoplay;
|
|
1891
|
+
swiperVersion = "8";
|
|
1871
1892
|
} catch (e2) {
|
|
1872
|
-
console.warn("Failed to load swiper modules");
|
|
1873
|
-
swiperModules = {};
|
|
1893
|
+
console.warn("Failed to load swiper modules:", e2);
|
|
1874
1894
|
}
|
|
1875
1895
|
}
|
|
1876
|
-
var Navigation = swiperModules.Navigation;
|
|
1877
|
-
var Pagination = swiperModules.Pagination;
|
|
1878
|
-
var Autoplay = swiperModules.Autoplay;
|
|
1879
1896
|
if (typeof window !== "undefined") {
|
|
1880
1897
|
try {
|
|
1881
1898
|
__require("swiper/css");
|
|
@@ -2075,7 +2092,7 @@ var DemoRoomDetail = ({
|
|
|
2075
2092
|
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "relative h-[400px] rounded-2xl overflow-hidden", children: images.length > 0 ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
2076
2093
|
react.Swiper,
|
|
2077
2094
|
{
|
|
2078
|
-
modules: [Navigation, Pagination, Autoplay],
|
|
2095
|
+
...swiperVersion === "11+" && Navigation && Pagination && Autoplay ? { modules: [Navigation, Pagination, Autoplay] } : {},
|
|
2079
2096
|
spaceBetween: 0,
|
|
2080
2097
|
slidesPerView: 1,
|
|
2081
2098
|
navigation: true,
|