赣州市洪水风险预警系统二维版本
xiebin
2023-03-02 b39483c96ae572121d3c619c0b9d37634e682cc4
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
1038
1039
1040
1041
1042
1043
1044
1045
1046
1047
1048
1049
1050
1051
1052
1053
1054
1055
1056
1057
1058
1059
1060
1061
1062
1063
1064
1065
1066
1067
1068
1069
1070
1071
1072
1073
1074
1075
1076
1077
1078
1079
1080
1081
1082
1083
1084
1085
1086
1087
1088
1089
1090
1091
1092
1093
1094
1095
1096
1097
1098
1099
1100
1101
1102
1103
1104
1105
1106
1107
1108
1109
1110
1111
1112
1113
1114
1115
1116
1117
1118
1119
1120
1121
1122
1123
1124
1125
1126
1127
1128
1129
1130
1131
1132
1133
1134
1135
1136
1137
1138
1139
1140
1141
1142
1143
1144
1145
1146
1147
1148
1149
1150
1151
1152
1153
1154
1155
1156
1157
1158
1159
1160
1161
1162
1163
1164
1165
1166
1167
1168
1169
1170
1171
1172
1173
1174
1175
1176
1177
1178
1179
1180
1181
1182
1183
1184
1185
1186
1187
1188
1189
1190
1191
1192
1193
1194
1195
1196
1197
1198
/*mousewheel*/
(function(a) {
    function d(b) {
        var c = b || window.event,
            d = [].slice.call(arguments, 1),
            e = 0,
            f = !0,
            g = 0,
            h = 0;
        return b = a.event.fix(c), b.type = "mousewheel", c.wheelDelta && (e = c.wheelDelta / 120), c.detail && (e = -c.detail / 3), h = e, c.axis !== undefined && c.axis === c.HORIZONTAL_AXIS && (h = 0, g = -1 * e), c.wheelDeltaY !== undefined && (h = c.wheelDeltaY / 120), c.wheelDeltaX !== undefined && (g = -1 * c.wheelDeltaX / 120), d.unshift(b, e, g, h), (a.event.dispatch || a.event.handle).apply(this, d)
    }
    var b = ["DOMMouseScroll", "mousewheel"];
    if(a.event.fixHooks)
        for(var c = b.length; c;) a.event.fixHooks[b[--c]] = a.event.mouseHooks;
    a.event.special.mousewheel = {
        setup: function() {
            if(this.addEventListener)
                for(var a = b.length; a;) this.addEventListener(b[--a], d, !1);
            else this.onmousewheel = d
        },
        teardown: function() {
            if(this.removeEventListener)
                for(var a = b.length; a;) this.removeEventListener(b[--a], d, !1);
            else this.onmousewheel = null
        }
    }, a.fn.extend({
        mousewheel: function(a) {
            return a ? this.bind("mousewheel", a) : this.trigger("mousewheel")
        },
        unmousewheel: function(a) {
            return this.unbind("mousewheel", a)
        }
    })
})(jQuery);
/*custom scrollbar*/
(function(c) {
    var b = {
            init: function(e) {
                var f = {
                        set_width: false,
                        set_height: false,
                        horizontalScroll: false,
                        scrollInertia: 950,
                        mouseWheel: true,
                        mouseWheelPixels: "auto",
                        autoDraggerLength: true,
                        autoHideScrollbar: false,
                        snapAmount: null,
                        snapOffset: 0,
                        scrollButtons: {
                            enable: false,
                            scrollType: "continuous",
                            scrollSpeed: "auto",
                            scrollAmount: 40
                        },
                        advanced: {
                            updateOnBrowserResize: true,
                            updateOnContentResize: false,
                            autoExpandHorizontalScroll: false,
                            autoScrollOnFocus: true,
                            normalizeMouseWheelDelta: false
                        },
                        contentTouchScroll: true,
                        callbacks: {
                            onScrollStart: function() {},
                            onScroll: function() {},
                            onTotalScroll: function() {},
                            onTotalScrollBack: function() {},
                            onTotalScrollOffset: 0,
                            onTotalScrollBackOffset: 0,
                            whileScrolling: function() {}
                        },
                        theme: "light"
                    },
                    e = c.extend(true, f, e);
                return this.each(function() {
                    var m = c(this);
                    if(e.set_width) {
                        m.css("width", e.set_width)
                    }
                    if(e.set_height) {
                        m.css("height", e.set_height)
                    }
                    if(!c(document).data("mCustomScrollbar-index")) {
                        c(document).data("mCustomScrollbar-index", "1")
                    } else {
                        var t = parseInt(c(document).data("mCustomScrollbar-index"));
                        c(document).data("mCustomScrollbar-index", t + 1)
                    }
                    m.wrapInner("<div class='mCustomScrollBox mCS-" + e.theme + "' id='mCSB_" + c(document).data("mCustomScrollbar-index") + "' style='position:relative; height:100%; overflow:hidden; max-width:100%;' />").addClass("mCustomScrollbar _mCS_" + c(document).data("mCustomScrollbar-index"));
                    var g = m.children(".mCustomScrollBox");
                    if(e.horizontalScroll) {
                        g.addClass("mCSB_horizontal").wrapInner("<div class='mCSB_h_wrapper' style='position:relative; left:0; width:999999px;' />");
                        var k = g.children(".mCSB_h_wrapper");
                        k.wrapInner("<div class='mCSB_container' style='position:absolute; left:0;' />").children(".mCSB_container").css({
                            width: k.children().outerWidth(),
                            position: "relative"
                        }).unwrap()
                    } else {
                        g.wrapInner("<div class='mCSB_container' style='position:relative; top:0;' />")
                    }
                    var o = g.children(".mCSB_container");
                    if(c.support.touch) {
                        o.addClass("mCS_touch")
                    }
                    o.after("<div class='mCSB_scrollTools' style='position:absolute;'><div class='mCSB_draggerContainer'><div class='mCSB_dragger' style='position:absolute;' oncontextmenu='return false;'><div class='mCSB_dragger_bar' style='position:relative;'></div></div><div class='mCSB_draggerRail'></div></div></div>");
                    var l = g.children(".mCSB_scrollTools"),
                        h = l.children(".mCSB_draggerContainer"),
                        q = h.children(".mCSB_dragger");
                    if(e.horizontalScroll) {
                        q.data("minDraggerWidth", q.width())
                    } else {
                        q.data("minDraggerHeight", q.height())
                    }
                    if(e.scrollButtons.enable) {
                        if(e.horizontalScroll) {
                            l.prepend("<a class='mCSB_buttonLeft' oncontextmenu='return false;'></a>").append("<a class='mCSB_buttonRight' oncontextmenu='return false;'></a>")
                        } else {
                            l.prepend("<a class='mCSB_buttonUp' oncontextmenu='return false;'></a>").append("<a class='mCSB_buttonDown' oncontextmenu='return false;'></a>")
                        }
                    }
                    g.bind("scroll", function() {
                        if(!m.is(".mCS_disabled")) {
                            g.scrollTop(0).scrollLeft(0)
                        }
                    });
                    m.data({
                        mCS_Init: true,
                        mCustomScrollbarIndex: c(document).data("mCustomScrollbar-index"),
                        horizontalScroll: e.horizontalScroll,
                        scrollInertia: e.scrollInertia,
                        scrollEasing: "mcsEaseOut",
                        mouseWheel: e.mouseWheel,
                        mouseWheelPixels: e.mouseWheelPixels,
                        autoDraggerLength: e.autoDraggerLength,
                        autoHideScrollbar: e.autoHideScrollbar,
                        snapAmount: e.snapAmount,
                        snapOffset: e.snapOffset,
                        scrollButtons_enable: e.scrollButtons.enable,
                        scrollButtons_scrollType: e.scrollButtons.scrollType,
                        scrollButtons_scrollSpeed: e.scrollButtons.scrollSpeed,
                        scrollButtons_scrollAmount: e.scrollButtons.scrollAmount,
                        autoExpandHorizontalScroll: e.advanced.autoExpandHorizontalScroll,
                        autoScrollOnFocus: e.advanced.autoScrollOnFocus,
                        normalizeMouseWheelDelta: e.advanced.normalizeMouseWheelDelta,
                        contentTouchScroll: e.contentTouchScroll,
                        onScrollStart_Callback: e.callbacks.onScrollStart,
                        onScroll_Callback: e.callbacks.onScroll,
                        onTotalScroll_Callback: e.callbacks.onTotalScroll,
                        onTotalScrollBack_Callback: e.callbacks.onTotalScrollBack,
                        onTotalScroll_Offset: e.callbacks.onTotalScrollOffset,
                        onTotalScrollBack_Offset: e.callbacks.onTotalScrollBackOffset,
                        whileScrolling_Callback: e.callbacks.whileScrolling,
                        bindEvent_scrollbar_drag: false,
                        bindEvent_content_touch: false,
                        bindEvent_scrollbar_click: false,
                        bindEvent_mousewheel: false,
                        bindEvent_buttonsContinuous_y: false,
                        bindEvent_buttonsContinuous_x: false,
                        bindEvent_buttonsPixels_y: false,
                        bindEvent_buttonsPixels_x: false,
                        bindEvent_focusin: false,
                        bindEvent_autoHideScrollbar: false,
                        mCSB_buttonScrollRight: false,
                        mCSB_buttonScrollLeft: false,
                        mCSB_buttonScrollDown: false,
                        mCSB_buttonScrollUp: false
                    });
                    if(e.horizontalScroll) {
                        if(m.css("max-width") !== "none") {
                            if(!e.advanced.updateOnContentResize) {
                                e.advanced.updateOnContentResize = true
                            }
                        }
                    } else {
                        if(m.css("max-height") !== "none") {
                            var s = false,
                                r = parseInt(m.css("max-height"));
                            if(m.css("max-height").indexOf("%") >= 0) {
                                s = r, r = m.parent().height() * s / 100
                            }
                            m.css("overflow", "hidden");
                            g.css("max-height", r)
                        }
                    }
                    m.mCustomScrollbar("update");
                    if(e.advanced.updateOnBrowserResize) {
                        var i, j = c(window).width(),
                            u = c(window).height();
                        c(window).bind("resize." + m.data("mCustomScrollbarIndex"), function() {
                            if(i) {
                                clearTimeout(i)
                            }
                            i = setTimeout(function() {
                                if(!m.is(".mCS_disabled") && !m.is(".mCS_destroyed")) {
                                    var w = c(window).width(),
                                        v = c(window).height();
                                    if(j !== w || u !== v) {
                                        if(m.css("max-height") !== "none" && s) {
                                            g.css("max-height", m.parent().height() * s / 100)
                                        }
                                        m.mCustomScrollbar("update");
                                        j = w;
                                        u = v
                                    }
                                }
                            }, 150)
                        })
                    }
                    if(e.advanced.updateOnContentResize) {
                        var p;
                        if(e.horizontalScroll) {
                            var n = o.outerWidth()
                        } else {
                            var n = o.outerHeight()
                        }
                        p = setInterval(function() {
                            if(e.horizontalScroll) {
                                if(e.advanced.autoExpandHorizontalScroll) {
                                    o.css({
                                        position: "absolute",
                                        width: "auto"
                                    }).wrap("<div class='mCSB_h_wrapper' style='position:relative; left:0; width:999999px;' />").css({
                                        width: o.outerWidth(),
                                        position: "relative"
                                    }).unwrap()
                                }
                                var v = o.outerWidth()
                            } else {
                                var v = o.outerHeight()
                            }
                            if(v != n) {
                                m.mCustomScrollbar("update");
                                n = v
                            }
                        }, 300)
                    }
                })
            },
            update: function() {
                var n = c(this),
                    k = n.children(".mCustomScrollBox"),
                    q = k.children(".mCSB_container");
                q.removeClass("mCS_no_scrollbar");
                n.removeClass("mCS_disabled mCS_destroyed");
                k.scrollTop(0).scrollLeft(0);
                var y = k.children(".mCSB_scrollTools"),
                    o = y.children(".mCSB_draggerContainer"),
                    m = o.children(".mCSB_dragger");
                if(n.data("horizontalScroll")) {
                    var A = y.children(".mCSB_buttonLeft"),
                        t = y.children(".mCSB_buttonRight"),
                        f = k.width();
                    if(n.data("autoExpandHorizontalScroll")) {
                        q.css({
                            position: "absolute",
                            width: "auto"
                        }).wrap("<div class='mCSB_h_wrapper' style='position:relative; left:0; width:999999px;' />").css({
                            width: q.outerWidth(),
                            position: "relative"
                        }).unwrap()
                    }
                    var z = q.outerWidth()
                } else {
                    var w = y.children(".mCSB_buttonUp"),
                        g = y.children(".mCSB_buttonDown"),
                        r = k.height(),
                        i = q.outerHeight()
                }
                if(i > r && !n.data("horizontalScroll")) {
                    y.css("display", "block");
                    var s = o.height();
                    if(n.data("autoDraggerLength")) {
                        var u = Math.round(r / i * s),
                            l = m.data("minDraggerHeight");
                        if(u <= l) {
                            m.css({
                                height: l
                            })
                        } else {
                            if(u >= s - 10) {
                                var p = s - 10;
                                m.css({
                                    height: p
                                })
                            } else {
                                m.css({
                                    height: u
                                })
                            }
                        }
                        m.children(".mCSB_dragger_bar").css({
                            "line-height": m.height() + "px"
                        })
                    }
                    var B = m.height(),
                        x = (i - r) / (s - B);
                    n.data("scrollAmount", x).mCustomScrollbar("scrolling", k, q, o, m, w, g, A, t);
                    var D = Math.abs(q.position().top);
                    n.mCustomScrollbar("scrollTo", D, {
                        scrollInertia: 0,
                        trigger: "internal"
                    })
                } else {
                    if(z > f && n.data("horizontalScroll")) {
                        y.css("display", "block");
                        var h = o.width();
                        if(n.data("autoDraggerLength")) {
                            var j = Math.round(f / z * h),
                                C = m.data("minDraggerWidth");
                            if(j <= C) {
                                m.css({
                                    width: C
                                })
                            } else {
                                if(j >= h - 10) {
                                    var e = h - 10;
                                    m.css({
                                        width: e
                                    })
                                } else {
                                    m.css({
                                        width: j
                                    })
                                }
                            }
                        }
                        var v = m.width(),
                            x = (z - f) / (h - v);
                        n.data("scrollAmount", x).mCustomScrollbar("scrolling", k, q, o, m, w, g, A, t);
                        var D = Math.abs(q.position().left);
                        n.mCustomScrollbar("scrollTo", D, {
                            scrollInertia: 0,
                            trigger: "internal"
                        })
                    } else {
                        k.unbind("mousewheel focusin");
                        if(n.data("horizontalScroll")) {
                            m.add(q).css("left", 0)
                        } else {
                            m.add(q).css("top", 0)
                        }
                        y.css("display", "none");
                        q.addClass("mCS_no_scrollbar");
                        n.data({
                            bindEvent_mousewheel: false,
                            bindEvent_focusin: false
                        })
                    }
                }
            },
            scrolling: function(h, p, m, j, w, e, A, v) {
                var k = c(this);
                if(!k.data("bindEvent_scrollbar_drag")) {
                    var n, o;
                    if(c.support.msPointer) {
                        j.bind("MSPointerDown", function(H) {
                            H.preventDefault();
                            k.data({
                                on_drag: true
                            });
                            j.addClass("mCSB_dragger_onDrag");
                            var G = c(this),
                                J = G.offset(),
                                F = H.originalEvent.pageX - J.left,
                                I = H.originalEvent.pageY - J.top;
                            if(F < G.width() && F > 0 && I < G.height() && I > 0) {
                                n = I;
                                o = F
                            }
                        });
                        c(document).bind("MSPointerMove." + k.data("mCustomScrollbarIndex"), function(H) {
                            H.preventDefault();
                            if(k.data("on_drag")) {
                                var G = j,
                                    J = G.offset(),
                                    F = H.originalEvent.pageX - J.left,
                                    I = H.originalEvent.pageY - J.top;
                                D(n, o, I, F)
                            }
                        }).bind("MSPointerUp." + k.data("mCustomScrollbarIndex"), function(x) {
                            k.data({
                                on_drag: false
                            });
                            j.removeClass("mCSB_dragger_onDrag")
                        })
                    } else {
                        j.bind("mousedown touchstart", function(H) {
                            H.preventDefault();
                            H.stopImmediatePropagation();
                            var G = c(this),
                                K = G.offset(),
                                F, J;
                            if(H.type === "touchstart") {
                                var I = H.originalEvent.touches[0] || H.originalEvent.changedTouches[0];
                                F = I.pageX - K.left;
                                J = I.pageY - K.top
                            } else {
                                k.data({
                                    on_drag: true
                                });
                                j.addClass("mCSB_dragger_onDrag");
                                F = H.pageX - K.left;
                                J = H.pageY - K.top
                            }
                            if(F < G.width() && F > 0 && J < G.height() && J > 0) {
                                n = J;
                                o = F
                            }
                        }).bind("touchmove", function(H) {
                            H.preventDefault();
                            H.stopImmediatePropagation();
                            var K = H.originalEvent.touches[0] || H.originalEvent.changedTouches[0],
                                G = c(this),
                                J = G.offset(),
                                F = K.pageX - J.left,
                                I = K.pageY - J.top;
                            D(n, o, I, F)
                        });
                        c(document).bind("mousemove." + k.data("mCustomScrollbarIndex"), function(H) {
                            if(k.data("on_drag")) {
                                var G = j,
                                    J = G.offset(),
                                    F = H.pageX - J.left,
                                    I = H.pageY - J.top;
                                D(n, o, I, F)
                            }
                        }).bind("mouseup." + k.data("mCustomScrollbarIndex"), function(x) {
                            k.data({
                                on_drag: false
                            });
                            j.removeClass("mCSB_dragger_onDrag")
                        })
                    }
                    k.data({
                        bindEvent_scrollbar_drag: true
                    })
                }
 
                function D(G, H, I, F) {
                    if(k.data("horizontalScroll")) {
                        k.mCustomScrollbar("scrollTo", (j.position().left - (H)) + F, {
                            moveDragger: true,
                            trigger: "internal"
                        })
                    } else {
                        k.mCustomScrollbar("scrollTo", (j.position().top - (G)) + I, {
                            moveDragger: true,
                            trigger: "internal"
                        })
                    }
                }
                if(c.support.touch && k.data("contentTouchScroll")) {
                    if(!k.data("bindEvent_content_touch")) {
                        var l, B, r, s, u, C, E;
                        p.bind("touchstart", function(x) {
                            x.stopImmediatePropagation();
                            l = x.originalEvent.touches[0] || x.originalEvent.changedTouches[0];
                            B = c(this);
                            r = B.offset();
                            u = l.pageX - r.left;
                            s = l.pageY - r.top;
                            C = s;
                            E = u
                        });
                        p.bind("touchmove", function(x) {
                            x.preventDefault();
                            x.stopImmediatePropagation();
                            l = x.originalEvent.touches[0] || x.originalEvent.changedTouches[0];
                            B = c(this).parent();
                            r = B.offset();
                            u = l.pageX - r.left;
                            s = l.pageY - r.top;
                            if(k.data("horizontalScroll")) {
                                k.mCustomScrollbar("scrollTo", E - u, {
                                    trigger: "internal"
                                })
                            } else {
                                k.mCustomScrollbar("scrollTo", C - s, {
                                    trigger: "internal"
                                })
                            }
                        })
                    }
                }
                if(!k.data("bindEvent_scrollbar_click")) {
                    m.bind("click", function(F) {
                        var x = (F.pageY - m.offset().top) * k.data("scrollAmount"),
                            y = c(F.target);
                        if(k.data("horizontalScroll")) {
                            x = (F.pageX - m.offset().left) * k.data("scrollAmount")
                        }
                        if(y.hasClass("mCSB_draggerContainer") || y.hasClass("mCSB_draggerRail")) {
                            k.mCustomScrollbar("scrollTo", x, {
                                trigger: "internal",
                                scrollEasing: "draggerRailEase"
                            })
                        }
                    });
                    k.data({
                        bindEvent_scrollbar_click: true
                    })
                }
                if(k.data("mouseWheel")) {
                    if(!k.data("bindEvent_mousewheel")) {
                        h.bind("mousewheel", function(H, J) {
                            var G, F = k.data("mouseWheelPixels"),
                                x = Math.abs(p.position().top),
                                I = j.position().top,
                                y = m.height() - j.height();
                            if(k.data("normalizeMouseWheelDelta")) {
                                if(J < 0) {
                                    J = -1
                                } else {
                                    J = 1
                                }
                            }
                            if(F === "auto") {
                                F = 100 + Math.round(k.data("scrollAmount") / 2)
                            }
                            if(k.data("horizontalScroll")) {
                                I = j.position().left;
                                y = m.width() - j.width();
                                x = Math.abs(p.position().left)
                            }
                            if((J > 0 && I !== 0) || (J < 0 && I !== y)) {
                                H.preventDefault();
                                H.stopImmediatePropagation()
                            }
                            G = x - (J * F);
                            k.mCustomScrollbar("scrollTo", G, {
                                trigger: "internal"
                            })
                        });
                        k.data({
                            bindEvent_mousewheel: true
                        })
                    }
                }
                if(k.data("scrollButtons_enable")) {
                    if(k.data("scrollButtons_scrollType") === "pixels") {
                        if(k.data("horizontalScroll")) {
                            v.add(A).unbind("mousedown touchstart MSPointerDown mouseup MSPointerUp mouseout MSPointerOut touchend", i, g);
                            k.data({
                                bindEvent_buttonsContinuous_x: false
                            });
                            if(!k.data("bindEvent_buttonsPixels_x")) {
                                v.bind("click", function(x) {
                                    x.preventDefault();
                                    q(Math.abs(p.position().left) + k.data("scrollButtons_scrollAmount"))
                                });
                                A.bind("click", function(x) {
                                    x.preventDefault();
                                    q(Math.abs(p.position().left) - k.data("scrollButtons_scrollAmount"))
                                });
                                k.data({
                                    bindEvent_buttonsPixels_x: true
                                })
                            }
                        } else {
                            e.add(w).unbind("mousedown touchstart MSPointerDown mouseup MSPointerUp mouseout MSPointerOut touchend", i, g);
                            k.data({
                                bindEvent_buttonsContinuous_y: false
                            });
                            if(!k.data("bindEvent_buttonsPixels_y")) {
                                e.bind("click", function(x) {
                                    x.preventDefault();
                                    q(Math.abs(p.position().top) + k.data("scrollButtons_scrollAmount"))
                                });
                                w.bind("click", function(x) {
                                    x.preventDefault();
                                    q(Math.abs(p.position().top) - k.data("scrollButtons_scrollAmount"))
                                });
                                k.data({
                                    bindEvent_buttonsPixels_y: true
                                })
                            }
                        }
 
                        function q(x) {
                            if(!j.data("preventAction")) {
                                j.data("preventAction", true);
                                k.mCustomScrollbar("scrollTo", x, {
                                    trigger: "internal"
                                })
                            }
                        }
                    } else {
                        if(k.data("horizontalScroll")) {
                            v.add(A).unbind("click");
                            k.data({
                                bindEvent_buttonsPixels_x: false
                            });
                            if(!k.data("bindEvent_buttonsContinuous_x")) {
                                v.bind("mousedown touchstart MSPointerDown", function(y) {
                                    y.preventDefault();
                                    var x = z();
                                    k.data({
                                        mCSB_buttonScrollRight: setInterval(function() {
                                            k.mCustomScrollbar("scrollTo", Math.abs(p.position().left) + x, {
                                                trigger: "internal",
                                                scrollEasing: "easeOutCirc"
                                            })
                                        }, 17)
                                    })
                                });
                                var i = function(x) {
                                    x.preventDefault();
                                    clearInterval(k.data("mCSB_buttonScrollRight"))
                                };
                                v.bind("mouseup touchend MSPointerUp mouseout MSPointerOut", i);
                                A.bind("mousedown touchstart MSPointerDown", function(y) {
                                    y.preventDefault();
                                    var x = z();
                                    k.data({
                                        mCSB_buttonScrollLeft: setInterval(function() {
                                            k.mCustomScrollbar("scrollTo", Math.abs(p.position().left) - x, {
                                                trigger: "internal",
                                                scrollEasing: "easeOutCirc"
                                            })
                                        }, 17)
                                    })
                                });
                                var g = function(x) {
                                    x.preventDefault();
                                    clearInterval(k.data("mCSB_buttonScrollLeft"))
                                };
                                A.bind("mouseup touchend MSPointerUp mouseout MSPointerOut", g);
                                k.data({
                                    bindEvent_buttonsContinuous_x: true
                                })
                            }
                        } else {
                            e.add(w).unbind("click");
                            k.data({
                                bindEvent_buttonsPixels_y: false
                            });
                            if(!k.data("bindEvent_buttonsContinuous_y")) {
                                e.bind("mousedown touchstart MSPointerDown", function(y) {
                                    y.preventDefault();
                                    var x = z();
                                    k.data({
                                        mCSB_buttonScrollDown: setInterval(function() {
                                            k.mCustomScrollbar("scrollTo", Math.abs(p.position().top) + x, {
                                                trigger: "internal",
                                                scrollEasing: "easeOutCirc"
                                            })
                                        }, 17)
                                    })
                                });
                                var t = function(x) {
                                    x.preventDefault();
                                    clearInterval(k.data("mCSB_buttonScrollDown"))
                                };
                                e.bind("mouseup touchend MSPointerUp mouseout MSPointerOut", t);
                                w.bind("mousedown touchstart MSPointerDown", function(y) {
                                    y.preventDefault();
                                    var x = z();
                                    k.data({
                                        mCSB_buttonScrollUp: setInterval(function() {
                                            k.mCustomScrollbar("scrollTo", Math.abs(p.position().top) - x, {
                                                trigger: "internal",
                                                scrollEasing: "easeOutCirc"
                                            })
                                        }, 17)
                                    })
                                });
                                var f = function(x) {
                                    x.preventDefault();
                                    clearInterval(k.data("mCSB_buttonScrollUp"))
                                };
                                w.bind("mouseup touchend MSPointerUp mouseout MSPointerOut", f);
                                k.data({
                                    bindEvent_buttonsContinuous_y: true
                                })
                            }
                        }
 
                        function z() {
                            var x = k.data("scrollButtons_scrollSpeed");
                            if(k.data("scrollButtons_scrollSpeed") === "auto") {
                                x = Math.round((k.data("scrollInertia") + 100) / 40)
                            }
                            return x
                        }
                    }
                }
                if(k.data("autoScrollOnFocus")) {
                    if(!k.data("bindEvent_focusin")) {
                        h.bind("focusin", function() {
                            h.scrollTop(0).scrollLeft(0);
                            var x = c(document.activeElement);
                            if(x.is("input,textarea,select,button,a[tabindex],area,object")) {
                                var G = p.position().top,
                                    y = x.position().top,
                                    F = h.height() - x.outerHeight();
                                if(k.data("horizontalScroll")) {
                                    G = p.position().left;
                                    y = x.position().left;
                                    F = h.width() - x.outerWidth()
                                }
                                if(G + y < 0 || G + y > F) {
                                    k.mCustomScrollbar("scrollTo", y, {
                                        trigger: "internal"
                                    })
                                }
                            }
                        });
                        k.data({
                            bindEvent_focusin: true
                        })
                    }
                }
                if(k.data("autoHideScrollbar")) {
                    if(!k.data("bindEvent_autoHideScrollbar")) {
                        h.bind("mouseenter", function(x) {
                            h.addClass("mCS-mouse-over");
                            d.showScrollbar.call(h.children(".mCSB_scrollTools"))
                        }).bind("mouseleave touchend", function(x) {
                            h.removeClass("mCS-mouse-over");
                            if(x.type === "mouseleave") {
                                d.hideScrollbar.call(h.children(".mCSB_scrollTools"))
                            }
                        });
                        k.data({
                            bindEvent_autoHideScrollbar: true
                        })
                    }
                }
            },
            scrollTo: function(e, f) {
                var i = c(this),
                    o = {
                        moveDragger: false,
                        trigger: "external",
                        callbacks: true,
                        scrollInertia: i.data("scrollInertia"),
                        scrollEasing: i.data("scrollEasing")
                    },
                    f = c.extend(o, f),
                    p, g = i.children(".mCustomScrollBox"),
                    k = g.children(".mCSB_container"),
                    r = g.children(".mCSB_scrollTools"),
                    j = r.children(".mCSB_draggerContainer"),
                    h = j.children(".mCSB_dragger"),
                    t = draggerSpeed = f.scrollInertia,
                    q, s, m, l;
                if(!k.hasClass("mCS_no_scrollbar")) {
                    i.data({
                        mCS_trigger: f.trigger
                    });
                    if(i.data("mCS_Init")) {
                        f.callbacks = false
                    }
                    if(e || e === 0) {
                        if(typeof(e) === "number") {
                            if(f.moveDragger) {
                                p = e;
                                if(i.data("horizontalScroll")) {
                                    e = h.position().left * i.data("scrollAmount")
                                } else {
                                    e = h.position().top * i.data("scrollAmount")
                                }
                                draggerSpeed = 0
                            } else {
                                p = e / i.data("scrollAmount")
                            }
                        } else {
                            if(typeof(e) === "string") {
                                var v;
                                if(e === "top") {
                                    v = 0
                                } else {
                                    if(e === "bottom" && !i.data("horizontalScroll")) {
                                        v = k.outerHeight() - g.height()
                                    } else {
                                        if(e === "left") {
                                            v = 0
                                        } else {
                                            if(e === "right" && i.data("horizontalScroll")) {
                                                v = k.outerWidth() - g.width()
                                            } else {
                                                if(e === "first") {
                                                    v = i.find(".mCSB_container").find(":first")
                                                } else {
                                                    if(e === "last") {
                                                        v = i.find(".mCSB_container").find(":last")
                                                    } else {
                                                        v = i.find(e)
                                                    }
                                                }
                                            }
                                        }
                                    }
                                }
                                if(v.length === 1) {
                                    if(i.data("horizontalScroll")) {
                                        e = v.position().left
                                    } else {
                                        e = v.position().top
                                    }
                                    p = e / i.data("scrollAmount")
                                } else {
                                    p = e = v
                                }
                            }
                        }
                        if(i.data("horizontalScroll")) {
                            if(i.data("onTotalScrollBack_Offset")) {
                                s = -i.data("onTotalScrollBack_Offset")
                            }
                            if(i.data("onTotalScroll_Offset")) {
                                l = g.width() - k.outerWidth() + i.data("onTotalScroll_Offset")
                            }
                            if(p < 0) {
                                p = e = 0;
                                clearInterval(i.data("mCSB_buttonScrollLeft"));
                                if(!s) {
                                    q = true
                                }
                            } else {
                                if(p >= j.width() - h.width()) {
                                    p = j.width() - h.width();
                                    e = g.width() - k.outerWidth();
                                    clearInterval(i.data("mCSB_buttonScrollRight"));
                                    if(!l) {
                                        m = true
                                    }
                                } else {
                                    e = -e
                                }
                            }
                            var n = i.data("snapAmount");
                            if(n) {
                                e = Math.round(e / n) * n - i.data("snapOffset")
                            }
                            d.mTweenAxis.call(this, h[0], "left", Math.round(p), draggerSpeed, f.scrollEasing);
                            d.mTweenAxis.call(this, k[0], "left", Math.round(e), t, f.scrollEasing, {
                                onStart: function() {
                                    if(f.callbacks && !i.data("mCS_tweenRunning")) {
                                        u("onScrollStart")
                                    }
                                    if(i.data("autoHideScrollbar")) {
                                        d.showScrollbar.call(r)
                                    }
                                },
                                onUpdate: function() {
                                    if(f.callbacks) {
                                        u("whileScrolling")
                                    }
                                },
                                onComplete: function() {
                                    if(f.callbacks) {
                                        u("onScroll");
                                        if(q || (s && k.position().left >= s)) {
                                            u("onTotalScrollBack")
                                        }
                                        if(m || (l && k.position().left <= l)) {
                                            u("onTotalScroll")
                                        }
                                    }
                                    h.data("preventAction", false);
                                    i.data("mCS_tweenRunning", false);
                                    if(i.data("autoHideScrollbar")) {
                                        if(!g.hasClass("mCS-mouse-over")) {
                                            d.hideScrollbar.call(r)
                                        }
                                    }
                                }
                            })
                        } else {
                            if(i.data("onTotalScrollBack_Offset")) {
                                s = -i.data("onTotalScrollBack_Offset")
                            }
                            if(i.data("onTotalScroll_Offset")) {
                                l = g.height() - k.outerHeight() + i.data("onTotalScroll_Offset")
                            }
                            if(p < 0) {
                                p = e = 0;
                                clearInterval(i.data("mCSB_buttonScrollUp"));
                                if(!s) {
                                    q = true
                                }
                            } else {
                                if(p >= j.height() - h.height()) {
                                    p = j.height() - h.height();
                                    e = g.height() - k.outerHeight();
                                    clearInterval(i.data("mCSB_buttonScrollDown"));
                                    if(!l) {
                                        m = true
                                    }
                                } else {
                                    e = -e
                                }
                            }
                            var n = i.data("snapAmount");
                            if(n) {
                                e = Math.round(e / n) * n - i.data("snapOffset")
                            }
                            d.mTweenAxis.call(this, h[0], "top", Math.round(p), draggerSpeed, f.scrollEasing);
                            d.mTweenAxis.call(this, k[0], "top", Math.round(e), t, f.scrollEasing, {
                                onStart: function() {
                                    if(f.callbacks && !i.data("mCS_tweenRunning")) {
                                        u("onScrollStart")
                                    }
                                    if(i.data("autoHideScrollbar")) {
                                        d.showScrollbar.call(r)
                                    }
                                },
                                onUpdate: function() {
                                    if(f.callbacks) {
                                        u("whileScrolling")
                                    }
                                },
                                onComplete: function() {
                                    if(f.callbacks) {
                                        u("onScroll");
                                        if(q || (s && k.position().top >= s)) {
                                            u("onTotalScrollBack")
                                        }
                                        if(m || (l && k.position().top <= l)) {
                                            u("onTotalScroll")
                                        }
                                    }
                                    h.data("preventAction", false);
                                    i.data("mCS_tweenRunning", false);
                                    if(i.data("autoHideScrollbar")) {
                                        if(!g.hasClass("mCS-mouse-over")) {
                                            d.hideScrollbar.call(r)
                                        }
                                    }
                                }
                            })
                        }
                        if(i.data("mCS_Init")) {
                            i.data({
                                mCS_Init: false
                            })
                        }
                    }
                }
 
                function u(w) {
                    this.mcs = {
                        top: k.position().top,
                        left: k.position().left,
                        draggerTop: h.position().top,
                        draggerLeft: h.position().left,
                        topPct: Math.round((100 * Math.abs(k.position().top)) / Math.abs(k.outerHeight() - g.height())),
                        leftPct: Math.round((100 * Math.abs(k.position().left)) / Math.abs(k.outerWidth() - g.width()))
                    };
                    switch(w) {
                        case "onScrollStart":
                            i.data("mCS_tweenRunning", true).data("onScrollStart_Callback").call(i, this.mcs);
                            break;
                        case "whileScrolling":
                            i.data("whileScrolling_Callback").call(i, this.mcs);
                            break;
                        case "onScroll":
                            i.data("onScroll_Callback").call(i, this.mcs);
                            break;
                        case "onTotalScrollBack":
                            i.data("onTotalScrollBack_Callback").call(i, this.mcs);
                            break;
                        case "onTotalScroll":
                            i.data("onTotalScroll_Callback").call(i, this.mcs);
                            break
                    }
                }
            },
            stop: function() {
                var g = c(this),
                    e = g.children().children(".mCSB_container"),
                    f = g.children().children().children().children(".mCSB_dragger");
                d.mTweenAxisStop.call(this, e[0]);
                d.mTweenAxisStop.call(this, f[0])
            },
            disable: function(e) {
                var j = c(this),
                    f = j.children(".mCustomScrollBox"),
                    h = f.children(".mCSB_container"),
                    g = f.children(".mCSB_scrollTools"),
                    i = g.children().children(".mCSB_dragger");
                f.unbind("mousewheel focusin mouseenter mouseleave touchend");
                h.unbind("touchstart touchmove");
                if(e) {
                    if(j.data("horizontalScroll")) {
                        i.add(h).css("left", 0)
                    } else {
                        i.add(h).css("top", 0)
                    }
                }
                g.css("display", "none");
                h.addClass("mCS_no_scrollbar");
                j.data({
                    bindEvent_mousewheel: false,
                    bindEvent_focusin: false,
                    bindEvent_content_touch: false,
                    bindEvent_autoHideScrollbar: false
                }).addClass("mCS_disabled")
            },
            destroy: function() {
                var e = c(this);
                e.removeClass("mCustomScrollbar _mCS_" + e.data("mCustomScrollbarIndex")).addClass("mCS_destroyed").children().children(".mCSB_container").unwrap().children().unwrap().siblings(".mCSB_scrollTools").remove();
                c(document).unbind("mousemove." + e.data("mCustomScrollbarIndex") + " mouseup." + e.data("mCustomScrollbarIndex") + " MSPointerMove." + e.data("mCustomScrollbarIndex") + " MSPointerUp." + e.data("mCustomScrollbarIndex"));
                c(window).unbind("resize." + e.data("mCustomScrollbarIndex"))
            }
        },
        d = {
            showScrollbar: function() {
                this.stop().animate({
                    opacity: 1
                }, "fast")
            },
            hideScrollbar: function() {
                this.stop().animate({
                    opacity: 0
                }, "fast")
            },
            mTweenAxis: function(g, i, h, f, o, y) {
                var y = y || {},
                    v = y.onStart || function() {},
                    p = y.onUpdate || function() {},
                    w = y.onComplete || function() {};
                var n = t(),
                    l, j = 0,
                    r = g.offsetTop,
                    s = g.style;
                if(i === "left") {
                    r = g.offsetLeft
                }
                var m = h - r;
                q();
                e();
 
                function t() {
                    if(window.performance && window.performance.now) {
                        return window.performance.now()
                    } else {
                        if(window.performance && window.performance.webkitNow) {
                            return window.performance.webkitNow()
                        } else {
                            if(Date.now) {
                                return Date.now()
                            } else {
                                return new Date().getTime()
                            }
                        }
                    }
                }
 
                function x() {
                    if(!j) {
                        v.call()
                    }
                    j = t() - n;
                    u();
                    if(j >= g._time) {
                        g._time = (j > g._time) ? j + l - (j - g._time) : j + l - 1;
                        if(g._time < j + 1) {
                            g._time = j + 1
                        }
                    }
                    if(g._time < f) {
                        g._id = _request(x)
                    } else {
                        w.call()
                    }
                }
 
                function u() {
                    if(f > 0) {
                        g.currVal = k(g._time, r, m, f, o);
                        s[i] = Math.round(g.currVal) + "px"
                    } else {
                        s[i] = h + "px"
                    }
                    p.call()
                }
 
                function e() {
                    l = 1000 / 60;
                    g._time = j + l;
                    _request = (!window.requestAnimationFrame) ? function(z) {
                        u();
                        return setTimeout(z, 0.01)
                    } : window.requestAnimationFrame;
                    g._id = _request(x)
                }
 
                function q() {
                    if(g._id == null) {
                        return
                    }
                    if(!window.requestAnimationFrame) {
                        clearTimeout(g._id)
                    } else {
                        window.cancelAnimationFrame(g._id)
                    }
                    g._id = null
                }
 
                function k(B, A, F, E, C) {
                    switch(C) {
                        case "linear":
                            return F * B / E + A;
                            break;
                        case "easeOutQuad":
                            B /= E;
                            return -F * B * (B - 2) + A;
                            break;
                        case "easeInOutQuad":
                            B /= E / 2;
                            if(B < 1) {
                                return F / 2 * B * B + A
                            }
                            B--;
                            return -F / 2 * (B * (B - 2) - 1) + A;
                            break;
                        case "easeOutCubic":
                            B /= E;
                            B--;
                            return F * (B * B * B + 1) + A;
                            break;
                        case "easeOutQuart":
                            B /= E;
                            B--;
                            return -F * (B * B * B * B - 1) + A;
                            break;
                        case "easeOutQuint":
                            B /= E;
                            B--;
                            return F * (B * B * B * B * B + 1) + A;
                            break;
                        case "easeOutCirc":
                            B /= E;
                            B--;
                            return F * Math.sqrt(1 - B * B) + A;
                            break;
                        case "easeOutSine":
                            return F * Math.sin(B / E * (Math.PI / 2)) + A;
                            break;
                        case "easeOutExpo":
                            return F * (-Math.pow(2, -10 * B / E) + 1) + A;
                            break;
                        case "mcsEaseOut":
                            var D = (B /= E) * B,
                                z = D * B;
                            return A + F * (0.499999999999997 * z * D + -2.5 * D * D + 5.5 * z + -6.5 * D + 4 * B);
                            break;
                        case "draggerRailEase":
                            B /= E / 2;
                            if(B < 1) {
                                return F / 2 * B * B * B + A
                            }
                            B -= 2;
                            return F / 2 * (B * B * B + 2) + A;
                            break
                    }
                }
            },
            mTweenAxisStop: function(e) {
                if(e._id == null) {
                    return
                }
                if(!window.requestAnimationFrame) {
                    clearTimeout(e._id)
                } else {
                    window.cancelAnimationFrame(e._id)
                }
                e._id = null
            },
            rafPolyfill: function() {
                var f = ["ms", "moz", "webkit", "o"],
                    e = f.length;
                while(--e > -1 && !window.requestAnimationFrame) {
                    window.requestAnimationFrame = window[f[e] + "RequestAnimationFrame"];
                    window.cancelAnimationFrame = window[f[e] + "CancelAnimationFrame"] || window[f[e] + "CancelRequestAnimationFrame"]
                }
            }
        };
    d.rafPolyfill.call();
    c.support.touch = !!("ontouchstart" in window);
    c.support.msPointer = window.navigator.msPointerEnabled;
    var a = ("https:" == document.location.protocol) ? "https:" : "http:";
    c.event.special.mousewheel || document.write('<script src="' + a + '//cdnjs.cloudflare.com/ajax/libs/jquery-mousewheel/3.0.6/jquery.mousewheel.min.js"><\/script>');
    c.fn.mCustomScrollbar = function(e) {
        if(b[e]) {
            return b[e].apply(this, Array.prototype.slice.call(arguments, 1))
        } else {
            if(typeof e === "object" || !e) {
                return b.init.apply(this, arguments)
            } else {
                c.error("Method " + e + " does not exist")
            }
        }
    }
})(jQuery);