@eclipse-docks/extension-howto-system 0.8.13 → 0.8.15
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{howto-extension-Df54EW1X.js → howto-extension-BbJ7J894.js} +6 -11
- package/dist/{howto-extension-Df54EW1X.js.map → howto-extension-BbJ7J894.js.map} +1 -1
- package/dist/{i18n.de-6a7MkAVi.js → i18n.de-CmqGh2TT.js} +2 -3
- package/dist/{i18n.de-6a7MkAVi.js.map → i18n.de-CmqGh2TT.js.map} +1 -1
- package/dist/{i18n.en-C6vlH27W.js → i18n.en-DoB47dTB.js} +2 -3
- package/dist/{i18n.en-C6vlH27W.js.map → i18n.en-DoB47dTB.js.map} +1 -1
- package/dist/index.js +4 -5
- package/package.json +1 -1
|
@@ -3,7 +3,7 @@ import { AI_SETTINGS_KEY, OPEN_AI_SETTINGS_COMMAND, TOPIC, cognitiveRuntime } fr
|
|
|
3
3
|
import { css, html, nothing } from "lit";
|
|
4
4
|
import { customElement, query, state } from "lit/decorators.js";
|
|
5
5
|
import _decorate from "@oxc-project/runtime/helpers/decorate";
|
|
6
|
-
|
|
6
|
+
// src/howto-service.ts
|
|
7
7
|
var logger$1 = createLogger("HowToService");
|
|
8
8
|
var HOWTO_CONTRIBUTION_TARGET = "system.howtos";
|
|
9
9
|
/**
|
|
@@ -87,8 +87,7 @@ var HowToService = class {
|
|
|
87
87
|
}
|
|
88
88
|
};
|
|
89
89
|
var howToService = new HowToService();
|
|
90
|
-
|
|
91
|
-
//#region src/contributions/onboarding-howto-contributions.ts
|
|
90
|
+
// src/contributions/onboarding-howto-contributions.ts
|
|
92
91
|
var ONBOARDING_FILE_NAME = "welcome.txt";
|
|
93
92
|
async function getOnboardingFilePath() {
|
|
94
93
|
if (!await workspaceService.getWorkspace()) return null;
|
|
@@ -235,8 +234,7 @@ contributionRegistry.registerContribution(HOWTO_CONTRIBUTION_TARGET, {
|
|
|
235
234
|
}
|
|
236
235
|
]
|
|
237
236
|
});
|
|
238
|
-
|
|
239
|
-
//#region src/contributions/ai-setup-howto-contributions.ts
|
|
237
|
+
// src/contributions/ai-setup-howto-contributions.ts
|
|
240
238
|
function isAIConfigEditorOpen() {
|
|
241
239
|
const activeEditor = activeEditorSignal.get();
|
|
242
240
|
if (!activeEditor) return false;
|
|
@@ -334,8 +332,7 @@ var aiSetupContribution = {
|
|
|
334
332
|
]
|
|
335
333
|
};
|
|
336
334
|
contributionRegistry.registerContribution(HOWTO_CONTRIBUTION_TARGET, aiSetupContribution);
|
|
337
|
-
|
|
338
|
-
//#region src/howto-panel.ts
|
|
335
|
+
// src/howto-panel.ts
|
|
339
336
|
var TOPIC_SHOW_HOWTO_PANEL = "howto/show-panel";
|
|
340
337
|
var TOPIC_TOGGLE_HOWTO_PANEL = "howto/toggle-panel";
|
|
341
338
|
var SETTINGS_KEY = "howto-panel";
|
|
@@ -1016,8 +1013,7 @@ _decorate([state()], DocksHowToPanel.prototype, "stepStates", void 0);
|
|
|
1016
1013
|
_decorate([state()], DocksHowToPanel.prototype, "isVisible", void 0);
|
|
1017
1014
|
_decorate([query("docks-floating-panel")], DocksHowToPanel.prototype, "floatingPanel", void 0);
|
|
1018
1015
|
DocksHowToPanel = _decorate([customElement("docks-howto-panel")], DocksHowToPanel);
|
|
1019
|
-
|
|
1020
|
-
//#region src/howto-extension.ts
|
|
1016
|
+
// src/howto-extension.ts
|
|
1021
1017
|
var logger = createLogger("HowToExtension");
|
|
1022
1018
|
/**
|
|
1023
1019
|
* HowTo System Extension
|
|
@@ -1083,7 +1079,6 @@ function howToExtension(context) {
|
|
|
1083
1079
|
});
|
|
1084
1080
|
logger.info("HowTo system extension initialized");
|
|
1085
1081
|
}
|
|
1086
|
-
//#endregion
|
|
1087
1082
|
export { HOWTO_CONTRIBUTION_TARGET, howToExtension as default, howToService };
|
|
1088
1083
|
|
|
1089
|
-
//# sourceMappingURL=howto-extension-
|
|
1084
|
+
//# sourceMappingURL=howto-extension-BbJ7J894.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"howto-extension-Df54EW1X.js","names":["logger","getAppName"],"sources":["../src/howto-service.ts","../src/contributions/onboarding-howto-contributions.ts","../src/contributions/ai-setup-howto-contributions.ts","../src/howto-panel.ts","../src/howto-extension.ts"],"sourcesContent":["import { contributionRegistry, TOPIC_CONTRIBUTEIONS_CHANGED } from '@eclipse-docks/core';\nimport { HowToContribution, HowToStep } from './howto-contribution';\nimport { subscribe } from '@eclipse-docks/core';\nimport { createLogger } from '@eclipse-docks/core';\nimport { Signal } from '@lit-labs/signals';\n\nconst logger = createLogger('HowToService');\n\nexport const HOWTO_CONTRIBUTION_TARGET = 'system.howtos';\n\n/**\n * HowTo Service\n * \n * Manages HowTo contributions by reading from the contribution registry.\n * Provides methods to retrieve and manage workflows.\n */\nexport class HowToService {\n private contributions: Map<string, HowToContribution> = new Map();\n\n constructor() {\n // Load initial contributions\n this.loadContributions();\n\n // Subscribe to contribution changes\n subscribe(TOPIC_CONTRIBUTEIONS_CHANGED, (event: any) => {\n if (event.target === HOWTO_CONTRIBUTION_TARGET) {\n this.loadContributions();\n }\n });\n }\n\n /**\n * Load contributions from the contribution registry\n */\n private loadContributions(): void {\n const contributions = contributionRegistry.getContributions(HOWTO_CONTRIBUTION_TARGET) as HowToContribution[];\n \n this.contributions.clear();\n \n for (const contribution of contributions) {\n // Validate contribution\n if (!contribution.id) {\n logger.warn('HowTo contribution missing id, skipping');\n continue;\n }\n\n if (!contribution.label) {\n // Use title as label if label is not provided\n // Handle both string and function types\n const title = typeof contribution.title === 'function' \n ? contribution.title() \n : contribution.title;\n contribution.label = title;\n }\n\n if (!contribution.steps || contribution.steps.length === 0) {\n logger.warn(`HowTo contribution \"${contribution.id}\" has no steps, skipping`);\n continue;\n }\n\n // Validate step IDs are unique\n const stepIds = new Set<string>();\n for (const step of contribution.steps) {\n if (stepIds.has(step.id)) {\n logger.warn(`HowTo contribution \"${contribution.id}\" has duplicate step ID: \"${step.id}\"`);\n continue;\n }\n stepIds.add(step.id);\n }\n\n this.contributions.set(contribution.id, contribution);\n const title = typeof contribution.title === 'function' \n ? contribution.title() \n : contribution.title;\n logger.debug(`Loaded HowTo contribution: ${title} (${contribution.id})`);\n }\n\n logger.info(`Loaded ${this.contributions.size} HowTo contributions`);\n }\n\n /**\n * Get a HowTo Contribution by ID\n * \n * @param contributionId The ID of the contribution\n * @returns The contribution or undefined if not found\n */\n getContribution(contributionId: string): HowToContribution | undefined {\n return this.contributions.get(contributionId);\n }\n\n /**\n * Get all registered HowTo Contributions\n * \n * @returns Array of all contributions\n */\n getAllContributions(): HowToContribution[] {\n return Array.from(this.contributions.values());\n }\n\n /**\n * Get HowTo Contributions by category\n * \n * @param category The category to filter by\n * @returns Array of contributions in the category\n */\n getContributionsByCategory(category: string): HowToContribution[] {\n return Array.from(this.contributions.values())\n .filter(contrib => contrib.category === category);\n }\n\n /**\n * Check if a contribution exists\n * \n * @param contributionId The ID of the contribution\n * @returns True if the contribution exists\n */\n hasContribution(contributionId: string): boolean {\n return this.contributions.has(contributionId);\n }\n}\n\nexport const howToService = new HowToService();\n\n","import { contributionRegistry, workspaceService, File, TOPIC_WORKSPACE_CHANGED, TOPIC_WORKSPACE_CONNECTED, activeEditorSignal, partDirtySignal, subscribe, appLoaderService } from '@eclipse-docks/core';\nimport type { EditorContentProvider } from '@eclipse-docks/core';\nimport { watchSignal } from '@eclipse-docks/core';\nimport { HOWTO_CONTRIBUTION_TARGET } from '../howto-service';\nimport type { HowToContribution, HowToContext } from '../howto-contribution';\n\nconst ONBOARDING_FILE_NAME = 'welcome.txt';\n\nasync function getOnboardingFilePath(): Promise<string | null> {\n const workspace = await workspaceService.getWorkspace();\n if (!workspace) return null;\n const folders = await workspaceService.getFolders();\n if (folders.length === 0) return null;\n const firstFolderName = folders[0].name;\n return `${firstFolderName}/${ONBOARDING_FILE_NAME}`;\n}\n\n/**\n * Type guard to check if an editor implements EditorContentProvider\n */\nfunction isEditorContentProvider(editor: any): editor is EditorContentProvider {\n return editor &&\n typeof editor.getFilePath === 'function';\n}\n\n/**\n * Checks if a workspace is selected\n */\nasync function isWorkspaceSelected(): Promise<boolean> {\n return workspaceService.isConnected();\n}\n\n/**\n * Checks if the onboarding file exists\n */\nasync function onboardingFileExists(): Promise<boolean> {\n const path = await getOnboardingFilePath();\n if (!path) return false;\n const workspace = await workspaceService.getWorkspace();\n if (!workspace) return false;\n try {\n const resource = await workspace.getResource(path);\n return resource instanceof File;\n } catch {\n return false;\n }\n}\n\n/**\n * Checks if the onboarding file is open in an editor\n */\nfunction isOnboardingFileOpen(): boolean {\n const activeEditor = activeEditorSignal.get();\n if (!activeEditor || !isEditorContentProvider(activeEditor)) {\n return false;\n }\n const filePath = activeEditor.getFilePath();\n return filePath === ONBOARDING_FILE_NAME || filePath?.endsWith('/' + ONBOARDING_FILE_NAME) === true;\n}\n\n/**\n * Checks if the active editor is dirty (has unsaved changes)\n * Returns true only if the onboarding file is open AND dirty\n */\nfunction isActiveEditorDirty(): boolean {\n if (!isOnboardingFileOpen()) return false;\n \n const activeEditor = activeEditorSignal.get();\n if (!activeEditor) return false;\n \n return activeEditor.isDirty() === true;\n}\n\n/**\n * Checks if the active editor is clean (no unsaved changes)\n * Returns true only if the onboarding file is open AND not dirty\n */\nfunction isActiveEditorClean(): boolean {\n if (!isOnboardingFileOpen()) return false;\n \n const activeEditor = activeEditorSignal.get();\n if (!activeEditor) return false;\n \n return activeEditor.isDirty() === false;\n}\n\n/**\n * Checks if the onboarding file is closed (not open in any editor)\n */\nfunction isOnboardingFileClosed(): boolean {\n return !isOnboardingFileOpen();\n}\n\n// Get current app name for the title\nfunction getAppName(): string {\n const currentApp = appLoaderService.getCurrentApp();\n return currentApp?.name || 'AppSpace';\n}\n\n// Create the onboarding HowTo contribution\n// Using callback functions so the app name is read when the HowTo is displayed\nconst onboardingContribution: HowToContribution = {\n id: 'docks.onboarding',\n title: () => `Welcome to ${getAppName()}`,\n description: () => `Get started with ${getAppName()} by learning the basics of workspace and file management`,\n icon: 'graduation-cap',\n // label will be set from title in howto-service.ts\n label: '',\n category: 'Getting Started',\n initialize: (context: HowToContext) => {\n // Set up subscriptions for workspace and editor changes\n const cleanups: (() => void)[] = [];\n\n // Subscribe to workspace events\n subscribe(TOPIC_WORKSPACE_CHANGED, () => {\n context.requestUpdate();\n });\n\n subscribe(TOPIC_WORKSPACE_CONNECTED, () => {\n context.requestUpdate();\n });\n\n // Watch editor signals\n cleanups.push(\n watchSignal(activeEditorSignal, () => {\n context.requestUpdate();\n })\n );\n\n cleanups.push(\n watchSignal(partDirtySignal, () => {\n context.requestUpdate();\n })\n );\n\n // Return cleanup function\n return () => {\n cleanups.forEach(cleanup => cleanup());\n };\n },\n steps: [\n {\n id: 'create-text-file',\n title: 'Create welcome.txt',\n description: 'Create a new text file called \"welcome.txt\" in your workspace. If you don\\'t have a workspace selected, choose one first.',\n preCondition: async () => {\n // Workspace must be selected\n return await isWorkspaceSelected();\n },\n postCondition: async () => {\n return await onboardingFileExists();\n },\n command: 'touch',\n commandParams: async () => {\n const path = await getOnboardingFilePath();\n return path ? {\n path,\n contents: 'Welcome to AppSpace!\\n\\nThis is your first file. You can edit it and save your changes.'\n } : {};\n }\n },\n {\n id: 'open-text-file',\n title: 'Open welcome.txt',\n description: 'Open the \"welcome.txt\" file in the editor.',\n preCondition: async () => {\n return await onboardingFileExists();\n },\n postCondition: () => {\n return isOnboardingFileOpen();\n },\n command: 'open_editor',\n commandParams: async () => {\n const path = await getOnboardingFilePath();\n return path ? { path } : {};\n }\n },\n {\n id: 'edit-and-save',\n title: 'Type something and save',\n description: 'Type some text in the editor to modify the file, then save it using Ctrl+S or the save button.',\n preCondition: () => {\n return isOnboardingFileOpen();\n },\n postCondition: () => {\n // File must be open, was dirty (edited), and is now clean (saved)\n // Check that file is open and clean (saved)\n return isActiveEditorClean();\n },\n // No command - user manually edits and saves\n },\n {\n id: 'close-text-file',\n title: 'Close the file',\n description: 'Close the editor tab by clicking the X button on the tab.',\n preCondition: () => {\n return isOnboardingFileOpen();\n },\n postCondition: () => {\n return isOnboardingFileClosed();\n },\n // No command - user manually closes the tab\n }\n ]\n};\n\n// Register the contribution\ncontributionRegistry.registerContribution<HowToContribution>(HOWTO_CONTRIBUTION_TARGET, onboardingContribution);\n\n","import {\n contributionRegistry,\n activeEditorSignal,\n appLoaderService,\n partDirtySignal,\n subscribe,\n unsubscribe,\n watchSignal,\n} from '@eclipse-docks/core';\nimport {\n AI_SETTINGS_KEY,\n OPEN_AI_SETTINGS_COMMAND,\n TOPIC,\n cognitiveRuntime,\n} from '@eclipse-docks/extension-ai-system/api';\nimport { HOWTO_CONTRIBUTION_TARGET } from '../howto-service';\nimport type { HowToContribution, HowToContext } from '../howto-contribution';\n\nfunction isAIConfigEditorOpen(): boolean {\n const activeEditor = activeEditorSignal.get() as {\n input?: { key?: string };\n tagName?: string;\n localName?: string;\n } | null;\n if (!activeEditor) return false;\n if (activeEditor.input?.key === AI_SETTINGS_KEY) return true;\n const tag = (activeEditor.tagName || activeEditor.localName || '').toLowerCase();\n return tag === 'docks-cognitive-settings-editor';\n}\n\nasync function isLLMProviderConfigured(): Promise<boolean> {\n try {\n await cognitiveRuntime.whenReady();\n const settings = cognitiveRuntime.getProvidersSettings();\n if (!settings.defaultProviderId) return false;\n const provider = settings.providers.find((p) => p.id === settings.defaultProviderId);\n if (!provider?.enabled) return false;\n // Local providers (ollama/webllm) may not need a key.\n if (!provider.apiKey.trim()) {\n return /ollama|webllm|localhost|127\\.0\\.0\\.1/i.test(`${provider.id} ${provider.baseUrl}`);\n }\n return true;\n } catch {\n return false;\n }\n}\n\nfunction isAIConfigEditorDirty(): boolean {\n const activeEditor = activeEditorSignal.get() as { isDirty?: () => boolean } | null;\n if (!activeEditor || !isAIConfigEditorOpen()) return false;\n return activeEditor.isDirty?.() === true;\n}\n\nfunction isAIConfigEditorSaved(): boolean {\n return isAIConfigEditorOpen() && !isAIConfigEditorDirty();\n}\n\nfunction isAIConfigEditorClosed(): boolean {\n return !isAIConfigEditorOpen();\n}\n\nasync function hasTypedInChat(): Promise<boolean> {\n try {\n await cognitiveRuntime.whenReady();\n for (const session of cognitiveRuntime.sessions.list()) {\n const hasUserMessage = session.history.some(\n (msg) =>\n msg.role === 'user' &&\n msg.parts.some((part) => part.type === 'text' && part.text.trim() !== ''),\n );\n if (hasUserMessage) return true;\n }\n return false;\n } catch {\n return false;\n }\n}\n\nfunction getAppName(): string {\n const currentApp = appLoaderService.getCurrentApp();\n return currentApp?.name || 'AppSpace';\n}\n\nconst aiSetupContribution: HowToContribution = {\n id: 'docks.ai-setup',\n title: () => `Set up AI in ${getAppName()}`,\n description: () => `Configure an LLM provider to enable AI chat features in ${getAppName()}`,\n icon: 'robot',\n label: '',\n category: 'Getting Started',\n initialize: (context: HowToContext) => {\n const cleanups: Array<() => void> = [];\n\n cleanups.push(watchSignal(activeEditorSignal, () => context.requestUpdate()));\n cleanups.push(watchSignal(partDirtySignal, () => context.requestUpdate()));\n const providersToken = subscribe(TOPIC.providersChanged, () => context.requestUpdate());\n const sessionToken = subscribe(TOPIC.sessionChanged, () => context.requestUpdate());\n cleanups.push(() => unsubscribe(providersToken), () => unsubscribe(sessionToken));\n\n return () => {\n cleanups.forEach((cleanup) => cleanup());\n };\n },\n steps: [\n {\n id: 'open-ai-settings',\n title: 'Open AI Settings',\n description:\n 'Open the AI settings editor from the chat gear menu or the command palette.',\n preCondition: () => true,\n postCondition: () => isAIConfigEditorOpen(),\n command: OPEN_AI_SETTINGS_COMMAND,\n },\n {\n id: 'configure-llm-provider',\n title: 'Configure LLM Provider',\n description:\n 'Select a provider as default and enter an API key when required. Save your changes.',\n preCondition: () => isAIConfigEditorOpen(),\n postCondition: async () => {\n const configured = await isLLMProviderConfigured();\n const saved = isAIConfigEditorSaved();\n return configured && saved;\n },\n },\n {\n id: 'save-and-close',\n title: 'Save and Close',\n description: 'Save your changes (if not already saved) and close the AI settings editor tab.',\n preCondition: () => isAIConfigEditorOpen(),\n postCondition: () => isAIConfigEditorClosed(),\n },\n {\n id: 'type-in-chat',\n title: 'Type in Chat',\n description: 'Open the AI chat view and type a message to test your AI configuration.',\n preCondition: async () => await isLLMProviderConfigured(),\n postCondition: async () => await hasTypedInChat(),\n },\n ],\n};\n\ncontributionRegistry.registerContribution<HowToContribution>(HOWTO_CONTRIBUTION_TARGET, aiSetupContribution);\n","import { css, html, nothing } from 'lit';\nimport { customElement, query, state } from 'lit/decorators.js';\nimport { DocksWidget, type DocksFloatingPanel } from '@eclipse-docks/core';\nimport { howToService } from './howto-service';\nimport { HowToContribution, HowToStep } from './howto-contribution';\nimport { subscribe } from '@eclipse-docks/core';\nimport { commandRegistry } from '@eclipse-docks/core';\nimport { toastError } from '@eclipse-docks/core';\nimport { TOPIC_CONTRIBUTEIONS_CHANGED } from '@eclipse-docks/core';\nimport { HOWTO_CONTRIBUTION_TARGET } from './howto-service';\nimport { appSettings } from '@eclipse-docks/core';\nimport { workspaceService, TOPIC_WORKSPACE_CONNECTED } from '@eclipse-docks/core';\n\n// Event topic for showing the HowTo panel\nexport const TOPIC_SHOW_HOWTO_PANEL = 'howto/show-panel';\nexport const TOPIC_TOGGLE_HOWTO_PANEL = 'howto/toggle-panel';\n\n// Constants\nconst SETTINGS_KEY = 'howto-panel';\n\ninterface StepState {\n step: HowToStep;\n status: 'pending' | 'active' | 'completed' | 'skipped' | 'failed';\n preConditionMet?: boolean;\n postConditionMet?: boolean;\n}\n\n@customElement('docks-howto-panel')\nexport class DocksHowToPanel extends DocksWidget {\n @state()\n private contributions: HowToContribution[] = [];\n\n @state()\n private activeContributionId: string | null = null;\n\n @state()\n private stepStates: Map<string, StepState[]> = new Map();\n\n @state()\n private isVisible: boolean = false;\n\n @query('docks-floating-panel')\n private floatingPanel?: DocksFloatingPanel;\n\n private howtoCleanup?: () => void;\n\n protected async doBeforeUI() {\n this.loadContributions();\n \n subscribe(TOPIC_CONTRIBUTEIONS_CHANGED, (event: any) => {\n if (event.target === HOWTO_CONTRIBUTION_TARGET) {\n this.loadContributions();\n this.requestUpdate();\n }\n });\n\n // Subscribe to show/toggle panel events\n subscribe(TOPIC_SHOW_HOWTO_PANEL, () => this.showPanel());\n subscribe(TOPIC_TOGGLE_HOWTO_PANEL, () => this.toggleVisibility());\n\n // Load position and visibility from dialogsettings\n await this.loadSettings();\n \n // If no workspace is selected and panel wasn't explicitly hidden, show it by default\n const hasWorkspace = workspaceService.isConnected();\n if (!hasWorkspace && this.isVisible === false) {\n // Check if user has explicitly hidden it (if settings exist and visible is false)\n const settings = await appSettings.getDialogSetting(SETTINGS_KEY);\n if (!settings || settings.visible === undefined) {\n // No explicit preference, show panel when no workspace\n this.isVisible = true;\n await this.saveSettings();\n }\n }\n \n // Subscribe to workspace connection to hide panel when workspace is connected (if it was auto-shown)\n subscribe(TOPIC_WORKSPACE_CONNECTED, () => {\n // Only auto-hide if it was auto-shown (no explicit visibility setting)\n const checkAutoHide = async () => {\n const settings = await appSettings.getDialogSetting(SETTINGS_KEY);\n if (!settings || settings.visible === undefined) {\n // Was auto-shown, can auto-hide when workspace connects\n // But let's keep it visible - user might want to see howtos even with workspace\n }\n };\n checkAutoHide();\n });\n }\n\n private loadContributions() {\n this.contributions = howToService.getAllContributions();\n }\n\n private async loadSettings() {\n const settings = await appSettings.getDialogSetting(SETTINGS_KEY);\n if (settings && settings.visible !== undefined) {\n this.isVisible = settings.visible;\n }\n }\n\n private async saveSettings() {\n const current = await appSettings.getDialogSetting(SETTINGS_KEY);\n const base = current !== null && typeof current === 'object' ? current : {};\n await appSettings.setDialogSetting(SETTINGS_KEY, {\n ...base,\n visible: this.isVisible,\n });\n }\n\n private expandPanel(): void {\n if (!this.floatingPanel) return;\n this.floatingPanel.minimized = false;\n }\n\n private async startHowTo(contributionId: string) {\n const contribution = howToService.getContribution(contributionId);\n if (!contribution) {\n toastError(`HowTo \"${contributionId}\" not found`);\n return;\n }\n\n // Clean up previous HowTo\n this.cleanupHowTo();\n\n this.activeContributionId = contributionId;\n this.expandPanel();\n\n // Initialize step states\n const states: StepState[] = contribution.steps.map(step => ({\n step,\n status: 'pending'\n }));\n\n this.stepStates.set(contributionId, states);\n \n // Call HowTo's initialize function if provided\n if (contribution.initialize) {\n const context = {\n requestUpdate: () => this.recheckActiveStepConditions(),\n contributionId: contributionId\n };\n this.howtoCleanup = contribution.initialize(context) || undefined;\n }\n \n this.requestUpdate();\n\n // Check initial pre-conditions\n await this.checkPreConditions(contributionId, 0);\n }\n\n private cleanupHowTo() {\n if (this.howtoCleanup) {\n this.howtoCleanup();\n this.howtoCleanup = undefined;\n }\n }\n\n private getStepState(contributionId: string, stepIndex: number): StepState | null {\n const states = this.stepStates.get(contributionId);\n return states && stepIndex < states.length ? states[stepIndex] : null;\n }\n\n private async checkPreConditions(contributionId: string, stepIndex: number) {\n const state = this.getStepState(contributionId, stepIndex);\n if (!state) return;\n\n if (!state.step.preCondition) {\n state.preConditionMet = true;\n this.requestUpdate();\n return;\n }\n\n try {\n state.preConditionMet = await state.step.preCondition();\n this.requestUpdate();\n } catch (error) {\n console.error(`Pre-condition check failed for step ${state.step.id}:`, error);\n state.preConditionMet = false;\n this.requestUpdate();\n }\n }\n\n private async checkPostConditions(contributionId: string, stepIndex: number) {\n const state = this.getStepState(contributionId, stepIndex);\n if (!state) return;\n\n if (!state.step.postCondition) {\n this.completeStep(contributionId, stepIndex);\n return;\n }\n\n try {\n const result = await state.step.postCondition();\n state.postConditionMet = result;\n state.status = result ? 'completed' : 'failed';\n \n if (result) {\n this.activateNextStep(contributionId, stepIndex);\n }\n this.requestUpdate();\n } catch (error) {\n console.error(`Post-condition check failed for step ${state.step.id}:`, error);\n state.postConditionMet = false;\n state.status = 'failed';\n this.requestUpdate();\n }\n }\n\n private completeStep(contributionId: string, stepIndex: number) {\n const state = this.getStepState(contributionId, stepIndex);\n if (!state) return;\n \n state.status = 'completed';\n this.activateNextStep(contributionId, stepIndex);\n this.requestUpdate();\n }\n\n private async activateNextStep(contributionId: string, stepIndex: number) {\n const states = this.stepStates.get(contributionId);\n if (!states || stepIndex + 1 >= states.length) return;\n \n const nextState = states[stepIndex + 1];\n nextState.status = 'active';\n await this.checkPreConditions(contributionId, stepIndex + 1);\n }\n\n /**\n * Re-checks conditions for active and pending steps when workspace or editor state changes\n */\n private async recheckActiveStepConditions() {\n if (!this.activeContributionId) return;\n\n const states = this.stepStates.get(this.activeContributionId);\n if (!states) return;\n\n // Find the active step\n const activeStepIndex = states.findIndex(state => state.status === 'active');\n \n if (activeStepIndex !== -1) {\n const activeState = states[activeStepIndex];\n const step = activeState.step;\n\n // Re-check post-condition if it exists and step is active\n if (step.postCondition) {\n try {\n const result = await step.postCondition();\n if (result && activeState.status === 'active') {\n // Post-condition is met, complete the step and move to next\n await this.checkPostConditions(this.activeContributionId, activeStepIndex);\n return; // Step completed, no need to check pre-conditions\n }\n } catch (error) {\n // Ignore errors in post-condition checks during re-evaluation\n }\n }\n }\n\n // Re-check pre-conditions for pending steps (they might become available)\n for (let i = 0; i < states.length; i++) {\n const state = states[i];\n if (state.status === 'pending' && state.step.preCondition) {\n // Re-check pre-condition for pending steps\n await this.checkPreConditions(this.activeContributionId, i);\n }\n }\n\n this.requestUpdate();\n }\n\n private async executeStep(contributionId: string, stepIndex: number) {\n const state = this.getStepState(contributionId, stepIndex);\n if (!state) return;\n\n if (!await this.validatePreConditions(state, contributionId, stepIndex)) {\n return;\n }\n\n state.status = 'active';\n this.requestUpdate();\n\n if (state.step.command && !await this.executeStepCommand(state)) {\n return;\n }\n\n await this.checkPostConditions(contributionId, stepIndex);\n }\n\n private async validatePreConditions(state: StepState, contributionId: string, stepIndex: number): Promise<boolean> {\n if (!state.step.preCondition) {\n return true;\n }\n\n if (state.preConditionMet === undefined || state.preConditionMet === false) {\n await this.checkPreConditions(contributionId, stepIndex);\n }\n\n if (state.preConditionMet !== true) {\n toastError(`Pre-conditions not met for step: ${state.step.title}`);\n return false;\n }\n\n return true;\n }\n\n private async executeStepCommand(state: StepState): Promise<boolean> {\n if (!state.step.command) {\n return true;\n }\n\n try {\n const rawParams = state.step.commandParams;\n const params = typeof rawParams === 'function' ? await rawParams() : (rawParams || {});\n const execContext = commandRegistry.createExecutionContext(params);\n await commandRegistry.execute(state.step.command, execContext);\n return true;\n } catch (error) {\n console.error(`Failed to execute command for step ${state.step.id}:`, error);\n toastError(`Failed to execute step: ${state.step.title}`);\n state.status = 'failed';\n this.requestUpdate();\n return false;\n }\n }\n\n private async runStepCommand(contributionId: string, stepIndex: number) {\n const state = this.getStepState(contributionId, stepIndex);\n if (!state || !state.step.command) {\n return;\n }\n\n // Check pre-conditions if they exist\n if (state.step.preCondition) {\n const preConditionMet = await state.step.preCondition();\n if (!preConditionMet) {\n toastError(`Pre-conditions not met for step: ${state.step.title}`);\n return;\n }\n }\n\n // Execute the command\n const success = await this.executeStepCommand(state);\n if (success) {\n // Check post-conditions after command execution\n await this.checkPostConditions(contributionId, stepIndex);\n }\n }\n\n private skipStep(contributionId: string, stepIndex: number) {\n const state = this.getStepState(contributionId, stepIndex);\n if (!state || !state.step.optional) return;\n\n state.status = 'skipped';\n this.activateNextStep(contributionId, stepIndex);\n this.requestUpdate();\n }\n\n private closeHowTo() {\n this.cleanupHowTo();\n this.activeContributionId = null;\n this.stepStates.clear();\n this.requestUpdate();\n }\n\n private async showPanel() {\n this.isVisible = true;\n await this.saveSettings();\n this.requestUpdate();\n await this.updateComplete;\n this.expandPanel();\n }\n\n private async hidePanel() {\n this.isVisible = false;\n await this.saveSettings();\n this.requestUpdate();\n }\n\n private async toggleVisibility() {\n if (this.isVisible) {\n await this.hidePanel();\n } else {\n await this.showPanel();\n }\n }\n\n private renderStep(state: StepState, index: number, contributionId: string) {\n const { step, status, preConditionMet, postConditionMet } = state;\n const isActive = status === 'active';\n const isCompleted = status === 'completed';\n const isFailed = status === 'failed';\n const isPending = status === 'pending';\n const isSkipped = status === 'skipped';\n\n return html`\n <div class=\"step ${status}\" ?data-active=${isActive}>\n <div class=\"step-header\">\n <div class=\"step-number\">${index + 1}</div>\n <div class=\"step-title\">${step.title}</div>\n <div class=\"step-status\">\n ${step.command ? html`\n <wa-button \n size=\"s\" \n appearance=\"plain\" \n @click=${(e: Event) => {\n e.stopPropagation();\n this.runStepCommand(contributionId, index);\n }}\n title=\"Run step command\"\n >\n <wa-icon name=\"play\"></wa-icon>\n </wa-button>\n ` : nothing}\n ${isCompleted ? html`<wa-icon name=\"check-circle\" class=\"status-icon completed\"></wa-icon>` : nothing}\n ${isFailed ? html`<wa-icon name=\"xmark-circle\" class=\"status-icon failed\"></wa-icon>` : nothing}\n ${isSkipped ? html`<wa-icon name=\"minus-circle\" class=\"status-icon skipped\"></wa-icon>` : nothing}\n ${isPending ? html`<wa-icon name=\"circle\" class=\"status-icon pending\"></wa-icon>` : nothing}\n ${isActive ? html`<wa-icon name=\"play-circle\" class=\"status-icon active\"></wa-icon>` : nothing}\n </div>\n </div>\n <div class=\"step-description\">${step.description}</div>\n ${step.preCondition && preConditionMet !== undefined ? html`\n <div class=\"condition pre-condition ${preConditionMet ? 'met' : 'not-met'}\">\n <wa-icon name=\"${preConditionMet ? 'check' : 'xmark'}\"></wa-icon>\n <span>Pre-condition: ${preConditionMet ? 'Met' : 'Not met'}</span>\n </div>\n ` : nothing}\n ${step.postCondition && postConditionMet !== undefined ? html`\n <div class=\"condition post-condition ${postConditionMet ? 'met' : 'not-met'}\">\n <wa-icon name=\"${postConditionMet ? 'check' : 'xmark'}\"></wa-icon>\n <span>Post-condition: ${postConditionMet ? 'Met' : 'Not met'}</span>\n </div>\n ` : nothing}\n ${isActive && step.optional ? html`\n <div class=\"step-actions\">\n <wa-button size=\"s\" appearance=\"outline\" @click=${() => this.skipStep(contributionId, index)}>\n <wa-icon name=\"forward\"></wa-icon>\n Skip\n </wa-button>\n </div>\n ` : nothing}\n </div>\n `;\n }\n\n render() {\n if (!this.isVisible) {\n return nothing;\n }\n\n const activeContribution = this.activeContributionId\n ? howToService.getContribution(this.activeContributionId)\n : null;\n\n const activeStepStates = this.activeContributionId\n ? this.stepStates.get(this.activeContributionId) || []\n : [];\n\n return html`\n <docks-floating-panel\n label=\"HowTo Workflows\"\n icon=\"list-check\"\n .persistKey=${SETTINGS_KEY}\n @floating-close=${() => { void this.hidePanel(); }}\n >\n <div class=\"panel-content\">\n ${activeContribution ? html`\n <div class=\"active-workflow\">\n <div class=\"workflow-header\">\n <div class=\"workflow-title-section\">\n <h3>${typeof activeContribution.title === 'function' \n ? activeContribution.title() \n : activeContribution.title}</h3>\n ${activeContribution.description ? html`\n <p class=\"workflow-description\">${typeof activeContribution.description === 'function'\n ? activeContribution.description()\n : activeContribution.description}</p>\n ` : nothing}\n </div>\n <wa-button \n size=\"s\" \n appearance=\"plain\" \n @click=${this.closeHowTo}\n title=\"Close HowTo\"\n >\n <wa-icon name=\"xmark\"></wa-icon>\n </wa-button>\n </div>\n <div class=\"steps-list\">\n ${activeStepStates.map((state, index) => \n this.renderStep(state, index, this.activeContributionId!)\n )}\n </div>\n </div>\n ` : html`\n <div class=\"workflows-list\">\n <h3>Available Workflows</h3>\n ${this.contributions.length === 0 ? html`\n <div class=\"empty-state\">\n <wa-icon name=\"list-check\" style=\"font-size: 2em; opacity: 0.5; margin-bottom: 12px;\"></wa-icon>\n <p>No HowTo workflows available yet.</p>\n <p style=\"font-size: 0.9em; opacity: 0.7;\">Extensions can register workflows via the contribution registry.</p>\n </div>\n ` : this.contributions.map(contrib => {\n const title = typeof contrib.title === 'function' ? contrib.title() : contrib.title;\n const description = contrib.description \n ? (typeof contrib.description === 'function' ? contrib.description() : contrib.description)\n : null;\n return html`\n <div class=\"workflow-item\" @click=${() => this.startHowTo(contrib.id)}>\n ${contrib.icon ? html`\n <wa-icon name=\"${contrib.icon}\"></wa-icon>\n ` : html`\n <wa-icon name=\"list-check\"></wa-icon>\n `}\n <div class=\"workflow-info\">\n <div class=\"workflow-title\">${title}</div>\n ${description ? html`\n <div class=\"workflow-desc\">${description}</div>\n ` : nothing}\n <div class=\"workflow-meta\">${contrib.steps.length} step${contrib.steps.length !== 1 ? 's' : ''}</div>\n </div>\n </div>\n `})}\n </div>\n `}\n </div>\n </docks-floating-panel>\n `;\n }\n\n static styles = css`\n :host {\n display: contents;\n }\n\n .panel-content {\n width: 400px;\n max-height: 600px;\n box-sizing: border-box;\n overflow-y: auto;\n padding: var(--wa-spacing-large, 16px);\n }\n\n .workflows-list h3 {\n margin: 0 0 var(--wa-spacing-medium, 12px) 0;\n font-size: var(--wa-font-size-medium, 14px);\n font-weight: 600;\n color: var(--wa-color-text-normal, var(--wa-color-neutral-80));\n }\n\n :host-context(.wa-light) .workflows-list h3 {\n color: var(--wa-color-text-normal, var(--wa-color-neutral-20));\n }\n\n .workflow-item {\n display: flex;\n align-items: flex-start;\n gap: var(--wa-spacing-medium, 12px);\n padding: var(--wa-spacing-medium, 12px);\n margin-bottom: var(--wa-spacing-small, 8px);\n background: var(--wa-color-surface-lowered, var(--wa-color-neutral-10));\n border: var(--wa-border-width-s, 1px) solid var(--wa-color-neutral-border-subtle, var(--wa-color-neutral-20));\n border-radius: var(--wa-border-radius-small, 6px);\n cursor: pointer;\n transition: all var(--wa-transition-medium, 0.2s);\n }\n\n :host-context(.wa-light) .workflow-item {\n background: var(--wa-color-surface-lowered, var(--wa-color-neutral-90));\n border-color: var(--wa-color-neutral-border-subtle, var(--wa-color-neutral-80));\n }\n\n .workflow-item:hover {\n background: var(--wa-color-mix-hover, var(--wa-color-neutral-15));\n border-color: var(--wa-color-neutral-border-loud, var(--wa-color-neutral-30));\n }\n\n :host-context(.wa-light) .workflow-item:hover {\n background: var(--wa-color-mix-hover, var(--wa-color-neutral-85));\n border-color: var(--wa-color-neutral-border-loud, var(--wa-color-neutral-70));\n }\n\n .workflow-info {\n flex: 1;\n }\n\n .workflow-title {\n font-weight: 600;\n margin-bottom: var(--wa-spacing-x-small, 4px);\n color: var(--wa-color-text-normal, var(--wa-color-neutral-90));\n }\n\n :host-context(.wa-light) .workflow-title {\n color: var(--wa-color-text-normal, var(--wa-color-neutral-10));\n }\n\n .workflow-desc {\n font-size: var(--wa-font-size-small, 12px);\n color: var(--wa-color-text-subtle, var(--wa-color-neutral-70));\n margin-bottom: var(--wa-spacing-x-small, 4px);\n }\n\n :host-context(.wa-light) .workflow-desc {\n color: var(--wa-color-text-subtle, var(--wa-color-neutral-30));\n }\n\n .workflow-meta {\n font-size: var(--wa-font-size-x-small, 11px);\n color: var(--wa-color-text-quiet, var(--wa-color-neutral-60));\n }\n\n :host-context(.wa-light) .workflow-meta {\n color: var(--wa-color-text-quiet, var(--wa-color-neutral-40));\n }\n\n .active-workflow {\n display: flex;\n flex-direction: column;\n gap: var(--wa-spacing-large, 16px);\n }\n\n .workflow-header {\n display: flex;\n align-items: flex-start;\n justify-content: space-between;\n gap: var(--wa-spacing-medium, 12px);\n margin-bottom: var(--wa-spacing-medium, 12px);\n }\n\n .workflow-title-section {\n flex: 1;\n }\n\n .workflow-header h3 {\n margin: 0 0 var(--wa-spacing-small, 8px) 0;\n font-size: var(--wa-font-size-large, 16px);\n font-weight: 600;\n color: var(--wa-color-text-normal, var(--wa-color-neutral-90));\n }\n\n :host-context(.wa-light) .workflow-header h3 {\n color: var(--wa-color-text-normal, var(--wa-color-neutral-10));\n }\n\n .workflow-description {\n margin: 0;\n font-size: var(--wa-font-size-medium, 13px);\n color: var(--wa-color-text-subtle, var(--wa-color-neutral-70));\n }\n\n :host-context(.wa-light) .workflow-description {\n color: var(--wa-color-text-subtle, var(--wa-color-neutral-30));\n }\n\n .steps-list {\n display: flex;\n flex-direction: column;\n gap: var(--wa-spacing-medium, 12px);\n }\n\n .step {\n padding: var(--wa-spacing-medium, 12px);\n background: var(--wa-color-surface-lowered, var(--wa-color-neutral-10));\n border: var(--wa-border-width-s, 1px) solid var(--wa-color-neutral-border-subtle, var(--wa-color-neutral-20));\n border-radius: var(--wa-border-radius-small, 6px);\n transition: all var(--wa-transition-medium, 0.2s);\n }\n\n :host-context(.wa-light) .step {\n background: var(--wa-color-surface-lowered, var(--wa-color-neutral-90));\n border-color: var(--wa-color-neutral-border-subtle, var(--wa-color-neutral-80));\n }\n\n .step[data-active=\"true\"] {\n border-color: var(--wa-color-primary-50);\n background: var(--wa-color-primary-05);\n }\n\n :host-context(.wa-light) .step[data-active=\"true\"] {\n background: var(--wa-color-primary-95);\n border-color: var(--wa-color-primary-50);\n }\n\n .step.completed {\n border-color: var(--wa-color-success-50);\n background: var(--wa-color-success-05);\n }\n\n :host-context(.wa-light) .step.completed {\n background: var(--wa-color-success-95);\n border-color: var(--wa-color-success-50);\n }\n\n .step.failed {\n border-color: var(--wa-color-danger-50);\n background: var(--wa-color-danger-05);\n }\n\n :host-context(.wa-light) .step.failed {\n background: var(--wa-color-danger-95);\n border-color: var(--wa-color-danger-50);\n }\n\n .step-header {\n display: flex;\n align-items: center;\n gap: var(--wa-spacing-medium, 12px);\n margin-bottom: var(--wa-spacing-small, 8px);\n }\n\n .step-number {\n width: 24px;\n height: 24px;\n display: flex;\n align-items: center;\n justify-content: center;\n background: var(--wa-color-surface-lowered, var(--wa-color-neutral-20));\n border-radius: 50%;\n font-size: var(--wa-font-size-small, 12px);\n font-weight: 600;\n color: var(--wa-color-text-normal, var(--wa-color-neutral-80));\n }\n\n :host-context(.wa-light) .step-number {\n background: var(--wa-color-surface-lowered, var(--wa-color-neutral-80));\n color: var(--wa-color-text-normal, var(--wa-color-neutral-20));\n }\n\n .step-title {\n flex: 1;\n font-weight: 600;\n color: var(--wa-color-text-normal, var(--wa-color-neutral-90));\n }\n\n :host-context(.wa-light) .step-title {\n color: var(--wa-color-text-normal, var(--wa-color-neutral-10));\n }\n\n .step-status {\n display: flex;\n align-items: center;\n gap: var(--wa-spacing-small, 8px);\n }\n\n .status-icon {\n width: 20px;\n height: 20px;\n }\n\n .status-icon.completed {\n color: var(--wa-color-success-50);\n }\n\n .status-icon.failed {\n color: var(--wa-color-danger-50);\n }\n\n .status-icon.skipped {\n color: var(--wa-color-neutral-50);\n }\n\n .status-icon.active {\n color: var(--wa-color-primary-50);\n }\n\n .status-icon.pending {\n color: var(--wa-color-neutral-50);\n }\n\n .step-description {\n font-size: var(--wa-font-size-medium, 13px);\n color: var(--wa-color-text-subtle, var(--wa-color-neutral-70));\n margin-bottom: var(--wa-spacing-small, 8px);\n line-height: 1.4;\n }\n\n :host-context(.wa-light) .step-description {\n color: var(--wa-color-text-subtle, var(--wa-color-neutral-30));\n }\n\n .condition {\n display: flex;\n align-items: center;\n gap: var(--wa-spacing-x-small, 6px);\n font-size: var(--wa-font-size-small, 12px);\n padding: var(--wa-spacing-x-small, 6px) var(--wa-spacing-small, 8px);\n border-radius: var(--wa-border-radius-x-small, 4px);\n margin-bottom: var(--wa-spacing-small, 8px);\n }\n\n .condition.met {\n background: var(--wa-color-success-10);\n color: var(--wa-color-success-70);\n }\n\n :host-context(.wa-light) .condition.met {\n background: var(--wa-color-success-90);\n color: var(--wa-color-success-30);\n }\n\n .condition.not-met {\n background: var(--wa-color-danger-10);\n color: var(--wa-color-danger-70);\n }\n\n :host-context(.wa-light) .condition.not-met {\n background: var(--wa-color-danger-90);\n color: var(--wa-color-danger-30);\n }\n\n .step-actions {\n display: flex;\n gap: var(--wa-spacing-small, 8px);\n margin-top: var(--wa-spacing-small, 8px);\n }\n\n .empty-state {\n display: flex;\n flex-direction: column;\n align-items: center;\n justify-content: center;\n padding: var(--wa-spacing-x-large, 40px) var(--wa-spacing-large, 20px);\n text-align: center;\n color: var(--wa-color-text-subtle, var(--wa-color-neutral-70));\n }\n\n :host-context(.wa-light) .empty-state {\n color: var(--wa-color-text-subtle, var(--wa-color-neutral-30));\n }\n\n .empty-state p {\n margin: var(--wa-spacing-small, 8px) 0;\n }\n `;\n}\n\n","import { createLogger } from '@eclipse-docks/core';\nimport { rootContext } from '@eclipse-docks/core';\nimport { howToService } from './howto-service';\nimport { HOWTO_CONTRIBUTION_TARGET } from './howto-service';\nimport './contributions/onboarding-howto-contributions';\nimport './contributions/ai-setup-howto-contributions';\nimport { TOPIC_SHOW_HOWTO_PANEL, TOPIC_TOGGLE_HOWTO_PANEL } from './howto-panel';\nimport { registerAll } from '@eclipse-docks/core';\nimport { publish } from '@eclipse-docks/core';\nimport { TOOLBAR_BOTTOM_END } from '@eclipse-docks/core';\nimport './howto-panel';\n\nconst logger = createLogger('HowToExtension');\n\n/**\n * HowTo System Extension\n * \n * Provides a system for registering and displaying step-by-step workflows\n * that guide users through specific processes with pre and post condition checks.\n * \n * Features:\n * - Register HowToContributions via contribution registry\n * - Floating, draggable UI panel\n * - Sequential step execution\n * - Pre and post condition validation\n * - Step status tracking\n */\nexport default function howToExtension(context: any) {\n logger.info('HowTo system extension loaded');\n\n // Register the HowTo service in the dependency injection context\n rootContext.put('howToService', howToService);\n\n // Ensure the panel is added to the DOM\n const ensurePanelInDOM = () => {\n // Check if panel already exists\n if (document.querySelector('docks-howto-panel')) {\n return;\n }\n\n // Create and append the panel\n const panel = document.createElement('docks-howto-panel');\n document.body.appendChild(panel);\n logger.info('HowTo panel added to DOM');\n };\n\n // Add panel to DOM - use requestAnimationFrame to ensure DOM is ready\n if (document.body) {\n requestAnimationFrame(() => {\n ensurePanelInDOM();\n });\n } else {\n // Wait for DOM to be ready\n const checkDOM = () => {\n if (document.body) {\n ensurePanelInDOM();\n } else {\n requestAnimationFrame(checkDOM);\n }\n };\n requestAnimationFrame(checkDOM);\n }\n\n // Register command to show/toggle the HowTo panel\n registerAll({\n command: {\n id: 'howto.show-panel',\n name: 'Show HowTo Panel',\n description: 'Shows the HowTo workflows panel',\n icon: 'list-check',\n parameters: []\n },\n handler: {\n execute: () => {\n publish(TOPIC_SHOW_HOWTO_PANEL, null);\n }\n }\n });\n\n registerAll({\n command: {\n id: 'howto.toggle-panel',\n name: 'Toggle HowTo Panel',\n description: 'Toggles the visibility of the HowTo workflows panel',\n icon: 'list-check',\n keyBinding: 'CTRL+SHIFT+H',\n parameters: []\n },\n handler: {\n execute: () => {\n publish(TOPIC_TOGGLE_HOWTO_PANEL, null);\n }\n },\n contribution: {\n target: TOOLBAR_BOTTOM_END,\n icon: 'list-check',\n label: 'HowTo',\n }\n });\n\n logger.info('HowTo system extension initialized');\n}\n\n// Export the service and types for direct imports\nexport { howToService, HOWTO_CONTRIBUTION_TARGET } from './howto-service';\nexport type { HowToContribution, HowToStep, ConditionFunction } from './howto-contribution';\n\n"],"mappings":";;;;;;AAMA,IAAMA,WAAS,aAAa,cAAc;AAE1C,IAAa,4BAA4B;;;;;;;AAQzC,IAAa,eAAb,MAA0B;CAGtB,cAAc;EAF0C,KAAA,gCAAA,IAAI,IAAI;EAI5D,KAAK,kBAAkB;EAGvB,UAAU,+BAA+B,UAAe;GACpD,IAAI,MAAM,WAAA,iBACN,KAAK,kBAAkB;EAE/B,CAAC;CACL;;;;CAKA,oBAAkC;EAC9B,MAAM,gBAAgB,qBAAqB,iBAAiB,yBAAyB;EAErF,KAAK,cAAc,MAAM;EAEzB,KAAK,MAAM,gBAAgB,eAAe;GAEtC,IAAI,CAAC,aAAa,IAAI;IAClB,SAAO,KAAK,yCAAyC;IACrD;GACJ;GAEA,IAAI,CAAC,aAAa,OAMd,aAAa,QAHC,OAAO,aAAa,UAAU,aACtC,aAAa,MAAM,IACnB,aAAa;GAIvB,IAAI,CAAC,aAAa,SAAS,aAAa,MAAM,WAAW,GAAG;IACxD,SAAO,KAAK,uBAAuB,aAAa,GAAG,yBAAyB;IAC5E;GACJ;GAGA,MAAM,0BAAU,IAAI,IAAY;GAChC,KAAK,MAAM,QAAQ,aAAa,OAAO;IACnC,IAAI,QAAQ,IAAI,KAAK,EAAE,GAAG;KACtB,SAAO,KAAK,uBAAuB,aAAa,GAAG,4BAA4B,KAAK,GAAG,EAAE;KACzF;IACJ;IACA,QAAQ,IAAI,KAAK,EAAE;GACvB;GAEA,KAAK,cAAc,IAAI,aAAa,IAAI,YAAY;GACpD,MAAM,QAAQ,OAAO,aAAa,UAAU,aACtC,aAAa,MAAM,IACnB,aAAa;GACnB,SAAO,MAAM,8BAA8B,MAAM,IAAI,aAAa,G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,IAAI;GACJ,MAAM;GACN,aAAa;GACb,MAAM;GACN,YAAY;GACZ,YAAY,CAAC;EACjB;EACA,SAAS,EACL,eAAe;GACX,QAAQ,0BAA0B,IAAI;EAC1C,EACJ;EACA,cAAc;GACV,QAAQ;GACR,MAAM;GACN,OAAO;EACX;CACJ,CAAC;CAED,OAAO,KAAK,oCAAoC;AACpD"}
|
|
1
|
+
{"version":3,"file":"howto-extension-BbJ7J894.js","names":["logger","getAppName"],"sources":["../src/howto-service.ts","../src/contributions/onboarding-howto-contributions.ts","../src/contributions/ai-setup-howto-contributions.ts","../src/howto-panel.ts","../src/howto-extension.ts"],"sourcesContent":["import { contributionRegistry, TOPIC_CONTRIBUTEIONS_CHANGED } from '@eclipse-docks/core';\nimport { HowToContribution, HowToStep } from './howto-contribution';\nimport { subscribe } from '@eclipse-docks/core';\nimport { createLogger } from '@eclipse-docks/core';\nimport { Signal } from '@lit-labs/signals';\n\nconst logger = createLogger('HowToService');\n\nexport const HOWTO_CONTRIBUTION_TARGET = 'system.howtos';\n\n/**\n * HowTo Service\n * \n * Manages HowTo contributions by reading from the contribution registry.\n * Provides methods to retrieve and manage workflows.\n */\nexport class HowToService {\n private contributions: Map<string, HowToContribution> = new Map();\n\n constructor() {\n // Load initial contributions\n this.loadContributions();\n\n // Subscribe to contribution changes\n subscribe(TOPIC_CONTRIBUTEIONS_CHANGED, (event: any) => {\n if (event.target === HOWTO_CONTRIBUTION_TARGET) {\n this.loadContributions();\n }\n });\n }\n\n /**\n * Load contributions from the contribution registry\n */\n private loadContributions(): void {\n const contributions = contributionRegistry.getContributions(HOWTO_CONTRIBUTION_TARGET) as HowToContribution[];\n \n this.contributions.clear();\n \n for (const contribution of contributions) {\n // Validate contribution\n if (!contribution.id) {\n logger.warn('HowTo contribution missing id, skipping');\n continue;\n }\n\n if (!contribution.label) {\n // Use title as label if label is not provided\n // Handle both string and function types\n const title = typeof contribution.title === 'function' \n ? contribution.title() \n : contribution.title;\n contribution.label = title;\n }\n\n if (!contribution.steps || contribution.steps.length === 0) {\n logger.warn(`HowTo contribution \"${contribution.id}\" has no steps, skipping`);\n continue;\n }\n\n // Validate step IDs are unique\n const stepIds = new Set<string>();\n for (const step of contribution.steps) {\n if (stepIds.has(step.id)) {\n logger.warn(`HowTo contribution \"${contribution.id}\" has duplicate step ID: \"${step.id}\"`);\n continue;\n }\n stepIds.add(step.id);\n }\n\n this.contributions.set(contribution.id, contribution);\n const title = typeof contribution.title === 'function' \n ? contribution.title() \n : contribution.title;\n logger.debug(`Loaded HowTo contribution: ${title} (${contribution.id})`);\n }\n\n logger.info(`Loaded ${this.contributions.size} HowTo contributions`);\n }\n\n /**\n * Get a HowTo Contribution by ID\n * \n * @param contributionId The ID of the contribution\n * @returns The contribution or undefined if not found\n */\n getContribution(contributionId: string): HowToContribution | undefined {\n return this.contributions.get(contributionId);\n }\n\n /**\n * Get all registered HowTo Contributions\n * \n * @returns Array of all contributions\n */\n getAllContributions(): HowToContribution[] {\n return Array.from(this.contributions.values());\n }\n\n /**\n * Get HowTo Contributions by category\n * \n * @param category The category to filter by\n * @returns Array of contributions in the category\n */\n getContributionsByCategory(category: string): HowToContribution[] {\n return Array.from(this.contributions.values())\n .filter(contrib => contrib.category === category);\n }\n\n /**\n * Check if a contribution exists\n * \n * @param contributionId The ID of the contribution\n * @returns True if the contribution exists\n */\n hasContribution(contributionId: string): boolean {\n return this.contributions.has(contributionId);\n }\n}\n\nexport const howToService = new HowToService();\n\n","import { contributionRegistry, workspaceService, File, TOPIC_WORKSPACE_CHANGED, TOPIC_WORKSPACE_CONNECTED, activeEditorSignal, partDirtySignal, subscribe, appLoaderService } from '@eclipse-docks/core';\nimport type { EditorContentProvider } from '@eclipse-docks/core';\nimport { watchSignal } from '@eclipse-docks/core';\nimport { HOWTO_CONTRIBUTION_TARGET } from '../howto-service';\nimport type { HowToContribution, HowToContext } from '../howto-contribution';\n\nconst ONBOARDING_FILE_NAME = 'welcome.txt';\n\nasync function getOnboardingFilePath(): Promise<string | null> {\n const workspace = await workspaceService.getWorkspace();\n if (!workspace) return null;\n const folders = await workspaceService.getFolders();\n if (folders.length === 0) return null;\n const firstFolderName = folders[0].name;\n return `${firstFolderName}/${ONBOARDING_FILE_NAME}`;\n}\n\n/**\n * Type guard to check if an editor implements EditorContentProvider\n */\nfunction isEditorContentProvider(editor: any): editor is EditorContentProvider {\n return editor &&\n typeof editor.getFilePath === 'function';\n}\n\n/**\n * Checks if a workspace is selected\n */\nasync function isWorkspaceSelected(): Promise<boolean> {\n return workspaceService.isConnected();\n}\n\n/**\n * Checks if the onboarding file exists\n */\nasync function onboardingFileExists(): Promise<boolean> {\n const path = await getOnboardingFilePath();\n if (!path) return false;\n const workspace = await workspaceService.getWorkspace();\n if (!workspace) return false;\n try {\n const resource = await workspace.getResource(path);\n return resource instanceof File;\n } catch {\n return false;\n }\n}\n\n/**\n * Checks if the onboarding file is open in an editor\n */\nfunction isOnboardingFileOpen(): boolean {\n const activeEditor = activeEditorSignal.get();\n if (!activeEditor || !isEditorContentProvider(activeEditor)) {\n return false;\n }\n const filePath = activeEditor.getFilePath();\n return filePath === ONBOARDING_FILE_NAME || filePath?.endsWith('/' + ONBOARDING_FILE_NAME) === true;\n}\n\n/**\n * Checks if the active editor is dirty (has unsaved changes)\n * Returns true only if the onboarding file is open AND dirty\n */\nfunction isActiveEditorDirty(): boolean {\n if (!isOnboardingFileOpen()) return false;\n \n const activeEditor = activeEditorSignal.get();\n if (!activeEditor) return false;\n \n return activeEditor.isDirty() === true;\n}\n\n/**\n * Checks if the active editor is clean (no unsaved changes)\n * Returns true only if the onboarding file is open AND not dirty\n */\nfunction isActiveEditorClean(): boolean {\n if (!isOnboardingFileOpen()) return false;\n \n const activeEditor = activeEditorSignal.get();\n if (!activeEditor) return false;\n \n return activeEditor.isDirty() === false;\n}\n\n/**\n * Checks if the onboarding file is closed (not open in any editor)\n */\nfunction isOnboardingFileClosed(): boolean {\n return !isOnboardingFileOpen();\n}\n\n// Get current app name for the title\nfunction getAppName(): string {\n const currentApp = appLoaderService.getCurrentApp();\n return currentApp?.name || 'AppSpace';\n}\n\n// Create the onboarding HowTo contribution\n// Using callback functions so the app name is read when the HowTo is displayed\nconst onboardingContribution: HowToContribution = {\n id: 'docks.onboarding',\n title: () => `Welcome to ${getAppName()}`,\n description: () => `Get started with ${getAppName()} by learning the basics of workspace and file management`,\n icon: 'graduation-cap',\n // label will be set from title in howto-service.ts\n label: '',\n category: 'Getting Started',\n initialize: (context: HowToContext) => {\n // Set up subscriptions for workspace and editor changes\n const cleanups: (() => void)[] = [];\n\n // Subscribe to workspace events\n subscribe(TOPIC_WORKSPACE_CHANGED, () => {\n context.requestUpdate();\n });\n\n subscribe(TOPIC_WORKSPACE_CONNECTED, () => {\n context.requestUpdate();\n });\n\n // Watch editor signals\n cleanups.push(\n watchSignal(activeEditorSignal, () => {\n context.requestUpdate();\n })\n );\n\n cleanups.push(\n watchSignal(partDirtySignal, () => {\n context.requestUpdate();\n })\n );\n\n // Return cleanup function\n return () => {\n cleanups.forEach(cleanup => cleanup());\n };\n },\n steps: [\n {\n id: 'create-text-file',\n title: 'Create welcome.txt',\n description: 'Create a new text file called \"welcome.txt\" in your workspace. If you don\\'t have a workspace selected, choose one first.',\n preCondition: async () => {\n // Workspace must be selected\n return await isWorkspaceSelected();\n },\n postCondition: async () => {\n return await onboardingFileExists();\n },\n command: 'touch',\n commandParams: async () => {\n const path = await getOnboardingFilePath();\n return path ? {\n path,\n contents: 'Welcome to AppSpace!\\n\\nThis is your first file. You can edit it and save your changes.'\n } : {};\n }\n },\n {\n id: 'open-text-file',\n title: 'Open welcome.txt',\n description: 'Open the \"welcome.txt\" file in the editor.',\n preCondition: async () => {\n return await onboardingFileExists();\n },\n postCondition: () => {\n return isOnboardingFileOpen();\n },\n command: 'open_editor',\n commandParams: async () => {\n const path = await getOnboardingFilePath();\n return path ? { path } : {};\n }\n },\n {\n id: 'edit-and-save',\n title: 'Type something and save',\n description: 'Type some text in the editor to modify the file, then save it using Ctrl+S or the save button.',\n preCondition: () => {\n return isOnboardingFileOpen();\n },\n postCondition: () => {\n // File must be open, was dirty (edited), and is now clean (saved)\n // Check that file is open and clean (saved)\n return isActiveEditorClean();\n },\n // No command - user manually edits and saves\n },\n {\n id: 'close-text-file',\n title: 'Close the file',\n description: 'Close the editor tab by clicking the X button on the tab.',\n preCondition: () => {\n return isOnboardingFileOpen();\n },\n postCondition: () => {\n return isOnboardingFileClosed();\n },\n // No command - user manually closes the tab\n }\n ]\n};\n\n// Register the contribution\ncontributionRegistry.registerContribution<HowToContribution>(HOWTO_CONTRIBUTION_TARGET, onboardingContribution);\n\n","import {\n contributionRegistry,\n activeEditorSignal,\n appLoaderService,\n partDirtySignal,\n subscribe,\n unsubscribe,\n watchSignal,\n} from '@eclipse-docks/core';\nimport {\n AI_SETTINGS_KEY,\n OPEN_AI_SETTINGS_COMMAND,\n TOPIC,\n cognitiveRuntime,\n} from '@eclipse-docks/extension-ai-system/api';\nimport { HOWTO_CONTRIBUTION_TARGET } from '../howto-service';\nimport type { HowToContribution, HowToContext } from '../howto-contribution';\n\nfunction isAIConfigEditorOpen(): boolean {\n const activeEditor = activeEditorSignal.get() as {\n input?: { key?: string };\n tagName?: string;\n localName?: string;\n } | null;\n if (!activeEditor) return false;\n if (activeEditor.input?.key === AI_SETTINGS_KEY) return true;\n const tag = (activeEditor.tagName || activeEditor.localName || '').toLowerCase();\n return tag === 'docks-cognitive-settings-editor';\n}\n\nasync function isLLMProviderConfigured(): Promise<boolean> {\n try {\n await cognitiveRuntime.whenReady();\n const settings = cognitiveRuntime.getProvidersSettings();\n if (!settings.defaultProviderId) return false;\n const provider = settings.providers.find((p) => p.id === settings.defaultProviderId);\n if (!provider?.enabled) return false;\n // Local providers (ollama/webllm) may not need a key.\n if (!provider.apiKey.trim()) {\n return /ollama|webllm|localhost|127\\.0\\.0\\.1/i.test(`${provider.id} ${provider.baseUrl}`);\n }\n return true;\n } catch {\n return false;\n }\n}\n\nfunction isAIConfigEditorDirty(): boolean {\n const activeEditor = activeEditorSignal.get() as { isDirty?: () => boolean } | null;\n if (!activeEditor || !isAIConfigEditorOpen()) return false;\n return activeEditor.isDirty?.() === true;\n}\n\nfunction isAIConfigEditorSaved(): boolean {\n return isAIConfigEditorOpen() && !isAIConfigEditorDirty();\n}\n\nfunction isAIConfigEditorClosed(): boolean {\n return !isAIConfigEditorOpen();\n}\n\nasync function hasTypedInChat(): Promise<boolean> {\n try {\n await cognitiveRuntime.whenReady();\n for (const session of cognitiveRuntime.sessions.list()) {\n const hasUserMessage = session.history.some(\n (msg) =>\n msg.role === 'user' &&\n msg.parts.some((part) => part.type === 'text' && part.text.trim() !== ''),\n );\n if (hasUserMessage) return true;\n }\n return false;\n } catch {\n return false;\n }\n}\n\nfunction getAppName(): string {\n const currentApp = appLoaderService.getCurrentApp();\n return currentApp?.name || 'AppSpace';\n}\n\nconst aiSetupContribution: HowToContribution = {\n id: 'docks.ai-setup',\n title: () => `Set up AI in ${getAppName()}`,\n description: () => `Configure an LLM provider to enable AI chat features in ${getAppName()}`,\n icon: 'robot',\n label: '',\n category: 'Getting Started',\n initialize: (context: HowToContext) => {\n const cleanups: Array<() => void> = [];\n\n cleanups.push(watchSignal(activeEditorSignal, () => context.requestUpdate()));\n cleanups.push(watchSignal(partDirtySignal, () => context.requestUpdate()));\n const providersToken = subscribe(TOPIC.providersChanged, () => context.requestUpdate());\n const sessionToken = subscribe(TOPIC.sessionChanged, () => context.requestUpdate());\n cleanups.push(() => unsubscribe(providersToken), () => unsubscribe(sessionToken));\n\n return () => {\n cleanups.forEach((cleanup) => cleanup());\n };\n },\n steps: [\n {\n id: 'open-ai-settings',\n title: 'Open AI Settings',\n description:\n 'Open the AI settings editor from the chat gear menu or the command palette.',\n preCondition: () => true,\n postCondition: () => isAIConfigEditorOpen(),\n command: OPEN_AI_SETTINGS_COMMAND,\n },\n {\n id: 'configure-llm-provider',\n title: 'Configure LLM Provider',\n description:\n 'Select a provider as default and enter an API key when required. Save your changes.',\n preCondition: () => isAIConfigEditorOpen(),\n postCondition: async () => {\n const configured = await isLLMProviderConfigured();\n const saved = isAIConfigEditorSaved();\n return configured && saved;\n },\n },\n {\n id: 'save-and-close',\n title: 'Save and Close',\n description: 'Save your changes (if not already saved) and close the AI settings editor tab.',\n preCondition: () => isAIConfigEditorOpen(),\n postCondition: () => isAIConfigEditorClosed(),\n },\n {\n id: 'type-in-chat',\n title: 'Type in Chat',\n description: 'Open the AI chat view and type a message to test your AI configuration.',\n preCondition: async () => await isLLMProviderConfigured(),\n postCondition: async () => await hasTypedInChat(),\n },\n ],\n};\n\ncontributionRegistry.registerContribution<HowToContribution>(HOWTO_CONTRIBUTION_TARGET, aiSetupContribution);\n","import { css, html, nothing } from 'lit';\nimport { customElement, query, state } from 'lit/decorators.js';\nimport { DocksWidget, type DocksFloatingPanel } from '@eclipse-docks/core';\nimport { howToService } from './howto-service';\nimport { HowToContribution, HowToStep } from './howto-contribution';\nimport { subscribe } from '@eclipse-docks/core';\nimport { commandRegistry } from '@eclipse-docks/core';\nimport { toastError } from '@eclipse-docks/core';\nimport { TOPIC_CONTRIBUTEIONS_CHANGED } from '@eclipse-docks/core';\nimport { HOWTO_CONTRIBUTION_TARGET } from './howto-service';\nimport { appSettings } from '@eclipse-docks/core';\nimport { workspaceService, TOPIC_WORKSPACE_CONNECTED } from '@eclipse-docks/core';\n\n// Event topic for showing the HowTo panel\nexport const TOPIC_SHOW_HOWTO_PANEL = 'howto/show-panel';\nexport const TOPIC_TOGGLE_HOWTO_PANEL = 'howto/toggle-panel';\n\n// Constants\nconst SETTINGS_KEY = 'howto-panel';\n\ninterface StepState {\n step: HowToStep;\n status: 'pending' | 'active' | 'completed' | 'skipped' | 'failed';\n preConditionMet?: boolean;\n postConditionMet?: boolean;\n}\n\n@customElement('docks-howto-panel')\nexport class DocksHowToPanel extends DocksWidget {\n @state()\n private contributions: HowToContribution[] = [];\n\n @state()\n private activeContributionId: string | null = null;\n\n @state()\n private stepStates: Map<string, StepState[]> = new Map();\n\n @state()\n private isVisible: boolean = false;\n\n @query('docks-floating-panel')\n private floatingPanel?: DocksFloatingPanel;\n\n private howtoCleanup?: () => void;\n\n protected async doBeforeUI() {\n this.loadContributions();\n \n subscribe(TOPIC_CONTRIBUTEIONS_CHANGED, (event: any) => {\n if (event.target === HOWTO_CONTRIBUTION_TARGET) {\n this.loadContributions();\n this.requestUpdate();\n }\n });\n\n // Subscribe to show/toggle panel events\n subscribe(TOPIC_SHOW_HOWTO_PANEL, () => this.showPanel());\n subscribe(TOPIC_TOGGLE_HOWTO_PANEL, () => this.toggleVisibility());\n\n // Load position and visibility from dialogsettings\n await this.loadSettings();\n \n // If no workspace is selected and panel wasn't explicitly hidden, show it by default\n const hasWorkspace = workspaceService.isConnected();\n if (!hasWorkspace && this.isVisible === false) {\n // Check if user has explicitly hidden it (if settings exist and visible is false)\n const settings = await appSettings.getDialogSetting(SETTINGS_KEY);\n if (!settings || settings.visible === undefined) {\n // No explicit preference, show panel when no workspace\n this.isVisible = true;\n await this.saveSettings();\n }\n }\n \n // Subscribe to workspace connection to hide panel when workspace is connected (if it was auto-shown)\n subscribe(TOPIC_WORKSPACE_CONNECTED, () => {\n // Only auto-hide if it was auto-shown (no explicit visibility setting)\n const checkAutoHide = async () => {\n const settings = await appSettings.getDialogSetting(SETTINGS_KEY);\n if (!settings || settings.visible === undefined) {\n // Was auto-shown, can auto-hide when workspace connects\n // But let's keep it visible - user might want to see howtos even with workspace\n }\n };\n checkAutoHide();\n });\n }\n\n private loadContributions() {\n this.contributions = howToService.getAllContributions();\n }\n\n private async loadSettings() {\n const settings = await appSettings.getDialogSetting(SETTINGS_KEY);\n if (settings && settings.visible !== undefined) {\n this.isVisible = settings.visible;\n }\n }\n\n private async saveSettings() {\n const current = await appSettings.getDialogSetting(SETTINGS_KEY);\n const base = current !== null && typeof current === 'object' ? current : {};\n await appSettings.setDialogSetting(SETTINGS_KEY, {\n ...base,\n visible: this.isVisible,\n });\n }\n\n private expandPanel(): void {\n if (!this.floatingPanel) return;\n this.floatingPanel.minimized = false;\n }\n\n private async startHowTo(contributionId: string) {\n const contribution = howToService.getContribution(contributionId);\n if (!contribution) {\n toastError(`HowTo \"${contributionId}\" not found`);\n return;\n }\n\n // Clean up previous HowTo\n this.cleanupHowTo();\n\n this.activeContributionId = contributionId;\n this.expandPanel();\n\n // Initialize step states\n const states: StepState[] = contribution.steps.map(step => ({\n step,\n status: 'pending'\n }));\n\n this.stepStates.set(contributionId, states);\n \n // Call HowTo's initialize function if provided\n if (contribution.initialize) {\n const context = {\n requestUpdate: () => this.recheckActiveStepConditions(),\n contributionId: contributionId\n };\n this.howtoCleanup = contribution.initialize(context) || undefined;\n }\n \n this.requestUpdate();\n\n // Check initial pre-conditions\n await this.checkPreConditions(contributionId, 0);\n }\n\n private cleanupHowTo() {\n if (this.howtoCleanup) {\n this.howtoCleanup();\n this.howtoCleanup = undefined;\n }\n }\n\n private getStepState(contributionId: string, stepIndex: number): StepState | null {\n const states = this.stepStates.get(contributionId);\n return states && stepIndex < states.length ? states[stepIndex] : null;\n }\n\n private async checkPreConditions(contributionId: string, stepIndex: number) {\n const state = this.getStepState(contributionId, stepIndex);\n if (!state) return;\n\n if (!state.step.preCondition) {\n state.preConditionMet = true;\n this.requestUpdate();\n return;\n }\n\n try {\n state.preConditionMet = await state.step.preCondition();\n this.requestUpdate();\n } catch (error) {\n console.error(`Pre-condition check failed for step ${state.step.id}:`, error);\n state.preConditionMet = false;\n this.requestUpdate();\n }\n }\n\n private async checkPostConditions(contributionId: string, stepIndex: number) {\n const state = this.getStepState(contributionId, stepIndex);\n if (!state) return;\n\n if (!state.step.postCondition) {\n this.completeStep(contributionId, stepIndex);\n return;\n }\n\n try {\n const result = await state.step.postCondition();\n state.postConditionMet = result;\n state.status = result ? 'completed' : 'failed';\n \n if (result) {\n this.activateNextStep(contributionId, stepIndex);\n }\n this.requestUpdate();\n } catch (error) {\n console.error(`Post-condition check failed for step ${state.step.id}:`, error);\n state.postConditionMet = false;\n state.status = 'failed';\n this.requestUpdate();\n }\n }\n\n private completeStep(contributionId: string, stepIndex: number) {\n const state = this.getStepState(contributionId, stepIndex);\n if (!state) return;\n \n state.status = 'completed';\n this.activateNextStep(contributionId, stepIndex);\n this.requestUpdate();\n }\n\n private async activateNextStep(contributionId: string, stepIndex: number) {\n const states = this.stepStates.get(contributionId);\n if (!states || stepIndex + 1 >= states.length) return;\n \n const nextState = states[stepIndex + 1];\n nextState.status = 'active';\n await this.checkPreConditions(contributionId, stepIndex + 1);\n }\n\n /**\n * Re-checks conditions for active and pending steps when workspace or editor state changes\n */\n private async recheckActiveStepConditions() {\n if (!this.activeContributionId) return;\n\n const states = this.stepStates.get(this.activeContributionId);\n if (!states) return;\n\n // Find the active step\n const activeStepIndex = states.findIndex(state => state.status === 'active');\n \n if (activeStepIndex !== -1) {\n const activeState = states[activeStepIndex];\n const step = activeState.step;\n\n // Re-check post-condition if it exists and step is active\n if (step.postCondition) {\n try {\n const result = await step.postCondition();\n if (result && activeState.status === 'active') {\n // Post-condition is met, complete the step and move to next\n await this.checkPostConditions(this.activeContributionId, activeStepIndex);\n return; // Step completed, no need to check pre-conditions\n }\n } catch (error) {\n // Ignore errors in post-condition checks during re-evaluation\n }\n }\n }\n\n // Re-check pre-conditions for pending steps (they might become available)\n for (let i = 0; i < states.length; i++) {\n const state = states[i];\n if (state.status === 'pending' && state.step.preCondition) {\n // Re-check pre-condition for pending steps\n await this.checkPreConditions(this.activeContributionId, i);\n }\n }\n\n this.requestUpdate();\n }\n\n private async executeStep(contributionId: string, stepIndex: number) {\n const state = this.getStepState(contributionId, stepIndex);\n if (!state) return;\n\n if (!await this.validatePreConditions(state, contributionId, stepIndex)) {\n return;\n }\n\n state.status = 'active';\n this.requestUpdate();\n\n if (state.step.command && !await this.executeStepCommand(state)) {\n return;\n }\n\n await this.checkPostConditions(contributionId, stepIndex);\n }\n\n private async validatePreConditions(state: StepState, contributionId: string, stepIndex: number): Promise<boolean> {\n if (!state.step.preCondition) {\n return true;\n }\n\n if (state.preConditionMet === undefined || state.preConditionMet === false) {\n await this.checkPreConditions(contributionId, stepIndex);\n }\n\n if (state.preConditionMet !== true) {\n toastError(`Pre-conditions not met for step: ${state.step.title}`);\n return false;\n }\n\n return true;\n }\n\n private async executeStepCommand(state: StepState): Promise<boolean> {\n if (!state.step.command) {\n return true;\n }\n\n try {\n const rawParams = state.step.commandParams;\n const params = typeof rawParams === 'function' ? await rawParams() : (rawParams || {});\n const execContext = commandRegistry.createExecutionContext(params);\n await commandRegistry.execute(state.step.command, execContext);\n return true;\n } catch (error) {\n console.error(`Failed to execute command for step ${state.step.id}:`, error);\n toastError(`Failed to execute step: ${state.step.title}`);\n state.status = 'failed';\n this.requestUpdate();\n return false;\n }\n }\n\n private async runStepCommand(contributionId: string, stepIndex: number) {\n const state = this.getStepState(contributionId, stepIndex);\n if (!state || !state.step.command) {\n return;\n }\n\n // Check pre-conditions if they exist\n if (state.step.preCondition) {\n const preConditionMet = await state.step.preCondition();\n if (!preConditionMet) {\n toastError(`Pre-conditions not met for step: ${state.step.title}`);\n return;\n }\n }\n\n // Execute the command\n const success = await this.executeStepCommand(state);\n if (success) {\n // Check post-conditions after command execution\n await this.checkPostConditions(contributionId, stepIndex);\n }\n }\n\n private skipStep(contributionId: string, stepIndex: number) {\n const state = this.getStepState(contributionId, stepIndex);\n if (!state || !state.step.optional) return;\n\n state.status = 'skipped';\n this.activateNextStep(contributionId, stepIndex);\n this.requestUpdate();\n }\n\n private closeHowTo() {\n this.cleanupHowTo();\n this.activeContributionId = null;\n this.stepStates.clear();\n this.requestUpdate();\n }\n\n private async showPanel() {\n this.isVisible = true;\n await this.saveSettings();\n this.requestUpdate();\n await this.updateComplete;\n this.expandPanel();\n }\n\n private async hidePanel() {\n this.isVisible = false;\n await this.saveSettings();\n this.requestUpdate();\n }\n\n private async toggleVisibility() {\n if (this.isVisible) {\n await this.hidePanel();\n } else {\n await this.showPanel();\n }\n }\n\n private renderStep(state: StepState, index: number, contributionId: string) {\n const { step, status, preConditionMet, postConditionMet } = state;\n const isActive = status === 'active';\n const isCompleted = status === 'completed';\n const isFailed = status === 'failed';\n const isPending = status === 'pending';\n const isSkipped = status === 'skipped';\n\n return html`\n <div class=\"step ${status}\" ?data-active=${isActive}>\n <div class=\"step-header\">\n <div class=\"step-number\">${index + 1}</div>\n <div class=\"step-title\">${step.title}</div>\n <div class=\"step-status\">\n ${step.command ? html`\n <wa-button \n size=\"s\" \n appearance=\"plain\" \n @click=${(e: Event) => {\n e.stopPropagation();\n this.runStepCommand(contributionId, index);\n }}\n title=\"Run step command\"\n >\n <wa-icon name=\"play\"></wa-icon>\n </wa-button>\n ` : nothing}\n ${isCompleted ? html`<wa-icon name=\"check-circle\" class=\"status-icon completed\"></wa-icon>` : nothing}\n ${isFailed ? html`<wa-icon name=\"xmark-circle\" class=\"status-icon failed\"></wa-icon>` : nothing}\n ${isSkipped ? html`<wa-icon name=\"minus-circle\" class=\"status-icon skipped\"></wa-icon>` : nothing}\n ${isPending ? html`<wa-icon name=\"circle\" class=\"status-icon pending\"></wa-icon>` : nothing}\n ${isActive ? html`<wa-icon name=\"play-circle\" class=\"status-icon active\"></wa-icon>` : nothing}\n </div>\n </div>\n <div class=\"step-description\">${step.description}</div>\n ${step.preCondition && preConditionMet !== undefined ? html`\n <div class=\"condition pre-condition ${preConditionMet ? 'met' : 'not-met'}\">\n <wa-icon name=\"${preConditionMet ? 'check' : 'xmark'}\"></wa-icon>\n <span>Pre-condition: ${preConditionMet ? 'Met' : 'Not met'}</span>\n </div>\n ` : nothing}\n ${step.postCondition && postConditionMet !== undefined ? html`\n <div class=\"condition post-condition ${postConditionMet ? 'met' : 'not-met'}\">\n <wa-icon name=\"${postConditionMet ? 'check' : 'xmark'}\"></wa-icon>\n <span>Post-condition: ${postConditionMet ? 'Met' : 'Not met'}</span>\n </div>\n ` : nothing}\n ${isActive && step.optional ? html`\n <div class=\"step-actions\">\n <wa-button size=\"s\" appearance=\"outline\" @click=${() => this.skipStep(contributionId, index)}>\n <wa-icon name=\"forward\"></wa-icon>\n Skip\n </wa-button>\n </div>\n ` : nothing}\n </div>\n `;\n }\n\n render() {\n if (!this.isVisible) {\n return nothing;\n }\n\n const activeContribution = this.activeContributionId\n ? howToService.getContribution(this.activeContributionId)\n : null;\n\n const activeStepStates = this.activeContributionId\n ? this.stepStates.get(this.activeContributionId) || []\n : [];\n\n return html`\n <docks-floating-panel\n label=\"HowTo Workflows\"\n icon=\"list-check\"\n .persistKey=${SETTINGS_KEY}\n @floating-close=${() => { void this.hidePanel(); }}\n >\n <div class=\"panel-content\">\n ${activeContribution ? html`\n <div class=\"active-workflow\">\n <div class=\"workflow-header\">\n <div class=\"workflow-title-section\">\n <h3>${typeof activeContribution.title === 'function' \n ? activeContribution.title() \n : activeContribution.title}</h3>\n ${activeContribution.description ? html`\n <p class=\"workflow-description\">${typeof activeContribution.description === 'function'\n ? activeContribution.description()\n : activeContribution.description}</p>\n ` : nothing}\n </div>\n <wa-button \n size=\"s\" \n appearance=\"plain\" \n @click=${this.closeHowTo}\n title=\"Close HowTo\"\n >\n <wa-icon name=\"xmark\"></wa-icon>\n </wa-button>\n </div>\n <div class=\"steps-list\">\n ${activeStepStates.map((state, index) => \n this.renderStep(state, index, this.activeContributionId!)\n )}\n </div>\n </div>\n ` : html`\n <div class=\"workflows-list\">\n <h3>Available Workflows</h3>\n ${this.contributions.length === 0 ? html`\n <div class=\"empty-state\">\n <wa-icon name=\"list-check\" style=\"font-size: 2em; opacity: 0.5; margin-bottom: 12px;\"></wa-icon>\n <p>No HowTo workflows available yet.</p>\n <p style=\"font-size: 0.9em; opacity: 0.7;\">Extensions can register workflows via the contribution registry.</p>\n </div>\n ` : this.contributions.map(contrib => {\n const title = typeof contrib.title === 'function' ? contrib.title() : contrib.title;\n const description = contrib.description \n ? (typeof contrib.description === 'function' ? contrib.description() : contrib.description)\n : null;\n return html`\n <div class=\"workflow-item\" @click=${() => this.startHowTo(contrib.id)}>\n ${contrib.icon ? html`\n <wa-icon name=\"${contrib.icon}\"></wa-icon>\n ` : html`\n <wa-icon name=\"list-check\"></wa-icon>\n `}\n <div class=\"workflow-info\">\n <div class=\"workflow-title\">${title}</div>\n ${description ? html`\n <div class=\"workflow-desc\">${description}</div>\n ` : nothing}\n <div class=\"workflow-meta\">${contrib.steps.length} step${contrib.steps.length !== 1 ? 's' : ''}</div>\n </div>\n </div>\n `})}\n </div>\n `}\n </div>\n </docks-floating-panel>\n `;\n }\n\n static styles = css`\n :host {\n display: contents;\n }\n\n .panel-content {\n width: 400px;\n max-height: 600px;\n box-sizing: border-box;\n overflow-y: auto;\n padding: var(--wa-spacing-large, 16px);\n }\n\n .workflows-list h3 {\n margin: 0 0 var(--wa-spacing-medium, 12px) 0;\n font-size: var(--wa-font-size-medium, 14px);\n font-weight: 600;\n color: var(--wa-color-text-normal, var(--wa-color-neutral-80));\n }\n\n :host-context(.wa-light) .workflows-list h3 {\n color: var(--wa-color-text-normal, var(--wa-color-neutral-20));\n }\n\n .workflow-item {\n display: flex;\n align-items: flex-start;\n gap: var(--wa-spacing-medium, 12px);\n padding: var(--wa-spacing-medium, 12px);\n margin-bottom: var(--wa-spacing-small, 8px);\n background: var(--wa-color-surface-lowered, var(--wa-color-neutral-10));\n border: var(--wa-border-width-s, 1px) solid var(--wa-color-neutral-border-subtle, var(--wa-color-neutral-20));\n border-radius: var(--wa-border-radius-small, 6px);\n cursor: pointer;\n transition: all var(--wa-transition-medium, 0.2s);\n }\n\n :host-context(.wa-light) .workflow-item {\n background: var(--wa-color-surface-lowered, var(--wa-color-neutral-90));\n border-color: var(--wa-color-neutral-border-subtle, var(--wa-color-neutral-80));\n }\n\n .workflow-item:hover {\n background: var(--wa-color-mix-hover, var(--wa-color-neutral-15));\n border-color: var(--wa-color-neutral-border-loud, var(--wa-color-neutral-30));\n }\n\n :host-context(.wa-light) .workflow-item:hover {\n background: var(--wa-color-mix-hover, var(--wa-color-neutral-85));\n border-color: var(--wa-color-neutral-border-loud, var(--wa-color-neutral-70));\n }\n\n .workflow-info {\n flex: 1;\n }\n\n .workflow-title {\n font-weight: 600;\n margin-bottom: var(--wa-spacing-x-small, 4px);\n color: var(--wa-color-text-normal, var(--wa-color-neutral-90));\n }\n\n :host-context(.wa-light) .workflow-title {\n color: var(--wa-color-text-normal, var(--wa-color-neutral-10));\n }\n\n .workflow-desc {\n font-size: var(--wa-font-size-small, 12px);\n color: var(--wa-color-text-subtle, var(--wa-color-neutral-70));\n margin-bottom: var(--wa-spacing-x-small, 4px);\n }\n\n :host-context(.wa-light) .workflow-desc {\n color: var(--wa-color-text-subtle, var(--wa-color-neutral-30));\n }\n\n .workflow-meta {\n font-size: var(--wa-font-size-x-small, 11px);\n color: var(--wa-color-text-quiet, var(--wa-color-neutral-60));\n }\n\n :host-context(.wa-light) .workflow-meta {\n color: var(--wa-color-text-quiet, var(--wa-color-neutral-40));\n }\n\n .active-workflow {\n display: flex;\n flex-direction: column;\n gap: var(--wa-spacing-large, 16px);\n }\n\n .workflow-header {\n display: flex;\n align-items: flex-start;\n justify-content: space-between;\n gap: var(--wa-spacing-medium, 12px);\n margin-bottom: var(--wa-spacing-medium, 12px);\n }\n\n .workflow-title-section {\n flex: 1;\n }\n\n .workflow-header h3 {\n margin: 0 0 var(--wa-spacing-small, 8px) 0;\n font-size: var(--wa-font-size-large, 16px);\n font-weight: 600;\n color: var(--wa-color-text-normal, var(--wa-color-neutral-90));\n }\n\n :host-context(.wa-light) .workflow-header h3 {\n color: var(--wa-color-text-normal, var(--wa-color-neutral-10));\n }\n\n .workflow-description {\n margin: 0;\n font-size: var(--wa-font-size-medium, 13px);\n color: var(--wa-color-text-subtle, var(--wa-color-neutral-70));\n }\n\n :host-context(.wa-light) .workflow-description {\n color: var(--wa-color-text-subtle, var(--wa-color-neutral-30));\n }\n\n .steps-list {\n display: flex;\n flex-direction: column;\n gap: var(--wa-spacing-medium, 12px);\n }\n\n .step {\n padding: var(--wa-spacing-medium, 12px);\n background: var(--wa-color-surface-lowered, var(--wa-color-neutral-10));\n border: var(--wa-border-width-s, 1px) solid var(--wa-color-neutral-border-subtle, var(--wa-color-neutral-20));\n border-radius: var(--wa-border-radius-small, 6px);\n transition: all var(--wa-transition-medium, 0.2s);\n }\n\n :host-context(.wa-light) .step {\n background: var(--wa-color-surface-lowered, var(--wa-color-neutral-90));\n border-color: var(--wa-color-neutral-border-subtle, var(--wa-color-neutral-80));\n }\n\n .step[data-active=\"true\"] {\n border-color: var(--wa-color-primary-50);\n background: var(--wa-color-primary-05);\n }\n\n :host-context(.wa-light) .step[data-active=\"true\"] {\n background: var(--wa-color-primary-95);\n border-color: var(--wa-color-primary-50);\n }\n\n .step.completed {\n border-color: var(--wa-color-success-50);\n background: var(--wa-color-success-05);\n }\n\n :host-context(.wa-light) .step.completed {\n background: var(--wa-color-success-95);\n border-color: var(--wa-color-success-50);\n }\n\n .step.failed {\n border-color: var(--wa-color-danger-50);\n background: var(--wa-color-danger-05);\n }\n\n :host-context(.wa-light) .step.failed {\n background: var(--wa-color-danger-95);\n border-color: var(--wa-color-danger-50);\n }\n\n .step-header {\n display: flex;\n align-items: center;\n gap: var(--wa-spacing-medium, 12px);\n margin-bottom: var(--wa-spacing-small, 8px);\n }\n\n .step-number {\n width: 24px;\n height: 24px;\n display: flex;\n align-items: center;\n justify-content: center;\n background: var(--wa-color-surface-lowered, var(--wa-color-neutral-20));\n border-radius: 50%;\n font-size: var(--wa-font-size-small, 12px);\n font-weight: 600;\n color: var(--wa-color-text-normal, var(--wa-color-neutral-80));\n }\n\n :host-context(.wa-light) .step-number {\n background: var(--wa-color-surface-lowered, var(--wa-color-neutral-80));\n color: var(--wa-color-text-normal, var(--wa-color-neutral-20));\n }\n\n .step-title {\n flex: 1;\n font-weight: 600;\n color: var(--wa-color-text-normal, var(--wa-color-neutral-90));\n }\n\n :host-context(.wa-light) .step-title {\n color: var(--wa-color-text-normal, var(--wa-color-neutral-10));\n }\n\n .step-status {\n display: flex;\n align-items: center;\n gap: var(--wa-spacing-small, 8px);\n }\n\n .status-icon {\n width: 20px;\n height: 20px;\n }\n\n .status-icon.completed {\n color: var(--wa-color-success-50);\n }\n\n .status-icon.failed {\n color: var(--wa-color-danger-50);\n }\n\n .status-icon.skipped {\n color: var(--wa-color-neutral-50);\n }\n\n .status-icon.active {\n color: var(--wa-color-primary-50);\n }\n\n .status-icon.pending {\n color: var(--wa-color-neutral-50);\n }\n\n .step-description {\n font-size: var(--wa-font-size-medium, 13px);\n color: var(--wa-color-text-subtle, var(--wa-color-neutral-70));\n margin-bottom: var(--wa-spacing-small, 8px);\n line-height: 1.4;\n }\n\n :host-context(.wa-light) .step-description {\n color: var(--wa-color-text-subtle, var(--wa-color-neutral-30));\n }\n\n .condition {\n display: flex;\n align-items: center;\n gap: var(--wa-spacing-x-small, 6px);\n font-size: var(--wa-font-size-small, 12px);\n padding: var(--wa-spacing-x-small, 6px) var(--wa-spacing-small, 8px);\n border-radius: var(--wa-border-radius-x-small, 4px);\n margin-bottom: var(--wa-spacing-small, 8px);\n }\n\n .condition.met {\n background: var(--wa-color-success-10);\n color: var(--wa-color-success-70);\n }\n\n :host-context(.wa-light) .condition.met {\n background: var(--wa-color-success-90);\n color: var(--wa-color-success-30);\n }\n\n .condition.not-met {\n background: var(--wa-color-danger-10);\n color: var(--wa-color-danger-70);\n }\n\n :host-context(.wa-light) .condition.not-met {\n background: var(--wa-color-danger-90);\n color: var(--wa-color-danger-30);\n }\n\n .step-actions {\n display: flex;\n gap: var(--wa-spacing-small, 8px);\n margin-top: var(--wa-spacing-small, 8px);\n }\n\n .empty-state {\n display: flex;\n flex-direction: column;\n align-items: center;\n justify-content: center;\n padding: var(--wa-spacing-x-large, 40px) var(--wa-spacing-large, 20px);\n text-align: center;\n color: var(--wa-color-text-subtle, var(--wa-color-neutral-70));\n }\n\n :host-context(.wa-light) .empty-state {\n color: var(--wa-color-text-subtle, var(--wa-color-neutral-30));\n }\n\n .empty-state p {\n margin: var(--wa-spacing-small, 8px) 0;\n }\n `;\n}\n\n","import { createLogger } from '@eclipse-docks/core';\nimport { rootContext } from '@eclipse-docks/core';\nimport { howToService } from './howto-service';\nimport { HOWTO_CONTRIBUTION_TARGET } from './howto-service';\nimport './contributions/onboarding-howto-contributions';\nimport './contributions/ai-setup-howto-contributions';\nimport { TOPIC_SHOW_HOWTO_PANEL, TOPIC_TOGGLE_HOWTO_PANEL } from './howto-panel';\nimport { registerAll } from '@eclipse-docks/core';\nimport { publish } from '@eclipse-docks/core';\nimport { TOOLBAR_BOTTOM_END } from '@eclipse-docks/core';\nimport './howto-panel';\n\nconst logger = createLogger('HowToExtension');\n\n/**\n * HowTo System Extension\n * \n * Provides a system for registering and displaying step-by-step workflows\n * that guide users through specific processes with pre and post condition checks.\n * \n * Features:\n * - Register HowToContributions via contribution registry\n * - Floating, draggable UI panel\n * - Sequential step execution\n * - Pre and post condition validation\n * - Step status tracking\n */\nexport default function howToExtension(context: any) {\n logger.info('HowTo system extension loaded');\n\n // Register the HowTo service in the dependency injection context\n rootContext.put('howToService', howToService);\n\n // Ensure the panel is added to the DOM\n const ensurePanelInDOM = () => {\n // Check if panel already exists\n if (document.querySelector('docks-howto-panel')) {\n return;\n }\n\n // Create and append the panel\n const panel = document.createElement('docks-howto-panel');\n document.body.appendChild(panel);\n logger.info('HowTo panel added to DOM');\n };\n\n // Add panel to DOM - use requestAnimationFrame to ensure DOM is ready\n if (document.body) {\n requestAnimationFrame(() => {\n ensurePanelInDOM();\n });\n } else {\n // Wait for DOM to be ready\n const checkDOM = () => {\n if (document.body) {\n ensurePanelInDOM();\n } else {\n requestAnimationFrame(checkDOM);\n }\n };\n requestAnimationFrame(checkDOM);\n }\n\n // Register command to show/toggle the HowTo panel\n registerAll({\n command: {\n id: 'howto.show-panel',\n name: 'Show HowTo Panel',\n description: 'Shows the HowTo workflows panel',\n icon: 'list-check',\n parameters: []\n },\n handler: {\n execute: () => {\n publish(TOPIC_SHOW_HOWTO_PANEL, null);\n }\n }\n });\n\n registerAll({\n command: {\n id: 'howto.toggle-panel',\n name: 'Toggle HowTo Panel',\n description: 'Toggles the visibility of the HowTo workflows panel',\n icon: 'list-check',\n keyBinding: 'CTRL+SHIFT+H',\n parameters: []\n },\n handler: {\n execute: () => {\n publish(TOPIC_TOGGLE_HOWTO_PANEL, null);\n }\n },\n contribution: {\n target: TOOLBAR_BOTTOM_END,\n icon: 'list-check',\n label: 'HowTo',\n }\n });\n\n logger.info('HowTo system extension initialized');\n}\n\n// Export the service and types for direct imports\nexport { howToService, HOWTO_CONTRIBUTION_TARGET } from './howto-service';\nexport type { HowToContribution, HowToStep, ConditionFunction } from './howto-contribution';\n\n"],"mappings":";;;;;;AAMA,IAAMA,WAAS,aAAa,cAAc;AAE1C,IAAa,4BAA4B;;;;;;;AAQzC,IAAa,eAAb,MAA0B;CAGtB,cAAc;EAF0C,KAAA,gCAAA,IAAI,IAAI;EAI5D,KAAK,kBAAkB;EAGvB,UAAU,+BAA+B,UAAe;GACpD,IAAI,MAAM,WAAA,iBACN,KAAK,kBAAkB;EAE/B,CAAC;CACL;;;;CAKA,oBAAkC;EAC9B,MAAM,gBAAgB,qBAAqB,iBAAiB,yBAAyB;EAErF,KAAK,cAAc,MAAM;EAEzB,KAAK,MAAM,gBAAgB,eAAe;GAEtC,IAAI,CAAC,aAAa,IAAI;IAClB,SAAO,KAAK,yCAAyC;IACrD;GACJ;GAEA,IAAI,CAAC,aAAa,OAMd,aAAa,QAHC,OAAO,aAAa,UAAU,aACtC,aAAa,MAAM,IACnB,aAAa;GAIvB,IAAI,CAAC,aAAa,SAAS,aAAa,MAAM,WAAW,GAAG;IACxD,SAAO,KAAK,uBAAuB,aAAa,GAAG,yBAAyB;IAC5E;GACJ;GAGA,MAAM,0BAAU,IAAI,IAAY;GAChC,KAAK,MAAM,QAAQ,aAAa,OAAO;IACnC,IAAI,QAAQ,IAAI,KAAK,EAAE,GAAG;KACtB,SAAO,KAAK,uBAAuB,aAAa,GAAG,4BAA4B,KAAK,GAAG,EAAE;K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Q;CAClC;CAGA,YAAY;EACR,SAAS;GACL,IAAI;GACJ,MAAM;GACN,aAAa;GACb,MAAM;GACN,YAAY,CAAC;EACjB;EACA,SAAS,EACL,eAAe;GACX,QAAQ,wBAAwB,IAAI;EACxC,EACJ;CACJ,CAAC;CAED,YAAY;EACR,SAAS;GACL,IAAI;GACJ,MAAM;GACN,aAAa;GACb,MAAM;GACN,YAAY;GACZ,YAAY,CAAC;EACjB;EACA,SAAS,EACL,eAAe;GACX,QAAQ,0BAA0B,IAAI;EAC1C,EACJ;EACA,cAAc;GACV,QAAQ;GACR,MAAM;GACN,OAAO;EACX;CACJ,CAAC;CAED,OAAO,KAAK,oCAAoC;AACpD"}
|
|
@@ -1,11 +1,10 @@
|
|
|
1
|
-
|
|
1
|
+
// src/i18n.de.json
|
|
2
2
|
var EXT_HOWTO_NAME = "HowTo-System";
|
|
3
3
|
var EXT_HOWTO_DESC = "Schritt-für-Schritt-Workflow-System mit Vor- und Nachbedingungsprüfungen";
|
|
4
4
|
var i18n_de_default = {
|
|
5
5
|
EXT_HOWTO_NAME,
|
|
6
6
|
EXT_HOWTO_DESC
|
|
7
7
|
};
|
|
8
|
-
//#endregion
|
|
9
8
|
export { EXT_HOWTO_DESC, EXT_HOWTO_NAME, i18n_de_default as default };
|
|
10
9
|
|
|
11
|
-
//# sourceMappingURL=i18n.de-
|
|
10
|
+
//# sourceMappingURL=i18n.de-CmqGh2TT.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"i18n.de-
|
|
1
|
+
{"version":3,"file":"i18n.de-CmqGh2TT.js","names":[],"sources":["../src/i18n.de.json"],"sourcesContent":["{\n \"EXT_HOWTO_NAME\": \"HowTo-System\",\n \"EXT_HOWTO_DESC\": \"Schritt-für-Schritt-Workflow-System mit Vor- und Nachbedingungsprüfungen\"\n}\n"],"mappings":""}
|
|
@@ -1,11 +1,10 @@
|
|
|
1
|
-
|
|
1
|
+
// src/i18n.en.json
|
|
2
2
|
var EXT_HOWTO_NAME = "HowTo System";
|
|
3
3
|
var EXT_HOWTO_DESC = "Step-by-step workflow system with pre and post condition checks";
|
|
4
4
|
var i18n_en_default = {
|
|
5
5
|
EXT_HOWTO_NAME,
|
|
6
6
|
EXT_HOWTO_DESC
|
|
7
7
|
};
|
|
8
|
-
//#endregion
|
|
9
8
|
export { EXT_HOWTO_DESC, EXT_HOWTO_NAME, i18n_en_default as default };
|
|
10
9
|
|
|
11
|
-
//# sourceMappingURL=i18n.en-
|
|
10
|
+
//# sourceMappingURL=i18n.en-DoB47dTB.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"i18n.en-
|
|
1
|
+
{"version":3,"file":"i18n.en-DoB47dTB.js","names":[],"sources":["../src/i18n.en.json"],"sourcesContent":["{\n \"EXT_HOWTO_NAME\": \"HowTo System\",\n \"EXT_HOWTO_DESC\": \"Step-by-step workflow system with pre and post condition checks\"\n}\n"],"mappings":""}
|
package/dist/index.js
CHANGED
|
@@ -1,19 +1,18 @@
|
|
|
1
1
|
import { extensionRegistry, i18n } from "@eclipse-docks/core";
|
|
2
2
|
import pkg from "../package.json";
|
|
3
|
-
|
|
3
|
+
// src/index.ts
|
|
4
4
|
var t = await i18n(/* #__PURE__ */ Object.assign({
|
|
5
|
-
"./i18n.de.json": () => import("./i18n.de-
|
|
6
|
-
"./i18n.en.json": () => import("./i18n.en-
|
|
5
|
+
"./i18n.de.json": () => import("./i18n.de-CmqGh2TT.js"),
|
|
6
|
+
"./i18n.en.json": () => import("./i18n.en-DoB47dTB.js")
|
|
7
7
|
}), true);
|
|
8
8
|
extensionRegistry.registerExtension({
|
|
9
9
|
id: pkg.name,
|
|
10
10
|
name: t.EXT_HOWTO_NAME,
|
|
11
11
|
description: t.EXT_HOWTO_DESC,
|
|
12
|
-
loader: () => import("./howto-extension-
|
|
12
|
+
loader: () => import("./howto-extension-BbJ7J894.js"),
|
|
13
13
|
icon: "list-check",
|
|
14
14
|
experimental: true,
|
|
15
15
|
dependencies: ["@eclipse-docks/extension-ai-system"]
|
|
16
16
|
});
|
|
17
|
-
//#endregion
|
|
18
17
|
|
|
19
18
|
//# sourceMappingURL=index.js.map
|