@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.mjs
CHANGED
|
@@ -1849,21 +1849,38 @@ var DemoRoom = ({
|
|
|
1849
1849
|
] });
|
|
1850
1850
|
};
|
|
1851
1851
|
DemoRoom.displayName = "DemoRoom";
|
|
1852
|
-
var
|
|
1852
|
+
var Navigation;
|
|
1853
|
+
var Pagination;
|
|
1854
|
+
var Autoplay;
|
|
1855
|
+
var swiperVersion = "11+";
|
|
1853
1856
|
try {
|
|
1854
|
-
|
|
1857
|
+
const modules = __require("swiper/modules");
|
|
1858
|
+
Navigation = modules.Navigation;
|
|
1859
|
+
Pagination = modules.Pagination;
|
|
1860
|
+
Autoplay = modules.Autoplay;
|
|
1861
|
+
swiperVersion = "11+";
|
|
1855
1862
|
} catch (e) {
|
|
1856
1863
|
try {
|
|
1857
1864
|
const SwiperCore = __require("swiper");
|
|
1858
|
-
|
|
1865
|
+
const SwiperNavigation = __require("swiper/modules/navigation");
|
|
1866
|
+
const SwiperPagination = __require("swiper/modules/pagination");
|
|
1867
|
+
const SwiperAutoplay = __require("swiper/modules/autoplay");
|
|
1868
|
+
const SwiperClass = SwiperCore.default || SwiperCore;
|
|
1869
|
+
if (SwiperClass && SwiperClass.use) {
|
|
1870
|
+
SwiperClass.use([
|
|
1871
|
+
SwiperNavigation.default || SwiperNavigation,
|
|
1872
|
+
SwiperPagination.default || SwiperPagination,
|
|
1873
|
+
SwiperAutoplay.default || SwiperAutoplay
|
|
1874
|
+
]);
|
|
1875
|
+
}
|
|
1876
|
+
Navigation = SwiperNavigation.default || SwiperNavigation;
|
|
1877
|
+
Pagination = SwiperPagination.default || SwiperPagination;
|
|
1878
|
+
Autoplay = SwiperAutoplay.default || SwiperAutoplay;
|
|
1879
|
+
swiperVersion = "8";
|
|
1859
1880
|
} catch (e2) {
|
|
1860
|
-
console.warn("Failed to load swiper modules");
|
|
1861
|
-
swiperModules = {};
|
|
1881
|
+
console.warn("Failed to load swiper modules:", e2);
|
|
1862
1882
|
}
|
|
1863
1883
|
}
|
|
1864
|
-
var Navigation = swiperModules.Navigation;
|
|
1865
|
-
var Pagination = swiperModules.Pagination;
|
|
1866
|
-
var Autoplay = swiperModules.Autoplay;
|
|
1867
1884
|
if (typeof window !== "undefined") {
|
|
1868
1885
|
try {
|
|
1869
1886
|
__require("swiper/css");
|
|
@@ -2063,7 +2080,7 @@ var DemoRoomDetail = ({
|
|
|
2063
2080
|
/* @__PURE__ */ jsx("div", { className: "relative h-[400px] rounded-2xl overflow-hidden", children: images.length > 0 ? /* @__PURE__ */ jsx(
|
|
2064
2081
|
Swiper,
|
|
2065
2082
|
{
|
|
2066
|
-
modules: [Navigation, Pagination, Autoplay],
|
|
2083
|
+
...swiperVersion === "11+" && Navigation && Pagination && Autoplay ? { modules: [Navigation, Pagination, Autoplay] } : {},
|
|
2067
2084
|
spaceBetween: 0,
|
|
2068
2085
|
slidesPerView: 1,
|
|
2069
2086
|
navigation: true,
|