vue-laravel-crud 1.6.0 → 1.6.1
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.
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
import 'vue';
|
|
2
|
+
|
|
1
3
|
var commonjsGlobal = typeof globalThis !== 'undefined' ? globalThis : typeof window !== 'undefined' ? window : typeof global !== 'undefined' ? global : typeof self !== 'undefined' ? self : {};
|
|
2
4
|
|
|
3
5
|
function getDefaultExportFromCjs (x) {
|
|
@@ -11875,9 +11877,247 @@ vueInfiniteLoading.exports;
|
|
|
11875
11877
|
var vueInfiniteLoadingExports = vueInfiniteLoading.exports;
|
|
11876
11878
|
var InfiniteLoading = /*@__PURE__*/getDefaultExportFromCjs(vueInfiniteLoadingExports);
|
|
11877
11879
|
|
|
11880
|
+
/*!
|
|
11881
|
+
* vue-masonry-css v1.0.3
|
|
11882
|
+
* https://github.com/paulcollett/vue-masonry-css
|
|
11883
|
+
* Released under the MIT License.
|
|
11884
|
+
*/
|
|
11885
|
+
|
|
11886
|
+
// the component name `<masonry />`
|
|
11887
|
+
// can be overridden with `Vue.use(Masonry, { name: 'the-masonry' });`
|
|
11888
|
+
var componentName = 'masonry';
|
|
11889
|
+
|
|
11890
|
+
var props = {
|
|
11891
|
+
tag: {
|
|
11892
|
+
type: [String],
|
|
11893
|
+
default: 'div'
|
|
11894
|
+
},
|
|
11895
|
+
cols: {
|
|
11896
|
+
type: [Object, Number, String],
|
|
11897
|
+
default: 2
|
|
11898
|
+
},
|
|
11899
|
+
gutter: {
|
|
11900
|
+
type: [Object, Number, String],
|
|
11901
|
+
default: 0
|
|
11902
|
+
},
|
|
11903
|
+
css: {
|
|
11904
|
+
type: [Boolean],
|
|
11905
|
+
default: true
|
|
11906
|
+
},
|
|
11907
|
+
columnTag: {
|
|
11908
|
+
type: [String],
|
|
11909
|
+
default: 'div'
|
|
11910
|
+
},
|
|
11911
|
+
columnClass: {
|
|
11912
|
+
type: [String, Array, Object],
|
|
11913
|
+
default: function () { return []; }
|
|
11914
|
+
},
|
|
11915
|
+
columnAttr: {
|
|
11916
|
+
type: [Object],
|
|
11917
|
+
default: function () { return ({}); }
|
|
11918
|
+
}
|
|
11919
|
+
};
|
|
11920
|
+
|
|
11921
|
+
// Get the resulting value from `:col=` prop
|
|
11922
|
+
// based on the window width
|
|
11923
|
+
var breakpointValue = function (mixed, windowWidth) {
|
|
11924
|
+
var valueAsNum = parseInt(mixed);
|
|
11925
|
+
|
|
11926
|
+
if(valueAsNum > -1) {
|
|
11927
|
+
return mixed;
|
|
11928
|
+
}else if(typeof mixed !== 'object') {
|
|
11929
|
+
return 0;
|
|
11930
|
+
}
|
|
11931
|
+
|
|
11932
|
+
var matchedBreakpoint = Infinity;
|
|
11933
|
+
var matchedValue = mixed.default || 0;
|
|
11934
|
+
|
|
11935
|
+
for(var k in mixed) {
|
|
11936
|
+
var breakpoint = parseInt(k);
|
|
11937
|
+
var breakpointValRaw = mixed[breakpoint];
|
|
11938
|
+
var breakpointVal = parseInt(breakpointValRaw);
|
|
11939
|
+
|
|
11940
|
+
if(isNaN(breakpoint) || isNaN(breakpointVal)) {
|
|
11941
|
+
continue;
|
|
11942
|
+
}
|
|
11943
|
+
|
|
11944
|
+
var isNewBreakpoint = windowWidth <= breakpoint && breakpoint < matchedBreakpoint;
|
|
11945
|
+
|
|
11946
|
+
if(isNewBreakpoint) {
|
|
11947
|
+
matchedBreakpoint = breakpoint;
|
|
11948
|
+
matchedValue = breakpointValRaw;
|
|
11949
|
+
}
|
|
11950
|
+
}
|
|
11951
|
+
|
|
11952
|
+
return matchedValue;
|
|
11953
|
+
};
|
|
11954
|
+
|
|
11955
|
+
var component$1 = {
|
|
11956
|
+
props: props,
|
|
11957
|
+
|
|
11958
|
+
data: function data() {
|
|
11959
|
+
return {
|
|
11960
|
+
displayColumns: 2,
|
|
11961
|
+
displayGutter: 0
|
|
11962
|
+
}
|
|
11963
|
+
},
|
|
11964
|
+
|
|
11965
|
+
mounted: function mounted() {
|
|
11966
|
+
var this$1$1 = this;
|
|
11967
|
+
|
|
11968
|
+
this.$nextTick(function () {
|
|
11969
|
+
this$1$1.reCalculate();
|
|
11970
|
+
});
|
|
11971
|
+
|
|
11972
|
+
// Bind resize handler to page
|
|
11973
|
+
if(window) {
|
|
11974
|
+
window.addEventListener('resize', this.reCalculate);
|
|
11975
|
+
}
|
|
11976
|
+
},
|
|
11977
|
+
|
|
11978
|
+
updated: function updated() {
|
|
11979
|
+
var this$1$1 = this;
|
|
11980
|
+
|
|
11981
|
+
this.$nextTick(function () {
|
|
11982
|
+
this$1$1.reCalculate();
|
|
11983
|
+
});
|
|
11984
|
+
},
|
|
11985
|
+
|
|
11986
|
+
beforeDestroy: function beforeDestroy() {
|
|
11987
|
+
if(window) {
|
|
11988
|
+
window.removeEventListener('resize', this.reCalculate);
|
|
11989
|
+
}
|
|
11990
|
+
},
|
|
11991
|
+
|
|
11992
|
+
methods: {
|
|
11993
|
+
// Recalculate how many columns to display based on window width
|
|
11994
|
+
// and the value of the passed `:cols=` prop
|
|
11995
|
+
reCalculate: function reCalculate() {
|
|
11996
|
+
var previousWindowWidth = this.windowWidth;
|
|
11997
|
+
|
|
11998
|
+
this.windowWidth = (window ? window.innerWidth : null) || Infinity;
|
|
11999
|
+
|
|
12000
|
+
// Window resize events get triggered on page height
|
|
12001
|
+
// change which when loading the page can result in multiple
|
|
12002
|
+
// needless calculations. We prevent this here.
|
|
12003
|
+
if(previousWindowWidth === this.windowWidth) {
|
|
12004
|
+
return;
|
|
12005
|
+
}
|
|
12006
|
+
|
|
12007
|
+
this._reCalculateColumnCount(this.windowWidth);
|
|
12008
|
+
|
|
12009
|
+
this._reCalculateGutterSize(this.windowWidth);
|
|
12010
|
+
},
|
|
12011
|
+
|
|
12012
|
+
_reCalculateGutterSize: function _reCalculateGutterSize(windowWidth) {
|
|
12013
|
+
this.displayGutter = breakpointValue(this.gutter, windowWidth);
|
|
12014
|
+
},
|
|
12015
|
+
|
|
12016
|
+
_reCalculateColumnCount: function _reCalculateColumnCount(windowWidth) {
|
|
12017
|
+
var newColumns = breakpointValue(this.cols, windowWidth);
|
|
12018
|
+
|
|
12019
|
+
// Make sure we can return a valid value
|
|
12020
|
+
newColumns = Math.max(1, Number(newColumns) || 0);
|
|
12021
|
+
|
|
12022
|
+
this.displayColumns = newColumns;
|
|
12023
|
+
},
|
|
12024
|
+
|
|
12025
|
+
_getChildItemsInColumnsArray: function _getChildItemsInColumnsArray() {
|
|
12026
|
+
var this$1$1 = this;
|
|
12027
|
+
|
|
12028
|
+
var columns = [];
|
|
12029
|
+
var childItems = this.$slots.default || [];
|
|
12030
|
+
|
|
12031
|
+
// This component does not work with a child <transition-group /> ..yet,
|
|
12032
|
+
// so for now we think it may be helpful to ignore until we can find a way for support
|
|
12033
|
+
if(childItems.length === 1 && childItems[0].componentOptions && childItems[0].componentOptions.tag == 'transition-group') {
|
|
12034
|
+
childItems = childItems[0].componentOptions.children;
|
|
12035
|
+
}
|
|
12036
|
+
|
|
12037
|
+
// Loop through child elements
|
|
12038
|
+
for (var i = 0, visibleItemI = 0; i < childItems.length; i++, visibleItemI++) {
|
|
12039
|
+
// skip Vue elements without tags, which includes
|
|
12040
|
+
// whitespace elements and also plain text
|
|
12041
|
+
if(!childItems[i].tag) {
|
|
12042
|
+
visibleItemI--;
|
|
12043
|
+
|
|
12044
|
+
continue;
|
|
12045
|
+
}
|
|
12046
|
+
|
|
12047
|
+
// Get the column index the child item will end up in
|
|
12048
|
+
var columnIndex = visibleItemI % this$1$1.displayColumns;
|
|
12049
|
+
|
|
12050
|
+
if(!columns[columnIndex]) {
|
|
12051
|
+
columns[columnIndex] = [];
|
|
12052
|
+
}
|
|
12053
|
+
|
|
12054
|
+
columns[columnIndex].push(childItems[i]);
|
|
12055
|
+
}
|
|
12056
|
+
|
|
12057
|
+
return columns;
|
|
12058
|
+
}
|
|
12059
|
+
},
|
|
12060
|
+
|
|
12061
|
+
render: function render(createElement) {
|
|
12062
|
+
var this$1$1 = this;
|
|
12063
|
+
|
|
12064
|
+
var columnsContainingChildren = this._getChildItemsInColumnsArray();
|
|
12065
|
+
var isGutterSizeUnitless = parseInt(this.displayGutter) === this.displayGutter * 1;
|
|
12066
|
+
var gutterSizeWithUnit = isGutterSizeUnitless ? ((this.displayGutter) + "px") : this.displayGutter;
|
|
12067
|
+
|
|
12068
|
+
var columnStyle = {
|
|
12069
|
+
boxSizing: 'border-box',
|
|
12070
|
+
backgroundClip: 'padding-box',
|
|
12071
|
+
width: ((100 / this.displayColumns) + "%"),
|
|
12072
|
+
border: '0 solid transparent',
|
|
12073
|
+
borderLeftWidth: gutterSizeWithUnit
|
|
12074
|
+
};
|
|
12075
|
+
|
|
12076
|
+
var columns = columnsContainingChildren.map(function (children, index) {
|
|
12077
|
+
/// Create column element and inject the children
|
|
12078
|
+
return createElement(this$1$1.columnTag, {
|
|
12079
|
+
key: index + '-' + columnsContainingChildren.length,
|
|
12080
|
+
style: this$1$1.css ? columnStyle : null,
|
|
12081
|
+
class: this$1$1.columnClass,
|
|
12082
|
+
attrs: this$1$1.columnAttr
|
|
12083
|
+
}, children); // specify child items here
|
|
12084
|
+
});
|
|
12085
|
+
|
|
12086
|
+
var containerStyle = {
|
|
12087
|
+
display: ['-webkit-box', '-ms-flexbox', 'flex'],
|
|
12088
|
+
marginLeft: ("-" + gutterSizeWithUnit)
|
|
12089
|
+
};
|
|
12090
|
+
|
|
12091
|
+
// Return wrapper with columns
|
|
12092
|
+
return createElement(
|
|
12093
|
+
this.tag, // tag name
|
|
12094
|
+
this.css ? { style: containerStyle } : null, // element options
|
|
12095
|
+
columns // column vue elements
|
|
12096
|
+
);
|
|
12097
|
+
}
|
|
12098
|
+
};
|
|
12099
|
+
|
|
12100
|
+
var Plugin = function () {};
|
|
12101
|
+
|
|
12102
|
+
Plugin.install = function (Vue, options) {
|
|
12103
|
+
if (Plugin.installed) {
|
|
12104
|
+
return;
|
|
12105
|
+
}
|
|
12106
|
+
|
|
12107
|
+
if(options && options.name) {
|
|
12108
|
+
Vue.component(options.name, component$1);
|
|
12109
|
+
} else {
|
|
12110
|
+
Vue.component(componentName, component$1);
|
|
12111
|
+
}
|
|
12112
|
+
};
|
|
12113
|
+
|
|
12114
|
+
if (typeof window !== 'undefined' && window.Vue) {
|
|
12115
|
+
window.Vue.use(Plugin);
|
|
12116
|
+
}
|
|
12117
|
+
|
|
11878
12118
|
var e=[],t=[];function n(n,r){if(n&&"undefined"!=typeof document){var a,s=!0===r.prepend?"prepend":"append",d=!0===r.singleTag,i="string"==typeof r.container?document.querySelector(r.container):document.getElementsByTagName("head")[0];if(d){var u=e.indexOf(i);-1===u&&(u=e.push(i)-1,t[u]={}),a=t[u]&&t[u][s]?t[u][s]:t[u][s]=c();}else a=c();65279===n.charCodeAt(0)&&(n=n.substring(1)),a.styleSheet?a.styleSheet.cssText+=n:a.appendChild(document.createTextNode(n));}function c(){var e=document.createElement("style");if(e.setAttribute("type","text/css"),r.attributes)for(var t=Object.keys(r.attributes),n=0;n<t.length;n++)e.setAttribute(t[n],r.attributes[t[n]]);var a="prepend"===s?"afterbegin":"beforeend";return i.insertAdjacentElement(a,e),e}}
|
|
11879
12119
|
|
|
11880
|
-
var css = "tr td[data-v-
|
|
12120
|
+
var css = "tr td[data-v-45e6bdb2]:last-child,\ntr td[data-v-45e6bdb2]:first-child {\n width: 1%;\n white-space: nowrap; }\n\n.crud-pagination[data-v-45e6bdb2] {\n display: flex;\n align-items: center;\n width: 100%;\n justify-content: center;\n margin-top: 1rem; }\n\n.crud-header[data-v-45e6bdb2] {\n display: flex;\n justify-content: space-between;\n max-height: 3rem; }\n .crud-header[data-v-45e6bdb2] .crud-title[data-v-45e6bdb2] {\n margin: 0; }\n .crud-header[data-v-45e6bdb2] .crud-search[data-v-45e6bdb2] {\n max-width: 15rem; }\n .crud-header[data-v-45e6bdb2] .crud-search[data-v-45e6bdb2] .btn[data-v-45e6bdb2] {\n border-top-left-radius: 0;\n border-bottom-left-radius: 0;\n border-top-right-radius: 0.375rem;\n border-bottom-right-radius: 0.375rem; }\n .crud-header[data-v-45e6bdb2] .crud-search[data-v-45e6bdb2] .btn[data-v-45e6bdb2].open[data-v-45e6bdb2] {\n border-top-right-radius: 0;\n border-bottom-right-radius: 0; }\n .crud-header[data-v-45e6bdb2] .table-options[data-v-45e6bdb2] {\n margin-bottom: 1rem;\n display: flex;\n align-items: center;\n justify-content: flex-end; }\n\n.custom-control[data-v-45e6bdb2] {\n position: relative;\n top: -15px; }\n\n@media (min-width: 992px) {\n .table[data-v-45e6bdb2] {\n table-layout: auto; }\n .table[data-v-45e6bdb2] tbody[data-v-45e6bdb2] td[data-v-45e6bdb2] {\n overflow: scroll;\n -ms-overflow-style: none;\n /* IE and Edge */\n scrollbar-width: none;\n /* Firefox */ }\n .table[data-v-45e6bdb2] tbody[data-v-45e6bdb2] td[data-v-45e6bdb2]::-webkit-scrollbar {\n display: none; } }\n";
|
|
11881
12121
|
n(css, {});
|
|
11882
12122
|
|
|
11883
12123
|
function normalizeComponent (
|
|
@@ -11977,7 +12217,8 @@ const _sfc_main = {
|
|
|
11977
12217
|
name: "VueLaravelCrud",
|
|
11978
12218
|
components: {
|
|
11979
12219
|
draggable,
|
|
11980
|
-
InfiniteLoading
|
|
12220
|
+
InfiniteLoading,
|
|
12221
|
+
VueMasonry: Plugin
|
|
11981
12222
|
},
|
|
11982
12223
|
data() {
|
|
11983
12224
|
return {
|
|
@@ -14020,7 +14261,7 @@ var _sfc_render = function render() {
|
|
|
14020
14261
|
}) : _vm._e()], 2)], 1);
|
|
14021
14262
|
};
|
|
14022
14263
|
var _sfc_staticRenderFns = [];
|
|
14023
|
-
var __component__ = /*#__PURE__*/normalizeComponent(_sfc_main, _sfc_render, _sfc_staticRenderFns, false, null, "
|
|
14264
|
+
var __component__ = /*#__PURE__*/normalizeComponent(_sfc_main, _sfc_render, _sfc_staticRenderFns, false, null, "45e6bdb2", null, null);
|
|
14024
14265
|
var component = __component__.exports;
|
|
14025
14266
|
|
|
14026
14267
|
// Import vue component
|