@genexus/genexus-ide-ui 3.2.10 → 3.2.12

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (115) hide show
  1. package/dist/cjs/genexus-ide-ui.cjs.js +1 -1
  2. package/dist/cjs/gx-ide-db-properties-configurator.cjs.entry.js +165 -0
  3. package/dist/cjs/gx-ide-db-properties-configurator.cjs.entry.js.map +1 -0
  4. package/dist/cjs/gx-ide-select-team-or-org.cjs.entry.js +128 -0
  5. package/dist/cjs/gx-ide-select-team-or-org.cjs.entry.js.map +1 -0
  6. package/dist/cjs/gx-ide-sign-in-organization.cjs.entry.js +187 -0
  7. package/dist/cjs/gx-ide-sign-in-organization.cjs.entry.js.map +1 -0
  8. package/dist/cjs/loader.cjs.js +1 -1
  9. package/dist/collection/collection-manifest.json +3 -2
  10. package/dist/collection/components/db-properties-configurator/db-properties-configurator.css +127 -0
  11. package/dist/collection/components/db-properties-configurator/db-properties-configurator.js +250 -0
  12. package/dist/collection/components/db-properties-configurator/db-properties-configurator.js.map +1 -0
  13. package/dist/collection/components/db-properties-configurator/gx-ide-assets/db-properties-configurator/langs/db-properties-configurator.lang.en.json +24 -0
  14. package/dist/collection/components/db-properties-configurator/gx-ide-assets/db-properties-configurator/langs/db-properties-configurator.lang.ja.json +24 -0
  15. package/dist/collection/components/db-properties-configurator/gx-ide-assets/db-properties-configurator/langs/db-properties-configurator.lang.zh.json +24 -0
  16. package/dist/collection/components/select-team-or-org/gx-ide-assets/select-team-or-org/langs/select-team-or-org.lang.en.json +18 -0
  17. package/dist/collection/components/select-team-or-org/gx-ide-assets/select-team-or-org/langs/select-team-or-org.lang.ja.json +18 -0
  18. package/dist/collection/components/select-team-or-org/gx-ide-assets/select-team-or-org/langs/select-team-or-org.lang.zh.json +18 -0
  19. package/dist/collection/components/select-team-or-org/helpers.js +9 -0
  20. package/dist/collection/components/select-team-or-org/helpers.js.map +1 -0
  21. package/dist/collection/components/{select-user-team/select-user-team.css → select-team-or-org/select-team-or-org.css} +7 -4
  22. package/dist/collection/components/select-team-or-org/select-team-or-org.js +220 -0
  23. package/dist/collection/components/select-team-or-org/select-team-or-org.js.map +1 -0
  24. package/dist/{genexus-ide-ui/gx-ide-assets/sign-in-team/langs/sign-in-team.lang.en.json → collection/components/sign-in-organization/gx-ide-assets/sign-in-organization/langs/sign-in-organization.lang.en.json} +5 -5
  25. package/dist/{genexus-ide-ui/gx-ide-assets/sign-in-team/langs/sign-in-team.lang.ja.json → collection/components/sign-in-organization/gx-ide-assets/sign-in-organization/langs/sign-in-organization.lang.ja.json} +5 -5
  26. package/dist/collection/components/{sign-in-team/gx-ide-assets/sign-in-team/langs/sign-in-team.lang.en.json → sign-in-organization/gx-ide-assets/sign-in-organization/langs/sign-in-organization.lang.zh.json} +5 -5
  27. package/dist/collection/components/sign-in-organization/helpers.js +10 -0
  28. package/dist/collection/components/sign-in-organization/helpers.js.map +1 -0
  29. package/dist/collection/components/{sign-in-team/sign-in-team.js → sign-in-organization/sign-in-organization.js} +72 -72
  30. package/dist/collection/components/sign-in-organization/sign-in-organization.js.map +1 -0
  31. package/dist/collection/testing/locale.e2e.js +3 -2
  32. package/dist/collection/testing/locale.e2e.js.map +1 -1
  33. package/dist/components/gx-ide-db-properties-configurator.d.ts +11 -0
  34. package/dist/components/gx-ide-db-properties-configurator.js +183 -0
  35. package/dist/components/gx-ide-db-properties-configurator.js.map +1 -0
  36. package/dist/components/gx-ide-select-team-or-org.d.ts +11 -0
  37. package/dist/components/gx-ide-select-team-or-org.js +157 -0
  38. package/dist/components/gx-ide-select-team-or-org.js.map +1 -0
  39. package/dist/components/gx-ide-sign-in-organization.d.ts +11 -0
  40. package/dist/components/gx-ide-sign-in-organization.js +221 -0
  41. package/dist/components/gx-ide-sign-in-organization.js.map +1 -0
  42. package/dist/esm/genexus-ide-ui.js +1 -1
  43. package/dist/esm/gx-ide-db-properties-configurator.entry.js +161 -0
  44. package/dist/esm/gx-ide-db-properties-configurator.entry.js.map +1 -0
  45. package/dist/esm/gx-ide-select-team-or-org.entry.js +124 -0
  46. package/dist/esm/gx-ide-select-team-or-org.entry.js.map +1 -0
  47. package/dist/esm/gx-ide-sign-in-organization.entry.js +183 -0
  48. package/dist/esm/gx-ide-sign-in-organization.entry.js.map +1 -0
  49. package/dist/esm/loader.js +1 -1
  50. package/dist/genexus-ide-ui/genexus-ide-ui.esm.js +1 -1
  51. package/dist/genexus-ide-ui/genexus-ide-ui.esm.js.map +1 -1
  52. package/dist/genexus-ide-ui/gx-ide-assets/db-properties-configurator/langs/db-properties-configurator.lang.en.json +24 -0
  53. package/dist/genexus-ide-ui/gx-ide-assets/db-properties-configurator/langs/db-properties-configurator.lang.ja.json +24 -0
  54. package/dist/genexus-ide-ui/gx-ide-assets/db-properties-configurator/langs/db-properties-configurator.lang.zh.json +24 -0
  55. package/dist/genexus-ide-ui/gx-ide-assets/select-team-or-org/langs/select-team-or-org.lang.en.json +18 -0
  56. package/dist/genexus-ide-ui/gx-ide-assets/select-team-or-org/langs/select-team-or-org.lang.ja.json +18 -0
  57. package/dist/genexus-ide-ui/gx-ide-assets/select-team-or-org/langs/select-team-or-org.lang.zh.json +18 -0
  58. package/dist/genexus-ide-ui/gx-ide-assets/{sign-in-team/langs/sign-in-team.lang.zh.json → sign-in-organization/langs/sign-in-organization.lang.en.json} +5 -5
  59. package/dist/{collection/components/sign-in-team/gx-ide-assets/sign-in-team/langs/sign-in-team.lang.ja.json → genexus-ide-ui/gx-ide-assets/sign-in-organization/langs/sign-in-organization.lang.ja.json} +5 -5
  60. package/dist/{collection/components/sign-in-team/gx-ide-assets/sign-in-team/langs/sign-in-team.lang.zh.json → genexus-ide-ui/gx-ide-assets/sign-in-organization/langs/sign-in-organization.lang.zh.json} +5 -5
  61. package/dist/genexus-ide-ui/{p-1d44dd0a.entry.js → p-15b1c9be.entry.js} +72 -72
  62. package/dist/genexus-ide-ui/p-15b1c9be.entry.js.map +1 -0
  63. package/dist/genexus-ide-ui/p-2129d0d2.entry.js +164 -0
  64. package/dist/genexus-ide-ui/p-2129d0d2.entry.js.map +1 -0
  65. package/dist/genexus-ide-ui/p-e759cfdb.entry.js +281 -0
  66. package/dist/genexus-ide-ui/p-e759cfdb.entry.js.map +1 -0
  67. package/dist/types/components/db-properties-configurator/db-properties-configurator.d.ts +50 -0
  68. package/dist/types/components/select-team-or-org/helpers.d.ts +3 -0
  69. package/dist/types/components/select-team-or-org/select-team-or-org.d.ts +38 -0
  70. package/dist/types/components/sign-in-organization/helpers.d.ts +3 -0
  71. package/dist/types/components/{sign-in-team/sign-in-team.d.ts → sign-in-organization/sign-in-organization.d.ts} +8 -8
  72. package/dist/types/components.d.ts +161 -106
  73. package/package.json +1 -1
  74. package/dist/cjs/gx-ide-select-user-team.cjs.entry.js +0 -121
  75. package/dist/cjs/gx-ide-select-user-team.cjs.entry.js.map +0 -1
  76. package/dist/cjs/gx-ide-sign-in-team.cjs.entry.js +0 -187
  77. package/dist/cjs/gx-ide-sign-in-team.cjs.entry.js.map +0 -1
  78. package/dist/collection/components/select-user-team/gx-ide-assets/select-user-team/langs/select-user-team.lang.en.json +0 -10
  79. package/dist/collection/components/select-user-team/gx-ide-assets/select-user-team/langs/select-user-team.lang.ja.json +0 -10
  80. package/dist/collection/components/select-user-team/gx-ide-assets/select-user-team/langs/select-user-team.lang.zh.json +0 -10
  81. package/dist/collection/components/select-user-team/helpers.js +0 -9
  82. package/dist/collection/components/select-user-team/helpers.js.map +0 -1
  83. package/dist/collection/components/select-user-team/select-user-team.js +0 -189
  84. package/dist/collection/components/select-user-team/select-user-team.js.map +0 -1
  85. package/dist/collection/components/sign-in-team/helpers.js +0 -10
  86. package/dist/collection/components/sign-in-team/helpers.js.map +0 -1
  87. package/dist/collection/components/sign-in-team/sign-in-team.js.map +0 -1
  88. package/dist/components/gx-ide-select-user-team.d.ts +0 -11
  89. package/dist/components/gx-ide-select-user-team.js +0 -149
  90. package/dist/components/gx-ide-select-user-team.js.map +0 -1
  91. package/dist/components/gx-ide-sign-in-team.d.ts +0 -11
  92. package/dist/components/gx-ide-sign-in-team.js +0 -221
  93. package/dist/components/gx-ide-sign-in-team.js.map +0 -1
  94. package/dist/esm/gx-ide-select-user-team.entry.js +0 -117
  95. package/dist/esm/gx-ide-select-user-team.entry.js.map +0 -1
  96. package/dist/esm/gx-ide-sign-in-team.entry.js +0 -183
  97. package/dist/esm/gx-ide-sign-in-team.entry.js.map +0 -1
  98. package/dist/genexus-ide-ui/gx-ide-assets/select-user-team/langs/select-user-team.lang.en.json +0 -10
  99. package/dist/genexus-ide-ui/gx-ide-assets/select-user-team/langs/select-user-team.lang.ja.json +0 -10
  100. package/dist/genexus-ide-ui/gx-ide-assets/select-user-team/langs/select-user-team.lang.zh.json +0 -10
  101. package/dist/genexus-ide-ui/p-1d44dd0a.entry.js.map +0 -1
  102. package/dist/genexus-ide-ui/p-2317ffcb.entry.js +0 -156
  103. package/dist/genexus-ide-ui/p-2317ffcb.entry.js.map +0 -1
  104. package/dist/types/components/select-user-team/helpers.d.ts +0 -3
  105. package/dist/types/components/select-user-team/select-user-team.d.ts +0 -32
  106. package/dist/types/components/sign-in-team/helpers.d.ts +0 -3
  107. /package/dist/collection/components/{select-user-team/gx-ide-assets/select-user-team → select-team-or-org/gx-ide-assets/select-team-or-org}/images/copyrights-illustration.png +0 -0
  108. /package/dist/collection/components/{select-user-team/gx-ide-assets/select-user-team → select-team-or-org/gx-ide-assets/select-team-or-org}/images/icon-next.svg +0 -0
  109. /package/dist/collection/components/{sign-in-team/gx-ide-assets/sign-in-team → sign-in-organization/gx-ide-assets/sign-in-organization}/images/copyrights-illustration.png +0 -0
  110. /package/dist/collection/components/{sign-in-team/gx-ide-assets/sign-in-team → sign-in-organization/gx-ide-assets/sign-in-organization}/images/icon-next.svg +0 -0
  111. /package/dist/collection/components/{sign-in-team/sign-in-team.css → sign-in-organization/sign-in-organization.css} +0 -0
  112. /package/dist/genexus-ide-ui/gx-ide-assets/{select-user-team → select-team-or-org}/images/copyrights-illustration.png +0 -0
  113. /package/dist/genexus-ide-ui/gx-ide-assets/{select-user-team → select-team-or-org}/images/icon-next.svg +0 -0
  114. /package/dist/genexus-ide-ui/gx-ide-assets/{sign-in-team → sign-in-organization}/images/copyrights-illustration.png +0 -0
  115. /package/dist/genexus-ide-ui/gx-ide-assets/{sign-in-team → sign-in-organization}/images/icon-next.svg +0 -0
