parcelRequire=function(e,r,t,n){var i,o="function"==typeof parcelRequire&&parcelRequire,u="function"==typeof require&&require;function f(t,n){if(!r[t]){if(!e[t]){var i="function"==typeof parcelRequire&&parcelRequire;if(!n&&i)return i(t,!0);if(o)return o(t,!0);if(u&&"string"==typeof t)return u(t);var c=new Error("Cannot find module '"+t+"'");throw c.code="MODULE_NOT_FOUND",c}p.resolve=function(r){return e[t][1][r]||r},p.cache={};var l=r[t]=new f.Module(t);e[t][0].call(l.exports,p,l,l.exports,this)}return r[t].exports;function p(e){return f(p.resolve(e))}}f.isParcelRequire=!0,f.Module=function(e){this.id=e,this.bundle=f,this.exports={}},f.modules=e,f.cache=r,f.parent=o,f.register=function(r,t){e[r]=[function(e,r){r.exports=t},{}]};for(var c=0;c<t.length;c++)try{f(t[c])}catch(e){i||(i=e)}if(t.length){var l=f(t[t.length-1]);"object"==typeof exports&&"undefined"!=typeof module?module.exports=l:"function"==typeof define&&define.amd?define(function(){return l}):n&&(this[n]=l)}if(parcelRequire=f,i)throw i;return f}({"vpUX":[function(require,module,exports) {
module.exports={props:{primaryKeyField:{type:String,required:!0},fields:{type:Object,required:!0},items:{type:Array,default:function(){return[]}},viewOptions:{type:Object,default:function(){return{}}},viewQuery:{type:Object,default:function(){return{}}},loading:{type:Boolean,default:!1},lazyLoading:{type:Boolean,default:!1},selection:{type:Array,default:function(){return[]}},link:{type:String,default:null},sortField:{type:String,default:null}}};
},{}],"K8Nu":[function(require,module,exports) {
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.default=void 0;var e=i(require("../../../mixins/layout"));function i(e){return e&&e.__esModule?e:{default:e}}var t={mixins:[e.default],computed:{columns:function(){var e=this,i=Object.values(this.fields);return(this.viewQuery.fields?Array.isArray(this.viewQuery.fields)?this.viewQuery.fields:this.viewQuery.fields.split(","):i.filter(function(e){return!1===e.primary_key||"0"===e.primary_key}).slice(0,4).map(function(e){return e.field})).filter(function(i){return e.fields[i]}).map(function(i){var t=e.fields[i];return{field:i,name:t.name,fieldInfo:t}})},rowHeight:function(){return"comfortable"===this.viewOptions.spacing?50:"cozy"===this.viewOptions.spacing?40:"compact"===this.viewOptions.spacing?30:40},sortVal:function(){var e=this.viewQuery&&this.viewQuery.sort||this.primaryKeyField;return{asc:!e.startsWith("-"),field:e.replace("-","")}}},methods:{sort:function(e){var i=(e.asc?"":"-")+e.field;this.$emit("query",{sort:i})},setWidths:function(e){this.$emit("options",{widths:e})}},watch:{sortVal:function(e,i){e!==i&&(this.$refs.table.$el.scrollTop=0)}}};exports.default=t;
(function(){var e=exports.default||module.exports;"function"==typeof e&&(e=e.options),Object.assign(e,{render:function(){var e=this,t=e.$createElement;return(e._self._c||t)("v-table",{ref:"table",class:e.viewOptions.spacing,attrs:{items:e.items,columns:e.columns,"primary-key-field":e.primaryKeyField,selection:e.selection,"sort-val":e.sortVal,"row-height":e.rowHeight,loading:e.loading,"lazy-loading":e.lazyLoading,"column-widths":e.viewOptions.widths||{},link:e.link,"use-interfaces":!0,"manual-sort-field":e.sortField},on:{sort:e.sort,widths:e.setWidths,select:function(t){return e.$emit("select",t)},"scroll-end":function(t){return e.$emit("next-page")},input:function(t){return e.$emit("input",t)}}})},staticRenderFns:[],_compiled:!0,_scopeId:null,functional:void 0});})();
},{"../../../mixins/layout":"vpUX"}]},{},["K8Nu"], "__DirectusExtension__")