@genexus/genexus-ide-ui 0.0.21 → 0.0.23
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/{ch-grid_4.cjs.entry.js → ch-grid_8.cjs.entry.js} +143 -0
- package/dist/cjs/{ch-suggest_5.cjs.entry.js → ch-suggest_4.cjs.entry.js} +0 -65
- package/dist/cjs/format-date-f2c49d1a.js +28 -0
- package/dist/cjs/genexus-ide-ui.cjs.js +1 -1
- package/dist/cjs/gx-ide-team-dev-commit.cjs.entry.js +4 -24
- package/dist/cjs/gx-ide-team-dev-select-recent-comment.cjs.entry.js +5 -15
- package/dist/cjs/gx-ide-team-dev-update-partial-selection.cjs.entry.js +102 -0
- package/dist/cjs/gx-ide-team-dev-update-to-revision.cjs.entry.js +53 -0
- package/dist/cjs/gx-ide-team-dev-update.cjs.entry.js +278 -0
- package/dist/cjs/gx-ide-top-bar.cjs.entry.js +37 -0
- package/dist/cjs/{gxg-combo-box_8.cjs.entry.js → gxg-combo-box_6.cjs.entry.js} +1 -132
- package/dist/cjs/gxg-form-checkbox-group_2.cjs.entry.js +140 -0
- package/dist/cjs/{gx-ide-top-bar_2.cjs.entry.js → gxg-form-radio-group.cjs.entry.js} +0 -31
- package/dist/cjs/gxg-text.cjs.entry.js +72 -0
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/collection/collection-manifest.json +3 -0
- package/dist/collection/common/format-date.js +11 -0
- package/dist/collection/components/team-dev-commit/team-dev-commit.js +3 -13
- package/dist/collection/components/team-dev-select-recent-comment/team-dev-select-recent-comment.js +6 -16
- package/dist/collection/components/team-dev-update/gx-ide-assets/team-dev-update/langs/team-dev-update.lang.en.json +45 -0
- package/dist/collection/components/team-dev-update/gx-ide-assets/team-dev-update/langs/team-dev-update.lang.ja.json +3 -0
- package/dist/collection/components/team-dev-update/gx-ide-assets/team-dev-update/langs/team-dev-update.lang.zh.json +3 -0
- package/dist/collection/components/team-dev-update/team-dev-update.css +216 -0
- package/dist/collection/components/team-dev-update/team-dev-update.js +524 -0
- package/dist/collection/components/team-dev-update-partial-selection/gx-ide-assets/team-dev-update-partial-selection/langs/team-dev-update-partial-selection.lang.en.json +15 -0
- package/dist/collection/components/team-dev-update-partial-selection/gx-ide-assets/team-dev-update-partial-selection/langs/team-dev-update-partial-selection.lang.ja.json +3 -0
- package/dist/collection/components/team-dev-update-partial-selection/gx-ide-assets/team-dev-update-partial-selection/langs/team-dev-update-partial-selection.lang.zh.json +3 -0
- package/dist/collection/components/team-dev-update-partial-selection/team-dev-update-partial-selection.css +149 -0
- package/dist/collection/components/team-dev-update-partial-selection/team-dev-update-partial-selection.js +238 -0
- package/dist/collection/components/team-dev-update-to-revision/gx-ide-assets/team-dev-update-to-revision/langs/team-dev-update-to-revision.lang.en.json +11 -0
- package/dist/collection/components/team-dev-update-to-revision/gx-ide-assets/team-dev-update-to-revision/langs/team-dev-update-to-revision.lang.ja.json +3 -0
- package/dist/collection/components/team-dev-update-to-revision/gx-ide-assets/team-dev-update-to-revision/langs/team-dev-update-to-revision.lang.zh.json +3 -0
- package/dist/collection/components/team-dev-update-to-revision/team-dev-update-to-revision.css +147 -0
- package/dist/collection/components/team-dev-update-to-revision/team-dev-update-to-revision.js +136 -0
- package/dist/components/ch-grid-rowset-empty.js +1 -24
- package/dist/components/ch-grid-rowset-empty2.js +26 -0
- package/dist/components/format-date.js +25 -0
- package/dist/components/gx-ide-team-dev-commit.js +4 -24
- package/dist/components/gx-ide-team-dev-select-recent-comment.js +5 -15
- package/dist/components/gx-ide-team-dev-update-partial-selection.d.ts +11 -0
- package/dist/components/gx-ide-team-dev-update-partial-selection.js +213 -0
- package/dist/components/gx-ide-team-dev-update-to-revision.d.ts +11 -0
- package/dist/components/gx-ide-team-dev-update-to-revision.js +131 -0
- package/dist/components/gx-ide-team-dev-update.d.ts +11 -0
- package/dist/components/gx-ide-team-dev-update.js +473 -0
- package/dist/components/index.d.ts +3 -0
- package/dist/components/index.js +3 -0
- package/dist/components/tabs.js +1 -0
- package/dist/esm/{ch-grid_4.entry.js → ch-grid_8.entry.js} +140 -1
- package/dist/esm/{ch-suggest_5.entry.js → ch-suggest_4.entry.js} +1 -65
- package/dist/esm/format-date-e9ca0786.js +25 -0
- package/dist/esm/genexus-ide-ui.js +1 -1
- package/dist/esm/gx-ide-team-dev-commit.entry.js +4 -24
- package/dist/esm/gx-ide-team-dev-select-recent-comment.entry.js +5 -15
- package/dist/esm/gx-ide-team-dev-update-partial-selection.entry.js +98 -0
- package/dist/esm/gx-ide-team-dev-update-to-revision.entry.js +49 -0
- package/dist/esm/gx-ide-team-dev-update.entry.js +274 -0
- package/dist/esm/gx-ide-top-bar.entry.js +33 -0
- package/dist/esm/{gxg-combo-box_8.entry.js → gxg-combo-box_6.entry.js} +3 -132
- package/dist/esm/gxg-form-checkbox-group_2.entry.js +135 -0
- package/dist/esm/{gx-ide-top-bar_2.entry.js → gxg-form-radio-group.entry.js} +2 -32
- package/dist/esm/gxg-text.entry.js +68 -0
- package/dist/esm/loader.js +1 -1
- package/dist/genexus-ide-ui/genexus-ide-ui.esm.js +1 -1
- package/dist/genexus-ide-ui/gx-ide-assets/team-dev-update/langs/team-dev-update.lang.en.json +45 -0
- package/dist/genexus-ide-ui/gx-ide-assets/team-dev-update/langs/team-dev-update.lang.ja.json +3 -0
- package/dist/genexus-ide-ui/gx-ide-assets/team-dev-update/langs/team-dev-update.lang.zh.json +3 -0
- package/dist/genexus-ide-ui/gx-ide-assets/team-dev-update-partial-selection/langs/team-dev-update-partial-selection.lang.en.json +15 -0
- package/dist/genexus-ide-ui/gx-ide-assets/team-dev-update-partial-selection/langs/team-dev-update-partial-selection.lang.ja.json +3 -0
- package/dist/genexus-ide-ui/gx-ide-assets/team-dev-update-partial-selection/langs/team-dev-update-partial-selection.lang.zh.json +3 -0
- package/dist/genexus-ide-ui/gx-ide-assets/team-dev-update-to-revision/langs/team-dev-update-to-revision.lang.en.json +11 -0
- package/dist/genexus-ide-ui/gx-ide-assets/team-dev-update-to-revision/langs/team-dev-update-to-revision.lang.ja.json +3 -0
- package/dist/genexus-ide-ui/gx-ide-assets/team-dev-update-to-revision/langs/team-dev-update-to-revision.lang.zh.json +3 -0
- package/dist/genexus-ide-ui/p-16bd5578.entry.js +1 -0
- package/dist/genexus-ide-ui/p-32b8abf6.entry.js +1 -0
- package/dist/genexus-ide-ui/p-3bdcb73b.entry.js +1 -0
- package/dist/genexus-ide-ui/p-53d36ef7.entry.js +1 -0
- package/dist/genexus-ide-ui/p-5884a014.entry.js +1 -0
- package/dist/genexus-ide-ui/p-66072dce.entry.js +1 -0
- package/dist/genexus-ide-ui/p-6e80380b.entry.js +1 -0
- package/dist/genexus-ide-ui/p-718759e7.entry.js +1 -0
- package/dist/genexus-ide-ui/p-72303355.js +1 -0
- package/dist/genexus-ide-ui/p-757f8567.entry.js +1 -0
- package/dist/genexus-ide-ui/p-a0e85c2a.entry.js +1 -0
- package/dist/genexus-ide-ui/p-afe9515e.entry.js +1 -0
- package/dist/types/common/format-date.d.ts +1 -0
- package/dist/types/components/team-dev-commit/team-dev-commit.d.ts +0 -1
- package/dist/types/components/team-dev-select-recent-comment/team-dev-select-recent-comment.d.ts +1 -31
- package/dist/types/components/team-dev-update/team-dev-update.d.ts +173 -0
- package/dist/types/components/team-dev-update-partial-selection/team-dev-update-partial-selection.d.ts +61 -0
- package/dist/types/components/team-dev-update-to-revision/team-dev-update-to-revision.d.ts +41 -0
- package/dist/types/components.d.ts +207 -1
- package/package.json +3 -3
- package/dist/cjs/ch-grid-column-resize_4.cjs.entry.js +0 -150
- package/dist/esm/ch-grid-column-resize_4.entry.js +0 -143
- package/dist/genexus-ide-ui/p-554ed73a.entry.js +0 -1
- package/dist/genexus-ide-ui/p-6d378d61.entry.js +0 -1
- package/dist/genexus-ide-ui/p-a8433582.entry.js +0 -1
- package/dist/genexus-ide-ui/p-b26b5d74.entry.js +0 -1
- package/dist/genexus-ide-ui/p-d5c29251.entry.js +0 -1
- package/dist/genexus-ide-ui/p-f1a3397d.entry.js +0 -1
|
@@ -1,15 +1,6 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { r as registerInstance, c as createEvent, h, H as Host, g as getElement } from './index-0da01575.js';
|
|
2
2
|
import { L as Locale } from './locale-e183487a.js';
|
|
3
|
-
|
|
4
|
-
/* STENCIL IMPORTS */
|
|
5
|
-
const renderComboItems = (gxOptions) => {
|
|
6
|
-
const comboItemsArray = [];
|
|
7
|
-
gxOptions.forEach((gxOption) => {
|
|
8
|
-
const iconName = gxOption.iconName || gxOption.icon;
|
|
9
|
-
comboItemsArray.push(h("gxg-combo-box-item", { value: gxOption.value, icon: iconName }, gxOption.label || gxOption.name));
|
|
10
|
-
});
|
|
11
|
-
return comboItemsArray;
|
|
12
|
-
};
|
|
3
|
+
import { f as formatDate, r as renderComboItems } from './format-date-e9ca0786.js';
|
|
13
4
|
|
|
14
5
|
const teamDevCommitCss = ".gxi-hidden{display:none !important}.gxi-full-height{height:100%}.align-start{display:flex;align-items:start}.align-center{display:flex;align-items:center}.align-end{display:flex;align-items:end}.grid{display:grid;grid-row-gap:var(--gx-ide-grid-row-gap);grid-column-gap:var(--gx-ide-grid-column-gap);grid-template-rows:auto}:host(.gx-ide-component){box-shadow:var(--box-shadow-01) !important;height:100% !important;display:flex !important;flex-direction:column !important}:host(:focus-within) gx-ide-top-bar::part(wrapper){background-color:var(--color-secondary-enabled)}.gx-ide-main-wrapper{color:var(--gx-ide-component-text-color);font-weight:var(--font-weight-regular);font-size:var(--font-size-lg);line-height:1.6em;height:100%;background-color:var(--gx-ide-component-background-color);display:flex;flex-direction:column;flex-grow:1}.gx-ide-main{flex-grow:1;overflow-y:auto;}.gx-ide-main::-webkit-scrollbar{width:6px;height:6px}.gx-ide-main::-webkit-scrollbar-track{background-color:var(--gray-02);border-radius:10px}.gx-ide-main::-webkit-scrollbar-thumb{background:var(--gray-05);border-radius:10px}.gx-ide-main::-webkit-scrollbar-thumb:hover{background:var(--gray-04);cursor:pointer}.gx-ide-main .gxg-scroll{display:block;overflow-y:auto;padding-inline-end:2px}.gx-ide-overflow{overflow-y:auto;}.gx-ide-overflow::-webkit-scrollbar{width:6px;height:6px}.gx-ide-overflow::-webkit-scrollbar-track{background-color:var(--gray-02);border-radius:10px}.gx-ide-overflow::-webkit-scrollbar-thumb{background:var(--gray-05);border-radius:10px}.gx-ide-overflow::-webkit-scrollbar-thumb:hover{background:var(--gray-04);cursor:pointer}.gx-ide-overflow .gxg-scroll{display:block;overflow-y:auto;padding-inline-end:2px}:host{display:block}.main-wrapper{width:100%}.gxg-tabs{margin-top:0;box-shadow:none}.header{grid-template-columns:4fr auto}.second-grid{grid-template-rows:1fr auto}.second-grid .actions-row{grid-template-columns:1fr auto}.action-buttons{justify-self:flex-end}.hidden{display:none}.filters-grid{grid-template-rows:repeat(2, 1fr)}.filters-grid .first-row{grid-template-columns:repeat(2, 1fr)}.filters-grid .second-row{grid-template-columns:repeat(2, 1fr)}";
|
|
15
6
|
|
|
@@ -69,17 +60,6 @@ const GxIdeTeamDevCommit = class {
|
|
|
69
60
|
}
|
|
70
61
|
return h("gxg-icon", { type: type, color: color });
|
|
71
62
|
};
|
|
72
|
-
this.formatDate = (dateObject) => {
|
|
73
|
-
const date = dateObject.toISOString().slice(0, 10);
|
|
74
|
-
const hours = dateObject.getHours();
|
|
75
|
-
const minutes = dateObject.getMinutes();
|
|
76
|
-
const time = `${hours}:${minutes}`;
|
|
77
|
-
let period = "AM"; // Assume it's AM by default
|
|
78
|
-
if (hours >= 12) {
|
|
79
|
-
period = "PM";
|
|
80
|
-
}
|
|
81
|
-
return `${date} ${time}${period} `;
|
|
82
|
-
};
|
|
83
63
|
this.pendingCommitsRowMarkingChangedHandler = async (e) => {
|
|
84
64
|
// remove "rowMarkingChanged" until checkboxes have been added/removed on togglePendingCommitsCheckboxes, to prevent loops.
|
|
85
65
|
this.chGridPendingCommitsEl.removeEventListener("rowMarkingChanged", this.pendingCommitsRowMarkingChangedHandler);
|
|
@@ -116,11 +96,11 @@ const GxIdeTeamDevCommit = class {
|
|
|
116
96
|
};
|
|
117
97
|
/* pending commits grid render*/
|
|
118
98
|
this.renderPendingCommitsGrid = () => {
|
|
119
|
-
return (h("gxg-grid", null, h("ch-grid", { rowSelectionMode: "multiple", ref: (el) => (this.chGridPendingCommitsEl = el), part: "ch-grid-pending-commits", class: "no-border", onContextMenu: this.gridContextMenuCallbackHandler("commit") }, h("ch-grid-columnset", null, h("ch-grid-column", { columnType: "rich", richRowSelector: true, richRowSelectorMode: "mark", settingable: false, sortable: false, size: "auto" }), h("ch-grid-column", { columnName: "State", settingable: false, sortable: false, size: "auto" }), h("ch-grid-column", { settingable: false, sortable: false, size: "auto" }), h("ch-grid-column", { sortable: true, columnName: "Name", settingable: false, size: "auto" }), h("ch-grid-column", { sortable: true, columnName: "Type", settingable: false, size: "auto" }), h("ch-grid-column", { columnName: "Description", settingable: false, size: "auto" }), h("ch-grid-column", { sortable: true, columnName: "Modified On", settingable: false }), h("ch-grid-column", { columnName: "Module", settingable: false, size: "auto" }), h("ch-grid-column", { columnName: "Local State", settingable: false, size: "auto" }), h("ch-grid-column", { columnName: "Last Synchronized", settingable: false, size: "150px" }), h("ch-grid-column", { sortable: true, columnName: "User", settingable: false, size: "auto" })), this.pendingCommits.map((obj) => (h("ch-grid-row", { rowid: obj.id }, h("ch-grid-cell", { "cell-type": "rich", "row-selector": true }), h("ch-grid-cell", null, " ", this.renderIconState(obj.state), " "), h("ch-grid-cell", null, h("gxg-icon", { color: "auto", type: obj.iconType })), h("ch-grid-cell", null, " ", obj.name, " "), h("ch-grid-cell", null, " ", obj.type, " "), h("ch-grid-cell", null, " ", obj.description, " "), h("ch-grid-cell", null, `${
|
|
99
|
+
return (h("gxg-grid", null, h("ch-grid", { rowSelectionMode: "multiple", ref: (el) => (this.chGridPendingCommitsEl = el), part: "ch-grid-pending-commits", class: "no-border", onContextMenu: this.gridContextMenuCallbackHandler("commit") }, h("ch-grid-columnset", null, h("ch-grid-column", { columnType: "rich", richRowSelector: true, richRowSelectorMode: "mark", settingable: false, sortable: false, size: "auto" }), h("ch-grid-column", { columnName: "State", settingable: false, sortable: false, size: "auto" }), h("ch-grid-column", { settingable: false, sortable: false, size: "auto" }), h("ch-grid-column", { sortable: true, columnName: "Name", settingable: false, size: "auto" }), h("ch-grid-column", { sortable: true, columnName: "Type", settingable: false, size: "auto" }), h("ch-grid-column", { columnName: "Description", settingable: false, size: "auto" }), h("ch-grid-column", { sortable: true, columnName: "Modified On", settingable: false }), h("ch-grid-column", { columnName: "Module", settingable: false, size: "auto" }), h("ch-grid-column", { columnName: "Local State", settingable: false, size: "auto" }), h("ch-grid-column", { columnName: "Last Synchronized", settingable: false, size: "150px" }), h("ch-grid-column", { sortable: true, columnName: "User", settingable: false, size: "auto" })), this.pendingCommits.map((obj) => (h("ch-grid-row", { rowid: obj.id }, h("ch-grid-cell", { "cell-type": "rich", "row-selector": true }), h("ch-grid-cell", null, " ", this.renderIconState(obj.state), " "), h("ch-grid-cell", null, h("gxg-icon", { color: "auto", type: obj.iconType })), h("ch-grid-cell", null, " ", obj.name, " "), h("ch-grid-cell", null, " ", obj.type, " "), h("ch-grid-cell", null, " ", obj.description, " "), h("ch-grid-cell", null, `${formatDate(obj.modifiedOn)}`), h("ch-grid-cell", null, " ", obj.module, " "), h("ch-grid-cell", null, " ", obj.localState, " "), h("ch-grid-cell", null, `${formatDate(obj.lastSynchronized)}`), h("ch-grid-cell", null, " ", obj.user, " ")))))));
|
|
120
100
|
};
|
|
121
101
|
/* ignored objects grid render*/
|
|
122
102
|
this.renderIgnoredObjectsGrid = () => {
|
|
123
|
-
return (h("gxg-grid", null, h("ch-grid", { rowSelectionMode: "multiple", ref: (el) => (this.chIgnoredObjectsEl = el), part: "ch-grid-pending-commits", onContextMenu: this.gridContextMenuCallbackHandler("ignored") }, h("ch-grid-columnset", null, h("ch-grid-column", { columnName: "", settingable: false }), h("ch-grid-column", { columnName: "TypeIcon", settingable: false }), h("ch-grid-column", { columnName: "Name", settingable: false, sortable: true }), h("ch-grid-column", { columnName: "Type", settingable: false }), h("ch-grid-column", { columnName: "Description", settingable: false }), h("ch-grid-column", { columnName: "Modified On", settingable: false }), h("ch-grid-column", { columnName: "Module", settingable: false }), h("ch-grid-column", { columnName: "Local State", settingable: false }), h("ch-grid-column", { columnName: "Last Synchronized", settingable: false }), h("ch-grid-column", { columnName: "User", settingable: false })), this.ignoredObjects.map((obj) => (h("ch-grid-row", { "row-id": obj.id, selected: true }, h("ch-grid-cell", null, " ", this.renderIconState(obj.state), " "), h("ch-grid-cell", null, h("gxg-icon", { color: "auto", type: obj.iconType })), h("ch-grid-cell", null, " ", obj.name, " "), h("ch-grid-cell", null, " ", obj.type, " "), h("ch-grid-cell", null, " ", obj.description, " "), h("ch-grid-cell", null, `${
|
|
103
|
+
return (h("gxg-grid", null, h("ch-grid", { rowSelectionMode: "multiple", ref: (el) => (this.chIgnoredObjectsEl = el), part: "ch-grid-pending-commits", onContextMenu: this.gridContextMenuCallbackHandler("ignored") }, h("ch-grid-columnset", null, h("ch-grid-column", { columnName: "", settingable: false }), h("ch-grid-column", { columnName: "TypeIcon", settingable: false }), h("ch-grid-column", { columnName: "Name", settingable: false, sortable: true }), h("ch-grid-column", { columnName: "Type", settingable: false }), h("ch-grid-column", { columnName: "Description", settingable: false }), h("ch-grid-column", { columnName: "Modified On", settingable: false }), h("ch-grid-column", { columnName: "Module", settingable: false }), h("ch-grid-column", { columnName: "Local State", settingable: false }), h("ch-grid-column", { columnName: "Last Synchronized", settingable: false }), h("ch-grid-column", { columnName: "User", settingable: false })), this.ignoredObjects.map((obj) => (h("ch-grid-row", { "row-id": obj.id, selected: true }, h("ch-grid-cell", null, " ", this.renderIconState(obj.state), " "), h("ch-grid-cell", null, h("gxg-icon", { color: "auto", type: obj.iconType })), h("ch-grid-cell", null, " ", obj.name, " "), h("ch-grid-cell", null, " ", obj.type, " "), h("ch-grid-cell", null, " ", obj.description, " "), h("ch-grid-cell", null, `${formatDate(obj.modifiedOn)}`), h("ch-grid-cell", null, " ", obj.module, " "), h("ch-grid-cell", null, " ", obj.localState, " "), h("ch-grid-cell", null, `${formatDate(obj.lastSynchronized)}`), h("ch-grid-cell", null, " ", obj.user, " ")))))));
|
|
124
104
|
};
|
|
125
105
|
this.getRecentCommentHandler = async () => {
|
|
126
106
|
if (this.getRecentCommentCallback) {
|
|
@@ -8,15 +8,9 @@ const GxIdeTeamDevSelectRecentComment = class {
|
|
|
8
8
|
registerInstance(this, hostRef);
|
|
9
9
|
this.componentDidLoadEvent = createEvent(this, "componentDidLoadEvent", 7);
|
|
10
10
|
this.selectedComment = null;
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
/** *****************************
|
|
15
|
-
* 8.PUBLIC METHODS API
|
|
16
|
-
********************************/
|
|
17
|
-
/** *****************************
|
|
18
|
-
* 9.LOCAL METHODS
|
|
19
|
-
********************************/
|
|
11
|
+
// 7.LISTENERS //
|
|
12
|
+
// 8.PUBLIC METHODS API //
|
|
13
|
+
// 9.LOCAL METHODS //
|
|
20
14
|
this.renderObjectItems = (options) => {
|
|
21
15
|
if (options.length) {
|
|
22
16
|
const items = [];
|
|
@@ -41,16 +35,12 @@ const GxIdeTeamDevSelectRecentComment = class {
|
|
|
41
35
|
this.confirmCallback = undefined;
|
|
42
36
|
this.cancelCallback = undefined;
|
|
43
37
|
}
|
|
44
|
-
|
|
45
|
-
* 6.COMPONENT LIFECYCLE EVENTS
|
|
46
|
-
********************************/
|
|
38
|
+
// 6.COMPONENT LIFECYCLE EVENTS //
|
|
47
39
|
async componentWillLoad() {
|
|
48
40
|
this._componentLocale = await Locale.getComponentStrings(this.el);
|
|
49
41
|
this.componentDidLoadEvent.emit(true);
|
|
50
42
|
}
|
|
51
|
-
|
|
52
|
-
* 10.RENDER() FUNCTION
|
|
53
|
-
********************************/
|
|
43
|
+
// 10.RENDER() FUNCTION //
|
|
54
44
|
render() {
|
|
55
45
|
return (h(Host, null, h("div", { class: `main-wrapper` }, h("gxg-container", { displayBorder: true }, h("gxg-list-box", { id: "max-height", singleSelection: true, height: "100%", required: true, "min-height": "50%", onSelectionChanged: event => {
|
|
56
46
|
if (event.detail[0]) {
|
|
@@ -0,0 +1,98 @@
|
|
|
1
|
+
import { r as registerInstance, c as createEvent, h, H as Host, g as getElement } from './index-0da01575.js';
|
|
2
|
+
import { L as Locale } from './locale-e183487a.js';
|
|
3
|
+
|
|
4
|
+
const teamDevUpdatePartialSelectionCss = ".gxi-hidden{display:none !important}.gxi-full-height{height:100%}.align-start{display:flex;align-items:start}.align-center{display:flex;align-items:center}.align-end{display:flex;align-items:end}.grid{display:grid;grid-row-gap:var(--gx-ide-grid-row-gap);grid-column-gap:var(--gx-ide-grid-column-gap);grid-template-rows:auto}:host(.gx-ide-component){box-shadow:var(--box-shadow-01) !important;height:100% !important;display:flex !important;flex-direction:column !important}:host(:focus-within) gx-ide-top-bar::part(wrapper){background-color:var(--color-secondary-enabled)}.gx-ide-main-wrapper{color:var(--gx-ide-component-text-color);font-weight:var(--font-weight-regular);font-size:var(--font-size-lg);line-height:1.6em;height:100%;background-color:var(--gx-ide-component-background-color);display:flex;flex-direction:column;flex-grow:1}.gx-ide-main{flex-grow:1;overflow-y:auto;}.gx-ide-main::-webkit-scrollbar{width:6px;height:6px}.gx-ide-main::-webkit-scrollbar-track{background-color:var(--gray-02);border-radius:10px}.gx-ide-main::-webkit-scrollbar-thumb{background:var(--gray-05);border-radius:10px}.gx-ide-main::-webkit-scrollbar-thumb:hover{background:var(--gray-04);cursor:pointer}.gx-ide-main .gxg-scroll{display:block;overflow-y:auto;padding-inline-end:2px}.gx-ide-overflow{overflow-y:auto;}.gx-ide-overflow::-webkit-scrollbar{width:6px;height:6px}.gx-ide-overflow::-webkit-scrollbar-track{background-color:var(--gray-02);border-radius:10px}.gx-ide-overflow::-webkit-scrollbar-thumb{background:var(--gray-05);border-radius:10px}.gx-ide-overflow::-webkit-scrollbar-thumb:hover{background:var(--gray-04);cursor:pointer}.gx-ide-overflow .gxg-scroll{display:block;overflow-y:auto;padding-inline-end:2px}:host{display:block;border:1px solid var(--gxg-border-color--regular);background-color:var(--color-background)}:host(.gxi-object-selector--shadow){border:none;box-shadow:var(--box-shadow-01)}.top-actions{display:flex;align-items:center;justify-content:flex-end}.actions{grid-template-columns:repeat(2, 1fr)}.actions>*{display:flex;flex-direction:row;gap:var(--gx-ide-grid-row-gap)}.actions>*:nth-child(2){justify-content:flex-end}";
|
|
5
|
+
|
|
6
|
+
const GxIdeTeamDevUpdatePartialSelection = class {
|
|
7
|
+
constructor(hostRef) {
|
|
8
|
+
registerInstance(this, hostRef);
|
|
9
|
+
this.componentDidLoadEvent = createEvent(this, "componentDidLoadEvent", 7);
|
|
10
|
+
// 9.LOCAL METHODS //
|
|
11
|
+
this.handleKeyDownEvent = (add) => {
|
|
12
|
+
if (add) {
|
|
13
|
+
document.addEventListener("keydown", this.keyDownEventHandler);
|
|
14
|
+
}
|
|
15
|
+
else {
|
|
16
|
+
document.removeEventListener("keydown", this.keyDownEventHandler);
|
|
17
|
+
}
|
|
18
|
+
};
|
|
19
|
+
this.keyDownEventHandler = (e) => {
|
|
20
|
+
console.log(e.detail);
|
|
21
|
+
};
|
|
22
|
+
this.renderObjects = () => {
|
|
23
|
+
return (h("gxg-grid", null, h("ch-grid", { "row-selection-mode": "multiple", ref: (el) => (this.chGridEl = el), part: "ch-grid-objects" }, h("ch-grid-columnset", null, h("ch-grid-column", { columnName: "", settingable: false, sortable: false }), h("ch-grid-column", { columnName: this._componentLocale.tableHead.name, settingable: false }), h("ch-grid-column", { columnName: this._componentLocale.tableHead.type, settingable: false }), h("ch-grid-column", { columnName: this._componentLocale.tableHead.description, settingable: false }), h("ch-grid-column", { columnName: this._componentLocale.tableHead.modifiedOn, settingable: false })), this.selection.map((obj) => (h("ch-grid-row", { rowid: obj.id }, h("ch-grid-cell", null, h("gxg-icon", { type: obj.typeIcon })), h("ch-grid-cell", null, " ", obj.name, " "), h("ch-grid-cell", null, " ", obj.type, " "), h("ch-grid-cell", null, " ", obj.description, " "), h("ch-grid-cell", null, `${obj.modifiedOn.toISOString().slice(0, 10)}`)))))));
|
|
24
|
+
};
|
|
25
|
+
this.getObjects = () => {
|
|
26
|
+
this.addCallback().then((items) => {
|
|
27
|
+
if ((items === null || items === void 0 ? void 0 : items.length) > 0) {
|
|
28
|
+
this.selection = [...this.selection, ...items];
|
|
29
|
+
this.selectedObjectsIds = [];
|
|
30
|
+
this.deselectAll();
|
|
31
|
+
}
|
|
32
|
+
});
|
|
33
|
+
};
|
|
34
|
+
this.removeObjects = () => {
|
|
35
|
+
this.selection = this.selection.filter(item => !this.selectedObjectsIds.includes(item.id));
|
|
36
|
+
this.selectedObjectsIds = [];
|
|
37
|
+
this.deselectAll();
|
|
38
|
+
};
|
|
39
|
+
this.confirm = () => {
|
|
40
|
+
this.confirmCallback(this.selectedObjectsIds);
|
|
41
|
+
};
|
|
42
|
+
this.cancel = () => {
|
|
43
|
+
this.cancelCallback();
|
|
44
|
+
};
|
|
45
|
+
this.deselectAll = () => {
|
|
46
|
+
this.chGridEl.selectAllRows(false);
|
|
47
|
+
};
|
|
48
|
+
this.listenChanges = () => {
|
|
49
|
+
// for grid selection
|
|
50
|
+
this.chGridEl.addEventListener("selectionChanged", (ev) => {
|
|
51
|
+
this.selectedObjectsIds = ev.detail.rowsId;
|
|
52
|
+
});
|
|
53
|
+
};
|
|
54
|
+
this.addCallback = undefined;
|
|
55
|
+
this.cancelCallback = undefined;
|
|
56
|
+
this.confirmCallback = undefined;
|
|
57
|
+
this.selection = [];
|
|
58
|
+
this.selectedObjectsIds = [];
|
|
59
|
+
}
|
|
60
|
+
// 6.COMPONENT LIFECYCLE EVENTS //
|
|
61
|
+
async componentWillLoad() {
|
|
62
|
+
this._componentLocale = await Locale.getComponentStrings(this.el);
|
|
63
|
+
this.componentDidLoadEvent.emit(true);
|
|
64
|
+
this.handleKeyDownEvent(true);
|
|
65
|
+
}
|
|
66
|
+
componentDidLoad() {
|
|
67
|
+
this.listenChanges();
|
|
68
|
+
}
|
|
69
|
+
// 7.LISTENERS //
|
|
70
|
+
keyDownHandler(eventInfo) {
|
|
71
|
+
if (document.activeElement === this.el) {
|
|
72
|
+
switch (eventInfo.key) {
|
|
73
|
+
case "Delete":
|
|
74
|
+
this.removeObjects();
|
|
75
|
+
break;
|
|
76
|
+
}
|
|
77
|
+
}
|
|
78
|
+
}
|
|
79
|
+
// 8.PUBLIC METHODS API //
|
|
80
|
+
/**
|
|
81
|
+
* Validate necessary data input
|
|
82
|
+
*/
|
|
83
|
+
async validate() {
|
|
84
|
+
const isValid = true;
|
|
85
|
+
return isValid;
|
|
86
|
+
}
|
|
87
|
+
// 10.RENDER() FUNCTION //
|
|
88
|
+
render() {
|
|
89
|
+
return (h(Host, { class: {
|
|
90
|
+
"gxi-team-dev-update-partial-selection": true
|
|
91
|
+
} }, h("div", { class: `main-wrapper` }, h("gxg-container", { containerTitle: this._componentLocale.title }, h("div", { class: "top-actions" }, h("gxg-button", { id: "button-add", type: "secondary-icon-only", icon: "gemini-tools/add-circle", onClick: this.getObjects, part: "gxg-button gxg-button--add" }), h("gxg-button", { id: "button-remove", type: "secondary-icon-only", icon: "gemini-tools/minus-circle", onClick: this.removeObjects, part: "gxg-button gxg-button--remove" })), this.renderObjects(), h("gxg-container", { displayBorderTop: true }, h("div", { class: "grid actions" }, h("div", null, h("gxg-button", { id: "button-clear", type: "primary-text-only", onClick: this.deselectAll, part: "gxg-button gxg-button--clear" }, this._componentLocale.footer.btnClear)), h("div", null, h("gxg-button", { id: "button-ok", type: "primary-text-only", onClick: this.confirm, part: "gxg-button gxg-button--ok" }, this._componentLocale.footer.btnOk), h("gxg-button", { id: "button-cancel", type: "outlined", onClick: this.cancel, part: "gxg-button gxg-button--cancel" }, this._componentLocale.footer.btnCancel))))))));
|
|
92
|
+
}
|
|
93
|
+
static get assetsDirs() { return ["gx-ide-assets/team-dev-update-partial-selection"]; }
|
|
94
|
+
get el() { return getElement(this); }
|
|
95
|
+
};
|
|
96
|
+
GxIdeTeamDevUpdatePartialSelection.style = teamDevUpdatePartialSelectionCss;
|
|
97
|
+
|
|
98
|
+
export { GxIdeTeamDevUpdatePartialSelection as gx_ide_team_dev_update_partial_selection };
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
import { r as registerInstance, c as createEvent, h, H as Host, g as getElement } from './index-0da01575.js';
|
|
2
|
+
import { L as Locale } from './locale-e183487a.js';
|
|
3
|
+
|
|
4
|
+
const teamDevUpdateToRevisionCss = ".gxi-hidden{display:none !important}.gxi-full-height{height:100%}.align-start{display:flex;align-items:start}.align-center{display:flex;align-items:center}.align-end{display:flex;align-items:end}.grid{display:grid;grid-row-gap:var(--gx-ide-grid-row-gap);grid-column-gap:var(--gx-ide-grid-column-gap);grid-template-rows:auto}:host(.gx-ide-component){box-shadow:var(--box-shadow-01) !important;height:100% !important;display:flex !important;flex-direction:column !important}:host(:focus-within) gx-ide-top-bar::part(wrapper){background-color:var(--color-secondary-enabled)}.gx-ide-main-wrapper{color:var(--gx-ide-component-text-color);font-weight:var(--font-weight-regular);font-size:var(--font-size-lg);line-height:1.6em;height:100%;background-color:var(--gx-ide-component-background-color);display:flex;flex-direction:column;flex-grow:1}.gx-ide-main{flex-grow:1;overflow-y:auto;}.gx-ide-main::-webkit-scrollbar{width:6px;height:6px}.gx-ide-main::-webkit-scrollbar-track{background-color:var(--gray-02);border-radius:10px}.gx-ide-main::-webkit-scrollbar-thumb{background:var(--gray-05);border-radius:10px}.gx-ide-main::-webkit-scrollbar-thumb:hover{background:var(--gray-04);cursor:pointer}.gx-ide-main .gxg-scroll{display:block;overflow-y:auto;padding-inline-end:2px}.gx-ide-overflow{overflow-y:auto;}.gx-ide-overflow::-webkit-scrollbar{width:6px;height:6px}.gx-ide-overflow::-webkit-scrollbar-track{background-color:var(--gray-02);border-radius:10px}.gx-ide-overflow::-webkit-scrollbar-thumb{background:var(--gray-05);border-radius:10px}.gx-ide-overflow::-webkit-scrollbar-thumb:hover{background:var(--gray-04);cursor:pointer}.gx-ide-overflow .gxg-scroll{display:block;overflow-y:auto;padding-inline-end:2px}:host{display:block;border:1px solid var(--gxg-border-color--regular);background-color:var(--color-background)}:host(.gxi-object-selector--shadow){border:none;box-shadow:var(--box-shadow-01)}.revision-number{display:flex;align-items:center;gap:var(--gx-ide-grid-row-gap)}.revision-number>:nth-child(2){width:auto !important}.actions{display:flex;justify-content:flex-end;align-items:center;gap:var(--gx-ide-grid-row-gap)}";
|
|
5
|
+
|
|
6
|
+
const GxIdeTeamDevUpdateToRevision = class {
|
|
7
|
+
constructor(hostRef) {
|
|
8
|
+
registerInstance(this, hostRef);
|
|
9
|
+
this.componentDidLoadEvent = createEvent(this, "componentDidLoadEvent", 7);
|
|
10
|
+
// 9.LOCAL METHODS //
|
|
11
|
+
this.confirm = () => {
|
|
12
|
+
let revision = undefined;
|
|
13
|
+
if (this.updateToRevisionEl.checked) {
|
|
14
|
+
revision = this.revisionNumberEl.value;
|
|
15
|
+
}
|
|
16
|
+
this.confirmCallback(revision);
|
|
17
|
+
};
|
|
18
|
+
this.cancel = () => {
|
|
19
|
+
this.cancelCallback();
|
|
20
|
+
};
|
|
21
|
+
this.cancelCallback = undefined;
|
|
22
|
+
this.confirmCallback = undefined;
|
|
23
|
+
}
|
|
24
|
+
// 6.COMPONENT LIFECYCLE EVENTS //
|
|
25
|
+
async componentWillLoad() {
|
|
26
|
+
this._componentLocale = await Locale.getComponentStrings(this.el);
|
|
27
|
+
this.componentDidLoadEvent.emit(true);
|
|
28
|
+
}
|
|
29
|
+
// 7.LISTENERS //
|
|
30
|
+
// 8.PUBLIC METHODS API //
|
|
31
|
+
/**
|
|
32
|
+
* Validate necessary data input
|
|
33
|
+
*/
|
|
34
|
+
async validate() {
|
|
35
|
+
const isValid = true;
|
|
36
|
+
return isValid;
|
|
37
|
+
}
|
|
38
|
+
// 10.RENDER() FUNCTION //
|
|
39
|
+
render() {
|
|
40
|
+
return (h(Host, { class: {
|
|
41
|
+
"gxi-team-dev-update-to-revision": true
|
|
42
|
+
} }, h("div", { class: `main-wrapper` }, h("gxg-container", null, h("gxg-form-radio-group", null, h("gxg-form-radio", { label: this._componentLocale.options.updateToLatest, value: "updateToLatest", part: "radio-to-latest" }), h("div", { class: "revision-number" }, h("gxg-form-radio", { label: this._componentLocale.options.updateToRevision, value: "updateToRevision", ref: (el) => (this.updateToRevisionEl = el), part: "radio-to-revision" }), h("gxg-form-text", { ref: (el) => (this.revisionNumberEl = el), part: "revision-number" })))), h("gxg-container", { displayBorderTop: true }, h("div", { class: "actions" }, h("gxg-button", { id: "button-ok", type: "primary-text-only", onClick: this.confirm, part: "gxg-button gxg-button--ok" }, this._componentLocale.footer.btnOk), h("gxg-button", { id: "button-cancel", type: "outlined", onClick: this.cancel, part: "gxg-button gxg-button--cancel" }, this._componentLocale.footer.btnCancel))))));
|
|
43
|
+
}
|
|
44
|
+
static get assetsDirs() { return ["gx-ide-assets/team-dev-update-to-revision"]; }
|
|
45
|
+
get el() { return getElement(this); }
|
|
46
|
+
};
|
|
47
|
+
GxIdeTeamDevUpdateToRevision.style = teamDevUpdateToRevisionCss;
|
|
48
|
+
|
|
49
|
+
export { GxIdeTeamDevUpdateToRevision as gx_ide_team_dev_update_to_revision };
|
|
@@ -0,0 +1,274 @@
|
|
|
1
|
+
import { r as registerInstance, c as createEvent, h, H as Host, g as getElement } from './index-0da01575.js';
|
|
2
|
+
import { L as Locale } from './locale-e183487a.js';
|
|
3
|
+
import { f as formatDate, r as renderComboItems } from './format-date-e9ca0786.js';
|
|
4
|
+
|
|
5
|
+
const teamDevUpdateCss = ".gxi-hidden{display:none !important}.gxi-full-height{height:100%}.align-start{display:flex;align-items:start}.align-center{display:flex;align-items:center}.align-end{display:flex;align-items:end}.grid{display:grid;grid-row-gap:var(--gx-ide-grid-row-gap);grid-column-gap:var(--gx-ide-grid-column-gap);grid-template-rows:auto}:host(.gx-ide-component){box-shadow:var(--box-shadow-01) !important;height:100% !important;display:flex !important;flex-direction:column !important}:host(:focus-within) gx-ide-top-bar::part(wrapper){background-color:var(--color-secondary-enabled)}.gx-ide-main-wrapper{color:var(--gx-ide-component-text-color);font-weight:var(--font-weight-regular);font-size:var(--font-size-lg);line-height:1.6em;height:100%;background-color:var(--gx-ide-component-background-color);display:flex;flex-direction:column;flex-grow:1}.gx-ide-main{flex-grow:1;overflow-y:auto;}.gx-ide-main::-webkit-scrollbar{width:6px;height:6px}.gx-ide-main::-webkit-scrollbar-track{background-color:var(--gray-02);border-radius:10px}.gx-ide-main::-webkit-scrollbar-thumb{background:var(--gray-05);border-radius:10px}.gx-ide-main::-webkit-scrollbar-thumb:hover{background:var(--gray-04);cursor:pointer}.gx-ide-main .gxg-scroll{display:block;overflow-y:auto;padding-inline-end:2px}.gx-ide-overflow{overflow-y:auto;}.gx-ide-overflow::-webkit-scrollbar{width:6px;height:6px}.gx-ide-overflow::-webkit-scrollbar-track{background-color:var(--gray-02);border-radius:10px}.gx-ide-overflow::-webkit-scrollbar-thumb{background:var(--gray-05);border-radius:10px}.gx-ide-overflow::-webkit-scrollbar-thumb:hover{background:var(--gray-04);cursor:pointer}.gx-ide-overflow .gxg-scroll{display:block;overflow-y:auto;padding-inline-end:2px}:host{display:block;border:1px solid var(--gxg-border-color--regular);background-color:var(--color-background)}:host(.gxi-object-selector--shadow){border:none;box-shadow:var(--box-shadow-01)}.options-grid{grid-template-columns:1fr auto}.options-grid .options-update-from-grid{grid-template-columns:auto 1fr;grid-row-gap:0}.options-grid .options-scope-grid{grid-template-columns:auto 1fr auto}.options-grid .options-scope-grid>:nth-child(7){grid-area:3/1/4/4}.flex{display:flex;flex-direction:row;align-items:center}.with-gap{gap:var(--gx-ide-grid-row-gap)}.hide{display:none !important}.filters-container-body{width:100%;display:flex;align-items:flex-end;justify-content:space-between}.filters-container-body .filter-grid{flex:1;grid-template-columns:repeat(2, 1fr)}.filters-container-body .actions{display:flex;justify-content:flex-end;align-items:center}.filters-container-body .actions.close{width:100%}.data-grid{grid-template-columns:repeat(3, 1fr)}.data-grid>:nth-child(1){grid-area:1/1/2/2}.data-grid>:nth-child(2){grid-area:1/2/2/4}.data-panel-grid{grid-template-columns:repeat(2, 1fr)}.data-preview img{max-width:100%}.data-max-height{max-height:300px;overflow-y:auto}.actions{justify-content:flex-end}.no-border{border:0}.bold{font-weight:bold}";
|
|
6
|
+
|
|
7
|
+
const GxIdeTeamDevUpdate = class {
|
|
8
|
+
constructor(hostRef) {
|
|
9
|
+
registerInstance(this, hostRef);
|
|
10
|
+
this.componentDidLoadEvent = createEvent(this, "componentDidLoadEvent", 7);
|
|
11
|
+
this.loadDataCalledFirstTime = false; // pending for update grid checkboxes, should be checked, after loadData has loaded objects for the first time.
|
|
12
|
+
// 9.LOCAL METHODS //
|
|
13
|
+
this.markAllPendingToUpdateRows = () => {
|
|
14
|
+
this.chGridPendingForUpdateEl.markAllRows();
|
|
15
|
+
};
|
|
16
|
+
this.renderOptions = () => {
|
|
17
|
+
return (h("gxg-container", { part: "options-container" }, h("div", { class: "grid options-grid" }, h("gxg-container", { displayBorder: true, part: "options-update-from", containerTitle: this._componentLocale.options.updateFrom }, h("div", { class: "grid options-update-from-grid" }, h("gxg-text", { type: "text-regular" }, this._componentLocale.options.updateFrom, ":"), h("gxg-text", { type: "text-link", onClick: this.openServerCallback }, this.updateFrom ? this.updateFrom.serverUrl : ""), h("gxg-text", { type: "text-regular" }, this._componentLocale.options.knowledgeBase, ":"), h("gxg-text", { type: "text-regular" }, this.updateFrom ? this.updateFrom.kbName : ""), h("gxg-text", { type: "text-regular" }, this._componentLocale.options.version, ":"), h("gxg-text", { type: "text-regular" }, this.updateFrom ? this.updateFrom.versionName : ""), h("gxg-text", { type: "text-regular" }, this._componentLocale.options.lastFullUpdate, ":"), h("gxg-text", { type: "text-regular" }, this.updateFrom
|
|
18
|
+
? formatDate(this.updateFrom.lastFullUpdate)
|
|
19
|
+
: ""))), h("gxg-container", { displayBorder: true, part: "options-scope", containerTitle: this._componentLocale.options.scope }, h("div", { class: "grid options-scope-grid" }, h("gxg-text", { type: "text-regular" }, this._componentLocale.options.objects, ":"), h("gxg-text", { type: "text-regular" }, h("span", { class: { bold: this.objectScopeText === "partial" } }, this._componentLocale.options.scopeData.objects[this.objectScopeText.toLocaleLowerCase()])), h("gxg-button", { id: "button-scope-objects-change", type: "outlined", onClick: this.objectsScope, part: "gxg-button gxg-button--scope-objects-change" }, this._componentLocale.options.changeBtn), h("gxg-text", { type: "text-regular" }, this._componentLocale.options.revision, ":"), h("gxg-text", { type: "text-regular" }, h("span", { class: { bold: this.revisionScopeText !== undefined } }, this.revisionScopeText === undefined
|
|
20
|
+
? this._componentLocale.options.scopeData.revision.latest
|
|
21
|
+
: this.revisionScopeText)), h("gxg-button", { id: "button-scope-revision-change", type: "outlined", onClick: this.revisionScope, part: "gxg-button gxg-button--scope-revision-change" }, this._componentLocale.options.changeBtn), h("gxg-form-checkbox", { label: this._componentLocale.options.kbProperties, class: "align-center", part: "option-kb-properties" }))))));
|
|
22
|
+
};
|
|
23
|
+
this.renderFilter = () => {
|
|
24
|
+
return (h("gxg-container", { part: "filters-container" }, h("div", { class: "filters-container-body with-gap" }, h("div", { class: {
|
|
25
|
+
"grid": true,
|
|
26
|
+
"filter-grid": true,
|
|
27
|
+
"hide": !this.showFilter
|
|
28
|
+
} }, h("gxg-form-text", { "label-position": "above", label: this._componentLocale.filter.pattern, ref: (el) => (this.filterPatternEl = el), part: "filter-pattern", onInput: this.loadData }), h("gxg-combo-box", { "disable-filter": true, label: this._componentLocale.filter.type, disabled: !this.types, ref: (el) => (this.filterTypeEl = el), onValueChanged: this.loadData, part: "filter-type", value: this.types[0].id }, renderComboItems(this.types))), h("div", { class: { actions: true, close: !this.showFilter } }, h("gxg-button", { type: "secondary-icon-only", icon: "patterns/filters", onClick: this.toggleFilter, part: "gxg-button gxg-button--show-filter" }), h("gxg-button", { type: "secondary-icon-only", icon: "gemini-tools/reset", onClick: this.loadData, part: "gxg-button gxg-button--reload" })))));
|
|
29
|
+
};
|
|
30
|
+
this.renderData = () => {
|
|
31
|
+
return (h("gxg-container", { part: "data-container" }, h("gxg-tabs", { id: "dataTabs", part: "data-tabs" }, h("gxg-tab-bar", { slot: "tab-bar-container" }, h("gxg-tab-button", { slot: "tab-bar", "tab-label": this._componentLocale.tabs.pendingForUpdate, tab: "pendingForUpdate", key: "pendingForUpdate", isSelected: true }), h("gxg-tab-button", { slot: "tab-bar", "tab-label": this._componentLocale.tabs.ignoredObjects, tab: "ignoredObjects", key: "ignoredObjects" }), h("gxg-tab-button", { slot: "tab-bar", "tab-label": this._componentLocale.tabs.results, tab: "results", key: "results", ref: (el) => (this.gxgTabButtonResultsEl = el) })), h("gxg-tab", { tab: "pendingForUpdate", key: "pendingForUpdate", isSelected: true }, this.renderPendingForUpdate()), h("gxg-tab", { tab: "ignoredObjects", key: "ignoredObjects" }, this.renderIgnoredObjects()), h("gxg-tab", { tab: "results", key: "results" }, this.renderResults()))));
|
|
32
|
+
};
|
|
33
|
+
this.renderPendingForUpdate = () => {
|
|
34
|
+
return (h("gxg-grid", null, h("ch-grid", { "row-selection-mode": "none", ref: (el) => (this.chGridPendingForUpdateEl = el), part: "ch-grid-pending-for-updates", class: "no-border" }, h("ch-grid-columnset", null, h("ch-grid-column", { settingable: false, sortable: false, "column-type": "rich", richRowSelector: true, richRowSelectorMode: "mark" }), h("ch-grid-column", { settingable: false, sortable: false }), h("ch-grid-column", { settingable: false, sortable: false }), h("ch-grid-column", { columnName: this._componentLocale.tableHead.name, settingable: false }), h("ch-grid-column", { columnName: this._componentLocale.tableHead.type, settingable: false }), h("ch-grid-column", { columnName: this._componentLocale.tableHead.description, settingable: false }), h("ch-grid-column", { columnName: this._componentLocale.tableHead.modifiedOn, settingable: false }), h("ch-grid-column", { columnName: this._componentLocale.tableHead.status, settingable: false }), h("ch-grid-column", { columnName: this._componentLocale.tableHead.action, settingable: false })), this.updateData.pendingForUpdate.map((obj) => (h("ch-grid-row", { rowid: obj.id }, h("ch-grid-cell", { "cell-type": "rich", "row-selector": true }), h("ch-grid-cell", null, h("gxg-icon", { type: obj.typeIcon })), h("ch-grid-cell", null, " ", this.renderIconState(obj.state), " "), h("ch-grid-cell", null, " ", obj.name, " "), h("ch-grid-cell", null, " ", obj.type, " "), h("ch-grid-cell", null, " ", obj.description, " "), h("ch-grid-cell", null, `${formatDate(obj.modifiedOn)}`), h("ch-grid-cell", null, " ", obj.status, " "), h("ch-grid-cell", null, " ", obj.action, " ")))))));
|
|
35
|
+
};
|
|
36
|
+
this.renderIgnoredObjects = () => {
|
|
37
|
+
return (h("gxg-grid", null, h("ch-grid", { "row-selection-mode": "multiple", ref: (el) => (this.chGridIgnoredObjectsEl = el), part: "ch-grid-ignored-objects", class: "no-border" }, h("ch-grid-columnset", null, h("ch-grid-column", { settingable: false, sortable: false, size: "min-content" }), h("ch-grid-column", { columnName: this._componentLocale.tableHead.name, settingable: false, size: "1fr" }), h("ch-grid-column", { columnName: this._componentLocale.tableHead.type, settingable: false, size: "1fr" })), this.updateData.ignoredObjects.map((obj) => (h("ch-grid-row", { rowid: obj.id }, h("ch-grid-cell", null, h("gxg-icon", { type: obj.typeIcon })), h("ch-grid-cell", null, " ", obj.name, " "), h("ch-grid-cell", null, " ", obj.type, " ")))))));
|
|
38
|
+
};
|
|
39
|
+
this.renderResults = () => {
|
|
40
|
+
return (h("gxg-grid", null, h("ch-grid", { "row-selection-mode": "multiple", ref: (el) => (this.chGridResultsEl = el), part: "ch-grid-results", class: "no-border" }, h("ch-grid-columnset", null, h("ch-grid-column", { settingable: false, sortable: false, "column-type": "tree" }), h("ch-grid-column", { settingable: false, sortable: false }), h("ch-grid-column", { settingable: false, sortable: false }), h("ch-grid-column", { columnName: this._componentLocale.tableHead.name, settingable: false }), h("ch-grid-column", { columnName: this._componentLocale.tableHead.type, settingable: false }), h("ch-grid-column", { columnName: this._componentLocale.tableHead.description, settingable: false }), h("ch-grid-column", { columnName: this._componentLocale.tableHead.notes, settingable: false })), this.updateResultData.map((obj) => (h("ch-grid-row", { rowid: obj.id }, h("ch-grid-cell", null, " ", this.renderIconResult(obj.result), " "), h("ch-grid-cell", null, h("gxg-icon", { type: obj.typeIcon })), h("ch-grid-cell", null, " ", this.renderIconState(obj.state), " "), h("ch-grid-cell", null, " ", obj.name, " "), h("ch-grid-cell", null, " ", obj.type, " "), h("ch-grid-cell", null, " ", obj.description, " "), h("ch-grid-cell", null, " ", obj.notes, " "), h("ch-grid-rowset", null, obj.messages.map(msg => {
|
|
41
|
+
let msgType;
|
|
42
|
+
switch (msg.type) {
|
|
43
|
+
case "info":
|
|
44
|
+
msgType = "text-alert-info";
|
|
45
|
+
break;
|
|
46
|
+
case "success":
|
|
47
|
+
msgType = "text-alert-success";
|
|
48
|
+
break;
|
|
49
|
+
case "warning":
|
|
50
|
+
msgType = "text-alert-warning";
|
|
51
|
+
break;
|
|
52
|
+
case "error":
|
|
53
|
+
msgType = "text-alert-error";
|
|
54
|
+
break;
|
|
55
|
+
}
|
|
56
|
+
return (h("ch-grid-rowset-empty", null, h("gxg-text", { type: msgType }, msg.text)));
|
|
57
|
+
}))))))));
|
|
58
|
+
};
|
|
59
|
+
this.renderIconState = (state) => {
|
|
60
|
+
let type;
|
|
61
|
+
let color;
|
|
62
|
+
switch (state) {
|
|
63
|
+
case "modified":
|
|
64
|
+
type = "gx-server/changes-commit-pending";
|
|
65
|
+
color = "primary-active";
|
|
66
|
+
break;
|
|
67
|
+
case "inserted":
|
|
68
|
+
type = "gx-server/new";
|
|
69
|
+
color = "success";
|
|
70
|
+
break;
|
|
71
|
+
case "deleted":
|
|
72
|
+
type = "gx-server/delete";
|
|
73
|
+
color = "error";
|
|
74
|
+
break;
|
|
75
|
+
case "conflicted":
|
|
76
|
+
type = "gx-server/conflict";
|
|
77
|
+
color = "warning";
|
|
78
|
+
break;
|
|
79
|
+
}
|
|
80
|
+
return h("gxg-icon", { type: type, color: color });
|
|
81
|
+
};
|
|
82
|
+
this.renderIconResult = (result) => {
|
|
83
|
+
let type;
|
|
84
|
+
let color;
|
|
85
|
+
switch (result) {
|
|
86
|
+
case "info":
|
|
87
|
+
type = "gemini-tools/notice";
|
|
88
|
+
color = "primary-active";
|
|
89
|
+
break;
|
|
90
|
+
case "success":
|
|
91
|
+
type = "gemini-tools/success";
|
|
92
|
+
color = "success";
|
|
93
|
+
break;
|
|
94
|
+
case "warning":
|
|
95
|
+
type = "gemini-tools/warning";
|
|
96
|
+
color = "warning";
|
|
97
|
+
break;
|
|
98
|
+
case "error":
|
|
99
|
+
type = "gemini-tools/error";
|
|
100
|
+
color = "error";
|
|
101
|
+
break;
|
|
102
|
+
}
|
|
103
|
+
return h("gxg-icon", { type: type, color: color });
|
|
104
|
+
};
|
|
105
|
+
this.loadData = async () => {
|
|
106
|
+
const filters = {
|
|
107
|
+
pattern: this.showFilter ? this.filterPatternEl.value : null,
|
|
108
|
+
type: this.showFilter ? this.filterTypeEl.value : null
|
|
109
|
+
};
|
|
110
|
+
// this.updateData = null;
|
|
111
|
+
this.isLoading = true;
|
|
112
|
+
this.updateData = await this.loadCallback(filters);
|
|
113
|
+
this.isLoading = false;
|
|
114
|
+
if (!this.loadDataCalledFirstTime) {
|
|
115
|
+
/* this allows checking the pending commits checkboxes on first load*/
|
|
116
|
+
this.loadDataCalledFirstTime = true;
|
|
117
|
+
}
|
|
118
|
+
};
|
|
119
|
+
this.update = async () => {
|
|
120
|
+
if (this.updateCallback) {
|
|
121
|
+
const pendingForUpdateMarked = await this.chGridPendingForUpdateEl.getMarkedRows();
|
|
122
|
+
this.updateCallback(pendingForUpdateMarked).then((updateResultData) => {
|
|
123
|
+
this.updateResultData = updateResultData;
|
|
124
|
+
this.gxgTabButtonResultsEl.tabButtonClick();
|
|
125
|
+
});
|
|
126
|
+
}
|
|
127
|
+
};
|
|
128
|
+
this.toggleFilter = () => {
|
|
129
|
+
this.showFilter = !this.showFilter;
|
|
130
|
+
};
|
|
131
|
+
this.objectsScope = () => {
|
|
132
|
+
if (this.objectsScopeCallback) {
|
|
133
|
+
this.objectsScopeCallback().then(objectData => {
|
|
134
|
+
if (objectData) {
|
|
135
|
+
this.objectScopeText = objectData;
|
|
136
|
+
}
|
|
137
|
+
});
|
|
138
|
+
}
|
|
139
|
+
};
|
|
140
|
+
this.revisionScope = () => {
|
|
141
|
+
if (this.revisionScopeCallback) {
|
|
142
|
+
this.revisionScopeCallback().then(revisionData => {
|
|
143
|
+
this.revisionScopeText = revisionData;
|
|
144
|
+
});
|
|
145
|
+
}
|
|
146
|
+
};
|
|
147
|
+
this.addListeners = async () => {
|
|
148
|
+
// for pending-for-update grid events
|
|
149
|
+
if (this.updateData.pendingForUpdate) {
|
|
150
|
+
this.chGridPendingForUpdateEl.addEventListener("contextmenu", async (ev) => {
|
|
151
|
+
ev.preventDefault();
|
|
152
|
+
ev.stopPropagation();
|
|
153
|
+
const pendingForUpdateMarked = await this.chGridPendingForUpdateEl.getMarkedRows();
|
|
154
|
+
this.gridContextMenuCallback(pendingForUpdateMarked, "update");
|
|
155
|
+
});
|
|
156
|
+
}
|
|
157
|
+
// for ignored-objects grid events
|
|
158
|
+
this.chGridIgnoredObjectsEl.addEventListener("contextmenu", async (ev) => {
|
|
159
|
+
ev.preventDefault();
|
|
160
|
+
ev.stopPropagation();
|
|
161
|
+
const ignoredObjectsSelected = await this.chGridIgnoredObjectsEl.getSelectedRows();
|
|
162
|
+
this.gridContextMenuCallback(ignoredObjectsSelected, "ignored");
|
|
163
|
+
});
|
|
164
|
+
// for results grid events
|
|
165
|
+
this.chGridResultsEl.addEventListener("contextmenu", async (ev) => {
|
|
166
|
+
ev.preventDefault();
|
|
167
|
+
ev.stopPropagation();
|
|
168
|
+
const resultsObjectsSelected = await this.chGridResultsEl.getMarkedRows();
|
|
169
|
+
this.gridContextMenuCallback(resultsObjectsSelected, "results");
|
|
170
|
+
});
|
|
171
|
+
};
|
|
172
|
+
this.pendingForUpdatesRowMarkingChangedHandler = async (e) => {
|
|
173
|
+
// remove "rowMarkingChanged" until checkboxes have been added/removed on togglePendingCommitsCheckboxes, to prevent loops.
|
|
174
|
+
this.chGridPendingForUpdateEl.removeEventListener("rowMarkingChanged", this.pendingForUpdatesRowMarkingChangedHandler);
|
|
175
|
+
if (this.chGridPendingForUpdateEl) {
|
|
176
|
+
const addedRowsIds = e.detail.addedRowsId;
|
|
177
|
+
const removedRowsId = e.detail.removedRowsId;
|
|
178
|
+
const pendingItemCheckedResult = await this.pendingItemCheckedCallback({
|
|
179
|
+
itemsChecked: addedRowsIds,
|
|
180
|
+
itemsUnchecked: removedRowsId
|
|
181
|
+
});
|
|
182
|
+
if (pendingItemCheckedResult === undefined) {
|
|
183
|
+
// undo check/uncheck
|
|
184
|
+
await this.revertPendingCommitsCheckboxes(addedRowsIds, removedRowsId);
|
|
185
|
+
}
|
|
186
|
+
else {
|
|
187
|
+
await this.togglePendingCommitsCheckboxes(pendingItemCheckedResult);
|
|
188
|
+
}
|
|
189
|
+
this.chGridPendingForUpdateEl.addEventListener("rowMarkingChanged", this.pendingForUpdatesRowMarkingChangedHandler);
|
|
190
|
+
}
|
|
191
|
+
this.chGridPendingForUpdateEl.addEventListener("rowMarkingChanged", this.pendingForUpdatesRowMarkingChangedHandler);
|
|
192
|
+
};
|
|
193
|
+
this.togglePendingCommitsCheckboxes = async (itemsToToggle) => {
|
|
194
|
+
if (this.chGridPendingForUpdateEl) {
|
|
195
|
+
const itemsToCheck = itemsToToggle.itemsToCheck;
|
|
196
|
+
const itemsToUncheck = itemsToToggle.itemsToUncheck;
|
|
197
|
+
// check
|
|
198
|
+
for (const rowId of itemsToCheck) {
|
|
199
|
+
await this.chGridPendingForUpdateEl.markRow(rowId, true);
|
|
200
|
+
}
|
|
201
|
+
// uncheck
|
|
202
|
+
for (const rowId of itemsToUncheck) {
|
|
203
|
+
await this.chGridPendingForUpdateEl.markRow(rowId, false);
|
|
204
|
+
}
|
|
205
|
+
}
|
|
206
|
+
};
|
|
207
|
+
this.revertPendingCommitsCheckboxes = async (addedRowsIds, removedRowsId) => {
|
|
208
|
+
if (this.chGridPendingForUpdateEl) {
|
|
209
|
+
for (const rowId of addedRowsIds) {
|
|
210
|
+
await this.chGridPendingForUpdateEl.markRow(rowId, false);
|
|
211
|
+
}
|
|
212
|
+
for (const rowId of removedRowsId) {
|
|
213
|
+
await this.chGridPendingForUpdateEl.markRow(rowId, true);
|
|
214
|
+
}
|
|
215
|
+
}
|
|
216
|
+
};
|
|
217
|
+
this.isLoading = false;
|
|
218
|
+
this.objectScopeText = "all";
|
|
219
|
+
this.openTab = "pending";
|
|
220
|
+
this.revisionScopeText = undefined;
|
|
221
|
+
this.showFilter = false;
|
|
222
|
+
this.updateData = {
|
|
223
|
+
pendingForUpdate: [],
|
|
224
|
+
ignoredObjects: []
|
|
225
|
+
};
|
|
226
|
+
this.updateResultData = [];
|
|
227
|
+
this.confirmCallback = undefined;
|
|
228
|
+
this.gridContextMenuCallback = undefined;
|
|
229
|
+
this.loadCallback = undefined;
|
|
230
|
+
this.objectsScopeCallback = undefined;
|
|
231
|
+
this.openServerCallback = undefined;
|
|
232
|
+
this.pendingItemCheckedCallback = undefined;
|
|
233
|
+
this.revisionScopeCallback = undefined;
|
|
234
|
+
this.types = undefined;
|
|
235
|
+
this.updateCallback = undefined;
|
|
236
|
+
this.updateFrom = undefined;
|
|
237
|
+
}
|
|
238
|
+
// 6.COMPONENT LIFECYCLE EVENTS //
|
|
239
|
+
async componentWillLoad() {
|
|
240
|
+
this._componentLocale = await Locale.getComponentStrings(this.el);
|
|
241
|
+
this.componentDidLoadEvent.emit(true);
|
|
242
|
+
}
|
|
243
|
+
async componentDidLoad() {
|
|
244
|
+
await this.loadData();
|
|
245
|
+
this.addListeners();
|
|
246
|
+
}
|
|
247
|
+
async componentDidRender() {
|
|
248
|
+
if (this.loadDataCalledFirstTime) {
|
|
249
|
+
// call this method only once
|
|
250
|
+
await this.markAllPendingToUpdateRows();
|
|
251
|
+
// attach "rowMarkingChanged" after rows have been checked for the first time.
|
|
252
|
+
this.chGridPendingForUpdateEl.addEventListener("rowMarkingChanged", this.pendingForUpdatesRowMarkingChangedHandler);
|
|
253
|
+
this.loadDataCalledFirstTime = false;
|
|
254
|
+
}
|
|
255
|
+
}
|
|
256
|
+
// 7.LISTENERS //
|
|
257
|
+
// 8.PUBLIC METHODS API //
|
|
258
|
+
/**
|
|
259
|
+
* Validate necessary data input
|
|
260
|
+
*/
|
|
261
|
+
async validate() {
|
|
262
|
+
const isValid = true;
|
|
263
|
+
return isValid;
|
|
264
|
+
}
|
|
265
|
+
// 10.RENDER() FUNCTION //
|
|
266
|
+
render() {
|
|
267
|
+
return (h(Host, { class: "gx-ide-component" }, h("div", { class: "gx-ide-main-wrapper gx-ide-overflow" }, this.renderOptions(), this.renderFilter(), this.renderData(), h("gxg-container", { displayBorderTop: true }, h("div", { class: "align-center with-gap actions" }, h("gxg-button", { id: "button-update", type: "primary-text-only", onClick: this.update, part: "gxg-button gxg-button--update", disabled: this.isLoading }, this._componentLocale.footer.btnUpdate))))));
|
|
268
|
+
}
|
|
269
|
+
static get assetsDirs() { return ["gx-ide-assets/team-dev-update"]; }
|
|
270
|
+
get el() { return getElement(this); }
|
|
271
|
+
};
|
|
272
|
+
GxIdeTeamDevUpdate.style = teamDevUpdateCss;
|
|
273
|
+
|
|
274
|
+
export { GxIdeTeamDevUpdate as gx_ide_team_dev_update };
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import { r as registerInstance, h, H as Host, g as getElement } from './index-0da01575.js';
|
|
2
|
+
|
|
3
|
+
const topBarCss = ":host{display:block;box-sizing:border-box}.wrapper{display:flex;justify-content:space-between;padding:var(--spacing-comp-01) var(--spacing-comp-02);transition:background-color var(--gx-ide-timing-super-fast-ms);background-color:var(--gray-01)}gxg-title::part(title){color:var(--color-on-secondary);transition:color var(--gx-ide-timing-super-fast-ms)}";
|
|
4
|
+
|
|
5
|
+
const GxIdeTopBar = class {
|
|
6
|
+
constructor(hostRef) {
|
|
7
|
+
registerInstance(this, hostRef);
|
|
8
|
+
this.topBarTitle = undefined;
|
|
9
|
+
}
|
|
10
|
+
// 5.EVENTS (EMIT) //
|
|
11
|
+
// 6.METHODS //
|
|
12
|
+
componentWillLoad() {
|
|
13
|
+
this.evaluateSlots();
|
|
14
|
+
}
|
|
15
|
+
// 7.LISTENERS //
|
|
16
|
+
// 8.PUBLIC METHODS API //
|
|
17
|
+
// 9.LOCAL METHODS //
|
|
18
|
+
evaluateSlots() {
|
|
19
|
+
// header
|
|
20
|
+
const menuSlot = this.el.querySelectorAll('[slot="menu"]');
|
|
21
|
+
if (menuSlot.length) {
|
|
22
|
+
this._hasMenuSlot = true;
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
// 10.RENDER() FUNCTION //
|
|
26
|
+
render() {
|
|
27
|
+
return (h(Host, null, h("div", { class: "wrapper", part: "wrapper" }, h("div", { class: "wrapper__left", part: "wrapper-left" }, h("gxg-title", { type: "title-04", exportparts: "title: gxg-title" }, this.topBarTitle)), h("div", { class: "wrapper__right", part: "wrapper-right" }, this._hasMenuSlot ? (h("gxg-button", { type: "secondary-icon-only", icon: "gemini-tools/show-more-vertical" }, h("slot", { name: "menu" }))) : null))));
|
|
28
|
+
}
|
|
29
|
+
get el() { return getElement(this); }
|
|
30
|
+
};
|
|
31
|
+
GxIdeTopBar.style = topBarCss;
|
|
32
|
+
|
|
33
|
+
export { GxIdeTopBar as gx_ide_top_bar };
|