@genexus/genexus-ide-ui 0.0.32 → 0.0.33
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/genexus-ide-ui.cjs.js +1 -1
- package/dist/cjs/gx-ide-team-dev-commit.cjs.entry.js +17 -4
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/collection/components/team-dev-commit/team-dev-commit.js +20 -6
- package/dist/components/gx-ide-team-dev-commit.js +18 -4
- package/dist/esm/genexus-ide-ui.js +1 -1
- package/dist/esm/gx-ide-team-dev-commit.entry.js +17 -4
- package/dist/esm/loader.js +1 -1
- package/dist/genexus-ide-ui/genexus-ide-ui.esm.js +1 -1
- package/dist/genexus-ide-ui/p-bc2d4253.entry.js +1 -0
- package/dist/types/components/team-dev-commit/team-dev-commit.d.ts +4 -2
- package/package.json +1 -1
- package/dist/genexus-ide-ui/p-b2923298.entry.js +0 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r as t,c as i,h as e,H as o,g as a}from"./p-976c3a09.js";import{L as s}from"./p-26957490.js";import{f as l,r}from"./p-72303355.js";const n=class{constructor(o){t(this,o),this.componentDidLoadEvent=i(this,"componentDidLoadEvent",7),this.loadDataCalledFirstTime=!1,this.conditionToCommit=async()=>{const t=!!this.commitCommentEl.value.length,i=await this.chGridPendingCommitsEl.getMarkedRows();this.commitButtonEnabled=!!(t&&i.length>0)},this.markAllPendingCommitsRows=()=>{this.chGridPendingCommitsEl.markAllRows()},this.togglePendingCommitsCheckboxes=async t=>{if(this.chGridPendingCommitsEl){const i=t.itemsToCheck,e=t.itemsToUncheck;for(const t of i)await this.chGridPendingCommitsEl.markRow(t,!0);for(const t of e)await this.chGridPendingCommitsEl.markRow(t,!1)}},this.revertPendingCommitsCheckboxes=async(t,i)=>{if(this.chGridPendingCommitsEl){for(const i of t)await this.chGridPendingCommitsEl.markRow(i,!1);for(const t of i)await this.chGridPendingCommitsEl.markRow(t,!0)}},this.renderIconState=t=>{let i,o;switch(t){case"inserted":i="gx-server/new",o="success";break;case"modified":i="gx-server/changes-commit-pending",o="primary-active";break;case"deleted":i="gx-server/delete",o="error";break;case"conflicted":i="gx-server/conflict",o="warning"}return e("gxg-icon",{type:i,color:o})},this.pendingCommitsRowMarkingChangedHandler=async t=>{if(this.chGridPendingCommitsEl.removeEventListener("rowMarkingChanged",this.pendingCommitsRowMarkingChangedHandler),this.chGridPendingCommitsEl){const i=t.detail.addedRowsId,e=t.detail.removedRowsId,o=await this.pendingItemsCheckedCallback({itemsChecked:i,itemsUnchecked:e});void 0===o?await this.revertPendingCommitsCheckboxes(i,e):await this.togglePendingCommitsCheckboxes(o),this.conditionToCommit(),this.chGridPendingCommitsEl.addEventListener("rowMarkingChanged",this.pendingCommitsRowMarkingChangedHandler)}},this.objectsOnContextMenuCallbackHandler=t=>async i=>{i.preventDefault(),i.stopPropagation();let e=[];"commit"===t?e=i.detail.selectedRowsId:"ignored"===t&&(e=await this.chGridIgnoredObjectsEl.getSelectedRows()),this.objectsContextMenuCallback&&await this.objectsContextMenuCallback(t,{selection:e,clientX:i.detail.clientX,clientY:i.detail.clientY})},this.gridOnSelectionChangedCallbackHandler=t=>async i=>{this.selectCallback&&await this.selectCallback(t,i.detail.rowsId)},this.renderPendingCommitsGrid=()=>e("gxg-grid",null,e("ch-grid",{rowSelectionMode:"multiple",ref:t=>this.chGridPendingCommitsEl=t,part:"ch-grid-pending-commits",class:"no-border",onRowContextMenu:this.objectsOnContextMenuCallbackHandler("commit"),onSelectionChanged:this.gridOnSelectionChangedCallbackHandler("commit")},e("ch-grid-columnset",null,e("ch-grid-column",{columnType:"rich",richRowSelector:!0,richRowSelectorMode:"mark",settingable:!1,sortable:!1,size:"auto"}),e("ch-grid-column",{columnName:"State",settingable:!1,sortable:!1,size:"auto"}),e("ch-grid-column",{settingable:!1,sortable:!1,size:"auto"}),e("ch-grid-column",{sortable:!0,columnName:"Name",settingable:!1,size:"auto"}),e("ch-grid-column",{sortable:!0,columnName:"Type",settingable:!1,size:"auto"}),e("ch-grid-column",{columnName:"Description",settingable:!1,size:"auto"}),e("ch-grid-column",{sortable:!0,columnName:"Modified On",settingable:!1}),e("ch-grid-column",{columnName:"Module",settingable:!1,size:"auto"}),e("ch-grid-column",{columnName:"Local State",settingable:!1,size:"auto"}),e("ch-grid-column",{columnName:"Last Synchronized",settingable:!1,size:"150px"}),e("ch-grid-column",{sortable:!0,columnName:"User",settingable:!1,size:"auto"})),this.pendingCommits.map((t=>e("ch-grid-row",{rowid:t.id},e("ch-grid-cell",{"cell-type":"rich","row-selector":!0}),e("ch-grid-cell",null," ",this.renderIconState(t.state)," "),e("ch-grid-cell",null,e("gxg-icon",{color:"auto",type:t.iconType})),e("ch-grid-cell",null," ",t.name," "),e("ch-grid-cell",null," ",t.type," "),e("ch-grid-cell",null," ",t.description," "),e("ch-grid-cell",null,`${l(t.modifiedOn)}`),e("ch-grid-cell",null," ",t.module," "),e("ch-grid-cell",null," ",t.localState," "),e("ch-grid-cell",null,`${l(t.lastSynchronized)}`),e("ch-grid-cell",null," ",t.user," ")))))),this.renderIgnoredObjectsGrid=()=>e("gxg-grid",null,e("ch-grid",{rowSelectionMode:"multiple",ref:t=>this.chGridIgnoredObjectsEl=t,part:"ch-grid-pending-commits",onRowContextMenu:this.objectsOnContextMenuCallbackHandler("ignored"),onSelectionChanged:this.gridOnSelectionChangedCallbackHandler("ignored")},e("ch-grid-columnset",null,e("ch-grid-column",{columnName:"",settingable:!1}),e("ch-grid-column",{columnName:"TypeIcon",settingable:!1}),e("ch-grid-column",{columnName:"Name",settingable:!1,sortable:!0}),e("ch-grid-column",{columnName:"Type",settingable:!1}),e("ch-grid-column",{columnName:"Description",settingable:!1}),e("ch-grid-column",{columnName:"Modified On",settingable:!1}),e("ch-grid-column",{columnName:"Module",settingable:!1}),e("ch-grid-column",{columnName:"Local State",settingable:!1}),e("ch-grid-column",{columnName:"Last Synchronized",settingable:!1}),e("ch-grid-column",{columnName:"User",settingable:!1})),this.ignoredObjects.map((t=>e("ch-grid-row",{rowid:t.id,selected:!0},e("ch-grid-cell",null," ",this.renderIconState(t.state)," "),e("ch-grid-cell",null,e("gxg-icon",{color:"auto",type:t.iconType})),e("ch-grid-cell",null," ",t.name," "),e("ch-grid-cell",null," ",t.type," "),e("ch-grid-cell",null," ",t.description," "),e("ch-grid-cell",null,`${l(t.modifiedOn)}`),e("ch-grid-cell",null," ",t.module," "),e("ch-grid-cell",null," ",t.localState," "),e("ch-grid-cell",null,`${l(t.lastSynchronized)}`),e("ch-grid-cell",null," ",t.user," ")))))),this.getRecentCommentHandler=async()=>{if(this.getRecentCommentCallback){const t=await this.getRecentCommentCallback();t&&(this.comment=t)}},this.commitCallbackHandler=async()=>{const t=this.commitCommentEl.value;this.chGridPendingCommitsEl.getMarkedRows().then((async i=>{await this.commitCallback(i,t)}))},this.loadData=async()=>{const t={pattern:this.patternEl.value,changeSet:this.changeSetEl.value,folder:this.foldersEl.value,category:this.categoriesEl.value,type:this.typesEl.value};return await this.loadCallback(t).then((async({pending:t,ignored:i})=>{this.pendingCommits=t,this.ignoredObjects=i}))},this.toggleFiltersHandler=()=>{this.filtersHidden=!this.filtersHidden},this.filtersHidden=!0,this.comment="",this.pendingCommits=[],this.ignoredObjects=[],this.commitButtonEnabled=!1,this.changeSet=void 0,this.types=void 0,this.folders=void 0,this.categories=void 0,this.getRecentCommentCallback=void 0,this.loadCallback=void 0,this.commitCallback=void 0,this.selectCallback=void 0,this.pendingItemsCheckedCallback=void 0,this.objectsContextMenuCallback=void 0}async componentWillLoad(){this._componentLocale=await s.getComponentStrings(this.el)}async componentDidLoad(){await this.loadData(),this.loadDataCalledFirstTime=!0,this.componentDidLoadEvent.emit(!0),this.conditionToCommit()}async componentDidRender(){this.loadDataCalledFirstTime&&(await this.markAllPendingCommitsRows(),this.chGridPendingCommitsEl.addEventListener("rowMarkingChanged",this.pendingCommitsRowMarkingChangedHandler),this.loadDataCalledFirstTime=!1)}async reload(){this.loadData()}render(){return e(o,{class:"gx-ide-component"},e("div",{class:"gx-ide-main-wrapper gx-ide-overflow"},e("gxg-container",null,e("header",{class:"header grid"},e("gxg-form-textarea",{id:"gxg-textarea",height:"100px",label:this._componentLocale.topMenu.commentLabel,value:this.comment,ref:t=>this.commitCommentEl=t,onInput:this.conditionToCommit,placeholder:this._componentLocale.topMenu.commentPlaceholder,part:"comment"}),e("gxg-button",{class:"header-button",type:"outlined",part:"location",onClick:this.getRecentCommentHandler},this._componentLocale.topMenu.recentCommentsButton))),e("main",{class:"main"},e("gxg-container",{fieldset:!0,noContentPadding:!!this.filtersHidden},e("div",{class:"grid second-grid"},e("div",{class:"actions-row grid"},e("gxg-form-text",{class:this.filtersHidden?"hidden":null,"disable-filter":!0,label:this._componentLocale.filtersMenu.patternLabel,labelPosition:"start",value:"",ref:t=>this.patternEl=t,"display-validation-styles":!0,"display-validation-message":!0,part:"pattern",onInput:this.loadData}),e("div",{class:"action-buttons",slot:"tab-bar"},e("gxg-button",{onClick:this.toggleFiltersHandler,type:"secondary-icon-only",icon:"patterns/filters",part:"gxg-button gxg-button--show-filter"}),e("gxg-button",{type:"secondary-icon-only",icon:"gemini-tools/reset",onClick:this.loadData,part:"gxg-button gxg-button--reload"}))),e("div",{class:"filters-grid grid "+(this.filtersHidden?"hidden":null)},e("div",{class:"first-row grid"},e("gxg-combo-box",{labelPosition:"start",label:this._componentLocale.filtersMenu.changesetLabel,value:this.changeSet[0].id,ref:t=>this.changeSetEl=t,part:"change-set","display-validation-styles":!0,"display-validation-message":!0,onValueChanged:this.loadData},r(this.changeSet)),e("gxg-combo-box",{labelPosition:"start",label:this._componentLocale.filtersMenu.typeLabel,value:this.types[0].id,ref:t=>this.typesEl=t,part:"type",onValueChanged:this.loadData},r(this.types))),e("div",{class:"second-row grid"},e("gxg-combo-box",{labelPosition:"start",label:this._componentLocale.filtersMenu.folderLabel,value:this.folders[0].id,ref:t=>this.foldersEl=t,part:"folder","display-validation-styles":!0,"display-validation-message":!0,onValueChanged:this.loadData},r(this.folders)),e("gxg-combo-box",{labelPosition:"start",label:this._componentLocale.filtersMenu.categoryLabel,value:this.categories[0].id,ref:t=>this.categoriesEl=t,part:"categories",onValueChanged:this.loadData},r(this.categories)))))),e("gxg-container",null,e("gxg-tabs",{height:"100%",position:"top",class:"gxg-tabs"},e("gxg-tab-bar",{slot:"tab-bar-container"},e("gxg-tab-button",{slot:"tab-bar","tab-label":`${this._componentLocale.tabs.pendingCommits} (${this.pendingCommits.length})`,tab:"pending-commits","is-selected":!0}),e("gxg-tab-button",{slot:"tab-bar","tab-label":`${this._componentLocale.tabs.ignoredObjects} (${this.ignoredObjects.length})`,tab:"ignored-objects"})),e("gxg-tab",{tab:"pending-commits","no-padding":!0},this.renderPendingCommitsGrid()),e("gxg-tab",{tab:"ignored-objects","no-padding":!0},this.renderIgnoredObjectsGrid())),e("gxg-button",{slot:"footer",type:"primary-text-only",onClick:this.commitCallbackHandler,part:"commit-button",disabled:!this.commitButtonEnabled},this._componentLocale.footer.commitButton)))))}static get assetsDirs(){return["gx-ide-assets/team-dev-commit"]}get el(){return a(this)}};n.style=".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}.header .header-button{height:fit-content}.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)}";export{n as gx_ide_team_dev_commit}
|
|
@@ -14,11 +14,12 @@ export declare class GxIdeTeamDevCommit {
|
|
|
14
14
|
private categoriesEl;
|
|
15
15
|
private chGridPendingCommitsEl;
|
|
16
16
|
private chGridIgnoredObjectsEl;
|
|
17
|
-
private
|
|
17
|
+
private commitCommentEl;
|
|
18
18
|
filtersHidden: boolean;
|
|
19
19
|
comment: string;
|
|
20
20
|
pendingCommits: ModifiedObjectData[];
|
|
21
21
|
ignoredObjects: ModifiedObjectData[];
|
|
22
|
+
commitButtonEnabled: boolean;
|
|
22
23
|
/**
|
|
23
24
|
* Possible values for ChangeSet filter
|
|
24
25
|
*/
|
|
@@ -70,6 +71,7 @@ export declare class GxIdeTeamDevCommit {
|
|
|
70
71
|
* The method used by the Host to instruct the component to force a data refresh in the grids.
|
|
71
72
|
*/
|
|
72
73
|
reload(): Promise<void>;
|
|
74
|
+
private conditionToCommit;
|
|
73
75
|
private markAllPendingCommitsRows;
|
|
74
76
|
private togglePendingCommitsCheckboxes;
|
|
75
77
|
private revertPendingCommitsCheckboxes;
|
|
@@ -87,7 +89,7 @@ export declare class GxIdeTeamDevCommit {
|
|
|
87
89
|
}
|
|
88
90
|
export type GetRecentComment = () => Promise<string | undefined>;
|
|
89
91
|
export type LoadCallback = (filters: FiltersData) => Promise<CommitData>;
|
|
90
|
-
export type CommitCallback = (selection: string[],
|
|
92
|
+
export type CommitCallback = (selection: string[], commitCommentEl: string) => Promise<boolean>;
|
|
91
93
|
export type PendingItemsCheckedCallback = (pendingItemsCheckedState: ItemsCheckedState) => Promise<ItemsCheckedResult | undefined>;
|
|
92
94
|
export type CommitSelectCallback = (grid: CommitSourceType, selectionIds: string[]) => Promise<void>;
|
|
93
95
|
export type ItemCheckedCallback = (checkedItemIds: string[]) => Promise<ItemsCheckedResult | undefined>;
|
package/package.json
CHANGED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{r as t,c as i,h as e,H as o,g as a}from"./p-976c3a09.js";import{L as l}from"./p-26957490.js";import{f as s,r}from"./p-72303355.js";const n=class{constructor(o){t(this,o),this.componentDidLoadEvent=i(this,"componentDidLoadEvent",7),this.loadDataCalledFirstTime=!1,this.markAllPendingCommitsRows=()=>{this.chGridPendingCommitsEl.markAllRows()},this.togglePendingCommitsCheckboxes=async t=>{if(this.chGridPendingCommitsEl){const i=t.itemsToCheck,e=t.itemsToUncheck;for(const t of i)await this.chGridPendingCommitsEl.markRow(t,!0);for(const t of e)await this.chGridPendingCommitsEl.markRow(t,!1)}},this.revertPendingCommitsCheckboxes=async(t,i)=>{if(this.chGridPendingCommitsEl){for(const i of t)await this.chGridPendingCommitsEl.markRow(i,!1);for(const t of i)await this.chGridPendingCommitsEl.markRow(t,!0)}},this.renderIconState=t=>{let i,o;switch(t){case"inserted":i="gx-server/new",o="success";break;case"modified":i="gx-server/changes-commit-pending",o="primary-active";break;case"deleted":i="gx-server/delete",o="error";break;case"conflicted":i="gx-server/conflict",o="warning"}return e("gxg-icon",{type:i,color:o})},this.pendingCommitsRowMarkingChangedHandler=async t=>{if(this.chGridPendingCommitsEl.removeEventListener("rowMarkingChanged",this.pendingCommitsRowMarkingChangedHandler),this.chGridPendingCommitsEl){const i=t.detail.addedRowsId,e=t.detail.removedRowsId,o=await this.pendingItemsCheckedCallback({itemsChecked:i,itemsUnchecked:e});void 0===o?await this.revertPendingCommitsCheckboxes(i,e):await this.togglePendingCommitsCheckboxes(o),this.chGridPendingCommitsEl.addEventListener("rowMarkingChanged",this.pendingCommitsRowMarkingChangedHandler)}},this.objectsOnContextMenuCallbackHandler=t=>async i=>{i.preventDefault(),i.stopPropagation();let e=[];"commit"===t?e=i.detail.selectedRowsId:"ignored"===t&&(e=await this.chGridIgnoredObjectsEl.getSelectedRows()),this.objectsContextMenuCallback&&await this.objectsContextMenuCallback(t,{selection:e,clientX:i.detail.clientX,clientY:i.detail.clientY})},this.gridOnSelectionChangedCallbackHandler=t=>async i=>{this.selectCallback&&await this.selectCallback(t,i.detail.rowsId)},this.renderPendingCommitsGrid=()=>e("gxg-grid",null,e("ch-grid",{rowSelectionMode:"multiple",ref:t=>this.chGridPendingCommitsEl=t,part:"ch-grid-pending-commits",class:"no-border",onRowContextMenu:this.objectsOnContextMenuCallbackHandler("commit"),onSelectionChanged:this.gridOnSelectionChangedCallbackHandler("commit")},e("ch-grid-columnset",null,e("ch-grid-column",{columnType:"rich",richRowSelector:!0,richRowSelectorMode:"mark",settingable:!1,sortable:!1,size:"auto"}),e("ch-grid-column",{columnName:"State",settingable:!1,sortable:!1,size:"auto"}),e("ch-grid-column",{settingable:!1,sortable:!1,size:"auto"}),e("ch-grid-column",{sortable:!0,columnName:"Name",settingable:!1,size:"auto"}),e("ch-grid-column",{sortable:!0,columnName:"Type",settingable:!1,size:"auto"}),e("ch-grid-column",{columnName:"Description",settingable:!1,size:"auto"}),e("ch-grid-column",{sortable:!0,columnName:"Modified On",settingable:!1}),e("ch-grid-column",{columnName:"Module",settingable:!1,size:"auto"}),e("ch-grid-column",{columnName:"Local State",settingable:!1,size:"auto"}),e("ch-grid-column",{columnName:"Last Synchronized",settingable:!1,size:"150px"}),e("ch-grid-column",{sortable:!0,columnName:"User",settingable:!1,size:"auto"})),this.pendingCommits.map((t=>e("ch-grid-row",{rowid:t.id},e("ch-grid-cell",{"cell-type":"rich","row-selector":!0}),e("ch-grid-cell",null," ",this.renderIconState(t.state)," "),e("ch-grid-cell",null,e("gxg-icon",{color:"auto",type:t.iconType})),e("ch-grid-cell",null," ",t.name," "),e("ch-grid-cell",null," ",t.type," "),e("ch-grid-cell",null," ",t.description," "),e("ch-grid-cell",null,`${s(t.modifiedOn)}`),e("ch-grid-cell",null," ",t.module," "),e("ch-grid-cell",null," ",t.localState," "),e("ch-grid-cell",null,`${s(t.lastSynchronized)}`),e("ch-grid-cell",null," ",t.user," ")))))),this.renderIgnoredObjectsGrid=()=>e("gxg-grid",null,e("ch-grid",{rowSelectionMode:"multiple",ref:t=>this.chGridIgnoredObjectsEl=t,part:"ch-grid-pending-commits",onRowContextMenu:this.objectsOnContextMenuCallbackHandler("ignored"),onSelectionChanged:this.gridOnSelectionChangedCallbackHandler("ignored")},e("ch-grid-columnset",null,e("ch-grid-column",{columnName:"",settingable:!1}),e("ch-grid-column",{columnName:"TypeIcon",settingable:!1}),e("ch-grid-column",{columnName:"Name",settingable:!1,sortable:!0}),e("ch-grid-column",{columnName:"Type",settingable:!1}),e("ch-grid-column",{columnName:"Description",settingable:!1}),e("ch-grid-column",{columnName:"Modified On",settingable:!1}),e("ch-grid-column",{columnName:"Module",settingable:!1}),e("ch-grid-column",{columnName:"Local State",settingable:!1}),e("ch-grid-column",{columnName:"Last Synchronized",settingable:!1}),e("ch-grid-column",{columnName:"User",settingable:!1})),this.ignoredObjects.map((t=>e("ch-grid-row",{rowid:t.id,selected:!0},e("ch-grid-cell",null," ",this.renderIconState(t.state)," "),e("ch-grid-cell",null,e("gxg-icon",{color:"auto",type:t.iconType})),e("ch-grid-cell",null," ",t.name," "),e("ch-grid-cell",null," ",t.type," "),e("ch-grid-cell",null," ",t.description," "),e("ch-grid-cell",null,`${s(t.modifiedOn)}`),e("ch-grid-cell",null," ",t.module," "),e("ch-grid-cell",null," ",t.localState," "),e("ch-grid-cell",null,`${s(t.lastSynchronized)}`),e("ch-grid-cell",null," ",t.user," ")))))),this.getRecentCommentHandler=async()=>{if(this.getRecentCommentCallback){const t=await this.getRecentCommentCallback();t&&(this.comment=t)}},this.commitCallbackHandler=async()=>{const t=this.commitComment.value;this.chGridPendingCommitsEl.getMarkedRows().then((async i=>{await this.commitCallback(i,t)}))},this.loadData=async()=>{const t={pattern:this.patternEl.value,changeSet:this.changeSetEl.value,folder:this.foldersEl.value,category:this.categoriesEl.value,type:this.typesEl.value};return await this.loadCallback(t).then((async({pending:t,ignored:i})=>{this.pendingCommits=t,this.ignoredObjects=i}))},this.toggleFiltersHandler=()=>{this.filtersHidden=!this.filtersHidden},this.filtersHidden=!0,this.comment="",this.pendingCommits=[],this.ignoredObjects=[],this.changeSet=void 0,this.types=void 0,this.folders=void 0,this.categories=void 0,this.getRecentCommentCallback=void 0,this.loadCallback=void 0,this.commitCallback=void 0,this.selectCallback=void 0,this.pendingItemsCheckedCallback=void 0,this.objectsContextMenuCallback=void 0}async componentWillLoad(){this._componentLocale=await l.getComponentStrings(this.el)}async componentDidLoad(){await this.loadData(),this.loadDataCalledFirstTime=!0,this.componentDidLoadEvent.emit(!0)}async componentDidRender(){this.loadDataCalledFirstTime&&(await this.markAllPendingCommitsRows(),this.chGridPendingCommitsEl.addEventListener("rowMarkingChanged",this.pendingCommitsRowMarkingChangedHandler),this.loadDataCalledFirstTime=!1)}async reload(){this.loadData()}render(){return e(o,{class:"gx-ide-component"},e("div",{class:"gx-ide-main-wrapper gx-ide-overflow"},e("gxg-container",null,e("header",{class:"header grid"},e("gxg-form-textarea",{id:"gxg-textarea",height:"100px",label:this._componentLocale.topMenu.commentLabel,value:this.comment,ref:t=>this.commitComment=t,placeholder:this._componentLocale.topMenu.commentPlaceholder,part:"comment"}),e("gxg-button",{class:"header-button",type:"outlined",part:"location",onClick:this.getRecentCommentHandler},this._componentLocale.topMenu.recentCommentsButton))),e("main",{class:"main"},e("gxg-container",{fieldset:!0,noContentPadding:!!this.filtersHidden},e("div",{class:"grid second-grid"},e("div",{class:"actions-row grid"},e("gxg-form-text",{class:this.filtersHidden?"hidden":null,"disable-filter":!0,label:this._componentLocale.filtersMenu.patternLabel,labelPosition:"start",value:"",ref:t=>this.patternEl=t,"display-validation-styles":!0,"display-validation-message":!0,part:"pattern",onInput:this.loadData}),e("div",{class:"action-buttons",slot:"tab-bar"},e("gxg-button",{onClick:this.toggleFiltersHandler,type:"secondary-icon-only",icon:"patterns/filters",part:"gxg-button gxg-button--show-filter"}),e("gxg-button",{type:"secondary-icon-only",icon:"gemini-tools/reset",onClick:this.loadData,part:"gxg-button gxg-button--reload"}))),e("div",{class:"filters-grid grid "+(this.filtersHidden?"hidden":null)},e("div",{class:"first-row grid"},e("gxg-combo-box",{labelPosition:"start",label:this._componentLocale.filtersMenu.changesetLabel,value:this.changeSet[0].id,ref:t=>this.changeSetEl=t,part:"change-set","display-validation-styles":!0,"display-validation-message":!0,onValueChanged:this.loadData},r(this.changeSet)),e("gxg-combo-box",{labelPosition:"start",label:this._componentLocale.filtersMenu.typeLabel,value:this.types[0].id,ref:t=>this.typesEl=t,part:"type",onValueChanged:this.loadData},r(this.types))),e("div",{class:"second-row grid"},e("gxg-combo-box",{labelPosition:"start",label:this._componentLocale.filtersMenu.folderLabel,value:this.folders[0].id,ref:t=>this.foldersEl=t,part:"folder","display-validation-styles":!0,"display-validation-message":!0,onValueChanged:this.loadData},r(this.folders)),e("gxg-combo-box",{labelPosition:"start",label:this._componentLocale.filtersMenu.categoryLabel,value:this.categories[0].id,ref:t=>this.categoriesEl=t,part:"categories",onValueChanged:this.loadData},r(this.categories)))))),e("gxg-container",null,e("gxg-tabs",{height:"100%",position:"top",class:"gxg-tabs"},e("gxg-tab-bar",{slot:"tab-bar-container"},e("gxg-tab-button",{slot:"tab-bar","tab-label":`${this._componentLocale.tabs.pendingCommits} (${this.pendingCommits.length})`,tab:"pending-commits","is-selected":!0}),e("gxg-tab-button",{slot:"tab-bar","tab-label":`${this._componentLocale.tabs.ignoredObjects} (${this.ignoredObjects.length})`,tab:"ignored-objects"})),e("gxg-tab",{tab:"pending-commits","no-padding":!0},this.renderPendingCommitsGrid()),e("gxg-tab",{tab:"ignored-objects","no-padding":!0},this.renderIgnoredObjectsGrid())),e("gxg-button",{slot:"footer",type:"primary-text-only",onClick:this.commitCallbackHandler,part:"commit-button"},this._componentLocale.footer.commitButton)))))}static get assetsDirs(){return["gx-ide-assets/team-dev-commit"]}get el(){return a(this)}};n.style=".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}.header .header-button{height:fit-content}.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)}";export{n as gx_ide_team_dev_commit}
|