@endge/ui-vue 0.23.3

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.
Files changed (79) hide show
  1. package/LICENSE +201 -0
  2. package/dist/domain/core/endge-vue.d.ts +22 -0
  3. package/dist/domain/types/filter-renderer.type.d.ts +5 -0
  4. package/dist/domain/types/sfc-render.type.d.ts +143 -0
  5. package/dist/edit.utils-Dnnbd0xG-D9ndNtVP.js +51 -0
  6. package/dist/events-BvSmBueA-Doh7RyHn.js +23 -0
  7. package/dist/main-CQv-nkoD.js +19453 -0
  8. package/dist/main.d.ts +42 -0
  9. package/dist/model/render/sfc/SFCVueRenderInspection.d.ts +12 -0
  10. package/dist/model/render/sfc/SFCVueRuntimeBridge.d.ts +43 -0
  11. package/dist/model/render/sfc/native-vue-sfc-adapter.d.ts +4 -0
  12. package/dist/model/style/EndgeDOMStyleRuntime.d.ts +10 -0
  13. package/dist/model/style/endge-dom-style.d.ts +17 -0
  14. package/dist/model/style/index.d.ts +2 -0
  15. package/dist/reactive/use-current-environment.d.ts +8 -0
  16. package/dist/reactive/use-current-locale.d.ts +8 -0
  17. package/dist/reactive/use-current-project-filter.d.ts +8 -0
  18. package/dist/reactive/use-current-theme.d.ts +8 -0
  19. package/dist/reactive/use-ui.d.ts +3 -0
  20. package/dist/revo-grid.entry-BAwst49a.js +1615 -0
  21. package/dist/revogr-attribution_7.entry-BMG7pXkt.js +967 -0
  22. package/dist/revogr-clipboard_3.entry-BRLLR59Q.js +334 -0
  23. package/dist/revogr-data_4.entry-D1ndZEok.js +745 -0
  24. package/dist/revogr-filter-panel.entry-C-xzIppO.js +329 -0
  25. package/dist/store/domain.d.ts +91 -0
  26. package/dist/test/overlay/context-menu-manager.test.d.ts +1 -0
  27. package/dist/test/sfc/EndgeVueAdapter.test.d.ts +1 -0
  28. package/dist/test/sfc/SFCRender_Component.test.d.ts +1 -0
  29. package/dist/test/sfc/SFCRender_Evaluator.test.d.ts +1 -0
  30. package/dist/test/sfc/SFCRender_FormControls.test.d.ts +1 -0
  31. package/dist/test/sfc/SFCRender_Grid.test.d.ts +1 -0
  32. package/dist/test/sfc/SFCRender_IntrinsicEvents.test.d.ts +1 -0
  33. package/dist/test/sfc/SFCRender_TableAlignment.test.d.ts +1 -0
  34. package/dist/test/sfc/SFCRender_TableLayout.test.d.ts +1 -0
  35. package/dist/test/sfc/SFCRender_TableVisibility.test.d.ts +1 -0
  36. package/dist/test/sfc/SFCVueRenderInspection.test.d.ts +1 -0
  37. package/dist/test/style/endge-dom-runtime-placement.test.d.ts +1 -0
  38. package/dist/test/style/endge-dom-style-jsdom.test.d.ts +1 -0
  39. package/dist/test/style/endge-dom-style.test.d.ts +1 -0
  40. package/dist/test/style/sfc-style-markers.test.d.ts +1 -0
  41. package/dist/throttle-Cpk1LoGk-5dM_0aHc.js +183 -0
  42. package/dist/ui/filter/EndgeFilterControlRenderer.d.ts +33 -0
  43. package/dist/ui/filter/EndgeFilterField.vue.d.ts +13 -0
  44. package/dist/ui/filter/EndgeFilterRenderer.vue.d.ts +3 -0
  45. package/dist/ui/filter/index.d.ts +2 -0
  46. package/dist/ui/layout/EndgeShell.vue.d.ts +22 -0
  47. package/dist/ui/overlay/EndgeContextMenuRoot.vue.d.ts +4 -0
  48. package/dist/ui/overlay/context-menu-manager.d.ts +46 -0
  49. package/dist/ui/render/entities/EndgePage.vue.d.ts +1852 -0
  50. package/dist/ui/render/sfc/SFCRender_Badge.d.ts +3 -0
  51. package/dist/ui/render/sfc/SFCRender_Base.d.ts +8 -0
  52. package/dist/ui/render/sfc/SFCRender_BoundaryRegistry.d.ts +15 -0
  53. package/dist/ui/render/sfc/SFCRender_Box.d.ts +3 -0
  54. package/dist/ui/render/sfc/SFCRender_Checkbox.d.ts +3 -0
  55. package/dist/ui/render/sfc/SFCRender_Component.d.ts +3 -0
  56. package/dist/ui/render/sfc/SFCRender_Context.d.ts +8 -0
  57. package/dist/ui/render/sfc/SFCRender_DateTime.d.ts +3 -0
  58. package/dist/ui/render/sfc/SFCRender_Divider.d.ts +3 -0
  59. package/dist/ui/render/sfc/SFCRender_Dot.d.ts +3 -0
  60. package/dist/ui/render/sfc/SFCRender_Evaluator.d.ts +19 -0
  61. package/dist/ui/render/sfc/SFCRender_Flex.d.ts +3 -0
  62. package/dist/ui/render/sfc/SFCRender_Grid.d.ts +3 -0
  63. package/dist/ui/render/sfc/SFCRender_Icon.d.ts +3 -0
  64. package/dist/ui/render/sfc/SFCRender_Input.d.ts +3 -0
  65. package/dist/ui/render/sfc/SFCRender_Node.d.ts +6 -0
  66. package/dist/ui/render/sfc/SFCRender_Number.d.ts +3 -0
  67. package/dist/ui/render/sfc/SFCRender_Select.d.ts +3 -0
  68. package/dist/ui/render/sfc/SFCRender_Table.d.ts +9 -0
  69. package/dist/ui/render/sfc/SFCRender_TableAlignment.d.ts +8 -0
  70. package/dist/ui/render/sfc/SFCRender_TableStyle.d.ts +35 -0
  71. package/dist/ui/render/sfc/SFCRender_Text.d.ts +3 -0
  72. package/dist/ui/render/sfc/SFCRender_Textarea.d.ts +3 -0
  73. package/dist/ui/render/sfc/SFC_Renderer.vue.d.ts +3 -0
  74. package/dist/ui/render/sfc/SFC_RuntimeRenderer.vue.d.ts +3 -0
  75. package/dist/ui/table/NativeTablePagination.vue.d.ts +15 -0
  76. package/dist/viewport.helpers-CoCAvmZs-f555rwPU.js +77 -0
  77. package/dist/vue.css +1 -0
  78. package/dist/vue.js +75 -0
  79. package/package.json +77 -0
