@genexus/genexus-ide-ui 1.0.22 → 1.0.24

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 (63) hide show
  1. package/dist/cjs/gx-ide-ai-assistant.cjs.entry.js +4 -3
  2. package/dist/cjs/gx-ide-ai-assistant.cjs.entry.js.map +1 -1
  3. package/dist/cjs/gx-ide-ai-message.cjs.entry.js +10 -28
  4. package/dist/cjs/gx-ide-ai-message.cjs.entry.js.map +1 -1
  5. package/dist/cjs/gx-ide-start-page.cjs.entry.js +2 -4
  6. package/dist/cjs/gx-ide-start-page.cjs.entry.js.map +1 -1
  7. package/dist/cjs/gx-ide-welcome-page.cjs.entry.js +2 -2
  8. package/dist/cjs/gx-ide-welcome-page.cjs.entry.js.map +1 -1
  9. package/dist/collection/components/ai-assistant/ai-assistant.css +2 -2
  10. package/dist/collection/components/ai-assistant/ai-assistant.js +3 -2
  11. package/dist/collection/components/ai-assistant/ai-assistant.js.map +1 -1
  12. package/dist/collection/components/ai-assistant/ai-message.css +38 -13
  13. package/dist/collection/components/ai-assistant/ai-message.js +11 -27
  14. package/dist/collection/components/ai-assistant/ai-message.js.map +1 -1
  15. package/dist/collection/components/ai-assistant/gx-ide-assets/ai-assistant/langs/ai-assistant.lang.en.json +1 -0
  16. package/dist/collection/components/ai-assistant/gx-ide-assets/ai-assistant/langs/ai-assistant.lang.ja.json +2 -1
  17. package/dist/collection/components/ai-assistant/gx-ide-assets/ai-message/langs/ai-message.lang.en.json +4 -0
  18. package/dist/collection/components/ai-assistant/gx-ide-assets/ai-message/langs/ai-message.lang.ja.json +3 -0
  19. package/dist/collection/components/ai-assistant/gx-ide-assets/ai-message/langs/ai-message.lang.zh.json +3 -0
  20. package/dist/collection/components/start-page/start-page.css +3 -2
  21. package/dist/collection/components/start-page/start-page.js +1 -3
  22. package/dist/collection/components/start-page/start-page.js.map +1 -1
  23. package/dist/collection/components/welcome-page/welcome-page.css +2 -16
  24. package/dist/collection/components/welcome-page/welcome-page.js +1 -1
  25. package/dist/collection/components/welcome-page/welcome-page.js.map +1 -1
  26. package/dist/components/ai-message.js +10 -28
  27. package/dist/components/ai-message.js.map +1 -1
  28. package/dist/components/gx-ide-ai-assistant.js +4 -3
  29. package/dist/components/gx-ide-ai-assistant.js.map +1 -1
  30. package/dist/components/gx-ide-start-page.js +2 -4
  31. package/dist/components/gx-ide-start-page.js.map +1 -1
  32. package/dist/components/gx-ide-welcome-page.js +2 -2
  33. package/dist/components/gx-ide-welcome-page.js.map +1 -1
  34. package/dist/esm/gx-ide-ai-assistant.entry.js +4 -3
  35. package/dist/esm/gx-ide-ai-assistant.entry.js.map +1 -1
  36. package/dist/esm/gx-ide-ai-message.entry.js +10 -28
  37. package/dist/esm/gx-ide-ai-message.entry.js.map +1 -1
  38. package/dist/esm/gx-ide-start-page.entry.js +2 -4
  39. package/dist/esm/gx-ide-start-page.entry.js.map +1 -1
  40. package/dist/esm/gx-ide-welcome-page.entry.js +2 -2
  41. package/dist/esm/gx-ide-welcome-page.entry.js.map +1 -1
  42. package/dist/genexus-ide-ui/genexus-ide-ui.esm.js +1 -1
  43. package/dist/genexus-ide-ui/gx-ide-assets/ai-assistant/langs/ai-assistant.lang.en.json +1 -0
  44. package/dist/genexus-ide-ui/gx-ide-assets/ai-assistant/langs/ai-assistant.lang.ja.json +2 -1
  45. package/dist/genexus-ide-ui/gx-ide-assets/ai-message/langs/ai-message.lang.en.json +4 -0
  46. package/dist/genexus-ide-ui/gx-ide-assets/ai-message/langs/ai-message.lang.ja.json +3 -0
  47. package/dist/genexus-ide-ui/gx-ide-assets/ai-message/langs/ai-message.lang.zh.json +3 -0
  48. package/dist/genexus-ide-ui/{p-7a2d3f1c.entry.js → p-10beeb25.entry.js} +32 -30
  49. package/dist/genexus-ide-ui/p-10beeb25.entry.js.map +1 -0
  50. package/dist/genexus-ide-ui/{p-120d283a.entry.js → p-4b46f4bf.entry.js} +6 -6
  51. package/dist/genexus-ide-ui/p-4b46f4bf.entry.js.map +1 -0
  52. package/dist/genexus-ide-ui/p-673480ac.entry.js +88 -0
  53. package/dist/genexus-ide-ui/p-673480ac.entry.js.map +1 -0
  54. package/dist/genexus-ide-ui/{p-26b2037d.entry.js → p-9e810ad5.entry.js} +5 -4
  55. package/dist/genexus-ide-ui/p-9e810ad5.entry.js.map +1 -0
  56. package/dist/types/components/ai-assistant/ai-message.d.ts +1 -1
  57. package/dist/types/components/welcome-page/welcome-page.d.ts +4 -1
  58. package/package.json +3 -3
  59. package/dist/genexus-ide-ui/p-120d283a.entry.js.map +0 -1
  60. package/dist/genexus-ide-ui/p-26b2037d.entry.js.map +0 -1
  61. package/dist/genexus-ide-ui/p-5dfb7c66.entry.js +0 -106
  62. package/dist/genexus-ide-ui/p-5dfb7c66.entry.js.map +0 -1
  63. package/dist/genexus-ide-ui/p-7a2d3f1c.entry.js.map +0 -1
