From ff367fa79cc70a05aed4cbdbc8a961e6c0a33e4a Mon Sep 17 00:00:00 2001 From: Allan Jardine Date: Tue, 15 Nov 2022 11:21:39 +0000 Subject: [PATCH] d145c8bc5c29bf3931bdbd7deca9d875d085d865 Sync to source repo @d145c8bc5c29bf3931bdb7deca9d875d085d865 --- datatables.json | 2 +- js/buttons.bootstrap5.js | 3 +-- js/buttons.bootstrap5.min.js | 2 +- js/buttons.bootstrap5.min.mjs | 2 +- js/buttons.bootstrap5.mjs | 2 +- 5 files changed, 5 insertions(+), 6 deletions(-) diff --git a/datatables.json b/datatables.json index eb5d600..1633f42 100644 --- a/datatables.json +++ b/datatables.json @@ -15,5 +15,5 @@ ], "src-repo": "http://github.com/DataTables/Buttons", "last-tag": "2.3.2", - "last-sync": "d145c8bc5c29bf3931bdbd7deca9d875d085d865" + "last-sync": "d145c8bc5c29bf3931bdb7deca9d875d085d865" } \ No newline at end of file diff --git a/js/buttons.bootstrap5.js b/js/buttons.bootstrap5.js index 88059ca..073f1ce 100644 --- a/js/buttons.bootstrap5.js +++ b/js/buttons.bootstrap5.js @@ -28,11 +28,10 @@ require('datatables.net-bs5')(root, $); } - if ( ! $.fn.dataTable ) { + if ( ! $.fn.dataTable.Buttons ) { require('datatables.net-buttons')(root, $); } - return factory( $, root, root.document ); }; } diff --git a/js/buttons.bootstrap5.min.js b/js/buttons.bootstrap5.min.js index f50ec11..8c486af 100644 --- a/js/buttons.bootstrap5.min.js +++ b/js/buttons.bootstrap5.min.js @@ -1,4 +1,4 @@ /*! Bootstrap integration for DataTables' Buttons * ©2016 SpryMedia Ltd - datatables.net/license */ -!function(n){"function"==typeof define&&define.amd?define(["jquery","datatables.net-bs5","datatables.net-buttons"],function(t){return n(t,window,document)}):"object"==typeof exports?module.exports=function(t,e){return t=t||window,(e=e||("undefined"!=typeof window?require("jquery"):require("jquery")(t))).fn.dataTable||require("datatables.net-bs5")(t,e),e.fn.dataTable||require("datatables.net-buttons")(t,e),n(e,0,t.document)}:n(jQuery,window,document)}(function(n,t,e,o){"use strict";var a=n.fn.dataTable;return n.extend(!0,a.Buttons.defaults,{dom:{container:{className:"dt-buttons btn-group flex-wrap"},button:{className:"btn btn-secondary"},collection:{tag:"div",className:"dropdown-menu",closeButton:!1,button:{tag:"a",className:"dt-button dropdown-item",active:"active",disabled:"disabled"}},splitWrapper:{tag:"div",className:"dt-btn-split-wrapper btn-group",closeButton:!1},splitDropdown:{tag:"button",text:"",className:"btn btn-secondary dt-btn-split-drop dropdown-toggle dropdown-toggle-split",closeButton:!1,align:"split-left",splitAlignClass:"dt-button-split-left"},splitDropdownButton:{tag:"button",className:"dt-btn-split-drop-button btn btn-secondary",closeButton:!1}},buttonCreated:function(t,e){return t.buttons?n('
').append(e):e}}),a.ext.buttons.collection.className+=" dropdown-toggle",a.ext.buttons.collection.rightAlignClassName="dropdown-menu-right",a}); \ No newline at end of file +!function(e){"function"==typeof define&&define.amd?define(["jquery","datatables.net-bs5","datatables.net-buttons"],function(t){return e(t,window,document)}):"object"==typeof exports?module.exports=function(t,n){return t=t||window,(n=n||("undefined"!=typeof window?require("jquery"):require("jquery")(t))).fn.dataTable||require("datatables.net-bs5")(t,n),n.fn.dataTable.Buttons||require("datatables.net-buttons")(t,n),e(n,0,t.document)}:e(jQuery,window,document)}(function(e,t,n,o){"use strict";var a=e.fn.dataTable;return e.extend(!0,a.Buttons.defaults,{dom:{container:{className:"dt-buttons btn-group flex-wrap"},button:{className:"btn btn-secondary"},collection:{tag:"div",className:"dropdown-menu",closeButton:!1,button:{tag:"a",className:"dt-button dropdown-item",active:"active",disabled:"disabled"}},splitWrapper:{tag:"div",className:"dt-btn-split-wrapper btn-group",closeButton:!1},splitDropdown:{tag:"button",text:"",className:"btn btn-secondary dt-btn-split-drop dropdown-toggle dropdown-toggle-split",closeButton:!1,align:"split-left",splitAlignClass:"dt-button-split-left"},splitDropdownButton:{tag:"button",className:"dt-btn-split-drop-button btn btn-secondary",closeButton:!1}},buttonCreated:function(t,n){return t.buttons?e('
').append(n):n}}),a.ext.buttons.collection.className+=" dropdown-toggle",a.ext.buttons.collection.rightAlignClassName="dropdown-menu-right",a}); \ No newline at end of file diff --git a/js/buttons.bootstrap5.min.mjs b/js/buttons.bootstrap5.min.mjs index 81cec4c..b80ba33 100644 --- a/js/buttons.bootstrap5.min.mjs +++ b/js/buttons.bootstrap5.min.mjs @@ -1,4 +1,4 @@ /*! Bootstrap integration for DataTables' Buttons * ©2016 SpryMedia Ltd - datatables.net/license */ -import $ from"jquery";import DataTable from"datatables.net-bs5";import"datatables.net-buttons";$.extend(!0,DataTable.Buttons.defaults,{dom:{container:{className:"dt-buttons btn-group flex-wrap"},button:{className:"btn btn-secondary"},collection:{tag:"div",className:"dropdown-menu",closeButton:!1,button:{tag:"a",className:"dt-button dropdown-item",active:"active",disabled:"disabled"}},splitWrapper:{tag:"div",className:"dt-btn-split-wrapper btn-group",closeButton:!1},splitDropdown:{tag:"button",text:"",className:"btn btn-secondary dt-btn-split-drop dropdown-toggle dropdown-toggle-split",closeButton:!1,align:"split-left",splitAlignClass:"dt-button-split-left"},splitDropdownButton:{tag:"button",className:"dt-btn-split-drop-button btn btn-secondary",closeButton:!1}},buttonCreated:function(t,o){return t.buttons?$('
').append(o):o}}),DataTable.ext.buttons.collection.className+=" dropdown-toggle",DataTable.ext.buttons.collection.rightAlignClassName="dropdown-menu-right";export default DataTable; \ No newline at end of file +import $ from"jquery";import DataTable from"datatables.net-bs5";import Buttons from"datatables.net-buttons";$.extend(!0,DataTable.Buttons.defaults,{dom:{container:{className:"dt-buttons btn-group flex-wrap"},button:{className:"btn btn-secondary"},collection:{tag:"div",className:"dropdown-menu",closeButton:!1,button:{tag:"a",className:"dt-button dropdown-item",active:"active",disabled:"disabled"}},splitWrapper:{tag:"div",className:"dt-btn-split-wrapper btn-group",closeButton:!1},splitDropdown:{tag:"button",text:"",className:"btn btn-secondary dt-btn-split-drop dropdown-toggle dropdown-toggle-split",closeButton:!1,align:"split-left",splitAlignClass:"dt-button-split-left"},splitDropdownButton:{tag:"button",className:"dt-btn-split-drop-button btn btn-secondary",closeButton:!1}},buttonCreated:function(t,o){return t.buttons?$('
').append(o):o}}),DataTable.ext.buttons.collection.className+=" dropdown-toggle",DataTable.ext.buttons.collection.rightAlignClassName="dropdown-menu-right";export default DataTable; \ No newline at end of file diff --git a/js/buttons.bootstrap5.mjs b/js/buttons.bootstrap5.mjs index 30fbb5e..4b70173 100644 --- a/js/buttons.bootstrap5.mjs +++ b/js/buttons.bootstrap5.mjs @@ -4,7 +4,7 @@ import $ from 'jquery'; import DataTable from 'datatables.net-bs5'; -import 'datatables.net-buttons'; +import Buttons from 'datatables.net-buttons';