@sankhyalabs/sankhyablocks 8.9.3 → 8.9.4
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/cjs/{ConfigStorage-c15716fd.js → ConfigStorage-90552fe8.js} +2 -2
- package/dist/cjs/{DataFetcher-713f0749.js → DataFetcher-1b1e9ff0.js} +58 -43
- package/dist/cjs/{SnkFormConfigManager-29101e20.js → SnkFormConfigManager-0561602d.js} +2 -2
- package/dist/cjs/Sortable-fb1c4cbb.js +2853 -0
- package/dist/cjs/{auth-fetcher-555ff856.js → auth-fetcher-eee6ec18.js} +1 -1
- package/dist/cjs/{constants-d187e03e.js → constants-35ddd366.js} +4 -0
- package/dist/cjs/{dataunit-fetcher-a0079a6f.js → dataunit-fetcher-38233d72.js} +1 -1
- package/dist/cjs/{form-config-fetcher-17775a75.js → form-config-fetcher-00372ac0.js} +1 -1
- package/dist/cjs/{pesquisa-fetcher-34922b83.js → pesquisa-fetcher-8bc6d0a5.js} +1 -1
- package/dist/cjs/snk-actions-button.cjs.entry.js +4 -5
- package/dist/cjs/snk-application.cjs.entry.js +6 -7
- package/dist/cjs/snk-attach.cjs.entry.js +3 -4
- package/dist/cjs/snk-config-options.cjs.entry.js +1 -1
- package/dist/cjs/snk-configurator.cjs.entry.js +1 -1
- package/dist/cjs/snk-crud.cjs.entry.js +6 -7
- package/dist/cjs/snk-data-exporter.cjs.entry.js +2 -3
- package/dist/cjs/snk-detail-view.cjs.entry.js +8 -9
- package/dist/cjs/snk-field-config.cjs.entry.js +1 -1
- package/dist/cjs/snk-filter-bar.cjs.entry.js +3 -4
- package/dist/cjs/snk-filter-modal-item.cjs.entry.js +3 -4
- package/dist/cjs/snk-form-config.cjs.entry.js +15 -14
- package/dist/cjs/snk-form.cjs.entry.js +4 -5
- package/dist/cjs/snk-grid-config.cjs.entry.js +4 -5
- package/dist/cjs/snk-grid.cjs.entry.js +3 -4
- package/dist/cjs/{snk-guides-viewer-f7ef9607.js → snk-guides-viewer-676dd526.js} +6 -6
- package/dist/cjs/snk-guides-viewer.cjs.entry.js +8 -9
- package/dist/cjs/snk-personalized-filter.cjs.entry.js +3 -4
- package/dist/cjs/snk-select-box.cjs.entry.js +1 -1
- package/dist/cjs/snk-simple-crud.cjs.entry.js +5 -6
- package/dist/cjs/snk-tab-config.cjs.entry.js +7 -7
- package/dist/collection/components/snk-form/subcomponents/snk-form-config/snk-form-config.js +10 -8
- package/dist/collection/components/snk-form/subcomponents/snk-tab-config/snk-tab-config.js +5 -4
- package/dist/collection/lib/utils/constants.js +3 -0
- package/dist/components/DataFetcher.js +16 -1
- package/dist/components/constants.js +4 -1
- package/dist/components/snk-form-config2.js +13 -11
- package/dist/components/snk-tab-config2.js +2198 -6229
- package/dist/esm/{ConfigStorage-79c81f36.js → ConfigStorage-84abda58.js} +2 -2
- package/dist/esm/{DataFetcher-79f78222.js → DataFetcher-7814568f.js} +16 -1
- package/dist/esm/{SnkFormConfigManager-7723f3ec.js → SnkFormConfigManager-655943d0.js} +2 -2
- package/dist/esm/Sortable-83960219.js +2851 -0
- package/dist/esm/{auth-fetcher-e260d0cd.js → auth-fetcher-06354710.js} +1 -1
- package/dist/esm/{constants-3644f1b6.js → constants-8457af36.js} +4 -1
- package/dist/esm/{dataunit-fetcher-a2e763f3.js → dataunit-fetcher-aa70ea72.js} +1 -1
- package/dist/esm/{form-config-fetcher-e1603e66.js → form-config-fetcher-24f43afd.js} +1 -1
- package/dist/esm/{pesquisa-fetcher-8e922c9d.js → pesquisa-fetcher-f7aaf727.js} +1 -1
- package/dist/esm/snk-actions-button.entry.js +4 -5
- package/dist/esm/snk-application.entry.js +6 -7
- package/dist/esm/snk-attach.entry.js +3 -4
- package/dist/esm/snk-config-options.entry.js +1 -1
- package/dist/esm/snk-configurator.entry.js +1 -1
- package/dist/esm/snk-crud.entry.js +6 -7
- package/dist/esm/snk-data-exporter.entry.js +2 -3
- package/dist/esm/snk-detail-view.entry.js +8 -9
- package/dist/esm/snk-field-config.entry.js +1 -1
- package/dist/esm/snk-filter-bar.entry.js +3 -4
- package/dist/esm/snk-filter-modal-item.entry.js +3 -4
- package/dist/esm/snk-form-config.entry.js +15 -14
- package/dist/esm/snk-form.entry.js +4 -5
- package/dist/esm/snk-grid-config.entry.js +4 -5
- package/dist/esm/snk-grid.entry.js +3 -4
- package/dist/esm/{snk-guides-viewer-9f5dfbcc.js → snk-guides-viewer-746e2547.js} +6 -6
- package/dist/esm/snk-guides-viewer.entry.js +8 -9
- package/dist/esm/snk-personalized-filter.entry.js +3 -4
- package/dist/esm/snk-select-box.entry.js +1 -1
- package/dist/esm/snk-simple-crud.entry.js +5 -6
- package/dist/esm/snk-tab-config.entry.js +7 -7
- package/dist/sankhyablocks/p-0d5e8a37.entry.js +1 -0
- package/dist/sankhyablocks/p-1a991d41.entry.js +1 -0
- package/dist/sankhyablocks/p-1ae31937.entry.js +1 -0
- package/dist/sankhyablocks/p-25df73bf.entry.js +1 -0
- package/dist/sankhyablocks/p-3b60db06.entry.js +1 -0
- package/dist/sankhyablocks/p-3f0fe056.js +1 -0
- package/dist/sankhyablocks/{p-2e6f1666.js → p-5eb3ac18.js} +1 -1
- package/dist/sankhyablocks/{p-73d3daa8.entry.js → p-5f74c859.entry.js} +1 -1
- package/dist/sankhyablocks/p-6e32de4b.entry.js +1 -0
- package/dist/sankhyablocks/p-718ecd01.entry.js +1 -0
- package/dist/sankhyablocks/p-809a09ac.entry.js +1 -0
- package/dist/sankhyablocks/p-88039a7f.js +1 -0
- package/dist/sankhyablocks/p-8eb67fa4.entry.js +1 -0
- package/dist/sankhyablocks/p-8f307ef2.entry.js +1 -0
- package/dist/sankhyablocks/{p-f30526a7.entry.js → p-95df461f.entry.js} +1 -1
- package/dist/sankhyablocks/{p-838f8234.entry.js → p-98674137.entry.js} +1 -1
- package/dist/sankhyablocks/p-993e27ad.entry.js +1 -0
- package/dist/sankhyablocks/p-a3868fbc.entry.js +1 -0
- package/dist/sankhyablocks/p-a3fbded7.entry.js +1 -0
- package/dist/sankhyablocks/p-a4401f5f.entry.js +1 -0
- package/dist/sankhyablocks/{p-29176742.js → p-a9b6acf1.js} +1 -1
- package/dist/sankhyablocks/p-b0ef4383.js +1 -0
- package/dist/sankhyablocks/{p-80e9773f.js → p-b54e06ca.js} +1 -1
- package/dist/sankhyablocks/p-c6800fd4.entry.js +1 -0
- package/dist/sankhyablocks/p-d7665a57.entry.js +1 -0
- package/dist/sankhyablocks/{p-41d156dd.js → p-e38f28ae.js} +2 -2
- package/dist/sankhyablocks/{p-4651b43f.js → p-e47d966c.js} +1 -1
- package/dist/sankhyablocks/{p-839da75f.js → p-ee49df44.js} +1 -1
- package/dist/sankhyablocks/{p-6a33f844.entry.js → p-f3479d53.entry.js} +2 -2
- package/dist/sankhyablocks/p-fa816fb2.js +1 -0
- package/dist/sankhyablocks/sankhyablocks.esm.js +1 -1
- package/dist/types/lib/utils/constants.d.ts +3 -4
- package/package.json +2 -2
- package/dist/cjs/_commonjsHelpers-537d719a.js +0 -20
- package/dist/cjs/draggable.bundle-82a25c06.js +0 -6886
- package/dist/components/_commonjsHelpers.js +0 -17
- package/dist/esm/_commonjsHelpers-9943807e.js +0 -17
- package/dist/esm/draggable.bundle-41d56f06.js +0 -6884
- package/dist/sankhyablocks/p-06e76ed2.entry.js +0 -1
- package/dist/sankhyablocks/p-112455b1.js +0 -1
- package/dist/sankhyablocks/p-1e8262a0.entry.js +0 -1
- package/dist/sankhyablocks/p-32b0a5e1.entry.js +0 -1
- package/dist/sankhyablocks/p-47e4b6c9.entry.js +0 -1
- package/dist/sankhyablocks/p-4a78e118.js +0 -1
- package/dist/sankhyablocks/p-51529d47.entry.js +0 -1
- package/dist/sankhyablocks/p-6bdb1068.entry.js +0 -1
- package/dist/sankhyablocks/p-80692cbd.entry.js +0 -1
- package/dist/sankhyablocks/p-94c532bb.entry.js +0 -1
- package/dist/sankhyablocks/p-9cbf6c15.entry.js +0 -1
- package/dist/sankhyablocks/p-b2ce189a.entry.js +0 -1
- package/dist/sankhyablocks/p-b6d6b172.js +0 -1
- package/dist/sankhyablocks/p-bd628455.entry.js +0 -1
- package/dist/sankhyablocks/p-c1e50dda.entry.js +0 -1
- package/dist/sankhyablocks/p-c9399ce6.js +0 -1
- package/dist/sankhyablocks/p-cead4799.entry.js +0 -1
- package/dist/sankhyablocks/p-d0b36421.js +0 -1
- package/dist/sankhyablocks/p-e60325bc.entry.js +0 -1
- package/dist/sankhyablocks/p-f007b434.entry.js +0 -1
- package/dist/sankhyablocks/p-fda8c84c.entry.js +0 -1
package/dist/collection/components/snk-form/subcomponents/snk-form-config/snk-form-config.js
CHANGED
@@ -2,7 +2,7 @@ import { h, Host } from "@stencil/core";
|
|
2
2
|
import { Sortable } from '@shopify/draggable';
|
3
3
|
import { ObjectUtils, ArrayUtils, ElementIDUtils } from '@sankhyalabs/core';
|
4
4
|
import { ApplicationUtils, DialogType } from "@sankhyalabs/ezui/dist/collection/utils";
|
5
|
-
import { ACTION_CONFIG, CONFIG_EVENTS, DEFAULT_TYPE, TAB_NAMES } from "../../../../lib/utils/constants";
|
5
|
+
import { ACTION_CONFIG, CONFIG_EVENTS, CONFIG_SORTABLE_EVENTS, DEFAULT_TYPE, TAB_NAMES } from "../../../../lib/utils/constants";
|
6
6
|
import { UserConfigType } from "../../../../lib/http/data-fetcher/fetchers/form-config-fetcher";
|
7
7
|
import { buildFormConfigFromDataUnit } from "@sankhyalabs/ezui/dist/collection/utils/form";
|
8
8
|
const CONTAINER_ID = {
|
@@ -410,11 +410,12 @@ export class SnkFormConfig {
|
|
410
410
|
draggable: '[data-draggable-element="field"]',
|
411
411
|
mirror: {
|
412
412
|
constrainDimensions: true
|
413
|
-
}
|
413
|
+
},
|
414
|
+
distance: CONFIG_EVENTS.dragStartDistance
|
414
415
|
});
|
415
|
-
this._sortableField.on(
|
416
|
-
this._sortableField.on(
|
417
|
-
this._sortableField.on(
|
416
|
+
this._sortableField.on(CONFIG_SORTABLE_EVENTS.dragStart, (evt) => this.controlStartDraggingField(evt));
|
417
|
+
this._sortableField.on(CONFIG_SORTABLE_EVENTS.dragSorted, (evt) => this.controlSortedDraggingField(evt));
|
418
|
+
this._sortableField.on(CONFIG_SORTABLE_EVENTS.dragStop, (evt) => this.controlStopDraggingField(evt));
|
418
419
|
}
|
419
420
|
controlStartDraggingGroup(evt) {
|
420
421
|
if (this._mouseOnFieldConfig || this._editingTitleGroup) {
|
@@ -440,10 +441,11 @@ export class SnkFormConfig {
|
|
440
441
|
draggable: '[data-draggable-element="group"]',
|
441
442
|
mirror: {
|
442
443
|
constrainDimensions: true
|
443
|
-
}
|
444
|
+
},
|
445
|
+
distance: CONFIG_EVENTS.dragStartDistance
|
444
446
|
});
|
445
|
-
this._sortableGroup.on(
|
446
|
-
this._sortableGroup.on(
|
447
|
+
this._sortableGroup.on(CONFIG_SORTABLE_EVENTS.dragStart, (evt) => this.controlStartDraggingGroup(evt));
|
448
|
+
this._sortableGroup.on(CONFIG_SORTABLE_EVENTS.dragStop, (evt) => this.controlStopDraggingGroup(evt));
|
447
449
|
}
|
448
450
|
loadUserConfig() {
|
449
451
|
if (this.configManager == undefined) {
|
@@ -1,7 +1,7 @@
|
|
1
1
|
import { h, Host, Fragment } from "@stencil/core";
|
2
2
|
import { Sortable } from '@shopify/draggable';
|
3
3
|
import { ApplicationContext, ElementIDUtils } from "@sankhyalabs/core";
|
4
|
-
import { CONFIG_EVENTS, KEY_EVENTS, TAB_NAMES, TYPE_ACTIONS } from "../../../../lib/utils/constants";
|
4
|
+
import { CONFIG_EVENTS, CONFIG_SORTABLE_EVENTS, KEY_EVENTS, TAB_NAMES, TYPE_ACTIONS } from "../../../../lib/utils/constants";
|
5
5
|
export class SnkTabConfig {
|
6
6
|
constructor() {
|
7
7
|
this._refTabActions = [];
|
@@ -33,10 +33,11 @@ export class SnkTabConfig {
|
|
33
33
|
draggable: '[data-draggable-element="tab"]',
|
34
34
|
mirror: {
|
35
35
|
constrainDimensions: true
|
36
|
-
}
|
36
|
+
},
|
37
|
+
distance: CONFIG_EVENTS.dragStartDistance
|
37
38
|
});
|
38
|
-
this._sortableTab.on(
|
39
|
-
this._sortableTab.on(
|
39
|
+
this._sortableTab.on(CONFIG_SORTABLE_EVENTS.dragStart, (evt) => this.controlStartDraggingTab(evt));
|
40
|
+
this._sortableTab.on(CONFIG_SORTABLE_EVENTS.dragStop, (evt) => this.controlStopDraggingTab(evt));
|
40
41
|
}
|
41
42
|
controlStartDraggingTab(evt) {
|
42
43
|
var _a, _b;
|
@@ -35,6 +35,9 @@ export const CONFIG_EVENTS = {
|
|
35
35
|
changeConfig: "changeConfig",
|
36
36
|
configChanged: "configChanged",
|
37
37
|
fieldChanged: "ezChange",
|
38
|
+
dragStartDistance: 40
|
39
|
+
};
|
40
|
+
export const CONFIG_SORTABLE_EVENTS = {
|
38
41
|
dragStart: "sortable:start",
|
39
42
|
dragSort: "sortable:sort",
|
40
43
|
dragSorted: "sortable:sorted",
|
@@ -1,8 +1,23 @@
|
|
1
1
|
import { DataType, ApplicationContext, StringUtils, ErrorException, WarningException, ObjectUtils } from '@sankhyalabs/core';
|
2
|
-
import { c as createCommonjsModule, a as commonjsGlobal } from './_commonjsHelpers.js';
|
3
2
|
import { DataUnitTransient } from '@sankhyalabs/core/dist/dataunit/metadata/UnitMetadata';
|
4
3
|
import { P as PrintUtils } from './PrintUtils.js';
|
5
4
|
|
5
|
+
var commonjsGlobal = typeof globalThis !== 'undefined' ? globalThis : typeof window !== 'undefined' ? window : typeof global !== 'undefined' ? global : typeof self !== 'undefined' ? self : {};
|
6
|
+
|
7
|
+
function createCommonjsModule(fn, basedir, module) {
|
8
|
+
return module = {
|
9
|
+
path: basedir,
|
10
|
+
exports: {},
|
11
|
+
require: function (path, base) {
|
12
|
+
return commonjsRequire();
|
13
|
+
}
|
14
|
+
}, fn(module, module.exports), module.exports;
|
15
|
+
}
|
16
|
+
|
17
|
+
function commonjsRequire () {
|
18
|
+
throw new Error('Dynamic requires are not currently supported by @rollup/plugin-commonjs');
|
19
|
+
}
|
20
|
+
|
6
21
|
var browserPonyfill = createCommonjsModule(function (module, exports) {
|
7
22
|
var global = typeof self !== 'undefined' ? self : commonjsGlobal;
|
8
23
|
var __self__ = (function () {
|
@@ -32,6 +32,9 @@ const CONFIG_EVENTS = {
|
|
32
32
|
changeConfig: "changeConfig",
|
33
33
|
configChanged: "configChanged",
|
34
34
|
fieldChanged: "ezChange",
|
35
|
+
dragStartDistance: 40
|
36
|
+
};
|
37
|
+
const CONFIG_SORTABLE_EVENTS = {
|
35
38
|
dragStart: "sortable:start",
|
36
39
|
dragSort: "sortable:sort",
|
37
40
|
dragSorted: "sortable:sorted",
|
@@ -87,4 +90,4 @@ var SIMPLE_CRUD_MODE;
|
|
87
90
|
SIMPLE_CRUD_MODE[SIMPLE_CRUD_MODE["IN_MEMORY"] = 1] = "IN_MEMORY";
|
88
91
|
})(SIMPLE_CRUD_MODE || (SIMPLE_CRUD_MODE = {}));
|
89
92
|
|
90
|
-
export { ACTION_CONFIG as A, CONFIG_EVENTS as C, DEFAULT_TYPE as D, KEY_EVENTS as K, ORDER_VALUES as O, REPORT_LAUNCHER_RESOURCE_ID as R, SIMPLE_CRUD_MODE as S, TAGS_BY_TYPE as T, VIEW_MODE as V, VARS_BY_TYPE as a,
|
93
|
+
export { ACTION_CONFIG as A, CONFIG_EVENTS as C, DEFAULT_TYPE as D, KEY_EVENTS as K, ORDER_VALUES as O, REPORT_LAUNCHER_RESOURCE_ID as R, SIMPLE_CRUD_MODE as S, TAGS_BY_TYPE as T, VIEW_MODE as V, VARS_BY_TYPE as a, CONFIG_SORTABLE_EVENTS as b, TAB_NAMES as c, TYPE_ACTIONS as d };
|
@@ -1,8 +1,8 @@
|
|
1
1
|
import { proxyCustomElement, HTMLElement, createEvent, h, Host } from '@stencil/core/internal/client';
|
2
|
-
import { a as
|
2
|
+
import { a as Sortable, d as defineCustomElement$1 } from './snk-tab-config2.js';
|
3
3
|
import { ObjectUtils, ElementIDUtils, ArrayUtils } from '@sankhyalabs/core';
|
4
4
|
import { ApplicationUtils, DialogType } from '@sankhyalabs/ezui/dist/collection/utils';
|
5
|
-
import { C as CONFIG_EVENTS, b as TAB_NAMES, A as ACTION_CONFIG, D as DEFAULT_TYPE } from './constants.js';
|
5
|
+
import { C as CONFIG_EVENTS, b as CONFIG_SORTABLE_EVENTS, c as TAB_NAMES, A as ACTION_CONFIG, D as DEFAULT_TYPE } from './constants.js';
|
6
6
|
import { U as UserConfigType } from './form-config-fetcher.js';
|
7
7
|
import { buildFormConfigFromDataUnit } from '@sankhyalabs/ezui/dist/collection/utils/form';
|
8
8
|
import { d as defineCustomElement$3 } from './snk-config-options2.js';
|
@@ -412,15 +412,16 @@ const SnkFormConfig = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement
|
|
412
412
|
if (this._sortableField) {
|
413
413
|
this._sortableField.destroy();
|
414
414
|
}
|
415
|
-
this._sortableField = new
|
415
|
+
this._sortableField = new Sortable(this._sortableContainer.querySelectorAll('[data-draggable-parent="field"]'), {
|
416
416
|
draggable: '[data-draggable-element="field"]',
|
417
417
|
mirror: {
|
418
418
|
constrainDimensions: true
|
419
|
-
}
|
419
|
+
},
|
420
|
+
distance: CONFIG_EVENTS.dragStartDistance
|
420
421
|
});
|
421
|
-
this._sortableField.on(
|
422
|
-
this._sortableField.on(
|
423
|
-
this._sortableField.on(
|
422
|
+
this._sortableField.on(CONFIG_SORTABLE_EVENTS.dragStart, (evt) => this.controlStartDraggingField(evt));
|
423
|
+
this._sortableField.on(CONFIG_SORTABLE_EVENTS.dragSorted, (evt) => this.controlSortedDraggingField(evt));
|
424
|
+
this._sortableField.on(CONFIG_SORTABLE_EVENTS.dragStop, (evt) => this.controlStopDraggingField(evt));
|
424
425
|
}
|
425
426
|
controlStartDraggingGroup(evt) {
|
426
427
|
if (this._mouseOnFieldConfig || this._editingTitleGroup) {
|
@@ -442,14 +443,15 @@ const SnkFormConfig = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement
|
|
442
443
|
if (this._sortableGroup) {
|
443
444
|
this._sortableGroup.destroy();
|
444
445
|
}
|
445
|
-
this._sortableGroup = new
|
446
|
+
this._sortableGroup = new Sortable(this._sortableContainer.querySelectorAll('[data-draggable-parent="group"]'), {
|
446
447
|
draggable: '[data-draggable-element="group"]',
|
447
448
|
mirror: {
|
448
449
|
constrainDimensions: true
|
449
|
-
}
|
450
|
+
},
|
451
|
+
distance: CONFIG_EVENTS.dragStartDistance
|
450
452
|
});
|
451
|
-
this._sortableGroup.on(
|
452
|
-
this._sortableGroup.on(
|
453
|
+
this._sortableGroup.on(CONFIG_SORTABLE_EVENTS.dragStart, (evt) => this.controlStartDraggingGroup(evt));
|
454
|
+
this._sortableGroup.on(CONFIG_SORTABLE_EVENTS.dragStop, (evt) => this.controlStopDraggingGroup(evt));
|
453
455
|
}
|
454
456
|
loadUserConfig() {
|
455
457
|
if (this.configManager == undefined) {
|