@@ -169,9 +169,7 @@ export class GxIdeStartPage {
169
169
  var _a;
170
170
  this.loading =
171
171
  (!this.kbs || ((_a = this.kbs) === null || _a === void 0 ? void 0 : _a.length) === 0) && !this.secondarySection;
172
- return (h(Host, null, h("ch-theme", { model: CSS_BUNDLES }), h("main", { class: {
173
- main: true
174
- } }, h("section", {
172
+ return (h(Host, { class: "widget scrollable spacing-body" }, h("ch-theme", { model: CSS_BUNDLES }), h("main", { class: "main scrollable" }, h("section", {
175
173
  // Create a new Knowledge Base
176
174
  class: "section-create-new-kb"
177
175
  }, h("header", {
@@ -1 +1 @@
1
- {"version":3,"file":"start-page.js","sourceRoot":"","sources":["../../../src/components/start-page/start-page.tsx"],"names":[],"mappings":";;;;;;;;;;;;AAAA,UAAU;AACV,OAAO,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC,EAAE,IAAI,EAAE,KAAK,EAAE,OAAO,EAAE,KAAK,EAAE,MAAM,eAAe,CAAC;AAChF,kBAAkB;AAClB,OAAO,EAAkB,WAAW,EAAE,MAAM,kBAAkB,CAAC;AAC/D,OAAO,EAAE,m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AAC,qBAAqB,IAC3B,uBAAA,IAAI,uCAAiB,CAAC,mBAAmB,CAAC,WAAW,CACpD,CACA,CACC;4BACT,cAAQ,KAAK,EAAC,cAAc;gCAC1B,cACE,KAAK,EAAC,6BAA6B,EACnC,OAAO,EAAE,uBAAA,IAAI,4CAAsB,MAA1B,IAAI,EAAuB,IAAI,CAAC,IAExC,uBAAA,IAAI,uCAAiB,CAAC,mBAAmB,CAAC,aAAa,CACjD,CACF,CACD,CACF,CACF;gBACV,eAAS,KAAK,EAAC,8BAA8B,IAC1C,IAAI,CAAC,OAAO,CAAC,CAAC,CAAC,CACd,qBACE,KAAK,EAAC,QAAQ,EACd,WAAW,EAAE,uBAAA,IAAI,uCAAiB,CAAC,SAAS,CAAC,WAAW,EACxD,WAAW,EAAE,uBAAA,IAAI,uCAAiB,CAAC,SAAS,CAAC,iBAAiB,EAC9D,IAAI,SACW,CAClB,CAAC,CAAC,CAAC,CACF,uBAAA,IAAI,0EAAyB,MAA7B,IAAI,CAA2B,CAChC,CACO,CACL,CACF,CACR,CAAC;IACJ,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF;;IA7JG,OAAO,IAAI,CAAC,GAAG,IAAI,IAAI,CAAC,GAAG,CAAC,MAAM,GAAG,CAAC;QACpC,CAAC,CAAC,uBAAA,IAAI,wCAAkB,MAAtB,IAAI,CAAoB;QAC1B,CAAC,CAAC,uBAAA,IAAI,8CAAwB,MAA5B,IAAI,CAA0B,CAAC;AACrC,CAAC","sourcesContent":["// Stencil\nimport { Component, Host, h, Prop, State, Element, Watch } from \"@stencil/core\";\n// Other Libraries\nimport { MercuryBundles, getIconPath } from \"@genexus/mercury\";\nimport { formatDistanceToNow, Locale as LocaleDateFns } from \"date-fns\";\nimport { ja, zhCN, enUS } from \"date-fns/locale\";\n// import { enUS } from \"date-fns/locale\";\nimport { ChEditCustomEvent } from \"@genexus/chameleon-controls-library\";\n// Custom\nimport { Locale } from \"../../common/locale\";\n\n// const locale = enUS; // use `zhCN` for Chinese, `ja` for Japanese, `enUS` for English\n\nconst LANGS_DATE_FNS_MAP: LanguageMap = {\n \"en\": enUS,\n \"ja\": ja,\n \"zh-CN\": zhCN,\n \"zh-TW\": zhCN,\n \"zh-HK\": zhCN\n};\n\nconst DETAIL_ICON = getIconPath({\n category: \"system\",\n name: \"detail\",\n colorType: \"primary\"\n});\nconst FILTER_ICON = getIconPath({\n category: \"window-tools\",\n name: \"filter\",\n colorType: \"on-elevation\"\n});\nconst KB_DEFAULT_ICON = getIconPath({\n category: \"objects\",\n name: \"knowledge-base\"\n});\nconst SEARCH_ICON = getIconPath({\n category: \"system\",\n name: \"search\",\n colorType: \"on-elevation\"\n});\n\nconst CSS_BUNDLES: MercuryBundles = [\n \"resets/box-sizing\",\n \"utils/typography\",\n \"utils/layout\",\n \"components/edit\",\n \"components/icon\",\n \"components/button\",\n \"chameleon/scrollbar\",\n \"utils/typography\"\n];\n\n@Component({\n tag: \"gx-ide-start-page\",\n styleUrl: \"start-page.scss\",\n shadow: true,\n assetsDirs: [\"gx-ide-assets/start-page\"]\n})\nexport class GxIdeStartPage {\n /**\n * The component hard-coded strings translations.\n */\n // eslint-disable-next-line @stencil-community/own-props-must-be-private\n #componentLocale: any;\n #userLanguage: LocaleDateFns;\n\n @Element() el: HTMLGxIdeStartPageElement;\n\n @State() kbFilterValue: string = \"\";\n @Watch(\"kbFilterValue\")\n kbFilterValueChanged(newKbFilterValue: string) {\n this.filteredKbs = this.kbs.filter(kb =>\n kb.name.toLowerCase().includes(newKbFilterValue.toLocaleLowerCase())\n );\n }\n\n /**\n * The kbs after the filter value.\n */\n @State() filteredKbs: RecentKBData[];\n\n /**\n * True if the start page is waiting, either for the kb's list or the secondary section.\n */\n @State() loading: boolean = true;\n\n /**\n * Callback invoked to create a new KB. It must be specified whether this create is create from server or not, through the parameter 'fromServer'.\n */\n @Prop() readonly createKBCallback!: (fromServer: boolean) => Promise<void>;\n\n /**\n * Callback invoked to open a KB when the user clicks on a KB card.\n */\n @Prop() readonly openKbCallback!: (id: string) => Promise<void>;\n\n /**\n * The secondary section that will appear below the \"Create a new Knowledge Base\" main section. This section will be displayed if there are no recent kbs.\n */\n @Prop() readonly secondarySection?: SecondarySection;\n\n /**\n * User's kbs array\n */\n @Prop() readonly kbs: RecentKBData[];\n @Watch(\"kbs\")\n kbsChanged(newKbs: RecentKBData[]) {\n this.filteredKbs = newKbs;\n this.kbFilterValue = \"\"; // clear filter\n }\n\n /**\n * The minimum required of kbs to display a filter.\n */\n @Prop() readonly kbsFilterThreshold: number;\n\n async componentWillLoad() {\n this.#componentLocale = await Locale.getComponentStrings(this.el);\n\n // initialize filteredKbs\n this.kbsChanged(this.kbs);\n\n // get user language to display the kb \"last opened\" value in the appropriate language.\n const userLanguage: keyof LanguageMap = document.documentElement\n .lang as keyof LanguageMap;\n this.#userLanguage = LANGS_DATE_FNS_MAP[userLanguage];\n }\n\n #createKBClickHandler = (fromServer: boolean) => (event: MouseEvent) => {\n event.stopPropagation();\n this.createKBCallback(fromServer);\n };\n\n #openKbClickHandler = (kbId: string) => (event: MouseEvent) => {\n event.stopPropagation();\n this.openKbCallback(kbId);\n };\n\n #filterKbs = (event: ChEditCustomEvent<string> | InputEvent) => {\n this.kbFilterValue = event.detail as string;\n };\n\n #renderKbsSection = () => {\n const hideKbsFilter = this.kbs.length < this.kbsFilterThreshold;\n const kbsListEmpty = this.filteredKbs.length === 0;\n let contentToRender: HTMLGxgIdeLoaderElement | HTMLElement[];\n\n // Evaluate what is the content to display.\n if (this.filteredKbs.length > 0) {\n contentToRender = this.#renderKbs();\n } else {\n // No kb has pass the filter. Display an empty-state.\n contentToRender = (\n <gx-ide-empty-state\n isAnimated\n stateIconSrc={FILTER_ICON}\n stateTitle={this.#componentLocale.recentKBs.noMatches}\n ></gx-ide-empty-state>\n );\n }\n\n return (\n <section class=\"section-kbs\">\n <header\n class={{\n \"section-kbs__header\": true\n }}\n >\n <h2 class=\"heading-3 section-kbs__title\">\n {this.#componentLocale.recentKBs.title}\n </h2>\n <ch-edit\n // Render always, and display or hide, ro prevent FOUC, and also prevent\n // the header block-size from growing a little bit when the input renders.\n value={this.kbFilterValue}\n class={{\n \"input\": true,\n \"section-kbs__filter--hidden\": hideKbsFilter\n }}\n startImgSrc={SEARCH_ICON}\n placeholder={this.#componentLocale.recentKBs.filterKbsPlaceholder}\n onInput={!hideKbsFilter && this.#filterKbs}\n disabled={hideKbsFilter}\n ></ch-edit>\n </header>\n\n <div\n class={{\n \"section-kbs__list\": true,\n \"section-kbs__list--empty\": kbsListEmpty,\n \"scrollable\": true\n }}\n >\n {this.filteredKbs.length > 0 ? this.#renderKbs() : contentToRender}\n </div>\n </section>\n );\n };\n\n #renderKbs = (): HTMLElement[] => {\n return this.filteredKbs?.map((kb, index) => {\n // relative time ago\n\n const relativeDate = kb.lastOpenedDate\n ? formatDistanceToNow(new Date(kb.lastOpenedDate), {\n addSuffix: true,\n locale: this.#userLanguage\n })\n : undefined;\n\n // icon\n const kbIcon = kb.icon ?? KB_DEFAULT_ICON;\n\n return (\n <article class=\"kb__item\" key={index}>\n <div class=\"kb__details\">\n <ch-image class=\"icon-md\" src={kbIcon}></ch-image>\n <p\n class=\"text-body-regular-m kb__name\"\n onClick={this.#openKbClickHandler(kb.id)}\n >\n {kb.name}\n </p>\n </div>\n {relativeDate && (\n <div class=\"text-body-regular-m kb__modified\">\n {`${this.#componentLocale.recentKBs.opened} ${relativeDate}`}\n </div>\n )}\n </article>\n );\n });\n };\n\n #evaluateContentToRender() {\n return this.kbs && this.kbs.length > 0\n ? this.#renderKbsSection()\n : this.#renderSecondarySection();\n }\n\n #renderSecondarySection = (): HTMLElement | null => {\n if (!this.secondarySection) {\n return null;\n }\n\n const multipleCards = this.secondarySection.cards.length > 2;\n\n return (\n <section\n // Recent Knowledge Bases\n class=\"section-secondary\"\n >\n <header>\n <h2 class=\"heading-3\">{this.secondarySection.title}</h2>\n </header>\n\n <section\n class={{\n \"section-secondary__actions\": true,\n \"section-secondary__actions--two-cards\": !multipleCards,\n \"section-secondary__actions--multiple-cards\": multipleCards,\n \"scrollable\": true\n }}\n >\n {this.secondarySection.cards.map((card, index) => {\n return (\n <article class=\"card card-outlined\" key={index}>\n <header class=\"card__header\">\n <span class=\"icon-capsule\">\n <ch-image\n class=\"icon-md icon-circular\"\n src={card.icon.src}\n aria-label={card.icon.ariaLabel}\n ></ch-image>\n </span>\n <div class=\"card__header-description\">\n <h2 class=\"heading-3\">{card.title}</h2>\n {card.description.map(paragraph => (\n <p class=\"text-body-regular-m\">{paragraph}</p>\n ))}\n </div>\n </header>\n <footer class=\"card__footer\">\n {card.action && (\n <button\n class=\"button-tertiary button-icon-and-text\"\n onClick={card.action.callback && card.action.callback}\n >\n <ch-image class=\"icon-md\" src={DETAIL_ICON}></ch-image>\n {card.action.caption}\n </button>\n )}\n </footer>\n </article>\n );\n })}\n </section>\n </section>\n );\n };\n\n render() {\n this.loading =\n (!this.kbs || this.kbs?.length === 0) && !this.secondarySection;\n return (\n <Host>\n <ch-theme model={CSS_BUNDLES}></ch-theme>\n <main\n class={{\n main: true\n }}\n >\n <section\n // Create a new Knowledge Base\n class=\"section-create-new-kb\"\n >\n <header\n // main header\n class=\"section-create-new__header\"\n >\n <h1 class=\"heading-2\">{this.#componentLocale.createKB.title}</h1>\n <p class=\"text-body-regular-m\">\n {this.#componentLocale.createKB.description}\n </p>\n </header>\n\n <section class=\"section-create-new-kb__actions scrollable\">\n <article\n // create project\n class=\"card card-filled\"\n >\n <header class=\"card__header\">\n <div class=\"card__header-description\">\n <h2 class=\"heading-3\">\n {this.#componentLocale.createProject.title}\n </h2>\n <p class=\"text-body-regular-m\">\n {this.#componentLocale.createProject.description}\n </p>\n </div>\n </header>\n <footer class=\"card__footer\">\n <button\n class=\"button-primary\"\n onClick={this.#createKBClickHandler(false)}\n >\n {this.#componentLocale.createProject.buttonCaption}\n </button>\n </footer>\n </article>\n\n <article\n // open existing project\n class=\"card-filled\"\n >\n <header class=\"card__header\">\n <div class=\"card__header-description\">\n <h2 class=\"heading-3\">\n {this.#componentLocale.openExistingProject.title}\n </h2>\n <p class=\"text-body-regular-m\">\n {this.#componentLocale.openExistingProject.description}\n </p>\n </div>\n </header>\n <footer class=\"card__footer\">\n <button\n class=\"button-secondary cancel-btn\"\n onClick={this.#createKBClickHandler(true)}\n >\n {this.#componentLocale.openExistingProject.buttonCaption}\n </button>\n </footer>\n </article>\n </section>\n </section>\n <section class=\"section-secondary scrollable\">\n {this.loading ? (\n <gx-ide-loader\n class=\"loader\"\n loaderTitle={this.#componentLocale.recentKBs.loaderTitle}\n description={this.#componentLocale.recentKBs.loaderDescription}\n show\n ></gx-ide-loader>\n ) : (\n this.#evaluateContentToRender()\n )}\n </section>\n </main>\n </Host>\n );\n }\n}\n\nexport type RecentKBData = {\n id?: string;\n name: string;\n lastOpenedDate?: Date;\n icon: string;\n};\n\nexport type SecondarySection = {\n title: string;\n cards: CardInfo[];\n};\n\nexport type CardInfo = {\n icon?: {\n src: string;\n ariaLabel: string;\n };\n title: string;\n description: string[];\n action?: {\n iconSrc: string;\n caption: string;\n callback?: () => void;\n };\n};\n\ntype LanguageMap = {\n \"en\": LocaleDateFns;\n \"ja\": LocaleDateFns;\n \"zh-CN\": LocaleDateFns;\n \"zh-TW\": LocaleDateFns;\n \"zh-HK\": LocaleDateFns;\n};\n"]}
1
+ {"version":3,"file":"start-page.js","sourceRoot":"","sources":["../../../src/components/start-page/start-page.tsx"],"names":[],"mappings":";;;;;;;;;;;;AAAA,UAAU;AACV,OAAO,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC,EAAE,IAAI,EAAE,KAAK,EAAE,OAAO,EAAE,KAAK,EAAE,MAAM,eAAe,CAAC;AAChF,kBAAkB;AAClB,OAAO,EAAkB,WAAW,EAAE,MAAM,kBAAkB,CAAC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KAAK,CAC7C;oCACL,SAAG,KAAK,EAAC,qBAAqB,IAC3B,uBAAA,IAAI,uCAAiB,CAAC,mBAAmB,CAAC,WAAW,CACpD,CACA,CACC;4BACT,cAAQ,KAAK,EAAC,cAAc;gCAC1B,cACE,KAAK,EAAC,6BAA6B,EACnC,OAAO,EAAE,uBAAA,IAAI,4CAAsB,MAA1B,IAAI,EAAuB,IAAI,CAAC,IAExC,uBAAA,IAAI,uCAAiB,CAAC,mBAAmB,CAAC,aAAa,CACjD,CACF,CACD,CACF,CACF;gBACV,eAAS,KAAK,EAAC,8BAA8B,IAC1C,IAAI,CAAC,OAAO,CAAC,CAAC,CAAC,CACd,qBACE,KAAK,EAAC,QAAQ,EACd,WAAW,EAAE,uBAAA,IAAI,uCAAiB,CAAC,SAAS,CAAC,WAAW,EACxD,WAAW,EAAE,uBAAA,IAAI,uCAAiB,CAAC,SAAS,CAAC,iBAAiB,EAC9D,IAAI,SACW,CAClB,CAAC,CAAC,CAAC,CACF,uBAAA,IAAI,0EAAyB,MAA7B,IAAI,CAA2B,CAChC,CACO,CACL,CACF,CACR,CAAC;IACJ,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF;;IAzJG,OAAO,IAAI,CAAC,GAAG,IAAI,IAAI,CAAC,GAAG,CAAC,MAAM,GAAG,CAAC;QACpC,CAAC,CAAC,uBAAA,IAAI,wCAAkB,MAAtB,IAAI,CAAoB;QAC1B,CAAC,CAAC,uBAAA,IAAI,8CAAwB,MAA5B,IAAI,CAA0B,CAAC;AACrC,CAAC","sourcesContent":["// Stencil\nimport { Component, Host, h, Prop, State, Element, Watch } from \"@stencil/core\";\n// Other Libraries\nimport { MercuryBundles, getIconPath } from \"@genexus/mercury\";\nimport { formatDistanceToNow, Locale as LocaleDateFns } from \"date-fns\";\nimport { ja, zhCN, enUS } from \"date-fns/locale\";\n// import { enUS } from \"date-fns/locale\";\nimport { ChEditCustomEvent } from \"@genexus/chameleon-controls-library\";\n// Custom\nimport { Locale } from \"../../common/locale\";\n\n// const locale = enUS; // use `zhCN` for Chinese, `ja` for Japanese, `enUS` for English\n\nconst LANGS_DATE_FNS_MAP: LanguageMap = {\n \"en\": enUS,\n \"ja\": ja,\n \"zh-CN\": zhCN,\n \"zh-TW\": zhCN,\n \"zh-HK\": zhCN\n};\n\nconst DETAIL_ICON = getIconPath({\n category: \"system\",\n name: \"detail\",\n colorType: \"primary\"\n});\nconst FILTER_ICON = getIconPath({\n category: \"window-tools\",\n name: \"filter\",\n colorType: \"on-elevation\"\n});\nconst KB_DEFAULT_ICON = getIconPath({\n category: \"objects\",\n name: \"knowledge-base\"\n});\nconst SEARCH_ICON = getIconPath({\n category: \"system\",\n name: \"search\",\n colorType: \"on-elevation\"\n});\n\nconst CSS_BUNDLES: MercuryBundles = [\n \"resets/box-sizing\",\n \"utils/typography\",\n \"utils/layout\",\n \"components/edit\",\n \"components/icon\",\n \"components/button\",\n \"chameleon/scrollbar\",\n \"utils/typography\"\n];\n\n@Component({\n tag: \"gx-ide-start-page\",\n styleUrl: \"start-page.scss\",\n shadow: true,\n assetsDirs: [\"gx-ide-assets/start-page\"]\n})\nexport class GxIdeStartPage {\n /**\n * The component hard-coded strings translations.\n */\n // eslint-disable-next-line @stencil-community/own-props-must-be-private\n #componentLocale: any;\n #userLanguage: LocaleDateFns;\n\n @Element() el: HTMLGxIdeStartPageElement;\n\n @State() kbFilterValue: string = \"\";\n @Watch(\"kbFilterValue\")\n kbFilterValueChanged(newKbFilterValue: string) {\n this.filteredKbs = this.kbs.filter(kb =>\n kb.name.toLowerCase().includes(newKbFilterValue.toLocaleLowerCase())\n );\n }\n\n /**\n * The kbs after the filter value.\n */\n @State() filteredKbs: RecentKBData[];\n\n /**\n * True if the start page is waiting, either for the kb's list or the secondary section.\n */\n @State() loading: boolean = true;\n\n /**\n * Callback invoked to create a new KB. It must be specified whether this create is create from server or not, through the parameter 'fromServer'.\n */\n @Prop() readonly createKBCallback!: (fromServer: boolean) => Promise<void>;\n\n /**\n * Callback invoked to open a KB when the user clicks on a KB card.\n */\n @Prop() readonly openKbCallback!: (id: string) => Promise<void>;\n\n /**\n * The secondary section that will appear below the \"Create a new Knowledge Base\" main section. This section will be displayed if there are no recent kbs.\n */\n @Prop() readonly secondarySection?: SecondarySection;\n\n /**\n * User's kbs array\n */\n @Prop() readonly kbs: RecentKBData[];\n @Watch(\"kbs\")\n kbsChanged(newKbs: RecentKBData[]) {\n this.filteredKbs = newKbs;\n this.kbFilterValue = \"\"; // clear filter\n }\n\n /**\n * The minimum required of kbs to display a filter.\n */\n @Prop() readonly kbsFilterThreshold: number;\n\n async componentWillLoad() {\n this.#componentLocale = await Locale.getComponentStrings(this.el);\n\n // initialize filteredKbs\n this.kbsChanged(this.kbs);\n\n // get user language to display the kb \"last opened\" value in the appropriate language.\n const userLanguage: keyof LanguageMap = document.documentElement\n .lang as keyof LanguageMap;\n this.#userLanguage = LANGS_DATE_FNS_MAP[userLanguage];\n }\n\n #createKBClickHandler = (fromServer: boolean) => (event: MouseEvent) => {\n event.stopPropagation();\n this.createKBCallback(fromServer);\n };\n\n #openKbClickHandler = (kbId: string) => (event: MouseEvent) => {\n event.stopPropagation();\n this.openKbCallback(kbId);\n };\n\n #filterKbs = (event: ChEditCustomEvent<string> | InputEvent) => {\n this.kbFilterValue = event.detail as string;\n };\n\n #renderKbsSection = () => {\n const hideKbsFilter = this.kbs.length < this.kbsFilterThreshold;\n const kbsListEmpty = this.filteredKbs.length === 0;\n let contentToRender: HTMLGxgIdeLoaderElement | HTMLElement[];\n\n // Evaluate what is the content to display.\n if (this.filteredKbs.length > 0) {\n contentToRender = this.#renderKbs();\n } else {\n // No kb has pass the filter. Display an empty-state.\n contentToRender = (\n <gx-ide-empty-state\n isAnimated\n stateIconSrc={FILTER_ICON}\n stateTitle={this.#componentLocale.recentKBs.noMatches}\n ></gx-ide-empty-state>\n );\n }\n\n return (\n <section class=\"section-kbs\">\n <header\n class={{\n \"section-kbs__header\": true\n }}\n >\n <h2 class=\"heading-3 section-kbs__title\">\n {this.#componentLocale.recentKBs.title}\n </h2>\n <ch-edit\n // Render always, and display or hide, ro prevent FOUC, and also prevent\n // the header block-size from growing a little bit when the input renders.\n value={this.kbFilterValue}\n class={{\n \"input\": true,\n \"section-kbs__filter--hidden\": hideKbsFilter\n }}\n startImgSrc={SEARCH_ICON}\n placeholder={this.#componentLocale.recentKBs.filterKbsPlaceholder}\n onInput={!hideKbsFilter && this.#filterKbs}\n disabled={hideKbsFilter}\n ></ch-edit>\n </header>\n\n <div\n class={{\n \"section-kbs__list\": true,\n \"section-kbs__list--empty\": kbsListEmpty,\n \"scrollable\": true\n }}\n >\n {this.filteredKbs.length > 0 ? this.#renderKbs() : contentToRender}\n </div>\n </section>\n );\n };\n\n #renderKbs = (): HTMLElement[] => {\n return this.filteredKbs?.map((kb, index) => {\n // relative time ago\n\n const relativeDate = kb.lastOpenedDate\n ? formatDistanceToNow(new Date(kb.lastOpenedDate), {\n addSuffix: true,\n locale: this.#userLanguage\n })\n : undefined;\n\n // icon\n const kbIcon = kb.icon ?? KB_DEFAULT_ICON;\n\n return (\n <article class=\"kb__item\" key={index}>\n <div class=\"kb__details\">\n <ch-image class=\"icon-md\" src={kbIcon}></ch-image>\n <p\n class=\"text-body-regular-m kb__name\"\n onClick={this.#openKbClickHandler(kb.id)}\n >\n {kb.name}\n </p>\n </div>\n {relativeDate && (\n <div class=\"text-body-regular-m kb__modified\">\n {`${this.#componentLocale.recentKBs.opened} ${relativeDate}`}\n </div>\n )}\n </article>\n );\n });\n };\n\n #evaluateContentToRender() {\n return this.kbs && this.kbs.length > 0\n ? this.#renderKbsSection()\n : this.#renderSecondarySection();\n }\n\n #renderSecondarySection = (): HTMLElement | null => {\n if (!this.secondarySection) {\n return null;\n }\n\n const multipleCards = this.secondarySection.cards.length > 2;\n\n return (\n <section\n // Recent Knowledge Bases\n class=\"section-secondary\"\n >\n <header>\n <h2 class=\"heading-3\">{this.secondarySection.title}</h2>\n </header>\n\n <section\n class={{\n \"section-secondary__actions\": true,\n \"section-secondary__actions--two-cards\": !multipleCards,\n \"section-secondary__actions--multiple-cards\": multipleCards,\n \"scrollable\": true\n }}\n >\n {this.secondarySection.cards.map((card, index) => {\n return (\n <article class=\"card card-outlined\" key={index}>\n <header class=\"card__header\">\n <span class=\"icon-capsule\">\n <ch-image\n class=\"icon-md icon-circular\"\n src={card.icon.src}\n aria-label={card.icon.ariaLabel}\n ></ch-image>\n </span>\n <div class=\"card__header-description\">\n <h2 class=\"heading-3\">{card.title}</h2>\n {card.description.map(paragraph => (\n <p class=\"text-body-regular-m\">{paragraph}</p>\n ))}\n </div>\n </header>\n <footer class=\"card__footer\">\n {card.action && (\n <button\n class=\"button-tertiary button-icon-and-text\"\n onClick={card.action.callback && card.action.callback}\n >\n <ch-image class=\"icon-md\" src={DETAIL_ICON}></ch-image>\n {card.action.caption}\n </button>\n )}\n </footer>\n </article>\n );\n })}\n </section>\n </section>\n );\n };\n\n render() {\n this.loading =\n (!this.kbs || this.kbs?.length === 0) && !this.secondarySection;\n return (\n <Host class=\"widget scrollable spacing-body\">\n <ch-theme model={CSS_BUNDLES}></ch-theme>\n <main class=\"main scrollable\">\n <section\n // Create a new Knowledge Base\n class=\"section-create-new-kb\"\n >\n <header\n // main header\n class=\"section-create-new__header\"\n >\n <h1 class=\"heading-2\">{this.#componentLocale.createKB.title}</h1>\n <p class=\"text-body-regular-m\">\n {this.#componentLocale.createKB.description}\n </p>\n </header>\n\n <section class=\"section-create-new-kb__actions scrollable\">\n <article\n // create project\n class=\"card card-filled\"\n >\n <header class=\"card__header\">\n <div class=\"card__header-description\">\n <h2 class=\"heading-3\">\n {this.#componentLocale.createProject.title}\n </h2>\n <p class=\"text-body-regular-m\">\n {this.#componentLocale.createProject.description}\n </p>\n </div>\n </header>\n <footer class=\"card__footer\">\n <button\n class=\"button-primary\"\n onClick={this.#createKBClickHandler(false)}\n >\n {this.#componentLocale.createProject.buttonCaption}\n </button>\n </footer>\n </article>\n\n <article\n // open existing project\n class=\"card-filled\"\n >\n <header class=\"card__header\">\n <div class=\"card__header-description\">\n <h2 class=\"heading-3\">\n {this.#componentLocale.openExistingProject.title}\n </h2>\n <p class=\"text-body-regular-m\">\n {this.#componentLocale.openExistingProject.description}\n </p>\n </div>\n </header>\n <footer class=\"card__footer\">\n <button\n class=\"button-secondary cancel-btn\"\n onClick={this.#createKBClickHandler(true)}\n >\n {this.#componentLocale.openExistingProject.buttonCaption}\n </button>\n </footer>\n </article>\n </section>\n </section>\n <section class=\"section-secondary scrollable\">\n {this.loading ? (\n <gx-ide-loader\n class=\"loader\"\n loaderTitle={this.#componentLocale.recentKBs.loaderTitle}\n description={this.#componentLocale.recentKBs.loaderDescription}\n show\n ></gx-ide-loader>\n ) : (\n this.#evaluateContentToRender()\n )}\n </section>\n </main>\n </Host>\n );\n }\n}\n\nexport type RecentKBData = {\n id?: string;\n name: string;\n lastOpenedDate?: Date;\n icon: string;\n};\n\nexport type SecondarySection = {\n title: string;\n cards: CardInfo[];\n};\n\nexport type CardInfo = {\n icon?: {\n src: string;\n ariaLabel: string;\n };\n title: string;\n description: string[];\n action?: {\n iconSrc: string;\n caption: string;\n callback?: () => void;\n };\n};\n\ntype LanguageMap = {\n \"en\": LocaleDateFns;\n \"ja\": LocaleDateFns;\n \"zh-CN\": LocaleDateFns;\n \"zh-TW\": LocaleDateFns;\n \"zh-HK\": LocaleDateFns;\n};\n"]}
@@ -115,22 +115,8 @@
115
115
  padding: 0;
116
116
  margin: 0;
117
117
  }
118
- .slide__list-item {
119
- position: relative;
120
- padding-inline-start: 24px;
121
- }
122
- .slide__list-item::before {
123
- content: "";
124
- display: inline-block;
125
- inline-size: var(--mer-spacing--sm);
126
- block-size: var(--mer-spacing--sm);
127
- border: var(--mer-border__width--sm) solid var(--mer-color__tinted-primary--50);
128
- border-radius: 50%;
129
- background-color: var(--mer-color__tinted-primary--10);
130
- margin-inline-end: var(--mer-spacing--sm);
131
- position: absolute;
132
- inset-inline-start: 0;
133
- inset-block-start: 6px;
118
+ .slide__list-item-title {
119
+ font-weight: var(--mer-font__weight--medium);
134
120
  }
135
121
  .slide__word {
136
122
  transition: var(--mer-timing--regular) opacity;
@@ -150,7 +150,7 @@ export class GxIdeWelcomePage {
150
150
  ? __classPrivateFieldGet(this, _GxIdeWelcomePage_splitWords, "f").call(this, paragraph)
151
151
  : paragraph));
152
152
  }), ((_b = slide.listItems) === null || _b === void 0 ? void 0 : _b.length) && (h("ul", { class: "slide__list" }, slide.listItems.map(item => {
153
- return h("li", { class: "slide__list-item" }, item);
153
+ return (h("li", { class: "slide__list-item" }, h("strong", { class: "slide__list-item-title" }, item.title), " ", item.description));
154
154
  })))), isLastSlide && (h("button", { class: "button-primary start-button", onClick: __classPrivateFieldGet(this, _GxIdeWelcomePage_closeSlider, "f") }, __classPrivateFieldGet(this, _GxIdeWelcomePage_componentLocale, "f").startButtonCaption))))));
155
155
  }), "f");
156
156
  });