@@ -0,0 +1,250 @@
1
+ var __classPrivateFieldGet = (this && this.__classPrivateFieldGet) || function (receiver, state, kind, f) {
2
+ if (kind === "a" && !f)
3
+ throw new TypeError("Private accessor was defined without a getter");
4
+ if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver))
5
+ throw new TypeError("Cannot read private member from an object whose class did not declare it");
6
+ return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
7
+ };
8
+ var __classPrivateFieldSet = (this && this.__classPrivateFieldSet) || function (receiver, state, value, kind, f) {
9
+ if (kind === "m")
10
+ throw new TypeError("Private method is not writable");
11
+ if (kind === "a" && !f)
12
+ throw new TypeError("Private accessor was defined without a setter");
13
+ if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver))
14
+ throw new TypeError("Cannot write private member to an object whose class did not declare it");
15
+ return (kind === "a" ? f.call(receiver, value) : f ? f.value = value : state.set(receiver, value)), value;
16
+ };
17
+ var _GxIdeDbPropertiesConfigurator_componentLocale, _GxIdeDbPropertiesConfigurator_getValue, _GxIdeDbPropertiesConfigurator_hasPendingRequired, _GxIdeDbPropertiesConfigurator_buildComboModel, _GxIdeDbPropertiesConfigurator_isAuthField, _GxIdeDbPropertiesConfigurator_hasTrustedConnection, _GxIdeDbPropertiesConfigurator_valueChangeHandler, _GxIdeDbPropertiesConfigurator_cancelButtonClickedHandler, _GxIdeDbPropertiesConfigurator_confirmButtonClickedHandler, _GxIdeDbPropertiesConfigurator_renderControl, _GxIdeDbPropertiesConfigurator_renderField, _GxIdeDbPropertiesConfigurator_renderSection;
18
+ import { Host, h } from "@stencil/core";
19
+ import { getIconPath } from "@genexus/mercury";
20
+ import { Locale } from "../../common/locale";
21
+ import { config } from "../../common/config";
22
+ const CSS_BUNDLES = [
23
+ "resets/box-sizing",
24
+ "components/button",
25
+ "components/combo-box",
26
+ "components/edit",
27
+ "components/icon",
28
+ "utils/form",
29
+ "utils/layout",
30
+ "utils/typography",
31
+ "utils/spacing",
32
+ "chameleon/scrollbar"
33
+ ];
34
+ const DATABASE_ICON = getIconPath({
35
+ category: "system",
36
+ name: "database",
37
+ colorType: "primary"
38
+ });
39
+ /**
40
+ * Name of the property that toggles integrated security. Its presence in
41
+ * `properties` is what drives the rendering of the Authentication section.
42
+ */
43
+ const TRUSTED_CONNECTION = "TRUSTED_CONNECTION";
44
+ const USER_ID = "USER_ID";
45
+ const USER_PASSWORD = "USER_PASSWORD";
46
+ /** Category that groups the authentication-related fields. */
47
+ const AUTH_CATEGORY = "authentication";
48
+ export class GxIdeDbPropertiesConfigurator {
49
+ constructor() {
50
+ // eslint-disable-next-line @stencil-community/own-props-must-be-private
51
+ _GxIdeDbPropertiesConfigurator_componentLocale.set(this, void 0);
52
+ _GxIdeDbPropertiesConfigurator_getValue.set(this, (field) => { var _a; return (_a = field.value) !== null && _a !== void 0 ? _a : ""; });
53
+ _GxIdeDbPropertiesConfigurator_hasPendingRequired.set(this, () => {
54
+ var _a;
55
+ return ((_a = this.properties) !== null && _a !== void 0 ? _a : []).some(field => field.missing && __classPrivateFieldGet(this, _GxIdeDbPropertiesConfigurator_getValue, "f").call(this, field).trim() === "");
56
+ });
57
+ _GxIdeDbPropertiesConfigurator_buildComboModel.set(this, (field) => { var _a; return ((_a = field.standardValues) !== null && _a !== void 0 ? _a : []).map(value => ({ value, caption: value })); });
58
+ _GxIdeDbPropertiesConfigurator_isAuthField.set(this, (field) => {
59
+ var _a;
60
+ return field.name === TRUSTED_CONNECTION ||
61
+ field.name === USER_ID ||
62
+ field.name === USER_PASSWORD ||
63
+ ((_a = field.category) === null || _a === void 0 ? void 0 : _a.toLowerCase()) === AUTH_CATEGORY;
64
+ });
65
+ /** Whether the host sent the TRUSTED_CONNECTION property. Only then is the
66
+ * Authentication section rendered. */
67
+ _GxIdeDbPropertiesConfigurator_hasTrustedConnection.set(this, () => { var _a; return ((_a = this.properties) !== null && _a !== void 0 ? _a : []).some(field => field.name === TRUSTED_CONNECTION); });
68
+ _GxIdeDbPropertiesConfigurator_valueChangeHandler.set(this, (name) => (event) => {
69
+ var _a, _b;
70
+ const detail = event.detail;
71
+ const value = typeof detail === "string"
72
+ ? detail
73
+ : ((_b = (_a = event.target) === null || _a === void 0 ? void 0 : _a.value) !== null && _b !== void 0 ? _b : "");
74
+ this.propertyChangeCallback(name, value);
75
+ });
76
+ _GxIdeDbPropertiesConfigurator_cancelButtonClickedHandler.set(this, () => {
77
+ var _a;
78
+ (_a = this.cancelCallback) === null || _a === void 0 ? void 0 : _a.call(this);
79
+ });
80
+ _GxIdeDbPropertiesConfigurator_confirmButtonClickedHandler.set(this, () => {
81
+ var _a;
82
+ (_a = this.confirmCallback) === null || _a === void 0 ? void 0 : _a.call(this);
83
+ });
84
+ // #region Renders
85
+ _GxIdeDbPropertiesConfigurator_renderControl.set(this, (field) => {
86
+ const fieldId = `field-${field.name}`;
87
+ const value = __classPrivateFieldGet(this, _GxIdeDbPropertiesConfigurator_getValue, "f").call(this, field);
88
+ switch (field.control) {
89
+ case "password":
90
+ return (h("ch-edit", { id: fieldId, class: "input", type: "password", showPasswordButton: true, debounce: config.inputDebounce, value: value, onInput: __classPrivateFieldGet(this, _GxIdeDbPropertiesConfigurator_valueChangeHandler, "f").call(this, field.name) }));
91
+ case "combo":
92
+ return (h("ch-combo-box-render", { id: fieldId, class: "combo-box", value: value, model: __classPrivateFieldGet(this, _GxIdeDbPropertiesConfigurator_buildComboModel, "f").call(this, field), onInput: __classPrivateFieldGet(this, _GxIdeDbPropertiesConfigurator_valueChangeHandler, "f").call(this, field.name), onChange: __classPrivateFieldGet(this, _GxIdeDbPropertiesConfigurator_valueChangeHandler, "f").call(this, field.name) }));
93
+ case "checkbox":
94
+ return (h("ch-checkbox", { id: fieldId, class: "checkbox", value: value, checkedValue: "Yes", unCheckedValue: "No", onInput: __classPrivateFieldGet(this, _GxIdeDbPropertiesConfigurator_valueChangeHandler, "f").call(this, field.name) }));
95
+ case "combo-editable":
96
+ return (h("ch-combo-box-render", { id: fieldId, class: "combo-box", suggest: true, suggestDebounce: config.inputDebounce, value: value, model: __classPrivateFieldGet(this, _GxIdeDbPropertiesConfigurator_buildComboModel, "f").call(this, field), onInput: __classPrivateFieldGet(this, _GxIdeDbPropertiesConfigurator_valueChangeHandler, "f").call(this, field.name), onChange: __classPrivateFieldGet(this, _GxIdeDbPropertiesConfigurator_valueChangeHandler, "f").call(this, field.name), part: `combo-box combo-box--editable combo-box--${field.name}` }));
97
+ case "custom":
98
+ case "readonly":
99
+ return (h("ch-edit", { id: fieldId, class: "input", readonly: true, value: value, part: `input input--${field.control} input--${field.name}` }));
100
+ // "text"
101
+ default:
102
+ return (h("ch-edit", { id: fieldId, class: "input", debounce: config.inputDebounce, value: value, onInput: __classPrivateFieldGet(this, _GxIdeDbPropertiesConfigurator_valueChangeHandler, "f").call(this, field.name), part: `input input--text input--${field.name}` }));
103
+ }
104
+ });
105
+ _GxIdeDbPropertiesConfigurator_renderField.set(this, (field) => {
106
+ const fieldId = `field-${field.name}`;
107
+ const isReadonly = field.control === "readonly" || field.control === "custom";
108
+ const isCheckbox = field.control === "checkbox";
109
+ if (isCheckbox) {
110
+ return (h("div", { class: "field field--checkbox field--full", key: field.name }, h("div", { class: "field__row" }, __classPrivateFieldGet(this, _GxIdeDbPropertiesConfigurator_renderControl, "f").call(this, field), h("label", { class: "label", htmlFor: fieldId }, field.label)), field.description && (h("p", { class: "field__hint body-regular-s" }, field.description))));
111
+ }
112
+ return (h("div", { class: "field field-block", key: field.name }, h("label", { class: { "label": true, "label--disabled": isReadonly }, htmlFor: fieldId }, field.label), __classPrivateFieldGet(this, _GxIdeDbPropertiesConfigurator_renderControl, "f").call(this, field)));
113
+ });
114
+ _GxIdeDbPropertiesConfigurator_renderSection.set(this, (title, fields) => (h("section", { class: "field-section" }, h("div", { class: "field-section__head" }, h("span", { class: "field-section__title" }, title)), h("div", { class: "fields" }, fields.map(__classPrivateFieldGet(this, _GxIdeDbPropertiesConfigurator_renderField, "f"))))));
115
+ this.properties = [];
116
+ this.cancelCallback = undefined;
117
+ this.confirmCallback = undefined;
118
+ this.propertyChangeCallback = undefined;
119
+ }
120
+ async componentWillLoad() {
121
+ __classPrivateFieldSet(this, _GxIdeDbPropertiesConfigurator_componentLocale, await Locale.getComponentStrings(this.el), "f");
122
+ }
123
+ // #endregion Renders
124
+ render() {
125
+ var _a;
126
+ const title = __classPrivateFieldGet(this, _GxIdeDbPropertiesConfigurator_componentLocale, "f").header.title;
127
+ const description = __classPrivateFieldGet(this, _GxIdeDbPropertiesConfigurator_componentLocale, "f").header.description;
128
+ const sections = __classPrivateFieldGet(this, _GxIdeDbPropertiesConfigurator_componentLocale, "f").sections;
129
+ const allFields = (_a = this.properties) !== null && _a !== void 0 ? _a : [];
130
+ const hasAuthSection = __classPrivateFieldGet(this, _GxIdeDbPropertiesConfigurator_hasTrustedConnection, "f").call(this);
131
+ // The Authentication section is only rendered when TRUSTED_CONNECTION is
132
+ // present; otherwise every field stays in the always-present Connection
133
+ // section so nothing is dropped.
134
+ const authFields = hasAuthSection
135
+ ? allFields.filter(__classPrivateFieldGet(this, _GxIdeDbPropertiesConfigurator_isAuthField, "f"))
136
+ : [];
137
+ const connectionFields = hasAuthSection
138
+ ? allFields.filter(field => !__classPrivateFieldGet(this, _GxIdeDbPropertiesConfigurator_isAuthField, "f").call(this, field))
139
+ : allFields;
140
+ return (h(Host, { class: "widget" }, h("ch-theme", { model: CSS_BUNDLES }), h("section", { class: "section" }, h("div", { class: "hero" }, h("div", { class: "hero__text" }, h("h1", { class: "hero__title subtitle-semi-bold-l" }, title), description && (h("p", { class: "hero__description body-regular-s" }, description))), h("div", { class: "hero__badge", "aria-hidden": "true" }, h("ch-image", { class: "icon-xl", src: DATABASE_ICON }))), h("div", { class: "main scrollable" }, connectionFields.length > 0 &&
141
+ __classPrivateFieldGet(this, _GxIdeDbPropertiesConfigurator_renderSection, "f").call(this, sections.connection, connectionFields), hasAuthSection &&
142
+ authFields.length > 0 &&
143
+ __classPrivateFieldGet(this, _GxIdeDbPropertiesConfigurator_renderSection, "f").call(this, sections.authentication, authFields)), h("footer", { class: "dialog-footer-with-border footer" }, h("div", { class: "buttons-spacer" }, h("button", { class: "button-secondary", id: "button-cancel", type: "button", onClick: __classPrivateFieldGet(this, _GxIdeDbPropertiesConfigurator_cancelButtonClickedHandler, "f"), part: "button-cancel" }, __classPrivateFieldGet(this, _GxIdeDbPropertiesConfigurator_componentLocale, "f").footer.btnCancel), h("button", { class: "button-primary", id: "button-confirm", type: "button", disabled: __classPrivateFieldGet(this, _GxIdeDbPropertiesConfigurator_hasPendingRequired, "f").call(this), onClick: __classPrivateFieldGet(this, _GxIdeDbPropertiesConfigurator_confirmButtonClickedHandler, "f"), part: "button-confirm" }, __classPrivateFieldGet(this, _GxIdeDbPropertiesConfigurator_componentLocale, "f").footer.btnConfirm))))));
144
+ }
145
+ static get is() { return "gx-ide-db-properties-configurator"; }
146
+ static get encapsulation() { return "shadow"; }
147
+ static get originalStyleUrls() {
148
+ return {
149
+ "$": ["db-properties-configurator.scss"]
150
+ };
151
+ }
152
+ static get styleUrls() {
153
+ return {
154
+ "$": ["db-properties-configurator.css"]
155
+ };
156
+ }
157
+ static get assetsDirs() { return ["gx-ide-assets/db-properties-configurator"]; }
158
+ static get properties() {
159
+ return {
160
+ "properties": {
161
+ "type": "unknown",
162
+ "mutable": false,
163
+ "complexType": {
164
+ "original": "DSPropertyField[]",
165
+ "resolved": "DSPropertyField[]",
166
+ "references": {
167
+ "DSPropertyField": {
168
+ "location": "local",
169
+ "path": "/home/runner/work/genexus-ide-ui/genexus-ide-ui/src/components/db-properties-configurator/db-properties-configurator.tsx",
170
+ "id": "src/components/db-properties-configurator/db-properties-configurator.tsx::DSPropertyField"
171
+ }
172
+ }
173
+ },
174
+ "required": false,
175
+ "optional": false,
176
+ "docs": {
177
+ "tags": [],
178
+ "text": "The list of properties to configure. Acts as the single source of truth:\nthe dialog reads each value from `DSPropertyField.value` and notifies the\nhost of every edit through `propertyChangeCallback`."
179
+ },
180
+ "defaultValue": "[]"
181
+ },
182
+ "cancelCallback": {
183
+ "type": "unknown",
184
+ "mutable": false,
185
+ "complexType": {
186
+ "original": "CancelCallback",
187
+ "resolved": "() => void | Promise<void>",
188
+ "references": {
189
+ "CancelCallback": {
190
+ "location": "local",
191
+ "path": "/home/runner/work/genexus-ide-ui/genexus-ide-ui/src/components/db-properties-configurator/db-properties-configurator.tsx",
192
+ "id": "src/components/db-properties-configurator/db-properties-configurator.tsx::CancelCallback"
193
+ }
194
+ }
195
+ },
196
+ "required": true,
197
+ "optional": false,
198
+ "docs": {
199
+ "tags": [],
200
+ "text": "Callback invoked when the user cancels the configuration."
201
+ }
202
+ },
203
+ "confirmCallback": {
204
+ "type": "unknown",
205
+ "mutable": false,
206
+ "complexType": {
207
+ "original": "ConfirmCallback",
208
+ "resolved": "() => void | Promise<void>",
209
+ "references": {
210
+ "ConfirmCallback": {
211
+ "location": "local",
212
+ "path": "/home/runner/work/genexus-ide-ui/genexus-ide-ui/src/components/db-properties-configurator/db-properties-configurator.tsx",
213
+ "id": "src/components/db-properties-configurator/db-properties-configurator.tsx::ConfirmCallback"
214
+ }
215
+ }
216
+ },
217
+ "required": true,
218
+ "optional": false,
219
+ "docs": {
220
+ "tags": [],
221
+ "text": "Callback invoked when the user confirms the configuration."
222
+ }
223
+ },
224
+ "propertyChangeCallback": {
225
+ "type": "unknown",
226
+ "mutable": false,
227
+ "complexType": {
228
+ "original": "PropertyChangeCallback",
229
+ "resolved": "(name: string, value: string) => void | Promise<void>",
230
+ "references": {
231
+ "PropertyChangeCallback": {
232
+ "location": "local",
233
+ "path": "/home/runner/work/genexus-ide-ui/genexus-ide-ui/src/components/db-properties-configurator/db-properties-configurator.tsx",
234
+ "id": "src/components/db-properties-configurator/db-properties-configurator.tsx::PropertyChangeCallback"
235
+ }
236
+ }
237
+ },
238
+ "required": true,
239
+ "optional": false,
240
+ "docs": {
241
+ "tags": [],
242
+ "text": "Callback invoked on every input change. Receives the name of the\nproperty that changed and its new value. The host is expected to apply\nthe change and push an updated `properties` array back to the component."
243
+ }
244
+ }
245
+ };
246
+ }
247
+ static get elementRef() { return "el"; }
248
+ }
249
+ _GxIdeDbPropertiesConfigurator_componentLocale = new WeakMap(), _GxIdeDbPropertiesConfigurator_getValue = new WeakMap(), _GxIdeDbPropertiesConfigurator_hasPendingRequired = new WeakMap(), _GxIdeDbPropertiesConfigurator_buildComboModel = new WeakMap(), _GxIdeDbPropertiesConfigurator_isAuthField = new WeakMap(), _GxIdeDbPropertiesConfigurator_hasTrustedConnection = new WeakMap(), _GxIdeDbPropertiesConfigurator_valueChangeHandler = new WeakMap(), _GxIdeDbPropertiesConfigurator_cancelButtonClickedHandler = new WeakMap(), _GxIdeDbPropertiesConfigurator_confirmButtonClickedHandler = new WeakMap(), _GxIdeDbPropertiesConfigurator_renderControl = new WeakMap(), _GxIdeDbPropertiesConfigurator_renderField = new WeakMap(), _GxIdeDbPropertiesConfigurator_renderSection = new WeakMap();
250
+ //# sourceMappingURL=db-properties-configurator.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"db-properties-configurator.js","sourceRoot":"","sources":["../../../src/components/db-properties-configurator/db-properties-configurator.tsx"],"names":[],"mappings":";;;;;;;;;;;;AAAA,OAAO,EAAE,SAAS,EAAE,IAAI,EAAE,IAAI,EAAE,OAAO,EAAE,CAAC,EAAE,MAAM,eAAe,CAAC;AAElE,OAAO,EAAkB,WAAW,EAAE,MAAM,kBAAkB,CAAC;AAG/D,OAAO,EAAE,MAAM,EAAE,MAAM,qBAAqB,CAAC;AAC7C,OAAO,EAAE,MAAM,EAAE,M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,EACb,OAAO,EAAE,uBAAA,IAAI,iEAA4B,EACzC,IAAI,EAAC,eAAe,IAEnB,uBAAA,IAAI,sDAAiB,CAAC,MAAM,CAAC,SAAS,CAChC;wBACT,cACE,KAAK,EAAC,gBAAgB,EACtB,EAAE,EAAC,gBAAgB,EACnB,IAAI,EAAC,QAAQ,EACb,QAAQ,EAAE,uBAAA,IAAI,yDAAoB,MAAxB,IAAI,CAAsB,EACpC,OAAO,EAAE,uBAAA,IAAI,kEAA6B,EAC1C,IAAI,EAAC,gBAAgB,IAEpB,uBAAA,IAAI,sDAAiB,CAAC,MAAM,CAAC,UAAU,CACjC,CACL,CACC,CACD,CACL,CACR,CAAC;IACJ,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["import { Component, Host, Prop, Element, h } from \"@stencil/core\";\n\nimport { MercuryBundles, getIconPath } from \"@genexus/mercury\";\nimport { ComboBoxModel } from \"@genexus/chameleon-controls-library\";\n\nimport { Locale } from \"../../common/locale\";\nimport { config } from \"../../common/config\";\n\nconst CSS_BUNDLES: MercuryBundles = [\n \"resets/box-sizing\",\n \"components/button\",\n \"components/combo-box\",\n \"components/edit\",\n \"components/icon\",\n \"utils/form\",\n \"utils/layout\",\n \"utils/typography\",\n \"utils/spacing\",\n \"chameleon/scrollbar\"\n];\n\nconst DATABASE_ICON = getIconPath({\n category: \"system\",\n name: \"database\",\n colorType: \"primary\"\n});\n\n/**\n * Name of the property that toggles integrated security. Its presence in\n * `properties` is what drives the rendering of the Authentication section.\n */\nconst TRUSTED_CONNECTION = \"TRUSTED_CONNECTION\";\nconst USER_ID = \"USER_ID\";\nconst USER_PASSWORD = \"USER_PASSWORD\";\n\n/** Category that groups the authentication-related fields. */\nconst AUTH_CATEGORY = \"authentication\";\n\n@Component({\n tag: \"gx-ide-db-properties-configurator\",\n styleUrl: \"db-properties-configurator.scss\",\n shadow: true,\n assetsDirs: [\"gx-ide-assets/db-properties-configurator\"]\n})\nexport class GxIdeDbPropertiesConfigurator {\n // eslint-disable-next-line @stencil-community/own-props-must-be-private\n #componentLocale: any;\n\n @Element() el: HTMLGxIdeDbPropertiesConfiguratorElement;\n\n /**\n * The list of properties to configure. Acts as the single source of truth:\n * the dialog reads each value from `DSPropertyField.value` and notifies the\n * host of every edit through `propertyChangeCallback`.\n */\n @Prop() readonly properties: DSPropertyField[] = [];\n\n /**\n * Callback invoked when the user cancels the configuration.\n */\n @Prop() readonly cancelCallback!: CancelCallback;\n\n /**\n * Callback invoked when the user confirms the configuration.\n */\n @Prop() readonly confirmCallback!: ConfirmCallback;\n\n /**\n * Callback invoked on every input change. Receives the name of the\n * property that changed and its new value. The host is expected to apply\n * the change and push an updated `properties` array back to the component.\n */\n @Prop() readonly propertyChangeCallback!: PropertyChangeCallback;\n\n async componentWillLoad() {\n this.#componentLocale = await Locale.getComponentStrings(this.el);\n }\n\n #getValue = (field: DSPropertyField): string => field.value ?? \"\";\n\n #hasPendingRequired = (): boolean =>\n (this.properties ?? []).some(\n field => field.missing && this.#getValue(field).trim() === \"\"\n );\n\n #buildComboModel = (field: DSPropertyField): ComboBoxModel =>\n (field.standardValues ?? []).map(value => ({ value, caption: value }));\n\n #isAuthField = (field: DSPropertyField): boolean =>\n field.name === TRUSTED_CONNECTION ||\n field.name === USER_ID ||\n field.name === USER_PASSWORD ||\n field.category?.toLowerCase() === AUTH_CATEGORY;\n\n /** Whether the host sent the TRUSTED_CONNECTION property. Only then is the\n * Authentication section rendered. */\n #hasTrustedConnection = (): boolean =>\n (this.properties ?? []).some(field => field.name === TRUSTED_CONNECTION);\n\n #valueChangeHandler =\n (name: string) => (event: CustomEvent<string> | InputEvent) => {\n const detail = (event as CustomEvent<string>).detail;\n const value =\n typeof detail === \"string\"\n ? detail\n : ((event.target as HTMLChEditElement)?.value ?? \"\");\n this.propertyChangeCallback(name, value);\n };\n\n #cancelButtonClickedHandler = () => {\n this.cancelCallback?.();\n };\n\n #confirmButtonClickedHandler = () => {\n this.confirmCallback?.();\n };\n\n // #region Renders\n\n #renderControl = (field: DSPropertyField) => {\n const fieldId = `field-${field.name}`;\n const value = this.#getValue(field);\n\n switch (field.control) {\n case \"password\":\n return (\n <ch-edit\n id={fieldId}\n class=\"input\"\n type=\"password\"\n showPasswordButton\n debounce={config.inputDebounce}\n value={value}\n onInput={this.#valueChangeHandler(field.name)}\n ></ch-edit>\n );\n\n case \"combo\":\n return (\n <ch-combo-box-render\n id={fieldId}\n class=\"combo-box\"\n value={value}\n model={this.#buildComboModel(field)}\n onInput={this.#valueChangeHandler(field.name)}\n onChange={this.#valueChangeHandler(field.name)}\n ></ch-combo-box-render>\n );\n\n case \"checkbox\":\n return (\n <ch-checkbox\n id={fieldId}\n class=\"checkbox\"\n value={value}\n checkedValue=\"Yes\"\n unCheckedValue=\"No\"\n onInput={this.#valueChangeHandler(field.name)}\n ></ch-checkbox>\n );\n\n case \"combo-editable\":\n return (\n <ch-combo-box-render\n id={fieldId}\n class=\"combo-box\"\n suggest\n suggestDebounce={config.inputDebounce}\n value={value}\n model={this.#buildComboModel(field)}\n onInput={this.#valueChangeHandler(field.name)}\n onChange={this.#valueChangeHandler(field.name)}\n part={`combo-box combo-box--editable combo-box--${field.name}`}\n ></ch-combo-box-render>\n );\n\n case \"custom\":\n case \"readonly\":\n return (\n <ch-edit\n id={fieldId}\n class=\"input\"\n readonly\n value={value}\n part={`input input--${field.control} input--${field.name}`}\n ></ch-edit>\n );\n\n // \"text\"\n default:\n return (\n <ch-edit\n id={fieldId}\n class=\"input\"\n debounce={config.inputDebounce}\n value={value}\n onInput={this.#valueChangeHandler(field.name)}\n part={`input input--text input--${field.name}`}\n ></ch-edit>\n );\n }\n };\n\n #renderField = (field: DSPropertyField) => {\n const fieldId = `field-${field.name}`;\n const isReadonly =\n field.control === \"readonly\" || field.control === \"custom\";\n const isCheckbox = field.control === \"checkbox\";\n\n if (isCheckbox) {\n return (\n <div class=\"field field--checkbox field--full\" key={field.name}>\n <div class=\"field__row\">\n {this.#renderControl(field)}\n <label class=\"label\" htmlFor={fieldId}>\n {field.label}\n </label>\n </div>\n {field.description && (\n <p class=\"field__hint body-regular-s\">{field.description}</p>\n )}\n </div>\n );\n }\n\n return (\n <div class=\"field field-block\" key={field.name}>\n <label\n class={{ \"label\": true, \"label--disabled\": isReadonly }}\n htmlFor={fieldId}\n >\n {field.label}\n </label>\n\n {this.#renderControl(field)}\n </div>\n );\n };\n\n #renderSection = (title: string, fields: DSPropertyField[]) => (\n <section class=\"field-section\">\n <div class=\"field-section__head\">\n <span class=\"field-section__title\">{title}</span>\n </div>\n <div class=\"fields\">{fields.map(this.#renderField)}</div>\n </section>\n );\n\n // #endregion Renders\n\n render() {\n const title = this.#componentLocale.header.title;\n const description = this.#componentLocale.header.description;\n const sections = this.#componentLocale.sections;\n\n const allFields = this.properties ?? [];\n const hasAuthSection = this.#hasTrustedConnection();\n\n // The Authentication section is only rendered when TRUSTED_CONNECTION is\n // present; otherwise every field stays in the always-present Connection\n // section so nothing is dropped.\n const authFields = hasAuthSection\n ? allFields.filter(this.#isAuthField)\n : [];\n const connectionFields = hasAuthSection\n ? allFields.filter(field => !this.#isAuthField(field))\n : allFields;\n\n return (\n <Host class=\"widget\">\n <ch-theme model={CSS_BUNDLES}></ch-theme>\n <section class=\"section\">\n <div class=\"hero\">\n <div class=\"hero__text\">\n <h1 class=\"hero__title subtitle-semi-bold-l\">{title}</h1>\n {description && (\n <p class=\"hero__description body-regular-s\">{description}</p>\n )}\n </div>\n <div class=\"hero__badge\" aria-hidden=\"true\">\n <ch-image class=\"icon-xl\" src={DATABASE_ICON}></ch-image>\n </div>\n </div>\n\n <div class=\"main scrollable\">\n {connectionFields.length > 0 &&\n this.#renderSection(sections.connection, connectionFields)}\n\n {hasAuthSection &&\n authFields.length > 0 &&\n this.#renderSection(sections.authentication, authFields)}\n </div>\n\n <footer class=\"dialog-footer-with-border footer\">\n <div class=\"buttons-spacer\">\n <button\n class=\"button-secondary\"\n id=\"button-cancel\"\n type=\"button\"\n onClick={this.#cancelButtonClickedHandler}\n part=\"button-cancel\"\n >\n {this.#componentLocale.footer.btnCancel}\n </button>\n <button\n class=\"button-primary\"\n id=\"button-confirm\"\n type=\"button\"\n disabled={this.#hasPendingRequired()}\n onClick={this.#confirmButtonClickedHandler}\n part=\"button-confirm\"\n >\n {this.#componentLocale.footer.btnConfirm}\n </button>\n </div>\n </footer>\n </section>\n </Host>\n );\n }\n}\n\nexport type DSControlKind =\n | \"checkbox\"\n | \"text\"\n | \"password\"\n | \"combo\"\n | \"combo-editable\"\n | \"custom\"\n | \"readonly\";\n\nexport interface DSPropertyField {\n /** `PropertyData.name` — key used to set the property value. */\n name: string;\n /** `definition.displayName`. */\n label: string;\n /** `definition.description` (rendered below the control). */\n description?: string;\n /** `definition.category` (optional grouping). */\n category?: string;\n\n /** Control resolved by the host. */\n control: DSControlKind;\n\n /** `PropertyData.value` (masked when password). */\n value: string;\n /** `required && isDefault` (host detection). */\n missing: boolean;\n\n // combos:\n /** `PropertyData.standardValues`. */\n standardValues?: string[];\n /** `PropertyData.isStandardValuesExclusive`. */\n exclusive?: boolean;\n}\n\nexport type CancelCallback = () => void | Promise<void>;\n\nexport type ConfirmCallback = () => void | Promise<void>;\n\nexport type PropertyChangeCallback = (\n name: string,\n value: string\n) => void | Promise<void>;\n"]}
@@ -0,0 +1,24 @@
1
+ {
2
+ "componentName": "DB Properties Configurator",
3
+ "header": {
4
+ "caption": "Database connection",
5
+ "title": "Set required properties",
6
+ "description": "The following properties must be set to start the Build process. Fill them with the appropriate values for your database instance.",
7
+ "close": "Close"
8
+ },
9
+ "sections": {
10
+ "connection": "Connection",
11
+ "authentication": "Authentication"
12
+ },
13
+ "fields": {
14
+ "required": "Required",
15
+ "requiredMarker": "*",
16
+ "openEditor": "Open editor",
17
+ "editorEllipsis": "…",
18
+ "uncategorized": "General"
19
+ },
20
+ "footer": {
21
+ "btnCancel": "Cancel",
22
+ "btnConfirm": "Confirm"
23
+ }
24
+ }
@@ -0,0 +1,24 @@
1
+ {
2
+ "componentName": "DB プロパティ構成",
3
+ "header": {
4
+ "caption": "データベース接続",
5
+ "title": "必須プロパティの設定",
6
+ "description": "ビルドプロセスを開始するには、以下のプロパティを設定する必要があります。データベースインスタンスに適した値を入力してください。",
7
+ "close": "閉じる"
8
+ },
9
+ "sections": {
10
+ "connection": "接続",
11
+ "authentication": "認証"
12
+ },
13
+ "fields": {
14
+ "required": "必須",
15
+ "requiredMarker": "*",
16
+ "openEditor": "エディターを開く",
17
+ "editorEllipsis": "…",
18
+ "uncategorized": "全般"
19
+ },
20
+ "footer": {
21
+ "btnCancel": "キャンセル",
22
+ "btnConfirm": "確認"
23
+ }
24
+ }
@@ -0,0 +1,24 @@
1
+ {
2
+ "componentName": "数据库属性配置器",
3
+ "header": {
4
+ "caption": "数据库连接",
5
+ "title": "设置必填属性",
6
+ "description": "必须设置以下属性才能开始构建过程。请为您的数据库实例填写适当的值。",
7
+ "close": "关闭"
8
+ },
9
+ "sections": {
10
+ "connection": "连接",
11
+ "authentication": "身份验证"
12
+ },
13
+ "fields": {
14
+ "required": "必填",
15
+ "requiredMarker": "*",
16
+ "openEditor": "打开编辑器",
17
+ "editorEllipsis": "…",
18
+ "uncategorized": "常规"
19
+ },
20
+ "footer": {
21
+ "btnCancel": "取消",
22
+ "btnConfirm": "确认"
23
+ }
24
+ }
@@ -0,0 +1,18 @@
1
+ {
2
+ "team": {
3
+ "title": "Change your team",
4
+ "infoMessage": "Select new team from the list below",
5
+ "label": "Teams"
6
+ },
7
+ "organization": {
8
+ "title": "Change your organization",
9
+ "infoMessage": "Select new organization from the list below",
10
+ "label": "Organizations"
11
+ },
12
+ "confirmButtonCaption": "Confirm",
13
+ "cancelButtonCaption": "Cancel",
14
+ "loader": {
15
+ "title": "Fetching user data",
16
+ "description": "Thanks for your patience!"
17
+ }
18
+ }
@@ -0,0 +1,18 @@
1
+ {
2
+ "team": {
3
+ "title": "チームを変更",
4
+ "infoMessage": "下のリストから新しいチームを選択してください",
5
+ "label": "チーム"
6
+ },
7
+ "organization": {
8
+ "title": "組織を変更",
9
+ "infoMessage": "下のリストから新しい組織を選択してください",
10
+ "label": "組織"
11
+ },
12
+ "confirmButtonCaption": "確認",
13
+ "cancelButtonCaption": "キャンセル",
14
+ "loader": {
15
+ "title": "ユーザーデータを取得中",
16
+ "description": "しばらくお待ちください"
17
+ }
18
+ }
@@ -0,0 +1,18 @@
1
+ {
2
+ "team": {
3
+ "title": "Change your team",
4
+ "infoMessage": "Select new team from the list below",
5
+ "label": "Teams"
6
+ },
7
+ "organization": {
8
+ "title": "Change your organization",
9
+ "infoMessage": "Select new organization from the list below",
10
+ "label": "Organizations"
11
+ },
12
+ "confirmButtonCaption": "Confirm",
13
+ "cancelButtonCaption": "Cancel",
14
+ "loader": {
15
+ "title": "Fetching user data",
16
+ "description": "Thanks for your patience!"
17
+ }
18
+ }
@@ -0,0 +1,9 @@
1
+ export const mapItemsToComboBoxItemModel = (items) => {
2
+ return items === null || items === void 0 ? void 0 : items.map(item => {
3
+ return {
4
+ value: item.id,
5
+ caption: item.name
6
+ };
7
+ });
8
+ };
9
+ //# sourceMappingURL=helpers.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"helpers.js","sourceRoot":"","sources":["../../../src/components/select-team-or-org/helpers.tsx"],"names":[],"mappings":"AAGA,MAAM,CAAC,MAAM,2BAA2B,GAAG,CACzC,KAAuB,EACF,EAAE;IACvB,OAAO,KAAK,aAAL,KAAK,uBAAL,KAAK,CAAE,GAAG,CAAC,IAAI,CAAC,EAAE;QACvB,OAAO;YACL,KAAK,EAAE,IAAI,CAAC,EAAE;YACd,OAAO,EAAE,IAAI,CAAC,IAAI;SACnB,CAAC;IACJ,CAAC,CAAC,CAAC;AACL,CAAC,CAAC","sourcesContent":["import { ComboBoxItemModel } from \"@genexus/chameleon-controls-library/dist/types/components/combo-box/types\";\nimport { SelectableItem } from \"./select-team-or-org\";\n\nexport const mapItemsToComboBoxItemModel = (\n items: SelectableItem[]\n): ComboBoxItemModel[] => {\n return items?.map(item => {\n return {\n value: item.id,\n caption: item.name\n };\n });\n};\n"]}
@@ -16,6 +16,7 @@ button.button-secondary {
16
16
  display: grid;
17
17
  grid-template-columns: 1fr 1fr;
18
18
  block-size: 100%;
19
+ border-radius: var(--border-radius-m);
19
20
  max-block-size: 700px;
20
21
  max-inline-size: 1100px;
21
22
  background-color: var(--color-accent-surface-elevation-1);
@@ -34,7 +35,7 @@ button.button-secondary {
34
35
  inline-size: 100%;
35
36
  padding: 48px;
36
37
  transform: translateY(4px);
37
- transition: var(--display-teams-transtion-time) all;
38
+ transition: var(--display-items-transtion-time) all;
38
39
  opacity: 0;
39
40
  position: relative;
40
41
  }
@@ -46,6 +47,7 @@ button.button-secondary {
46
47
  display: grid;
47
48
  place-self: center;
48
49
  gap: var(--spacing-gap-xxl);
50
+ inline-size: 100%;
49
51
  max-inline-size: 480px;
50
52
  }
51
53
  .slide__main-header {
@@ -58,6 +60,7 @@ button.button-secondary {
58
60
  font-size: var(--font-size-header-h2);
59
61
  font-weight: var(--font-style-semi-bold);
60
62
  letter-spacing: 0.02em;
63
+ line-height: var(--line-height-tight);
61
64
  color: var(--color-text-neutral-strawberry);
62
65
  }
63
66
  .slide__main-description {
@@ -73,14 +76,14 @@ button.button-secondary {
73
76
  text-decoration: underline;
74
77
  }
75
78
 
76
- .teams-list {
79
+ .items-list {
77
80
  inline-size: 100%;
78
- max-inline-size: 400px;
79
- --ch-combo-box__popover-max-inline-size: 400px;
81
+ --ch-combo-box__popover-max-inline-size: 100%;
80
82
  }
81
83
 
82
84
  .buttons-container {
83
85
  display: flex;
86
+ inline-size: 100%;
84
87
  gap: var(--spacing-gap-xl);
85
88
  }
86
89