@sankhyalabs/sankhyablocks 5.4.3 → 5.5.0
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/{SnkMessageBuilder-115e8a80.js → SnkMessageBuilder-26da04f7.js} +35 -1
- package/dist/cjs/{constants-ae0ed870.js → constants-3787fa32.js} +1 -0
- package/dist/cjs/dataunit-fetcher-8f5ade55.js +319 -0
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/sankhyablocks.cjs.js +1 -1
- package/dist/cjs/snk-application.cjs.entry.js +3 -315
- package/dist/cjs/snk-attach.cjs.entry.js +449 -0
- 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 +22 -13
- package/dist/cjs/snk-data-exporter.cjs.entry.js +3 -3
- package/dist/cjs/{snk-data-unit-aa613f3b.js → snk-data-unit-c43df27b.js} +4 -1
- package/dist/cjs/snk-data-unit.cjs.entry.js +2 -2
- package/dist/cjs/snk-detail-view.cjs.entry.js +4 -5
- package/dist/cjs/snk-field-config.cjs.entry.js +1 -1
- package/dist/cjs/snk-form-config.cjs.entry.js +1 -1
- package/dist/cjs/snk-grid-config.cjs.entry.js +1 -1
- package/dist/cjs/snk-grid.cjs.entry.js +11 -4
- package/dist/cjs/{snk-guides-viewer-7db960c2.js → snk-guides-viewer-e6a65393.js} +2 -2
- package/dist/cjs/snk-guides-viewer.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 → snk-simple-bar_2.cjs.entry.js} +47 -5
- package/dist/cjs/snk-tab-config.cjs.entry.js +1 -1
- package/dist/cjs/snk-taskbar.cjs.entry.js +5 -4
- package/dist/cjs/taskbar-elements-80285601.js +313 -0
- package/dist/collection/collection-manifest.json +2 -1
- package/dist/collection/components/snk-attach/interfaces/index.js +1 -0
- package/dist/collection/components/snk-attach/snk-attach.css +8 -0
- package/dist/collection/components/snk-attach/snk-attach.js +202 -0
- package/dist/collection/components/snk-attach/structure/crud-config-builder.js +37 -0
- package/dist/collection/components/snk-attach/structure/data-unit-builder.js +106 -0
- package/dist/collection/components/snk-attach/structure/index.js +3 -0
- package/dist/collection/components/snk-attach/structure/taskbar-builder.js +47 -0
- package/dist/collection/components/snk-configurator/snk-configurator.js +3 -3
- package/dist/collection/components/snk-crud/snk-crud.js +22 -11
- package/dist/collection/components/snk-data-unit/snk-data-unit.js +21 -0
- package/dist/collection/components/snk-grid/snk-grid.js +11 -3
- package/dist/collection/components/snk-simple-bar/snk-simple-bar.js +37 -2
- package/dist/collection/components/snk-simple-crud/snk-simple-crud.js +65 -2
- package/dist/collection/components/snk-taskbar/elements/taskbar-elements.js +3 -0
- package/dist/collection/components/snk-taskbar/snk-taskbar.js +4 -2
- package/dist/collection/lib/http/data-fetcher/fetchers/attach-fetcher.js +136 -0
- package/dist/collection/lib/http/data-fetcher/fetchers/fecthAttach/interfaces/IDelete.js +1 -0
- package/dist/collection/lib/http/data-fetcher/fetchers/fecthAttach/interfaces/IDownloadKey.js +1 -0
- package/dist/collection/lib/http/data-fetcher/fetchers/fecthAttach/interfaces/ISave.js +6 -0
- package/dist/collection/lib/http/data-fetcher/fetchers/fecthAttach/interfaces/index.js +3 -0
- package/dist/collection/lib/message/SnkMessageBuilder.js +5 -1
- package/dist/collection/lib/message/resources/snk-attach.msg.js +27 -0
- package/dist/collection/lib/message/resources/snk-simple-bar.msg.js +3 -0
- package/dist/collection/lib/message/resources/snk-taskbar.msg.js +1 -0
- package/dist/collection/lib/utils/constants.js +1 -0
- package/dist/components/SnkMessageBuilder.js +35 -1
- package/dist/components/constants.js +1 -0
- package/dist/components/dataunit-fetcher.js +317 -0
- package/dist/components/index.d.ts +1 -0
- package/dist/components/index.js +1 -0
- package/dist/components/snk-application2.js +2 -314
- package/dist/components/snk-attach.d.ts +11 -0
- package/dist/components/snk-attach.js +6 -0
- package/dist/components/snk-attach2.js +498 -0
- package/dist/components/snk-crud.js +77 -48
- package/dist/components/snk-data-unit2.js +4 -0
- package/dist/components/snk-grid2.js +11 -4
- package/dist/components/snk-simple-bar.js +1 -41
- package/dist/components/snk-simple-bar2.js +59 -0
- package/dist/components/snk-simple-crud.js +1 -328
- package/dist/{esm/snk-simple-crud.entry.js → components/snk-simple-crud2.js} +73 -18
- package/dist/components/snk-taskbar2.js +7 -2
- package/dist/esm/{SnkMessageBuilder-a15d22f8.js → SnkMessageBuilder-7a9392e6.js} +35 -1
- package/dist/esm/{constants-15617e7d.js → constants-e916ccc3.js} +1 -0
- package/dist/esm/dataunit-fetcher-d32c6a47.js +317 -0
- package/dist/esm/loader.js +1 -1
- package/dist/esm/sankhyablocks.js +1 -1
- package/dist/esm/snk-application.entry.js +3 -315
- package/dist/esm/snk-attach.entry.js +445 -0
- 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 +23 -14
- package/dist/esm/snk-data-exporter.entry.js +3 -3
- package/dist/esm/{snk-data-unit-5ed93c0e.js → snk-data-unit-f9e4c694.js} +4 -1
- package/dist/esm/snk-data-unit.entry.js +2 -2
- package/dist/esm/snk-detail-view.entry.js +4 -5
- package/dist/esm/snk-field-config.entry.js +1 -1
- package/dist/esm/snk-form-config.entry.js +1 -1
- package/dist/esm/snk-grid-config.entry.js +1 -1
- package/dist/esm/snk-grid.entry.js +11 -4
- package/dist/esm/{snk-guides-viewer-1e7c21f6.js → snk-guides-viewer-62a9f74d.js} +2 -2
- package/dist/esm/snk-guides-viewer.entry.js +3 -4
- package/dist/esm/snk-select-box.entry.js +1 -1
- package/dist/esm/snk-simple-bar_2.entry.js +324 -0
- package/dist/esm/snk-tab-config.entry.js +1 -1
- package/dist/esm/snk-taskbar.entry.js +5 -4
- package/dist/esm/taskbar-elements-055ba1ad.js +309 -0
- package/dist/sankhyablocks/p-17375123.js +1 -0
- package/dist/sankhyablocks/{p-b80cf644.entry.js → p-1c0ee011.entry.js} +1 -1
- package/dist/sankhyablocks/p-4512cc6c.entry.js +1 -0
- package/dist/sankhyablocks/p-5cbbe1f7.entry.js +1 -0
- package/dist/sankhyablocks/p-63d01871.entry.js +1 -0
- package/dist/sankhyablocks/{p-0a1e7f75.entry.js → p-6ac29569.entry.js} +1 -1
- package/dist/sankhyablocks/{p-f4d36823.entry.js → p-6f0b3cc0.entry.js} +1 -1
- package/dist/sankhyablocks/p-741b00ef.entry.js +1 -0
- package/dist/sankhyablocks/{p-6516f35a.entry.js → p-86f75e7a.entry.js} +1 -1
- package/dist/sankhyablocks/{p-32599159.entry.js → p-8b02b276.entry.js} +1 -1
- package/dist/sankhyablocks/p-92a0fca4.js +1 -0
- package/dist/sankhyablocks/p-999d1953.entry.js +1 -0
- package/dist/sankhyablocks/{p-9bfa3cfb.entry.js → p-a412992c.entry.js} +1 -1
- package/dist/sankhyablocks/{p-703dddb9.js → p-aeffd219.js} +1 -1
- package/dist/sankhyablocks/p-b2523981.entry.js +11 -0
- package/dist/sankhyablocks/p-c3efd4eb.entry.js +1 -0
- package/dist/sankhyablocks/{p-3169584f.entry.js → p-e0b4aec3.entry.js} +1 -1
- package/dist/sankhyablocks/p-ebe876f5.entry.js +1 -0
- package/dist/sankhyablocks/p-ed438690.js +1 -0
- package/dist/sankhyablocks/p-f2223502.js +1 -0
- package/dist/sankhyablocks/p-f3d0c744.entry.js +1 -0
- package/dist/sankhyablocks/p-f821768b.js +74 -0
- package/dist/sankhyablocks/{p-f29caa0a.entry.js → p-f8c66aa3.entry.js} +1 -1
- package/dist/sankhyablocks/sankhyablocks.esm.js +1 -1
- package/dist/types/components/snk-attach/interfaces/index.d.ts +10 -0
- package/dist/types/components/snk-attach/snk-attach.d.ts +45 -0
- package/dist/types/components/snk-attach/structure/crud-config-builder.d.ts +7 -0
- package/dist/types/components/snk-attach/structure/data-unit-builder.d.ts +16 -0
- package/dist/types/components/snk-attach/structure/index.d.ts +3 -0
- package/dist/types/components/snk-attach/structure/taskbar-builder.d.ts +8 -0
- package/dist/types/components/snk-data-unit/snk-data-unit.d.ts +5 -0
- package/dist/types/components/snk-simple-bar/snk-simple-bar.d.ts +14 -0
- package/dist/types/components/snk-taskbar/elements/taskbar-elements.d.ts +2 -1
- package/dist/types/components/snk-taskbar/snk-taskbar.d.ts +1 -0
- package/dist/types/components.d.ts +67 -0
- package/dist/types/global.d.ts +9 -0
- package/dist/types/lib/http/data-fetcher/DataFetcher.d.ts +8 -2
- package/dist/types/lib/http/data-fetcher/fetchers/attach-fetcher.d.ts +14 -0
- package/dist/types/lib/http/data-fetcher/fetchers/fecthAttach/interfaces/IDelete.d.ts +9 -0
- package/dist/types/lib/http/data-fetcher/fetchers/fecthAttach/interfaces/IDownloadKey.d.ts +13 -0
- package/dist/types/lib/http/data-fetcher/fetchers/fecthAttach/interfaces/ISave.d.ts +26 -0
- package/dist/types/lib/http/data-fetcher/fetchers/fecthAttach/interfaces/index.d.ts +3 -0
- package/dist/types/lib/message/resources/snk-attach.msg.d.ts +2 -0
- package/dist/types/lib/message/resources/snk-simple-bar.msg.d.ts +1 -0
- package/dist/types/lib/utils/constants.d.ts +2 -1
- package/package.json +1 -1
- package/react/components.d.ts +1 -0
- package/react/components.js +1 -0
- package/react/components.js.map +1 -1
- package/dist/cjs/index-fc7ca86c.js +0 -200
- package/dist/cjs/snk-simple-bar.cjs.entry.js +0 -30
- package/dist/cjs/taskbar-elements-5e87cf44.js +0 -115
- package/dist/esm/index-e467ade5.js +0 -198
- package/dist/esm/snk-simple-bar.entry.js +0 -26
- package/dist/esm/taskbar-elements-10d80c79.js +0 -112
- package/dist/sankhyablocks/p-1393dc00.entry.js +0 -1
- package/dist/sankhyablocks/p-1c17eecf.entry.js +0 -1
- package/dist/sankhyablocks/p-2ecf14ff.js +0 -1
- package/dist/sankhyablocks/p-340d6fb0.entry.js +0 -84
- package/dist/sankhyablocks/p-74724fa7.js +0 -1
- package/dist/sankhyablocks/p-79f01b63.entry.js +0 -1
- package/dist/sankhyablocks/p-81e85890.entry.js +0 -1
- package/dist/sankhyablocks/p-94e6fc90.entry.js +0 -1
- package/dist/sankhyablocks/p-98f7f796.js +0 -1
- package/dist/sankhyablocks/p-b3e71248.entry.js +0 -1
- package/dist/sankhyablocks/p-bc281de0.js +0 -1
- package/dist/sankhyablocks/p-d61759a5.entry.js +0 -1
- package/dist/sankhyablocks/p-d65809d5.entry.js +0 -1
- package/dist/sankhyablocks/p-f587a454.js +0 -1
- package/dist/types/components/snk-application/snk-application.d.ts +0 -259
- package/dist/types/components/snk-crud/snk-crud.d.ts +0 -73
- package/dist/types/components/snk-data-exporter/exporter-email-sender/snk-exporter-email-sender.d.ts +0 -40
- package/dist/types/components/snk-filter-bar/filter-item/editors/snk-filter-binary-select.d.ts +0 -27
- package/dist/types/components/snk-filter-bar/filter-item/editors/snk-filter-multi-select.d.ts +0 -23
- package/dist/types/components/snk-filter-bar/filter-item/editors/snk-filter-number.d.ts +0 -23
- package/dist/types/components/snk-filter-bar/filter-item/editors/snk-filter-period.d.ts +0 -29
- package/dist/types/components/snk-filter-bar/filter-item/editors/snk-filter-search.d.ts +0 -25
- package/dist/types/components/snk-filter-bar/filter-item/editors/snk-filter-text.d.ts +0 -19
- package/dist/types/components/snk-filter-bar/filter-item/snk-filter-detail.d.ts +0 -38
- package/dist/types/components/snk-filter-bar/filter-list/snk-filter-list.d.ts +0 -74
- package/dist/types/components/snk-filter-bar/filter-modal/snk-filter-modal.d.ts +0 -53
- package/dist/types/components/snk-grid/snk-grid.d.ts +0 -95
- package/dist/types/components/snk-simple-crud/snk-simple-crud.d.ts +0 -59
@@ -0,0 +1,26 @@
|
|
1
|
+
import { SavedRecord } from "@sankhyalabs/core";
|
2
|
+
import { ServiceBrokerPayload } from "../../../DataFetcher";
|
3
|
+
export type SavePayload = ServiceBrokerPayload<{
|
4
|
+
resourceID: string;
|
5
|
+
nuAttach?: string;
|
6
|
+
description: string;
|
7
|
+
fileSelect: number;
|
8
|
+
keySession?: string;
|
9
|
+
keyAttach?: string;
|
10
|
+
nameAttach?: string;
|
11
|
+
link?: string;
|
12
|
+
nameEntity: string;
|
13
|
+
pkEntity: string;
|
14
|
+
typeAcess: string;
|
15
|
+
typeApres: string;
|
16
|
+
}>;
|
17
|
+
export type SaveResponse = {
|
18
|
+
chave: {
|
19
|
+
valor: string;
|
20
|
+
};
|
21
|
+
} & SavedRecord;
|
22
|
+
export declare enum SaveErrorsEnum {
|
23
|
+
LINK_AND_FILE_AT_THE_SAME_TIME = "LINK_AND_FILE_AT_THE_SAME_TIME",
|
24
|
+
ANY_LINK_OR_FILE_FILLED = "ANY_LINK_OR_FILE_FILLED",
|
25
|
+
UNKNOWN = "UNKNOWN"
|
26
|
+
}
|
@@ -0,0 +1 @@
|
|
1
|
+
export declare const snkSimpleBarMessages: Object;
|
package/package.json
CHANGED
package/react/components.d.ts
CHANGED
@@ -1,6 +1,7 @@
|
|
1
1
|
/// <reference types="react" />
|
2
2
|
import type { JSX } from '@sankhyalabs/sankhyablocks';
|
3
3
|
export declare const SnkApplication: import("react").ForwardRefExoticComponent<JSX.SnkApplication & Omit<import("react").HTMLAttributes<HTMLSnkApplicationElement>, "style"> & import("./react-component-lib/interfaces").StyleReactProps & import("react").RefAttributes<HTMLSnkApplicationElement>>;
|
4
|
+
export declare const SnkAttach: import("react").ForwardRefExoticComponent<JSX.SnkAttach & Omit<import("react").HTMLAttributes<HTMLSnkAttachElement>, "style"> & import("./react-component-lib/interfaces").StyleReactProps & import("react").RefAttributes<HTMLSnkAttachElement>>;
|
4
5
|
export declare const SnkConfigOptions: import("react").ForwardRefExoticComponent<JSX.SnkConfigOptions & Omit<import("react").HTMLAttributes<HTMLSnkConfigOptionsElement>, "style"> & import("./react-component-lib/interfaces").StyleReactProps & import("react").RefAttributes<HTMLSnkConfigOptionsElement>>;
|
5
6
|
export declare const SnkConfigurator: import("react").ForwardRefExoticComponent<JSX.SnkConfigurator & Omit<import("react").HTMLAttributes<HTMLSnkConfiguratorElement>, "style"> & import("./react-component-lib/interfaces").StyleReactProps & import("react").RefAttributes<HTMLSnkConfiguratorElement>>;
|
6
7
|
export declare const SnkCrud: import("react").ForwardRefExoticComponent<JSX.SnkCrud & Omit<import("react").HTMLAttributes<HTMLSnkCrudElement>, "style"> & import("./react-component-lib/interfaces").StyleReactProps & import("react").RefAttributes<HTMLSnkCrudElement>>;
|
package/react/components.js
CHANGED
@@ -3,6 +3,7 @@
|
|
3
3
|
/* auto-generated react proxies */
|
4
4
|
import { createReactComponent } from './react-component-lib';
|
5
5
|
export const SnkApplication = /*@__PURE__*/ createReactComponent('snk-application');
|
6
|
+
export const SnkAttach = /*@__PURE__*/ createReactComponent('snk-attach');
|
6
7
|
export const SnkConfigOptions = /*@__PURE__*/ createReactComponent('snk-config-options');
|
7
8
|
export const SnkConfigurator = /*@__PURE__*/ createReactComponent('snk-configurator');
|
8
9
|
export const SnkCrud = /*@__PURE__*/ createReactComponent('snk-crud');
|
package/react/components.js.map
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"components.js","sourceRoot":"","sources":["../src/components.ts"],"names":[],"mappings":"AAAA,oBAAoB;AACpB,oBAAoB;AACpB,kCAAkC;AAClC,OAAO,EAAE,oBAAoB,EAAE,MAAM,uBAAuB,CAAC;AAM7D,MAAM,CAAC,MAAM,cAAc,GAAG,aAAa,CAAA,oBAAoB,CAAgD,iBAAiB,CAAC,CAAC;AAClI,MAAM,CAAC,MAAM,gBAAgB,GAAG,aAAa,CAAA,oBAAoB,CAAoD,oBAAoB,CAAC,CAAC;AAC3I,MAAM,CAAC,MAAM,eAAe,GAAG,aAAa,CAAA,oBAAoB,CAAkD,kBAAkB,CAAC,CAAC;AACtI,MAAM,CAAC,MAAM,OAAO,GAAG,aAAa,CAAA,oBAAoB,CAAkC,UAAU,CAAC,CAAC;AACtG,MAAM,CAAC,MAAM,eAAe,GAAG,aAAa,CAAA,oBAAoB,CAAkD,mB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
2
|
-
|
3
|
-
const index = require('./index-21bd01e1.js');
|
4
|
-
|
5
|
-
const appendToMap = (map, propName, value) => {
|
6
|
-
const items = map.get(propName);
|
7
|
-
if (!items) {
|
8
|
-
map.set(propName, [value]);
|
9
|
-
}
|
10
|
-
else if (!items.includes(value)) {
|
11
|
-
items.push(value);
|
12
|
-
}
|
13
|
-
};
|
14
|
-
const debounce = (fn, ms) => {
|
15
|
-
let timeoutId;
|
16
|
-
return (...args) => {
|
17
|
-
if (timeoutId) {
|
18
|
-
clearTimeout(timeoutId);
|
19
|
-
}
|
20
|
-
timeoutId = setTimeout(() => {
|
21
|
-
timeoutId = 0;
|
22
|
-
fn(...args);
|
23
|
-
}, ms);
|
24
|
-
};
|
25
|
-
};
|
26
|
-
|
27
|
-
/**
|
28
|
-
* Check if a possible element isConnected.
|
29
|
-
* The property might not be there, so we check for it.
|
30
|
-
*
|
31
|
-
* We want it to return true if isConnected is not a property,
|
32
|
-
* otherwise we would remove these elements and would not update.
|
33
|
-
*
|
34
|
-
* Better leak in Edge than to be useless.
|
35
|
-
*/
|
36
|
-
const isConnected = (maybeElement) => !('isConnected' in maybeElement) || maybeElement.isConnected;
|
37
|
-
const cleanupElements = debounce((map) => {
|
38
|
-
for (let key of map.keys()) {
|
39
|
-
map.set(key, map.get(key).filter(isConnected));
|
40
|
-
}
|
41
|
-
}, 2000);
|
42
|
-
const stencilSubscription = () => {
|
43
|
-
if (typeof index.getRenderingRef !== 'function') {
|
44
|
-
// If we are not in a stencil project, we do nothing.
|
45
|
-
// This function is not really exported by @stencil/core.
|
46
|
-
return {};
|
47
|
-
}
|
48
|
-
const elmsToUpdate = new Map();
|
49
|
-
return {
|
50
|
-
dispose: () => elmsToUpdate.clear(),
|
51
|
-
get: (propName) => {
|
52
|
-
const elm = index.getRenderingRef();
|
53
|
-
if (elm) {
|
54
|
-
appendToMap(elmsToUpdate, propName, elm);
|
55
|
-
}
|
56
|
-
},
|
57
|
-
set: (propName) => {
|
58
|
-
const elements = elmsToUpdate.get(propName);
|
59
|
-
if (elements) {
|
60
|
-
elmsToUpdate.set(propName, elements.filter(index.forceUpdate));
|
61
|
-
}
|
62
|
-
cleanupElements(elmsToUpdate);
|
63
|
-
},
|
64
|
-
reset: () => {
|
65
|
-
elmsToUpdate.forEach((elms) => elms.forEach(index.forceUpdate));
|
66
|
-
cleanupElements(elmsToUpdate);
|
67
|
-
},
|
68
|
-
};
|
69
|
-
};
|
70
|
-
|
71
|
-
const unwrap = (val) => (typeof val === 'function' ? val() : val);
|
72
|
-
const createObservableMap = (defaultState, shouldUpdate = (a, b) => a !== b) => {
|
73
|
-
const unwrappedState = unwrap(defaultState);
|
74
|
-
let states = new Map(Object.entries(unwrappedState !== null && unwrappedState !== void 0 ? unwrappedState : {}));
|
75
|
-
const handlers = {
|
76
|
-
dispose: [],
|
77
|
-
get: [],
|
78
|
-
set: [],
|
79
|
-
reset: [],
|
80
|
-
};
|
81
|
-
const reset = () => {
|
82
|
-
var _a;
|
83
|
-
// When resetting the state, the default state may be a function - unwrap it to invoke it.
|
84
|
-
// otherwise, the state won't be properly reset
|
85
|
-
states = new Map(Object.entries((_a = unwrap(defaultState)) !== null && _a !== void 0 ? _a : {}));
|
86
|
-
handlers.reset.forEach((cb) => cb());
|
87
|
-
};
|
88
|
-
const dispose = () => {
|
89
|
-
// Call first dispose as resetting the state would
|
90
|
-
// cause less updates ;)
|
91
|
-
handlers.dispose.forEach((cb) => cb());
|
92
|
-
reset();
|
93
|
-
};
|
94
|
-
const get = (propName) => {
|
95
|
-
handlers.get.forEach((cb) => cb(propName));
|
96
|
-
return states.get(propName);
|
97
|
-
};
|
98
|
-
const set = (propName, value) => {
|
99
|
-
const oldValue = states.get(propName);
|
100
|
-
if (shouldUpdate(value, oldValue, propName)) {
|
101
|
-
states.set(propName, value);
|
102
|
-
handlers.set.forEach((cb) => cb(propName, value, oldValue));
|
103
|
-
}
|
104
|
-
};
|
105
|
-
const state = (typeof Proxy === 'undefined'
|
106
|
-
? {}
|
107
|
-
: new Proxy(unwrappedState, {
|
108
|
-
get(_, propName) {
|
109
|
-
return get(propName);
|
110
|
-
},
|
111
|
-
ownKeys(_) {
|
112
|
-
return Array.from(states.keys());
|
113
|
-
},
|
114
|
-
getOwnPropertyDescriptor() {
|
115
|
-
return {
|
116
|
-
enumerable: true,
|
117
|
-
configurable: true,
|
118
|
-
};
|
119
|
-
},
|
120
|
-
has(_, propName) {
|
121
|
-
return states.has(propName);
|
122
|
-
},
|
123
|
-
set(_, propName, value) {
|
124
|
-
set(propName, value);
|
125
|
-
return true;
|
126
|
-
},
|
127
|
-
}));
|
128
|
-
const on = (eventName, callback) => {
|
129
|
-
handlers[eventName].push(callback);
|
130
|
-
return () => {
|
131
|
-
removeFromArray(handlers[eventName], callback);
|
132
|
-
};
|
133
|
-
};
|
134
|
-
const onChange = (propName, cb) => {
|
135
|
-
const unSet = on('set', (key, newValue) => {
|
136
|
-
if (key === propName) {
|
137
|
-
cb(newValue);
|
138
|
-
}
|
139
|
-
});
|
140
|
-
// We need to unwrap the defaultState because it might be a function.
|
141
|
-
// Otherwise we might not be sending the right reset value.
|
142
|
-
const unReset = on('reset', () => cb(unwrap(defaultState)[propName]));
|
143
|
-
return () => {
|
144
|
-
unSet();
|
145
|
-
unReset();
|
146
|
-
};
|
147
|
-
};
|
148
|
-
const use = (...subscriptions) => {
|
149
|
-
const unsubs = subscriptions.reduce((unsubs, subscription) => {
|
150
|
-
if (subscription.set) {
|
151
|
-
unsubs.push(on('set', subscription.set));
|
152
|
-
}
|
153
|
-
if (subscription.get) {
|
154
|
-
unsubs.push(on('get', subscription.get));
|
155
|
-
}
|
156
|
-
if (subscription.reset) {
|
157
|
-
unsubs.push(on('reset', subscription.reset));
|
158
|
-
}
|
159
|
-
if (subscription.dispose) {
|
160
|
-
unsubs.push(on('dispose', subscription.dispose));
|
161
|
-
}
|
162
|
-
return unsubs;
|
163
|
-
}, []);
|
164
|
-
return () => unsubs.forEach((unsub) => unsub());
|
165
|
-
};
|
166
|
-
const forceUpdate = (key) => {
|
167
|
-
const oldValue = states.get(key);
|
168
|
-
handlers.set.forEach((cb) => cb(key, oldValue, oldValue));
|
169
|
-
};
|
170
|
-
return {
|
171
|
-
state,
|
172
|
-
get,
|
173
|
-
set,
|
174
|
-
on,
|
175
|
-
onChange,
|
176
|
-
use,
|
177
|
-
dispose,
|
178
|
-
reset,
|
179
|
-
forceUpdate,
|
180
|
-
};
|
181
|
-
};
|
182
|
-
const removeFromArray = (array, item) => {
|
183
|
-
const index = array.indexOf(item);
|
184
|
-
if (index >= 0) {
|
185
|
-
array[index] = array[array.length - 1];
|
186
|
-
array.length--;
|
187
|
-
}
|
188
|
-
};
|
189
|
-
|
190
|
-
const createStore = (defaultState, shouldUpdate) => {
|
191
|
-
const map = createObservableMap(defaultState, shouldUpdate);
|
192
|
-
map.use(stencilSubscription());
|
193
|
-
return map;
|
194
|
-
};
|
195
|
-
|
196
|
-
const store = createStore({
|
197
|
-
exporterProviders: {}
|
198
|
-
});
|
199
|
-
|
200
|
-
exports.store = store;
|
@@ -1,30 +0,0 @@
|
|
1
|
-
'use strict';
|
2
|
-
|
3
|
-
Object.defineProperty(exports, '__esModule', { value: true });
|
4
|
-
|
5
|
-
const index = require('./index-21bd01e1.js');
|
6
|
-
const core = require('@sankhyalabs/core');
|
7
|
-
|
8
|
-
const snkSimpleBarCss = ".sc-snk-simple-bar-h{display:flex;height:100%;width:100%}.simple-bar__container.sc-snk-simple-bar{flex:1;display:flex;align-items:stretch;gap:var(--space--small)}.simple-bar__left-slot.sc-snk-simple-bar{min-width:280px;flex:1;display:flex;align-items:center}.simple-bar__right-slot.sc-snk-simple-bar{flex:1;display:flex;align-items:center;justify-content:flex-end}.simple-bar__column.sc-snk-simple-bar{flex:1;display:flex;flex-direction:column}";
|
9
|
-
|
10
|
-
const SnkSimpleBar = class {
|
11
|
-
constructor(hostRef) {
|
12
|
-
index.registerInstance(this, hostRef);
|
13
|
-
this.clickBreadcrumbItem = index.createEvent(this, "clickBreadcrumbItem", 3);
|
14
|
-
this.exit = index.createEvent(this, "exit", 3);
|
15
|
-
this.label = undefined;
|
16
|
-
this.breadcrumbItens = undefined;
|
17
|
-
}
|
18
|
-
componentDidLoad() {
|
19
|
-
if (!this._element)
|
20
|
-
return;
|
21
|
-
core.ElementIDUtils.addIDInfo(this._element);
|
22
|
-
}
|
23
|
-
render() {
|
24
|
-
return (index.h("div", { class: "simple-bar__container ez-margin-vertical--medium ez-padding--extra-small" }, index.h("div", { class: "simple-bar__left-slot" }, index.h("ez-button", { class: "ez-padding-right--medium", mode: 'icon', iconName: "arrow_back", size: 'medium', onClick: () => this.exit.emit() }), index.h("div", { class: "simple-bar__column" }, index.h("h1", { class: "ez-title ez-title--primary ez-title--extra-large" }, this.label), index.h("ez-breadcrumb", { items: this.breadcrumbItens, onSelectedItem: ({ detail }) => this.clickBreadcrumbItem.emit(detail) }))), index.h("div", { class: "simple-bar__right-slot" }, index.h("slot", { name: "rightSlot" }))));
|
25
|
-
}
|
26
|
-
get _element() { return index.getElement(this); }
|
27
|
-
};
|
28
|
-
SnkSimpleBar.style = snkSimpleBarCss;
|
29
|
-
|
30
|
-
exports.snk_simple_bar = SnkSimpleBar;
|
@@ -1,115 +0,0 @@
|
|
1
|
-
'use strict';
|
2
|
-
|
3
|
-
const index = require('./index-21bd01e1.js');
|
4
|
-
const index$2 = require('./index-f400b1d6.js');
|
5
|
-
const index$1 = require('./index-fc7ca86c.js');
|
6
|
-
|
7
|
-
exports.TaskbarElement = void 0;
|
8
|
-
(function (TaskbarElement) {
|
9
|
-
TaskbarElement["PREVIOUS"] = "PREVIOUS";
|
10
|
-
TaskbarElement["NEXT"] = "NEXT";
|
11
|
-
TaskbarElement["REFRESH"] = "REFRESH";
|
12
|
-
TaskbarElement["UPDATE"] = "UPDATE";
|
13
|
-
TaskbarElement["CLONE"] = "CLONE";
|
14
|
-
TaskbarElement["REMOVE"] = "REMOVE";
|
15
|
-
TaskbarElement["INSERT"] = "INSERT";
|
16
|
-
TaskbarElement["CANCEL"] = "CANCEL";
|
17
|
-
TaskbarElement["SAVE"] = "SAVE";
|
18
|
-
TaskbarElement["GRID_MODE"] = "GRID_MODE";
|
19
|
-
TaskbarElement["FORM_MODE"] = "FORM_MODE";
|
20
|
-
TaskbarElement["MORE_OPTIONS"] = "MORE_OPTIONS";
|
21
|
-
TaskbarElement["DIVIDER"] = "DIVIDER";
|
22
|
-
TaskbarElement["CONFIGURATOR"] = "CONFIGURATOR";
|
23
|
-
TaskbarElement["DATA_EXPORTER"] = "DATA_EXPORTER";
|
24
|
-
})(exports.TaskbarElement || (exports.TaskbarElement = {}));
|
25
|
-
exports.AuthorizationElements = void 0;
|
26
|
-
(function (AuthorizationElements) {
|
27
|
-
AuthorizationElements["UPDATE"] = "UPDATE";
|
28
|
-
AuthorizationElements["CLONE"] = "CLONE";
|
29
|
-
AuthorizationElements["REMOVE"] = "REMOVE";
|
30
|
-
AuthorizationElements["INSERT"] = "INSERT";
|
31
|
-
AuthorizationElements["CONFIGURATOR"] = "CONFIGURATOR";
|
32
|
-
})(exports.AuthorizationElements || (exports.AuthorizationElements = {}));
|
33
|
-
exports.VisibleWhenForbidden = void 0;
|
34
|
-
(function (VisibleWhenForbidden) {
|
35
|
-
VisibleWhenForbidden["CONFIGURATOR"] = "CONFIGURATOR";
|
36
|
-
})(exports.VisibleWhenForbidden || (exports.VisibleWhenForbidden = {}));
|
37
|
-
const buildCustomButton = (def, className, dataElementId, action, isEnabled) => {
|
38
|
-
const { hint, text, iconName } = def;
|
39
|
-
if (iconName) {
|
40
|
-
if (text) {
|
41
|
-
return iconTextButton(iconName, def.name, className, dataElementId, hint, text, action, isEnabled);
|
42
|
-
}
|
43
|
-
else {
|
44
|
-
return iconButton(iconName, def.name, className, dataElementId, hint, action, isEnabled);
|
45
|
-
}
|
46
|
-
}
|
47
|
-
else {
|
48
|
-
return textButton(def.name, className, dataElementId, text, hint, action, isEnabled);
|
49
|
-
}
|
50
|
-
};
|
51
|
-
const buildElem = (element, className, dataElementId, getTitle, action, isEnabled, actions, configName, presentationMode) => {
|
52
|
-
var _a;
|
53
|
-
const title = getTitle(element);
|
54
|
-
switch (element) {
|
55
|
-
case exports.TaskbarElement.PREVIOUS:
|
56
|
-
return iconButton("chevron-left", element, className, dataElementId, title, action, isEnabled);
|
57
|
-
case exports.TaskbarElement.NEXT:
|
58
|
-
return iconButton("chevron-right", element, className, dataElementId, title, action, isEnabled);
|
59
|
-
case exports.TaskbarElement.REFRESH:
|
60
|
-
return iconButton("sync", element, className, dataElementId, title, action, isEnabled);
|
61
|
-
case exports.TaskbarElement.UPDATE:
|
62
|
-
return iconButton("edit", element, className, dataElementId, title, action, isEnabled);
|
63
|
-
case exports.TaskbarElement.CLONE:
|
64
|
-
return iconButton("copy", element, className, dataElementId, title, action, isEnabled);
|
65
|
-
case exports.TaskbarElement.REMOVE:
|
66
|
-
return iconButton("delete", element, className, dataElementId, title, action, isEnabled);
|
67
|
-
case exports.TaskbarElement.INSERT:
|
68
|
-
if (presentationMode === index$2.PresentationMode.PRIMARY) {
|
69
|
-
return iconTextButton("plus", element, className, dataElementId, title, title, action, isEnabled);
|
70
|
-
}
|
71
|
-
else {
|
72
|
-
return iconButton("plus", element, className, dataElementId, title, action, isEnabled);
|
73
|
-
}
|
74
|
-
case exports.TaskbarElement.CANCEL:
|
75
|
-
return textButton(element, className, dataElementId, title, title, action, isEnabled);
|
76
|
-
case exports.TaskbarElement.SAVE:
|
77
|
-
if (presentationMode === index$2.PresentationMode.PRIMARY) {
|
78
|
-
return iconTextButton("save", element, className, dataElementId, title, title, action, isEnabled);
|
79
|
-
}
|
80
|
-
else {
|
81
|
-
return iconButton("save", element, className, dataElementId, title, action, isEnabled);
|
82
|
-
}
|
83
|
-
case exports.TaskbarElement.GRID_MODE:
|
84
|
-
return iconButton("table", element, className, dataElementId, title, action, isEnabled);
|
85
|
-
case exports.TaskbarElement.FORM_MODE:
|
86
|
-
return iconButton("list", element, className, dataElementId, title, action, isEnabled);
|
87
|
-
case exports.TaskbarElement.CONFIGURATOR:
|
88
|
-
return iconButton("settings-inverted", element, className, dataElementId, title, action, isEnabled);
|
89
|
-
case exports.TaskbarElement.MORE_OPTIONS:
|
90
|
-
return actionButton(element, className, dataElementId, title, action, isEnabled, actions);
|
91
|
-
case exports.TaskbarElement.DIVIDER:
|
92
|
-
return index.h("hr", { class: "ez-divider-vertical ez-divider--dark ez-margin-horizontal--medium", "data-taskbar-divider": true });
|
93
|
-
case exports.TaskbarElement.DATA_EXPORTER:
|
94
|
-
const provider = (_a = index$1.store.get("exporterProviders")) === null || _a === void 0 ? void 0 : _a[configName];
|
95
|
-
return index.h("snk-data-exporter", { class: className, provider: provider, "data-element-id": dataElementId });
|
96
|
-
}
|
97
|
-
};
|
98
|
-
function textButton(name, className, dataElementId, text, title, action, isEnabled) {
|
99
|
-
return index.h("ez-button", { title: title, label: text, size: "small", class: className, "data-element-id": dataElementId, enabled: isEnabled(name), onClick: () => action(name) });
|
100
|
-
}
|
101
|
-
function iconButton(iconName, name, className, dataElementId, title, action, isEnabled) {
|
102
|
-
return index.h("ez-button", { title: title, mode: "icon", size: "small", class: className, "data-element-id": dataElementId, iconName: iconName, enabled: isEnabled(name), onClick: () => action(name) });
|
103
|
-
}
|
104
|
-
function iconTextButton(iconName, name, className, dataElementId, text, title, action, isEnabled) {
|
105
|
-
return index.h("ez-button", { title: title, label: text, size: "small", class: className, "data-element-id": dataElementId, enabled: isEnabled(name), onClick: () => action(name) },
|
106
|
-
index.h("ez-icon", { class: "ez-padding-right--small", slot: "leftIcon", iconName: iconName }));
|
107
|
-
}
|
108
|
-
function actionButton(element, className, dataElementId, title, action, isEnabled, actions) {
|
109
|
-
return actions && actions.length > 0
|
110
|
-
? index.h("ez-actions-button", { title: title, size: "small", "data-element-id": dataElementId, arrowActive: true, class: className, enabled: isEnabled(element), onEzAction: (evt) => action(evt.detail.value), actions: actions })
|
111
|
-
: undefined;
|
112
|
-
}
|
113
|
-
|
114
|
-
exports.buildCustomButton = buildCustomButton;
|
115
|
-
exports.buildElem = buildElem;
|
@@ -1,198 +0,0 @@
|
|
1
|
-
import { a as getRenderingRef, f as forceUpdate } from './index-cfd4bb13.js';
|
2
|
-
|
3
|
-
const appendToMap = (map, propName, value) => {
|
4
|
-
const items = map.get(propName);
|
5
|
-
if (!items) {
|
6
|
-
map.set(propName, [value]);
|
7
|
-
}
|
8
|
-
else if (!items.includes(value)) {
|
9
|
-
items.push(value);
|
10
|
-
}
|
11
|
-
};
|
12
|
-
const debounce = (fn, ms) => {
|
13
|
-
let timeoutId;
|
14
|
-
return (...args) => {
|
15
|
-
if (timeoutId) {
|
16
|
-
clearTimeout(timeoutId);
|
17
|
-
}
|
18
|
-
timeoutId = setTimeout(() => {
|
19
|
-
timeoutId = 0;
|
20
|
-
fn(...args);
|
21
|
-
}, ms);
|
22
|
-
};
|
23
|
-
};
|
24
|
-
|
25
|
-
/**
|
26
|
-
* Check if a possible element isConnected.
|
27
|
-
* The property might not be there, so we check for it.
|
28
|
-
*
|
29
|
-
* We want it to return true if isConnected is not a property,
|
30
|
-
* otherwise we would remove these elements and would not update.
|
31
|
-
*
|
32
|
-
* Better leak in Edge than to be useless.
|
33
|
-
*/
|
34
|
-
const isConnected = (maybeElement) => !('isConnected' in maybeElement) || maybeElement.isConnected;
|
35
|
-
const cleanupElements = debounce((map) => {
|
36
|
-
for (let key of map.keys()) {
|
37
|
-
map.set(key, map.get(key).filter(isConnected));
|
38
|
-
}
|
39
|
-
}, 2000);
|
40
|
-
const stencilSubscription = () => {
|
41
|
-
if (typeof getRenderingRef !== 'function') {
|
42
|
-
// If we are not in a stencil project, we do nothing.
|
43
|
-
// This function is not really exported by @stencil/core.
|
44
|
-
return {};
|
45
|
-
}
|
46
|
-
const elmsToUpdate = new Map();
|
47
|
-
return {
|
48
|
-
dispose: () => elmsToUpdate.clear(),
|
49
|
-
get: (propName) => {
|
50
|
-
const elm = getRenderingRef();
|
51
|
-
if (elm) {
|
52
|
-
appendToMap(elmsToUpdate, propName, elm);
|
53
|
-
}
|
54
|
-
},
|
55
|
-
set: (propName) => {
|
56
|
-
const elements = elmsToUpdate.get(propName);
|
57
|
-
if (elements) {
|
58
|
-
elmsToUpdate.set(propName, elements.filter(forceUpdate));
|
59
|
-
}
|
60
|
-
cleanupElements(elmsToUpdate);
|
61
|
-
},
|
62
|
-
reset: () => {
|
63
|
-
elmsToUpdate.forEach((elms) => elms.forEach(forceUpdate));
|
64
|
-
cleanupElements(elmsToUpdate);
|
65
|
-
},
|
66
|
-
};
|
67
|
-
};
|
68
|
-
|
69
|
-
const unwrap = (val) => (typeof val === 'function' ? val() : val);
|
70
|
-
const createObservableMap = (defaultState, shouldUpdate = (a, b) => a !== b) => {
|
71
|
-
const unwrappedState = unwrap(defaultState);
|
72
|
-
let states = new Map(Object.entries(unwrappedState !== null && unwrappedState !== void 0 ? unwrappedState : {}));
|
73
|
-
const handlers = {
|
74
|
-
dispose: [],
|
75
|
-
get: [],
|
76
|
-
set: [],
|
77
|
-
reset: [],
|
78
|
-
};
|
79
|
-
const reset = () => {
|
80
|
-
var _a;
|
81
|
-
// When resetting the state, the default state may be a function - unwrap it to invoke it.
|
82
|
-
// otherwise, the state won't be properly reset
|
83
|
-
states = new Map(Object.entries((_a = unwrap(defaultState)) !== null && _a !== void 0 ? _a : {}));
|
84
|
-
handlers.reset.forEach((cb) => cb());
|
85
|
-
};
|
86
|
-
const dispose = () => {
|
87
|
-
// Call first dispose as resetting the state would
|
88
|
-
// cause less updates ;)
|
89
|
-
handlers.dispose.forEach((cb) => cb());
|
90
|
-
reset();
|
91
|
-
};
|
92
|
-
const get = (propName) => {
|
93
|
-
handlers.get.forEach((cb) => cb(propName));
|
94
|
-
return states.get(propName);
|
95
|
-
};
|
96
|
-
const set = (propName, value) => {
|
97
|
-
const oldValue = states.get(propName);
|
98
|
-
if (shouldUpdate(value, oldValue, propName)) {
|
99
|
-
states.set(propName, value);
|
100
|
-
handlers.set.forEach((cb) => cb(propName, value, oldValue));
|
101
|
-
}
|
102
|
-
};
|
103
|
-
const state = (typeof Proxy === 'undefined'
|
104
|
-
? {}
|
105
|
-
: new Proxy(unwrappedState, {
|
106
|
-
get(_, propName) {
|
107
|
-
return get(propName);
|
108
|
-
},
|
109
|
-
ownKeys(_) {
|
110
|
-
return Array.from(states.keys());
|
111
|
-
},
|
112
|
-
getOwnPropertyDescriptor() {
|
113
|
-
return {
|
114
|
-
enumerable: true,
|
115
|
-
configurable: true,
|
116
|
-
};
|
117
|
-
},
|
118
|
-
has(_, propName) {
|
119
|
-
return states.has(propName);
|
120
|
-
},
|
121
|
-
set(_, propName, value) {
|
122
|
-
set(propName, value);
|
123
|
-
return true;
|
124
|
-
},
|
125
|
-
}));
|
126
|
-
const on = (eventName, callback) => {
|
127
|
-
handlers[eventName].push(callback);
|
128
|
-
return () => {
|
129
|
-
removeFromArray(handlers[eventName], callback);
|
130
|
-
};
|
131
|
-
};
|
132
|
-
const onChange = (propName, cb) => {
|
133
|
-
const unSet = on('set', (key, newValue) => {
|
134
|
-
if (key === propName) {
|
135
|
-
cb(newValue);
|
136
|
-
}
|
137
|
-
});
|
138
|
-
// We need to unwrap the defaultState because it might be a function.
|
139
|
-
// Otherwise we might not be sending the right reset value.
|
140
|
-
const unReset = on('reset', () => cb(unwrap(defaultState)[propName]));
|
141
|
-
return () => {
|
142
|
-
unSet();
|
143
|
-
unReset();
|
144
|
-
};
|
145
|
-
};
|
146
|
-
const use = (...subscriptions) => {
|
147
|
-
const unsubs = subscriptions.reduce((unsubs, subscription) => {
|
148
|
-
if (subscription.set) {
|
149
|
-
unsubs.push(on('set', subscription.set));
|
150
|
-
}
|
151
|
-
if (subscription.get) {
|
152
|
-
unsubs.push(on('get', subscription.get));
|
153
|
-
}
|
154
|
-
if (subscription.reset) {
|
155
|
-
unsubs.push(on('reset', subscription.reset));
|
156
|
-
}
|
157
|
-
if (subscription.dispose) {
|
158
|
-
unsubs.push(on('dispose', subscription.dispose));
|
159
|
-
}
|
160
|
-
return unsubs;
|
161
|
-
}, []);
|
162
|
-
return () => unsubs.forEach((unsub) => unsub());
|
163
|
-
};
|
164
|
-
const forceUpdate = (key) => {
|
165
|
-
const oldValue = states.get(key);
|
166
|
-
handlers.set.forEach((cb) => cb(key, oldValue, oldValue));
|
167
|
-
};
|
168
|
-
return {
|
169
|
-
state,
|
170
|
-
get,
|
171
|
-
set,
|
172
|
-
on,
|
173
|
-
onChange,
|
174
|
-
use,
|
175
|
-
dispose,
|
176
|
-
reset,
|
177
|
-
forceUpdate,
|
178
|
-
};
|
179
|
-
};
|
180
|
-
const removeFromArray = (array, item) => {
|
181
|
-
const index = array.indexOf(item);
|
182
|
-
if (index >= 0) {
|
183
|
-
array[index] = array[array.length - 1];
|
184
|
-
array.length--;
|
185
|
-
}
|
186
|
-
};
|
187
|
-
|
188
|
-
const createStore = (defaultState, shouldUpdate) => {
|
189
|
-
const map = createObservableMap(defaultState, shouldUpdate);
|
190
|
-
map.use(stencilSubscription());
|
191
|
-
return map;
|
192
|
-
};
|
193
|
-
|
194
|
-
const store = createStore({
|
195
|
-
exporterProviders: {}
|
196
|
-
});
|
197
|
-
|
198
|
-
export { store as s };
|
@@ -1,26 +0,0 @@
|
|
1
|
-
import { r as registerInstance, c as createEvent, h, g as getElement } from './index-cfd4bb13.js';
|
2
|
-
import { ElementIDUtils } from '@sankhyalabs/core';
|
3
|
-
|
4
|
-
const snkSimpleBarCss = ".sc-snk-simple-bar-h{display:flex;height:100%;width:100%}.simple-bar__container.sc-snk-simple-bar{flex:1;display:flex;align-items:stretch;gap:var(--space--small)}.simple-bar__left-slot.sc-snk-simple-bar{min-width:280px;flex:1;display:flex;align-items:center}.simple-bar__right-slot.sc-snk-simple-bar{flex:1;display:flex;align-items:center;justify-content:flex-end}.simple-bar__column.sc-snk-simple-bar{flex:1;display:flex;flex-direction:column}";
|
5
|
-
|
6
|
-
const SnkSimpleBar = class {
|
7
|
-
constructor(hostRef) {
|
8
|
-
registerInstance(this, hostRef);
|
9
|
-
this.clickBreadcrumbItem = createEvent(this, "clickBreadcrumbItem", 3);
|
10
|
-
this.exit = createEvent(this, "exit", 3);
|
11
|
-
this.label = undefined;
|
12
|
-
this.breadcrumbItens = undefined;
|
13
|
-
}
|
14
|
-
componentDidLoad() {
|
15
|
-
if (!this._element)
|
16
|
-
return;
|
17
|
-
ElementIDUtils.addIDInfo(this._element);
|
18
|
-
}
|
19
|
-
render() {
|
20
|
-
return (h("div", { class: "simple-bar__container ez-margin-vertical--medium ez-padding--extra-small" }, h("div", { class: "simple-bar__left-slot" }, h("ez-button", { class: "ez-padding-right--medium", mode: 'icon', iconName: "arrow_back", size: 'medium', onClick: () => this.exit.emit() }), h("div", { class: "simple-bar__column" }, h("h1", { class: "ez-title ez-title--primary ez-title--extra-large" }, this.label), h("ez-breadcrumb", { items: this.breadcrumbItens, onSelectedItem: ({ detail }) => this.clickBreadcrumbItem.emit(detail) }))), h("div", { class: "simple-bar__right-slot" }, h("slot", { name: "rightSlot" }))));
|
21
|
-
}
|
22
|
-
get _element() { return getElement(this); }
|
23
|
-
};
|
24
|
-
SnkSimpleBar.style = snkSimpleBarCss;
|
25
|
-
|
26
|
-
export { SnkSimpleBar as snk_simple_bar };
|