@@ -1 +1 @@
1
- {"version":3,"file":"welcome-page.js","sourceRoot":"","sources":["../../../src/components/welcome-page/welcome-page.tsx"],"names":[],"mappings":";;;;;;;;;;;;AAAA,UAAU;AACV,OAAO,EACL,SAAS,EACT,IAAI,EACJ,CAAC,EACD,IAAI,EACJ,OAAO,EACP,KAAK,EACL,YAAY,EACb,MAAM,eAAe,CAAC;AACvB,kBAAkB;AAClB,OAAO,EAAkB,WAAW,EAAE,MAAM,kBAAkB,CAAC;AAE/D,iBAAiB;AACjB,OAAO,EAAE,MAAM,EAAE,MAAM,qBAAqB,CAAC;AAE7C,MAAM,qBAAqB,GAAG,QAAQ,CAAC;AACvC,MAAM,cAAc,GAAG,WAAW,CAAC;AACnC,MAAM,eAAe,GAAG,YAAY,CAAC;AACrC,MAAM,UAAU,GAAG,QAAQ,CAAC;AAC5B,MAAM,mBAAmB,GAA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BACL,eAAe,EAAE,IAAI;4BACrB,0BAA0B,EAAE,IAAI,CAAC,gBAAgB;yBAClD;wBAED,WACE,KAAK,EAAE;gCACL,uBAAuB,EAAE,IAAI;gCAC7B,8BAA8B,EAAE,IAAI,CAAC,gBAAgB;6BACtD;4BAED,UAAI,KAAK,EAAC,aAAa,gBAAY,kBAAkB,IAClD,IAAI,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,KAAK,EAAE,EAAE;gCAC5B,OAAO,CACL,UACE,KAAK,EAAE;wCACL,YAAY,EAAE,IAAI;wCAClB,qBAAqB,EAAE,IAAI,CAAC,kBAAkB;wCAC9C,CAAC,qBAAqB,CAAC,EACrB,KAAK,KAAK,IAAI,CAAC,gBAAgB;qCAClC,gBACW,KAAK,EACjB,OAAO,EACL,CAAC,IAAI,CAAC,kBAAkB,IAAI,uBAAA,IAAI,2CAAmB,GAEjD,CACP,CAAC;4BACJ,CAAC,CAAC,CACC,CACD,CACC,CACD,CACN,CACD,CACR,CAAC;IACJ,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["// Stencil\nimport {\n Component,\n Host,\n h,\n Prop,\n Element,\n State,\n getAssetPath\n} from \"@stencil/core\";\n// Other Libraries\nimport { MercuryBundles, getIconPath } from \"@genexus/mercury\";\n\n// Custom Imports\nimport { Locale } from \"../../common/locale\";\n\nconst ACTIVE_SLIDE_SELECTOR = \"active\";\nconst ARROW_LEFT_KEY = \"ArrowLeft\";\nconst ARROW_RIGHT_KEY = \"ArrowRight\";\nconst ESCAPE_KEY = \"Escape\";\nconst SLIDE_FADE_DURATION = 300;\nconst SLIDE_WORD_SELECTOR = \".slide__word\";\nconst SLIDE_WORD_SELECTOR_TIMEOUT = 70;\nconst SLIDE_WORD_SELECTOR_VISIBLE = \"slide__word--visible\";\n\n// icons\nconst ICON_NEXT = getAssetPath(\n `./gx-ide-assets/welcome-page/images/icon-next.svg`\n);\nconst CLOSE_ICON = getIconPath({\n category: \"system\",\n name: \"close\",\n colorType: \"on-elevation\"\n});\n\nconst CSS_BUNDLES: MercuryBundles = [\n \"resets/box-sizing\",\n \"utils/typography\",\n \"components/icon\",\n \"components/button\"\n];\n\n@Component({\n tag: \"gx-ide-welcome-page\",\n styleUrl: \"welcome-page.scss\",\n shadow: true,\n assetsDirs: [\"gx-ide-assets/welcome-page\"]\n})\nexport class GxIdeWelcomePage {\n /**\n * The component hard-coded strings translations.\n */\n // eslint-disable-next-line @stencil-community/own-props-must-be-private\n #componentLocale: any;\n\n #slidesDescriptionAsChunksAlreadyDisplayed: Map<number, boolean> = new Map();\n #slidesElements: HTMLElement[] = [];\n #slidesElementsRef: HTMLElement[] = [];\n // #slidesDescriptionAsChunksAlreadyDisplayed is used to know if the description of a slide\n // that is set to be displayed as chunks, has already been displayed. Used to not display\n // as chunks after the first time.\n #slideTimeOutId: NodeJS.Timeout;\n\n @Element() el: HTMLGxIdeWelcomePageElement;\n\n /**\n * The current active slide index from 'slides' Prop. It does not considers the very first slide \"Copyright\".\n */\n @State() activeSlideIndex: number = 0;\n\n /**\n * When true the slider will be visible. Used to display and hide the slide with a smooth transition.\n */\n @State() displaySlider: boolean = false;\n\n /**\n * True if the very first slide is visible (The copyright slide)\n */\n @State() copyrightsVisible: boolean = true;\n\n /**\n * True if the user has reached the last slide. Used to hide/disable the navigation.\n */\n @State() lastSlideReached: boolean = false;\n\n /**\n * When true the slider will be visible. Used to display and hide the slider with a smooth transition.\n */\n @State() sliderVisible: boolean = false;\n\n /**\n * True if a slide is transitioning, false otherwise. Used to disable the navigation arrows while transitioning.\n */\n @State() slideTransitioning: boolean = false;\n\n /**\n * True if the user has changed slides by clicking on the navigation dots, or by using the keyboard arrows. This is used to know evaluate the slide transition setTimeOut. If the user has navigated, automatic slide transition should be turned off.\n */\n @State() userHasChangedSlide: boolean = false;\n\n /**\n * The transition type between the slides. \"static\" requires the user to navigate by clicking the navigation dots. \"auto\" will transition automatically after a calculated amount of time.\n */\n @Prop() readonly transitionType: TransitionType = \"auto\";\n\n /**\n * The estimated amount of words per minute that the user requires to read a slide. This value is used to return the time each slide is freezed before transitioning to the next one. Only evaluated when transitionType is set to \"auto\".\n */\n @Prop() readonly wordsPerMinute: number = 250;\n\n /**\n * Callback invoked when the user closes the slider by pressing the close button.\n */\n @Prop() readonly closeCallback!: CloseCallback;\n\n /**\n * 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.\n */\n @Prop() readonly slides: SlideInfo[] = [];\n\n async componentWillLoad() {\n this.#componentLocale = await Locale.getComponentStrings(this.el);\n this.#renderSlides();\n }\n\n componentDidLoad() {\n this.#slidesElementsRef[this.activeSlideIndex].classList.add(\n ACTIVE_SLIDE_SELECTOR\n );\n this.sliderVisible = true;\n this.#initiateSlidesTransition();\n }\n\n #closeSlider = () => {\n this.sliderVisible = false;\n setTimeout(() => {\n // wait until the slide disappears, then remove.\n this.el.remove();\n this.closeCallback();\n document.removeEventListener(\"keydown\", this.#keyboardEventHandler);\n }, SLIDE_FADE_DURATION);\n };\n\n #initiateSlidesTransition = () => {\n this.#slideTimeOut();\n // listen to keydown events to navigate the slides with the arrows\n document.addEventListener(\"keydown\", this.#keyboardEventHandler);\n };\n\n #displayWords = (wordsNodeList: NodeListOf<HTMLElement>) => {\n wordsNodeList.forEach((word, index) => {\n setTimeout(() => {\n word.classList.add(SLIDE_WORD_SELECTOR_VISIBLE);\n }, index * SLIDE_WORD_SELECTOR_TIMEOUT);\n });\n };\n\n #dotClickedHandler = (event: MouseEvent) => {\n this.userHasChangedSlide = true;\n const itemClicked = event.currentTarget as HTMLElement;\n const index = parseInt(itemClicked.getAttribute(\"data-index\"), 10);\n this.#updateActiveSlide(index);\n };\n\n #keyboardEventHandler = (event: KeyboardEvent) => {\n this.userHasChangedSlide = true;\n const goToPrevSlide =\n event.key === ARROW_LEFT_KEY &&\n !this.slideTransitioning &&\n !this.lastSlideReached &&\n this.activeSlideIndex !== 0;\n\n const goToNextSlide =\n event.key === ARROW_RIGHT_KEY &&\n !this.slideTransitioning &&\n !this.lastSlideReached;\n\n const closeSlider =\n event.key === ESCAPE_KEY ||\n (event.key === ARROW_RIGHT_KEY &&\n !this.slideTransitioning &&\n this.lastSlideReached);\n\n if (goToNextSlide) {\n this.#nextSlideHandler();\n } else if (goToPrevSlide) {\n this.#prevSlideHandler();\n } else if (closeSlider) {\n this.#closeSlider();\n }\n };\n\n #nextSlideHandler = () => {\n const newIndex = this.activeSlideIndex + 1;\n this.#updateActiveSlide(newIndex);\n };\n\n #prevSlideHandler = () => {\n const newIndex = this.activeSlideIndex - 1;\n this.#updateActiveSlide(newIndex);\n };\n\n #slideTimeOut = () => {\n // Clear any existing timeout\n if (this.#slideTimeOutId) {\n clearTimeout(this.#slideTimeOutId);\n }\n\n const autoChangeSlide =\n this.transitionType === \"auto\" &&\n !this.lastSlideReached &&\n !this.userHasChangedSlide;\n\n if (!autoChangeSlide) {\n return;\n }\n\n const mergedDescription =\n this.slides[this.activeSlideIndex].description.join(\"\");\n const words = mergedDescription.split(\" \").length;\n const timeBeforeNextSlide: number = this.#secondsToRead(words);\n\n // Set a fresh timeout\n if (timeBeforeNextSlide) {\n this.#slideTimeOutId = setTimeout(() => {\n this.#nextSlideHandler();\n }, timeBeforeNextSlide);\n }\n };\n\n #secondsToRead = (\n wordsCount: number,\n wordsPerMinute = this.wordsPerMinute\n ): number => {\n const minutes = wordsCount / wordsPerMinute;\n const milliseconds = minutes * 60000; // Convert minutes to milliseconds\n return milliseconds;\n };\n\n #renderSlides = () => {\n this.#slidesElements = this.slides.map((slide, index) => {\n const isLastSlide = index === this.slides.length - 1;\n return (\n <section\n class=\"slide__wrapper\"\n ref={(el: HTMLElement) =>\n (this.#slidesElementsRef[index] = el as HTMLElement)\n }\n >\n <div\n class=\"slide__illustration\"\n role=\"img\"\n aria-label={this.#componentLocale.copyright.illustrationAriaLabel}\n >\n <img\n class=\"slide__illustration-img\"\n src={slide.illustration.url}\n alt={slide.illustration.alt}\n />\n </div>\n <section class=\"slide__copy\">\n <div class=\"slide__copy-container\">\n <header class=\"slide__copy-header\">\n <img src={ICON_NEXT} alt=\"GeneXus Next isologotype\" />\n <h2 class=\"slide__copy-title\">{slide.title}</h2>\n </header>\n <div class=\"slide__copy-description\">\n {slide.description?.map(paragraph => {\n return (\n <p>\n {slide.descriptionAsChunks\n ? this.#splitWords(paragraph)\n : paragraph}\n </p>\n );\n })}\n {slide.listItems?.length && (\n <ul class=\"slide__list\">\n {slide.listItems.map(item => {\n return <li class=\"slide__list-item\">{item}</li>;\n })}\n </ul>\n )}\n </div>\n {isLastSlide && (\n <button\n class=\"button-primary start-button\"\n onClick={this.#closeSlider}\n >\n {this.#componentLocale.startButtonCaption}\n </button>\n )}\n </div>\n </section>\n </section>\n );\n });\n };\n\n #splitWords = (paragraph: string): HTMLSpanElement[] => {\n return paragraph.split(\" \").map(word => {\n // keep the space after {word} !\n return <span class=\"slide__word\">{word} </span>;\n });\n };\n\n #updateActiveSlide = (newSlideIndex: number) => {\n if (this.lastSlideReached) {\n return;\n }\n this.slideTransitioning = true;\n\n // unset current active slide\n const activeSlide = this.#slidesElementsRef[this.activeSlideIndex];\n activeSlide.classList.remove(ACTIVE_SLIDE_SELECTOR);\n\n const nextSlideReference = this.#slidesElementsRef[newSlideIndex];\n const displayDescriptionAsChunks =\n this.slides[newSlideIndex].descriptionAsChunks;\n const descriptionAsChunksDisplayedAlready =\n this.#slidesDescriptionAsChunksAlreadyDisplayed.get(newSlideIndex);\n let wordsCount;\n let wordsNodeList: NodeListOf<HTMLElement>;\n let slideTimeOut = 0;\n if (displayDescriptionAsChunks) {\n wordsNodeList = nextSlideReference.querySelectorAll(SLIDE_WORD_SELECTOR);\n wordsCount = wordsNodeList.length;\n slideTimeOut = wordsCount * SLIDE_WORD_SELECTOR_TIMEOUT;\n }\n\n this.lastSlideReached = newSlideIndex === this.slides.length - 1;\n\n // set new slide as active after fade out\n setTimeout(() => {\n nextSlideReference.classList.add(ACTIVE_SLIDE_SELECTOR);\n\n if (displayDescriptionAsChunks && !descriptionAsChunksDisplayedAlready) {\n this.#slidesDescriptionAsChunksAlreadyDisplayed.set(\n newSlideIndex,\n true\n );\n this.#displayWords(wordsNodeList);\n setTimeout(() => {\n this.slideTransitioning = false;\n }, slideTimeOut);\n } else {\n this.slideTransitioning = false;\n }\n }, SLIDE_FADE_DURATION);\n\n // update active slide index\n this.activeSlideIndex = newSlideIndex;\n this.#slideTimeOut(); // this has to be after this.#updateActiveSlide.\n };\n\n render() {\n return (\n <Host>\n <ch-theme model={CSS_BUNDLES}></ch-theme>\n <div\n class={{\n \"main\": true,\n \"main--visible\": this.sliderVisible,\n \"main--border-glow\": this.lastSlideReached\n }}\n style={{ \"--slide-fade-duration\": `${SLIDE_FADE_DURATION}ms` }}\n >\n <section class=\"slide\">\n <header class=\"slide__header\">\n <button\n class=\"button-tertiary button-icon-only close-icon\"\n aria-label=\"close presentation\"\n onClick={this.#closeSlider}\n >\n <ch-image class=\"icon-md\" src={CLOSE_ICON}></ch-image>\n </button>\n </header>\n <div class=\"slide__container\">{this.#slidesElements}</div>\n <footer\n // slide common footer\n class={{\n \"slide__footer\": true,\n \"slide__footer-last-slide\": this.lastSlideReached\n }}\n >\n <div\n class={{\n \"slide__footer-wrapper\": true,\n \"slide__footer-wrapper-hidden\": this.lastSlideReached\n }}\n >\n <ul class=\"slide__dots\" aria-label=\"Slide indicators\">\n {this.slides.map((_, index) => {\n return (\n <li\n class={{\n \"slide__dot\": true,\n \"slide__dot-inactive\": this.slideTransitioning,\n [ACTIVE_SLIDE_SELECTOR]:\n index === this.activeSlideIndex\n }}\n data-index={index}\n onClick={\n !this.slideTransitioning && this.#dotClickedHandler\n }\n ></li>\n );\n })}\n </ul>\n </div>\n </footer>\n </section>\n </div>\n </Host>\n );\n }\n}\n\nexport type SlideInfo = {\n illustration: {\n url: string;\n alt: string;\n };\n title: string;\n description?: string[];\n descriptionAsChunks?: boolean;\n listItems?: string[];\n};\n\nexport type CloseCallback = () => Promise<void>;\nexport type TransitionType = \"static\" | \"auto\";\n"]}
1
+ {"version":3,"file":"welcome-page.js","sourceRoot":"","sources":["../../../src/components/welcome-page/welcome-page.tsx"],"names":[],"mappings":";;;;;;;;;;;;AAAA,UAAU;AACV,OAAO,EACL,SAAS,EACT,IAAI,EACJ,CAAC,EACD,IAAI,EACJ,OAAO,EACP,KAAK,EACL,YAAY,EACb,MAAM,eAAe,CAAC;AACvB,kBAAkB;AAClB,OAAO,EAAkB,WAAW,EAAE,MAAM,kBAAkB,CAAC;AAE/D,iBAAiB;AACjB,OAAO,EAAE,MAAM,EAAE,MAAM,qBAAqB,CAAC;AAE7C,MAAM,qBAAqB,GAAG,QAAQ,CAAC;AACvC,MAAM,cAAc,GAAG,WAAW,CAAC;AACnC,MAAM,eAAe,GAAG,YAAY,CAAC;AACrC,MAAM,UAAU,GAAG,QAAQ,CAAC;AAC5B,MAAM,mBAAmB,GAAG,GAAG,CAAC;AAChC,MAAM,mBAAmB,GAAG,cAAc,CAAC;AAC3C,MAAM,2BAA2B,GAAG,EAAE,CAAC;AACvC,MAAM,2BAA2B,GAAG,sBAAsB,CAAC;AAE3D,QAAQ;AACR,MAAM,SAAS,GAAG,YAAY,CAC5B,mDAAmD,CACpD,CAAC;AACF,MAAM,UAAU,GAAG,WAAW,CAAC;IAC7B,QAAQ,EAAE,QAAQ;IAClB,IAAI,EAAE,OAAO;IACb,SAAS,EAAE,cAAc;CAC1B,CAAC,CAAC;AAEH,MAAM,WAAW,GAAmB;IAClC,mBAAmB;IACnB,kBAAkB;IAClB,iBAAiB;IACjB,mBAAmB;CACpB,CAAC;AAQF,MAAM,OAAO,gBAAgB;;QAC3B;;WAEG;QACH,wEAAwE;QACxE,oDAAsB;QAEtB,sEAAmE,IAAI,GAAG,EAAE,EAAC;QAC7E,2CAAiC,EAAE,EAA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B;qCAClC,gBACW,KAAK,EACjB,OAAO,EACL,CAAC,IAAI,CAAC,kBAAkB,IAAI,uBAAA,IAAI,2CAAmB,GAEjD,CACP,CAAC;4BACJ,CAAC,CAAC,CACC,CACD,CACC,CACD,CACN,CACD,CACR,CAAC;IACJ,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["// Stencil\nimport {\n Component,\n Host,\n h,\n Prop,\n Element,\n State,\n getAssetPath\n} from \"@stencil/core\";\n// Other Libraries\nimport { MercuryBundles, getIconPath } from \"@genexus/mercury\";\n\n// Custom Imports\nimport { Locale } from \"../../common/locale\";\n\nconst ACTIVE_SLIDE_SELECTOR = \"active\";\nconst ARROW_LEFT_KEY = \"ArrowLeft\";\nconst ARROW_RIGHT_KEY = \"ArrowRight\";\nconst ESCAPE_KEY = \"Escape\";\nconst SLIDE_FADE_DURATION = 300;\nconst SLIDE_WORD_SELECTOR = \".slide__word\";\nconst SLIDE_WORD_SELECTOR_TIMEOUT = 70;\nconst SLIDE_WORD_SELECTOR_VISIBLE = \"slide__word--visible\";\n\n// icons\nconst ICON_NEXT = getAssetPath(\n `./gx-ide-assets/welcome-page/images/icon-next.svg`\n);\nconst CLOSE_ICON = getIconPath({\n category: \"system\",\n name: \"close\",\n colorType: \"on-elevation\"\n});\n\nconst CSS_BUNDLES: MercuryBundles = [\n \"resets/box-sizing\",\n \"utils/typography\",\n \"components/icon\",\n \"components/button\"\n];\n\n@Component({\n tag: \"gx-ide-welcome-page\",\n styleUrl: \"welcome-page.scss\",\n shadow: true,\n assetsDirs: [\"gx-ide-assets/welcome-page\"]\n})\nexport class GxIdeWelcomePage {\n /**\n * The component hard-coded strings translations.\n */\n // eslint-disable-next-line @stencil-community/own-props-must-be-private\n #componentLocale: any;\n\n #slidesDescriptionAsChunksAlreadyDisplayed: Map<number, boolean> = new Map();\n #slidesElements: HTMLElement[] = [];\n #slidesElementsRef: HTMLElement[] = [];\n // #slidesDescriptionAsChunksAlreadyDisplayed is used to know if the description of a slide\n // that is set to be displayed as chunks, has already been displayed. Used to not display\n // as chunks after the first time.\n #slideTimeOutId: NodeJS.Timeout;\n\n @Element() el: HTMLGxIdeWelcomePageElement;\n\n /**\n * The current active slide index from 'slides' Prop. It does not considers the very first slide \"Copyright\".\n */\n @State() activeSlideIndex: number = 0;\n\n /**\n * When true the slider will be visible. Used to display and hide the slide with a smooth transition.\n */\n @State() displaySlider: boolean = false;\n\n /**\n * True if the very first slide is visible (The copyright slide)\n */\n @State() copyrightsVisible: boolean = true;\n\n /**\n * True if the user has reached the last slide. Used to hide/disable the navigation.\n */\n @State() lastSlideReached: boolean = false;\n\n /**\n * When true the slider will be visible. Used to display and hide the slider with a smooth transition.\n */\n @State() sliderVisible: boolean = false;\n\n /**\n * True if a slide is transitioning, false otherwise. Used to disable the navigation arrows while transitioning.\n */\n @State() slideTransitioning: boolean = false;\n\n /**\n * True if the user has changed slides by clicking on the navigation dots, or by using the keyboard arrows. This is used to know evaluate the slide transition setTimeOut. If the user has navigated, automatic slide transition should be turned off.\n */\n @State() userHasChangedSlide: boolean = false;\n\n /**\n * The transition type between the slides. \"static\" requires the user to navigate by clicking the navigation dots. \"auto\" will transition automatically after a calculated amount of time.\n */\n @Prop() readonly transitionType: TransitionType = \"auto\";\n\n /**\n * The estimated amount of words per minute that the user requires to read a slide. This value is used to return the time each slide is freezed before transitioning to the next one. Only evaluated when transitionType is set to \"auto\".\n */\n @Prop() readonly wordsPerMinute: number = 250;\n\n /**\n * Callback invoked when the user closes the slider by pressing the close button.\n */\n @Prop() readonly closeCallback!: CloseCallback;\n\n /**\n * 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.\n */\n @Prop() readonly slides: SlideInfo[] = [];\n\n async componentWillLoad() {\n this.#componentLocale = await Locale.getComponentStrings(this.el);\n this.#renderSlides();\n }\n\n componentDidLoad() {\n this.#slidesElementsRef[this.activeSlideIndex].classList.add(\n ACTIVE_SLIDE_SELECTOR\n );\n this.sliderVisible = true;\n this.#initiateSlidesTransition();\n }\n\n #closeSlider = () => {\n this.sliderVisible = false;\n setTimeout(() => {\n // wait until the slide disappears, then remove.\n this.el.remove();\n this.closeCallback();\n document.removeEventListener(\"keydown\", this.#keyboardEventHandler);\n }, SLIDE_FADE_DURATION);\n };\n\n #initiateSlidesTransition = () => {\n this.#slideTimeOut();\n // listen to keydown events to navigate the slides with the arrows\n document.addEventListener(\"keydown\", this.#keyboardEventHandler);\n };\n\n #displayWords = (wordsNodeList: NodeListOf<HTMLElement>) => {\n wordsNodeList.forEach((word, index) => {\n setTimeout(() => {\n word.classList.add(SLIDE_WORD_SELECTOR_VISIBLE);\n }, index * SLIDE_WORD_SELECTOR_TIMEOUT);\n });\n };\n\n #dotClickedHandler = (event: MouseEvent) => {\n this.userHasChangedSlide = true;\n const itemClicked = event.currentTarget as HTMLElement;\n const index = parseInt(itemClicked.getAttribute(\"data-index\"), 10);\n this.#updateActiveSlide(index);\n };\n\n #keyboardEventHandler = (event: KeyboardEvent) => {\n this.userHasChangedSlide = true;\n const goToPrevSlide =\n event.key === ARROW_LEFT_KEY &&\n !this.slideTransitioning &&\n !this.lastSlideReached &&\n this.activeSlideIndex !== 0;\n\n const goToNextSlide =\n event.key === ARROW_RIGHT_KEY &&\n !this.slideTransitioning &&\n !this.lastSlideReached;\n\n const closeSlider =\n event.key === ESCAPE_KEY ||\n (event.key === ARROW_RIGHT_KEY &&\n !this.slideTransitioning &&\n this.lastSlideReached);\n\n if (goToNextSlide) {\n this.#nextSlideHandler();\n } else if (goToPrevSlide) {\n this.#prevSlideHandler();\n } else if (closeSlider) {\n this.#closeSlider();\n }\n };\n\n #nextSlideHandler = () => {\n const newIndex = this.activeSlideIndex + 1;\n this.#updateActiveSlide(newIndex);\n };\n\n #prevSlideHandler = () => {\n const newIndex = this.activeSlideIndex - 1;\n this.#updateActiveSlide(newIndex);\n };\n\n #slideTimeOut = () => {\n // Clear any existing timeout\n if (this.#slideTimeOutId) {\n clearTimeout(this.#slideTimeOutId);\n }\n\n const autoChangeSlide =\n this.transitionType === \"auto\" &&\n !this.lastSlideReached &&\n !this.userHasChangedSlide;\n\n if (!autoChangeSlide) {\n return;\n }\n\n const mergedDescription =\n this.slides[this.activeSlideIndex].description.join(\"\");\n const words = mergedDescription.split(\" \").length;\n const timeBeforeNextSlide: number = this.#secondsToRead(words);\n\n // Set a fresh timeout\n if (timeBeforeNextSlide) {\n this.#slideTimeOutId = setTimeout(() => {\n this.#nextSlideHandler();\n }, timeBeforeNextSlide);\n }\n };\n\n #secondsToRead = (\n wordsCount: number,\n wordsPerMinute = this.wordsPerMinute\n ): number => {\n const minutes = wordsCount / wordsPerMinute;\n const milliseconds = minutes * 60000; // Convert minutes to milliseconds\n return milliseconds;\n };\n\n #renderSlides = () => {\n this.#slidesElements = this.slides.map((slide, index) => {\n const isLastSlide = index === this.slides.length - 1;\n return (\n <section\n class=\"slide__wrapper\"\n ref={(el: HTMLElement) =>\n (this.#slidesElementsRef[index] = el as HTMLElement)\n }\n >\n <div\n class=\"slide__illustration\"\n role=\"img\"\n aria-label={this.#componentLocale.copyright.illustrationAriaLabel}\n >\n <img\n class=\"slide__illustration-img\"\n src={slide.illustration.url}\n alt={slide.illustration.alt}\n />\n </div>\n <section class=\"slide__copy\">\n <div class=\"slide__copy-container\">\n <header class=\"slide__copy-header\">\n <img src={ICON_NEXT} alt=\"GeneXus Next isologotype\" />\n <h2 class=\"slide__copy-title\">{slide.title}</h2>\n </header>\n <div class=\"slide__copy-description\">\n {slide.description?.map(paragraph => {\n return (\n <p>\n {slide.descriptionAsChunks\n ? this.#splitWords(paragraph)\n : paragraph}\n </p>\n );\n })}\n {slide.listItems?.length && (\n <ul class=\"slide__list\">\n {slide.listItems.map(item => {\n return (\n <li class=\"slide__list-item\">\n <strong class=\"slide__list-item-title\">\n {item.title}\n </strong>{\" \"}\n {item.description}\n </li>\n );\n })}\n </ul>\n )}\n </div>\n {isLastSlide && (\n <button\n class=\"button-primary start-button\"\n onClick={this.#closeSlider}\n >\n {this.#componentLocale.startButtonCaption}\n </button>\n )}\n </div>\n </section>\n </section>\n );\n });\n };\n\n #splitWords = (paragraph: string): HTMLSpanElement[] => {\n return paragraph.split(\" \").map(word => {\n // keep the space after {word} !\n return <span class=\"slide__word\">{word} </span>;\n });\n };\n\n #updateActiveSlide = (newSlideIndex: number) => {\n if (this.lastSlideReached) {\n return;\n }\n this.slideTransitioning = true;\n\n // unset current active slide\n const activeSlide = this.#slidesElementsRef[this.activeSlideIndex];\n activeSlide.classList.remove(ACTIVE_SLIDE_SELECTOR);\n\n const nextSlideReference = this.#slidesElementsRef[newSlideIndex];\n const displayDescriptionAsChunks =\n this.slides[newSlideIndex].descriptionAsChunks;\n const descriptionAsChunksDisplayedAlready =\n this.#slidesDescriptionAsChunksAlreadyDisplayed.get(newSlideIndex);\n let wordsCount;\n let wordsNodeList: NodeListOf<HTMLElement>;\n let slideTimeOut = 0;\n if (displayDescriptionAsChunks) {\n wordsNodeList = nextSlideReference.querySelectorAll(SLIDE_WORD_SELECTOR);\n wordsCount = wordsNodeList.length;\n slideTimeOut = wordsCount * SLIDE_WORD_SELECTOR_TIMEOUT;\n }\n\n this.lastSlideReached = newSlideIndex === this.slides.length - 1;\n\n // set new slide as active after fade out\n setTimeout(() => {\n nextSlideReference.classList.add(ACTIVE_SLIDE_SELECTOR);\n\n if (displayDescriptionAsChunks && !descriptionAsChunksDisplayedAlready) {\n this.#slidesDescriptionAsChunksAlreadyDisplayed.set(\n newSlideIndex,\n true\n );\n this.#displayWords(wordsNodeList);\n setTimeout(() => {\n this.slideTransitioning = false;\n }, slideTimeOut);\n } else {\n this.slideTransitioning = false;\n }\n }, SLIDE_FADE_DURATION);\n\n // update active slide index\n this.activeSlideIndex = newSlideIndex;\n this.#slideTimeOut(); // this has to be after this.#updateActiveSlide.\n };\n\n render() {\n return (\n <Host>\n <ch-theme model={CSS_BUNDLES}></ch-theme>\n <div\n class={{\n \"main\": true,\n \"main--visible\": this.sliderVisible,\n \"main--border-glow\": this.lastSlideReached\n }}\n style={{ \"--slide-fade-duration\": `${SLIDE_FADE_DURATION}ms` }}\n >\n <section class=\"slide\">\n <header class=\"slide__header\">\n <button\n class=\"button-tertiary button-icon-only close-icon\"\n aria-label=\"close presentation\"\n onClick={this.#closeSlider}\n >\n <ch-image class=\"icon-md\" src={CLOSE_ICON}></ch-image>\n </button>\n </header>\n <div class=\"slide__container\">{this.#slidesElements}</div>\n <footer\n // slide common footer\n class={{\n \"slide__footer\": true,\n \"slide__footer-last-slide\": this.lastSlideReached\n }}\n >\n <div\n class={{\n \"slide__footer-wrapper\": true,\n \"slide__footer-wrapper-hidden\": this.lastSlideReached\n }}\n >\n <ul class=\"slide__dots\" aria-label=\"Slide indicators\">\n {this.slides.map((_, index) => {\n return (\n <li\n class={{\n \"slide__dot\": true,\n \"slide__dot-inactive\": this.slideTransitioning,\n [ACTIVE_SLIDE_SELECTOR]:\n index === this.activeSlideIndex\n }}\n data-index={index}\n onClick={\n !this.slideTransitioning && this.#dotClickedHandler\n }\n ></li>\n );\n })}\n </ul>\n </div>\n </footer>\n </section>\n </div>\n </Host>\n );\n }\n}\n\nexport type SlideInfo = {\n illustration: {\n url: string;\n alt: string;\n };\n title: string;\n description?: string[];\n descriptionAsChunks?: boolean;\n listItems?: Array<{\n title: string;\n description: string;\n }>;\n};\n\nexport type CloseCallback = () => Promise<void>;\nexport type TransitionType = \"static\" | \"auto\";\n"]}
@@ -1,28 +1,14 @@
1
1
  import { proxyCustomElement, HTMLElement, h } from '@stencil/core/internal/client';
2
+ import { L as Locale } from './locale.js';
2
3
  import { h as hiChar } from './helpers.js';
3
4
 
4
- const aiMessageCss = ":host{font-family:var(--mer-font-family--primary)}.message{color:var(--mer-color__neutral-gray--200);display:grid;grid-template-rows:0fr;transition:grid-template-rows 100ms;transition:grid-template-rows 100ms, -ms-grid-rows 100ms;}.message__outer-wrapper{overflow:hidden}.message__inner-wrapper{padding:var(--mer-spacing--2xs) var(--mer-spacing--xs);border-radius:var(--mer-border__radius--xs);border:var(--mer-border__width--sm) solid transparent;background-color:var(--mer-color__neutral-gray--1200);margin-block-start:var(--mer-spacing--xs)}.message__caption{font-size:var(--mer-font__size--2xs);line-height:var(--mer-line-height--comfortable);position:relative}.message--visible{grid-template-rows:1fr}.message--copying{pointer-events:none}.message--copying span:not(.copied),.message--copying .message__caption{color:transparent;-webkit-user-select:none;-ms-user-select:none;user-select:none;}.message--user .message__inner-wrapper{background-color:var(--mer-color__tint-blue--8)}.message--assistant-action .message__inner-wrapper{font-style:italic}.message--assistant-in-progress{color:var(--mer-color__neutral-gray--500)}.message--assistant-in-progress .message__inner-wrapper{font-style:italic;display:grid;grid-template-columns:1fr auto;gap:var(--mer-spacing--xs)}.message--assistant-in-progress .message__inner-wrapper .message__caption{overflow:hidden;white-space:nowrap;text-overflow:ellipsis;flex:1}.message--assistant-in-progress .message__inner-wrapper .animation-wrapper{flex:none}.message--assistant-error .message__inner-wrapper{background-color:var(--mer-color__tint-red--5);border-color:var(--mer-color__tint-red--60)}.message--copyable{cursor:pointer}.message:last-child{margin-block-end:0}:host(:first-child) .message__inner-wrapper{margin-block-end:0}.animation-wrapper{width:45px;display:flex;align-items:center;justify-content:center}.dot-pulse{position:relative;left:-9999px;width:5px;height:5px;border-radius:2.5px;background-color:var(--mer-color__neutral-gray--400);color:var(--mer-color__neutral-gray--400);box-shadow:9999px 0 0 -5px;animation:dot-pulse 1.5s infinite linear;animation-delay:0.25s}.dot-pulse::before,.dot-pulse::after{content:\"\";display:inline-block;position:absolute;top:0;width:5px;height:5px;border-radius:2.5px;background-color:var(--mer-color__neutral-gray--400);color:var(--mer-color__neutral-gray--400)}.dot-pulse::before{box-shadow:9984px 0 0 -5px;animation:dot-pulse-before 1.5s infinite linear;animation-delay:0s}.dot-pulse::after{box-shadow:10014px 0 0 -5px;animation:dot-pulse-after 1.5s infinite linear;animation-delay:0.5s}@keyframes dot-pulse-before{0%{box-shadow:9984px 0 0 -5px}30%{box-shadow:9984px 0 0 2px}60%,100%{box-shadow:9984px 0 0 -5px}}@keyframes dot-pulse{0%{box-shadow:9999px 0 0 -5px}30%{box-shadow:9999px 0 0 2px}60%,100%{box-shadow:9999px 0 0 -5px}}@keyframes dot-pulse-after{0%{box-shadow:10014px 0 0 -5px}30%{box-shadow:10014px 0 0 2px}60%,100%{box-shadow:10014px 0 0 -5px}}.copied{position:absolute;width:100%;height:100%;display:flex;align-items:center;justify-content:center;color:var(--mer-color__neutral-gray--300);display:flex;gap:var(--mer-spacing--2xs)}.hiChar{color:var(--mer-color__primary--200);filter:brightness(1.3)}";
5
+ const aiMessageCss = ":host{font-family:var(--mer-font-family--primary)}.message{color:var(--mer-color__neutral-gray--100);display:grid;grid-template-rows:0fr;transition:grid-template-rows 100ms;transition:grid-template-rows 100ms, -ms-grid-rows 100ms;}.message__outer-wrapper{overflow:hidden}.message__inner-wrapper{padding:var(--mer-spacing--sm) var(--mer-spacing--sm);border-radius:var(--mer-border__radius--sm);border-inline-start:var(--mer-border__width--md) solid transparent;background-color:var(--mer-color__neutral-gray--1200);margin-block-start:var(--mer-spacing--xs)}.message__role{display:inline-block;font-weight:var(--mer-font__weight--semi-bold);margin-block-end:var(--mer-spacing--xs);display:inline-grid;grid-template-columns:max-content max-content;gap:6px}.message__role:before{content:\"\";display:grid;place-self:center flex-end;inline-size:4px;block-size:4px;border-radius:50%;background-color:currentcolor}.message__role--user{color:var(--mer-color__primary--300)}.message__role--hidden{display:none}.message__caption{font-size:var(--mer-font__size--xs);line-height:var(--mer-line-height--regular);position:relative}.message--visible{grid-template-rows:1fr}.message--copying{pointer-events:none}.message--copying span:not(.copied),.message--copying .message__caption{color:transparent;-webkit-user-select:none;-ms-user-select:none;user-select:none;}.message--user .message__inner-wrapper{background-color:rgba(91, 167, 255, 0.08);border-color:var(--mer-border-color__primary)}.message--assistant-action .message__inner-wrapper{background-color:rgba(63, 168, 155, 0.05);border-color:var(--mer-border-color__success)}.message--assistant-chat .message__inner-wrapper{background-color:var(--mer-surface__elevation--01)}.message--assistant-in-progress{color:var(--mer-color__neutral-gray--500)}.message--assistant-in-progress .message__inner-wrapper{font-style:italic;display:grid;grid-template-columns:1fr auto;gap:var(--mer-spacing--xs)}.message--assistant-in-progress .message__inner-wrapper .message__caption{overflow:hidden;white-space:nowrap;text-overflow:ellipsis;flex:1}.message--assistant-in-progress .message__inner-wrapper .animation-wrapper{flex:none}.message--assistant-error .message__inner-wrapper{background-color:rgba(251, 124, 132, 0.05);border-color:var(--mer-border-color__error)}.message:last-child{margin-block-end:0}:host(:first-child) .message__inner-wrapper{margin-block-end:0}.animation-wrapper{width:45px;display:flex;align-items:center;justify-content:center}.dot-pulse{position:relative;left:-9999px;width:5px;height:5px;border-radius:2.5px;background-color:var(--mer-color__neutral-gray--400);color:var(--mer-color__neutral-gray--400);box-shadow:9999px 0 0 -5px;animation:dot-pulse 1.5s infinite linear;animation-delay:0.25s}.dot-pulse::before,.dot-pulse::after{content:\"\";display:inline-block;position:absolute;top:0;width:5px;height:5px;border-radius:2.5px;background-color:var(--mer-color__neutral-gray--400);color:var(--mer-color__neutral-gray--400)}.dot-pulse::before{box-shadow:9984px 0 0 -5px;animation:dot-pulse-before 1.5s infinite linear;animation-delay:0s}.dot-pulse::after{box-shadow:10014px 0 0 -5px;animation:dot-pulse-after 1.5s infinite linear;animation-delay:0.5s}@keyframes dot-pulse-before{0%{box-shadow:9984px 0 0 -5px}30%{box-shadow:9984px 0 0 2px}60%,100%{box-shadow:9984px 0 0 -5px}}@keyframes dot-pulse{0%{box-shadow:9999px 0 0 -5px}30%{box-shadow:9999px 0 0 2px}60%,100%{box-shadow:9999px 0 0 -5px}}@keyframes dot-pulse-after{0%{box-shadow:10014px 0 0 -5px}30%{box-shadow:10014px 0 0 2px}60%,100%{box-shadow:10014px 0 0 -5px}}.copied{position:absolute;width:100%;height:100%;display:flex;align-items:center;justify-content:center;color:var(--mer-color__neutral-gray--300);display:flex;gap:var(--mer-spacing--2xs)}.hiChar{color:var(--mer-color__primary--200);filter:brightness(1.3)}";
5
6
 
6
7
  const GxIdeAiMessage = /*@__PURE__*/ proxyCustomElement(class GxIdeAiMessage extends HTMLElement {
7
8
  constructor() {
8
9
  super();
9
10
  this.__registerHost();
10
11
  this.__attachShadow();
11
- /*
12
- INDEX:
13
- 1.OWN PROPERTIES
14
- 2.REFERENCE TO ELEMENTS
15
- 3.STATE() VARIABLES
16
- 4.PUBLIC PROPERTY API | WATCH'S
17
- 5.EVENTS (EMIT)
18
- 6.COMPONENT LIFECYCLE METHODS
19
- 7.LISTENERS
20
- 8.PUBLIC METHODS API
21
- 9.LOCAL METHODS
22
- 10.RENDER() FUNCTION
23
- */
24
- // 1.OWN PROPERTIES //
25
- /* The message allows to be copied*/
26
12
  this.copyable = false;
27
13
  // 7.LISTENERS //
28
14
  // 8.PUBLIC METHODS API //
@@ -32,13 +18,6 @@ const GxIdeAiMessage = /*@__PURE__*/ proxyCustomElement(class GxIdeAiMessage ext
32
18
  this.messageType !== "assistant-in-progress" &&
33
19
  this.messageType !== "assistant-action";
34
20
  };
35
- this.copyMessage = () => {
36
- navigator.clipboard.writeText(this.message);
37
- this.showCopiedMessage = true;
38
- setTimeout(() => {
39
- this.showCopiedMessage = false;
40
- }, 1500);
41
- };
42
21
  this.visible = false;
43
22
  this.showCopiedMessage = false;
44
23
  this.message = undefined;
@@ -50,6 +29,7 @@ const GxIdeAiMessage = /*@__PURE__*/ proxyCustomElement(class GxIdeAiMessage ext
50
29
  // 5.EVENTS (EMIT) //
51
30
  // 6.COMPONENT LIFECYCLE METHODS //
52
31
  async componentWillLoad() {
32
+ this._componentLocale = await Locale.getComponentStrings(this.el);
53
33
  this.evaluateMessageIsCopyable();
54
34
  }
55
35
  componentDidRender() {
@@ -69,14 +49,16 @@ const GxIdeAiMessage = /*@__PURE__*/ proxyCustomElement(class GxIdeAiMessage ext
69
49
  "message--assistant": this.messageType !== "user",
70
50
  "message--copyable": this.copyable,
71
51
  "message--copying": this.showCopiedMessage
72
- }, onClick: this.copyable && this.copyMessage }, h("div", { class: "message__outer-wrapper" }, h("div", { class: {
52
+ } }, h("div", { class: "message__outer-wrapper" }, h("div", { class: {
73
53
  "message__inner-wrapper": true
74
- } }, h("div", { class: {
54
+ } }, this.messageType === "user" ? (h("span", { class: "message__role message__role--user" }, this._componentLocale.you)) : (h("span", { class: {
55
+ "message__role": this.messageType !== "assistant-in-progress",
56
+ "message__role--hidden": this.messageType === "assistant-in-progress",
57
+ "message__role--assistant": true
58
+ } }, this._componentLocale.assistant)), h("div", { class: {
75
59
  "message__caption": true,
76
60
  "message__caption--in-progress": this.messageType === "assistant-in-progress"
77
- } }, this.showCopiedMessage ? (h("span", { class: {
78
- copied: true
79
- } }, h("gxg-icon", { type: "bpm/tasks", color: "mercury" }), this.translations["copied"])) : null, hiChar(this.message, this.filterValue)), this.messageType === "assistant-in-progress" ? (h("div", { class: "animation-wrapper" }, h("div", { class: "dot-pulse" }))) : null))));
61
+ } }, hiChar(this.message, this.filterValue)), this.messageType === "assistant-in-progress" ? (h("div", { class: "animation-wrapper" }, h("div", { class: "dot-pulse" }))) : null))));
80
62
  }
