@genexus/genexus-ide-ui 0.0.134 → 0.0.136
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/gx-ide-bpm-timer-duration.cjs.entry.js +1 -1
- package/dist/cjs/gx-ide-bpm-timer-duration.cjs.entry.js.map +1 -1
- package/dist/cjs/gx-ide-connect-gx-server.cjs.entry.js +3 -5
- package/dist/cjs/gx-ide-connect-gx-server.cjs.entry.js.map +1 -1
- package/dist/collection/components/bpm/timer-duration/timer-duration.js +1 -1
- package/dist/collection/components/bpm/timer-duration/timer-duration.js.map +1 -1
- package/dist/collection/components/connect-gx-server/connect-gx-server.js +7 -9
- package/dist/collection/components/connect-gx-server/connect-gx-server.js.map +1 -1
- package/dist/components/gx-ide-bpm-timer-duration.js +1 -1
- package/dist/components/gx-ide-bpm-timer-duration.js.map +1 -1
- package/dist/components/gx-ide-connect-gx-server.js +3 -5
- package/dist/components/gx-ide-connect-gx-server.js.map +1 -1
- package/dist/esm/gx-ide-bpm-timer-duration.entry.js +1 -1
- package/dist/esm/gx-ide-bpm-timer-duration.entry.js.map +1 -1
- package/dist/esm/gx-ide-connect-gx-server.entry.js +3 -5
- package/dist/esm/gx-ide-connect-gx-server.entry.js.map +1 -1
- package/dist/genexus-ide-ui/genexus-ide-ui.esm.js +1 -1
- package/dist/genexus-ide-ui/{p-7b258a37.entry.js → p-56aaeefb.entry.js} +5 -5
- package/dist/genexus-ide-ui/{p-7b258a37.entry.js.map → p-56aaeefb.entry.js.map} +1 -1
- package/dist/genexus-ide-ui/{p-64de1e77.entry.js → p-89dd5963.entry.js} +5 -5
- package/dist/genexus-ide-ui/p-89dd5963.entry.js.map +1 -0
- package/dist/types/components/connect-gx-server/connect-gx-server.d.ts +5 -3
- package/dist/types/components.d.ts +4 -4
- package/package.json +1 -1
- package/dist/genexus-ide-ui/p-64de1e77.entry.js.map +0 -1
|
@@ -47,7 +47,7 @@ const GxIdeBpmTimerDuration = class {
|
|
|
47
47
|
// 10.RENDER() FUNCTION //
|
|
48
48
|
render() {
|
|
49
49
|
var _a, _b, _c, _d, _e, _f;
|
|
50
|
-
return (index.h(index.Host, { class: "gx-ide-component" }, index.h("div", { class: "gx-ide-main-wrapper" }, index.h("gx-ide-container", { containerTitle: this.displayTitle ? this._componentLocale.componentName : null, slimmerFooter: config.config.gxIdeContainer.slimmerFooter }, index.h("div", { class: "control-wrapper control-wrapper--vertical" }, index.h("label", { htmlFor: "years" }, this._componentLocale.controls.years), index.h("input", { type: "number", id: "years", class: "input-text input-text--full-width", value: (_a = this.duration) === null || _a === void 0 ? void 0 : _a.years.toString(), ref: el => (this.yearsEl = el) })), index.h("div", { class: "control-wrapper control-wrapper--vertical" }, index.h("label", { htmlFor: "months" }, this._componentLocale.controls.months), index.h("input", { type: "number", id: "months", class: "input-text input-text--full-width", value: (_b = this.duration) === null || _b === void 0 ? void 0 : _b.months.toString(), ref: el => (this.monthsEl = el) })), index.h("div", { class: "control-wrapper control-wrapper--vertical" }, index.h("label", { htmlFor: "days" }, this._componentLocale.controls.days), index.h("input", { type: "number", id: "days", class: "input-text input-text--full-width", value: (_c = this.duration) === null || _c === void 0 ? void 0 : _c.
|
|
50
|
+
return (index.h(index.Host, { class: "gx-ide-component" }, index.h("div", { class: "gx-ide-main-wrapper" }, index.h("gx-ide-container", { containerTitle: this.displayTitle ? this._componentLocale.componentName : null, slimmerFooter: config.config.gxIdeContainer.slimmerFooter }, index.h("div", { class: "control-wrapper control-wrapper--vertical" }, index.h("label", { htmlFor: "years" }, this._componentLocale.controls.years), index.h("input", { type: "number", id: "years", class: "input-text input-text--full-width", value: (_a = this.duration) === null || _a === void 0 ? void 0 : _a.years.toString(), ref: el => (this.yearsEl = el) })), index.h("div", { class: "control-wrapper control-wrapper--vertical" }, index.h("label", { htmlFor: "months" }, this._componentLocale.controls.months), index.h("input", { type: "number", id: "months", class: "input-text input-text--full-width", value: (_b = this.duration) === null || _b === void 0 ? void 0 : _b.months.toString(), ref: el => (this.monthsEl = el) })), index.h("div", { class: "control-wrapper control-wrapper--vertical" }, index.h("label", { htmlFor: "days" }, this._componentLocale.controls.days), index.h("input", { type: "number", id: "days", class: "input-text input-text--full-width", value: (_c = this.duration) === null || _c === void 0 ? void 0 : _c.days.toString(), ref: el => (this.daysEl = el) })), index.h("div", { class: "control-wrapper control-wrapper--vertical" }, index.h("label", { htmlFor: "hours" }, this._componentLocale.controls.hours), index.h("input", { type: "number", id: "hours", class: "input-text input-text--full-width", value: (_d = this.duration) === null || _d === void 0 ? void 0 : _d.hours.toString(), ref: el => (this.hoursEl = el) })), index.h("div", { class: "control-wrapper control-wrapper--vertical" }, index.h("label", { htmlFor: "minutes" }, this._componentLocale.controls.minutes), index.h("input", { type: "number", id: "minutes", class: "input-text input-text--full-width", value: (_e = this.duration) === null || _e === void 0 ? void 0 : _e.minutes.toString(), ref: el => (this.minutesEl = el) })), index.h("div", { class: "control-wrapper control-wrapper--vertical" }, index.h("label", { htmlFor: "seconds" }, this._componentLocale.controls.seconds), index.h("input", { type: "number", id: "seconds", class: "input-text input-text--full-width", value: (_f = this.duration) === null || _f === void 0 ? void 0 : _f.seconds.toString(), ref: el => (this.secondsEl = el) })), index.h("div", { class: "controls-wrapper" }, index.h("button", { onClick: this.confirmCallbackHandler }, this._componentLocale.controls.ok), index.h("button", { onClick: this.cancelCallback }, this._componentLocale.controls.cancel))))));
|
|
51
51
|
}
|
|
52
52
|
static get assetsDirs() { return ["gx-ide-assets/bpm-timer-duration"]; }
|
|
53
53
|
get el() { return index.getElement(this); }
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"file":"gx-ide-bpm-timer-duration.entry.cjs.js","mappings":";;;;;;;;AAAA,MAAM,gBAAgB,GAAG,q7WAAq7W;;MCqBj8W,qBAAqB;;;;QAOxB,sBAAiB,GAAG,KAAK,CAAC;;;;QAgE1B,2BAAsB,GAAG;YAC/B,IAAI,IAAI,CAAC,eAAe,EAAE;gBACxB,MAAM,IAAI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,EACvC,GAAG,EAAE,EAAE,KAAK,IAAI,CAAC,OAAO,GAAG,EAAsB,CAAC,GAClD,CACE,EAENA,iBAAK,KAAK,EAAC,2CAA2C,IACpDA,mBAAO,OAAO,EAAC,SAAS,IACrB,IAAI,CAAC,gBAAgB,CAAC,QAAQ,CAAC,OAAO,CACjC,EACRA,mBACE,IAAI,EAAC,QAAQ,EACb,EAAE,EAAC,SAAS,EACZ,KAAK,EAAC,mCAAmC,EACzC,KAAK,EAAE,MAAA,IAAI,CAAC,QAAQ,0CAAE,MAAM,CAAC,QAAQ,EAAE,EACvC,GAAG,EAAE,EAAE,KAAK,IAAI,CAAC,SAAS,GAAG,EAAsB,CAAC,GACpD,CACE,EAENA,iBAAK,KAAK,EAAC,2CAA2C,IACpDA,mBAAO,OAAO,EAAC,SAAS,IACrB,IAAI,CAAC,gBAAgB,CAAC,QAAQ,CAAC,OAAO,CACjC,EACRA,mBACE,IAAI,EAAC,QAAQ,EACb,EAAE,EAAC,SAAS,EACZ,KAAK,EAAC,mCAAmC,EACzC,KAAK,EAAE,MAAA,IAAI,CAAC,QAAQ,0CAAE,MAAM,CAAC,QAAQ,EAAE,EACvC,GAAG,EAAE,EAAE,KAAK,IAAI,CAAC,SAAS,GAAG,EAAsB,CAAC,GACpD,CACE,EAENA,iBAAK,KAAK,EAAC,kBAAkB,IAC3BA,oBAAQ,OAAO,EAAE,IAAI,CAAC,sBAAsB,IACzC,IAAI,CAAC,gBAAgB,CAAC,QAAQ,CAAC,EAAE,CAC3B,EACTA,oBAAQ,OAAO,EAAE,IAAI,CAAC,cAAc,IACjC,IAAI,CAAC,gBAAgB,CAAC,QAAQ,CAAC,MAAM,CAC/B,CACL,CACW,CACf,CACD,EACP;KACH;;;;;;;;","names":["Locale","h","Host","config"],"sources":["src/components/bpm/timer-duration/timer-duration.scss?tag=gx-ide-bpm-timer-duration&encapsulation=shadow","src/components/bpm/timer-duration/timer-duration.tsx"],"sourcesContent":["@import \"../../../global/gx-ide-common.scss\";\n@import \"../../../global/gx-ide-mixins.scss\";\n@import \"../../../global/temporary-tokens-chameleon.scss\";\n\n:host {\n display: block;\n}\n","/* STENCIL IMPORTS */\nimport {\n Component,\n Host,\n h,\n Prop,\n Element,\n Event,\n EventEmitter\n} from \"@stencil/core\";\n/* OTHER LIBRARIES IMPORTS */\n/* CUSTOM IMPORTS */\nimport { config } from \"../../../common/config\";\nimport { Locale } from \"../../../common/locale\";\n\n@Component({\n tag: \"gx-ide-bpm-timer-duration\",\n styleUrl: \"timer-duration.scss\",\n shadow: true,\n assetsDirs: [\"gx-ide-assets/bpm-timer-duration\"]\n})\nexport class GxIdeBpmTimerDuration {\n // 1.OWN PROPERTIES //\n\n /**\n * The component hard-coded strings translations.\n */\n private _componentLocale: any;\n private renderedFirstTime = false;\n\n // 2. REFERENCE TO ELEMENTS //\n\n @Element() el: HTMLGxIdeBpmTimerDurationElement;\n\n private yearsEl!: HTMLInputElement;\n private monthsEl!: HTMLInputElement;\n private daysEl!: HTMLInputElement;\n private hoursEl!: HTMLInputElement;\n private minutesEl!: HTMLInputElement;\n private secondsEl!: HTMLInputElement;\n\n // 3.STATE() VARIABLES //\n\n // 4.PUBLIC PROPERTY API | WATCH'S //\n\n /**\n * If true it displays the component title on the header\n */\n @Prop() readonly displayTitle = false;\n\n /**\n * Current value for timer.\n */\n @Prop() readonly duration?: TimerDuration;\n\n /**\n * Callback invoked when user confirms application declaration, (OK Button)\n */\n @Prop() readonly confirmCallback: (data: TimerDuration) => Promise<void>;\n\n /**\n * Callback invoked when user cancels application declaration */\n @Prop() readonly cancelCallback: () => Promise<void>;\n\n // 5.EVENTS (EMIT) //\n\n /**\n * @description Gets fired when the component has rendered for the first time.\n */\n @Event() componentDidRenderFirstTime: EventEmitter<string>;\n\n // 6.COMPONENT LIFECYCLE METHODS //\n\n async componentWillLoad() {\n this._componentLocale = await Locale.getComponentStrings(this.el);\n }\n\n componentDidRender() {\n if (!this.renderedFirstTime) {\n this.componentDidRenderFirstTime.emit(\n this._componentLocale.componentName\n );\n this.renderedFirstTime = true;\n }\n }\n\n // 7.LISTENERS //\n\n // 8.PUBLIC METHODS API //\n\n // 9.LOCAL METHODS //\n\n private confirmCallbackHandler = async () => {\n if (this.confirmCallback) {\n const data: TimerDuration = {\n years: parseInt(this.yearsEl.value),\n months: parseInt(this.monthsEl.value),\n days: parseInt(this.daysEl.value),\n hours: parseInt(this.hoursEl.value),\n minutes: parseInt(this.minutesEl.value),\n seconds: parseInt(this.secondsEl.value)\n };\n\n await this.confirmCallback(data);\n }\n };\n\n // 10.RENDER() FUNCTION //\n\n render() {\n return (\n <Host class=\"gx-ide-component\">\n <div class=\"gx-ide-main-wrapper\">\n <gx-ide-container\n containerTitle={\n this.displayTitle ? this._componentLocale.componentName : null\n }\n slimmerFooter={config.gxIdeContainer.slimmerFooter}\n >\n <div class=\"control-wrapper control-wrapper--vertical\">\n <label htmlFor=\"years\">\n {this._componentLocale.controls.years}\n </label>\n <input\n type=\"number\"\n id=\"years\"\n class=\"input-text input-text--full-width\"\n value={this.duration?.years.toString()}\n ref={el => (this.yearsEl = el as HTMLInputElement)}\n />\n </div>\n\n <div class=\"control-wrapper control-wrapper--vertical\">\n <label htmlFor=\"months\">\n {this._componentLocale.controls.months}\n </label>\n <input\n type=\"number\"\n id=\"months\"\n class=\"input-text input-text--full-width\"\n value={this.duration?.months.toString()}\n ref={el => (this.monthsEl = el as HTMLInputElement)}\n />\n </div>\n\n <div class=\"control-wrapper control-wrapper--vertical\">\n <label htmlFor=\"days\">\n {this._componentLocale.controls.days}\n </label>\n <input\n type=\"number\"\n id=\"days\"\n class=\"input-text input-text--full-width\"\n value={this.duration?.months.toString()}\n ref={el => (this.daysEl = el as HTMLInputElement)}\n />\n </div>\n\n <div class=\"control-wrapper control-wrapper--vertical\">\n <label htmlFor=\"hours\">\n {this._componentLocale.controls.hours}\n </label>\n <input\n type=\"number\"\n id=\"hours\"\n class=\"input-text input-text--full-width\"\n value={this.duration?.months.toString()}\n ref={el => (this.hoursEl = el as HTMLInputElement)}\n />\n </div>\n\n <div class=\"control-wrapper control-wrapper--vertical\">\n <label htmlFor=\"minutes\">\n {this._componentLocale.controls.minutes}\n </label>\n <input\n type=\"number\"\n id=\"minutes\"\n class=\"input-text input-text--full-width\"\n value={this.duration?.months.toString()}\n ref={el => (this.minutesEl = el as HTMLInputElement)}\n />\n </div>\n\n <div class=\"control-wrapper control-wrapper--vertical\">\n <label htmlFor=\"seconds\">\n {this._componentLocale.controls.seconds}\n </label>\n <input\n type=\"number\"\n id=\"seconds\"\n class=\"input-text input-text--full-width\"\n value={this.duration?.months.toString()}\n ref={el => (this.secondsEl = el as HTMLInputElement)}\n />\n </div>\n\n <div class=\"controls-wrapper\">\n <button onClick={this.confirmCallbackHandler}>\n {this._componentLocale.controls.ok}\n </button>\n <button onClick={this.cancelCallback}>\n {this._componentLocale.controls.cancel}\n </button>\n </div>\n </gx-ide-container>\n </div>\n </Host>\n );\n }\n}\n\nexport type TimerDuration = {\n years: number;\n months: number;\n days: number;\n hours: number;\n minutes: number;\n seconds: number;\n};\n"],"version":3}
|
|
1
|
+
{"file":"gx-ide-bpm-timer-duration.entry.cjs.js","mappings":";;;;;;;;AAAA,MAAM,gBAAgB,GAAG,q7WAAq7W;;MCqBj8W,qBAAqB;;;;QAOxB,sBAAiB,GAAG,KAAK,CAAC;;;;QAgE1B,2BAAsB,GAAG;YAC/B,IAAI,IAAI,CAAC,eAAe,EAAE;gBACxB,MAAM,IAAI,GAAkB;oBAC1B,KAAK,EAAE,QAAQ,CAAC,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC;oBACnC,MAAM,EAAE,QAAQ,CAAC,IAAI,CAAC,QAAQ,CAAC,KAAK,CAAC;oBACrC,IAAI,EAAE,QAAQ,CAAC,IAAI,CAAC,MAAM,CAAC,KAAK,CAAC;oBACjC,KAAK,EAAE,QAAQ,CAAC,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC;oBACnC,OAAO,EAAE,QAAQ,CAAC,I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,QAAQ,0CAAE,OAAO,CAAC,QAAQ,EAAE,EACxC,GAAG,EAAE,EAAE,KAAK,IAAI,CAAC,SAAS,GAAG,EAAsB,CAAC,GACpD,CACE,EAENA,iBAAK,KAAK,EAAC,2CAA2C,IACpDA,mBAAO,OAAO,EAAC,SAAS,IACrB,IAAI,CAAC,gBAAgB,CAAC,QAAQ,CAAC,OAAO,CACjC,EACRA,mBACE,IAAI,EAAC,QAAQ,EACb,EAAE,EAAC,SAAS,EACZ,KAAK,EAAC,mCAAmC,EACzC,KAAK,EAAE,MAAA,IAAI,CAAC,QAAQ,0CAAE,OAAO,CAAC,QAAQ,EAAE,EACxC,GAAG,EAAE,EAAE,KAAK,IAAI,CAAC,SAAS,GAAG,EAAsB,CAAC,GACpD,CACE,EAENA,iBAAK,KAAK,EAAC,kBAAkB,IAC3BA,oBAAQ,OAAO,EAAE,IAAI,CAAC,sBAAsB,IACzC,IAAI,CAAC,gBAAgB,CAAC,QAAQ,CAAC,EAAE,CAC3B,EACTA,oBAAQ,OAAO,EAAE,IAAI,CAAC,cAAc,IACjC,IAAI,CAAC,gBAAgB,CAAC,QAAQ,CAAC,MAAM,CAC/B,CACL,CACW,CACf,CACD,EACP;KACH;;;;;;;;","names":["Locale","h","Host","config"],"sources":["src/components/bpm/timer-duration/timer-duration.scss?tag=gx-ide-bpm-timer-duration&encapsulation=shadow","src/components/bpm/timer-duration/timer-duration.tsx"],"sourcesContent":["@import \"../../../global/gx-ide-common.scss\";\n@import \"../../../global/gx-ide-mixins.scss\";\n@import \"../../../global/temporary-tokens-chameleon.scss\";\n\n:host {\n display: block;\n}\n","/* STENCIL IMPORTS */\nimport {\n Component,\n Host,\n h,\n Prop,\n Element,\n Event,\n EventEmitter\n} from \"@stencil/core\";\n/* OTHER LIBRARIES IMPORTS */\n/* CUSTOM IMPORTS */\nimport { config } from \"../../../common/config\";\nimport { Locale } from \"../../../common/locale\";\n\n@Component({\n tag: \"gx-ide-bpm-timer-duration\",\n styleUrl: \"timer-duration.scss\",\n shadow: true,\n assetsDirs: [\"gx-ide-assets/bpm-timer-duration\"]\n})\nexport class GxIdeBpmTimerDuration {\n // 1.OWN PROPERTIES //\n\n /**\n * The component hard-coded strings translations.\n */\n private _componentLocale: any;\n private renderedFirstTime = false;\n\n // 2. REFERENCE TO ELEMENTS //\n\n @Element() el: HTMLGxIdeBpmTimerDurationElement;\n\n private yearsEl!: HTMLInputElement;\n private monthsEl!: HTMLInputElement;\n private daysEl!: HTMLInputElement;\n private hoursEl!: HTMLInputElement;\n private minutesEl!: HTMLInputElement;\n private secondsEl!: HTMLInputElement;\n\n // 3.STATE() VARIABLES //\n\n // 4.PUBLIC PROPERTY API | WATCH'S //\n\n /**\n * If true it displays the component title on the header\n */\n @Prop() readonly displayTitle = false;\n\n /**\n * Current value for timer.\n */\n @Prop() readonly duration?: TimerDuration;\n\n /**\n * Callback invoked when user confirms application declaration, (OK Button)\n */\n @Prop() readonly confirmCallback: (data: TimerDuration) => Promise<void>;\n\n /**\n * Callback invoked when user cancels application declaration */\n @Prop() readonly cancelCallback: () => Promise<void>;\n\n // 5.EVENTS (EMIT) //\n\n /**\n * @description Gets fired when the component has rendered for the first time.\n */\n @Event() componentDidRenderFirstTime: EventEmitter<string>;\n\n // 6.COMPONENT LIFECYCLE METHODS //\n\n async componentWillLoad() {\n this._componentLocale = await Locale.getComponentStrings(this.el);\n }\n\n componentDidRender() {\n if (!this.renderedFirstTime) {\n this.componentDidRenderFirstTime.emit(\n this._componentLocale.componentName\n );\n this.renderedFirstTime = true;\n }\n }\n\n // 7.LISTENERS //\n\n // 8.PUBLIC METHODS API //\n\n // 9.LOCAL METHODS //\n\n private confirmCallbackHandler = async () => {\n if (this.confirmCallback) {\n const data: TimerDuration = {\n years: parseInt(this.yearsEl.value),\n months: parseInt(this.monthsEl.value),\n days: parseInt(this.daysEl.value),\n hours: parseInt(this.hoursEl.value),\n minutes: parseInt(this.minutesEl.value),\n seconds: parseInt(this.secondsEl.value)\n };\n\n await this.confirmCallback(data);\n }\n };\n\n // 10.RENDER() FUNCTION //\n\n render() {\n return (\n <Host class=\"gx-ide-component\">\n <div class=\"gx-ide-main-wrapper\">\n <gx-ide-container\n containerTitle={\n this.displayTitle ? this._componentLocale.componentName : null\n }\n slimmerFooter={config.gxIdeContainer.slimmerFooter}\n >\n <div class=\"control-wrapper control-wrapper--vertical\">\n <label htmlFor=\"years\">\n {this._componentLocale.controls.years}\n </label>\n <input\n type=\"number\"\n id=\"years\"\n class=\"input-text input-text--full-width\"\n value={this.duration?.years.toString()}\n ref={el => (this.yearsEl = el as HTMLInputElement)}\n />\n </div>\n\n <div class=\"control-wrapper control-wrapper--vertical\">\n <label htmlFor=\"months\">\n {this._componentLocale.controls.months}\n </label>\n <input\n type=\"number\"\n id=\"months\"\n class=\"input-text input-text--full-width\"\n value={this.duration?.months.toString()}\n ref={el => (this.monthsEl = el as HTMLInputElement)}\n />\n </div>\n\n <div class=\"control-wrapper control-wrapper--vertical\">\n <label htmlFor=\"days\">\n {this._componentLocale.controls.days}\n </label>\n <input\n type=\"number\"\n id=\"days\"\n class=\"input-text input-text--full-width\"\n value={this.duration?.days.toString()}\n ref={el => (this.daysEl = el as HTMLInputElement)}\n />\n </div>\n\n <div class=\"control-wrapper control-wrapper--vertical\">\n <label htmlFor=\"hours\">\n {this._componentLocale.controls.hours}\n </label>\n <input\n type=\"number\"\n id=\"hours\"\n class=\"input-text input-text--full-width\"\n value={this.duration?.hours.toString()}\n ref={el => (this.hoursEl = el as HTMLInputElement)}\n />\n </div>\n\n <div class=\"control-wrapper control-wrapper--vertical\">\n <label htmlFor=\"minutes\">\n {this._componentLocale.controls.minutes}\n </label>\n <input\n type=\"number\"\n id=\"minutes\"\n class=\"input-text input-text--full-width\"\n value={this.duration?.minutes.toString()}\n ref={el => (this.minutesEl = el as HTMLInputElement)}\n />\n </div>\n\n <div class=\"control-wrapper control-wrapper--vertical\">\n <label htmlFor=\"seconds\">\n {this._componentLocale.controls.seconds}\n </label>\n <input\n type=\"number\"\n id=\"seconds\"\n class=\"input-text input-text--full-width\"\n value={this.duration?.seconds.toString()}\n ref={el => (this.secondsEl = el as HTMLInputElement)}\n />\n </div>\n\n <div class=\"controls-wrapper\">\n <button onClick={this.confirmCallbackHandler}>\n {this._componentLocale.controls.ok}\n </button>\n <button onClick={this.cancelCallback}>\n {this._componentLocale.controls.cancel}\n </button>\n </div>\n </gx-ide-container>\n </div>\n </Host>\n );\n }\n}\n\nexport type TimerDuration = {\n years: number;\n months: number;\n days: number;\n hours: number;\n minutes: number;\n seconds: number;\n};\n"],"version":3}
|
|
@@ -72,11 +72,9 @@ const GxIdeConnectGxServer = class {
|
|
|
72
72
|
}
|
|
73
73
|
// 10.RENDER() FUNCTION //
|
|
74
74
|
render() {
|
|
75
|
-
var _a;
|
|
76
|
-
return (index.h(index.Host, { class: "gx-ide-component" }, index.h("div", { class: "gx-ide-main-wrapper" }, index.h("gx-ide-container", { containerTitle: this.displayTitle ? this._componentLocale.componentName : null, slimmerFooter: config.config.gxIdeContainer.slimmerFooter }, index.h("div", { class: "wrapper" }, index.h("gxg-combo-box", { label: this._componentLocale.main.serverUrl, disableFilter: !this.enableCustomServer, value: (_a = this.defaultConnectionData) === null || _a === void 0 ? void 0 : _a.serverUrl, ref: el => (this.serverURLEl = el), toolTip: config.config.tooltip }, this.renderServerUrls()), index.h("gxg-form-checkbox", { label: this._componentLocale.main.continueWithGxAccount, onChange: this.continueWithGxServerHandler, checked: this.
|
|
77
|
-
? this.defaultConnectionData.
|
|
78
|
-
: this.enableUserLogged, disabled: !this.enableUserLogged, ref: el => (this.continueWithGeneXusAccountEl =
|
|
79
|
-
el) }), this.displayLoginControls ? (index.h("div", { class: "user-details-container" }, index.h("gxg-form-text", { label: this._componentLocale.main.userName, labelPosition: "above", disabled: !this.displayLoginControls, value: this.defaultConnectionData.user, ref: el => (this.userNameEl = el), toolTip: config.config.tooltip }), index.h("gxg-form-text", { label: this._componentLocale.main.password, labelPosition: "above", disabled: !this.displayLoginControls, value: this.defaultConnectionData.password, ref: el => (this.passwordEl = el), password: true, toolTip: config.config.tooltip }))) : null), index.h("gxg-button", { slot: "footer-end", type: "outlined" }, this._componentLocale.main.cancel), index.h("gxg-button", { slot: "footer-end", onClick: this.connectHandler }, this._componentLocale.main.connect)))));
|
|
75
|
+
var _a, _b, _c;
|
|
76
|
+
return (index.h(index.Host, { class: "gx-ide-component" }, index.h("div", { class: "gx-ide-main-wrapper" }, index.h("gx-ide-container", { containerTitle: this.displayTitle ? this._componentLocale.componentName : null, slimmerFooter: config.config.gxIdeContainer.slimmerFooter }, index.h("div", { class: "wrapper" }, index.h("gxg-combo-box", { label: this._componentLocale.main.serverUrl, disableFilter: !this.enableCustomServer, value: (_a = this.defaultConnectionData) === null || _a === void 0 ? void 0 : _a.serverUrl, ref: el => (this.serverURLEl = el), toolTip: config.config.tooltip }, this.renderServerUrls()), index.h("gxg-form-checkbox", { label: this._componentLocale.main.continueWithGxAccount, onChange: this.continueWithGxServerHandler, checked: this.enableUserLogged, disabled: !this.enableUserLogged, ref: el => (this.continueWithGeneXusAccountEl =
|
|
77
|
+
el) }), this.displayLoginControls ? (index.h("div", { class: "user-details-container" }, index.h("gxg-form-text", { label: this._componentLocale.main.userName, labelPosition: "above", disabled: !this.displayLoginControls, value: (_b = this.defaultConnectionData) === null || _b === void 0 ? void 0 : _b.user, ref: el => (this.userNameEl = el), toolTip: config.config.tooltip }), index.h("gxg-form-text", { label: this._componentLocale.main.password, labelPosition: "above", disabled: !this.displayLoginControls, value: (_c = this.defaultConnectionData) === null || _c === void 0 ? void 0 : _c.password, ref: el => (this.passwordEl = el), password: true, toolTip: config.config.tooltip }))) : null), index.h("gxg-button", { slot: "footer-end", type: "outlined" }, this._componentLocale.main.cancel), index.h("gxg-button", { slot: "footer-end", onClick: this.connectHandler }, this._componentLocale.main.connect)))));
|
|
80
78
|
}
|
|
81
79
|
static get assetsDirs() { return ["gx-ide-assets/connect-gx-server"]; }
|
|
82
80
|
get el() { return index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B,EAE3B,QAAQ,EAAE,CAAC,IAAI,CAAC,gBAAgB,EAChC,GAAG,EAAE,EAAE,KACJ,IAAI,CAAC,4BAA4B;gBAChC,EAAgC,CAAC,GAElB,EAEpB,IAAI,CAAC,oBAAoB,IACxBA,iBAAK,KAAK,EAAC,wBAAwB,IAEjCA,2BACE,KAAK,EAAE,IAAI,CAAC,gBAAgB,CAAC,IAAI,CAAC,QAAQ,EAC1C,aAAa,EAAC,OAAO,EACrB,QAAQ,EAAE,CAAC,IAAI,CAAC,oBAAoB,EACpC,KAAK,EAAE,IAAI,CAAC,qBAAqB,CAAC,IAAI,EACtC,GAAG,EAAE,EAAE,KAAK,IAAI,CAAC,UAAU,GAAG,EAA4B,CAAC,EAC3D,OAAO,EAAEI,aAAM,CAAC,OAAO,GACR,EAEjBJ,2BACE,KAAK,EAAE,IAAI,CAAC,gBAAgB,CAAC,IAAI,CAAC,QAAQ,EAC1C,aAAa,EAAC,OAAO,EACrB,QAAQ,EAAE,CAAC,IAAI,CAAC,oBAAoB,EACpC,KAAK,EAAE,IAAI,CAAC,qBAAqB,CAAC,QAAQ,EAC1C,GAAG,EAAE,EAAE,KAAK,IAAI,CAAC,UAAU,GAAG,EAA4B,CAAC,EAC3D,QAAQ,QACR,OAAO,EAAEI,aAAM,CAAC,OAAO,GACR,CACb,IACJ,IAAI,CACJ,EAGNJ,wBAAY,IAAI,EAAC,YAAY,EAAC,IAAI,EAAC,UAAU,IAC1C,IAAI,CAAC,gBAAgB,CAAC,IAAI,CAAC,MAAM,CACvB,EACbA,wBAAY,IAAI,EAAC,YAAY,EAAC,OAAO,EAAE,IAAI,CAAC,cAAc,IACvD,IAAI,CAAC,gBAAgB,CAAC,IAAI,CAAC,OAAO,CACxB,CACI,CACf,CACD,EACP;KACH;;;;;;;;","names":["h","formSubmitValidation","Locale","Host","config"],"sources":["src/components/connect-gx-server/connect-gx-server.scss?tag=gx-ide-connect-gx-server&encapsulation=shadow","src/components/connect-gx-server/connect-gx-server.tsx"],"sourcesContent":["@import \"../../global/gx-ide-common.scss\";\n@import \"../../global/gx-ide-mixins.scss\";\n\n:host {\n display: block;\n}\n\n.user-details-container {\n display: flex;\n gap: var(--gx-ide-form-items-gap);\n}\n\n.wrapper {\n display: flex;\n flex-direction: column;\n gap: var(--mer-spacing--md);\n}\n","/* STENCIL IMPORTS */\nimport {\n Component,\n Host,\n h,\n Prop,\n Element,\n Event,\n EventEmitter,\n State\n} from \"@stencil/core\";\n/* OTHER LIBRARIES IMPORTS */\n/* CUSTOM IMPORTS */\nimport { config } from \"../../common/config\";\nimport { Locale } from \"../../common/locale\";\nimport { formSubmitValidation } from \"../../common/form-validation\";\nimport { ConnectionResultData } from \"../../common/types\";\n\n@Component({\n tag: \"gx-ide-connect-gx-server\",\n styleUrl: \"connect-gx-server.scss\",\n shadow: true,\n assetsDirs: [\"gx-ide-assets/connect-gx-server\"]\n})\nexport class GxIdeConnectGxServer {\n // 1.OWN PROPERTIES //\n\n /**\n * The component hard-coded strings translations.\n */\n private _componentLocale: any;\n private renderedFirstTime = false;\n\n // 2. REFERENCE TO ELEMENTS //\n\n @Element() el: HTMLGxIdeConnectGxServerElement;\n\n private serverURLEl!: HTMLGxgComboBoxElement;\n private userNameEl!: HTMLGxgFormTextElement;\n private passwordEl!: HTMLGxgFormTextElement;\n private continueWithGeneXusAccountEl!: HTMLGxgFormCheckboxElement;\n\n // 3.STATE() VARIABLES //\n\n //\n @State() displayLoginControls: boolean = false;\n\n // 4.PUBLIC PROPERTY API | WATCH'S //\n\n /**\n * If true it displays the component title on the header\n */\n @Prop() readonly displayTitle = false;\n\n /**\n * Array of cataloged server URLs\n */\n @Prop() readonly serverUrls: string[];\n\n /**\n * 'true' if the user should be allowed to manually enter a server URL in serverUrls.\n */\n @Prop() readonly enableCustomServer: boolean = false;\n\n /**\n * Initial user values for the case in which the user returns to the login modal after a successful authentication.\n */\n @Prop() readonly defaultConnectionData?: GXServerConnectionData;\n\n /**\n * If 'true', shows the enabled and checked 'Continue with GX Account' checkbox. If 'false', shows the checkbox unchecked and disabled, and displays the options to enter username and password directly. Even if 'true', allow the user to deselect the checkbox and enter username and password.\n */\n @Prop() readonly enableUserLogged: boolean = false;\n\n /**\n * If 'true', shows the enabled and checked 'Continue with GX Account' checkbox. If 'false', shows the checkbox unchecked and disabled, and displays the options to enter username and password directly. Even if 'true', allow the user to deselect the checkbox and enter username and password.\n */\n @Prop() readonly connectCallback: (\n data: GXServerConnectionData\n ) => Promise<ConnectionResultData>;\n\n /**\n * Callback that allows canceling the server connection process.\n */\n @Prop() readonly cancelCallback: () => Promise<void>;\n\n // 5.EVENTS (EMIT) //\n\n /**\n * @description Gets fired when the component has rendered for the first time.\n */\n @Event() componentDidRenderFirstTime: EventEmitter<string>;\n\n // 6.COMPONENT LIFECYCLE METHODS //\n\n async componentWillLoad() {\n this._componentLocale = await Locale.getComponentStrings(this.el);\n this.evaluateDisplayLoginControls();\n }\n\n componentDidRender() {\n if (!this.renderedFirstTime) {\n this.componentDidRenderFirstTime.emit(\n this._componentLocale.componentName\n );\n this.renderedFirstTime = true;\n }\n }\n\n // 7.LISTENERS //\n\n // 8.PUBLIC METHODS API //\n\n // 9.LOCAL METHODS //\n\n private renderServerUrls = (): HTMLGxgComboBoxItemElement[] => {\n if (this.serverUrls?.length) {\n return this.serverUrls.map(serverUrl => {\n return <gxg-combo-box-item>{serverUrl}</gxg-combo-box-item>;\n });\n }\n return [];\n };\n\n private continueWithGxServerHandler = (\n event: CustomEvent<{ id: string; value: boolean; disabled?: boolean }>\n ) => {\n this.displayLoginControls = !event.detail.value;\n };\n\n private evaluateDisplayLoginControls = () => {\n if (this.enableUserLogged) {\n this.displayLoginControls = false;\n } else {\n this.displayLoginControls = true;\n }\n };\n\n private connectHandler = () => {\n if (this.connectCallback) {\n this.connectCallback({\n serverUrl: this.serverURLEl.value,\n continueWithGeneXusAccount: this.continueWithGeneXusAccountEl.checked,\n user: this.userNameEl.value,\n password: this.passwordEl.value\n }).then((formSubmitResult: ConnectionResultData) => {\n console.log(formSubmitResult);\n formSubmitValidation(formSubmitResult, this);\n });\n }\n };\n\n // 10.RENDER() FUNCTION //\n\n render() {\n return (\n <Host class=\"gx-ide-component\">\n <div class=\"gx-ide-main-wrapper\">\n <gx-ide-container\n containerTitle={\n this.displayTitle ? this._componentLocale.componentName : null\n }\n slimmerFooter={config.gxIdeContainer.slimmerFooter}\n >\n <div class=\"wrapper\">\n {/* server url */}\n <gxg-combo-box\n label={this._componentLocale.main.serverUrl}\n disableFilter={!this.enableCustomServer}\n value={this.defaultConnectionData?.serverUrl}\n ref={el => (this.serverURLEl = el as HTMLGxgComboBoxElement)}\n toolTip={config.tooltip}\n >\n {this.renderServerUrls()}\n </gxg-combo-box>\n\n {/* continue with GeneXus account */}\n <gxg-form-checkbox\n label={this._componentLocale.main.continueWithGxAccount}\n onChange={this.continueWithGxServerHandler}\n checked={\n this.defaultConnectionData\n ? this.defaultConnectionData.continueWithGeneXusAccount\n : this.enableUserLogged\n }\n disabled={!this.enableUserLogged}\n ref={el =>\n (this.continueWithGeneXusAccountEl =\n el as HTMLGxgFormCheckboxElement)\n }\n ></gxg-form-checkbox>\n\n {this.displayLoginControls ? (\n <div class=\"user-details-container\">\n {/* username */}\n <gxg-form-text\n label={this._componentLocale.main.userName}\n labelPosition=\"above\"\n disabled={!this.displayLoginControls}\n value={this.defaultConnectionData.user}\n ref={el => (this.userNameEl = el as HTMLGxgFormTextElement)}\n toolTip={config.tooltip}\n ></gxg-form-text>\n {/* password */}\n <gxg-form-text\n label={this._componentLocale.main.password}\n labelPosition=\"above\"\n disabled={!this.displayLoginControls}\n value={this.defaultConnectionData.password}\n ref={el => (this.passwordEl = el as HTMLGxgFormTextElement)}\n password\n toolTip={config.tooltip}\n ></gxg-form-text>\n </div>\n ) : null}\n </div>\n\n {/* cancel and connect buttons */}\n <gxg-button slot=\"footer-end\" type=\"outlined\">\n {this._componentLocale.main.cancel}\n </gxg-button>\n <gxg-button slot=\"footer-end\" onClick={this.connectHandler}>\n {this._componentLocale.main.connect}\n </gxg-button>\n </gx-ide-container>\n </div>\n </Host>\n );\n }\n}\n\nexport type GXServerConnectionData = {\n serverUrl: string;\n continueWithGeneXusAccount: boolean;\n user: string;\n password: string;\n};\n"],"version":3}
|
|
1
|
+
{"file":"gx-ide-connect-gx-server.entry.cjs.js","mappings":";;;;;;;;;AAAA,MAAM,kBAAkB,GAAG,0gWAA0gW;;MCwBxhW,oBAAoB;;;;QAOvB,sBAAiB,GAAG,KAAK,CAAC;;;;QAoF1B,qBAAgB,GAAG;;YACzB,IAAI,MAAA,IAAI,CAAC,UAAU,0CAAE,MAAM,EAAE;gBAC3B,OAAO,IAAI,CAAC,UAAU,CAAC,GAAG,CAAC,SAAS;oBAClC,OAAOA,oCAAqB,SAAS,CAAsB,CAAC;iBAC7D,CAAC,CAAC;aACJ;YACD,OAAO,EAAE,CAAC;SACX,CAAC;QAEM,gCAA2B,GAAG,CACpC,KAAsE;YAEtE,IAAI,CAAC,oBAAoB,GAAG,CAAC,KAAK,CAAC,MAAM,CAAC,KAAK,CAAC;SACjD,CAAC;QAEM,iCAA4B,GAAG;YACrC,IAAI,IAAI,CAAC,gBAAgB,EAAE;gBACzB,IAAI,CAAC,oBAAoB,GAAG,KAAK,CAAC;aACnC;iBAAM;gBACL,IAAI,CAAC,oBAAoB,GAAG,IAAI,CAAC;aAClC;SACF,CAAC;QAEM,mBAAc,GAAG;YACvB,IAAI,IAAI,CAAC,eAAe,EAAE;gBACxB,IAAI,CAAC,eAAe,CAAC;oBACnB,SAAS,EAAE,IAAI,CAAC,WAAW,CAAC,KAAK;oBACjC,0BAA0B,EAAE,IAAI,CAAC,4BAA4B,CAAC,OAAO;oBACrE,IAAI,EAAE,IAAI,CAAC,UAAU,CAAC,KAAK;oBAC3B,QAAQ,EAAE,IAAI,CAAC,UAAU,CAAC,KAAK;iBAChC,CAAC,CAAC,IAAI,CAAC,CAAC,gBAAsC;oBAC7C,OAAO,CAAC,GAAG,CAAC,gBA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/connect-gx-server.scss?tag=gx-ide-connect-gx-server&encapsulation=shadow","src/components/connect-gx-server/connect-gx-server.tsx"],"sourcesContent":["@import \"../../global/gx-ide-common.scss\";\n@import \"../../global/gx-ide-mixins.scss\";\n\n:host {\n display: block;\n}\n\n.user-details-container {\n display: flex;\n gap: var(--gx-ide-form-items-gap);\n}\n\n.wrapper {\n display: flex;\n flex-direction: column;\n gap: var(--mer-spacing--md);\n}\n","/* STENCIL IMPORTS */\nimport {\n Component,\n Host,\n h,\n Prop,\n Element,\n Event,\n EventEmitter,\n State\n} from \"@stencil/core\";\n/* OTHER LIBRARIES IMPORTS */\n/* CUSTOM IMPORTS */\nimport { config } from \"../../common/config\";\nimport { Locale } from \"../../common/locale\";\nimport { formSubmitValidation } from \"../../common/form-validation\";\nimport { ConnectionResultData } from \"../../common/types\";\n\n@Component({\n tag: \"gx-ide-connect-gx-server\",\n styleUrl: \"connect-gx-server.scss\",\n shadow: true,\n assetsDirs: [\"gx-ide-assets/connect-gx-server\"]\n})\nexport class GxIdeConnectGxServer {\n // 1.OWN PROPERTIES //\n\n /**\n * The component hard-coded strings translations.\n */\n private _componentLocale: any;\n private renderedFirstTime = false;\n\n // 2. REFERENCE TO ELEMENTS //\n\n @Element() el: HTMLGxIdeConnectGxServerElement;\n\n private serverURLEl!: HTMLGxgComboBoxElement;\n private userNameEl!: HTMLGxgFormTextElement;\n private passwordEl!: HTMLGxgFormTextElement;\n private continueWithGeneXusAccountEl!: HTMLGxgFormCheckboxElement;\n\n // 3.STATE() VARIABLES //\n\n //\n @State() displayLoginControls: boolean = false;\n\n // 4.PUBLIC PROPERTY API | WATCH'S //\n\n /**\n * If true it displays the component title on the header\n */\n @Prop() readonly displayTitle = false;\n\n /**\n * Array of cataloged server URLs\n */\n @Prop() readonly serverUrls: string[];\n\n /**\n * 'true' if the user should be allowed to manually enter a server URL in serverUrls.\n */\n @Prop() readonly enableCustomServer: boolean = false;\n\n /**\n * Initial user values for the case in which the user returns to the login modal after a successful authentication.\n */\n @Prop() readonly defaultConnectionData?: GXServerConnectionDefault;\n\n /**\n * If 'true', shows the enabled and checked 'Continue with GX Account' checkbox. If 'false', shows the checkbox unchecked and disabled, and displays the options to enter username and password directly. Even if 'true', allow the user to deselect the checkbox and enter username and password.\n */\n @Prop() readonly enableUserLogged: boolean = false;\n\n /**\n * If 'true', shows the enabled and checked 'Continue with GX Account' checkbox. If 'false', shows the checkbox unchecked and disabled, and displays the options to enter username and password directly. Even if 'true', allow the user to deselect the checkbox and enter username and password.\n */\n @Prop() readonly connectCallback: (\n data: GXServerConnectionData\n ) => Promise<ConnectionResultData>;\n\n /**\n * Callback that allows canceling the server connection process.\n */\n @Prop() readonly cancelCallback: () => Promise<void>;\n\n // 5.EVENTS (EMIT) //\n\n /**\n * @description Gets fired when the component has rendered for the first time.\n */\n @Event() componentDidRenderFirstTime: EventEmitter<string>;\n\n // 6.COMPONENT LIFECYCLE METHODS //\n\n async componentWillLoad() {\n this._componentLocale = await Locale.getComponentStrings(this.el);\n this.evaluateDisplayLoginControls();\n }\n\n componentDidRender() {\n if (!this.renderedFirstTime) {\n this.componentDidRenderFirstTime.emit(\n this._componentLocale.componentName\n );\n this.renderedFirstTime = true;\n }\n }\n\n // 7.LISTENERS //\n\n // 8.PUBLIC METHODS API //\n\n // 9.LOCAL METHODS //\n\n private renderServerUrls = (): HTMLGxgComboBoxItemElement[] => {\n if (this.serverUrls?.length) {\n return this.serverUrls.map(serverUrl => {\n return <gxg-combo-box-item>{serverUrl}</gxg-combo-box-item>;\n });\n }\n return [];\n };\n\n private continueWithGxServerHandler = (\n event: CustomEvent<{ id: string; value: boolean; disabled?: boolean }>\n ) => {\n this.displayLoginControls = !event.detail.value;\n };\n\n private evaluateDisplayLoginControls = () => {\n if (this.enableUserLogged) {\n this.displayLoginControls = false;\n } else {\n this.displayLoginControls = true;\n }\n };\n\n private connectHandler = () => {\n if (this.connectCallback) {\n this.connectCallback({\n serverUrl: this.serverURLEl.value,\n continueWithGeneXusAccount: this.continueWithGeneXusAccountEl.checked,\n user: this.userNameEl.value,\n password: this.passwordEl.value\n }).then((formSubmitResult: ConnectionResultData) => {\n console.log(formSubmitResult);\n formSubmitValidation(formSubmitResult, this);\n });\n }\n };\n\n // 10.RENDER() FUNCTION //\n\n render() {\n return (\n <Host class=\"gx-ide-component\">\n <div class=\"gx-ide-main-wrapper\">\n <gx-ide-container\n containerTitle={\n this.displayTitle ? this._componentLocale.componentName : null\n }\n slimmerFooter={config.gxIdeContainer.slimmerFooter}\n >\n <div class=\"wrapper\">\n {/* server url */}\n <gxg-combo-box\n label={this._componentLocale.main.serverUrl}\n disableFilter={!this.enableCustomServer}\n value={this.defaultConnectionData?.serverUrl}\n ref={el => (this.serverURLEl = el as HTMLGxgComboBoxElement)}\n toolTip={config.tooltip}\n >\n {this.renderServerUrls()}\n </gxg-combo-box>\n\n {/* continue with GeneXus account */}\n <gxg-form-checkbox\n label={this._componentLocale.main.continueWithGxAccount}\n onChange={this.continueWithGxServerHandler}\n checked={this.enableUserLogged}\n disabled={!this.enableUserLogged}\n ref={el =>\n (this.continueWithGeneXusAccountEl =\n el as HTMLGxgFormCheckboxElement)\n }\n ></gxg-form-checkbox>\n\n {this.displayLoginControls ? (\n <div class=\"user-details-container\">\n {/* username */}\n <gxg-form-text\n label={this._componentLocale.main.userName}\n labelPosition=\"above\"\n disabled={!this.displayLoginControls}\n value={this.defaultConnectionData?.user}\n ref={el => (this.userNameEl = el as HTMLGxgFormTextElement)}\n toolTip={config.tooltip}\n ></gxg-form-text>\n {/* password */}\n <gxg-form-text\n label={this._componentLocale.main.password}\n labelPosition=\"above\"\n disabled={!this.displayLoginControls}\n value={this.defaultConnectionData?.password}\n ref={el => (this.passwordEl = el as HTMLGxgFormTextElement)}\n password\n toolTip={config.tooltip}\n ></gxg-form-text>\n </div>\n ) : null}\n </div>\n\n {/* cancel and connect buttons */}\n <gxg-button slot=\"footer-end\" type=\"outlined\">\n {this._componentLocale.main.cancel}\n </gxg-button>\n <gxg-button slot=\"footer-end\" onClick={this.connectHandler}>\n {this._componentLocale.main.connect}\n </gxg-button>\n </gx-ide-container>\n </div>\n </Host>\n );\n }\n}\n\nexport type GXServerConnectionDefault = {\n serverUrl: string;\n user: string;\n password: string;\n};\n\nexport type GXServerConnectionData = GXServerConnectionDefault & {\n continueWithGeneXusAccount: boolean;\n};\n"],"version":3}
|
|
@@ -41,7 +41,7 @@ export class GxIdeBpmTimerDuration {
|
|
|
41
41
|
// 10.RENDER() FUNCTION //
|
|
42
42
|
render() {
|
|
43
43
|
var _a, _b, _c, _d, _e, _f;
|
|
44
|
-
return (h(Host, { class: "gx-ide-component" }, h("div", { class: "gx-ide-main-wrapper" }, h("gx-ide-container", { containerTitle: this.displayTitle ? this._componentLocale.componentName : null, slimmerFooter: config.gxIdeContainer.slimmerFooter }, h("div", { class: "control-wrapper control-wrapper--vertical" }, h("label", { htmlFor: "years" }, this._componentLocale.controls.years), h("input", { type: "number", id: "years", class: "input-text input-text--full-width", value: (_a = this.duration) === null || _a === void 0 ? void 0 : _a.years.toString(), ref: el => (this.yearsEl = el) })), h("div", { class: "control-wrapper control-wrapper--vertical" }, h("label", { htmlFor: "months" }, this._componentLocale.controls.months), h("input", { type: "number", id: "months", class: "input-text input-text--full-width", value: (_b = this.duration) === null || _b === void 0 ? void 0 : _b.months.toString(), ref: el => (this.monthsEl = el) })), h("div", { class: "control-wrapper control-wrapper--vertical" }, h("label", { htmlFor: "days" }, this._componentLocale.controls.days), h("input", { type: "number", id: "days", class: "input-text input-text--full-width", value: (_c = this.duration) === null || _c === void 0 ? void 0 : _c.
|
|
44
|
+
return (h(Host, { class: "gx-ide-component" }, h("div", { class: "gx-ide-main-wrapper" }, h("gx-ide-container", { containerTitle: this.displayTitle ? this._componentLocale.componentName : null, slimmerFooter: config.gxIdeContainer.slimmerFooter }, h("div", { class: "control-wrapper control-wrapper--vertical" }, h("label", { htmlFor: "years" }, this._componentLocale.controls.years), h("input", { type: "number", id: "years", class: "input-text input-text--full-width", value: (_a = this.duration) === null || _a === void 0 ? void 0 : _a.years.toString(), ref: el => (this.yearsEl = el) })), h("div", { class: "control-wrapper control-wrapper--vertical" }, h("label", { htmlFor: "months" }, this._componentLocale.controls.months), h("input", { type: "number", id: "months", class: "input-text input-text--full-width", value: (_b = this.duration) === null || _b === void 0 ? void 0 : _b.months.toString(), ref: el => (this.monthsEl = el) })), h("div", { class: "control-wrapper control-wrapper--vertical" }, h("label", { htmlFor: "days" }, this._componentLocale.controls.days), h("input", { type: "number", id: "days", class: "input-text input-text--full-width", value: (_c = this.duration) === null || _c === void 0 ? void 0 : _c.days.toString(), ref: el => (this.daysEl = el) })), h("div", { class: "control-wrapper control-wrapper--vertical" }, h("label", { htmlFor: "hours" }, this._componentLocale.controls.hours), h("input", { type: "number", id: "hours", class: "input-text input-text--full-width", value: (_d = this.duration) === null || _d === void 0 ? void 0 : _d.hours.toString(), ref: el => (this.hoursEl = el) })), h("div", { class: "control-wrapper control-wrapper--vertical" }, h("label", { htmlFor: "minutes" }, this._componentLocale.controls.minutes), h("input", { type: "number", id: "minutes", class: "input-text input-text--full-width", value: (_e = this.duration) === null || _e === void 0 ? void 0 : _e.minutes.toString(), ref: el => (this.minutesEl = el) })), h("div", { class: "control-wrapper control-wrapper--vertical" }, h("label", { htmlFor: "seconds" }, this._componentLocale.controls.seconds), h("input", { type: "number", id: "seconds", class: "input-text input-text--full-width", value: (_f = this.duration) === null || _f === void 0 ? void 0 : _f.seconds.toString(), ref: el => (this.secondsEl = el) })), h("div", { class: "controls-wrapper" }, h("button", { onClick: this.confirmCallbackHandler }, this._componentLocale.controls.ok), h("button", { onClick: this.cancelCallback }, this._componentLocale.controls.cancel))))));
|
|
45
45
|
}
|
|
46
46
|
static get is() { return "gx-ide-bpm-timer-duration"; }
|
|
47
47
|
static get encapsulation() { return "shadow"; }
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"timer-duration.js","sourceRoot":"","sources":["../../../../src/components/bpm/timer-duration/tim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E,EAAC,SAAS,EACZ,KAAK,EAAC,mCAAmC,EACzC,KAAK,EAAE,MAAA,IAAI,CAAC,QAAQ,0CAAE,MAAM,CAAC,QAAQ,EAAE,EACvC,GAAG,EAAE,EAAE,CAAC,EAAE,CAAC,CAAC,IAAI,CAAC,SAAS,GAAG,EAAsB,CAAC,GACpD,CACE;oBAEN,WAAK,KAAK,EAAC,kBAAkB;wBAC3B,cAAQ,OAAO,EAAE,IAAI,CAAC,sBAAsB,IACzC,IAAI,CAAC,gBAAgB,CAAC,QAAQ,CAAC,EAAE,CAC3B;wBACT,cAAQ,OAAO,EAAE,IAAI,CAAC,cAAc,IACjC,IAAI,CAAC,gBAAgB,CAAC,QAAQ,CAAC,MAAM,CAC/B,CACL,CACW,CACf,CACD,CACR,CAAC;IACJ,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["/* STENCIL IMPORTS */\nimport {\n Component,\n Host,\n h,\n Prop,\n Element,\n Event,\n EventEmitter\n} from \"@stencil/core\";\n/* OTHER LIBRARIES IMPORTS */\n/* CUSTOM IMPORTS */\nimport { config } from \"../../../common/config\";\nimport { Locale } from \"../../../common/locale\";\n\n@Component({\n tag: \"gx-ide-bpm-timer-duration\",\n styleUrl: \"timer-duration.scss\",\n shadow: true,\n assetsDirs: [\"gx-ide-assets/bpm-timer-duration\"]\n})\nexport class GxIdeBpmTimerDuration {\n // 1.OWN PROPERTIES //\n\n /**\n * The component hard-coded strings translations.\n */\n private _componentLocale: any;\n private renderedFirstTime = false;\n\n // 2. REFERENCE TO ELEMENTS //\n\n @Element() el: HTMLGxIdeBpmTimerDurationElement;\n\n private yearsEl!: HTMLInputElement;\n private monthsEl!: HTMLInputElement;\n private daysEl!: HTMLInputElement;\n private hoursEl!: HTMLInputElement;\n private minutesEl!: HTMLInputElement;\n private secondsEl!: HTMLInputElement;\n\n // 3.STATE() VARIABLES //\n\n // 4.PUBLIC PROPERTY API | WATCH'S //\n\n /**\n * If true it displays the component title on the header\n */\n @Prop() readonly displayTitle = false;\n\n /**\n * Current value for timer.\n */\n @Prop() readonly duration?: TimerDuration;\n\n /**\n * Callback invoked when user confirms application declaration, (OK Button)\n */\n @Prop() readonly confirmCallback: (data: TimerDuration) => Promise<void>;\n\n /**\n * Callback invoked when user cancels application declaration */\n @Prop() readonly cancelCallback: () => Promise<void>;\n\n // 5.EVENTS (EMIT) //\n\n /**\n * @description Gets fired when the component has rendered for the first time.\n */\n @Event() componentDidRenderFirstTime: EventEmitter<string>;\n\n // 6.COMPONENT LIFECYCLE METHODS //\n\n async componentWillLoad() {\n this._componentLocale = await Locale.getComponentStrings(this.el);\n }\n\n componentDidRender() {\n if (!this.renderedFirstTime) {\n this.componentDidRenderFirstTime.emit(\n this._componentLocale.componentName\n );\n this.renderedFirstTime = true;\n }\n }\n\n // 7.LISTENERS //\n\n // 8.PUBLIC METHODS API //\n\n // 9.LOCAL METHODS //\n\n private confirmCallbackHandler = async () => {\n if (this.confirmCallback) {\n const data: TimerDuration = {\n years: parseInt(this.yearsEl.value),\n months: parseInt(this.monthsEl.value),\n days: parseInt(this.daysEl.value),\n hours: parseInt(this.hoursEl.value),\n minutes: parseInt(this.minutesEl.value),\n seconds: parseInt(this.secondsEl.value)\n };\n\n await this.confirmCallback(data);\n }\n };\n\n // 10.RENDER() FUNCTION //\n\n render() {\n return (\n <Host class=\"gx-ide-component\">\n <div class=\"gx-ide-main-wrapper\">\n <gx-ide-container\n containerTitle={\n this.displayTitle ? this._componentLocale.componentName : null\n }\n slimmerFooter={config.gxIdeContainer.slimmerFooter}\n >\n <div class=\"control-wrapper control-wrapper--vertical\">\n <label htmlFor=\"years\">\n {this._componentLocale.controls.years}\n </label>\n <input\n type=\"number\"\n id=\"years\"\n class=\"input-text input-text--full-width\"\n value={this.duration?.years.toString()}\n ref={el => (this.yearsEl = el as HTMLInputElement)}\n />\n </div>\n\n <div class=\"control-wrapper control-wrapper--vertical\">\n <label htmlFor=\"months\">\n {this._componentLocale.controls.months}\n </label>\n <input\n type=\"number\"\n id=\"months\"\n class=\"input-text input-text--full-width\"\n value={this.duration?.months.toString()}\n ref={el => (this.monthsEl = el as HTMLInputElement)}\n />\n </div>\n\n <div class=\"control-wrapper control-wrapper--vertical\">\n <label htmlFor=\"days\">\n {this._componentLocale.controls.days}\n </label>\n <input\n type=\"number\"\n id=\"days\"\n class=\"input-text input-text--full-width\"\n value={this.duration?.months.toString()}\n ref={el => (this.daysEl = el as HTMLInputElement)}\n />\n </div>\n\n <div class=\"control-wrapper control-wrapper--vertical\">\n <label htmlFor=\"hours\">\n {this._componentLocale.controls.hours}\n </label>\n <input\n type=\"number\"\n id=\"hours\"\n class=\"input-text input-text--full-width\"\n value={this.duration?.months.toString()}\n ref={el => (this.hoursEl = el as HTMLInputElement)}\n />\n </div>\n\n <div class=\"control-wrapper control-wrapper--vertical\">\n <label htmlFor=\"minutes\">\n {this._componentLocale.controls.minutes}\n </label>\n <input\n type=\"number\"\n id=\"minutes\"\n class=\"input-text input-text--full-width\"\n value={this.duration?.months.toString()}\n ref={el => (this.minutesEl = el as HTMLInputElement)}\n />\n </div>\n\n <div class=\"control-wrapper control-wrapper--vertical\">\n <label htmlFor=\"seconds\">\n {this._componentLocale.controls.seconds}\n </label>\n <input\n type=\"number\"\n id=\"seconds\"\n class=\"input-text input-text--full-width\"\n value={this.duration?.months.toString()}\n ref={el => (this.secondsEl = el as HTMLInputElement)}\n />\n </div>\n\n <div class=\"controls-wrapper\">\n <button onClick={this.confirmCallbackHandler}>\n {this._componentLocale.controls.ok}\n </button>\n <button onClick={this.cancelCallback}>\n {this._componentLocale.controls.cancel}\n </button>\n </div>\n </gx-ide-container>\n </div>\n </Host>\n );\n }\n}\n\nexport type TimerDuration = {\n years: number;\n months: number;\n days: number;\n hours: number;\n minutes: number;\n seconds: number;\n};\n"]}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gB,CAAC,QAAQ,CAAC,OAAO,CACjC;wBACR,aACE,IAAI,EAAC,QAAQ,EACb,EAAE,EAAC,SAAS,EACZ,KAAK,EAAC,mCAAmC,EACzC,KAAK,EAAE,MAAA,IAAI,CAAC,QAAQ,0CAAE,OAAO,CAAC,QAAQ,EAAE,EACxC,GAAG,EAAE,EAAE,CAAC,EAAE,CAAC,CAAC,IAAI,CAAC,SAAS,GAAG,EAAsB,CAAC,GACpD,CACE;oBAEN,WAAK,KAAK,EAAC,kBAAkB;wBAC3B,cAAQ,OAAO,EAAE,IAAI,CAAC,sBAAsB,IACzC,IAAI,CAAC,gBAAgB,CAAC,QAAQ,CAAC,EAAE,CAC3B;wBACT,cAAQ,OAAO,EAAE,IAAI,CAAC,cAAc,IACjC,IAAI,CAAC,gBAAgB,CAAC,QAAQ,CAAC,MAAM,CAC/B,CACL,CACW,CACf,CACD,CACR,CAAC;IACJ,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["/* STENCIL IMPORTS */\nimport {\n Component,\n Host,\n h,\n Prop,\n Element,\n Event,\n EventEmitter\n} from \"@stencil/core\";\n/* OTHER LIBRARIES IMPORTS */\n/* CUSTOM IMPORTS */\nimport { config } from \"../../../common/config\";\nimport { Locale } from \"../../../common/locale\";\n\n@Component({\n tag: \"gx-ide-bpm-timer-duration\",\n styleUrl: \"timer-duration.scss\",\n shadow: true,\n assetsDirs: [\"gx-ide-assets/bpm-timer-duration\"]\n})\nexport class GxIdeBpmTimerDuration {\n // 1.OWN PROPERTIES //\n\n /**\n * The component hard-coded strings translations.\n */\n private _componentLocale: any;\n private renderedFirstTime = false;\n\n // 2. REFERENCE TO ELEMENTS //\n\n @Element() el: HTMLGxIdeBpmTimerDurationElement;\n\n private yearsEl!: HTMLInputElement;\n private monthsEl!: HTMLInputElement;\n private daysEl!: HTMLInputElement;\n private hoursEl!: HTMLInputElement;\n private minutesEl!: HTMLInputElement;\n private secondsEl!: HTMLInputElement;\n\n // 3.STATE() VARIABLES //\n\n // 4.PUBLIC PROPERTY API | WATCH'S //\n\n /**\n * If true it displays the component title on the header\n */\n @Prop() readonly displayTitle = false;\n\n /**\n * Current value for timer.\n */\n @Prop() readonly duration?: TimerDuration;\n\n /**\n * Callback invoked when user confirms application declaration, (OK Button)\n */\n @Prop() readonly confirmCallback: (data: TimerDuration) => Promise<void>;\n\n /**\n * Callback invoked when user cancels application declaration */\n @Prop() readonly cancelCallback: () => Promise<void>;\n\n // 5.EVENTS (EMIT) //\n\n /**\n * @description Gets fired when the component has rendered for the first time.\n */\n @Event() componentDidRenderFirstTime: EventEmitter<string>;\n\n // 6.COMPONENT LIFECYCLE METHODS //\n\n async componentWillLoad() {\n this._componentLocale = await Locale.getComponentStrings(this.el);\n }\n\n componentDidRender() {\n if (!this.renderedFirstTime) {\n this.componentDidRenderFirstTime.emit(\n this._componentLocale.componentName\n );\n this.renderedFirstTime = true;\n }\n }\n\n // 7.LISTENERS //\n\n // 8.PUBLIC METHODS API //\n\n // 9.LOCAL METHODS //\n\n private confirmCallbackHandler = async () => {\n if (this.confirmCallback) {\n const data: TimerDuration = {\n years: parseInt(this.yearsEl.value),\n months: parseInt(this.monthsEl.value),\n days: parseInt(this.daysEl.value),\n hours: parseInt(this.hoursEl.value),\n minutes: parseInt(this.minutesEl.value),\n seconds: parseInt(this.secondsEl.value)\n };\n\n await this.confirmCallback(data);\n }\n };\n\n // 10.RENDER() FUNCTION //\n\n render() {\n return (\n <Host class=\"gx-ide-component\">\n <div class=\"gx-ide-main-wrapper\">\n <gx-ide-container\n containerTitle={\n this.displayTitle ? this._componentLocale.componentName : null\n }\n slimmerFooter={config.gxIdeContainer.slimmerFooter}\n >\n <div class=\"control-wrapper control-wrapper--vertical\">\n <label htmlFor=\"years\">\n {this._componentLocale.controls.years}\n </label>\n <input\n type=\"number\"\n id=\"years\"\n class=\"input-text input-text--full-width\"\n value={this.duration?.years.toString()}\n ref={el => (this.yearsEl = el as HTMLInputElement)}\n />\n </div>\n\n <div class=\"control-wrapper control-wrapper--vertical\">\n <label htmlFor=\"months\">\n {this._componentLocale.controls.months}\n </label>\n <input\n type=\"number\"\n id=\"months\"\n class=\"input-text input-text--full-width\"\n value={this.duration?.months.toString()}\n ref={el => (this.monthsEl = el as HTMLInputElement)}\n />\n </div>\n\n <div class=\"control-wrapper control-wrapper--vertical\">\n <label htmlFor=\"days\">\n {this._componentLocale.controls.days}\n </label>\n <input\n type=\"number\"\n id=\"days\"\n class=\"input-text input-text--full-width\"\n value={this.duration?.days.toString()}\n ref={el => (this.daysEl = el as HTMLInputElement)}\n />\n </div>\n\n <div class=\"control-wrapper control-wrapper--vertical\">\n <label htmlFor=\"hours\">\n {this._componentLocale.controls.hours}\n </label>\n <input\n type=\"number\"\n id=\"hours\"\n class=\"input-text input-text--full-width\"\n value={this.duration?.hours.toString()}\n ref={el => (this.hoursEl = el as HTMLInputElement)}\n />\n </div>\n\n <div class=\"control-wrapper control-wrapper--vertical\">\n <label htmlFor=\"minutes\">\n {this._componentLocale.controls.minutes}\n </label>\n <input\n type=\"number\"\n id=\"minutes\"\n class=\"input-text input-text--full-width\"\n value={this.duration?.minutes.toString()}\n ref={el => (this.minutesEl = el as HTMLInputElement)}\n />\n </div>\n\n <div class=\"control-wrapper control-wrapper--vertical\">\n <label htmlFor=\"seconds\">\n {this._componentLocale.controls.seconds}\n </label>\n <input\n type=\"number\"\n id=\"seconds\"\n class=\"input-text input-text--full-width\"\n value={this.duration?.seconds.toString()}\n ref={el => (this.secondsEl = el as HTMLInputElement)}\n />\n </div>\n\n <div class=\"controls-wrapper\">\n <button onClick={this.confirmCallbackHandler}>\n {this._componentLocale.controls.ok}\n </button>\n <button onClick={this.cancelCallback}>\n {this._componentLocale.controls.cancel}\n </button>\n </div>\n </gx-ide-container>\n </div>\n </Host>\n );\n }\n}\n\nexport type TimerDuration = {\n years: number;\n months: number;\n days: number;\n hours: number;\n minutes: number;\n seconds: number;\n};\n"]}
|
|
@@ -66,11 +66,9 @@ export class GxIdeConnectGxServer {
|
|
|
66
66
|
}
|
|
67
67
|
// 10.RENDER() FUNCTION //
|
|
68
68
|
render() {
|
|
69
|
-
var _a;
|
|
70
|
-
return (h(Host, { class: "gx-ide-component" }, h("div", { class: "gx-ide-main-wrapper" }, h("gx-ide-container", { containerTitle: this.displayTitle ? this._componentLocale.componentName : null, slimmerFooter: config.gxIdeContainer.slimmerFooter }, h("div", { class: "wrapper" }, h("gxg-combo-box", { label: this._componentLocale.main.serverUrl, disableFilter: !this.enableCustomServer, value: (_a = this.defaultConnectionData) === null || _a === void 0 ? void 0 : _a.serverUrl, ref: el => (this.serverURLEl = el), toolTip: config.tooltip }, this.renderServerUrls()), h("gxg-form-checkbox", { label: this._componentLocale.main.continueWithGxAccount, onChange: this.continueWithGxServerHandler, checked: this.
|
|
71
|
-
? this.defaultConnectionData.
|
|
72
|
-
: this.enableUserLogged, disabled: !this.enableUserLogged, ref: el => (this.continueWithGeneXusAccountEl =
|
|
73
|
-
el) }), this.displayLoginControls ? (h("div", { class: "user-details-container" }, h("gxg-form-text", { label: this._componentLocale.main.userName, labelPosition: "above", disabled: !this.displayLoginControls, value: this.defaultConnectionData.user, ref: el => (this.userNameEl = el), toolTip: config.tooltip }), h("gxg-form-text", { label: this._componentLocale.main.password, labelPosition: "above", disabled: !this.displayLoginControls, value: this.defaultConnectionData.password, ref: el => (this.passwordEl = el), password: true, toolTip: config.tooltip }))) : null), h("gxg-button", { slot: "footer-end", type: "outlined" }, this._componentLocale.main.cancel), h("gxg-button", { slot: "footer-end", onClick: this.connectHandler }, this._componentLocale.main.connect)))));
|
|
69
|
+
var _a, _b, _c;
|
|
70
|
+
return (h(Host, { class: "gx-ide-component" }, h("div", { class: "gx-ide-main-wrapper" }, h("gx-ide-container", { containerTitle: this.displayTitle ? this._componentLocale.componentName : null, slimmerFooter: config.gxIdeContainer.slimmerFooter }, h("div", { class: "wrapper" }, h("gxg-combo-box", { label: this._componentLocale.main.serverUrl, disableFilter: !this.enableCustomServer, value: (_a = this.defaultConnectionData) === null || _a === void 0 ? void 0 : _a.serverUrl, ref: el => (this.serverURLEl = el), toolTip: config.tooltip }, this.renderServerUrls()), h("gxg-form-checkbox", { label: this._componentLocale.main.continueWithGxAccount, onChange: this.continueWithGxServerHandler, checked: this.enableUserLogged, disabled: !this.enableUserLogged, ref: el => (this.continueWithGeneXusAccountEl =
|
|
71
|
+
el) }), this.displayLoginControls ? (h("div", { class: "user-details-container" }, h("gxg-form-text", { label: this._componentLocale.main.userName, labelPosition: "above", disabled: !this.displayLoginControls, value: (_b = this.defaultConnectionData) === null || _b === void 0 ? void 0 : _b.user, ref: el => (this.userNameEl = el), toolTip: config.tooltip }), h("gxg-form-text", { label: this._componentLocale.main.password, labelPosition: "above", disabled: !this.displayLoginControls, value: (_c = this.defaultConnectionData) === null || _c === void 0 ? void 0 : _c.password, ref: el => (this.passwordEl = el), password: true, toolTip: config.tooltip }))) : null), h("gxg-button", { slot: "footer-end", type: "outlined" }, this._componentLocale.main.cancel), h("gxg-button", { slot: "footer-end", onClick: this.connectHandler }, this._componentLocale.main.connect)))));
|
|
74
72
|
}
|
|
75
73
|
static get is() { return "gx-ide-connect-gx-server"; }
|
|
76
74
|
static get encapsulation() { return "shadow"; }
|
|
@@ -142,13 +140,13 @@ export class GxIdeConnectGxServer {
|
|
|
142
140
|
"type": "unknown",
|
|
143
141
|
"mutable": false,
|
|
144
142
|
"complexType": {
|
|
145
|
-
"original": "
|
|
146
|
-
"resolved": "{ serverUrl: string;
|
|
143
|
+
"original": "GXServerConnectionDefault",
|
|
144
|
+
"resolved": "{ serverUrl: string; user: string; password: string; }",
|
|
147
145
|
"references": {
|
|
148
|
-
"
|
|
146
|
+
"GXServerConnectionDefault": {
|
|
149
147
|
"location": "local",
|
|
150
148
|
"path": "/home/runner/work/genexus-ide-ui/genexus-ide-ui/src/components/connect-gx-server/connect-gx-server.tsx",
|
|
151
|
-
"id": "src/components/connect-gx-server/connect-gx-server.tsx::
|
|
149
|
+
"id": "src/components/connect-gx-server/connect-gx-server.tsx::GXServerConnectionDefault"
|
|
152
150
|
}
|
|
153
151
|
}
|
|
154
152
|
},
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"connect-gx-server.js","sourceRoot":"","sources":["../../../src/components/connect-gx-server/connect-gx-server.tsx"],"names":[],"mappings":"AAAA,qBAAqB;AACrB,OAAO,EACL,SAAS,EACT,IAAI,EACJ,CAAC,EACD,IAAI,EACJ,OAAO,EACP,KAAK,EAEL,KAAK,EACN,MAAM,eAAe,CAAC;AACvB,6BAA6B;AAC7B,oBAAoB;AACpB,OAAO,EAAE,MAAM,EAAE,MAAM,qBAAqB,CAAC;AAC7C,OAAO,EAAE,MAAM,EAAE,MAAM,qBAAqB,CAAC;AAC7C,OAAO,EAAE,oBAAoB,EAAE,MAAM,8BAA8B,CAAC;AASpE,MAAM,OAAO,oBAAoB;;QAOvB,sBAAiB,GAAG,KAAK,CAAC;QA8ElC,iBAAiB;QAEjB,0BAA0B;QAE1B,qBAAqB;QAEb,qBAAgB,GAAG,GAAiC,EAAE;;YAC5D,IAAI,MAAA,IAAI,CAAC,UAAU,0CAAE,MAAM,EAAE;gBAC3B,OAAO,IAAI,CAAC,UAAU,CAAC,GAAG,CAAC,SAAS,CAAC,EAAE;oBACrC,OAAO,8BAAqB,SAAS,CAAsB,CAAC;gBAC9D,CAAC,CAAC,CAAC;aACJ;YACD,OAAO,EAAE,CAAC;QACZ,CAAC,CAAC;QAEM,gCAA2B,GAAG,CACpC,KAAsE,EACtE,EAAE;YACF,IAAI,CAAC,oBAAoB,GAAG,CAAC,KAAK,CAAC,MAAM,CAAC,KAAK,CAAC;QAClD,CAAC,CAAC;QAEM,iCAA4B,GAAG,GAAG,EAAE;YAC1C,IAAI,IAAI,CAAC,gBAAgB,EAAE;gBACzB,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AI,CAAC,UAAU,GAAG,EAA4B,CAAC,EAC3D,OAAO,EAAE,MAAM,CAAC,OAAO,GACR;4BAEjB,qBACE,KAAK,EAAE,IAAI,CAAC,gBAAgB,CAAC,IAAI,CAAC,QAAQ,EAC1C,aAAa,EAAC,OAAO,EACrB,QAAQ,EAAE,CAAC,IAAI,CAAC,oBAAoB,EACpC,KAAK,EAAE,IAAI,CAAC,qBAAqB,CAAC,QAAQ,EAC1C,GAAG,EAAE,EAAE,CAAC,EAAE,CAAC,CAAC,IAAI,CAAC,UAAU,GAAG,EAA4B,CAAC,EAC3D,QAAQ,QACR,OAAO,EAAE,MAAM,CAAC,OAAO,GACR,CACb,CACP,CAAC,CAAC,CAAC,IAAI,CACJ;oBAGN,kBAAY,IAAI,EAAC,YAAY,EAAC,IAAI,EAAC,UAAU,IAC1C,IAAI,CAAC,gBAAgB,CAAC,IAAI,CAAC,MAAM,CACvB;oBACb,kBAAY,IAAI,EAAC,YAAY,EAAC,OAAO,EAAE,IAAI,CAAC,cAAc,IACvD,IAAI,CAAC,gBAAgB,CAAC,IAAI,CAAC,OAAO,CACxB,CACI,CACf,CACD,CACR,CAAC;IACJ,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["/* STENCIL IMPORTS */\nimport {\n Component,\n Host,\n h,\n Prop,\n Element,\n Event,\n EventEmitter,\n State\n} from \"@stencil/core\";\n/* OTHER LIBRARIES IMPORTS */\n/* CUSTOM IMPORTS */\nimport { config } from \"../../common/config\";\nimport { Locale } from \"../../common/locale\";\nimport { formSubmitValidation } from \"../../common/form-validation\";\nimport { ConnectionResultData } from \"../../common/types\";\n\n@Component({\n tag: \"gx-ide-connect-gx-server\",\n styleUrl: \"connect-gx-server.scss\",\n shadow: true,\n assetsDirs: [\"gx-ide-assets/connect-gx-server\"]\n})\nexport class GxIdeConnectGxServer {\n // 1.OWN PROPERTIES //\n\n /**\n * The component hard-coded strings translations.\n */\n private _componentLocale: any;\n private renderedFirstTime = false;\n\n // 2. REFERENCE TO ELEMENTS //\n\n @Element() el: HTMLGxIdeConnectGxServerElement;\n\n private serverURLEl!: HTMLGxgComboBoxElement;\n private userNameEl!: HTMLGxgFormTextElement;\n private passwordEl!: HTMLGxgFormTextElement;\n private continueWithGeneXusAccountEl!: HTMLGxgFormCheckboxElement;\n\n // 3.STATE() VARIABLES //\n\n //\n @State() displayLoginControls: boolean = false;\n\n // 4.PUBLIC PROPERTY API | WATCH'S //\n\n /**\n * If true it displays the component title on the header\n */\n @Prop() readonly displayTitle = false;\n\n /**\n * Array of cataloged server URLs\n */\n @Prop() readonly serverUrls: string[];\n\n /**\n * 'true' if the user should be allowed to manually enter a server URL in serverUrls.\n */\n @Prop() readonly enableCustomServer: boolean = false;\n\n /**\n * Initial user values for the case in which the user returns to the login modal after a successful authentication.\n */\n @Prop() readonly defaultConnectionData?: GXServerConnectionData;\n\n /**\n * If 'true', shows the enabled and checked 'Continue with GX Account' checkbox. If 'false', shows the checkbox unchecked and disabled, and displays the options to enter username and password directly. Even if 'true', allow the user to deselect the checkbox and enter username and password.\n */\n @Prop() readonly enableUserLogged: boolean = false;\n\n /**\n * If 'true', shows the enabled and checked 'Continue with GX Account' checkbox. If 'false', shows the checkbox unchecked and disabled, and displays the options to enter username and password directly. Even if 'true', allow the user to deselect the checkbox and enter username and password.\n */\n @Prop() readonly connectCallback: (\n data: GXServerConnectionData\n ) => Promise<ConnectionResultData>;\n\n /**\n * Callback that allows canceling the server connection process.\n */\n @Prop() readonly cancelCallback: () => Promise<void>;\n\n // 5.EVENTS (EMIT) //\n\n /**\n * @description Gets fired when the component has rendered for the first time.\n */\n @Event() componentDidRenderFirstTime: EventEmitter<string>;\n\n // 6.COMPONENT LIFECYCLE METHODS //\n\n async componentWillLoad() {\n this._componentLocale = await Locale.getComponentStrings(this.el);\n this.evaluateDisplayLoginControls();\n }\n\n componentDidRender() {\n if (!this.renderedFirstTime) {\n this.componentDidRenderFirstTime.emit(\n this._componentLocale.componentName\n );\n this.renderedFirstTime = true;\n }\n }\n\n // 7.LISTENERS //\n\n // 8.PUBLIC METHODS API //\n\n // 9.LOCAL METHODS //\n\n private renderServerUrls = (): HTMLGxgComboBoxItemElement[] => {\n if (this.serverUrls?.length) {\n return this.serverUrls.map(serverUrl => {\n return <gxg-combo-box-item>{serverUrl}</gxg-combo-box-item>;\n });\n }\n return [];\n };\n\n private continueWithGxServerHandler = (\n event: CustomEvent<{ id: string; value: boolean; disabled?: boolean }>\n ) => {\n this.displayLoginControls = !event.detail.value;\n };\n\n private evaluateDisplayLoginControls = () => {\n if (this.enableUserLogged) {\n this.displayLoginControls = false;\n } else {\n this.displayLoginControls = true;\n }\n };\n\n private connectHandler = () => {\n if (this.connectCallback) {\n this.connectCallback({\n serverUrl: this.serverURLEl.value,\n continueWithGeneXusAccount: this.continueWithGeneXusAccountEl.checked,\n user: this.userNameEl.value,\n password: this.passwordEl.value\n }).then((formSubmitResult: ConnectionResultData) => {\n console.log(formSubmitResult);\n formSubmitValidation(formSubmitResult, this);\n });\n }\n };\n\n // 10.RENDER() FUNCTION //\n\n render() {\n return (\n <Host class=\"gx-ide-component\">\n <div class=\"gx-ide-main-wrapper\">\n <gx-ide-container\n containerTitle={\n this.displayTitle ? this._componentLocale.componentName : null\n }\n slimmerFooter={config.gxIdeContainer.slimmerFooter}\n >\n <div class=\"wrapper\">\n {/* server url */}\n <gxg-combo-box\n label={this._componentLocale.main.serverUrl}\n disableFilter={!this.enableCustomServer}\n value={this.defaultConnectionData?.serverUrl}\n ref={el => (this.serverURLEl = el as HTMLGxgComboBoxElement)}\n toolTip={config.tooltip}\n >\n {this.renderServerUrls()}\n </gxg-combo-box>\n\n {/* continue with GeneXus account */}\n <gxg-form-checkbox\n label={this._componentLocale.main.continueWithGxAccount}\n onChange={this.continueWithGxServerHandler}\n checked={\n this.defaultConnectionData\n ? this.defaultConnectionData.continueWithGeneXusAccount\n : this.enableUserLogged\n }\n disabled={!this.enableUserLogged}\n ref={el =>\n (this.continueWithGeneXusAccountEl =\n el as HTMLGxgFormCheckboxElement)\n }\n ></gxg-form-checkbox>\n\n {this.displayLoginControls ? (\n <div class=\"user-details-container\">\n {/* username */}\n <gxg-form-text\n label={this._componentLocale.main.userName}\n labelPosition=\"above\"\n disabled={!this.displayLoginControls}\n value={this.defaultConnectionData.user}\n ref={el => (this.userNameEl = el as HTMLGxgFormTextElement)}\n toolTip={config.tooltip}\n ></gxg-form-text>\n {/* password */}\n <gxg-form-text\n label={this._componentLocale.main.password}\n labelPosition=\"above\"\n disabled={!this.displayLoginControls}\n value={this.defaultConnectionData.password}\n ref={el => (this.passwordEl = el as HTMLGxgFormTextElement)}\n password\n toolTip={config.tooltip}\n ></gxg-form-text>\n </div>\n ) : null}\n </div>\n\n {/* cancel and connect buttons */}\n <gxg-button slot=\"footer-end\" type=\"outlined\">\n {this._componentLocale.main.cancel}\n </gxg-button>\n <gxg-button slot=\"footer-end\" onClick={this.connectHandler}>\n {this._componentLocale.main.connect}\n </gxg-button>\n </gx-ide-container>\n </div>\n </Host>\n );\n }\n}\n\nexport type GXServerConnectionData = {\n serverUrl: string;\n continueWithGeneXusAccount: boolean;\n user: string;\n password: string;\n};\n"]}
|
|
1
|
+
{"version":3,"file":"connect-gx-server.js","sourceRoot":"","sources":["../../../src/components/connect-gx-server/connect-gx-server.tsx"],"names":[],"mappings":"AAAA,qBAAqB;AACrB,OAAO,EACL,SAAS,EACT,IAAI,EACJ,CAAC,EACD,IAAI,EACJ,OAAO,EACP,KAAK,EAEL,KAAK,EACN,MAAM,eAAe,CAAC;AACvB,6BAA6B;AAC7B,oBAAoB;AACpB,OAAO,EAAE,MAAM,EAAE,MAAM,qBAAqB,CAAC;AAC7C,OAAO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IAAI,CAAC,cAAc,IACvD,IAAI,CAAC,gBAAgB,CAAC,IAAI,CAAC,OAAO,CACxB,CACI,CACf,CACD,CACR,CAAC;IACJ,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["/* STENCIL IMPORTS */\nimport {\n Component,\n Host,\n h,\n Prop,\n Element,\n Event,\n EventEmitter,\n State\n} from \"@stencil/core\";\n/* OTHER LIBRARIES IMPORTS */\n/* CUSTOM IMPORTS */\nimport { config } from \"../../common/config\";\nimport { Locale } from \"../../common/locale\";\nimport { formSubmitValidation } from \"../../common/form-validation\";\nimport { ConnectionResultData } from \"../../common/types\";\n\n@Component({\n tag: \"gx-ide-connect-gx-server\",\n styleUrl: \"connect-gx-server.scss\",\n shadow: true,\n assetsDirs: [\"gx-ide-assets/connect-gx-server\"]\n})\nexport class GxIdeConnectGxServer {\n // 1.OWN PROPERTIES //\n\n /**\n * The component hard-coded strings translations.\n */\n private _componentLocale: any;\n private renderedFirstTime = false;\n\n // 2. REFERENCE TO ELEMENTS //\n\n @Element() el: HTMLGxIdeConnectGxServerElement;\n\n private serverURLEl!: HTMLGxgComboBoxElement;\n private userNameEl!: HTMLGxgFormTextElement;\n private passwordEl!: HTMLGxgFormTextElement;\n private continueWithGeneXusAccountEl!: HTMLGxgFormCheckboxElement;\n\n // 3.STATE() VARIABLES //\n\n //\n @State() displayLoginControls: boolean = false;\n\n // 4.PUBLIC PROPERTY API | WATCH'S //\n\n /**\n * If true it displays the component title on the header\n */\n @Prop() readonly displayTitle = false;\n\n /**\n * Array of cataloged server URLs\n */\n @Prop() readonly serverUrls: string[];\n\n /**\n * 'true' if the user should be allowed to manually enter a server URL in serverUrls.\n */\n @Prop() readonly enableCustomServer: boolean = false;\n\n /**\n * Initial user values for the case in which the user returns to the login modal after a successful authentication.\n */\n @Prop() readonly defaultConnectionData?: GXServerConnectionDefault;\n\n /**\n * If 'true', shows the enabled and checked 'Continue with GX Account' checkbox. If 'false', shows the checkbox unchecked and disabled, and displays the options to enter username and password directly. Even if 'true', allow the user to deselect the checkbox and enter username and password.\n */\n @Prop() readonly enableUserLogged: boolean = false;\n\n /**\n * If 'true', shows the enabled and checked 'Continue with GX Account' checkbox. If 'false', shows the checkbox unchecked and disabled, and displays the options to enter username and password directly. Even if 'true', allow the user to deselect the checkbox and enter username and password.\n */\n @Prop() readonly connectCallback: (\n data: GXServerConnectionData\n ) => Promise<ConnectionResultData>;\n\n /**\n * Callback that allows canceling the server connection process.\n */\n @Prop() readonly cancelCallback: () => Promise<void>;\n\n // 5.EVENTS (EMIT) //\n\n /**\n * @description Gets fired when the component has rendered for the first time.\n */\n @Event() componentDidRenderFirstTime: EventEmitter<string>;\n\n // 6.COMPONENT LIFECYCLE METHODS //\n\n async componentWillLoad() {\n this._componentLocale = await Locale.getComponentStrings(this.el);\n this.evaluateDisplayLoginControls();\n }\n\n componentDidRender() {\n if (!this.renderedFirstTime) {\n this.componentDidRenderFirstTime.emit(\n this._componentLocale.componentName\n );\n this.renderedFirstTime = true;\n }\n }\n\n // 7.LISTENERS //\n\n // 8.PUBLIC METHODS API //\n\n // 9.LOCAL METHODS //\n\n private renderServerUrls = (): HTMLGxgComboBoxItemElement[] => {\n if (this.serverUrls?.length) {\n return this.serverUrls.map(serverUrl => {\n return <gxg-combo-box-item>{serverUrl}</gxg-combo-box-item>;\n });\n }\n return [];\n };\n\n private continueWithGxServerHandler = (\n event: CustomEvent<{ id: string; value: boolean; disabled?: boolean }>\n ) => {\n this.displayLoginControls = !event.detail.value;\n };\n\n private evaluateDisplayLoginControls = () => {\n if (this.enableUserLogged) {\n this.displayLoginControls = false;\n } else {\n this.displayLoginControls = true;\n }\n };\n\n private connectHandler = () => {\n if (this.connectCallback) {\n this.connectCallback({\n serverUrl: this.serverURLEl.value,\n continueWithGeneXusAccount: this.continueWithGeneXusAccountEl.checked,\n user: this.userNameEl.value,\n password: this.passwordEl.value\n }).then((formSubmitResult: ConnectionResultData) => {\n console.log(formSubmitResult);\n formSubmitValidation(formSubmitResult, this);\n });\n }\n };\n\n // 10.RENDER() FUNCTION //\n\n render() {\n return (\n <Host class=\"gx-ide-component\">\n <div class=\"gx-ide-main-wrapper\">\n <gx-ide-container\n containerTitle={\n this.displayTitle ? this._componentLocale.componentName : null\n }\n slimmerFooter={config.gxIdeContainer.slimmerFooter}\n >\n <div class=\"wrapper\">\n {/* server url */}\n <gxg-combo-box\n label={this._componentLocale.main.serverUrl}\n disableFilter={!this.enableCustomServer}\n value={this.defaultConnectionData?.serverUrl}\n ref={el => (this.serverURLEl = el as HTMLGxgComboBoxElement)}\n toolTip={config.tooltip}\n >\n {this.renderServerUrls()}\n </gxg-combo-box>\n\n {/* continue with GeneXus account */}\n <gxg-form-checkbox\n label={this._componentLocale.main.continueWithGxAccount}\n onChange={this.continueWithGxServerHandler}\n checked={this.enableUserLogged}\n disabled={!this.enableUserLogged}\n ref={el =>\n (this.continueWithGeneXusAccountEl =\n el as HTMLGxgFormCheckboxElement)\n }\n ></gxg-form-checkbox>\n\n {this.displayLoginControls ? (\n <div class=\"user-details-container\">\n {/* username */}\n <gxg-form-text\n label={this._componentLocale.main.userName}\n labelPosition=\"above\"\n disabled={!this.displayLoginControls}\n value={this.defaultConnectionData?.user}\n ref={el => (this.userNameEl = el as HTMLGxgFormTextElement)}\n toolTip={config.tooltip}\n ></gxg-form-text>\n {/* password */}\n <gxg-form-text\n label={this._componentLocale.main.password}\n labelPosition=\"above\"\n disabled={!this.displayLoginControls}\n value={this.defaultConnectionData?.password}\n ref={el => (this.passwordEl = el as HTMLGxgFormTextElement)}\n password\n toolTip={config.tooltip}\n ></gxg-form-text>\n </div>\n ) : null}\n </div>\n\n {/* cancel and connect buttons */}\n <gxg-button slot=\"footer-end\" type=\"outlined\">\n {this._componentLocale.main.cancel}\n </gxg-button>\n <gxg-button slot=\"footer-end\" onClick={this.connectHandler}>\n {this._componentLocale.main.connect}\n </gxg-button>\n </gx-ide-container>\n </div>\n </Host>\n );\n }\n}\n\nexport type GXServerConnectionDefault = {\n serverUrl: string;\n user: string;\n password: string;\n};\n\nexport type GXServerConnectionData = GXServerConnectionDefault & {\n continueWithGeneXusAccount: boolean;\n};\n"]}
|
|
@@ -48,7 +48,7 @@ const GxIdeBpmTimerDuration$1 = /*@__PURE__*/ proxyCustomElement(class GxIdeBpmT
|
|
|
48
48
|
// 10.RENDER() FUNCTION //
|
|
49
49
|
render() {
|
|
50
50
|
var _a, _b, _c, _d, _e, _f;
|
|
51
|
-
return (h(Host, { class: "gx-ide-component" }, h("div", { class: "gx-ide-main-wrapper" }, h("gx-ide-container", { containerTitle: this.displayTitle ? this._componentLocale.componentName : null, slimmerFooter: config.gxIdeContainer.slimmerFooter }, h("div", { class: "control-wrapper control-wrapper--vertical" }, h("label", { htmlFor: "years" }, this._componentLocale.controls.years), h("input", { type: "number", id: "years", class: "input-text input-text--full-width", value: (_a = this.duration) === null || _a === void 0 ? void 0 : _a.years.toString(), ref: el => (this.yearsEl = el) })), h("div", { class: "control-wrapper control-wrapper--vertical" }, h("label", { htmlFor: "months" }, this._componentLocale.controls.months), h("input", { type: "number", id: "months", class: "input-text input-text--full-width", value: (_b = this.duration) === null || _b === void 0 ? void 0 : _b.months.toString(), ref: el => (this.monthsEl = el) })), h("div", { class: "control-wrapper control-wrapper--vertical" }, h("label", { htmlFor: "days" }, this._componentLocale.controls.days), h("input", { type: "number", id: "days", class: "input-text input-text--full-width", value: (_c = this.duration) === null || _c === void 0 ? void 0 : _c.
|
|
51
|
+
return (h(Host, { class: "gx-ide-component" }, h("div", { class: "gx-ide-main-wrapper" }, h("gx-ide-container", { containerTitle: this.displayTitle ? this._componentLocale.componentName : null, slimmerFooter: config.gxIdeContainer.slimmerFooter }, h("div", { class: "control-wrapper control-wrapper--vertical" }, h("label", { htmlFor: "years" }, this._componentLocale.controls.years), h("input", { type: "number", id: "years", class: "input-text input-text--full-width", value: (_a = this.duration) === null || _a === void 0 ? void 0 : _a.years.toString(), ref: el => (this.yearsEl = el) })), h("div", { class: "control-wrapper control-wrapper--vertical" }, h("label", { htmlFor: "months" }, this._componentLocale.controls.months), h("input", { type: "number", id: "months", class: "input-text input-text--full-width", value: (_b = this.duration) === null || _b === void 0 ? void 0 : _b.months.toString(), ref: el => (this.monthsEl = el) })), h("div", { class: "control-wrapper control-wrapper--vertical" }, h("label", { htmlFor: "days" }, this._componentLocale.controls.days), h("input", { type: "number", id: "days", class: "input-text input-text--full-width", value: (_c = this.duration) === null || _c === void 0 ? void 0 : _c.days.toString(), ref: el => (this.daysEl = el) })), h("div", { class: "control-wrapper control-wrapper--vertical" }, h("label", { htmlFor: "hours" }, this._componentLocale.controls.hours), h("input", { type: "number", id: "hours", class: "input-text input-text--full-width", value: (_d = this.duration) === null || _d === void 0 ? void 0 : _d.hours.toString(), ref: el => (this.hoursEl = el) })), h("div", { class: "control-wrapper control-wrapper--vertical" }, h("label", { htmlFor: "minutes" }, this._componentLocale.controls.minutes), h("input", { type: "number", id: "minutes", class: "input-text input-text--full-width", value: (_e = this.duration) === null || _e === void 0 ? void 0 : _e.minutes.toString(), ref: el => (this.minutesEl = el) })), h("div", { class: "control-wrapper control-wrapper--vertical" }, h("label", { htmlFor: "seconds" }, this._componentLocale.controls.seconds), h("input", { type: "number", id: "seconds", class: "input-text input-text--full-width", value: (_f = this.duration) === null || _f === void 0 ? void 0 : _f.seconds.toString(), ref: el => (this.secondsEl = el) })), h("div", { class: "controls-wrapper" }, h("button", { onClick: this.confirmCallbackHandler }, this._componentLocale.controls.ok), h("button", { onClick: this.cancelCallback }, this._componentLocale.controls.cancel))))));
|
|
52
52
|
}
|
|
53
53
|
static get assetsDirs() { return ["gx-ide-assets/bpm-timer-duration"]; }
|
|
54
54
|
get el() {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CAAC,MAAM,CAC/B,CACL,CACW,CACf,CACD,EACP;KACH;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","names":["GxIdeBpmTimerDuration"],"sources":["src/components/bpm/timer-duration/timer-duration.scss?tag=gx-ide-bpm-timer-duration&encapsulation=shadow","src/components/bpm/timer-duration/timer-duration.tsx"],"sourcesContent":["@import \"../../../global/gx-ide-common.scss\";\n@import \"../../../global/gx-ide-mixins.scss\";\n@import \"../../../global/temporary-tokens-chameleon.scss\";\n\n:host {\n display: block;\n}\n","/* STENCIL IMPORTS */\nimport {\n Component,\n Host,\n h,\n Prop,\n Element,\n Event,\n EventEmitter\n} from \"@stencil/core\";\n/* OTHER LIBRARIES IMPORTS */\n/* CUSTOM IMPORTS */\nimport { config } from \"../../../common/config\";\nimport { Locale } from \"../../../common/locale\";\n\n@Component({\n tag: \"gx-ide-bpm-timer-duration\",\n styleUrl: \"timer-duration.scss\",\n shadow: true,\n assetsDirs: [\"gx-ide-assets/bpm-timer-duration\"]\n})\nexport class GxIdeBpmTimerDuration {\n // 1.OWN PROPERTIES //\n\n /**\n * The component hard-coded strings translations.\n */\n private _componentLocale: any;\n private renderedFirstTime = false;\n\n // 2. REFERENCE TO ELEMENTS //\n\n @Element() el: HTMLGxIdeBpmTimerDurationElement;\n\n private yearsEl!: HTMLInputElement;\n private monthsEl!: HTMLInputElement;\n private daysEl!: HTMLInputElement;\n private hoursEl!: HTMLInputElement;\n private minutesEl!: HTMLInputElement;\n private secondsEl!: HTMLInputElement;\n\n // 3.STATE() VARIABLES //\n\n // 4.PUBLIC PROPERTY API | WATCH'S //\n\n /**\n * If true it displays the component title on the header\n */\n @Prop() readonly displayTitle = false;\n\n /**\n * Current value for timer.\n */\n @Prop() readonly duration?: TimerDuration;\n\n /**\n * Callback invoked when user confirms application declaration, (OK Button)\n */\n @Prop() readonly confirmCallback: (data: TimerDuration) => Promise<void>;\n\n /**\n * Callback invoked when user cancels application declaration */\n @Prop() readonly cancelCallback: () => Promise<void>;\n\n // 5.EVENTS (EMIT) //\n\n /**\n * @description Gets fired when the component has rendered for the first time.\n */\n @Event() componentDidRenderFirstTime: EventEmitter<string>;\n\n // 6.COMPONENT LIFECYCLE METHODS //\n\n async componentWillLoad() {\n this._componentLocale = await Locale.getComponentStrings(this.el);\n }\n\n componentDidRender() {\n if (!this.renderedFirstTime) {\n this.componentDidRenderFirstTime.emit(\n this._componentLocale.componentName\n );\n this.renderedFirstTime = true;\n }\n }\n\n // 7.LISTENERS //\n\n // 8.PUBLIC METHODS API //\n\n // 9.LOCAL METHODS //\n\n private confirmCallbackHandler = async () => {\n if (this.confirmCallback) {\n const data: TimerDuration = {\n years: parseInt(this.yearsEl.value),\n months: parseInt(this.monthsEl.value),\n days: parseInt(this.daysEl.value),\n hours: parseInt(this.hoursEl.value),\n minutes: parseInt(this.minutesEl.value),\n seconds: parseInt(this.secondsEl.value)\n };\n\n await this.confirmCallback(data);\n }\n };\n\n // 10.RENDER() FUNCTION //\n\n render() {\n return (\n <Host class=\"gx-ide-component\">\n <div class=\"gx-ide-main-wrapper\">\n <gx-ide-container\n containerTitle={\n this.displayTitle ? this._componentLocale.componentName : null\n }\n slimmerFooter={config.gxIdeContainer.slimmerFooter}\n >\n <div class=\"control-wrapper control-wrapper--vertical\">\n <label htmlFor=\"years\">\n {this._componentLocale.controls.years}\n </label>\n <input\n type=\"number\"\n id=\"years\"\n class=\"input-text input-text--full-width\"\n value={this.duration?.years.toString()}\n ref={el => (this.yearsEl = el as HTMLInputElement)}\n />\n </div>\n\n <div class=\"control-wrapper control-wrapper--vertical\">\n <label htmlFor=\"months\">\n {this._componentLocale.controls.months}\n </label>\n <input\n type=\"number\"\n id=\"months\"\n class=\"input-text input-text--full-width\"\n value={this.duration?.months.toString()}\n ref={el => (this.monthsEl = el as HTMLInputElement)}\n />\n </div>\n\n <div class=\"control-wrapper control-wrapper--vertical\">\n <label htmlFor=\"days\">\n {this._componentLocale.controls.days}\n </label>\n <input\n type=\"number\"\n id=\"days\"\n class=\"input-text input-text--full-width\"\n value={this.duration?.months.toString()}\n ref={el => (this.daysEl = el as HTMLInputElement)}\n />\n </div>\n\n <div class=\"control-wrapper control-wrapper--vertical\">\n <label htmlFor=\"hours\">\n {this._componentLocale.controls.hours}\n </label>\n <input\n type=\"number\"\n id=\"hours\"\n class=\"input-text input-text--full-width\"\n value={this.duration?.months.toString()}\n ref={el => (this.hoursEl = el as HTMLInputElement)}\n />\n </div>\n\n <div class=\"control-wrapper control-wrapper--vertical\">\n <label htmlFor=\"minutes\">\n {this._componentLocale.controls.minutes}\n </label>\n <input\n type=\"number\"\n id=\"minutes\"\n class=\"input-text input-text--full-width\"\n value={this.duration?.months.toString()}\n ref={el => (this.minutesEl = el as HTMLInputElement)}\n />\n </div>\n\n <div class=\"control-wrapper control-wrapper--vertical\">\n <label htmlFor=\"seconds\">\n {this._componentLocale.controls.seconds}\n </label>\n <input\n type=\"number\"\n id=\"seconds\"\n class=\"input-text input-text--full-width\"\n value={this.duration?.months.toString()}\n ref={el => (this.secondsEl = el as HTMLInputElement)}\n />\n </div>\n\n <div class=\"controls-wrapper\">\n <button onClick={this.confirmCallbackHandler}>\n {this._componentLocale.controls.ok}\n </button>\n <button onClick={this.cancelCallback}>\n {this._componentLocale.controls.cancel}\n </button>\n </div>\n </gx-ide-container>\n </div>\n </Host>\n );\n }\n}\n\nexport type TimerDuration = {\n years: number;\n months: number;\n days: number;\n hours: number;\n minutes: number;\n seconds: number;\n};\n"],"version":3}
|
|
1
|
+
{"file":"gx-ide-bpm-timer-duration.js","mappings":";;;;;;;AAAA,MAAM,gBAAgB,GAAG,q7WAAq7W;;MCqBj8WA,uBAAqB;;;;;;QAOxB,sBAAiB,GAAG,KAAK,CAAC;;;;QAgE1B,2BAAsB,GAAG;YAC/B,IAAI,IAAI,CAAC,eAAe,EAAE;gBACxB,MAAM,IAAI,GAAkB;oBAC1B,KAAK,EAAE,QAAQ,CAAC,IAAI,CAAC,OAAO,CAAC,K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AC,2CAA2C,IACpD,aAAO,OAAO,EAAC,SAAS,IACrB,IAAI,CAAC,gBAAgB,CAAC,QAAQ,CAAC,OAAO,CACjC,EACR,aACE,IAAI,EAAC,QAAQ,EACb,EAAE,EAAC,SAAS,EACZ,KAAK,EAAC,mCAAmC,EACzC,KAAK,EAAE,MAAA,IAAI,CAAC,QAAQ,0CAAE,OAAO,CAAC,QAAQ,EAAE,EACxC,GAAG,EAAE,EAAE,KAAK,IAAI,CAAC,SAAS,GAAG,EAAsB,CAAC,GACpD,CACE,EAEN,WAAK,KAAK,EAAC,2CAA2C,IACpD,aAAO,OAAO,EAAC,SAAS,IACrB,IAAI,CAAC,gBAAgB,CAAC,QAAQ,CAAC,OAAO,CACjC,EACR,aACE,IAAI,EAAC,QAAQ,EACb,EAAE,EAAC,SAAS,EACZ,KAAK,EAAC,mCAAmC,EACzC,KAAK,EAAE,MAAA,IAAI,CAAC,QAAQ,0CAAE,OAAO,CAAC,QAAQ,EAAE,EACxC,GAAG,EAAE,EAAE,KAAK,IAAI,CAAC,SAAS,GAAG,EAAsB,CAAC,GACpD,CACE,EAEN,WAAK,KAAK,EAAC,kBAAkB,IAC3B,cAAQ,OAAO,EAAE,IAAI,CAAC,sBAAsB,IACzC,IAAI,CAAC,gBAAgB,CAAC,QAAQ,CAAC,EAAE,CAC3B,EACT,cAAQ,OAAO,EAAE,IAAI,CAAC,cAAc,IACjC,IAAI,CAAC,gBAAgB,CAAC,QAAQ,CAAC,MAAM,CAC/B,CACL,CACW,CACf,CACD,EACP;KACH;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","names":["GxIdeBpmTimerDuration"],"sources":["src/components/bpm/timer-duration/timer-duration.scss?tag=gx-ide-bpm-timer-duration&encapsulation=shadow","src/components/bpm/timer-duration/timer-duration.tsx"],"sourcesContent":["@import \"../../../global/gx-ide-common.scss\";\n@import \"../../../global/gx-ide-mixins.scss\";\n@import \"../../../global/temporary-tokens-chameleon.scss\";\n\n:host {\n display: block;\n}\n","/* STENCIL IMPORTS */\nimport {\n Component,\n Host,\n h,\n Prop,\n Element,\n Event,\n EventEmitter\n} from \"@stencil/core\";\n/* OTHER LIBRARIES IMPORTS */\n/* CUSTOM IMPORTS */\nimport { config } from \"../../../common/config\";\nimport { Locale } from \"../../../common/locale\";\n\n@Component({\n tag: \"gx-ide-bpm-timer-duration\",\n styleUrl: \"timer-duration.scss\",\n shadow: true,\n assetsDirs: [\"gx-ide-assets/bpm-timer-duration\"]\n})\nexport class GxIdeBpmTimerDuration {\n // 1.OWN PROPERTIES //\n\n /**\n * The component hard-coded strings translations.\n */\n private _componentLocale: any;\n private renderedFirstTime = false;\n\n // 2. REFERENCE TO ELEMENTS //\n\n @Element() el: HTMLGxIdeBpmTimerDurationElement;\n\n private yearsEl!: HTMLInputElement;\n private monthsEl!: HTMLInputElement;\n private daysEl!: HTMLInputElement;\n private hoursEl!: HTMLInputElement;\n private minutesEl!: HTMLInputElement;\n private secondsEl!: HTMLInputElement;\n\n // 3.STATE() VARIABLES //\n\n // 4.PUBLIC PROPERTY API | WATCH'S //\n\n /**\n * If true it displays the component title on the header\n */\n @Prop() readonly displayTitle = false;\n\n /**\n * Current value for timer.\n */\n @Prop() readonly duration?: TimerDuration;\n\n /**\n * Callback invoked when user confirms application declaration, (OK Button)\n */\n @Prop() readonly confirmCallback: (data: TimerDuration) => Promise<void>;\n\n /**\n * Callback invoked when user cancels application declaration */\n @Prop() readonly cancelCallback: () => Promise<void>;\n\n // 5.EVENTS (EMIT) //\n\n /**\n * @description Gets fired when the component has rendered for the first time.\n */\n @Event() componentDidRenderFirstTime: EventEmitter<string>;\n\n // 6.COMPONENT LIFECYCLE METHODS //\n\n async componentWillLoad() {\n this._componentLocale = await Locale.getComponentStrings(this.el);\n }\n\n componentDidRender() {\n if (!this.renderedFirstTime) {\n this.componentDidRenderFirstTime.emit(\n this._componentLocale.componentName\n );\n this.renderedFirstTime = true;\n }\n }\n\n // 7.LISTENERS //\n\n // 8.PUBLIC METHODS API //\n\n // 9.LOCAL METHODS //\n\n private confirmCallbackHandler = async () => {\n if (this.confirmCallback) {\n const data: TimerDuration = {\n years: parseInt(this.yearsEl.value),\n months: parseInt(this.monthsEl.value),\n days: parseInt(this.daysEl.value),\n hours: parseInt(this.hoursEl.value),\n minutes: parseInt(this.minutesEl.value),\n seconds: parseInt(this.secondsEl.value)\n };\n\n await this.confirmCallback(data);\n }\n };\n\n // 10.RENDER() FUNCTION //\n\n render() {\n return (\n <Host class=\"gx-ide-component\">\n <div class=\"gx-ide-main-wrapper\">\n <gx-ide-container\n containerTitle={\n this.displayTitle ? this._componentLocale.componentName : null\n }\n slimmerFooter={config.gxIdeContainer.slimmerFooter}\n >\n <div class=\"control-wrapper control-wrapper--vertical\">\n <label htmlFor=\"years\">\n {this._componentLocale.controls.years}\n </label>\n <input\n type=\"number\"\n id=\"years\"\n class=\"input-text input-text--full-width\"\n value={this.duration?.years.toString()}\n ref={el => (this.yearsEl = el as HTMLInputElement)}\n />\n </div>\n\n <div class=\"control-wrapper control-wrapper--vertical\">\n <label htmlFor=\"months\">\n {this._componentLocale.controls.months}\n </label>\n <input\n type=\"number\"\n id=\"months\"\n class=\"input-text input-text--full-width\"\n value={this.duration?.months.toString()}\n ref={el => (this.monthsEl = el as HTMLInputElement)}\n />\n </div>\n\n <div class=\"control-wrapper control-wrapper--vertical\">\n <label htmlFor=\"days\">\n {this._componentLocale.controls.days}\n </label>\n <input\n type=\"number\"\n id=\"days\"\n class=\"input-text input-text--full-width\"\n value={this.duration?.days.toString()}\n ref={el => (this.daysEl = el as HTMLInputElement)}\n />\n </div>\n\n <div class=\"control-wrapper control-wrapper--vertical\">\n <label htmlFor=\"hours\">\n {this._componentLocale.controls.hours}\n </label>\n <input\n type=\"number\"\n id=\"hours\"\n class=\"input-text input-text--full-width\"\n value={this.duration?.hours.toString()}\n ref={el => (this.hoursEl = el as HTMLInputElement)}\n />\n </div>\n\n <div class=\"control-wrapper control-wrapper--vertical\">\n <label htmlFor=\"minutes\">\n {this._componentLocale.controls.minutes}\n </label>\n <input\n type=\"number\"\n id=\"minutes\"\n class=\"input-text input-text--full-width\"\n value={this.duration?.minutes.toString()}\n ref={el => (this.minutesEl = el as HTMLInputElement)}\n />\n </div>\n\n <div class=\"control-wrapper control-wrapper--vertical\">\n <label htmlFor=\"seconds\">\n {this._componentLocale.controls.seconds}\n </label>\n <input\n type=\"number\"\n id=\"seconds\"\n class=\"input-text input-text--full-width\"\n value={this.duration?.seconds.toString()}\n ref={el => (this.secondsEl = el as HTMLInputElement)}\n />\n </div>\n\n <div class=\"controls-wrapper\">\n <button onClick={this.confirmCallbackHandler}>\n {this._componentLocale.controls.ok}\n </button>\n <button onClick={this.cancelCallback}>\n {this._componentLocale.controls.cancel}\n </button>\n </div>\n </gx-ide-container>\n </div>\n </Host>\n );\n }\n}\n\nexport type TimerDuration = {\n years: number;\n months: number;\n days: number;\n hours: number;\n minutes: number;\n seconds: number;\n};\n"],"version":3}
|
|
@@ -82,11 +82,9 @@ const GxIdeConnectGxServer$1 = /*@__PURE__*/ proxyCustomElement(class GxIdeConne
|
|
|
82
82
|
}
|
|
83
83
|
// 10.RENDER() FUNCTION //
|
|
84
84
|
render() {
|
|
85
|
-
var _a;
|
|
86
|
-
return (h(Host, { class: "gx-ide-component" }, h("div", { class: "gx-ide-main-wrapper" }, h("gx-ide-container", { containerTitle: this.displayTitle ? this._componentLocale.componentName : null, slimmerFooter: config.gxIdeContainer.slimmerFooter }, h("div", { class: "wrapper" }, h("gxg-combo-box", { label: this._componentLocale.main.serverUrl, disableFilter: !this.enableCustomServer, value: (_a = this.defaultConnectionData) === null || _a === void 0 ? void 0 : _a.serverUrl, ref: el => (this.serverURLEl = el), toolTip: config.tooltip }, this.renderServerUrls()), h("gxg-form-checkbox", { label: this._componentLocale.main.continueWithGxAccount, onChange: this.continueWithGxServerHandler, checked: this.
|
|
87
|
-
? this.defaultConnectionData.
|
|
88
|
-
: this.enableUserLogged, disabled: !this.enableUserLogged, ref: el => (this.continueWithGeneXusAccountEl =
|
|
89
|
-
el) }), this.displayLoginControls ? (h("div", { class: "user-details-container" }, h("gxg-form-text", { label: this._componentLocale.main.userName, labelPosition: "above", disabled: !this.displayLoginControls, value: this.defaultConnectionData.user, ref: el => (this.userNameEl = el), toolTip: config.tooltip }), h("gxg-form-text", { label: this._componentLocale.main.password, labelPosition: "above", disabled: !this.displayLoginControls, value: this.defaultConnectionData.password, ref: el => (this.passwordEl = el), password: true, toolTip: config.tooltip }))) : null), h("gxg-button", { slot: "footer-end", type: "outlined" }, this._componentLocale.main.cancel), h("gxg-button", { slot: "footer-end", onClick: this.connectHandler }, this._componentLocale.main.connect)))));
|
|
85
|
+
var _a, _b, _c;
|
|
86
|
+
return (h(Host, { class: "gx-ide-component" }, h("div", { class: "gx-ide-main-wrapper" }, h("gx-ide-container", { containerTitle: this.displayTitle ? this._componentLocale.componentName : null, slimmerFooter: config.gxIdeContainer.slimmerFooter }, h("div", { class: "wrapper" }, h("gxg-combo-box", { label: this._componentLocale.main.serverUrl, disableFilter: !this.enableCustomServer, value: (_a = this.defaultConnectionData) === null || _a === void 0 ? void 0 : _a.serverUrl, ref: el => (this.serverURLEl = el), toolTip: config.tooltip }, this.renderServerUrls()), h("gxg-form-checkbox", { label: this._componentLocale.main.continueWithGxAccount, onChange: this.continueWithGxServerHandler, checked: this.enableUserLogged, disabled: !this.enableUserLogged, ref: el => (this.continueWithGeneXusAccountEl =
|
|
87
|
+
el) }), this.displayLoginControls ? (h("div", { class: "user-details-container" }, h("gxg-form-text", { label: this._componentLocale.main.userName, labelPosition: "above", disabled: !this.displayLoginControls, value: (_b = this.defaultConnectionData) === null || _b === void 0 ? void 0 : _b.user, ref: el => (this.userNameEl = el), toolTip: config.tooltip }), h("gxg-form-text", { label: this._componentLocale.main.password, labelPosition: "above", disabled: !this.displayLoginControls, value: (_c = this.defaultConnectionData) === null || _c === void 0 ? void 0 : _c.password, ref: el => (this.passwordEl = el), password: true, toolTip: config.tooltip }))) : null), h("gxg-button", { slot: "footer-end", type: "outlined" }, this._componentLocale.main.cancel), h("gxg-button", { slot: "footer-end", onClick: this.connectHandler }, this._componentLocale.main.connect)))));
|
|
90
88
|
}
|
|
91
89
|
static get assetsDirs() { return ["gx-ide-assets/connect-gx-server"]; }
|
|
92
90
|
get el() { return this; }
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"file":"gx-ide-connect-gx-server.js","mappings":";;;;;;;;;;;;;;;;;AAAA,MAAM,kBAAkB,GAAG,0gWAA0gW;;MCwBxhWA,sBAAoB;;;;;;QAOvB,sBAAiB,GAAG,KAAK,CAAC;;;;QAoF1B,qBAAgB,GAAG;;YACzB,IAAI,MAAA,IAAI,CAAC,UAAU,0CAAE,MAAM,EAAE;gBAC3B,OAAO,IAAI,CAAC,UAAU,CAAC,GAAG,CAAC,SAAS;oBAClC,OAAO,8BAAqB,SAAS,CAAsB,CAAC;iBAC7D,CAAC,CAAC;aACJ;YACD,OAAO,EAAE,CAAC;SACX,CAAC;QAEM,gCAA2B,GAAG,CACpC,KAAsE;YAEtE,IAAI,CAAC,oBAAoB,GAAG,CAAC,KAAK,CAAC,MAAM,CAAC,KAAK,CAAC;SACjD,CAAC;QAEM,iCAA4B,GAAG;YACrC,IAAI,IAAI,CAAC,gBAAgB,EAAE;gBACzB,IAAI,CAAC,oBAAoB,GAAG,KAAK,CAAC;aACnC;iBAAM;gBACL,IAAI,CAAC,oBAAoB,GAAG,IAAI,CAAC;aAClC;SACF,CAAC;QAEM,mBAAc,GAAG;YACvB,IAAI,IAAI,CAAC,eAAe,EAAE;gBACxB,IAAI,CAAC,eAAe,CAAC;oBACnB,SAAS,EAAE,IAAI,CAAC,WAAW,CAAC,KAAK;oBACjC,0BAA0B,EAAE,IAAI,CAAC,4BAA4B,CAAC,OAAO;oBACrE,IAAI,EAAE,IAAI,CAAC,UAAU,CAAC,KAAK;oBAC3B,QAAQ,EAAE,IAAI,CAAC,UAAU,CAAC,KAAK;iBAChC,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CAAC,OAAO,CACxB,CACI,CACf,CACD,EACP;KACH;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","names":["GxIdeConnectGxServer"],"sources":["src/components/connect-gx-server/connect-gx-server.scss?tag=gx-ide-connect-gx-server&encapsulation=shadow","src/components/connect-gx-server/connect-gx-server.tsx"],"sourcesContent":["@import \"../../global/gx-ide-common.scss\";\n@import \"../../global/gx-ide-mixins.scss\";\n\n:host {\n display: block;\n}\n\n.user-details-container {\n display: flex;\n gap: var(--gx-ide-form-items-gap);\n}\n\n.wrapper {\n display: flex;\n flex-direction: column;\n gap: var(--mer-spacing--md);\n}\n","/* STENCIL IMPORTS */\nimport {\n Component,\n Host,\n h,\n Prop,\n Element,\n Event,\n EventEmitter,\n State\n} from \"@stencil/core\";\n/* OTHER LIBRARIES IMPORTS */\n/* CUSTOM IMPORTS */\nimport { config } from \"../../common/config\";\nimport { Locale } from \"../../common/locale\";\nimport { formSubmitValidation } from \"../../common/form-validation\";\nimport { ConnectionResultData } from \"../../common/types\";\n\n@Component({\n tag: \"gx-ide-connect-gx-server\",\n styleUrl: \"connect-gx-server.scss\",\n shadow: true,\n assetsDirs: [\"gx-ide-assets/connect-gx-server\"]\n})\nexport class GxIdeConnectGxServer {\n // 1.OWN PROPERTIES //\n\n /**\n * The component hard-coded strings translations.\n */\n private _componentLocale: any;\n private renderedFirstTime = false;\n\n // 2. REFERENCE TO ELEMENTS //\n\n @Element() el: HTMLGxIdeConnectGxServerElement;\n\n private serverURLEl!: HTMLGxgComboBoxElement;\n private userNameEl!: HTMLGxgFormTextElement;\n private passwordEl!: HTMLGxgFormTextElement;\n private continueWithGeneXusAccountEl!: HTMLGxgFormCheckboxElement;\n\n // 3.STATE() VARIABLES //\n\n //\n @State() displayLoginControls: boolean = false;\n\n // 4.PUBLIC PROPERTY API | WATCH'S //\n\n /**\n * If true it displays the component title on the header\n */\n @Prop() readonly displayTitle = false;\n\n /**\n * Array of cataloged server URLs\n */\n @Prop() readonly serverUrls: string[];\n\n /**\n * 'true' if the user should be allowed to manually enter a server URL in serverUrls.\n */\n @Prop() readonly enableCustomServer: boolean = false;\n\n /**\n * Initial user values for the case in which the user returns to the login modal after a successful authentication.\n */\n @Prop() readonly defaultConnectionData?: GXServerConnectionData;\n\n /**\n * If 'true', shows the enabled and checked 'Continue with GX Account' checkbox. If 'false', shows the checkbox unchecked and disabled, and displays the options to enter username and password directly. Even if 'true', allow the user to deselect the checkbox and enter username and password.\n */\n @Prop() readonly enableUserLogged: boolean = false;\n\n /**\n * If 'true', shows the enabled and checked 'Continue with GX Account' checkbox. If 'false', shows the checkbox unchecked and disabled, and displays the options to enter username and password directly. Even if 'true', allow the user to deselect the checkbox and enter username and password.\n */\n @Prop() readonly connectCallback: (\n data: GXServerConnectionData\n ) => Promise<ConnectionResultData>;\n\n /**\n * Callback that allows canceling the server connection process.\n */\n @Prop() readonly cancelCallback: () => Promise<void>;\n\n // 5.EVENTS (EMIT) //\n\n /**\n * @description Gets fired when the component has rendered for the first time.\n */\n @Event() componentDidRenderFirstTime: EventEmitter<string>;\n\n // 6.COMPONENT LIFECYCLE METHODS //\n\n async componentWillLoad() {\n this._componentLocale = await Locale.getComponentStrings(this.el);\n this.evaluateDisplayLoginControls();\n }\n\n componentDidRender() {\n if (!this.renderedFirstTime) {\n this.componentDidRenderFirstTime.emit(\n this._componentLocale.componentName\n );\n this.renderedFirstTime = true;\n }\n }\n\n // 7.LISTENERS //\n\n // 8.PUBLIC METHODS API //\n\n // 9.LOCAL METHODS //\n\n private renderServerUrls = (): HTMLGxgComboBoxItemElement[] => {\n if (this.serverUrls?.length) {\n return this.serverUrls.map(serverUrl => {\n return <gxg-combo-box-item>{serverUrl}</gxg-combo-box-item>;\n });\n }\n return [];\n };\n\n private continueWithGxServerHandler = (\n event: CustomEvent<{ id: string; value: boolean; disabled?: boolean }>\n ) => {\n this.displayLoginControls = !event.detail.value;\n };\n\n private evaluateDisplayLoginControls = () => {\n if (this.enableUserLogged) {\n this.displayLoginControls = false;\n } else {\n this.displayLoginControls = true;\n }\n };\n\n private connectHandler = () => {\n if (this.connectCallback) {\n this.connectCallback({\n serverUrl: this.serverURLEl.value,\n continueWithGeneXusAccount: this.continueWithGeneXusAccountEl.checked,\n user: this.userNameEl.value,\n password: this.passwordEl.value\n }).then((formSubmitResult: ConnectionResultData) => {\n console.log(formSubmitResult);\n formSubmitValidation(formSubmitResult, this);\n });\n }\n };\n\n // 10.RENDER() FUNCTION //\n\n render() {\n return (\n <Host class=\"gx-ide-component\">\n <div class=\"gx-ide-main-wrapper\">\n <gx-ide-container\n containerTitle={\n this.displayTitle ? this._componentLocale.componentName : null\n }\n slimmerFooter={config.gxIdeContainer.slimmerFooter}\n >\n <div class=\"wrapper\">\n {/* server url */}\n <gxg-combo-box\n label={this._componentLocale.main.serverUrl}\n disableFilter={!this.enableCustomServer}\n value={this.defaultConnectionData?.serverUrl}\n ref={el => (this.serverURLEl = el as HTMLGxgComboBoxElement)}\n toolTip={config.tooltip}\n >\n {this.renderServerUrls()}\n </gxg-combo-box>\n\n {/* continue with GeneXus account */}\n <gxg-form-checkbox\n label={this._componentLocale.main.continueWithGxAccount}\n onChange={this.continueWithGxServerHandler}\n checked={\n this.defaultConnectionData\n ? this.defaultConnectionData.continueWithGeneXusAccount\n : this.enableUserLogged\n }\n disabled={!this.enableUserLogged}\n ref={el =>\n (this.continueWithGeneXusAccountEl =\n el as HTMLGxgFormCheckboxElement)\n }\n ></gxg-form-checkbox>\n\n {this.displayLoginControls ? (\n <div class=\"user-details-container\">\n {/* username */}\n <gxg-form-text\n label={this._componentLocale.main.userName}\n labelPosition=\"above\"\n disabled={!this.displayLoginControls}\n value={this.defaultConnectionData.user}\n ref={el => (this.userNameEl = el as HTMLGxgFormTextElement)}\n toolTip={config.tooltip}\n ></gxg-form-text>\n {/* password */}\n <gxg-form-text\n label={this._componentLocale.main.password}\n labelPosition=\"above\"\n disabled={!this.displayLoginControls}\n value={this.defaultConnectionData.password}\n ref={el => (this.passwordEl = el as HTMLGxgFormTextElement)}\n password\n toolTip={config.tooltip}\n ></gxg-form-text>\n </div>\n ) : null}\n </div>\n\n {/* cancel and connect buttons */}\n <gxg-button slot=\"footer-end\" type=\"outlined\">\n {this._componentLocale.main.cancel}\n </gxg-button>\n <gxg-button slot=\"footer-end\" onClick={this.connectHandler}>\n {this._componentLocale.main.connect}\n </gxg-button>\n </gx-ide-container>\n </div>\n </Host>\n );\n }\n}\n\nexport type GXServerConnectionData = {\n serverUrl: string;\n continueWithGeneXusAccount: boolean;\n user: string;\n password: string;\n};\n"],"version":3}
|
|
1
|
+
{"file":"gx-ide-connect-gx-server.js","mappings":";;;;;;;;;;;;;;;;;AAAA,MAAM,kBAAkB,GAAG,0gWAA0gW;;MCwBxhWA,sBAAoB;;;;;;QAOvB,sBAAiB,GAAG,KAAK,CAAC;;;;QAoF1B,qBAAgB,GAAG;;YACzB,IAAI,MAAA,IAAI,CAAC,UAAU,0CAAE,MAAM,EAAE;gBAC3B,OAAO,IAAI,CAAC,UAAU,CAAC,GAAG,CAAC,SAAS;oBAClC,OAAO,8BAAqB,SAAS,CAAsB,CAAC;iBAC7D,CAAC,CAAC;aACJ;YACD,OAAO,EAAE,CAAC;SACX,CAAC;QAEM,gCAA2B,GAAG,CACpC,KAAsE;YAEtE,IAAI,CAAC,oBAAoB,GAAG,CAAC,KAAK,CAAC,MAAM,CAAC,KAAK,CAAC;SACjD,CAAC;QAEM,iCAA4B,GAAG;YACrC,IAAI,IAAI,CAAC,gBAAgB,EAAE;gBACzB,IAAI,CAAC,oBAAoB,GAAG,KAAK,CAAC;aACnC;iBAAM;gBACL,IAAI,CAAC,oBAAoB,GAAG,IAAI,CAAC;aAClC;SACF,CAAC;QAEM,mBAAc,GAAG;YACvB,IAAI,IAAI,CAAC,eAAe,EAAE;gBACxB,IAAI,CAAC,eAAe,CAAC;oBACnB,SAAS,E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gBAAgB,CAAC,IAAI,CAAC,MAAM,CACvB,EACb,kBAAY,IAAI,EAAC,YAAY,EAAC,OAAO,EAAE,IAAI,CAAC,cAAc,IACvD,IAAI,CAAC,gBAAgB,CAAC,IAAI,CAAC,OAAO,CACxB,CACI,CACf,CACD,EACP;KACH;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","names":["GxIdeConnectGxServer"],"sources":["src/components/connect-gx-server/connect-gx-server.scss?tag=gx-ide-connect-gx-server&encapsulation=shadow","src/components/connect-gx-server/connect-gx-server.tsx"],"sourcesContent":["@import \"../../global/gx-ide-common.scss\";\n@import \"../../global/gx-ide-mixins.scss\";\n\n:host {\n display: block;\n}\n\n.user-details-container {\n display: flex;\n gap: var(--gx-ide-form-items-gap);\n}\n\n.wrapper {\n display: flex;\n flex-direction: column;\n gap: var(--mer-spacing--md);\n}\n","/* STENCIL IMPORTS */\nimport {\n Component,\n Host,\n h,\n Prop,\n Element,\n Event,\n EventEmitter,\n State\n} from \"@stencil/core\";\n/* OTHER LIBRARIES IMPORTS */\n/* CUSTOM IMPORTS */\nimport { config } from \"../../common/config\";\nimport { Locale } from \"../../common/locale\";\nimport { formSubmitValidation } from \"../../common/form-validation\";\nimport { ConnectionResultData } from \"../../common/types\";\n\n@Component({\n tag: \"gx-ide-connect-gx-server\",\n styleUrl: \"connect-gx-server.scss\",\n shadow: true,\n assetsDirs: [\"gx-ide-assets/connect-gx-server\"]\n})\nexport class GxIdeConnectGxServer {\n // 1.OWN PROPERTIES //\n\n /**\n * The component hard-coded strings translations.\n */\n private _componentLocale: any;\n private renderedFirstTime = false;\n\n // 2. REFERENCE TO ELEMENTS //\n\n @Element() el: HTMLGxIdeConnectGxServerElement;\n\n private serverURLEl!: HTMLGxgComboBoxElement;\n private userNameEl!: HTMLGxgFormTextElement;\n private passwordEl!: HTMLGxgFormTextElement;\n private continueWithGeneXusAccountEl!: HTMLGxgFormCheckboxElement;\n\n // 3.STATE() VARIABLES //\n\n //\n @State() displayLoginControls: boolean = false;\n\n // 4.PUBLIC PROPERTY API | WATCH'S //\n\n /**\n * If true it displays the component title on the header\n */\n @Prop() readonly displayTitle = false;\n\n /**\n * Array of cataloged server URLs\n */\n @Prop() readonly serverUrls: string[];\n\n /**\n * 'true' if the user should be allowed to manually enter a server URL in serverUrls.\n */\n @Prop() readonly enableCustomServer: boolean = false;\n\n /**\n * Initial user values for the case in which the user returns to the login modal after a successful authentication.\n */\n @Prop() readonly defaultConnectionData?: GXServerConnectionDefault;\n\n /**\n * If 'true', shows the enabled and checked 'Continue with GX Account' checkbox. If 'false', shows the checkbox unchecked and disabled, and displays the options to enter username and password directly. Even if 'true', allow the user to deselect the checkbox and enter username and password.\n */\n @Prop() readonly enableUserLogged: boolean = false;\n\n /**\n * If 'true', shows the enabled and checked 'Continue with GX Account' checkbox. If 'false', shows the checkbox unchecked and disabled, and displays the options to enter username and password directly. Even if 'true', allow the user to deselect the checkbox and enter username and password.\n */\n @Prop() readonly connectCallback: (\n data: GXServerConnectionData\n ) => Promise<ConnectionResultData>;\n\n /**\n * Callback that allows canceling the server connection process.\n */\n @Prop() readonly cancelCallback: () => Promise<void>;\n\n // 5.EVENTS (EMIT) //\n\n /**\n * @description Gets fired when the component has rendered for the first time.\n */\n @Event() componentDidRenderFirstTime: EventEmitter<string>;\n\n // 6.COMPONENT LIFECYCLE METHODS //\n\n async componentWillLoad() {\n this._componentLocale = await Locale.getComponentStrings(this.el);\n this.evaluateDisplayLoginControls();\n }\n\n componentDidRender() {\n if (!this.renderedFirstTime) {\n this.componentDidRenderFirstTime.emit(\n this._componentLocale.componentName\n );\n this.renderedFirstTime = true;\n }\n }\n\n // 7.LISTENERS //\n\n // 8.PUBLIC METHODS API //\n\n // 9.LOCAL METHODS //\n\n private renderServerUrls = (): HTMLGxgComboBoxItemElement[] => {\n if (this.serverUrls?.length) {\n return this.serverUrls.map(serverUrl => {\n return <gxg-combo-box-item>{serverUrl}</gxg-combo-box-item>;\n });\n }\n return [];\n };\n\n private continueWithGxServerHandler = (\n event: CustomEvent<{ id: string; value: boolean; disabled?: boolean }>\n ) => {\n this.displayLoginControls = !event.detail.value;\n };\n\n private evaluateDisplayLoginControls = () => {\n if (this.enableUserLogged) {\n this.displayLoginControls = false;\n } else {\n this.displayLoginControls = true;\n }\n };\n\n private connectHandler = () => {\n if (this.connectCallback) {\n this.connectCallback({\n serverUrl: this.serverURLEl.value,\n continueWithGeneXusAccount: this.continueWithGeneXusAccountEl.checked,\n user: this.userNameEl.value,\n password: this.passwordEl.value\n }).then((formSubmitResult: ConnectionResultData) => {\n console.log(formSubmitResult);\n formSubmitValidation(formSubmitResult, this);\n });\n }\n };\n\n // 10.RENDER() FUNCTION //\n\n render() {\n return (\n <Host class=\"gx-ide-component\">\n <div class=\"gx-ide-main-wrapper\">\n <gx-ide-container\n containerTitle={\n this.displayTitle ? this._componentLocale.componentName : null\n }\n slimmerFooter={config.gxIdeContainer.slimmerFooter}\n >\n <div class=\"wrapper\">\n {/* server url */}\n <gxg-combo-box\n label={this._componentLocale.main.serverUrl}\n disableFilter={!this.enableCustomServer}\n value={this.defaultConnectionData?.serverUrl}\n ref={el => (this.serverURLEl = el as HTMLGxgComboBoxElement)}\n toolTip={config.tooltip}\n >\n {this.renderServerUrls()}\n </gxg-combo-box>\n\n {/* continue with GeneXus account */}\n <gxg-form-checkbox\n label={this._componentLocale.main.continueWithGxAccount}\n onChange={this.continueWithGxServerHandler}\n checked={this.enableUserLogged}\n disabled={!this.enableUserLogged}\n ref={el =>\n (this.continueWithGeneXusAccountEl =\n el as HTMLGxgFormCheckboxElement)\n }\n ></gxg-form-checkbox>\n\n {this.displayLoginControls ? (\n <div class=\"user-details-container\">\n {/* username */}\n <gxg-form-text\n label={this._componentLocale.main.userName}\n labelPosition=\"above\"\n disabled={!this.displayLoginControls}\n value={this.defaultConnectionData?.user}\n ref={el => (this.userNameEl = el as HTMLGxgFormTextElement)}\n toolTip={config.tooltip}\n ></gxg-form-text>\n {/* password */}\n <gxg-form-text\n label={this._componentLocale.main.password}\n labelPosition=\"above\"\n disabled={!this.displayLoginControls}\n value={this.defaultConnectionData?.password}\n ref={el => (this.passwordEl = el as HTMLGxgFormTextElement)}\n password\n toolTip={config.tooltip}\n ></gxg-form-text>\n </div>\n ) : null}\n </div>\n\n {/* cancel and connect buttons */}\n <gxg-button slot=\"footer-end\" type=\"outlined\">\n {this._componentLocale.main.cancel}\n </gxg-button>\n <gxg-button slot=\"footer-end\" onClick={this.connectHandler}>\n {this._componentLocale.main.connect}\n </gxg-button>\n </gx-ide-container>\n </div>\n </Host>\n );\n }\n}\n\nexport type GXServerConnectionDefault = {\n serverUrl: string;\n user: string;\n password: string;\n};\n\nexport type GXServerConnectionData = GXServerConnectionDefault & {\n continueWithGeneXusAccount: boolean;\n};\n"],"version":3}
|
|
@@ -43,7 +43,7 @@ const GxIdeBpmTimerDuration = class {
|
|
|
43
43
|
// 10.RENDER() FUNCTION //
|
|
44
44
|
render() {
|
|
45
45
|
var _a, _b, _c, _d, _e, _f;
|
|
46
|
-
return (h(Host, { class: "gx-ide-component" }, h("div", { class: "gx-ide-main-wrapper" }, h("gx-ide-container", { containerTitle: this.displayTitle ? this._componentLocale.componentName : null, slimmerFooter: config.gxIdeContainer.slimmerFooter }, h("div", { class: "control-wrapper control-wrapper--vertical" }, h("label", { htmlFor: "years" }, this._componentLocale.controls.years), h("input", { type: "number", id: "years", class: "input-text input-text--full-width", value: (_a = this.duration) === null || _a === void 0 ? void 0 : _a.years.toString(), ref: el => (this.yearsEl = el) })), h("div", { class: "control-wrapper control-wrapper--vertical" }, h("label", { htmlFor: "months" }, this._componentLocale.controls.months), h("input", { type: "number", id: "months", class: "input-text input-text--full-width", value: (_b = this.duration) === null || _b === void 0 ? void 0 : _b.months.toString(), ref: el => (this.monthsEl = el) })), h("div", { class: "control-wrapper control-wrapper--vertical" }, h("label", { htmlFor: "days" }, this._componentLocale.controls.days), h("input", { type: "number", id: "days", class: "input-text input-text--full-width", value: (_c = this.duration) === null || _c === void 0 ? void 0 : _c.
|
|
46
|
+
return (h(Host, { class: "gx-ide-component" }, h("div", { class: "gx-ide-main-wrapper" }, h("gx-ide-container", { containerTitle: this.displayTitle ? this._componentLocale.componentName : null, slimmerFooter: config.gxIdeContainer.slimmerFooter }, h("div", { class: "control-wrapper control-wrapper--vertical" }, h("label", { htmlFor: "years" }, this._componentLocale.controls.years), h("input", { type: "number", id: "years", class: "input-text input-text--full-width", value: (_a = this.duration) === null || _a === void 0 ? void 0 : _a.years.toString(), ref: el => (this.yearsEl = el) })), h("div", { class: "control-wrapper control-wrapper--vertical" }, h("label", { htmlFor: "months" }, this._componentLocale.controls.months), h("input", { type: "number", id: "months", class: "input-text input-text--full-width", value: (_b = this.duration) === null || _b === void 0 ? void 0 : _b.months.toString(), ref: el => (this.monthsEl = el) })), h("div", { class: "control-wrapper control-wrapper--vertical" }, h("label", { htmlFor: "days" }, this._componentLocale.controls.days), h("input", { type: "number", id: "days", class: "input-text input-text--full-width", value: (_c = this.duration) === null || _c === void 0 ? void 0 : _c.days.toString(), ref: el => (this.daysEl = el) })), h("div", { class: "control-wrapper control-wrapper--vertical" }, h("label", { htmlFor: "hours" }, this._componentLocale.controls.hours), h("input", { type: "number", id: "hours", class: "input-text input-text--full-width", value: (_d = this.duration) === null || _d === void 0 ? void 0 : _d.hours.toString(), ref: el => (this.hoursEl = el) })), h("div", { class: "control-wrapper control-wrapper--vertical" }, h("label", { htmlFor: "minutes" }, this._componentLocale.controls.minutes), h("input", { type: "number", id: "minutes", class: "input-text input-text--full-width", value: (_e = this.duration) === null || _e === void 0 ? void 0 : _e.minutes.toString(), ref: el => (this.minutesEl = el) })), h("div", { class: "control-wrapper control-wrapper--vertical" }, h("label", { htmlFor: "seconds" }, this._componentLocale.controls.seconds), h("input", { type: "number", id: "seconds", class: "input-text input-text--full-width", value: (_f = this.duration) === null || _f === void 0 ? void 0 : _f.seconds.toString(), ref: el => (this.secondsEl = el) })), h("div", { class: "controls-wrapper" }, h("button", { onClick: this.confirmCallbackHandler }, this._componentLocale.controls.ok), h("button", { onClick: this.cancelCallback }, this._componentLocale.controls.cancel))))));
|
|
47
47
|
}
|
|
48
48
|
static get assetsDirs() { return ["gx-ide-assets/bpm-timer-duration"]; }
|
|
49
49
|
get el() { return getElement(this); }
|