@@ -0,0 +1,183 @@
1
+ import { g as h } from "./viewport.helpers-CoCAvmZs-f555rwPU.js";
2
+ import { as as d, l as m } from "./main-CQv-nkoD.js";
3
+ /*!
4
+ * Built by Revolist OU ❤️
5
+ */
6
+ const c = {
7
+ contentSize: 0,
8
+ clientSize: 0,
9
+ virtualSize: 0,
10
+ maxSize: 0
11
+ }, e = -1;
12
+ function C(a, i, t = 0) {
13
+ return h({
14
+ contentSize: a,
15
+ clientSize: i,
16
+ virtualSize: t
17
+ }).physicalContentSize;
18
+ }
19
+ class v {
20
+ constructor(i) {
21
+ this.cfg = i, this.preventArtificialScroll = {
22
+ rgRow: null,
23
+ rgCol: null
24
+ }, this.previousScroll = {
25
+ rgRow: e,
26
+ rgCol: e
27
+ }, this.previousLogicalScroll = {
28
+ rgRow: 0,
29
+ rgCol: 0
30
+ }, this.params = {
31
+ rgRow: Object.assign({}, c),
32
+ rgCol: Object.assign({}, c)
33
+ };
34
+ }
35
+ setParams(i, t) {
36
+ const o = h(i), l = o.physicalContentSize;
37
+ this.params[t] = Object.assign(Object.assign({}, i), {
38
+ maxSize: l - i.clientSize,
39
+ virtualContentSize: l,
40
+ scrollDimension: o
41
+ });
42
+ }
43
+ // apply scroll values after scroll done
44
+ async setScroll(i) {
45
+ this.cancelScroll(i.dimension);
46
+ const t = new Promise((o, l) => {
47
+ if (this.cfg.skipAnimationFrame)
48
+ return o();
49
+ const r = window.requestAnimationFrame(() => {
50
+ o();
51
+ });
52
+ this.preventArtificialScroll[i.dimension] = l.bind(null, r);
53
+ });
54
+ try {
55
+ await t;
56
+ const o = this.getParams(i.dimension);
57
+ i.coordinate = Math.ceil(i.coordinate), this.previousLogicalScroll[i.dimension] = this.wrapLogicalCoordinate(i.coordinate, o);
58
+ const l = this.toPhysicalCoordinate(i.coordinate, o);
59
+ this.previousScroll[i.dimension] = this.wrapPhysicalCoordinate(l, o), this.preventArtificialScroll[i.dimension] = null, this.cfg.applyScroll(Object.assign(Object.assign({}, i), { coordinate: l }));
60
+ } catch (o) {
61
+ window.cancelAnimationFrame(o);
62
+ }
63
+ }
64
+ async setScrollByDelta(i, t) {
65
+ var o;
66
+ const l = this.getParams(i.dimension), r = this.previousScroll[i.dimension] === e ? this.toLogicalCoordinate(t, l) : this.previousLogicalScroll[i.dimension], s = this.wrapLogicalCoordinate(r + ((o = i.delta) !== null && o !== void 0 ? o : 0), l), n = Object.assign(Object.assign({}, i), { coordinate: s });
67
+ return await this.setScroll(n), n;
68
+ }
69
+ /**
70
+ * On scroll event started
71
+ */
72
+ scroll(i, t, o = !1, l, r = !1) {
73
+ if (this.cancelScroll(t), !o && this.previousScroll[t] === i) {
74
+ this.previousScroll[t] = e;
75
+ return;
76
+ }
77
+ const s = this.getParams(t), n = this.toLogicalScrollCoordinate(i, t, s, l);
78
+ this.cfg.runScroll({
79
+ dimension: t,
80
+ coordinate: n,
81
+ delta: l,
82
+ outside: r
83
+ }), this.previousLogicalScroll[t] = n;
84
+ }
85
+ getParams(i) {
86
+ return this.params[i];
87
+ }
88
+ // check if scroll outside of region to avoid looping
89
+ wrapPhysicalCoordinate(i, t) {
90
+ return i < 0 ? e : typeof t.maxSize == "number" && i > t.maxSize ? t.maxSize : i;
91
+ }
92
+ wrapLogicalCoordinate(i, t) {
93
+ var o, l;
94
+ return i < 0 ? 0 : Math.min(i, (l = (o = t.scrollDimension) === null || o === void 0 ? void 0 : o.logicalScrollSize) !== null && l !== void 0 ? l : i);
95
+ }
96
+ // prevent already started scroll, performance optimization
97
+ cancelScroll(i) {
98
+ var t, o;
99
+ (o = (t = this.preventArtificialScroll)[i]) === null || o === void 0 || o.call(t), this.preventArtificialScroll[i] = null;
100
+ }
101
+ toLogicalScrollCoordinate(i, t, o, l) {
102
+ const r = o.scrollDimension;
103
+ if (!r)
104
+ return i;
105
+ if (typeof l == "number" && r.isCompressed) {
106
+ const s = this.previousScroll[t] === e ? r.toLogicalCoordinate(i - l) : this.previousLogicalScroll[t];
107
+ return r.toLogicalCoordinate(r.toPhysicalCoordinate(s + l));
108
+ }
109
+ return r.toLogicalCoordinate(i);
110
+ }
111
+ toPhysicalCoordinate(i, t) {
112
+ var o, l;
113
+ return (l = (o = t.scrollDimension) === null || o === void 0 ? void 0 : o.toPhysicalCoordinate(i)) !== null && l !== void 0 ? l : i;
114
+ }
115
+ toLogicalCoordinate(i, t) {
116
+ var o, l;
117
+ return (l = (o = t.scrollDimension) === null || o === void 0 ? void 0 : o.toLogicalCoordinate(i)) !== null && l !== void 0 ? l : i;
118
+ }
119
+ }
120
+ class p {
121
+ constructor(i = 10) {
122
+ this.scrollThrottling = i, this.mouseWheelScrollTimestamp = {
123
+ rgCol: 0,
124
+ rgRow: 0
125
+ }, this.lastKnownScrollCoordinate = {
126
+ rgCol: 0,
127
+ rgRow: 0
128
+ }, this.lastScrollUpdateCallbacks = {};
129
+ }
130
+ setCoordinate(i) {
131
+ this.lastKnownScrollCoordinate[i.dimension] = i.coordinate;
132
+ }
133
+ setCoordinateFromScroll(i) {
134
+ this.setCoordinate(i), this.mouseWheelScrollTimestamp[i.dimension] = 0;
135
+ }
136
+ /**
137
+ * Remember last mw event time
138
+ */
139
+ latestScrollUpdate(i) {
140
+ this.mouseWheelScrollTimestamp[i] = (/* @__PURE__ */ new Date()).getTime();
141
+ }
142
+ isReady(i, t) {
143
+ return this.lastScrollUpdateCallbacks[i] && this.clearLastScrollUpdate(i), this.verifyChange(i, t);
144
+ }
145
+ verifyChange(i, t) {
146
+ return (/* @__PURE__ */ new Date()).getTime() - this.mouseWheelScrollTimestamp[i] > this.scrollThrottling && t !== this.lastKnownScrollCoordinate[i];
147
+ }
148
+ clearLastScrollUpdate(i) {
149
+ var t, o;
150
+ clearTimeout((o = (t = this.lastScrollUpdateCallbacks[i]) === null || t === void 0 ? void 0 : t.timeout) !== null && o !== void 0 ? o : 0), delete this.lastScrollUpdateCallbacks[i];
151
+ }
152
+ throttleLastScrollUpdate(i, t, o) {
153
+ if (this.scrollThrottling) {
154
+ this.clearLastScrollUpdate(i);
155
+ const l = this.lastScrollUpdateCallbacks[i] = {
156
+ callback: o,
157
+ timestamp: (/* @__PURE__ */ new Date()).getTime(),
158
+ coordinate: t,
159
+ timeout: 0
160
+ };
161
+ l.timeout = setTimeout(() => {
162
+ this.clearLastScrollUpdate(i), this.mouseWheelScrollTimestamp[i] < l.timestamp && this.verifyChange(i, l.coordinate) && l.callback();
163
+ }, this.scrollThrottling + 50);
164
+ }
165
+ }
166
+ }
167
+ var g = "Expected a function";
168
+ function f(a, i, t) {
169
+ var o = !0, l = !0;
170
+ if (typeof a != "function")
171
+ throw new TypeError(g);
172
+ return d(t) && (o = "leading" in t ? !!t.leading : o, l = "trailing" in t ? !!t.trailing : l), m(a, i, {
173
+ leading: o,
174
+ maxWait: i,
175
+ trailing: l
176
+ });
177
+ }
178
+ export {
179
+ p as L,
180
+ v as a,
181
+ C as g,
182
+ f as t
183
+ };
@@ -0,0 +1,33 @@
1
+ import { FilterViewRenderField, SourceFieldOption } from '@endge/core';
2
+ import { PropType } from 'vue';
3
+ /** Делегирует один semantic control активному Vue adapter-у. */
4
+ export declare const EndgeFilterControlRenderer: import('vue').DefineComponent<import('vue').ExtractPropTypes<{
5
+ field: {
6
+ type: PropType<FilterViewRenderField>;
7
+ required: true;
8
+ };
9
+ options: {
10
+ type: PropType<SourceFieldOption[]>;
11
+ default: () => never[];
12
+ };
13
+ readonly: BooleanConstructor;
14
+ label: StringConstructor;
15
+ }>, () => import('../../domain/types/sfc-render.type').SFCVueRenderResult, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
16
+ 'update:value': (_value: unknown) => true;
17
+ }, string, import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<{
18
+ field: {
19
+ type: PropType<FilterViewRenderField>;
20
+ required: true;
21
+ };
22
+ options: {
23
+ type: PropType<SourceFieldOption[]>;
24
+ default: () => never[];
25
+ };
26
+ readonly: BooleanConstructor;
27
+ label: StringConstructor;
28
+ }>> & Readonly<{
29
+ "onUpdate:value"?: ((_value: unknown) => any) | undefined;
30
+ }>, {
31
+ readonly: boolean;
32
+ options: SourceFieldOption[];
33
+ }, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, any>;
@@ -0,0 +1,13 @@
1
+ import { FilterViewRenderField } from '@endge/core';
2
+ type __VLS_Props = {
3
+ field: FilterViewRenderField;
4
+ label?: string;
5
+ showLabel?: boolean;
6
+ readonly?: boolean;
7
+ };
8
+ declare const _default: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {} & {
9
+ "update:value": (value: unknown) => any;
10
+ }, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{
11
+ "onUpdate:value"?: ((value: unknown) => any) | undefined;
12
+ }>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, HTMLDivElement>;
13
+ export default _default;
@@ -0,0 +1,3 @@
1
+ import { EndgeFilterRendererProps } from '../../domain/types/filter-renderer.type';
2
+ declare const _default: import('vue').DefineComponent<EndgeFilterRendererProps, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<EndgeFilterRendererProps> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
3
+ export default _default;
@@ -0,0 +1,2 @@
1
+ export { default as EndgeFilterField } from './EndgeFilterField.vue';
2
+ export { default as EndgeFilterRenderer } from './EndgeFilterRenderer.vue';
@@ -0,0 +1,22 @@
1
+ import { EndgeEnvId, EndgeProjectId } from '@endge/core';
2
+ interface Props {
3
+ project: EndgeProjectId;
4
+ env: EndgeEnvId;
5
+ }
6
+ declare function __VLS_template(): {
7
+ attrs: Partial<{}>;
8
+ slots: {
9
+ default?(_: {}): any;
10
+ };
11
+ refs: {};
12
+ rootEl: any;
13
+ };
14
+ type __VLS_TemplateResult = ReturnType<typeof __VLS_template>;
15
+ declare const __VLS_component: import('vue').DefineComponent<Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<Props> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
16
+ declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, __VLS_TemplateResult["slots"]>;
17
+ export default _default;
18
+ type __VLS_WithTemplateSlots<T, S> = T & {
19
+ new (): {
20
+ $slots: S;
21
+ };
22
+ };
@@ -0,0 +1,4 @@
1
+ declare const _default: import('vue').DefineComponent<{}, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {
2
+ menuRef: HTMLDivElement;
3
+ }, any>;
4
+ export default _default;
@@ -0,0 +1,46 @@
1
+ import { ContextMenuDescriptor, ContextMenuItemDescriptor, ContextMenuNodeDescriptor, RuntimeActionContext } from '@endge/core';
2
+ export interface EndgeContextMenuOpenInput<TContext extends RuntimeActionContext = RuntimeActionContext> {
3
+ ownerId: string;
4
+ x: number;
5
+ y: number;
6
+ menu: ContextMenuDescriptor;
7
+ context: TContext;
8
+ }
9
+ export interface EndgeContextMenuState {
10
+ open: boolean;
11
+ ownerId: string | null;
12
+ x: number;
13
+ y: number;
14
+ menu: ContextMenuDescriptor | null;
15
+ context: RuntimeActionContext | null;
16
+ }
17
+ export declare const endgeContextMenuState: {
18
+ open: boolean;
19
+ ownerId: string | null;
20
+ x: number;
21
+ y: number;
22
+ menu: {
23
+ kind: "context-menu";
24
+ items: ({
25
+ kind: "item";
26
+ id: string;
27
+ label: string;
28
+ action: import('@endge/core').RuntimeActionId;
29
+ input?: unknown;
30
+ icon?: string | undefined;
31
+ } | {
32
+ kind: "separator";
33
+ id: string;
34
+ })[];
35
+ } | null;
36
+ context: {
37
+ surface: import('@endge/core').RuntimeActionSurface;
38
+ runtimeId?: string | undefined;
39
+ target?: unknown;
40
+ } | null;
41
+ };
42
+ export declare function openEndgeContextMenu(input: EndgeContextMenuOpenInput): void;
43
+ export declare function closeEndgeContextMenu(ownerId?: string): void;
44
+ export declare function getExecutableContextMenuItems(): ContextMenuNodeDescriptor[];
45
+ export declare function executeEndgeContextMenuItem(item: ContextMenuItemDescriptor): Promise<void>;
46
+ export declare function resolveEndgeContextMenuItemLabel(item: ContextMenuItemDescriptor): string;