@genexus/genexus-ide-ui 3.2.7 → 3.2.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/genexus-ide-ui.cjs.js +1 -1
- package/dist/cjs/gx-ide-mcp-server.cjs.entry.js +167 -0
- package/dist/cjs/gx-ide-mcp-server.cjs.entry.js.map +1 -0
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/collection/collection-manifest.json +1 -0
- package/dist/collection/components/mcp-server/gx-ide-assets/mcp-server/langs/mcp-server.lang.en.json +36 -0
- package/dist/collection/components/mcp-server/gx-ide-assets/mcp-server/langs/mcp-server.lang.ja.json +36 -0
- package/dist/collection/components/mcp-server/gx-ide-assets/mcp-server/langs/mcp-server.lang.zh.json +36 -0
- package/dist/collection/components/mcp-server/gx-ide-assets/mcp-server/shortcuts.json +15 -0
- package/dist/collection/components/mcp-server/mcp-server.css +128 -0
- package/dist/collection/components/mcp-server/mcp-server.js +358 -0
- package/dist/collection/components/mcp-server/mcp-server.js.map +1 -0
- package/dist/collection/components/mcp-server/tests/mcp-server.e2e.js +83 -0
- package/dist/collection/components/mcp-server/tests/mcp-server.e2e.js.map +1 -0
- package/dist/collection/components/mcp-server/types.js +2 -0
- package/dist/collection/components/mcp-server/types.js.map +1 -0
- package/dist/collection/testing/locale.e2e.js +1 -0
- package/dist/collection/testing/locale.e2e.js.map +1 -1
- package/dist/components/gx-ide-mcp-server.d.ts +11 -0
- package/dist/components/gx-ide-mcp-server.js +199 -0
- package/dist/components/gx-ide-mcp-server.js.map +1 -0
- package/dist/esm/genexus-ide-ui.js +1 -1
- package/dist/esm/gx-ide-mcp-server.entry.js +163 -0
- package/dist/esm/gx-ide-mcp-server.entry.js.map +1 -0
- package/dist/esm/loader.js +1 -1
- package/dist/genexus-ide-ui/genexus-ide-ui.esm.js +1 -1
- package/dist/genexus-ide-ui/genexus-ide-ui.esm.js.map +1 -1
- package/dist/genexus-ide-ui/gx-ide-assets/mcp-server/langs/mcp-server.lang.en.json +36 -0
- package/dist/genexus-ide-ui/gx-ide-assets/mcp-server/langs/mcp-server.lang.ja.json +36 -0
- package/dist/genexus-ide-ui/gx-ide-assets/mcp-server/langs/mcp-server.lang.zh.json +36 -0
- package/dist/genexus-ide-ui/gx-ide-assets/mcp-server/shortcuts.json +15 -0
- package/dist/genexus-ide-ui/p-a456237f.entry.js +239 -0
- package/dist/genexus-ide-ui/p-a456237f.entry.js.map +1 -0
- package/dist/types/components/mcp-server/mcp-server.d.ts +55 -0
- package/dist/types/components/mcp-server/types.d.ts +9 -0
- package/dist/types/components.d.ts +93 -8
- package/package.json +1 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["mcpServerCss","CSS_BUNDLES","COPY_ICON","getIconPath","category","name","colorType","GxIdeMcpServer","_GxIdeMcpServer_componentLocale","set","this","_GxIdeMcpServer_chShortcutsEl","_GxIdeMcpServer_shortcutsSrc","getAssetPath","_GxIdeMcpServer_startHandler","async","errorMessage","undefined","actionInProgress","result","startCallback","success","_a","__classPrivateFieldGet","errors","startFailed","_b","_GxIdeMcpServer_stopHandler","stopCallback","stopFailed","_GxIdeMcpServer_closeHandler","closeCallback","call","_GxIdeMcpServer_copyEndpointHandler","serverEndpoint","copyCallback","copying","setTimeout","componentWillLoad","__classPrivateFieldSet","Locale","getComponentStrings","el","suspendShortcuts","suspend","render","h","Host","class","model","src","ref","header","title","initialLoading","_GxIdeMcpServer_instances","_GxIdeMcpServer_renderStatusBadge","loaderTitle","loader","show","info","description","details","_GxIdeMcpServer_renderStatusCard","_GxIdeMcpServer_renderError","type","onClick","part","buttons","close","_GxIdeMcpServer_renderPrimaryButton","statusText","status","badgeClass","isAnimated","isDimmed","statusCard","statusLabel","serverPort","portLabel","endpointLabel","disabled","copyEndpoint","copiedEndpoint","isRunning","isTransitioning","isDisabled","stop","start"],"sources":["src/components/mcp-server/mcp-server.scss?tag=gx-ide-mcp-server&encapsulation=shadow","src/components/mcp-server/mcp-server.tsx"],"sourcesContent":["@import \"../../global/temporary-mercury-overrides/_button.scss\";\n\n:host {\n display: grid;\n inline-size: 100%;\n block-size: 100%;\n min-inline-size: 480px;\n min-block-size: 320px;\n overflow: auto;\n grid-template-rows: max-content 1fr max-content;\n}\n\n.section {\n display: contents;\n}\n\n.header {\n display: flex;\n align-items: center;\n justify-content: space-between;\n}\n\n.title {\n margin: 0;\n}\n\n.main {\n overflow: auto;\n display: flex;\n flex-direction: column;\n gap: var(--spacing-gap-xl);\n padding-block: var(--spacing-padding-l);\n}\n\n\n.info-section {\n display: flex;\n flex-direction: column;\n gap: var(--spacing-gap-m);\n color: var(--color-text-neutral-default);\n}\n\n.status-badge {\n display: inline-flex;\n align-items: center;\n gap: var(--spacing-gap-xs);\n}\n\n.status-dot {\n $dot-size: 8px;\n\n display: inline-block;\n inline-size: $dot-size;\n block-size: $dot-size;\n border-radius: 50%;\n background-color: var(--color-text-neutral-disabled);\n flex-shrink: 0;\n\n .status-badge--running & {\n background-color: var(--color-text-success-default, #22c55e);\n }\n\n .status-badge--error & {\n background-color: var(--color-text-error-default, #ef4444);\n }\n\n .status-badge--starting &,\n .status-badge--stopping & {\n background-color: var(--color-text-warning-default, #f59e0b);\n }\n\n &--animated {\n animation: pulse 1.2s ease-in-out infinite;\n }\n}\n\n@keyframes pulse {\n 0%,\n 100% {\n opacity: 1;\n }\n\n 50% {\n opacity: 0.3;\n }\n}\n\n.status-card {\n border: 1px solid var(--color-border-surface-on-elevation-1);\n border-radius: 4px;\n padding: var(--spacing-gap-l);\n display: flex;\n flex-direction: column;\n gap: var(--spacing-gap-m);\n\n &--dimmed {\n opacity: 0.5;\n }\n\n &__row {\n display: flex;\n align-items: flex-start;\n gap: var(--spacing-gap-l);\n\n > :first-child {\n min-inline-size: 80px;\n flex-shrink: 0;\n }\n }\n\n &__endpoint {\n display: flex;\n align-items: flex-start;\n gap: var(--spacing-gap-m);\n flex-wrap: wrap;\n\n > .button-icon-only {\n padding: 0;\n block-size: auto;\n }\n }\n}\n\n.endpoint-value {\n word-break: break-all;\n color: var(--color-text-neutral-default);\n}\n\n.loader {\n display: flex;\n align-items: center;\n justify-content: center;\n flex: 1;\n}\n\n.error-message {\n color: var(--color-text-error-default, #ef4444);\n padding: var(--spacing-gap-m);\n border: 1px solid var(--color-border-error-default, #ef4444);\n border-radius: 4px;\n background-color: var(--color-surface-error-default, rgba(239, 68, 68, 0.08));\n}\n\n","import {\n Component,\n Host,\n h,\n Prop,\n State,\n Element,\n getAssetPath,\n Method\n} from \"@stencil/core\";\n\nimport { MercuryBundles, getIconPath } from \"@genexus/mercury\";\n\nimport { Locale } from \"../../common/locale\";\nimport {\n McpServerStatus,\n McpStartResult,\n McpStopResult\n} from \"./types\";\n\nconst CSS_BUNDLES: MercuryBundles = [\n \"resets/box-sizing\",\n \"components/button\",\n \"components/icon\",\n \"utils/layout\",\n \"utils/typography\",\n \"utils/elevation\",\n \"utils/spacing\",\n \"chameleon/scrollbar\"\n];\n\nconst COPY_ICON = getIconPath({\n category: \"system\",\n name: \"copy\",\n colorType: \"primary\"\n});\n\n\n@Component({\n tag: \"gx-ide-mcp-server\",\n styleUrl: \"mcp-server.scss\",\n shadow: true,\n assetsDirs: [\"gx-ide-assets/mcp-server\"]\n})\nexport class GxIdeMcpServer {\n // eslint-disable-next-line @stencil-community/own-props-must-be-private\n #componentLocale: any;\n #chShortcutsEl: HTMLChShortcutsElement;\n #shortcutsSrc = getAssetPath(\n `./gx-ide-assets/mcp-server/shortcuts.json`\n );\n\n @Element() el: HTMLGxIdeMcpServerElement;\n\n @State() actionInProgress: boolean = false;\n @State() errorMessage: string | undefined;\n @State() copying: boolean = false;\n\n /**\n * When `true` the component shows a loader instead of content.\n * The host sets this to `false` once the initial status is known.\n */\n @Prop({ mutable: true }) initialLoading: boolean = true;\n\n /**\n * Current MCP server status. The host is responsible for keeping\n * this prop up to date (e.g. via polling or event-driven updates).\n * The component only mutates it internally during start/stop\n * transitions (`starting`, `stopping`, result states).\n */\n @Prop({ mutable: true }) status!: McpServerStatus;\n\n /**\n * Port the MCP server is listening on (shown when running).\n */\n @Prop({ mutable: true }) serverPort: number | undefined;\n\n /**\n * Full endpoint URL (shown when running).\n */\n @Prop({ mutable: true }) serverEndpoint: string | undefined;\n\n /**\n * Callback to start the MCP server. Returns result with connection info.\n */\n @Prop() readonly startCallback!: StartCallback;\n\n /**\n * Callback to stop the MCP server.\n */\n @Prop() readonly stopCallback!: StopCallback;\n\n /**\n * Callback to copy text to the clipboard. Delegated to the IDE clipboard\n * service so the host environment controls the copy behavior.\n */\n @Prop() readonly copyCallback!: CopyCallback;\n\n /**\n * Callback to close/dismiss the dialog.\n */\n @Prop() readonly closeCallback!: CloseCallback;\n\n async componentWillLoad() {\n this.#componentLocale = await Locale.getComponentStrings(this.el);\n }\n\n /**\n * Suspends or reactivates the shortcuts.\n */\n @Method()\n async suspendShortcuts(suspendShortcuts: boolean) {\n this.#chShortcutsEl.suspend = suspendShortcuts;\n }\n\n #startHandler = async () => {\n this.errorMessage = undefined;\n this.actionInProgress = true;\n\n try {\n const result = await this.startCallback();\n\n if (!result.success) {\n this.errorMessage =\n result.errorMessage ??\n this.#componentLocale.errors.startFailed;\n }\n } catch {\n this.errorMessage = this.#componentLocale.errors.startFailed;\n } finally {\n this.actionInProgress = false;\n }\n };\n\n #stopHandler = async () => {\n this.errorMessage = undefined;\n this.actionInProgress = true;\n\n try {\n const result = await this.stopCallback();\n\n if (!result.success) {\n this.errorMessage =\n result.errorMessage ??\n this.#componentLocale.errors.stopFailed;\n }\n } catch {\n this.errorMessage = this.#componentLocale.errors.stopFailed;\n } finally {\n this.actionInProgress = false;\n }\n };\n\n #closeHandler = () => {\n this.closeCallback?.();\n };\n\n #copyEndpointHandler = () => {\n if (this.serverEndpoint && this.copyCallback) {\n this.copying = true;\n this.copyCallback(this.serverEndpoint);\n setTimeout(() => {\n this.copying = false;\n }, 1000);\n }\n };\n\n #renderStatusBadge() {\n const statusText =\n this.#componentLocale.status[this.status] ?? this.status;\n\n const badgeClass = `status-badge status-badge--${this.status}`;\n const isAnimated =\n this.status === \"starting\" || this.status === \"stopping\";\n\n return (\n <span class={badgeClass}>\n <span\n class={`status-dot ${isAnimated ? \"status-dot--animated\" : \"\"}`}\n ></span>\n <span class=\"body-regular-s\">{statusText}</span>\n </span>\n );\n }\n\n #renderStatusCard() {\n if (this.status !== \"running\" && this.status !== \"stopping\") {\n return null;\n }\n\n const isDimmed = this.status === \"stopping\";\n\n return (\n <div\n class={`status-card elevation-1 ${isDimmed ? \"status-card--dimmed\" : \"\"}`}\n >\n <div class=\"status-card__row\">\n <span class=\"body-semi-bold-s\">\n {this.#componentLocale.statusCard.statusLabel}\n </span>\n <span class=\"body-regular-s\">\n {this.#componentLocale.status[this.status]}\n </span>\n </div>\n\n {this.serverPort !== undefined && (\n <div class=\"status-card__row\">\n <span class=\"body-semi-bold-s\">\n {this.#componentLocale.statusCard.portLabel}\n </span>\n <span class=\"body-regular-s\">{this.serverPort}</span>\n </div>\n )}\n\n {this.serverEndpoint && (\n <div class=\"status-card__row\">\n <span class=\"body-semi-bold-s\">\n {this.#componentLocale.statusCard.endpointLabel}\n </span>\n <span class=\"status-card__endpoint\">\n <span class=\"body-regular-s endpoint-value\">\n {this.serverEndpoint}\n </span>\n <button\n class=\"button-tertiary button-icon-only\"\n type=\"button\"\n onClick={this.#copyEndpointHandler}\n disabled={this.copying}\n aria-label={this.#componentLocale.statusCard.copyEndpoint}\n title={\n this.copying\n ? this.#componentLocale.statusCard.copiedEndpoint\n : this.#componentLocale.statusCard.copyEndpoint\n }\n >\n <ch-image class=\"icon-m\" src={COPY_ICON}></ch-image>\n </button>\n </span>\n </div>\n )}\n </div>\n );\n }\n\n #renderError() {\n if (!this.errorMessage) {\n return null;\n }\n\n return <div class=\"error-message body-regular-s\">{this.errorMessage}</div>;\n }\n\n #renderPrimaryButton() {\n const isRunning =\n this.status === \"running\" || this.status === \"stopping\";\n const isTransitioning =\n this.status === \"starting\" || this.status === \"stopping\";\n const isDisabled = this.actionInProgress || isTransitioning;\n\n if (isRunning) {\n return (\n <button\n class=\"button-primary primary-action\"\n type=\"button\"\n onClick={this.#stopHandler}\n disabled={isDisabled}\n part=\"button-confirm\"\n >\n {this.#componentLocale.buttons.stop}\n </button>\n );\n }\n\n return (\n <button\n class=\"button-primary primary-action\"\n type=\"button\"\n onClick={this.#startHandler}\n disabled={isDisabled}\n part=\"button-confirm\"\n >\n {this.#componentLocale.buttons.start}\n </button>\n );\n }\n\n render() {\n return (\n <Host class=\"widget\">\n <ch-theme model={CSS_BUNDLES}></ch-theme>\n <ch-shortcuts\n src={this.#shortcutsSrc}\n ref={(el: HTMLChShortcutsElement) =>\n (this.#chShortcutsEl = el as HTMLChShortcutsElement)\n }\n ></ch-shortcuts>\n <section class=\"section\">\n <header class=\"header dialog-header-with-border spacing-body-inline spacing-body-block-start\">\n <h1 class=\"heading-s title\">\n {this.#componentLocale.header.title}\n </h1>\n {!this.initialLoading && this.#renderStatusBadge()}\n </header>\n\n <div class=\"main spacing-body-inline\">\n {this.initialLoading ? (\n <gx-ide-loader\n loaderTitle={this.#componentLocale.loader.title}\n show\n class=\"loader\"\n ></gx-ide-loader>\n ) : ([\n <div class=\"info-section\">\n <p class=\"body-regular-m\">\n {this.#componentLocale.info.description}\n </p>\n <p class=\"body-regular-m\">\n {this.#componentLocale.info.details}\n </p>\n </div>,\n\n this.#renderStatusCard(),\n this.#renderError()\n ])}\n </div>\n\n <footer class=\"footer dialog-footer-with-border spacing-body-inline spacing-body-block-end\">\n <div class=\"buttons-spacer\">\n <button\n class=\"button-secondary\"\n type=\"button\"\n onClick={this.#closeHandler}\n part=\"button-cancel\"\n >\n {this.#componentLocale.buttons.close}\n </button>\n {!this.initialLoading && this.#renderPrimaryButton()}\n </div>\n </footer>\n </section>\n </Host>\n );\n }\n}\n\nexport type StartCallback = () => Promise<McpStartResult>;\nexport type StopCallback = () => Promise<McpStopResult>;\nexport type CopyCallback = (text: string) => void;\n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AAb,MAAIuB,GAAA;IACbgD,UAAUvE,KAAK0B;IAAO,cACVb,EAAAb,MAAIF,GAAA,KAAkBoE,WAAWM;IAC7C7B,OACE3C,KAAK0B,UACDb,EAAAb,MAAIF,GAAA,KAAkBoE,WAAWO,iBACjC5D,EAAAb,MAAIF,GAAA,KAAkBoE,WAAWM;KAGvCpC,EAAA;IAAUE,OAAM;IAASE,KAAKhD;;AAO5C,GAAC8D,IAAA,SAAAA;EAGC,KAAKtD,KAAKM,cAAc;IACtB,OAAO;;EAGT,OAAO8B,EAAA;IAAKE,OAAM;KAAgCtC,KAAKM;AACzD,GAACsD,IAAA,SAAAA;EAGC,MAAMc,IACJ1E,KAAK8D,WAAW,aAAa9D,KAAK8D,WAAW;EAC/C,MAAMa,IACJ3E,KAAK8D,WAAW,cAAc9D,KAAK8D,WAAW;EAChD,MAAMc,IAAa5E,KAAKQ,oBAAoBmE;EAE5C,IAAID,GAAW;IACb,OACEtC,EAAA;MACEE,OAAM;MACNiB,MAAK;MACLC,SAAS3C,EAAAb,MAAIiB,GAAA;MACbsD,UAAUK;MACVnB,MAAK;OAEJ5C,EAAAb,MAAIF,GAAA,KAAkB4D,QAAQmB;;EAKrC,OACEzC,EAAA;IACEE,OAAM;IACNiB,MAAK;IACLC,SAAS3C,EAAAb,MAAII,GAAA;IACbmE,UAAUK;IACVnB,MAAK;KAEJ5C,EAAAb,MAAIF,GAAA,KAAkB4D,QAAQoB;AAGrC"}
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
import { McpServerStatus, McpStartResult, McpStopResult } from "./types";
|
|
2
|
+
export declare class GxIdeMcpServer {
|
|
3
|
+
#private;
|
|
4
|
+
el: HTMLGxIdeMcpServerElement;
|
|
5
|
+
actionInProgress: boolean;
|
|
6
|
+
errorMessage: string | undefined;
|
|
7
|
+
copying: boolean;
|
|
8
|
+
/**
|
|
9
|
+
* When `true` the component shows a loader instead of content.
|
|
10
|
+
* The host sets this to `false` once the initial status is known.
|
|
11
|
+
*/
|
|
12
|
+
initialLoading: boolean;
|
|
13
|
+
/**
|
|
14
|
+
* Current MCP server status. The host is responsible for keeping
|
|
15
|
+
* this prop up to date (e.g. via polling or event-driven updates).
|
|
16
|
+
* The component only mutates it internally during start/stop
|
|
17
|
+
* transitions (`starting`, `stopping`, result states).
|
|
18
|
+
*/
|
|
19
|
+
status: McpServerStatus;
|
|
20
|
+
/**
|
|
21
|
+
* Port the MCP server is listening on (shown when running).
|
|
22
|
+
*/
|
|
23
|
+
serverPort: number | undefined;
|
|
24
|
+
/**
|
|
25
|
+
* Full endpoint URL (shown when running).
|
|
26
|
+
*/
|
|
27
|
+
serverEndpoint: string | undefined;
|
|
28
|
+
/**
|
|
29
|
+
* Callback to start the MCP server. Returns result with connection info.
|
|
30
|
+
*/
|
|
31
|
+
readonly startCallback: StartCallback;
|
|
32
|
+
/**
|
|
33
|
+
* Callback to stop the MCP server.
|
|
34
|
+
*/
|
|
35
|
+
readonly stopCallback: StopCallback;
|
|
36
|
+
/**
|
|
37
|
+
* Callback to copy text to the clipboard. Delegated to the IDE clipboard
|
|
38
|
+
* service so the host environment controls the copy behavior.
|
|
39
|
+
*/
|
|
40
|
+
readonly copyCallback: CopyCallback;
|
|
41
|
+
/**
|
|
42
|
+
* Callback to close/dismiss the dialog.
|
|
43
|
+
*/
|
|
44
|
+
readonly closeCallback: CloseCallback;
|
|
45
|
+
componentWillLoad(): Promise<void>;
|
|
46
|
+
/**
|
|
47
|
+
* Suspends or reactivates the shortcuts.
|
|
48
|
+
*/
|
|
49
|
+
suspendShortcuts(suspendShortcuts: boolean): Promise<void>;
|
|
50
|
+
render(): any;
|
|
51
|
+
}
|
|
52
|
+
export type StartCallback = () => Promise<McpStartResult>;
|
|
53
|
+
export type StopCallback = () => Promise<McpStopResult>;
|
|
54
|
+
export type CopyCallback = (text: string) => void;
|
|
55
|
+
export type CloseCallback = () => void;
|
|
@@ -43,9 +43,11 @@ import { CheckedItemsInfo } from "./components/_helpers/list-selector/list-selec
|
|
|
43
43
|
import { ItemData } from "./components/_helpers/list-selector/list-selector-item/list-selector-item";
|
|
44
44
|
import { IdeLoaderCancelCallback } from "./components/_helpers/ide-loader/ide-loader";
|
|
45
45
|
import { ExecuteActionCallback, ServerContextMenuCallback, ServerSelectedCallback } from "./components/modules/manage-module-references/manage-module-references";
|
|
46
|
+
import { McpServerStatus } from "./components/mcp-server/types";
|
|
47
|
+
import { CloseCallback, CopyCallback, StartCallback, StopCallback } from "./components/mcp-server/mcp-server";
|
|
46
48
|
import { ComboBoxModel } from "@genexus/chameleon-controls-library";
|
|
47
49
|
import { ContextMenuCallback, ContextMenuInfo as ContextMenuInfo1, FormSubmitResult as FormSubmitResult1 } from "./components";
|
|
48
|
-
import { CancelCallback as CancelCallback10, CloseCallback, ConfirmCallback as ConfirmCallback6, HeaderData, ItemSelectedCallback, NavigationData } from "./components/navigation-report/navigation-report";
|
|
50
|
+
import { CancelCallback as CancelCallback10, CloseCallback as CloseCallback1, ConfirmCallback as ConfirmCallback6, HeaderData, ItemSelectedCallback, NavigationData } from "./components/navigation-report/navigation-report";
|
|
49
51
|
import { CancelCallback as CancelCallback11, CreateCallback, GetDataSourcesCallback, GetEnvironmentNameCallback, GetFrontEndsCallback, GetLanguagesCallback } from "./components/new-environment/new-environment";
|
|
50
52
|
import { CancelCallback as CancelCallback12, CreateCallback as CreateCallback1, GetDataSourcesCallback as GetDataSourcesCallback1, GetFrontEndsCallback as GetFrontEndsCallback1, GetPrototypingEnvironmentsCallback, SelectLocationCallback as SelectLocationCallback1 } from "./components/new-kb/new-kb";
|
|
51
53
|
import { CancelCallback as CancelCallback13, CreateCallback as CreateCallback2, NewObjectData, SelectModuleCallback as SelectModuleCallback3, SuggestCallback, TypeCategoryData, ValidateNameCallback } from "./components/new-object/new-object";
|
|
@@ -76,7 +78,7 @@ import { cancelCallback, confirmCallback } from "./components/team-dev/select-re
|
|
|
76
78
|
import { ContextMenuCallback as ContextMenuCallback2, PendingItemsCheckedCallback as PendingItemsCheckedCallback1, UpdateFromData } from "./components/team-dev/update/update";
|
|
77
79
|
import { AddCallback, CancelCallback as CancelCallback17, ConfirmCallback as ConfirmCallback7, ObjectData as ObjectData2 } from "./components/team-dev/update-partial-selection/update-partial-selection";
|
|
78
80
|
import { cancelCallbackFn, confirmCallbackFn } from "./components/team-dev/update-to-revision/update-to-revision";
|
|
79
|
-
import { CloseCallback as
|
|
81
|
+
import { CloseCallback as CloseCallback2, SlideInfo, TransitionType } from "./components/welcome-page/welcome-page";
|
|
80
82
|
import { WFConfigData } from "./components/wf-settings/wf-settings";
|
|
81
83
|
import { ContextMenuCallback as ContextMenuCallback3, DeleteSelectionCallback, LoadCallback as LoadCallback5, ObjectActionCallback, OpenSelectionCallback as OpenSelectionCallback1, SelectionChangeCallback } from "./components/ww-attributes/ww-attributes";
|
|
82
84
|
import { ContextMenuCallback as ContextMenuCallback4, DeleteSelectionCallback as DeleteSelectionCallback1, GridColumnsVisibility, LoadCallback as LoadCallback6, NewFileCallback, OpenSelectionCallback as OpenSelectionCallback2, SelectionChangeCallback as SelectionChangeCallback1, SelectModuleCallback as SelectModuleCallback5 } from "./components/ww-files/ww-files";
|
|
@@ -119,9 +121,11 @@ export { CheckedItemsInfo } from "./components/_helpers/list-selector/list-selec
|
|
|
119
121
|
export { ItemData } from "./components/_helpers/list-selector/list-selector-item/list-selector-item";
|
|
120
122
|
export { IdeLoaderCancelCallback } from "./components/_helpers/ide-loader/ide-loader";
|
|
121
123
|
export { ExecuteActionCallback, ServerContextMenuCallback, ServerSelectedCallback } from "./components/modules/manage-module-references/manage-module-references";
|
|
124
|
+
export { McpServerStatus } from "./components/mcp-server/types";
|
|
125
|
+
export { CloseCallback, CopyCallback, StartCallback, StopCallback } from "./components/mcp-server/mcp-server";
|
|
122
126
|
export { ComboBoxModel } from "@genexus/chameleon-controls-library";
|
|
123
127
|
export { ContextMenuCallback, ContextMenuInfo as ContextMenuInfo1, FormSubmitResult as FormSubmitResult1 } from "./components";
|
|
124
|
-
export { CancelCallback as CancelCallback10, CloseCallback, ConfirmCallback as ConfirmCallback6, HeaderData, ItemSelectedCallback, NavigationData } from "./components/navigation-report/navigation-report";
|
|
128
|
+
export { CancelCallback as CancelCallback10, CloseCallback as CloseCallback1, ConfirmCallback as ConfirmCallback6, HeaderData, ItemSelectedCallback, NavigationData } from "./components/navigation-report/navigation-report";
|
|
125
129
|
export { CancelCallback as CancelCallback11, CreateCallback, GetDataSourcesCallback, GetEnvironmentNameCallback, GetFrontEndsCallback, GetLanguagesCallback } from "./components/new-environment/new-environment";
|
|
126
130
|
export { CancelCallback as CancelCallback12, CreateCallback as CreateCallback1, GetDataSourcesCallback as GetDataSourcesCallback1, GetFrontEndsCallback as GetFrontEndsCallback1, GetPrototypingEnvironmentsCallback, SelectLocationCallback as SelectLocationCallback1 } from "./components/new-kb/new-kb";
|
|
127
131
|
export { CancelCallback as CancelCallback13, CreateCallback as CreateCallback2, NewObjectData, SelectModuleCallback as SelectModuleCallback3, SuggestCallback, TypeCategoryData, ValidateNameCallback } from "./components/new-object/new-object";
|
|
@@ -152,7 +156,7 @@ export { cancelCallback, confirmCallback } from "./components/team-dev/select-re
|
|
|
152
156
|
export { ContextMenuCallback as ContextMenuCallback2, PendingItemsCheckedCallback as PendingItemsCheckedCallback1, UpdateFromData } from "./components/team-dev/update/update";
|
|
153
157
|
export { AddCallback, CancelCallback as CancelCallback17, ConfirmCallback as ConfirmCallback7, ObjectData as ObjectData2 } from "./components/team-dev/update-partial-selection/update-partial-selection";
|
|
154
158
|
export { cancelCallbackFn, confirmCallbackFn } from "./components/team-dev/update-to-revision/update-to-revision";
|
|
155
|
-
export { CloseCallback as
|
|
159
|
+
export { CloseCallback as CloseCallback2, SlideInfo, TransitionType } from "./components/welcome-page/welcome-page";
|
|
156
160
|
export { WFConfigData } from "./components/wf-settings/wf-settings";
|
|
157
161
|
export { ContextMenuCallback as ContextMenuCallback3, DeleteSelectionCallback, LoadCallback as LoadCallback5, ObjectActionCallback, OpenSelectionCallback as OpenSelectionCallback1, SelectionChangeCallback } from "./components/ww-attributes/ww-attributes";
|
|
158
162
|
export { ContextMenuCallback as ContextMenuCallback4, DeleteSelectionCallback as DeleteSelectionCallback1, GridColumnsVisibility, LoadCallback as LoadCallback6, NewFileCallback, OpenSelectionCallback as OpenSelectionCallback2, SelectionChangeCallback as SelectionChangeCallback1, SelectModuleCallback as SelectModuleCallback5 } from "./components/ww-files/ww-files";
|
|
@@ -1497,6 +1501,44 @@ export namespace Components {
|
|
|
1497
1501
|
*/
|
|
1498
1502
|
"showServerCommands": boolean;
|
|
1499
1503
|
}
|
|
1504
|
+
interface GxIdeMcpServer {
|
|
1505
|
+
/**
|
|
1506
|
+
* Callback to close/dismiss the dialog.
|
|
1507
|
+
*/
|
|
1508
|
+
"closeCallback": CloseCallback;
|
|
1509
|
+
/**
|
|
1510
|
+
* Callback to copy text to the clipboard. Delegated to the IDE clipboard service so the host environment controls the copy behavior.
|
|
1511
|
+
*/
|
|
1512
|
+
"copyCallback": CopyCallback;
|
|
1513
|
+
/**
|
|
1514
|
+
* When `true` the component shows a loader instead of content. The host sets this to `false` once the initial status is known.
|
|
1515
|
+
*/
|
|
1516
|
+
"initialLoading": boolean;
|
|
1517
|
+
/**
|
|
1518
|
+
* Full endpoint URL (shown when running).
|
|
1519
|
+
*/
|
|
1520
|
+
"serverEndpoint": string | undefined;
|
|
1521
|
+
/**
|
|
1522
|
+
* Port the MCP server is listening on (shown when running).
|
|
1523
|
+
*/
|
|
1524
|
+
"serverPort": number | undefined;
|
|
1525
|
+
/**
|
|
1526
|
+
* Callback to start the MCP server. Returns result with connection info.
|
|
1527
|
+
*/
|
|
1528
|
+
"startCallback": StartCallback;
|
|
1529
|
+
/**
|
|
1530
|
+
* Current MCP server status. The host is responsible for keeping this prop up to date (e.g. via polling or event-driven updates). The component only mutates it internally during start/stop transitions (`starting`, `stopping`, result states).
|
|
1531
|
+
*/
|
|
1532
|
+
"status": McpServerStatus;
|
|
1533
|
+
/**
|
|
1534
|
+
* Callback to stop the MCP server.
|
|
1535
|
+
*/
|
|
1536
|
+
"stopCallback": StopCallback;
|
|
1537
|
+
/**
|
|
1538
|
+
* Suspends or reactivates the shortcuts.
|
|
1539
|
+
*/
|
|
1540
|
+
"suspendShortcuts": (suspendShortcuts: boolean) => Promise<void>;
|
|
1541
|
+
}
|
|
1500
1542
|
interface GxIdeMultiSelect {
|
|
1501
1543
|
/**
|
|
1502
1544
|
* Disabled state
|
|
@@ -1547,7 +1589,7 @@ export namespace Components {
|
|
|
1547
1589
|
/**
|
|
1548
1590
|
* Callback to be invoked when the user closes the dialog
|
|
1549
1591
|
*/
|
|
1550
|
-
"closeCallback":
|
|
1592
|
+
"closeCallback": CloseCallback1;
|
|
1551
1593
|
/**
|
|
1552
1594
|
* Callback invoked when user confirms data base reorganization
|
|
1553
1595
|
*/
|
|
@@ -2686,7 +2728,7 @@ export namespace Components {
|
|
|
2686
2728
|
/**
|
|
2687
2729
|
* Callback invoked when the user closes the slider by pressing the close button.
|
|
2688
2730
|
*/
|
|
2689
|
-
"closeCallback":
|
|
2731
|
+
"closeCallback": CloseCallback2;
|
|
2690
2732
|
/**
|
|
2691
2733
|
* An array of slides, with the information that each slide requires. This slides appear after the first slide (Copyrights) that is defined inside the component.
|
|
2692
2734
|
*/
|
|
@@ -3527,6 +3569,12 @@ declare global {
|
|
|
3527
3569
|
prototype: HTMLGxIdeManageModuleReferencesElement;
|
|
3528
3570
|
new (): HTMLGxIdeManageModuleReferencesElement;
|
|
3529
3571
|
};
|
|
3572
|
+
interface HTMLGxIdeMcpServerElement extends Components.GxIdeMcpServer, HTMLStencilElement {
|
|
3573
|
+
}
|
|
3574
|
+
var HTMLGxIdeMcpServerElement: {
|
|
3575
|
+
prototype: HTMLGxIdeMcpServerElement;
|
|
3576
|
+
new (): HTMLGxIdeMcpServerElement;
|
|
3577
|
+
};
|
|
3530
3578
|
interface HTMLGxIdeMultiSelectElementEventMap {
|
|
3531
3579
|
"gxSelectionChange": string[];
|
|
3532
3580
|
}
|
|
@@ -3948,6 +3996,7 @@ declare global {
|
|
|
3948
3996
|
"gx-ide-list-selector-item": HTMLGxIdeListSelectorItemElement;
|
|
3949
3997
|
"gx-ide-loader": HTMLGxIdeLoaderElement;
|
|
3950
3998
|
"gx-ide-manage-module-references": HTMLGxIdeManageModuleReferencesElement;
|
|
3999
|
+
"gx-ide-mcp-server": HTMLGxIdeMcpServerElement;
|
|
3951
4000
|
"gx-ide-multi-select": HTMLGxIdeMultiSelectElement;
|
|
3952
4001
|
"gx-ide-name-picker": HTMLGxIdeNamePickerElement;
|
|
3953
4002
|
"gx-ide-navigation-report": HTMLGxIdeNavigationReportElement;
|
|
@@ -5414,6 +5463,40 @@ declare namespace LocalJSX {
|
|
|
5414
5463
|
*/
|
|
5415
5464
|
"showServerCommands"?: boolean;
|
|
5416
5465
|
}
|
|
5466
|
+
interface GxIdeMcpServer {
|
|
5467
|
+
/**
|
|
5468
|
+
* Callback to close/dismiss the dialog.
|
|
5469
|
+
*/
|
|
5470
|
+
"closeCallback": CloseCallback;
|
|
5471
|
+
/**
|
|
5472
|
+
* Callback to copy text to the clipboard. Delegated to the IDE clipboard service so the host environment controls the copy behavior.
|
|
5473
|
+
*/
|
|
5474
|
+
"copyCallback": CopyCallback;
|
|
5475
|
+
/**
|
|
5476
|
+
* When `true` the component shows a loader instead of content. The host sets this to `false` once the initial status is known.
|
|
5477
|
+
*/
|
|
5478
|
+
"initialLoading"?: boolean;
|
|
5479
|
+
/**
|
|
5480
|
+
* Full endpoint URL (shown when running).
|
|
5481
|
+
*/
|
|
5482
|
+
"serverEndpoint"?: string | undefined;
|
|
5483
|
+
/**
|
|
5484
|
+
* Port the MCP server is listening on (shown when running).
|
|
5485
|
+
*/
|
|
5486
|
+
"serverPort"?: number | undefined;
|
|
5487
|
+
/**
|
|
5488
|
+
* Callback to start the MCP server. Returns result with connection info.
|
|
5489
|
+
*/
|
|
5490
|
+
"startCallback": StartCallback;
|
|
5491
|
+
/**
|
|
5492
|
+
* Current MCP server status. The host is responsible for keeping this prop up to date (e.g. via polling or event-driven updates). The component only mutates it internally during start/stop transitions (`starting`, `stopping`, result states).
|
|
5493
|
+
*/
|
|
5494
|
+
"status": McpServerStatus;
|
|
5495
|
+
/**
|
|
5496
|
+
* Callback to stop the MCP server.
|
|
5497
|
+
*/
|
|
5498
|
+
"stopCallback": StopCallback;
|
|
5499
|
+
}
|
|
5417
5500
|
interface GxIdeMultiSelect {
|
|
5418
5501
|
/**
|
|
5419
5502
|
* Disabled state
|
|
@@ -5460,7 +5543,7 @@ declare namespace LocalJSX {
|
|
|
5460
5543
|
/**
|
|
5461
5544
|
* Callback to be invoked when the user closes the dialog
|
|
5462
5545
|
*/
|
|
5463
|
-
"closeCallback"?:
|
|
5546
|
+
"closeCallback"?: CloseCallback1;
|
|
5464
5547
|
/**
|
|
5465
5548
|
* Callback invoked when user confirms data base reorganization
|
|
5466
5549
|
*/
|
|
@@ -6545,7 +6628,7 @@ declare namespace LocalJSX {
|
|
|
6545
6628
|
/**
|
|
6546
6629
|
* Callback invoked when the user closes the slider by pressing the close button.
|
|
6547
6630
|
*/
|
|
6548
|
-
"closeCallback":
|
|
6631
|
+
"closeCallback": CloseCallback2;
|
|
6549
6632
|
/**
|
|
6550
6633
|
* An array of slides, with the information that each slide requires. This slides appear after the first slide (Copyrights) that is defined inside the component.
|
|
6551
6634
|
*/
|
|
@@ -6772,6 +6855,7 @@ declare namespace LocalJSX {
|
|
|
6772
6855
|
"gx-ide-list-selector-item": GxIdeListSelectorItem;
|
|
6773
6856
|
"gx-ide-loader": GxIdeLoader;
|
|
6774
6857
|
"gx-ide-manage-module-references": GxIdeManageModuleReferences;
|
|
6858
|
+
"gx-ide-mcp-server": GxIdeMcpServer;
|
|
6775
6859
|
"gx-ide-multi-select": GxIdeMultiSelect;
|
|
6776
6860
|
"gx-ide-name-picker": GxIdeNamePicker;
|
|
6777
6861
|
"gx-ide-navigation-report": GxIdeNavigationReport;
|
|
@@ -6863,6 +6947,7 @@ declare module "@stencil/core" {
|
|
|
6863
6947
|
"gx-ide-list-selector-item": LocalJSX.GxIdeListSelectorItem & JSXBase.HTMLAttributes<HTMLGxIdeListSelectorItemElement>;
|
|
6864
6948
|
"gx-ide-loader": LocalJSX.GxIdeLoader & JSXBase.HTMLAttributes<HTMLGxIdeLoaderElement>;
|
|
6865
6949
|
"gx-ide-manage-module-references": LocalJSX.GxIdeManageModuleReferences & JSXBase.HTMLAttributes<HTMLGxIdeManageModuleReferencesElement>;
|
|
6950
|
+
"gx-ide-mcp-server": LocalJSX.GxIdeMcpServer & JSXBase.HTMLAttributes<HTMLGxIdeMcpServerElement>;
|
|
6866
6951
|
"gx-ide-multi-select": LocalJSX.GxIdeMultiSelect & JSXBase.HTMLAttributes<HTMLGxIdeMultiSelectElement>;
|
|
6867
6952
|
"gx-ide-name-picker": LocalJSX.GxIdeNamePicker & JSXBase.HTMLAttributes<HTMLGxIdeNamePickerElement>;
|
|
6868
6953
|
"gx-ide-navigation-report": LocalJSX.GxIdeNavigationReport & JSXBase.HTMLAttributes<HTMLGxIdeNavigationReportElement>;
|