81
63
  static get assetsDirs() { return ["gx-ide-assets/ai-message"]; }
82
64
  get el() { return this; }
@@ -1 +1 @@
1
- {"file":"ai-message.js","mappings":";;;AAAA,MAAM,YAAY,GAAG,4oGAA4oG;;MCappG,cAAc;;;;;;;;;;;;;;;;;;;;QAkBjB,aAAQ,GAAG,KAAK,CAAC;;;;QAoEjB,8BAAyB,GAAG;YAClC,IAAI,CAAC,QAAQ;gBACX,IAAI,CAAC,WAAW,KAAK,uBAAuB;oBAC5C,IAAI,CAAC,WAAW,KAAK,kBAAkB,CAAC;SAC3C,CAAC;QAEM,gBAAW,GAAG;YACpB,SAAS,CAAC,SAAS,CAAC,SAAS,CAAC,IAAI,CAAC,OAAO,CAA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GAAY,EACrD,IAAI,CAAC,YAAY,CAAC,QAAQ,CAAC,CACvB,IACL,IAAI,EACP,MAAM,CAAC,IAAI,CAAC,OAAO,EAAE,IAAI,CAAC,WAAW,CAAC,CACnC,EACL,IAAI,CAAC,WAAW,KAAK,uBAAuB,IAC3C,WAAK,KAAK,EAAC,mBAAmB,IAC5B,WAAK,KAAK,EAAC,WAAW,GAAO,CACzB,IACJ,IAAI,CACJ,CACF,CACH,EACL;KACH;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","names":[],"sources":["src/components/ai-assistant/ai-message.scss?tag=gx-ide-ai-message&encapsulation=shadow","src/components/ai-assistant/ai-message.tsx"],"sourcesContent":["@import \"../../global/gx-ide-mixins.scss\";\n\n:host {\n font-family: var(--mer-font-family--primary);\n}\n/*--- Messages ---*/\n.message {\n color: var(--mer-color__neutral-gray--200);\n display: grid;\n grid-template-rows: 0fr;\n transition: grid-template-rows 100ms;\n transition: grid-template-rows 100ms, -ms-grid-rows 100ms;\n &__outer-wrapper {\n overflow: hidden;\n }\n &__inner-wrapper {\n padding: var(--mer-spacing--2xs) var(--mer-spacing--xs);\n border-radius: var(--mer-border__radius--xs);\n border: var(--mer-border__width--sm) solid transparent;\n background-color: var(--mer-color__neutral-gray--1200);\n margin-block-start: var(--mer-spacing--xs);\n }\n &__caption {\n font-size: var(--mer-font__size--2xs);\n line-height: var(--mer-line-height--comfortable);\n position: relative;\n }\n &--visible {\n grid-template-rows: 1fr;\n }\n &--copying {\n pointer-events: none;\n span:not(.copied),\n .message__caption {\n color: transparent;\n -webkit-user-select: none; /* Safari */\n -ms-user-select: none; /* IE 10 and IE 11 */\n user-select: none; /* Standard syntax */\n }\n }\n /*--- Types of messages ---*/\n &--user {\n .message__inner-wrapper {\n background-color: var(--mer-color__tint-blue--8);\n }\n }\n &--assistant-action {\n .message__inner-wrapper {\n font-style: italic;\n }\n }\n &--assistant-in-progress {\n color: var(--mer-color__neutral-gray--500);\n .message__inner-wrapper {\n font-style: italic;\n display: grid;\n grid-template-columns: 1fr auto;\n gap: var(--mer-spacing--xs);\n\n .message__caption {\n @include ellipsis;\n flex: 1;\n }\n .animation-wrapper {\n flex: none;\n }\n }\n }\n &--assistant-error {\n .message__inner-wrapper {\n background-color: var(--mer-color__tint-red--5);\n border-color: var(--mer-color__tint-red--60);\n }\n }\n &--copyable {\n cursor: pointer;\n &:hover {\n }\n }\n &:last-child {\n margin-block-end: 0;\n }\n}\n:host(:first-child) {\n .message {\n &__inner-wrapper {\n margin-block-end: 0;\n }\n }\n}\n\n/*--- Dot Pulse Sweet Animation ---*/\n.animation-wrapper {\n width: 45px;\n display: flex;\n align-items: center;\n justify-content: center;\n}\n$color: var(--mer-color__neutral-gray--400);\n.dot-pulse {\n position: relative;\n left: -9999px;\n width: 5px;\n height: 5px;\n border-radius: 2.5px;\n background-color: $color;\n color: $color;\n box-shadow: 9999px 0 0 -5px;\n animation: dot-pulse 1.5s infinite linear;\n animation-delay: 0.25s;\n &::before,\n &::after {\n content: \"\";\n display: inline-block;\n position: absolute;\n top: 0;\n width: 5px;\n height: 5px;\n border-radius: 2.5px;\n background-color: $color;\n color: $color;\n }\n &::before {\n box-shadow: 9984px 0 0 -5px;\n animation: dot-pulse-before 1.5s infinite linear;\n animation-delay: 0s;\n }\n &::after {\n box-shadow: 10014px 0 0 -5px;\n animation: dot-pulse-after 1.5s infinite linear;\n animation-delay: 0.5s;\n }\n}\n@keyframes dot-pulse-before {\n 0% {\n box-shadow: 9984px 0 0 -5px;\n }\n 30% {\n box-shadow: 9984px 0 0 2px;\n }\n 60%,\n 100% {\n box-shadow: 9984px 0 0 -5px;\n }\n}\n@keyframes dot-pulse {\n 0% {\n box-shadow: 9999px 0 0 -5px;\n }\n 30% {\n box-shadow: 9999px 0 0 2px;\n }\n 60%,\n 100% {\n box-shadow: 9999px 0 0 -5px;\n }\n}\n@keyframes dot-pulse-after {\n 0% {\n box-shadow: 10014px 0 0 -5px;\n }\n 30% {\n box-shadow: 10014px 0 0 2px;\n }\n 60%,\n 100% {\n box-shadow: 10014px 0 0 -5px;\n }\n}\n\n/*--- Copy Message ---*/\n.copied {\n position: absolute;\n width: 100%;\n height: 100%;\n display: flex;\n align-items: center;\n justify-content: center;\n color: var(--mer-color__neutral-gray--300);\n display: flex;\n gap: var(--mer-spacing--2xs);\n}\n\n@include hiChar;\n","/* STENCIL IMPORTS */\nimport { Component, h, Prop, Element, State } from \"@stencil/core\";\n/* OTHER LIBRARIES IMPORTS */\n/* CUSTOM IMPORTS */\nimport { MessageType } from \"./ai-assistant\";\nimport { hiChar } from \"../../common/helpers\";\n\n@Component({\n tag: \"gx-ide-ai-message\",\n styleUrl: \"ai-message.scss\",\n shadow: true,\n assetsDirs: [\"gx-ide-assets/ai-message\"]\n})\nexport class GxIdeAiMessage {\n /*\nINDEX:\n1.OWN PROPERTIES \n2.REFERENCE TO ELEMENTS\n3.STATE() VARIABLES\n4.PUBLIC PROPERTY API | WATCH'S\n5.EVENTS (EMIT)\n6.COMPONENT LIFECYCLE METHODS\n7.LISTENERS\n8.PUBLIC METHODS API\n9.LOCAL METHODS\n10.RENDER() FUNCTION\n*/\n\n // 1.OWN PROPERTIES //\n\n /* The message allows to be copied*/\n private copyable = false;\n\n // 2. REFERENCE TO ELEMENTS //\n\n @Element() el: HTMLGxIdeAiMessageElement;\n\n // 3.STATE() VARIABLES //\n\n /**\n * This wil display the message if true\n */\n @State() visible = false;\n\n /**\n * This wil show the user a text, indicating that the message has been copied\n */\n @State() showCopiedMessage = false;\n\n // 4.PUBLIC PROPERTY API | WATCH'S //\n\n /**\n * The actual message\n */\n @Prop() readonly message: string;\n\n /**\n * The message type\n */\n @Prop() readonly messageType: MessageType;\n\n /**\n * The filter value\n */\n @Prop() readonly filterValue: string;\n\n /**\n * It hides the message (used for the filter)\n */\n @Prop() readonly hidden: boolean;\n\n /**\n * An object with the needed string translations.\n */\n @Prop() readonly translations: Translations;\n\n // 5.EVENTS (EMIT) //\n\n // 6.COMPONENT LIFECYCLE METHODS //\n\n async componentWillLoad() {\n this.evaluateMessageIsCopyable();\n }\n\n componentDidRender() {\n setTimeout(() => {\n /* Without the timeout it appears instantly (no apparent transition)*/\n this.visible = true;\n const messagesList = this.el.parentElement;\n messagesList.scrollTo(0, 0);\n }, 0);\n }\n\n // 7.LISTENERS //\n\n // 8.PUBLIC METHODS API //\n\n // 9.LOCAL METHODS //\n\n private evaluateMessageIsCopyable = () => {\n this.copyable =\n this.messageType !== \"assistant-in-progress\" &&\n this.messageType !== \"assistant-action\";\n };\n\n private copyMessage = () => {\n navigator.clipboard.writeText(this.message);\n this.showCopiedMessage = true;\n setTimeout(() => {\n this.showCopiedMessage = false;\n }, 1500);\n };\n\n // 10.RENDER() FUNCTION //\n\n render() {\n return (\n <li\n class={{\n \"message\": true,\n \"message--visible\": this.visible && !this.hidden,\n [`message--${[this.messageType]}`]: true,\n \"message--assistant\": this.messageType !== \"user\",\n \"message--copyable\": this.copyable,\n \"message--copying\": this.showCopiedMessage\n }}\n onClick={this.copyable && this.copyMessage}\n >\n <div class=\"message__outer-wrapper\">\n <div\n class={{\n \"message__inner-wrapper\": true\n }}\n >\n <div\n class={{\n \"message__caption\": true,\n \"message__caption--in-progress\":\n this.messageType === \"assistant-in-progress\"\n }}\n >\n {this.showCopiedMessage ? (\n <span\n class={{\n copied: true\n }}\n >\n <gxg-icon type=\"bpm/tasks\" color=\"mercury\"></gxg-icon>\n {this.translations[\"copied\"]}\n </span>\n ) : null}\n {hiChar(this.message, this.filterValue)}\n </div>\n {this.messageType === \"assistant-in-progress\" ? (\n <div class=\"animation-wrapper\">\n <div class=\"dot-pulse\"></div>\n </div>\n ) : null}\n </div>\n </div>\n </li>\n );\n }\n}\n\nexport type Translations = {\n [key: string]: string;\n};\n"],"version":3}
1
+ {"file":"ai-message.js","mappings":";;;;AAAA,MAAM,YAAY,GAAG,4vHAA4vH;;MCcpwH,cAAc;;;;;QAmBjB,aAAQ,GAAG,KAAK,CAAC;;;;QAqEjB,8BAAyB,GAA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B;gBAC9C,0BAA0B,EAAE,IAAI;aACjC,IAEA,IAAI,CAAC,gBAAgB,CAAC,SAAS,CAC3B,CACR,EACD,WACE,KAAK,EAAE;gBACL,kBAAkB,EAAE,IAAI;gBACxB,+BAA+B,EAC7B,IAAI,CAAC,WAAW,KAAK,uBAAuB;aAC/C,IAEA,MAAM,CAAC,IAAI,CAAC,OAAO,EAAE,IAAI,CAAC,WAAW,CAAC,CACnC,EACL,IAAI,CAAC,WAAW,KAAK,uBAAuB,IAC3C,WAAK,KAAK,EAAC,mBAAmB,IAC5B,WAAK,KAAK,EAAC,WAAW,GAAO,CACzB,IACJ,IAAI,CACJ,CACF,CACH,EACL;KACH;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","names":[],"sources":["src/components/ai-assistant/ai-message.scss?tag=gx-ide-ai-message&encapsulation=shadow","src/components/ai-assistant/ai-message.tsx"],"sourcesContent":["@import \"../../global/gx-ide-mixins.scss\";\n\n:host {\n font-family: var(--mer-font-family--primary);\n}\n/*--- Messages ---*/\n.message {\n color: var(--mer-color__neutral-gray--100);\n display: grid;\n grid-template-rows: 0fr;\n transition: grid-template-rows 100ms;\n transition: grid-template-rows 100ms, -ms-grid-rows 100ms;\n &__outer-wrapper {\n overflow: hidden;\n }\n &__inner-wrapper {\n padding: var(--mer-spacing--sm) var(--mer-spacing--sm);\n border-radius: var(--mer-border__radius--sm);\n border-inline-start: var(--mer-border__width--md) solid transparent;\n background-color: var(--mer-color__neutral-gray--1200);\n margin-block-start: var(--mer-spacing--xs);\n }\n &__role {\n display: inline-block;\n font-weight: var(--mer-font__weight--semi-bold);\n margin-block-end: var(--mer-spacing--xs);\n display: inline-grid;\n grid-template-columns: max-content max-content;\n gap: 6px;\n &:before {\n content: \"\";\n display: grid;\n place-self: center flex-end;\n inline-size: 4px;\n block-size: 4px;\n border-radius: 50%;\n background-color: currentcolor;\n }\n\n &--user {\n color: var(--mer-color__primary--300);\n }\n &--assistant {\n }\n &--hidden {\n display: none;\n }\n }\n &__caption {\n font-size: var(--mer-font__size--xs);\n line-height: var(--mer-line-height--regular);\n position: relative;\n }\n &--visible {\n grid-template-rows: 1fr;\n }\n &--copying {\n pointer-events: none;\n span:not(.copied),\n .message__caption {\n color: transparent;\n -webkit-user-select: none; /* Safari */\n -ms-user-select: none; /* IE 10 and IE 11 */\n user-select: none; /* Standard syntax */\n }\n }\n /*--- Types of messages ---*/\n &--user {\n .message__inner-wrapper {\n background-color: rgba(91, 167, 255, 0.08);\n border-color: var(--mer-border-color__primary);\n }\n }\n &--assistant-action {\n .message__inner-wrapper {\n background-color: rgba(63, 168, 155, 0.05);\n border-color: var(--mer-border-color__success);\n }\n }\n &--assistant-chat {\n .message__inner-wrapper {\n background-color: var(--mer-surface__elevation--01);\n }\n }\n &--assistant-in-progress {\n color: var(--mer-color__neutral-gray--500);\n .message__inner-wrapper {\n font-style: italic;\n display: grid;\n grid-template-columns: 1fr auto;\n gap: var(--mer-spacing--xs);\n\n .message__caption {\n @include ellipsis;\n flex: 1;\n }\n .animation-wrapper {\n flex: none;\n }\n }\n }\n &--assistant-error {\n .message__inner-wrapper {\n background-color: rgba(251, 124, 132, 0.05);\n border-color: var(--mer-border-color__error);\n }\n }\n &--copyable {\n }\n &:last-child {\n margin-block-end: 0;\n }\n}\n:host(:first-child) {\n .message {\n &__inner-wrapper {\n margin-block-end: 0;\n }\n }\n}\n\n/*--- Dot Pulse Sweet Animation ---*/\n.animation-wrapper {\n width: 45px;\n display: flex;\n align-items: center;\n justify-content: center;\n}\n$color: var(--mer-color__neutral-gray--400);\n.dot-pulse {\n position: relative;\n left: -9999px;\n width: 5px;\n height: 5px;\n border-radius: 2.5px;\n background-color: $color;\n color: $color;\n box-shadow: 9999px 0 0 -5px;\n animation: dot-pulse 1.5s infinite linear;\n animation-delay: 0.25s;\n &::before,\n &::after {\n content: \"\";\n display: inline-block;\n position: absolute;\n top: 0;\n width: 5px;\n height: 5px;\n border-radius: 2.5px;\n background-color: $color;\n color: $color;\n }\n &::before {\n box-shadow: 9984px 0 0 -5px;\n animation: dot-pulse-before 1.5s infinite linear;\n animation-delay: 0s;\n }\n &::after {\n box-shadow: 10014px 0 0 -5px;\n animation: dot-pulse-after 1.5s infinite linear;\n animation-delay: 0.5s;\n }\n}\n@keyframes dot-pulse-before {\n 0% {\n box-shadow: 9984px 0 0 -5px;\n }\n 30% {\n box-shadow: 9984px 0 0 2px;\n }\n 60%,\n 100% {\n box-shadow: 9984px 0 0 -5px;\n }\n}\n@keyframes dot-pulse {\n 0% {\n box-shadow: 9999px 0 0 -5px;\n }\n 30% {\n box-shadow: 9999px 0 0 2px;\n }\n 60%,\n 100% {\n box-shadow: 9999px 0 0 -5px;\n }\n}\n@keyframes dot-pulse-after {\n 0% {\n box-shadow: 10014px 0 0 -5px;\n }\n 30% {\n box-shadow: 10014px 0 0 2px;\n }\n 60%,\n 100% {\n box-shadow: 10014px 0 0 -5px;\n }\n}\n\n/*--- Copy Message ---*/\n.copied {\n position: absolute;\n width: 100%;\n height: 100%;\n display: flex;\n align-items: center;\n justify-content: center;\n color: var(--mer-color__neutral-gray--300);\n display: flex;\n gap: var(--mer-spacing--2xs);\n}\n\n@include hiChar;\n","/* STENCIL IMPORTS */\nimport { Component, h, Prop, Element, State } from \"@stencil/core\";\n/* OTHER LIBRARIES IMPORTS */\n/* CUSTOM IMPORTS */\nimport { Locale } from \"../../common/locale\";\nimport { MessageType } from \"./ai-assistant\";\nimport { hiChar } from \"../../common/helpers\";\n\n@Component({\n tag: \"gx-ide-ai-message\",\n styleUrl: \"ai-message.scss\",\n shadow: true,\n assetsDirs: [\"gx-ide-assets/ai-message\"]\n})\nexport class GxIdeAiMessage {\n /*\nINDEX:\n1.OWN PROPERTIES \n2.REFERENCE TO ELEMENTS\n3.STATE() VARIABLES\n4.PUBLIC PROPERTY API | WATCH'S\n5.EVENTS (EMIT)\n6.COMPONENT LIFECYCLE METHODS\n7.LISTENERS\n8.PUBLIC METHODS API\n9.LOCAL METHODS\n10.RENDER() FUNCTION\n*/\n\n // 1.OWN PROPERTIES //\n\n /* The message allows to be copied*/\n private _componentLocale: any;\n private copyable = false;\n\n // 2. REFERENCE TO ELEMENTS //\n\n @Element() el: HTMLGxIdeAiMessageElement;\n\n // 3.STATE() VARIABLES //\n\n /**\n * This wil display the message if true\n */\n @State() visible = false;\n\n /**\n * This wil show the user a text, indicating that the message has been copied\n */\n @State() showCopiedMessage = false;\n\n // 4.PUBLIC PROPERTY API | WATCH'S //\n\n /**\n * The actual message\n */\n @Prop() readonly message: string;\n\n /**\n * The message type\n */\n @Prop() readonly messageType: MessageType;\n\n /**\n * The filter value\n */\n @Prop() readonly filterValue: string;\n\n /**\n * It hides the message (used for the filter)\n */\n @Prop() readonly hidden: boolean;\n\n /**\n * An object with the needed string translations.\n */\n @Prop() readonly translations: Translations;\n\n // 5.EVENTS (EMIT) //\n\n // 6.COMPONENT LIFECYCLE METHODS //\n\n async componentWillLoad() {\n this._componentLocale = await Locale.getComponentStrings(this.el);\n this.evaluateMessageIsCopyable();\n }\n\n componentDidRender() {\n setTimeout(() => {\n /* Without the timeout it appears instantly (no apparent transition)*/\n this.visible = true;\n const messagesList = this.el.parentElement;\n messagesList.scrollTo(0, 0);\n }, 0);\n }\n\n // 7.LISTENERS //\n\n // 8.PUBLIC METHODS API //\n\n // 9.LOCAL METHODS //\n\n private evaluateMessageIsCopyable = () => {\n this.copyable =\n this.messageType !== \"assistant-in-progress\" &&\n this.messageType !== \"assistant-action\";\n };\n\n // 10.RENDER() FUNCTION //\n\n render() {\n return (\n <li\n class={{\n \"message\": true,\n \"message--visible\": this.visible && !this.hidden,\n [`message--${[this.messageType]}`]: true,\n \"message--assistant\": this.messageType !== \"user\",\n \"message--copyable\": this.copyable,\n \"message--copying\": this.showCopiedMessage\n }}\n >\n <div class=\"message__outer-wrapper\">\n <div\n class={{\n \"message__inner-wrapper\": true\n }}\n >\n {this.messageType === \"user\" ? (\n <span class=\"message__role message__role--user\">\n {this._componentLocale.you}\n </span>\n ) : (\n <span\n class={{\n \"message__role\": this.messageType !== \"assistant-in-progress\",\n \"message__role--hidden\":\n this.messageType === \"assistant-in-progress\",\n \"message__role--assistant\": true\n }}\n >\n {this._componentLocale.assistant}\n </span>\n )}\n <div\n class={{\n \"message__caption\": true,\n \"message__caption--in-progress\":\n this.messageType === \"assistant-in-progress\"\n }}\n >\n {hiChar(this.message, this.filterValue)}\n </div>\n {this.messageType === \"assistant-in-progress\" ? (\n <div class=\"animation-wrapper\">\n <div class=\"dot-pulse\"></div>\n </div>\n ) : null}\n </div>\n </div>\n </li>\n );\n }\n}\n\nexport type Translations = {\n [key: string]: string;\n};\n"],"version":3}
@@ -2,7 +2,7 @@ import { proxyCustomElement, HTMLElement, createEvent, h, Host } from '@stencil/
2
2
  import { L as Locale } from './locale.js';
