@cortezaproject/corteza-vue 2022.9.2 → 2022.9.3-rc.2
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.
- package/dist/components/progress/index.d.ts +1 -0
- package/dist/index.d.ts +2 -1
- package/dist/index.es.js +48 -30
- package/dist/index.es.js.map +1 -1
- package/dist/index.js +48 -29
- package/dist/index.js.map +1 -1
- package/dist/libs/handle.d.ts +2 -0
- package/package.json +2 -2
- package/LICENSE +0 -202
- package/README.md +0 -105
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as CProgress } from './CProgress.vue';
|
package/dist/index.d.ts
CHANGED
|
@@ -6,6 +6,7 @@ import * as filters from './filters';
|
|
|
6
6
|
import * as store from './store';
|
|
7
7
|
import * as url from './libs/url';
|
|
8
8
|
import * as filter from './libs/filter';
|
|
9
|
+
import * as handle from './libs/handle';
|
|
9
10
|
import * as websocket from './libs/websocket';
|
|
10
11
|
import i18n from './i18n';
|
|
11
|
-
export { plugins, mixins, components, corredor, filters, store, url, filter, websocket, i18n, };
|
|
12
|
+
export { plugins, mixins, components, corredor, filters, store, url, filter, handle, websocket, i18n, };
|
package/dist/index.es.js
CHANGED
|
@@ -81944,16 +81944,6 @@ var __vue_staticRenderFns__$z = [];
|
|
|
81944
81944
|
//
|
|
81945
81945
|
//
|
|
81946
81946
|
//
|
|
81947
|
-
//
|
|
81948
|
-
//
|
|
81949
|
-
//
|
|
81950
|
-
//
|
|
81951
|
-
//
|
|
81952
|
-
//
|
|
81953
|
-
//
|
|
81954
|
-
//
|
|
81955
|
-
//
|
|
81956
|
-
//
|
|
81957
81947
|
var script$E = {
|
|
81958
81948
|
props: {
|
|
81959
81949
|
sidebarPinned: {
|
|
@@ -82034,20 +82024,20 @@ var script$E = {
|
|
|
82034
82024
|
const __vue_script__$E = script$E;
|
|
82035
82025
|
|
|
82036
82026
|
/* template */
|
|
82037
|
-
var __vue_render__$A = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{staticClass:"header-navigation d-flex align-items-center
|
|
82038
|
-
|
|
82039
|
-
|
|
82027
|
+
var __vue_render__$A = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{staticClass:"header-navigation d-flex align-items-center sticky-top pr-3 pl-5"},[_c('div',{staticClass:"spacer",class:{
|
|
82028
|
+
'expanded': _vm.sidebarPinned,
|
|
82029
|
+
}}),_vm._v(" "),_c('h2',{staticClass:"d-none d-sm-inline-block text-truncate mb-0 ml-1"},[_vm._t("title")],2),_vm._v(" "),_c('div',{staticClass:"ml-auto text-sm-nowrap"},[_vm._t("tools")],2),_vm._v(" "),(!_vm.hideAppSelector && !_vm.settings.hideAppSelector)?_c('b-button',{staticClass:"d-flex align-items-center justify-content-center text-dark border-0 nav-icon rounded-circle",attrs:{"variant":"outline-light","href":_vm.appSelectorURL,"size":"lg"}},[_c('font-awesome-icon',{staticClass:"m-0 h5",attrs:{"icon":['fas', 'grip-horizontal']}})],1):_vm._e(),_vm._v(" "),(!_vm.settings.hideHelp)?_c('b-dropdown',{staticClass:"nav-icon mx-1",attrs:{"data-test-id":"dropdown-helper","size":"lg","variant":"outline-light","toggle-class":"text-decoration-none text-dark rounded-circle border-0 w-100","menu-class":"topbar-dropdown-menu border-0 shadow-sm text-dark font-weight-bold mt-2","right":"","no-caret":""},scopedSlots:_vm._u([{key:"button-content",fn:function(){return [_c('div',{staticClass:"d-flex align-items-center justify-content-center"},[_c('font-awesome-icon',{staticClass:"m-0 h5",attrs:{"icon":['far', 'question-circle']}}),_vm._v(" "),_c('span',{staticClass:"sr-only"},[_vm._v("\n "+_vm._s(_vm.labels.helpForum)+"\n ")])],1)]},proxy:true}],null,false,2593833445)},[_vm._v(" "),_c('div',[_vm._t("help-dropdown")],2),_vm._v(" "),_vm._l((_vm.helpLinks),function(helpLink,index){return _c('b-dropdown-item',{key:index,attrs:{"href":helpLink.url,"target":helpLink.newTab ? '_blank' : ''}},[_vm._v("\n "+_vm._s(helpLink.handle)+"\n ")])}),_vm._v(" "),(!_vm.settings.hideForumLink)?_c('b-dropdown-item',{attrs:{"data-test-id":"dropdown-helper-forum","href":"https://forum.cortezaproject.org/","target":"_blank"}},[_vm._v("\n "+_vm._s(_vm.labels.helpForum)+"\n ")]):_vm._e(),_vm._v(" "),(!_vm.settings.hideDocumentationLink)?_c('b-dropdown-item',{attrs:{"data-test-id":"dropdown-helper-docs","href":_vm.documentationURL,"target":"_blank"}},[_vm._v("\n "+_vm._s(_vm.labels.helpDocumentation)+"\n ")]):_vm._e(),_vm._v(" "),(!_vm.settings.hideFeedbackLink)?_c('b-dropdown-item',{attrs:{"data-test-id":"dropdown-helper-feedback","href":"mailto:info@crust.tech","target":"_blank"}},[_vm._v("\n "+_vm._s(_vm.labels.helpFeedback)+"\n ")]):_vm._e(),_vm._v(" "),(!_vm.onlyVersion)?_c('b-dropdown-divider'):_vm._e(),_vm._v(" "),_c('b-dropdown-item',{staticClass:"small",attrs:{"disabled":""}},[_vm._v("\n "+_vm._s(_vm.labels.helpVersion)+"\n "),_c('br'),_vm._v("\n "+_vm._s(_vm.frontendVersion)+"\n ")])],2):_vm._e(),_vm._v(" "),(!_vm.settings.hideProfile)?_c('b-dropdown',{staticClass:"nav-user-icon",attrs:{"data-test-id":"dropdown-profile","data-v-onboarding":"profile","size":"lg","variant":"outline-light","toggle-class":"nav-icon text-decoration-none text-dark rounded-circle border","menu-class":"topbar-dropdown-menu border-0 shadow-sm text-dark font-weight-bold mt-2","right":"","no-caret":""},scopedSlots:_vm._u([{key:"button-content",fn:function(){return [_c('div',{staticClass:"d-flex align-items-center justify-content-center"},[_c('font-awesome-icon',{staticClass:"m-0 h5",attrs:{"icon":['far', 'user']}}),_vm._v(" "),_c('span',{staticClass:"sr-only"},[_vm._v("\n "+_vm._s(_vm.labels.helpForum)+"\n ")])],1)]},proxy:true}],null,false,304590661)},[_vm._v(" "),_c('b-dropdown-text',{staticClass:"text-muted mb-2"},[_vm._v("\n "+_vm._s(_vm.labels.userSettingsLoggedInAs)+"\n ")]),_vm._v(" "),_c('div',[_vm._t("avatar-dropdown")],2),_vm._v(" "),_vm._l((_vm.profileLinks),function(profileLink,index){return _c('b-dropdown-item',{key:index,attrs:{"href":profileLink.url,"target":profileLink.newTab ? '_blank' : ''}},[_vm._v("\n "+_vm._s(profileLink.handle)+"\n ")])}),_vm._v(" "),(!_vm.settings.hideProfileLink)?_c('b-dropdown-item',{attrs:{"data-test-id":"dropdown-profile-user","href":_vm.userProfileURL,"target":"_blank"}},[_vm._v("\n "+_vm._s(_vm.labels.userSettingsProfile)+"\n ")]):_vm._e(),_vm._v(" "),(!_vm.settings.hideChangePasswordLink)?_c('b-dropdown-item',{attrs:{"data-test-id":"dropdown-profile-change-password","href":_vm.changePasswordURL,"target":"_blank"}},[_vm._v("\n "+_vm._s(_vm.labels.userSettingsChangePassword)+"\n ")]):_vm._e(),_vm._v(" "),_c('b-dropdown-divider'),_vm._v(" "),_c('b-dropdown-item',{staticClass:"mt-2",attrs:{"data-test-id":"dropdown-profile-logout","href":""},on:{"click":function($event){return _vm.$auth.logout()}}},[_vm._v("\n "+_vm._s(_vm.labels.userSettingsLogout)+"\n ")])],2):_vm._e()],1)};
|
|
82040
82030
|
var __vue_staticRenderFns__$A = [];
|
|
82041
82031
|
|
|
82042
82032
|
/* style */
|
|
82043
82033
|
const __vue_inject_styles__$F = function (inject) {
|
|
82044
82034
|
if (!inject) return
|
|
82045
|
-
inject("data-v-
|
|
82046
|
-
,inject("data-v-
|
|
82035
|
+
inject("data-v-3f0cae1a_0", { source: ".icon-logo[data-v-3f0cae1a]{height:calc(64px / 2);background-repeat:no-repeat;background-position:center}.nav-icon[data-v-3f0cae1a]{width:40px;height:40px}.nav-user-icon[data-v-3f0cae1a]{width:50px;height:50px}.header-navigation[data-v-3f0cae1a]{width:100vw;height:64px;background-color:#f3f3f5!important}.header-navigation h2[data-v-3f0cae1a]{padding-left:calc(.5rem + 2px)}.topbar-dropdown-menu[data-v-3f0cae1a]{max-height:80vh;overflow-y:auto}.spacer[data-v-3f0cae1a]{min-width:0;-webkit-transition:min-width .15s ease-in-out;-moz-transition:min-width .15s ease-in-out;-o-transition:min-width .15s ease-in-out;transition:min-width .15s ease-in-out}.spacer.expanded[data-v-3f0cae1a]{min-width:calc(320px - 42px);-webkit-transition:min-width .2s ease-in-out;-moz-transition:min-width .2s ease-in-out;-o-transition:min-width .2s ease-in-out;transition:min-width .2s ease-in-out}", map: undefined, media: undefined })
|
|
82036
|
+
,inject("data-v-3f0cae1a_1", { source: ".topbar-tools .vue-portal-target{display:flex;align-items:center}", map: undefined, media: undefined });
|
|
82047
82037
|
|
|
82048
82038
|
};
|
|
82049
82039
|
/* scoped */
|
|
82050
|
-
const __vue_scope_id__$F = "data-v-
|
|
82040
|
+
const __vue_scope_id__$F = "data-v-3f0cae1a";
|
|
82051
82041
|
/* module identifier */
|
|
82052
82042
|
const __vue_module_identifier__$F = undefined;
|
|
82053
82043
|
/* functional template */
|
|
@@ -84498,23 +84488,24 @@ var script$Z = {
|
|
|
84498
84488
|
|
|
84499
84489
|
getPagination() {
|
|
84500
84490
|
const {
|
|
84501
|
-
|
|
84502
|
-
|
|
84503
|
-
|
|
84491
|
+
total = 0,
|
|
84492
|
+
limit = 10,
|
|
84493
|
+
page = 1
|
|
84504
84494
|
} = this.pagination;
|
|
84505
|
-
|
|
84495
|
+
const pagination = {
|
|
84506
84496
|
from: (page - 1) * limit + 1,
|
|
84507
|
-
to: Math.min(page * limit,
|
|
84508
|
-
count
|
|
84497
|
+
to: limit > 0 ? Math.min(page * limit, total) : total,
|
|
84498
|
+
count: total
|
|
84509
84499
|
};
|
|
84500
|
+
return this.$t(this.translations[total > limit ? 'showingPagination' : 'singlePluralPagination'], pagination);
|
|
84510
84501
|
},
|
|
84511
84502
|
|
|
84512
84503
|
hasPrevPage() {
|
|
84513
|
-
return
|
|
84504
|
+
return !!this.pagination.prevPage;
|
|
84514
84505
|
},
|
|
84515
84506
|
|
|
84516
84507
|
hasNextPage() {
|
|
84517
|
-
return
|
|
84508
|
+
return !!this.pagination.nextPage;
|
|
84518
84509
|
}
|
|
84519
84510
|
|
|
84520
84511
|
},
|
|
@@ -84561,11 +84552,23 @@ var script$Z = {
|
|
|
84561
84552
|
}
|
|
84562
84553
|
},
|
|
84563
84554
|
|
|
84564
|
-
goToPage(
|
|
84565
|
-
const pageCursor = this.pagination[
|
|
84566
|
-
|
|
84567
|
-
|
|
84555
|
+
goToPage(destination) {
|
|
84556
|
+
const pageCursor = this.pagination[destination] || '';
|
|
84557
|
+
let {
|
|
84558
|
+
page = 1
|
|
84559
|
+
} = this.pagination;
|
|
84560
|
+
|
|
84561
|
+
if (destination === 'nextPage') {
|
|
84562
|
+
page++;
|
|
84563
|
+
} else if (destination === 'prevPage') {
|
|
84564
|
+
page--;
|
|
84565
|
+
} else {
|
|
84566
|
+
page = 1;
|
|
84567
|
+
}
|
|
84568
|
+
|
|
84569
|
+
this.$router.replace({
|
|
84568
84570
|
query: { ...this.$route.query,
|
|
84571
|
+
page,
|
|
84569
84572
|
pageCursor
|
|
84570
84573
|
}
|
|
84571
84574
|
});
|
|
@@ -84578,7 +84581,7 @@ var script$Z = {
|
|
|
84578
84581
|
const __vue_script__$Z = script$Z;
|
|
84579
84582
|
|
|
84580
84583
|
/* template */
|
|
84581
|
-
var __vue_render__$T = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('b-card',{staticClass:"shadow-sm",attrs:{"no-body":"","header-bg-variant":"white"},scopedSlots:_vm._u([{key:"header",fn:function(){return [_c('b-container',{staticClass:"p-0",attrs:{"fluid":"","align-v":"center"}},[_c('b-row',[_c('b-col',{attrs:{"lg":"8"}},[_vm._t("header",null,{"selected":_vm.selected})],2),_vm._v(" "),(!_vm.hideSearch)?_c('b-col',[_c('c-input-search',{attrs:{"placeholder":_vm.translations.searchPlaceholder,"debounce":300},on:{"input":function($event){return _vm.$emit('search')}},model:{value:(_vm.filter[_vm.queryField]),callback:function ($$v) {_vm.$set(_vm.filter, _vm.queryField, (typeof $$v === 'string'? $$v.trim(): $$v));},expression:"filter[queryField]"}})],1):_vm._e()],1)],1)]},proxy:true},{key:"footer",fn:function(){return [_c('div',{staticClass:"d-flex align-items-center justify-content-between"},[_c('div',{staticClass:"text-truncate"},[(!_vm.hideTotal)?_c('div',{staticClass:"text-nowrap font-weight-bold"},[
|
|
84584
|
+
var __vue_render__$T = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('b-card',{staticClass:"shadow-sm",attrs:{"no-body":"","header-bg-variant":"white"},scopedSlots:_vm._u([{key:"header",fn:function(){return [_c('b-container',{staticClass:"p-0",attrs:{"fluid":"","align-v":"center"}},[_c('b-row',[_c('b-col',{attrs:{"lg":"8"}},[_vm._t("header",null,{"selected":_vm.selected})],2),_vm._v(" "),(!_vm.hideSearch)?_c('b-col',[_c('c-input-search',{attrs:{"placeholder":_vm.translations.searchPlaceholder,"debounce":300},on:{"input":function($event){return _vm.$emit('search')}},model:{value:(_vm.filter[_vm.queryField]),callback:function ($$v) {_vm.$set(_vm.filter, _vm.queryField, (typeof $$v === 'string'? $$v.trim(): $$v));},expression:"filter[queryField]"}})],1):_vm._e()],1),_vm._v(" "),_c('b-row',{class:{ 'mt-3': !!_vm.$slots.toolbar }},[_vm._t("toolbar")],2)],1)]},proxy:true},{key:"footer",fn:function(){return [_c('div',{staticClass:"d-flex align-items-center justify-content-between"},[_c('div',{staticClass:"text-truncate"},[(!_vm.hideTotal)?_c('div',{staticClass:"text-nowrap font-weight-bold"},[_vm._v("\n "+_vm._s(_vm.getPagination)+"\n ")]):_vm._e()]),_vm._v(" "),(!_vm.hidePagination)?_c('b-button-group',[_c('b-button',{staticClass:"text-dark",attrs:{"disabled":!_vm.hasPrevPage,"variant":"link"},on:{"click":function($event){return _vm.goToPage()}}},[_c('font-awesome-icon',{attrs:{"icon":['fas', 'angle-double-left']}})],1),_vm._v(" "),_c('b-button',{staticClass:"text-dark",attrs:{"disabled":!_vm.hasPrevPage,"variant":"link"},on:{"click":function($event){return _vm.goToPage('prevPage')}}},[_c('font-awesome-icon',{attrs:{"icon":['fas', 'angle-left']}}),_vm._v("\n "+_vm._s(_vm.translations.prevPagination)+"\n ")],1),_vm._v(" "),_c('b-button',{staticClass:"text-dark",attrs:{"disabled":!_vm.hasNextPage,"variant":"link"},on:{"click":function($event){return _vm.goToPage('nextPage')}}},[_vm._v("\n "+_vm._s(_vm.translations.nextPagination)+"\n "),_c('font-awesome-icon',{attrs:{"icon":['fas', 'angle-right']}})],1)],1):_vm._e()],1)]},proxy:true}],null,true)},[_vm._v(" "),_c('b-card-body',{staticClass:"p-0"},[_c('b-table',{ref:"resourceList",staticClass:"mb-0",attrs:{"id":"resource-list","head-variant":"light","hover":"","responsive":"","show-empty":"","no-sort-reset":"","no-local-sorting":"","primary-key":_vm.primaryKey,"sort-by":_vm.sorting.sortBy,"sort-desc":_vm.sorting.sortDesc,"items":_vm._items,"fields":_vm._fields,"tbody-tr-class":_vm.tableRowClasses},on:{"update:sortBy":function($event){return _vm.$set(_vm.sorting, "sortBy", $event)},"update:sort-by":function($event){return _vm.$set(_vm.sorting, "sortBy", $event)},"update:sortDesc":function($event){return _vm.$set(_vm.sorting, "sortDesc", $event)},"update:sort-desc":function($event){return _vm.$set(_vm.sorting, "sortDesc", $event)},"sort-changed":function($event){_vm.pagination.page = 1;},"row-clicked":function($event){return _vm.$emit('row-clicked', $event)}},scopedSlots:_vm._u([{key:"empty",fn:function(){return [_c('p',{staticClass:"text-center text-dark",staticStyle:{"margin-top":"1vh"},attrs:{"data-test-id":"no-matches"}},[_vm._v("\n "+_vm._s(_vm.translations.noItems)+"\n ")])]},proxy:true},{key:"table-busy",fn:function(){return [_c('div',{staticClass:"text-center m-5"},[_c('div',[_c('b-spinner',{staticClass:"align-middle m-2"})],1),_vm._v("\n "+_vm._s(_vm.translations.loading)+"\n ")])]},proxy:true},(_vm.selectable)?{key:"head(select)",fn:function(){return [_c('b-checkbox',{staticClass:"ml-1",attrs:{"disabled":_vm.disableSelectAll,"checked":_vm.allRowsSelected && !_vm.disableSelectAll},on:{"change":_vm.selectAllRows}})]},proxy:true}:null,{key:"cell(select)",fn:function(ref){
|
|
84582
84585
|
var item = ref.item;
|
|
84583
84586
|
return [(_vm.isItemSelectable(item))?_c('b-form-checkbox',{staticClass:"ml-1",attrs:{"checked":_vm.selected.includes(item[_vm.primaryKey])},on:{"change":function($event){return _vm.onSelectRow($event, item[_vm.primaryKey])}}}):_vm._e()]}},_vm._l((_vm.customFieldSlots),function(field){return {key:("cell(" + field + ")"),fn:function(ref){
|
|
84584
84587
|
var item = ref.item;
|
|
@@ -85637,6 +85640,21 @@ var filter = /*#__PURE__*/Object.freeze({
|
|
|
85637
85640
|
Assert: Assert
|
|
85638
85641
|
});
|
|
85639
85642
|
|
|
85643
|
+
const re = /^[A-Za-z][0-9A-Za-z_\-.]*[A-Za-z0-9]$/;
|
|
85644
|
+
const isValid = (h) => re.test(h);
|
|
85645
|
+
// Used for state
|
|
85646
|
+
function handleState(h) {
|
|
85647
|
+
if (h) {
|
|
85648
|
+
return isValid(h) ? null : false;
|
|
85649
|
+
}
|
|
85650
|
+
}
|
|
85651
|
+
|
|
85652
|
+
var handle = /*#__PURE__*/Object.freeze({
|
|
85653
|
+
__proto__: null,
|
|
85654
|
+
isValid: isValid,
|
|
85655
|
+
handleState: handleState
|
|
85656
|
+
});
|
|
85657
|
+
|
|
85640
85658
|
const config = {
|
|
85641
85659
|
format: 'json',
|
|
85642
85660
|
// (Boolean) whether to reconnect automatically (false)
|
|
@@ -85719,5 +85737,5 @@ var websocket = /*#__PURE__*/Object.freeze({
|
|
|
85719
85737
|
init: init
|
|
85720
85738
|
});
|
|
85721
85739
|
|
|
85722
|
-
export { index$3 as components, index$4 as corredor, filter, index$5 as filters, i18n, index$1 as mixins, index as plugins, index$7 as store, url, websocket };
|
|
85740
|
+
export { index$3 as components, index$4 as corredor, filter, index$5 as filters, handle, i18n, index$1 as mixins, index as plugins, index$7 as store, url, websocket };
|
|
85723
85741
|
//# sourceMappingURL=index.es.js.map
|