Skip to content

Commit f7f1793

Browse files
authored
Merge pull request #80 from esokullu/codex/fix-recommended-actions-overlay
[codex] Fix suggested action overlay
2 parents 71df10f + fcf60a4 commit f7f1793

16 files changed

Lines changed: 121 additions & 31 deletions

package-lock.json

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "webbrain",
3-
"version": "21.5.0",
3+
"version": "21.5.1",
44
"description": "Open-source AI browser agent — chat with pages, automate tasks, multi-provider LLM support.",
55
"private": true,
66
"type": "module",

src/chrome/ARCHITECTURE.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# WebBrain Chrome/Edge Extension — Architecture
22

3-
> Version 21.5.0 · Manifest V3 · Service Worker background
3+
> Version 21.5.1 · Manifest V3 · Service Worker background
44
55
## High-Level Overview
66

src/chrome/manifest.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"manifest_version": 3,
33
"name": "WebBrain",
4-
"version": "21.5.0",
4+
"version": "21.5.1",
55
"description": "Open-source AI browser agent — chat with pages, automate tasks, multi-provider LLM support.",
66
"permissions": [
77
"sidePanel",

src/chrome/src/ui/settings.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ import {
1919

2020
// Version shown in the subtitle. Kept here so it only needs one update per
2121
// release; the subtitle string itself is translated.
22-
const EXT_VERSION = '21.5.0';
22+
const EXT_VERSION = '21.5.1';
2323

2424
const providersContainer = document.getElementById('providers');
2525
const displaySettings = document.getElementById('display-settings');

src/chrome/src/ui/sidepanel.js

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1464,6 +1464,7 @@ async function handleScheduledJobEvent(data, tabId) {
14641464
isProcessing = true;
14651465
abortRequested = false;
14661466
syncSendButtonState();
1467+
hideRecommendedActions();
14671468
currentAssistantEl = addMessage('assistant', '');
14681469
if (jobId) currentAssistantEl.dataset.scheduledJobId = jobId;
14691470
showActivity(t('sp.scheduled.running', { title }));
@@ -1481,6 +1482,7 @@ async function handleScheduledJobEvent(data, tabId) {
14811482
clearActiveChatPayloadForTab(tabId ?? currentTabId);
14821483
isProcessing = true;
14831484
syncSendButtonState();
1485+
hideRecommendedActions();
14841486
} else {
14851487
isProcessing = false;
14861488
syncSendButtonState();
@@ -2077,6 +2079,7 @@ function conversationHasUserMessages() {
20772079
}
20782080

20792081
function hideRecommendedActions() {
2082+
recommendationsRequestId += 1;
20802083
if (!recommendedActionsEl || !recommendedActionsListEl) return;
20812084
recommendedActionsListEl.replaceChildren();
20822085
recommendedActionsEl.classList.add('hidden');
@@ -3790,6 +3793,7 @@ function renderClarifyCard(data) {
37903793
const tabId = data?.scheduledTabId ?? data?.tabId ?? currentTabId;
37913794
if (tabId == null) return;
37923795
const scheduledJobId = data?.scheduledJobId ? String(data.scheduledJobId) : '';
3796+
if (scheduledJobId) hideRecommendedActions();
37933797
let assistantEl = currentAssistantEl;
37943798
if (scheduledJobId && data.forceNewScheduledCard) {
37953799
assistantEl = addMessage('assistant', '');
@@ -4133,6 +4137,7 @@ function submitClarify(card, tabId, clarifyId, answer, source) {
41334137
}
41344138
isProcessing = true;
41354139
syncSendButtonState();
4140+
hideRecommendedActions();
41364141
showActivity(t('sp.activity.thinking'));
41374142
}
41384143
sendToBackground('clarify_response', { tabId, clarifyId, answer, source })

src/chrome/styles/sidepanel.css

Lines changed: 6 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1061,26 +1061,23 @@ body {
10611061

10621062

10631063

1064-
/* Context-aware recommendations — centered pill row in the chat body */
1064+
/* Context-aware recommendations — inline centered pill row in the chat body */
10651065
.recommended-actions {
1066-
position: absolute;
1067-
inset: 0;
1068-
z-index: 2;
10691066
display: flex;
10701067
flex-direction: column;
10711068
align-items: center;
1072-
justify-content: center;
10731069
gap: 8px;
1074-
margin: 0;
1075-
padding: 16px 12px;
1070+
margin: 12px 0 4px;
1071+
padding: 0 4px;
10761072
border: none;
10771073
border-radius: 0;
10781074
background: transparent;
1079-
pointer-events: none;
1075+
box-sizing: border-box;
1076+
width: 100%;
10801077
}
10811078

10821079
.recommended-actions.collapsed {
1083-
padding: 16px 12px;
1080+
margin-bottom: 0;
10841081
}
10851082

10861083
.recommended-actions.hidden {
@@ -1093,7 +1090,6 @@ body {
10931090
justify-content: center;
10941091
gap: 6px;
10951092
margin-bottom: 0;
1096-
pointer-events: auto;
10971093
}
10981094

10991095
.recommended-actions.collapsed .recommended-actions-header {
@@ -1152,7 +1148,6 @@ body {
11521148
gap: 6px;
11531149
justify-content: center;
11541150
max-width: min(100%, 340px);
1155-
pointer-events: auto;
11561151
}
11571152

11581153
.recommended-actions.collapsed .recommended-actions-list {

0 commit comments

Comments
 (0)