Forráskód Böngészése

Append pagination to the parent element of the track.

NaotoshiFujita 3 éve
szülő
commit
d786c39336

A különbségek nem kerülnek megjelenítésre, a fájl túl nagy
+ 0 - 0
dist/css/splide.min.css


A különbségek nem kerülnek megjelenítésre, a fájl túl nagy
+ 0 - 0
dist/css/themes/splide-default.min.css


A különbségek nem kerülnek megjelenítésre, a fájl túl nagy
+ 0 - 0
dist/css/themes/splide-sea-green.min.css


A különbségek nem kerülnek megjelenítésre, a fájl túl nagy
+ 0 - 0
dist/css/themes/splide-skyblue.min.css


+ 1 - 1
dist/js/splide.cjs.js

@@ -2514,7 +2514,7 @@ function Pagination(Splide2, Components2, options) {
         i18n = options.i18n,
         perPage = options.perPage;
     var max = hasFocus() ? length : ceil(length / perPage);
-    list = Elements.pagination || create("ul", classes.pagination, Elements.root);
+    list = Elements.pagination || create("ul", classes.pagination, Elements.track.parentElement);
     addClass(list, paginationClasses = CLASS_PAGINATION + "--" + getDirection());
     setAttribute(list, ROLE, "tablist");
     setAttribute(list, ARIA_LABEL, i18n.select);

+ 1 - 1
dist/js/splide.esm.js

@@ -2509,7 +2509,7 @@ function Pagination(Splide2, Components2, options) {
         i18n = options.i18n,
         perPage = options.perPage;
     var max = hasFocus() ? length : ceil(length / perPage);
-    list = Elements.pagination || create("ul", classes.pagination, Elements.root);
+    list = Elements.pagination || create("ul", classes.pagination, Elements.track.parentElement);
     addClass(list, paginationClasses = CLASS_PAGINATION + "--" + getDirection());
     setAttribute(list, ROLE, "tablist");
     setAttribute(list, ARIA_LABEL, i18n.select);

+ 1 - 1
dist/js/splide.js

@@ -2508,7 +2508,7 @@ function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _d
           i18n = options.i18n,
           perPage = options.perPage;
       var max = hasFocus() ? length : ceil(length / perPage);
-      list = Elements.pagination || create("ul", classes.pagination, Elements.root);
+      list = Elements.pagination || create("ul", classes.pagination, Elements.track.parentElement);
       addClass(list, paginationClasses = CLASS_PAGINATION + "--" + getDirection());
       setAttribute(list, ROLE, "tablist");
       setAttribute(list, ARIA_LABEL, i18n.select);

A különbségek nem kerülnek megjelenítésre, a fájl túl nagy
+ 0 - 0
dist/js/splide.min.js


BIN
dist/js/splide.min.js.gz


A különbségek nem kerülnek megjelenítésre, a fájl túl nagy
+ 0 - 0
dist/js/splide.min.js.map


+ 1 - 1
src/js/components/Pagination/Pagination.ts

@@ -142,7 +142,7 @@ export function Pagination( Splide: Splide, Components: Components, options: Opt
     const { classes, i18n, perPage } = options;
     const max = hasFocus() ? length : ceil( length / perPage );
 
-    list = Elements.pagination || create( 'ul', classes.pagination, Elements.root );
+    list = Elements.pagination || create( 'ul', classes.pagination, Elements.track.parentElement );
 
     addClass( list, ( paginationClasses = `${ CLASS_PAGINATION }--${ getDirection() }` ) );
     setAttribute( list, ROLE, 'tablist' );

+ 1 - 1
src/js/utils/dom/before/before.ts

@@ -7,7 +7,7 @@ import { forEach } from '../../array';
  * @param nodes - A node or nodes to insert.
  * @param ref   - A reference node.
  */
-export function before( nodes: Node | Node[], ref: Node ): void {
+export function before( nodes: Node | Node[], ref: Node | null ): void {
   forEach( nodes, node => {
     const parent = ( ref || node ).parentNode;
 

Nem az összes módosított fájl került megjelenítésre, mert túl sok fájl változott