|
@@ -122,56 +122,56 @@ export class PageCrmPlatform implements AfterViewInit {
|
|
];
|
|
];
|
|
|
|
|
|
ngAfterViewInit() {
|
|
ngAfterViewInit() {
|
|
- new Swiper('.swiper-container', {
|
|
|
|
- // 启用导航模块
|
|
|
|
- modules: [Navigation, Pagination, Autoplay],
|
|
|
|
-
|
|
|
|
- // 基本配置
|
|
|
|
- direction: 'horizontal',
|
|
|
|
- loop: true,
|
|
|
|
- speed: 600,
|
|
|
|
-
|
|
|
|
- // 分页器配置
|
|
|
|
- pagination: {
|
|
|
|
- el: '.swiper-pagination',
|
|
|
|
- clickable: true,
|
|
|
|
- dynamicBullets: true
|
|
|
|
- },
|
|
|
|
-
|
|
|
|
- // 导航按钮配置(关键修复)
|
|
|
|
- navigation: {
|
|
|
|
- nextEl: '.swiper-button-next',
|
|
|
|
- prevEl: '.swiper-button-prev',
|
|
|
|
- disabledClass: 'swiper-button-disabled' // 添加禁用状态类
|
|
|
|
- },
|
|
|
|
-
|
|
|
|
- // 自动播放配置
|
|
|
|
- autoplay: {
|
|
|
|
- delay: 5000,
|
|
|
|
- disableOnInteraction: false,
|
|
|
|
- },
|
|
|
|
-
|
|
|
|
- // 效果配置
|
|
|
|
- effect: 'fade',
|
|
|
|
- fadeEffect: {
|
|
|
|
- crossFade: true
|
|
|
|
- },
|
|
|
|
-
|
|
|
|
- // 键盘控制
|
|
|
|
- keyboard: {
|
|
|
|
- enabled: true,
|
|
|
|
- onlyInViewport: true,
|
|
|
|
- },
|
|
|
|
-
|
|
|
|
- // 触摸控制
|
|
|
|
- grabCursor: true,
|
|
|
|
-
|
|
|
|
- // 响应式配置
|
|
|
|
- breakpoints: {
|
|
|
|
- 480: {
|
|
|
|
- effect: 'slide'
|
|
|
|
|
|
+ new Swiper('.swiper-container', {
|
|
|
|
+ // 启用导航模块
|
|
|
|
+ modules: [Navigation, Pagination, Autoplay],
|
|
|
|
+
|
|
|
|
+ // 基本配置
|
|
|
|
+ direction: 'horizontal',
|
|
|
|
+ loop: true,
|
|
|
|
+ speed: 600,
|
|
|
|
+
|
|
|
|
+ // 分页器配置
|
|
|
|
+ pagination: {
|
|
|
|
+ el: '.swiper-pagination',
|
|
|
|
+ clickable: true,
|
|
|
|
+ dynamicBullets: true
|
|
|
|
+ },
|
|
|
|
+
|
|
|
|
+ // 导航按钮配置(关键修复)
|
|
|
|
+ navigation: {
|
|
|
|
+ nextEl: '.swiper-button-next',
|
|
|
|
+ prevEl: '.swiper-button-prev',
|
|
|
|
+ disabledClass: 'swiper-button-disabled' // 添加禁用状态类
|
|
|
|
+ },
|
|
|
|
+
|
|
|
|
+ // 自动播放配置
|
|
|
|
+ autoplay: {
|
|
|
|
+ delay: 5000,
|
|
|
|
+ disableOnInteraction: false,
|
|
|
|
+ },
|
|
|
|
+
|
|
|
|
+ // 效果配置
|
|
|
|
+ effect: 'fade',
|
|
|
|
+ fadeEffect: {
|
|
|
|
+ crossFade: true
|
|
|
|
+ },
|
|
|
|
+
|
|
|
|
+ // 键盘控制
|
|
|
|
+ keyboard: {
|
|
|
|
+ enabled: true,
|
|
|
|
+ onlyInViewport: true,
|
|
|
|
+ },
|
|
|
|
+
|
|
|
|
+ // 触摸控制
|
|
|
|
+ grabCursor: true,
|
|
|
|
+
|
|
|
|
+ // 响应式配置
|
|
|
|
+ breakpoints: {
|
|
|
|
+ 480: {
|
|
|
|
+ effect: 'slide'
|
|
|
|
+ }
|
|
}
|
|
}
|
|
- }
|
|
|
|
- });
|
|
|
|
-}
|
|
|
|
|
|
+ });
|
|
|
|
+ }
|
|
}
|
|
}
|