3
3
  import { d as defineCustomElement$2 } from './ai-message.js';
4
4
 
5
- const aiAssistantCss = ":root{--ui-animaton-speed:0.2s}.gxg-title-01{font-family:var(--ds-base-font-family-primary);font-weight:var(--ds-title-01-font-weight);font-size:var(--ds-title-01-font-size);letter-spacing:var(--ds-base-font-letter-spacing--comfortable);color:var(--ds-base-font-color);text-align:start;line-height:var(--ds-base-font-line-height--comfortable)}.gxg-title-01--negative{font-family:var(--ds-base-font-family-primary);font-weight:var(--ds-title-01-font-weight);font-size:var(--ds-title-01-font-size);letter-spacing:var(--ds-base-font-letter-spacing--comfortable);color:var(--ds-base-font-color);text-align:start;line-height:var(--ds-base-font-line-height--comfortable);color:var(--ds-base-font-color--negative)}.gxg-title-02{font-family:var(--ds-base-font-family-primary);font-weight:var(--ds-title-02-font-weight);font-size:var(--ds-title-02-font-size);letter-spacing:var(--ds-base-font-letter-spacing--regular);color:var(--ds-base-font-color);text-align:start;text-transform:uppercase;line-height:var(--ds-base-font-line-height--comfortable)}.gxg-title-02--negative{font-family:var(--ds-base-font-family-primary);font-weight:var(--ds-title-02-font-weight);font-size:var(--ds-title-02-font-size);letter-spacing:var(--ds-base-font-letter-spacing--regular);color:var(--ds-base-font-color);text-align:start;text-transform:uppercase;line-height:var(--ds-base-font-line-height--comfortable);color:var(--color-on-primary)}.gxg-title-03{font-family:var(--ds-base-font-family-primary);font-weight:var(--ds-title-03-font-weight);font-size:var(--ds-title-03-font-size);letter-spacing:var(--ds-base-font-letter-spacing--regular);color:var(--ds-base-font-color);text-align:start;text-transform:uppercase;line-height:var(--ds-base-font-line-height--comfortable)}.gxg-title-03--negative{font-family:var(--ds-base-font-family-primary);font-weight:var(--ds-title-03-font-weight);font-size:var(--ds-title-03-font-size);letter-spacing:var(--ds-base-font-letter-spacing--regular);color:var(--ds-base-font-color);text-align:start;text-transform:uppercase;line-height:var(--ds-base-font-line-height--comfortable);color:var(--ds-base-font-color--negative)}.gxg-title-04{font-family:var(--ds-base-font-family-primary);font-weight:var(--ds-title-04-font-weight);font-size:var(--ds-title-04-font-size);letter-spacing:var(--ds-base-font-letter-spacing--comfortable);color:var(--ds-base-font-color);text-align:start;line-height:var(--ds-base-font-line-height--comfortable)}.gxg-title-04--negative{font-family:var(--ds-base-font-family-primary);font-weight:var(--ds-title-04-font-weight);font-size:var(--ds-title-04-font-size);letter-spacing:var(--ds-base-font-letter-spacing--comfortable);color:var(--ds-base-font-color);text-align:start;line-height:var(--ds-base-font-line-height--comfortable);color:var(--ds-base-font-color--negative)}.gxg-title-05{font-family:var(--ds-base-font-family-primary);font-weight:var(--ds-title-05-font-weight);font-size:var(--ds-title-05-font-size);letter-spacing:var(--ds-base-font-letter-spacing--regular);color:var(--ds-base-font-color);text-align:start;line-height:var(--ds-base-font-line-height--comfortable)}.gxg-title-05--negative{font-family:var(--ds-base-font-family-primary);font-weight:var(--ds-title-05-font-weight);font-size:var(--ds-title-05-font-size);letter-spacing:var(--ds-base-font-letter-spacing--regular);color:var(--ds-base-font-color);text-align:start;line-height:var(--ds-base-font-line-height--comfortable);color:var(--ds-base-font-color--negative)}.gxg-text{font-family:var(--ds-base-font-family-primary);font-size:var(--ds-base-font-size);color:var(--ds-base-font-size-color);font-weight:var(--ds-base-font-size-weight);line-height:var(--ds-base-font-line-height--comfortable)}.gxg-text--negative{font-family:var(--ds-base-font-family-primary);font-size:var(--ds-base-font-size);color:var(--ds-base-font-size-color);font-weight:var(--ds-base-font-size-weight);line-height:var(--ds-base-font-line-height--comfortable);color:var(--ds-base-font-color--negative)}.gxg-text--gray{font-family:var(--ds-base-font-family-primary);font-size:var(--ds-base-font-size);color:var(--ds-base-font-size-color);font-weight:var(--ds-base-font-size-weight);line-height:var(--ds-base-font-line-height--comfortable);color:var(--ds-base-font-color--dimmed)}.gxg-quote{font-family:var(--ds-base-font-family-primary);font-size:var(--ds-base-font-size);color:var(--ds-base-font-size-color);font-weight:var(--ds-base-font-size-weight);line-height:var(--ds-base-font-line-height--comfortable);font-style:italic}.gxg-quote--negative{color:var(--ds-base-font-color--negative)}.gxg-link{line-height:unset;font-family:var(--ds-base-font-family-primary);font-size:var(--ds-base-font-size);color:var(--ds-base-font-size-color);font-weight:var(--ds-base-font-size-weight);line-height:var(--ds-base-font-line-height--comfortable);color:var(--ds-base-font-color--link);text-decoration:underline;cursor:pointer;display:inline-block}.gxg-link:hover{color:var(--ds-base-font-color--link-hover)}.gxg-link:active{color:var(--ds-base-font-color--link-active)}.gxg-link-gray{line-height:unset;font-family:var(--ds-base-font-family-primary);font-size:var(--ds-base-font-size);color:var(--ds-base-font-size-color);font-weight:var(--ds-base-font-size-weight);line-height:var(--ds-base-font-line-height--comfortable);color:var(--ds-base-font-color--link);text-decoration:underline;cursor:pointer;display:inline-block;color:var(--ds-base-font-color--dimmed)}.gxg-link-gray:hover{line-height:unset;font-family:var(--ds-base-font-family-primary);font-size:var(--ds-base-font-size);color:var(--ds-base-font-size-color);font-weight:var(--ds-base-font-size-weight);line-height:var(--ds-base-font-line-height--comfortable);color:var(--ds-base-font-color--link);text-decoration:underline;cursor:pointer;display:inline-block;color:var(--ds-base-font-color--dimmed);filter:brightness(1.4)}.gxg-alert-error{font-family:var(--ds-base-font-family-primary);font-size:var(--ds-base-font-size);color:var(--ds-base-font-size-color);font-weight:var(--ds-base-font-size-weight);line-height:var(--ds-base-font-line-height--comfortable);color:var(--ds-base-font-color--error);display:inline-block}.gxg-alert-warning{font-family:var(--ds-base-font-family-primary);font-size:var(--ds-base-font-size);color:var(--ds-base-font-size-color);font-weight:var(--ds-base-font-size-weight);line-height:var(--ds-base-font-line-height--comfortable);color:var(--ds-base-font-color--warning);display:inline-block}.gxg-alert-success{font-family:var(--ds-base-font-family-primary);font-size:var(--ds-base-font-size);color:var(--ds-base-font-size-color);font-weight:var(--ds-base-font-size-weight);line-height:var(--ds-base-font-line-height--comfortable);color:var(--ds-base-font-color--success);display:inline-block}.gxg-tab--disabled{color:var(--color-primary-disabled);pointer-events:none}.gxg-tab--disabled[disabled]{color:var(--color-primary-disabled);pointer-events:none}.gxg-label{font-family:var(--ds-base-font-family-primary);font-weight:var(--gxg-label-font-weight);font-size:var(--gxg-label-font-size);color:var(--gxg-label-color);text-align:center;line-height:1.455em;display:flex;align-items:center}.gxg-label:hover{color:var(--color-primary-hover)}.gxg-label:focus{color:var(--color-primary-active)}.gxg-label:active{color:var(--color-primary-active)}.gxg-label[disabled]{color:var(--color-primary-disabled)}.gxg-label--negative{color:var(--color-on-primary)}.gxg-label--negative[disabled]{color:var(--color-on-disabled)}.gxg-scrollbar{}.gxg-scrollbar::-webkit-scrollbar{width:var(--gxg-scrollbar-width);height:var(--gxg-scrollbar-width)}.gxg-scrollbar::-webkit-scrollbar-track{background-color:var(--gxg-scrollbar-track-background);border-radius:var(--gxg-scrollbar-track-border-radius)}.gxg-scrollbar::-webkit-scrollbar-thumb{background-color:var(--gxg-scrollbar-track-thumb-background);border-radius:var(--gxg-scrollbar-track-thumb-radius)}.gxg-scrollbar::-webkit-scrollbar-thumb:hover{background-color:var(--gxg-scrollbar-track-thumb-hover-background)}.gxg-scrollbar::-webkit-scrollbar-corner{background:rgba(0, 0, 0, 0)}@keyframes spin{0%{transform:rotate(0deg)}100%{transform:rotate(360deg)}}:host{display:grid;block-size:100%}.card-regular{background-color:var(--mer-surface__elevation--01);border:var(--mer-border__width--sm) solid var(--mer-border-color__on-elevation--01);border-radius:var(--mer-border__radius--md);padding:var(--mer-spacing--md) var(--mer-spacing--md);display:grid}.card-small{background-color:var(--mer-surface__elevation--02);border-radius:var(--mer-border__radius--sm);padding:var(--mer-spacing--sm) var(--mer-spacing--sm)}.card-small--actionable:hover{background-color:var(--mer-color__neutral-gray--600)}.card-small--actionable:active{background-color:var(--mer-color__neutral-gray--650)}.card-small:focus-visible{outline:var(--focus__outline-width) var(--focus__outline-style) var(--focus__outline-color);outline-offset:var(--focus__outline-offset)}.empty-state{block-size:100%;display:flex;align-items:center;justify-content:center;flex-direction:column;gap:var(--mer-spacing--sm);text-align:center}.empty-state__title,.empty-state__button,.empty-state__link{max-inline-size:300px}.opacity-0{opacity:0}.opacity-1{opacity:1}.display-contents{display:contents}.gxi-hidden{display:none !important}.gxi-full-height{height:100%}.gxi-overflow-auto{overflow:auto}.gxi-display-flex{display:flex}.align-start{display:flex;align-items:start}.align-center{display:flex;align-items:center}.align-end{display:flex;align-items:end}.overflow-auto{overflow:auto}.justify-start{display:flex;justify-content:start}.justify-center{display:flex;justify-content:center}.justify-end{display:flex;justify-content:end}.grid{display:grid;grid-row-gap:var(--gx-ide-grid-row-gap);grid-column-gap:var(--gx-ide-grid-column-gap);grid-template-rows:auto}ch-grid-cell{display:flex}ch-grid{overflow:auto;height:100%}ch-grid-column{z-index:99;border-bottom:1px solid var(--mer-color__neutral-gray--800)}ch-grid-column:first-child{padding-inline-start:var(--gx-ide-container__padding) !important}ch-grid-column:last-child{padding-inline-end:var(--gx-ide-container__padding) !important}ch-grid-cell{--mer-spacing--xs:var(--gx-ide-container__padding)}.layout{display:grid;gap:var(--mer-spacing--lg);box-sizing:border-box}.layout--two-cols{grid-template-columns:1fr 1fr}.layout--space-above{padding-block-start:var(--mer-spacing--lg)}gxg-tabs{box-shadow:none}:host(.gx-ide-component){height:100% !important;display:flex !important;flex-direction:column !important}:host(:focus-within) gx-ide-top-bar::part(wrapper){background-color:var(--color-secondary-enabled)}.gx-ide-main-wrapper{color:var(--gx-ide-component-text-color);font-weight:var(--mer-font__weight--regular);font-size:var(--mer-font__size--xs);font-family:var(--mer-font-family--primary);height:100%;background-color:var(--gx-ide-component-background-color);display:flex;flex-direction:column;flex-grow:1;box-sizing:border-box}.gx-ide-main{flex-grow:1;overflow-y:auto;}.gx-ide-main::-webkit-scrollbar{width:var(--gxg-scrollbar-width);height:var(--gxg-scrollbar-width)}.gx-ide-main::-webkit-scrollbar-track{background-color:var(--gxg-scrollbar-track-background);border-radius:var(--gxg-scrollbar-track-border-radius)}.gx-ide-main::-webkit-scrollbar-thumb{background-color:var(--gxg-scrollbar-track-thumb-background);border-radius:var(--gxg-scrollbar-track-thumb-radius)}.gx-ide-main::-webkit-scrollbar-thumb:hover{background-color:var(--gxg-scrollbar-track-thumb-hover-background)}.gx-ide-main::-webkit-scrollbar-corner{background:rgba(0, 0, 0, 0)}.gx-ide-overflow{overflow-y:auto;}.gx-ide-overflow::-webkit-scrollbar{width:var(--gxg-scrollbar-width);height:var(--gxg-scrollbar-width)}.gx-ide-overflow::-webkit-scrollbar-track{background-color:var(--gxg-scrollbar-track-background);border-radius:var(--gxg-scrollbar-track-border-radius)}.gx-ide-overflow::-webkit-scrollbar-thumb{background-color:var(--gxg-scrollbar-track-thumb-background);border-radius:var(--gxg-scrollbar-track-thumb-radius)}.gx-ide-overflow::-webkit-scrollbar-thumb:hover{background-color:var(--gxg-scrollbar-track-thumb-hover-background)}.gx-ide-overflow::-webkit-scrollbar-corner{background:rgba(0, 0, 0, 0)}.tree-view-primary{font-size:var(--mer-font__size--2xs)}p{margin:0;font-size:var(--mer-font__size--xxs)}.buttons-container{display:flex;gap:var(--mer-spacing--xs)}:root{--ui-animaton-speed:0.2s}.gxg-title-01{font-family:var(--ds-base-font-family-primary);font-weight:var(--ds-title-01-font-weight);font-size:var(--ds-title-01-font-size);letter-spacing:var(--ds-base-font-letter-spacing--comfortable);color:var(--ds-base-font-color);text-align:start;line-height:var(--ds-base-font-line-height--comfortable)}.gxg-title-01--negative{font-family:var(--ds-base-font-family-primary);font-weight:var(--ds-title-01-font-weight);font-size:var(--ds-title-01-font-size);letter-spacing:var(--ds-base-font-letter-spacing--comfortable);color:var(--ds-base-font-color);text-align:start;line-height:var(--ds-base-font-line-height--comfortable);color:var(--ds-base-font-color--negative)}.gxg-title-02{font-family:var(--ds-base-font-family-primary);font-weight:var(--ds-title-02-font-weight);font-size:var(--ds-title-02-font-size);letter-spacing:var(--ds-base-font-letter-spacing--regular);color:var(--ds-base-font-color);text-align:start;text-transform:uppercase;line-height:var(--ds-base-font-line-height--comfortable)}.gxg-title-02--negative{font-family:var(--ds-base-font-family-primary);font-weight:var(--ds-title-02-font-weight);font-size:var(--ds-title-02-font-size);letter-spacing:var(--ds-base-font-letter-spacing--regular);color:var(--ds-base-font-color);text-align:start;text-transform:uppercase;line-height:var(--ds-base-font-line-height--comfortable);color:var(--color-on-primary)}.gxg-title-03{font-family:var(--ds-base-font-family-primary);font-weight:var(--ds-title-03-font-weight);font-size:var(--ds-title-03-font-size);letter-spacing:var(--ds-base-font-letter-spacing--regular);color:var(--ds-base-font-color);text-align:start;text-transform:uppercase;line-height:var(--ds-base-font-line-height--comfortable)}.gxg-title-03--negative{font-family:var(--ds-base-font-family-primary);font-weight:var(--ds-title-03-font-weight);font-size:var(--ds-title-03-font-size);letter-spacing:var(--ds-base-font-letter-spacing--regular);color:var(--ds-base-font-color);text-align:start;text-transform:uppercase;line-height:var(--ds-base-font-line-height--comfortable);color:var(--ds-base-font-color--negative)}.gxg-title-04{font-family:var(--ds-base-font-family-primary);font-weight:var(--ds-title-04-font-weight);font-size:var(--ds-title-04-font-size);letter-spacing:var(--ds-base-font-letter-spacing--comfortable);color:var(--ds-base-font-color);text-align:start;line-height:var(--ds-base-font-line-height--comfortable)}.gxg-title-04--negative{font-family:var(--ds-base-font-family-primary);font-weight:var(--ds-title-04-font-weight);font-size:var(--ds-title-04-font-size);letter-spacing:var(--ds-base-font-letter-spacing--comfortable);color:var(--ds-base-font-color);text-align:start;line-height:var(--ds-base-font-line-height--comfortable);color:var(--ds-base-font-color--negative)}.gxg-title-05{font-family:var(--ds-base-font-family-primary);font-weight:var(--ds-title-05-font-weight);font-size:var(--ds-title-05-font-size);letter-spacing:var(--ds-base-font-letter-spacing--regular);color:var(--ds-base-font-color);text-align:start;line-height:var(--ds-base-font-line-height--comfortable)}.gxg-title-05--negative{font-family:var(--ds-base-font-family-primary);font-weight:var(--ds-title-05-font-weight);font-size:var(--ds-title-05-font-size);letter-spacing:var(--ds-base-font-letter-spacing--regular);color:var(--ds-base-font-color);text-align:start;line-height:var(--ds-base-font-line-height--comfortable);color:var(--ds-base-font-color--negative)}.gxg-text{font-family:var(--ds-base-font-family-primary);font-size:var(--ds-base-font-size);color:var(--ds-base-font-size-color);font-weight:var(--ds-base-font-size-weight);line-height:var(--ds-base-font-line-height--comfortable)}.gxg-text--negative{font-family:var(--ds-base-font-family-primary);font-size:var(--ds-base-font-size);color:var(--ds-base-font-size-color);font-weight:var(--ds-base-font-size-weight);line-height:var(--ds-base-font-line-height--comfortable);color:var(--ds-base-font-color--negative)}.gxg-text--gray{font-family:var(--ds-base-font-family-primary);font-size:var(--ds-base-font-size);color:var(--ds-base-font-size-color);font-weight:var(--ds-base-font-size-weight);line-height:var(--ds-base-font-line-height--comfortable);color:var(--ds-base-font-color--dimmed)}.gxg-quote{font-family:var(--ds-base-font-family-primary);font-size:var(--ds-base-font-size);color:var(--ds-base-font-size-color);font-weight:var(--ds-base-font-size-weight);line-height:var(--ds-base-font-line-height--comfortable);font-style:italic}.gxg-quote--negative{color:var(--ds-base-font-color--negative)}.gxg-link{line-height:unset;font-family:var(--ds-base-font-family-primary);font-size:var(--ds-base-font-size);color:var(--ds-base-font-size-color);font-weight:var(--ds-base-font-size-weight);line-height:var(--ds-base-font-line-height--comfortable);color:var(--ds-base-font-color--link);text-decoration:underline;cursor:pointer;display:inline-block}.gxg-link:hover{color:var(--ds-base-font-color--link-hover)}.gxg-link:active{color:var(--ds-base-font-color--link-active)}.gxg-link-gray{line-height:unset;font-family:var(--ds-base-font-family-primary);font-size:var(--ds-base-font-size);color:var(--ds-base-font-size-color);font-weight:var(--ds-base-font-size-weight);line-height:var(--ds-base-font-line-height--comfortable);color:var(--ds-base-font-color--link);text-decoration:underline;cursor:pointer;display:inline-block;color:var(--ds-base-font-color--dimmed)}.gxg-link-gray:hover{line-height:unset;font-family:var(--ds-base-font-family-primary);font-size:var(--ds-base-font-size);color:var(--ds-base-font-size-color);font-weight:var(--ds-base-font-size-weight);line-height:var(--ds-base-font-line-height--comfortable);color:var(--ds-base-font-color--link);text-decoration:underline;cursor:pointer;display:inline-block;color:var(--ds-base-font-color--dimmed);filter:brightness(1.4)}.gxg-alert-error{font-family:var(--ds-base-font-family-primary);font-size:var(--ds-base-font-size);color:var(--ds-base-font-size-color);font-weight:var(--ds-base-font-size-weight);line-height:var(--ds-base-font-line-height--comfortable);color:var(--ds-base-font-color--error);display:inline-block}.gxg-alert-warning{font-family:var(--ds-base-font-family-primary);font-size:var(--ds-base-font-size);color:var(--ds-base-font-size-color);font-weight:var(--ds-base-font-size-weight);line-height:var(--ds-base-font-line-height--comfortable);color:var(--ds-base-font-color--warning);display:inline-block}.gxg-alert-success{font-family:var(--ds-base-font-family-primary);font-size:var(--ds-base-font-size);color:var(--ds-base-font-size-color);font-weight:var(--ds-base-font-size-weight);line-height:var(--ds-base-font-line-height--comfortable);color:var(--ds-base-font-color--success);display:inline-block}.gxg-tab--disabled{color:var(--color-primary-disabled);pointer-events:none}.gxg-tab--disabled[disabled]{color:var(--color-primary-disabled);pointer-events:none}.gxg-label{font-family:var(--ds-base-font-family-primary);font-weight:var(--gxg-label-font-weight);font-size:var(--gxg-label-font-size);color:var(--gxg-label-color);text-align:center;line-height:1.455em;display:flex;align-items:center}.gxg-label:hover{color:var(--color-primary-hover)}.gxg-label:focus{color:var(--color-primary-active)}.gxg-label:active{color:var(--color-primary-active)}.gxg-label[disabled]{color:var(--color-primary-disabled)}.gxg-label--negative{color:var(--color-on-primary)}.gxg-label--negative[disabled]{color:var(--color-on-disabled)}.gxg-scrollbar{}.gxg-scrollbar::-webkit-scrollbar{width:var(--gxg-scrollbar-width);height:var(--gxg-scrollbar-width)}.gxg-scrollbar::-webkit-scrollbar-track{background-color:var(--gxg-scrollbar-track-background);border-radius:var(--gxg-scrollbar-track-border-radius)}.gxg-scrollbar::-webkit-scrollbar-thumb{background-color:var(--gxg-scrollbar-track-thumb-background);border-radius:var(--gxg-scrollbar-track-thumb-radius)}.gxg-scrollbar::-webkit-scrollbar-thumb:hover{background-color:var(--gxg-scrollbar-track-thumb-hover-background)}.gxg-scrollbar::-webkit-scrollbar-corner{background:rgba(0, 0, 0, 0)}:host{font-family:var(--mer-font-family--primary);display:block;height:100%;flex-basis:286px;flex-shrink:0;height:100%;overflow-y:auto}.gx-ide-main-wrapper{padding:0 10px 52px 10px;background-color:var(--mer-color__neutral-gray--1000);height:100%;display:grid;grid-template-rows:auto 1fr auto;gap:var(--mer-spacing--sm)}.header{padding-block-start:var(--mer-spacing--sm);display:flex;flex-direction:column}.header__actions-wrapper{display:flex;gap:var(--ai-assistant-header-actions-gap);margin-inline-start:auto}.header__first-row{display:flex;gap:var(--mer-spacing--xs);align-items:center;justify-content:space-between}.header__filter{margin-block-start:var(--mer-spacing--xs)}.header__second-row{transition:100ms grid-template-rows;display:grid;grid-template-rows:0fr}.header__second-row--visible{grid-template-rows:1fr}.header .filter-inner-wrapper{overflow:hidden}.messages-wrapper{position:relative;overflow:auto;display:flex;flex-direction:column;scroll-behavior:smooth;}.messages-wrapper::-webkit-scrollbar{width:var(--gxg-scrollbar-width);height:var(--gxg-scrollbar-width)}.messages-wrapper::-webkit-scrollbar-track{background-color:var(--gxg-scrollbar-track-background);border-radius:var(--gxg-scrollbar-track-border-radius)}.messages-wrapper::-webkit-scrollbar-thumb{background-color:var(--gxg-scrollbar-track-thumb-background);border-radius:var(--gxg-scrollbar-track-thumb-radius)}.messages-wrapper::-webkit-scrollbar-thumb:hover{background-color:var(--gxg-scrollbar-track-thumb-hover-background)}.messages-wrapper::-webkit-scrollbar-corner{background:rgba(0, 0, 0, 0)}.messages{display:flex;flex-direction:column;list-style-type:none;padding:0;margin:0}.prompt{position:relative;margin-top:auto}.prompt__textarea::part(textarea-wrapper){border:none;background-color:var(--mer-color__neutral-gray--1100)}.prompt__textarea::part(textarea){border:none}.prompt__shortcuts{position:absolute;display:flex;align-items:center;gap:var(--mer-spacing--2xs);padding-inline-end:var(--mer-spacing--xs);right:0;top:0;height:100%}.prompt__shortcut{color:var(--mer-color__neutral-gray--400);font-size:var(--mer-font__size--2xs);padding:var(--mer-spacing--3xs) var(--mer-spacing--xs);background-color:var(--mer-color__neutral-gray--700);border-radius:var(--mer-border__radius--xs)}";
5
+ const aiAssistantCss = ":root{--ui-animaton-speed:0.2s}.gxg-title-01{font-family:var(--ds-base-font-family-primary);font-weight:var(--ds-title-01-font-weight);font-size:var(--ds-title-01-font-size);letter-spacing:var(--ds-base-font-letter-spacing--comfortable);color:var(--ds-base-font-color);text-align:start;line-height:var(--ds-base-font-line-height--comfortable)}.gxg-title-01--negative{font-family:var(--ds-base-font-family-primary);font-weight:var(--ds-title-01-font-weight);font-size:var(--ds-title-01-font-size);letter-spacing:var(--ds-base-font-letter-spacing--comfortable);color:var(--ds-base-font-color);text-align:start;line-height:var(--ds-base-font-line-height--comfortable);color:var(--ds-base-font-color--negative)}.gxg-title-02{font-family:var(--ds-base-font-family-primary);font-weight:var(--ds-title-02-font-weight);font-size:var(--ds-title-02-font-size);letter-spacing:var(--ds-base-font-letter-spacing--regular);color:var(--ds-base-font-color);text-align:start;text-transform:uppercase;line-height:var(--ds-base-font-line-height--comfortable)}.gxg-title-02--negative{font-family:var(--ds-base-font-family-primary);font-weight:var(--ds-title-02-font-weight);font-size:var(--ds-title-02-font-size);letter-spacing:var(--ds-base-font-letter-spacing--regular);color:var(--ds-base-font-color);text-align:start;text-transform:uppercase;line-height:var(--ds-base-font-line-height--comfortable);color:var(--color-on-primary)}.gxg-title-03{font-family:var(--ds-base-font-family-primary);font-weight:var(--ds-title-03-font-weight);font-size:var(--ds-title-03-font-size);letter-spacing:var(--ds-base-font-letter-spacing--regular);color:var(--ds-base-font-color);text-align:start;text-transform:uppercase;line-height:var(--ds-base-font-line-height--comfortable)}.gxg-title-03--negative{font-family:var(--ds-base-font-family-primary);font-weight:var(--ds-title-03-font-weight);font-size:var(--ds-title-03-font-size);letter-spacing:var(--ds-base-font-letter-spacing--regular);color:var(--ds-base-font-color);text-align:start;text-transform:uppercase;line-height:var(--ds-base-font-line-height--comfortable);color:var(--ds-base-font-color--negative)}.gxg-title-04{font-family:var(--ds-base-font-family-primary);font-weight:var(--ds-title-04-font-weight);font-size:var(--ds-title-04-font-size);letter-spacing:var(--ds-base-font-letter-spacing--comfortable);color:var(--ds-base-font-color);text-align:start;line-height:var(--ds-base-font-line-height--comfortable)}.gxg-title-04--negative{font-family:var(--ds-base-font-family-primary);font-weight:var(--ds-title-04-font-weight);font-size:var(--ds-title-04-font-size);letter-spacing:var(--ds-base-font-letter-spacing--comfortable);color:var(--ds-base-font-color);text-align:start;line-height:var(--ds-base-font-line-height--comfortable);color:var(--ds-base-font-color--negative)}.gxg-title-05{font-family:var(--ds-base-font-family-primary);font-weight:var(--ds-title-05-font-weight);font-size:var(--ds-title-05-font-size);letter-spacing:var(--ds-base-font-letter-spacing--regular);color:var(--ds-base-font-color);text-align:start;line-height:var(--ds-base-font-line-height--comfortable)}.gxg-title-05--negative{font-family:var(--ds-base-font-family-primary);font-weight:var(--ds-title-05-font-weight);font-size:var(--ds-title-05-font-size);letter-spacing:var(--ds-base-font-letter-spacing--regular);color:var(--ds-base-font-color);text-align:start;line-height:var(--ds-base-font-line-height--comfortable);color:var(--ds-base-font-color--negative)}.gxg-text{font-family:var(--ds-base-font-family-primary);font-size:var(--ds-base-font-size);color:var(--ds-base-font-size-color);font-weight:var(--ds-base-font-size-weight);line-height:var(--ds-base-font-line-height--comfortable)}.gxg-text--negative{font-family:var(--ds-base-font-family-primary);font-size:var(--ds-base-font-size);color:var(--ds-base-font-size-color);font-weight:var(--ds-base-font-size-weight);line-height:var(--ds-base-font-line-height--comfortable);color:var(--ds-base-font-color--negative)}.gxg-text--gray{font-family:var(--ds-base-font-family-primary);font-size:var(--ds-base-font-size);color:var(--ds-base-font-size-color);font-weight:var(--ds-base-font-size-weight);line-height:var(--ds-base-font-line-height--comfortable);color:var(--ds-base-font-color--dimmed)}.gxg-quote{font-family:var(--ds-base-font-family-primary);font-size:var(--ds-base-font-size);color:var(--ds-base-font-size-color);font-weight:var(--ds-base-font-size-weight);line-height:var(--ds-base-font-line-height--comfortable);font-style:italic}.gxg-quote--negative{color:var(--ds-base-font-color--negative)}.gxg-link{line-height:unset;font-family:var(--ds-base-font-family-primary);font-size:var(--ds-base-font-size);color:var(--ds-base-font-size-color);font-weight:var(--ds-base-font-size-weight);line-height:var(--ds-base-font-line-height--comfortable);color:var(--ds-base-font-color--link);text-decoration:underline;cursor:pointer;display:inline-block}.gxg-link:hover{color:var(--ds-base-font-color--link-hover)}.gxg-link:active{color:var(--ds-base-font-color--link-active)}.gxg-link-gray{line-height:unset;font-family:var(--ds-base-font-family-primary);font-size:var(--ds-base-font-size);color:var(--ds-base-font-size-color);font-weight:var(--ds-base-font-size-weight);line-height:var(--ds-base-font-line-height--comfortable);color:var(--ds-base-font-color--link);text-decoration:underline;cursor:pointer;display:inline-block;color:var(--ds-base-font-color--dimmed)}.gxg-link-gray:hover{line-height:unset;font-family:var(--ds-base-font-family-primary);font-size:var(--ds-base-font-size);color:var(--ds-base-font-size-color);font-weight:var(--ds-base-font-size-weight);line-height:var(--ds-base-font-line-height--comfortable);color:var(--ds-base-font-color--link);text-decoration:underline;cursor:pointer;display:inline-block;color:var(--ds-base-font-color--dimmed);filter:brightness(1.4)}.gxg-alert-error{font-family:var(--ds-base-font-family-primary);font-size:var(--ds-base-font-size);color:var(--ds-base-font-size-color);font-weight:var(--ds-base-font-size-weight);line-height:var(--ds-base-font-line-height--comfortable);color:var(--ds-base-font-color--error);display:inline-block}.gxg-alert-warning{font-family:var(--ds-base-font-family-primary);font-size:var(--ds-base-font-size);color:var(--ds-base-font-size-color);font-weight:var(--ds-base-font-size-weight);line-height:var(--ds-base-font-line-height--comfortable);color:var(--ds-base-font-color--warning);display:inline-block}.gxg-alert-success{font-family:var(--ds-base-font-family-primary);font-size:var(--ds-base-font-size);color:var(--ds-base-font-size-color);font-weight:var(--ds-base-font-size-weight);line-height:var(--ds-base-font-line-height--comfortable);color:var(--ds-base-font-color--success);display:inline-block}.gxg-tab--disabled{color:var(--color-primary-disabled);pointer-events:none}.gxg-tab--disabled[disabled]{color:var(--color-primary-disabled);pointer-events:none}.gxg-label{font-family:var(--ds-base-font-family-primary);font-weight:var(--gxg-label-font-weight);font-size:var(--gxg-label-font-size);color:var(--gxg-label-color);text-align:center;line-height:1.455em;display:flex;align-items:center}.gxg-label:hover{color:var(--color-primary-hover)}.gxg-label:focus{color:var(--color-primary-active)}.gxg-label:active{color:var(--color-primary-active)}.gxg-label[disabled]{color:var(--color-primary-disabled)}.gxg-label--negative{color:var(--color-on-primary)}.gxg-label--negative[disabled]{color:var(--color-on-disabled)}.gxg-scrollbar{}.gxg-scrollbar::-webkit-scrollbar{width:var(--gxg-scrollbar-width);height:var(--gxg-scrollbar-width)}.gxg-scrollbar::-webkit-scrollbar-track{background-color:var(--gxg-scrollbar-track-background);border-radius:var(--gxg-scrollbar-track-border-radius)}.gxg-scrollbar::-webkit-scrollbar-thumb{background-color:var(--gxg-scrollbar-track-thumb-background);border-radius:var(--gxg-scrollbar-track-thumb-radius)}.gxg-scrollbar::-webkit-scrollbar-thumb:hover{background-color:var(--gxg-scrollbar-track-thumb-hover-background)}.gxg-scrollbar::-webkit-scrollbar-corner{background:rgba(0, 0, 0, 0)}@keyframes spin{0%{transform:rotate(0deg)}100%{transform:rotate(360deg)}}:host{display:grid;block-size:100%}.card-regular{background-color:var(--mer-surface__elevation--01);border:var(--mer-border__width--sm) solid var(--mer-border-color__on-elevation--01);border-radius:var(--mer-border__radius--md);padding:var(--mer-spacing--md) var(--mer-spacing--md);display:grid}.card-small{background-color:var(--mer-surface__elevation--02);border-radius:var(--mer-border__radius--sm);padding:var(--mer-spacing--sm) var(--mer-spacing--sm)}.card-small--actionable:hover{background-color:var(--mer-color__neutral-gray--600)}.card-small--actionable:active{background-color:var(--mer-color__neutral-gray--650)}.card-small:focus-visible{outline:var(--focus__outline-width) var(--focus__outline-style) var(--focus__outline-color);outline-offset:var(--focus__outline-offset)}.empty-state{block-size:100%;display:flex;align-items:center;justify-content:center;flex-direction:column;gap:var(--mer-spacing--sm);text-align:center}.empty-state__title,.empty-state__button,.empty-state__link{max-inline-size:300px}.opacity-0{opacity:0}.opacity-1{opacity:1}.display-contents{display:contents}.gxi-hidden{display:none !important}.gxi-full-height{height:100%}.gxi-overflow-auto{overflow:auto}.gxi-display-flex{display:flex}.align-start{display:flex;align-items:start}.align-center{display:flex;align-items:center}.align-end{display:flex;align-items:end}.overflow-auto{overflow:auto}.justify-start{display:flex;justify-content:start}.justify-center{display:flex;justify-content:center}.justify-end{display:flex;justify-content:end}.grid{display:grid;grid-row-gap:var(--gx-ide-grid-row-gap);grid-column-gap:var(--gx-ide-grid-column-gap);grid-template-rows:auto}ch-grid-cell{display:flex}ch-grid{overflow:auto;height:100%}ch-grid-column{z-index:99;border-bottom:1px solid var(--mer-color__neutral-gray--800)}ch-grid-column:first-child{padding-inline-start:var(--gx-ide-container__padding) !important}ch-grid-column:last-child{padding-inline-end:var(--gx-ide-container__padding) !important}ch-grid-cell{--mer-spacing--xs:var(--gx-ide-container__padding)}.layout{display:grid;gap:var(--mer-spacing--lg);box-sizing:border-box}.layout--two-cols{grid-template-columns:1fr 1fr}.layout--space-above{padding-block-start:var(--mer-spacing--lg)}gxg-tabs{box-shadow:none}:host(.gx-ide-component){height:100% !important;display:flex !important;flex-direction:column !important}:host(:focus-within) gx-ide-top-bar::part(wrapper){background-color:var(--color-secondary-enabled)}.gx-ide-main-wrapper{color:var(--gx-ide-component-text-color);font-weight:var(--mer-font__weight--regular);font-size:var(--mer-font__size--xs);font-family:var(--mer-font-family--primary);height:100%;background-color:var(--gx-ide-component-background-color);display:flex;flex-direction:column;flex-grow:1;box-sizing:border-box}.gx-ide-main{flex-grow:1;overflow-y:auto;}.gx-ide-main::-webkit-scrollbar{width:var(--gxg-scrollbar-width);height:var(--gxg-scrollbar-width)}.gx-ide-main::-webkit-scrollbar-track{background-color:var(--gxg-scrollbar-track-background);border-radius:var(--gxg-scrollbar-track-border-radius)}.gx-ide-main::-webkit-scrollbar-thumb{background-color:var(--gxg-scrollbar-track-thumb-background);border-radius:var(--gxg-scrollbar-track-thumb-radius)}.gx-ide-main::-webkit-scrollbar-thumb:hover{background-color:var(--gxg-scrollbar-track-thumb-hover-background)}.gx-ide-main::-webkit-scrollbar-corner{background:rgba(0, 0, 0, 0)}.gx-ide-overflow{overflow-y:auto;}.gx-ide-overflow::-webkit-scrollbar{width:var(--gxg-scrollbar-width);height:var(--gxg-scrollbar-width)}.gx-ide-overflow::-webkit-scrollbar-track{background-color:var(--gxg-scrollbar-track-background);border-radius:var(--gxg-scrollbar-track-border-radius)}.gx-ide-overflow::-webkit-scrollbar-thumb{background-color:var(--gxg-scrollbar-track-thumb-background);border-radius:var(--gxg-scrollbar-track-thumb-radius)}.gx-ide-overflow::-webkit-scrollbar-thumb:hover{background-color:var(--gxg-scrollbar-track-thumb-hover-background)}.gx-ide-overflow::-webkit-scrollbar-corner{background:rgba(0, 0, 0, 0)}.tree-view-primary{font-size:var(--mer-font__size--2xs)}p{margin:0;font-size:var(--mer-font__size--xxs)}.buttons-container{display:flex;gap:var(--mer-spacing--xs)}:root{--ui-animaton-speed:0.2s}.gxg-title-01{font-family:var(--ds-base-font-family-primary);font-weight:var(--ds-title-01-font-weight);font-size:var(--ds-title-01-font-size);letter-spacing:var(--ds-base-font-letter-spacing--comfortable);color:var(--ds-base-font-color);text-align:start;line-height:var(--ds-base-font-line-height--comfortable)}.gxg-title-01--negative{font-family:var(--ds-base-font-family-primary);font-weight:var(--ds-title-01-font-weight);font-size:var(--ds-title-01-font-size);letter-spacing:var(--ds-base-font-letter-spacing--comfortable);color:var(--ds-base-font-color);text-align:start;line-height:var(--ds-base-font-line-height--comfortable);color:var(--ds-base-font-color--negative)}.gxg-title-02{font-family:var(--ds-base-font-family-primary);font-weight:var(--ds-title-02-font-weight);font-size:var(--ds-title-02-font-size);letter-spacing:var(--ds-base-font-letter-spacing--regular);color:var(--ds-base-font-color);text-align:start;text-transform:uppercase;line-height:var(--ds-base-font-line-height--comfortable)}.gxg-title-02--negative{font-family:var(--ds-base-font-family-primary);font-weight:var(--ds-title-02-font-weight);font-size:var(--ds-title-02-font-size);letter-spacing:var(--ds-base-font-letter-spacing--regular);color:var(--ds-base-font-color);text-align:start;text-transform:uppercase;line-height:var(--ds-base-font-line-height--comfortable);color:var(--color-on-primary)}.gxg-title-03{font-family:var(--ds-base-font-family-primary);font-weight:var(--ds-title-03-font-weight);font-size:var(--ds-title-03-font-size);letter-spacing:var(--ds-base-font-letter-spacing--regular);color:var(--ds-base-font-color);text-align:start;text-transform:uppercase;line-height:var(--ds-base-font-line-height--comfortable)}.gxg-title-03--negative{font-family:var(--ds-base-font-family-primary);font-weight:var(--ds-title-03-font-weight);font-size:var(--ds-title-03-font-size);letter-spacing:var(--ds-base-font-letter-spacing--regular);color:var(--ds-base-font-color);text-align:start;text-transform:uppercase;line-height:var(--ds-base-font-line-height--comfortable);color:var(--ds-base-font-color--negative)}.gxg-title-04{font-family:var(--ds-base-font-family-primary);font-weight:var(--ds-title-04-font-weight);font-size:var(--ds-title-04-font-size);letter-spacing:var(--ds-base-font-letter-spacing--comfortable);color:var(--ds-base-font-color);text-align:start;line-height:var(--ds-base-font-line-height--comfortable)}.gxg-title-04--negative{font-family:var(--ds-base-font-family-primary);font-weight:var(--ds-title-04-font-weight);font-size:var(--ds-title-04-font-size);letter-spacing:var(--ds-base-font-letter-spacing--comfortable);color:var(--ds-base-font-color);text-align:start;line-height:var(--ds-base-font-line-height--comfortable);color:var(--ds-base-font-color--negative)}.gxg-title-05{font-family:var(--ds-base-font-family-primary);font-weight:var(--ds-title-05-font-weight);font-size:var(--ds-title-05-font-size);letter-spacing:var(--ds-base-font-letter-spacing--regular);color:var(--ds-base-font-color);text-align:start;line-height:var(--ds-base-font-line-height--comfortable)}.gxg-title-05--negative{font-family:var(--ds-base-font-family-primary);font-weight:var(--ds-title-05-font-weight);font-size:var(--ds-title-05-font-size);letter-spacing:var(--ds-base-font-letter-spacing--regular);color:var(--ds-base-font-color);text-align:start;line-height:var(--ds-base-font-line-height--comfortable);color:var(--ds-base-font-color--negative)}.gxg-text{font-family:var(--ds-base-font-family-primary);font-size:var(--ds-base-font-size);color:var(--ds-base-font-size-color);font-weight:var(--ds-base-font-size-weight);line-height:var(--ds-base-font-line-height--comfortable)}.gxg-text--negative{font-family:var(--ds-base-font-family-primary);font-size:var(--ds-base-font-size);color:var(--ds-base-font-size-color);font-weight:var(--ds-base-font-size-weight);line-height:var(--ds-base-font-line-height--comfortable);color:var(--ds-base-font-color--negative)}.gxg-text--gray{font-family:var(--ds-base-font-family-primary);font-size:var(--ds-base-font-size);color:var(--ds-base-font-size-color);font-weight:var(--ds-base-font-size-weight);line-height:var(--ds-base-font-line-height--comfortable);color:var(--ds-base-font-color--dimmed)}.gxg-quote{font-family:var(--ds-base-font-family-primary);font-size:var(--ds-base-font-size);color:var(--ds-base-font-size-color);font-weight:var(--ds-base-font-size-weight);line-height:var(--ds-base-font-line-height--comfortable);font-style:italic}.gxg-quote--negative{color:var(--ds-base-font-color--negative)}.gxg-link{line-height:unset;font-family:var(--ds-base-font-family-primary);font-size:var(--ds-base-font-size);color:var(--ds-base-font-size-color);font-weight:var(--ds-base-font-size-weight);line-height:var(--ds-base-font-line-height--comfortable);color:var(--ds-base-font-color--link);text-decoration:underline;cursor:pointer;display:inline-block}.gxg-link:hover{color:var(--ds-base-font-color--link-hover)}.gxg-link:active{color:var(--ds-base-font-color--link-active)}.gxg-link-gray{line-height:unset;font-family:var(--ds-base-font-family-primary);font-size:var(--ds-base-font-size);color:var(--ds-base-font-size-color);font-weight:var(--ds-base-font-size-weight);line-height:var(--ds-base-font-line-height--comfortable);color:var(--ds-base-font-color--link);text-decoration:underline;cursor:pointer;display:inline-block;color:var(--ds-base-font-color--dimmed)}.gxg-link-gray:hover{line-height:unset;font-family:var(--ds-base-font-family-primary);font-size:var(--ds-base-font-size);color:var(--ds-base-font-size-color);font-weight:var(--ds-base-font-size-weight);line-height:var(--ds-base-font-line-height--comfortable);color:var(--ds-base-font-color--link);text-decoration:underline;cursor:pointer;display:inline-block;color:var(--ds-base-font-color--dimmed);filter:brightness(1.4)}.gxg-alert-error{font-family:var(--ds-base-font-family-primary);font-size:var(--ds-base-font-size);color:var(--ds-base-font-size-color);font-weight:var(--ds-base-font-size-weight);line-height:var(--ds-base-font-line-height--comfortable);color:var(--ds-base-font-color--error);display:inline-block}.gxg-alert-warning{font-family:var(--ds-base-font-family-primary);font-size:var(--ds-base-font-size);color:var(--ds-base-font-size-color);font-weight:var(--ds-base-font-size-weight);line-height:var(--ds-base-font-line-height--comfortable);color:var(--ds-base-font-color--warning);display:inline-block}.gxg-alert-success{font-family:var(--ds-base-font-family-primary);font-size:var(--ds-base-font-size);color:var(--ds-base-font-size-color);font-weight:var(--ds-base-font-size-weight);line-height:var(--ds-base-font-line-height--comfortable);color:var(--ds-base-font-color--success);display:inline-block}.gxg-tab--disabled{color:var(--color-primary-disabled);pointer-events:none}.gxg-tab--disabled[disabled]{color:var(--color-primary-disabled);pointer-events:none}.gxg-label{font-family:var(--ds-base-font-family-primary);font-weight:var(--gxg-label-font-weight);font-size:var(--gxg-label-font-size);color:var(--gxg-label-color);text-align:center;line-height:1.455em;display:flex;align-items:center}.gxg-label:hover{color:var(--color-primary-hover)}.gxg-label:focus{color:var(--color-primary-active)}.gxg-label:active{color:var(--color-primary-active)}.gxg-label[disabled]{color:var(--color-primary-disabled)}.gxg-label--negative{color:var(--color-on-primary)}.gxg-label--negative[disabled]{color:var(--color-on-disabled)}.gxg-scrollbar{}.gxg-scrollbar::-webkit-scrollbar{width:var(--gxg-scrollbar-width);height:var(--gxg-scrollbar-width)}.gxg-scrollbar::-webkit-scrollbar-track{background-color:var(--gxg-scrollbar-track-background);border-radius:var(--gxg-scrollbar-track-border-radius)}.gxg-scrollbar::-webkit-scrollbar-thumb{background-color:var(--gxg-scrollbar-track-thumb-background);border-radius:var(--gxg-scrollbar-track-thumb-radius)}.gxg-scrollbar::-webkit-scrollbar-thumb:hover{background-color:var(--gxg-scrollbar-track-thumb-hover-background)}.gxg-scrollbar::-webkit-scrollbar-corner{background:rgba(0, 0, 0, 0)}:host{font-family:var(--mer-font-family--primary);display:block;height:100%;flex-basis:286px;flex-shrink:0;height:100%;overflow-y:auto}.gx-ide-main-wrapper{padding:0 10px 52px 10px;background-color:var(--mer-surface);height:100%;display:grid;grid-template-rows:auto 1fr auto;gap:var(--mer-spacing--sm)}.header{padding-block-start:var(--mer-spacing--sm);display:flex;flex-direction:column}.header__actions-wrapper{display:flex;gap:var(--ai-assistant-header-actions-gap);margin-inline-start:auto}.header__first-row{display:flex;gap:var(--mer-spacing--xs);align-items:center;justify-content:space-between}.header__filter{margin-block-start:var(--mer-spacing--xs)}.header__second-row{transition:100ms grid-template-rows;display:grid;grid-template-rows:0fr}.header__second-row--visible{grid-template-rows:1fr}.header .filter-inner-wrapper{overflow:hidden}.messages-wrapper{position:relative;overflow:auto;display:flex;flex-direction:column;scroll-behavior:smooth;}.messages-wrapper::-webkit-scrollbar{width:var(--gxg-scrollbar-width);height:var(--gxg-scrollbar-width)}.messages-wrapper::-webkit-scrollbar-track{background-color:var(--gxg-scrollbar-track-background);border-radius:var(--gxg-scrollbar-track-border-radius)}.messages-wrapper::-webkit-scrollbar-thumb{background-color:var(--gxg-scrollbar-track-thumb-background);border-radius:var(--gxg-scrollbar-track-thumb-radius)}.messages-wrapper::-webkit-scrollbar-thumb:hover{background-color:var(--gxg-scrollbar-track-thumb-hover-background)}.messages-wrapper::-webkit-scrollbar-corner{background:rgba(0, 0, 0, 0)}.messages{display:flex;flex-direction:column;list-style-type:none;padding:0;margin:0}.prompt{position:relative;margin-top:auto}.prompt__textarea::part(textarea-wrapper){border:none}.prompt__textarea::part(textarea){border:none;background-color:var(--mer-color__neutral-gray--800)}.prompt__shortcuts{position:absolute;display:flex;align-items:center;gap:var(--mer-spacing--2xs);padding-inline-end:var(--mer-spacing--xs);right:0;top:0;height:100%}.prompt__shortcut{color:var(--mer-color__neutral-gray--400);font-size:var(--mer-font__size--2xs);padding:var(--mer-spacing--3xs) var(--mer-spacing--xs);background-color:var(--mer-color__neutral-gray--700);border-radius:var(--mer-border__radius--xs)}";
6
6
 
