Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
22 commits
Select commit Hold shift + click to select a range
f611078
refactor(ai): rename PromptClient to GeminiNanoProvider with Provider…
dobrinyonkov Jul 6, 2026
531846f
refactor(ai): add provider registry with Gemini registered
dobrinyonkov Jul 6, 2026
e6cf674
feat(ai): add OpenAIProvider with hardcoded gateway config
dobrinyonkov Jul 6, 2026
dd3518a
refactor(ai): move OpenAIProvider network I/O into service worker
dobrinyonkov Jul 6, 2026
f6ab11b
fix(ai): allow service-worker fetch through extension_pages CSP
dobrinyonkov Jul 6, 2026
c973648
feat(ai): storage-driven provider selection and setProvider hot-swap
dobrinyonkov Jul 6, 2026
5170c58
feat(ai): settings modal with gear icon for provider selection
dobrinyonkov Jul 6, 2026
55ae9a1
fix(ai): feature-detect getUsageInfo and tighten banner button layout
dobrinyonkov Jul 6, 2026
2b3e5fe
feat(ai): add placeholders to provider config inputs
dobrinyonkov Jul 6, 2026
859c810
fix(ai): stop mislabelling the banner as Gemini for other providers
dobrinyonkov Jul 6, 2026
990c3a3
feat(ai): per-provider feature detection and not-configured banner ac…
dobrinyonkov Jul 6, 2026
d7eb7b9
fix(ai): hide token counter across all capability states, allow clear…
dobrinyonkov Jul 6, 2026
15bdea3
chore(ai): raise prompt section caps to ~2000 tokens
dobrinyonkov Jul 6, 2026
a33152b
refactor(ai): collapse OpenAI port-protocol specs into one integratio…
dobrinyonkov Jul 7, 2026
d0c2fad
refactor(ai): drop defensive wrappers around console-error accessors
dobrinyonkov Jul 7, 2026
9770172
refactor(ai): consolidate overlapping describe blocks in AssistantCon…
dobrinyonkov Jul 7, 2026
b1a1a71
refactor(ai): parametrise state-machine tests in AIChat.spec
dobrinyonkov Jul 7, 2026
915c942
refactor(ai): parametrise input-type and placeholder tests in AISetti…
dobrinyonkov Jul 7, 2026
e30fdbe
refactor(ai): dedupe visibility helpers and trim JSDoc in AIChat
dobrinyonkov Jul 7, 2026
90f6f65
refactor(ai): simplify recent AI code and delete verified dead code
dobrinyonkov Jul 7, 2026
a63504f
feat(ai): render grouped inherited properties with types in the prompt
dobrinyonkov Jul 8, 2026
efcf64e
feat(ai): render Enums used subsection with valid values for enum-typ…
dobrinyonkov Jul 8, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion .jshintrc
Original file line number Diff line number Diff line change
Expand Up @@ -166,6 +166,7 @@
"Event": true,
"ace": true,
"self": true,
"AbortController": true
"AbortController": true,
"AbortSignal": true
}
}
2 changes: 1 addition & 1 deletion app/manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
}
],
"content_security_policy": {
"extension_pages": "default-src 'self'; img-src 'self' data:; style-src 'unsafe-inline';"
"extension_pages": "default-src 'self'; connect-src 'self' http: https:; img-src 'self' data:; style-src 'unsafe-inline';"
},
"description": "With the UI5 Inspector, you can easily debug and support your OpenUI5 or SAPUI5-based apps.",
"devtools_page": "/html/devtools/index.html",
Expand Down
7 changes: 3 additions & 4 deletions app/scripts/background/main.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
var utils = require('../modules/utils/utils.js');
var ContextMenu = require('../modules/background/ContextMenu.js');
var pageAction = require('../modules/background/pageAction.js');
var attachOpenAIHandler = require('../modules/background/openaiHandler.js');

var contextMenu = new ContextMenu({
title: 'Inspect UI5 control',
Expand Down Expand Up @@ -430,10 +431,6 @@
promptAPIController.abort();
promptAPIController = null;
}

port.postMessage({
type: 'session-destroyed'
});
}

// Listen for long-lived connections for Prompt API
Expand Down Expand Up @@ -461,6 +458,8 @@
break;
}
});
} else if (port.name === 'openai-api') {
attachOpenAIHandler(port);
}
});

Expand Down
47 changes: 33 additions & 14 deletions app/scripts/devtools/panel/ui5/main.js
Original file line number Diff line number Diff line change
Expand Up @@ -449,7 +449,7 @@
});

// AI Chat component
var aiChat = new AIChat('ai-chat', {
var aiChatOptions = {
getAppInfo: function () {
var currentFrameId = framesSelect.getSelectedId();
return frameData[currentFrameId] ? frameData[currentFrameId].applicationInformation : null;
Expand All @@ -473,12 +473,25 @@
frameId: currentFrameId
});
}
};

var aiChat;
chrome.storage.local.get(['ai_provider_name', 'ai_provider_config'], function (stored) {
/* jshint camelcase:false */
var name = stored && typeof stored.ai_provider_name === 'string' ? stored.ai_provider_name : 'gemini-nano';
var perProvider = stored && stored.ai_provider_config && typeof stored.ai_provider_config === 'object' ? stored.ai_provider_config : {};
var config = perProvider[name] && typeof perProvider[name] === 'object' ? perProvider[name] : {};
aiChatOptions.providerName = name;
aiChatOptions.providerConfig = config;
aiChat = new AIChat('ai-chat', aiChatOptions);
});

// Tear down the AI session when the panel page is unloaded so the background
// service worker disconnects the prompt-api port and destroys the model session.
window.addEventListener('beforeunload', function () {
aiChat.destroy();
if (aiChat) {
aiChat.destroy();
}
});

// Notify the AI tab when it becomes active so the transcript scrolls to the
Expand All @@ -489,7 +502,9 @@
if (aiTabElement) {
aiTabElement.addEventListener('click', function () {
window.requestAnimationFrame(function () {
aiChat.onTabActivated();
if (aiChat) {
aiChat.onTabActivated();
}
});
});
}
Expand Down Expand Up @@ -550,7 +565,9 @@
controlTree.setData(message.controlTree);

// Set URL for AI Chat history
aiChat.setUrl(frameData[frameId].url);
if (aiChat) {
aiChat.setUrl(frameData[frameId].url);
}
appInfo.setData(message.applicationInformation);
oElementsRegistryMasterView.setData(message.elementRegistry);
}
Expand Down Expand Up @@ -639,16 +656,18 @@
}
}

aiChat.updateContext({
control: {
type: controlType,
id: controlId,
properties: message.controlProperties,
bindings: message.controlBindings,
aggregations: message.controlAggregations
},
appInfo: frameData[frameId].applicationInformation
});
if (aiChat) {
aiChat.updateContext({
control: {
type: controlType,
id: controlId,
properties: message.controlProperties,
bindings: message.controlBindings,
aggregations: message.controlAggregations
},
appInfo: frameData[frameId].applicationInformation
});
}
}
},

Expand Down
Loading
Loading