7
7
  const GxIdeTemplate = /*@__PURE__*/ proxyCustomElement(class GxIdeTemplate extends HTMLElement {
8
8
  constructor() {
@@ -205,7 +205,7 @@ const GxIdeTemplate = /*@__PURE__*/ proxyCustomElement(class GxIdeTemplate exten
205
205
  /* Doesn't seems to work without the setTimeout */
206
206
  this.textAreaEl.focus();
207
207
  this.setFocus = false;
208
- }, 0);
208
+ }, 50);
209
209
  }
210
210
  setTimeout(() => {
211
211
  this.scrollToBottom();
@@ -251,7 +251,8 @@ const GxIdeTemplate = /*@__PURE__*/ proxyCustomElement(class GxIdeTemplate exten
251
251
  "header__second-row": true,
252
252
  "header__second-row--visible": this.showFilter
253
253
  } }, h("div", { class: "filter-inner-wrapper" }, h("gxg-form-text", { class: "header__filter", onInput: this.filterMessagesHandler, ref: el => (this.filterEl = el) })))) : null), h("div", { class: {
254
- "messages-wrapper": true
254
+ "messages-wrapper": true,
255
+ "scrollable": true
255
256
  }, ref: el => (this.messagesWrapperEl = el) }, ((_a = this.messages) === null || _a === void 0 ? void 0 : _a.length) ? (h("ol", { class: { messages: true } }, this.messages.map((message, i) => {
256
257
  return this.renderMessage(message, i);
257
258
  }))) : null), h("div", { class: {