@vite-plugin-opencode-assistant/components 1.0.91 → 1.0.93

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (31) hide show
  1. package/es/index.d.ts +1 -1
  2. package/es/index.mjs +1 -1
  3. package/es/open-code-widget/composables/use-persist-state.d.ts +2 -0
  4. package/es/open-code-widget/composables/use-persist-state.mjs +2 -0
  5. package/es/open-code-widget/src/components/ChatPanel.vue.d.ts +2 -2
  6. package/es/open-code-widget/src/components/Frame.vue.mjs +7 -13
  7. package/es/open-code-widget/src/components/Header-sfc.css +1 -1
  8. package/es/open-code-widget/src/components/Header.vue.mjs +55 -23
  9. package/es/open-code-widget/src/components/SelectHint-sfc.css +1 -1
  10. package/es/open-code-widget/src/components/SelectHint.vue.mjs +2 -8
  11. package/es/open-code-widget/src/context.d.ts +2 -0
  12. package/es/open-code-widget/src/index-sfc.css +1 -1
  13. package/es/open-code-widget/src/index.vue.mjs +13 -1
  14. package/lib/@vite-plugin-opencode-assistant/components.cjs.js +65 -30
  15. package/lib/@vite-plugin-opencode-assistant/components.es.js +65 -30
  16. package/lib/components.css +3 -3
  17. package/lib/index.cjs +1 -1
  18. package/lib/index.d.ts +1 -1
  19. package/lib/open-code-widget/composables/use-persist-state.cjs +2 -0
  20. package/lib/open-code-widget/composables/use-persist-state.d.ts +2 -0
  21. package/lib/open-code-widget/src/components/ChatPanel.vue.d.ts +2 -2
  22. package/lib/open-code-widget/src/components/Frame.vue.cjs +6 -12
  23. package/lib/open-code-widget/src/components/Header-sfc.css +1 -1
  24. package/lib/open-code-widget/src/components/Header.vue.cjs +55 -23
  25. package/lib/open-code-widget/src/components/SelectHint-sfc.css +1 -1
  26. package/lib/open-code-widget/src/components/SelectHint.vue.cjs +1 -7
  27. package/lib/open-code-widget/src/context.d.ts +2 -0
  28. package/lib/open-code-widget/src/index-sfc.css +1 -1
  29. package/lib/open-code-widget/src/index.vue.cjs +13 -1
  30. package/lib/web-types.json +1 -1
  31. package/package.json +2 -2
@@ -67,11 +67,6 @@ var __vue_sfc__$9 = /* @__PURE__ */ (0, vue.defineComponent)({
67
67
  if (!((_a = iframeRef.value) == null ? void 0 : _a.contentWindow)) return;
68
68
  iframeRef.value.contentWindow.postMessage(__spreadValues$4({ type }, data), "*");
69
69
  }
70
- (0, vue.onMounted)(() => {
71
- if (iframeRef.value) iframeRef.value.addEventListener("load", () => {
72
- handleFrameLoaded();
73
- });
74
- });
75
70
  __expose({ sendMessageToIframe });
76
71
  const __returned__ = {
77
72
  iframeRef,
@@ -98,7 +93,7 @@ var _hoisted_3$5 = ["src"];
98
93
  function __vue_render__$9(_ctx, _cache, $props, $setup, $data, $options) {
99
94
  return (0, vue.openBlock)(), (0, vue.createElementBlock)("div", _hoisted_1$7, [
100
95
  (0, vue.createElementVNode)("div", { class: (0, vue.normalizeClass)(["opencode-empty-state-overlay", { visible: $setup.showEmptyState }]) }, [(0, vue.renderSlot)(_ctx.$slots, "empty-state", {}, () => [
101
- _cache[1] || (_cache[1] = (0, vue.createElementVNode)("div", { class: "opencode-empty-state-icon" }, [(0, vue.createElementVNode)("svg", {
96
+ _cache[2] || (_cache[2] = (0, vue.createElementVNode)("div", { class: "opencode-empty-state-icon" }, [(0, vue.createElementVNode)("svg", {
102
97
  viewBox: "0 0 24 24",
103
98
  width: "48",
104
99
  height: "48",
@@ -118,15 +113,16 @@ function __vue_render__$9(_ctx, _cache, $props, $setup, $data, $options) {
118
113
  onClick: _cache[0] || (_cache[0] = (...args) => $setup.handleEmptyAction && $setup.handleEmptyAction(...args))
119
114
  }, (0, vue.toDisplayString)($setup.emptyStateActionText), 1)
120
115
  ])], 2),
121
- (0, vue.createElementVNode)("div", { class: (0, vue.normalizeClass)(["opencode-loading-overlay", { visible: $setup.frameLoading }]) }, [(0, vue.renderSlot)(_ctx.$slots, "loading", {}, () => [_cache[2] || (_cache[2] = (0, vue.createElementVNode)("div", { class: "opencode-loading-spinner" }, null, -1)), _cache[3] || (_cache[3] = (0, vue.createElementVNode)("div", { class: "opencode-loading-text" }, "加载中...", -1))])], 2),
116
+ (0, vue.createElementVNode)("div", { class: (0, vue.normalizeClass)(["opencode-loading-overlay", { visible: $setup.frameLoading }]) }, [(0, vue.renderSlot)(_ctx.$slots, "loading", {}, () => [_cache[3] || (_cache[3] = (0, vue.createElementVNode)("div", { class: "opencode-loading-spinner" }, null, -1)), _cache[4] || (_cache[4] = (0, vue.createElementVNode)("div", { class: "opencode-loading-text" }, "加载中...", -1))])], 2),
122
117
  (0, vue.createElementVNode)("div", { class: (0, vue.normalizeClass)(["opencode-error-overlay", { visible: $setup.showError }]) }, [(0, vue.renderSlot)(_ctx.$slots, "error")], 2),
123
118
  (0, vue.renderSlot)(_ctx.$slots, "content", {}, () => [(0, vue.createElementVNode)("iframe", {
124
119
  ref: "iframeRef",
125
120
  class: "opencode-iframe",
126
121
  src: $setup.iframeSrc,
127
122
  allow: "clipboard-write; clipboard-read",
128
- referrerpolicy: "origin"
129
- }, null, 8, _hoisted_3$5)])
123
+ referrerpolicy: "origin",
124
+ onLoad: _cache[1] || (_cache[1] = (...args) => $setup.handleFrameLoaded && $setup.handleFrameLoaded(...args))
125
+ }, null, 40, _hoisted_3$5)])
130
126
  ]);
131
127
  }
132
128
  __vue_sfc__$9.render = __vue_render__$9;
@@ -137,7 +133,7 @@ var __vue_sfc__$8 = /* @__PURE__ */ (0, vue.defineComponent)({
137
133
  __name: "Header",
138
134
  setup(__props, { expose: __expose }) {
139
135
  __expose();
140
- const { title, sessionListTitle, sessionListCollapsed, selectMode, selectEnabled, theme, resolvedTheme, minimized, promptDockVisible, mode, displayMode, splitPosition, handleToggleSessionList, handleToggleSelectMode, handleToggleTheme, handleToggleDisplayMode, handleToggleSplitPosition, handleClose, handleToggleMinimize, handleTogglePromptDock, handleRefresh } = useOpenCodeWidgetContext();
136
+ const { title, sessionListTitle, sessionListCollapsed, selectMode, selectEnabled, theme, resolvedTheme, minimized, promptDockVisible, reviewPanelVisible, mode, displayMode, splitPosition, handleToggleSessionList, handleToggleSelectMode, handleToggleTheme, handleToggleDisplayMode, handleToggleSplitPosition, handleClose, handleToggleMinimize, handleTogglePromptDock, handleToggleReviewPanel, handleRefresh } = useOpenCodeWidgetContext();
141
137
  const __returned__ = {
142
138
  title,
143
139
  sessionListTitle,
@@ -148,6 +144,7 @@ var __vue_sfc__$8 = /* @__PURE__ */ (0, vue.defineComponent)({
148
144
  resolvedTheme,
149
145
  minimized,
150
146
  promptDockVisible,
147
+ reviewPanelVisible,
151
148
  mode,
152
149
  displayMode,
153
150
  splitPosition,
@@ -159,6 +156,7 @@ var __vue_sfc__$8 = /* @__PURE__ */ (0, vue.defineComponent)({
159
156
  handleClose,
160
157
  handleToggleMinimize,
161
158
  handleTogglePromptDock,
159
+ handleToggleReviewPanel,
162
160
  handleRefresh,
163
161
  isSplitMode: (0, vue.computed)(() => mode.value === "split"),
164
162
  themeIconTitle: (0, vue.computed)(() => {
@@ -319,7 +317,12 @@ var _hoisted_19 = [
319
317
  "aria-label",
320
318
  "aria-pressed"
321
319
  ];
322
- var _hoisted_20 = {
320
+ var _hoisted_20 = [
321
+ "title",
322
+ "aria-label",
323
+ "aria-pressed"
324
+ ];
325
+ var _hoisted_21 = {
323
326
  key: 0,
324
327
  viewBox: "0 0 24 24",
325
328
  width: "14",
@@ -329,7 +332,7 @@ var _hoisted_20 = {
329
332
  "stroke-width": "2",
330
333
  "aria-hidden": "true"
331
334
  };
332
- var _hoisted_21 = {
335
+ var _hoisted_22 = {
333
336
  key: 1,
334
337
  viewBox: "0 0 24 24",
335
338
  width: "14",
@@ -349,7 +352,7 @@ function __vue_render__$8(_ctx, _cache, $props, $setup, $data, $options) {
349
352
  "aria-label": $setup.sessionListTitle,
350
353
  "aria-expanded": !$setup.sessionListCollapsed,
351
354
  onClick: _cache[0] || (_cache[0] = (...args) => $setup.handleToggleSessionList && $setup.handleToggleSessionList(...args))
352
- }, [(0, vue.renderSlot)(_ctx.$slots, "session-toggle-icon", {}, () => [_cache[9] || (_cache[9] = (0, vue.createElementVNode)("svg", {
355
+ }, [(0, vue.renderSlot)(_ctx.$slots, "session-toggle-icon", {}, () => [_cache[10] || (_cache[10] = (0, vue.createElementVNode)("svg", {
353
356
  viewBox: "0 0 24 24",
354
357
  width: "16",
355
358
  height: "16",
@@ -369,7 +372,7 @@ function __vue_render__$8(_ctx, _cache, $props, $setup, $data, $options) {
369
372
  "aria-pressed": $setup.selectMode,
370
373
  disabled: !$setup.selectEnabled,
371
374
  onClick: _cache[1] || (_cache[1] = (...args) => $setup.handleToggleSelectMode && $setup.handleToggleSelectMode(...args))
372
- }, [(0, vue.renderSlot)(_ctx.$slots, "select-icon", {}, () => [_cache[10] || (_cache[10] = (0, vue.createElementVNode)("svg", {
375
+ }, [(0, vue.renderSlot)(_ctx.$slots, "select-icon", {}, () => [_cache[11] || (_cache[11] = (0, vue.createElementVNode)("svg", {
373
376
  viewBox: "0 0 1024 1024",
374
377
  width: "16",
375
378
  height: "16",
@@ -387,7 +390,7 @@ function __vue_render__$8(_ctx, _cache, $props, $setup, $data, $options) {
387
390
  title: $setup.themeIconTitle,
388
391
  "aria-label": $setup.themeIconLabel,
389
392
  onClick: _cache[2] || (_cache[2] = (...args) => $setup.handleToggleTheme && $setup.handleToggleTheme(...args))
390
- }, [(0, vue.renderSlot)(_ctx.$slots, "theme-icon", {}, () => [$setup.theme === "light" ? ((0, vue.openBlock)(), (0, vue.createElementBlock)("svg", _hoisted_6$4, [..._cache[11] || (_cache[11] = [(0, vue.createStaticVNode)("<circle cx=\"12\" cy=\"12\" r=\"5\"></circle><line x1=\"12\" y1=\"1\" x2=\"12\" y2=\"3\"></line><line x1=\"12\" y1=\"21\" x2=\"12\" y2=\"23\"></line><line x1=\"4.22\" y1=\"4.22\" x2=\"5.64\" y2=\"5.64\"></line><line x1=\"18.36\" y1=\"18.36\" x2=\"19.78\" y2=\"19.78\"></line><line x1=\"1\" y1=\"12\" x2=\"3\" y2=\"12\"></line><line x1=\"21\" y1=\"12\" x2=\"23\" y2=\"12\"></line><line x1=\"4.22\" y1=\"19.78\" x2=\"5.64\" y2=\"18.36\"></line><line x1=\"18.36\" y1=\"5.64\" x2=\"19.78\" y2=\"4.22\"></line>", 9)])])) : $setup.theme === "dark" ? ((0, vue.openBlock)(), (0, vue.createElementBlock)("svg", _hoisted_7$2, [..._cache[12] || (_cache[12] = [(0, vue.createElementVNode)("path", { d: "M21 12.79A9 9 0 1 1 11.21 3 7 7 0 0 0 21 12.79z" }, null, -1)])])) : ((0, vue.openBlock)(), (0, vue.createElementBlock)("svg", _hoisted_8$1, [..._cache[13] || (_cache[13] = [(0, vue.createStaticVNode)("<rect x=\"2\" y=\"3\" width=\"20\" height=\"14\" rx=\"2\" ry=\"2\"></rect><line x1=\"8\" y1=\"21\" x2=\"16\" y2=\"21\"></line><line x1=\"12\" y1=\"17\" x2=\"12\" y2=\"21\"></line><circle cx=\"12\" cy=\"10\" r=\"3\"></circle><path d=\"M7 7l2 2M17 7l-2 2M7 13l2-2M17 13l-2-2\"></path>", 5)])]))])], 8, _hoisted_5$4),
393
+ }, [(0, vue.renderSlot)(_ctx.$slots, "theme-icon", {}, () => [$setup.theme === "light" ? ((0, vue.openBlock)(), (0, vue.createElementBlock)("svg", _hoisted_6$4, [..._cache[12] || (_cache[12] = [(0, vue.createStaticVNode)("<circle cx=\"12\" cy=\"12\" r=\"5\"></circle><line x1=\"12\" y1=\"1\" x2=\"12\" y2=\"3\"></line><line x1=\"12\" y1=\"21\" x2=\"12\" y2=\"23\"></line><line x1=\"4.22\" y1=\"4.22\" x2=\"5.64\" y2=\"5.64\"></line><line x1=\"18.36\" y1=\"18.36\" x2=\"19.78\" y2=\"19.78\"></line><line x1=\"1\" y1=\"12\" x2=\"3\" y2=\"12\"></line><line x1=\"21\" y1=\"12\" x2=\"23\" y2=\"12\"></line><line x1=\"4.22\" y1=\"19.78\" x2=\"5.64\" y2=\"18.36\"></line><line x1=\"18.36\" y1=\"5.64\" x2=\"19.78\" y2=\"4.22\"></line>", 9)])])) : $setup.theme === "dark" ? ((0, vue.openBlock)(), (0, vue.createElementBlock)("svg", _hoisted_7$2, [..._cache[13] || (_cache[13] = [(0, vue.createElementVNode)("path", { d: "M21 12.79A9 9 0 1 1 11.21 3 7 7 0 0 0 21 12.79z" }, null, -1)])])) : ((0, vue.openBlock)(), (0, vue.createElementBlock)("svg", _hoisted_8$1, [..._cache[14] || (_cache[14] = [(0, vue.createStaticVNode)("<rect x=\"2\" y=\"3\" width=\"20\" height=\"14\" rx=\"2\" ry=\"2\"></rect><line x1=\"8\" y1=\"21\" x2=\"16\" y2=\"21\"></line><line x1=\"12\" y1=\"17\" x2=\"12\" y2=\"21\"></line><circle cx=\"12\" cy=\"10\" r=\"3\"></circle><path d=\"M7 7l2 2M17 7l-2 2M7 13l2-2M17 13l-2-2\"></path>", 5)])]))])], 8, _hoisted_5$4),
391
394
  $setup.displayMode !== "extension" ? ((0, vue.openBlock)(), (0, vue.createElementBlock)("button", {
392
395
  key: 0,
393
396
  class: "opencode-header-btn display-mode-btn",
@@ -395,7 +398,7 @@ function __vue_render__$8(_ctx, _cache, $props, $setup, $data, $options) {
395
398
  title: $setup.displayModeIconTitle,
396
399
  "aria-label": $setup.displayModeIconLabel,
397
400
  onClick: _cache[3] || (_cache[3] = (...args) => $setup.handleToggleDisplayMode && $setup.handleToggleDisplayMode(...args))
398
- }, [(0, vue.renderSlot)(_ctx.$slots, "display-mode-icon", {}, () => [$setup.displayMode === "bubble" ? ((0, vue.openBlock)(), (0, vue.createElementBlock)("svg", _hoisted_10$1, [..._cache[14] || (_cache[14] = [
401
+ }, [(0, vue.renderSlot)(_ctx.$slots, "display-mode-icon", {}, () => [$setup.displayMode === "bubble" ? ((0, vue.openBlock)(), (0, vue.createElementBlock)("svg", _hoisted_10$1, [..._cache[15] || (_cache[15] = [
399
402
  (0, vue.createElementVNode)("circle", {
400
403
  cx: "12",
401
404
  cy: "12",
@@ -419,7 +422,7 @@ function __vue_render__$8(_ctx, _cache, $props, $setup, $data, $options) {
419
422
  y2: "9",
420
423
  "stroke-linecap": "round"
421
424
  }, null, -1)
422
- ])])) : $setup.displayMode === "split" ? ((0, vue.openBlock)(), (0, vue.createElementBlock)("svg", _hoisted_11, [..._cache[15] || (_cache[15] = [(0, vue.createElementVNode)("rect", {
425
+ ])])) : $setup.displayMode === "split" ? ((0, vue.openBlock)(), (0, vue.createElementBlock)("svg", _hoisted_11, [..._cache[16] || (_cache[16] = [(0, vue.createElementVNode)("rect", {
423
426
  x: "3",
424
427
  y: "3",
425
428
  width: "18",
@@ -430,7 +433,7 @@ function __vue_render__$8(_ctx, _cache, $props, $setup, $data, $options) {
430
433
  y1: "3",
431
434
  x2: "12",
432
435
  y2: "21"
433
- }, null, -1)])])) : ((0, vue.openBlock)(), (0, vue.createElementBlock)("svg", _hoisted_12, [..._cache[16] || (_cache[16] = [
436
+ }, null, -1)])])) : ((0, vue.openBlock)(), (0, vue.createElementBlock)("svg", _hoisted_12, [..._cache[17] || (_cache[17] = [
434
437
  (0, vue.createElementVNode)("rect", {
435
438
  x: "3",
436
439
  y: "3",
@@ -468,7 +471,7 @@ function __vue_render__$8(_ctx, _cache, $props, $setup, $data, $options) {
468
471
  title: "刷新面板",
469
472
  "aria-label": "刷新面板",
470
473
  onClick: _cache[4] || (_cache[4] = (...args) => $setup.handleRefresh && $setup.handleRefresh(...args))
471
- }, [..._cache[17] || (_cache[17] = [(0, vue.createElementVNode)("svg", {
474
+ }, [..._cache[18] || (_cache[18] = [(0, vue.createElementVNode)("svg", {
472
475
  viewBox: "0 0 24 24",
473
476
  width: "16",
474
477
  height: "16",
@@ -484,7 +487,7 @@ function __vue_render__$8(_ctx, _cache, $props, $setup, $data, $options) {
484
487
  title: $setup.splitPositionIconTitle,
485
488
  "aria-label": $setup.splitPositionIconLabel,
486
489
  onClick: _cache[5] || (_cache[5] = (...args) => $setup.handleToggleSplitPosition && $setup.handleToggleSplitPosition(...args))
487
- }, [(0, vue.renderSlot)(_ctx.$slots, "split-position-icon", {}, () => [$setup.splitPosition === "right" ? ((0, vue.openBlock)(), (0, vue.createElementBlock)("svg", _hoisted_16, [..._cache[18] || (_cache[18] = [(0, vue.createElementVNode)("rect", {
490
+ }, [(0, vue.renderSlot)(_ctx.$slots, "split-position-icon", {}, () => [$setup.splitPosition === "right" ? ((0, vue.openBlock)(), (0, vue.createElementBlock)("svg", _hoisted_16, [..._cache[19] || (_cache[19] = [(0, vue.createElementVNode)("rect", {
488
491
  x: "3",
489
492
  y: "3",
490
493
  width: "18",
@@ -495,7 +498,7 @@ function __vue_render__$8(_ctx, _cache, $props, $setup, $data, $options) {
495
498
  y1: "3",
496
499
  x2: "15",
497
500
  y2: "21"
498
- }, null, -1)])])) : ((0, vue.openBlock)(), (0, vue.createElementBlock)("svg", _hoisted_17, [..._cache[19] || (_cache[19] = [(0, vue.createElementVNode)("rect", {
501
+ }, null, -1)])])) : ((0, vue.openBlock)(), (0, vue.createElementBlock)("svg", _hoisted_17, [..._cache[20] || (_cache[20] = [(0, vue.createElementVNode)("rect", {
499
502
  x: "3",
500
503
  y: "3",
501
504
  width: "18",
@@ -507,6 +510,24 @@ function __vue_render__$8(_ctx, _cache, $props, $setup, $data, $options) {
507
510
  x2: "9",
508
511
  y2: "21"
509
512
  }, null, -1)])]))])], 8, _hoisted_15)) : (0, vue.createCommentVNode)("v-if", true),
513
+ (0, vue.createElementVNode)("button", {
514
+ class: (0, vue.normalizeClass)(["opencode-header-btn review-panel", { active: $setup.reviewPanelVisible }]),
515
+ type: "button",
516
+ title: $setup.reviewPanelVisible ? "收起审查面板" : "展开审查面板",
517
+ "aria-label": $setup.reviewPanelVisible ? "收起审查面板" : "展开审查面板",
518
+ "aria-pressed": $setup.reviewPanelVisible,
519
+ onClick: _cache[6] || (_cache[6] = (...args) => $setup.handleToggleReviewPanel && $setup.handleToggleReviewPanel(...args))
520
+ }, [..._cache[21] || (_cache[21] = [(0, vue.createElementVNode)("svg", {
521
+ viewBox: "0 0 24 24",
522
+ width: "15",
523
+ height: "15",
524
+ fill: "none",
525
+ stroke: "currentColor",
526
+ "stroke-width": "2",
527
+ "stroke-linecap": "round",
528
+ "stroke-linejoin": "round",
529
+ "aria-hidden": "true"
530
+ }, [(0, vue.createElementVNode)("polyline", { points: "16 18 22 12 16 6" }), (0, vue.createElementVNode)("polyline", { points: "8 6 2 12 8 18" })], -1)])], 10, _hoisted_18),
510
531
  !$setup.isSplitMode ? ((0, vue.openBlock)(), (0, vue.createElementBlock)("button", {
511
532
  key: 2,
512
533
  class: "opencode-header-btn prompt-dock",
@@ -514,8 +535,8 @@ function __vue_render__$8(_ctx, _cache, $props, $setup, $data, $options) {
514
535
  title: $setup.promptDockVisible ? "隐藏对话框" : "显示对话框",
515
536
  "aria-label": $setup.promptDockVisible ? "隐藏对话框" : "显示对话框",
516
537
  "aria-pressed": $setup.promptDockVisible,
517
- onClick: _cache[6] || (_cache[6] = (...args) => $setup.handleTogglePromptDock && $setup.handleTogglePromptDock(...args))
518
- }, [(0, vue.renderSlot)(_ctx.$slots, "prompt-dock-icon", {}, () => [_cache[20] || (_cache[20] = (0, vue.createElementVNode)("svg", {
538
+ onClick: _cache[7] || (_cache[7] = (...args) => $setup.handleTogglePromptDock && $setup.handleTogglePromptDock(...args))
539
+ }, [(0, vue.renderSlot)(_ctx.$slots, "prompt-dock-icon", {}, () => [_cache[22] || (_cache[22] = (0, vue.createElementVNode)("svg", {
519
540
  viewBox: "0 0 24 24",
520
541
  width: "14",
521
542
  height: "14",
@@ -523,7 +544,7 @@ function __vue_render__$8(_ctx, _cache, $props, $setup, $data, $options) {
523
544
  stroke: "currentColor",
524
545
  "stroke-width": "2",
525
546
  "aria-hidden": "true"
526
- }, [(0, vue.createElementVNode)("path", { d: "M21 15a2 2 0 0 1-2 2H7l-4 4V5a2 2 0 0 1 2-2h14a2 2 0 0 1 2 2z" })], -1))])], 8, _hoisted_18)) : (0, vue.createCommentVNode)("v-if", true),
547
+ }, [(0, vue.createElementVNode)("path", { d: "M21 15a2 2 0 0 1-2 2H7l-4 4V5a2 2 0 0 1 2-2h14a2 2 0 0 1 2 2z" })], -1))])], 8, _hoisted_19)) : (0, vue.createCommentVNode)("v-if", true),
527
548
  !$setup.isSplitMode ? ((0, vue.openBlock)(), (0, vue.createElementBlock)("button", {
528
549
  key: 3,
529
550
  class: "opencode-header-btn minimize",
@@ -531,16 +552,16 @@ function __vue_render__$8(_ctx, _cache, $props, $setup, $data, $options) {
531
552
  title: $setup.minimized ? "展开" : "最小化",
532
553
  "aria-label": $setup.minimized ? "展开面板" : "最小化面板",
533
554
  "aria-pressed": $setup.minimized,
534
- onClick: _cache[7] || (_cache[7] = (...args) => $setup.handleToggleMinimize && $setup.handleToggleMinimize(...args))
535
- }, [(0, vue.renderSlot)(_ctx.$slots, "minimize-icon", {}, () => [$setup.minimized ? ((0, vue.openBlock)(), (0, vue.createElementBlock)("svg", _hoisted_20, [..._cache[21] || (_cache[21] = [(0, vue.createElementVNode)("path", { d: "M8 3v3a2 2 0 0 1-2 2H3m18 0h-3a2 2 0 0 1-2-2V3m0 18v-3a2 2 0 0 1 2-2h3M3 16h3a2 2 0 0 1 2 2v3" }, null, -1)])])) : ((0, vue.openBlock)(), (0, vue.createElementBlock)("svg", _hoisted_21, [..._cache[22] || (_cache[22] = [(0, vue.createElementVNode)("path", { d: "M8 3v3a2 2 0 0 1-2 2H3m18 0h-3a2 2 0 0 1-2-2V3m0 18v-3a2 2 0 0 1 2-2h3M3 16h3a2 2 0 0 1 2 2v3" }, null, -1)])]))])], 8, _hoisted_19)) : (0, vue.createCommentVNode)("v-if", true),
555
+ onClick: _cache[8] || (_cache[8] = (...args) => $setup.handleToggleMinimize && $setup.handleToggleMinimize(...args))
556
+ }, [(0, vue.renderSlot)(_ctx.$slots, "minimize-icon", {}, () => [$setup.minimized ? ((0, vue.openBlock)(), (0, vue.createElementBlock)("svg", _hoisted_21, [..._cache[23] || (_cache[23] = [(0, vue.createElementVNode)("path", { d: "M8 3v3a2 2 0 0 1-2 2H3m18 0h-3a2 2 0 0 1-2-2V3m0 18v-3a2 2 0 0 1 2-2h3M3 16h3a2 2 0 0 1 2 2v3" }, null, -1)])])) : ((0, vue.openBlock)(), (0, vue.createElementBlock)("svg", _hoisted_22, [..._cache[24] || (_cache[24] = [(0, vue.createElementVNode)("path", { d: "M8 3v3a2 2 0 0 1-2 2H3m18 0h-3a2 2 0 0 1-2-2V3m0 18v-3a2 2 0 0 1 2-2h3M3 16h3a2 2 0 0 1 2 2v3" }, null, -1)])]))])], 8, _hoisted_20)) : (0, vue.createCommentVNode)("v-if", true),
536
557
  !$setup.isSplitMode ? ((0, vue.openBlock)(), (0, vue.createElementBlock)("button", {
537
558
  key: 4,
538
559
  class: "opencode-header-btn close",
539
560
  type: "button",
540
561
  title: "关闭",
541
562
  "aria-label": "关闭面板",
542
- onClick: _cache[8] || (_cache[8] = (...args) => $setup.handleClose && $setup.handleClose(...args))
543
- }, [(0, vue.renderSlot)(_ctx.$slots, "close-icon", {}, () => [_cache[23] || (_cache[23] = (0, vue.createElementVNode)("svg", {
563
+ onClick: _cache[9] || (_cache[9] = (...args) => $setup.handleClose && $setup.handleClose(...args))
564
+ }, [(0, vue.renderSlot)(_ctx.$slots, "close-icon", {}, () => [_cache[25] || (_cache[25] = (0, vue.createElementVNode)("svg", {
544
565
  viewBox: "0 0 24 24",
545
566
  width: "14",
546
567
  height: "14",
@@ -1190,7 +1211,7 @@ var __vue_sfc__$3 = /* @__PURE__ */ (0, vue.defineComponent)({
1190
1211
  });
1191
1212
  var _hoisted_1$2 = { class: "opencode-hint-shortcut" };
1192
1213
  function __vue_render__$3(_ctx, _cache, $props, $setup, $data, $options) {
1193
- return (0, vue.openBlock)(), (0, vue.createElementBlock)("div", { class: (0, vue.normalizeClass)(["opencode-select-mode-hint", { visible: $setup.visible }]) }, [_cache[0] || (_cache[0] = (0, vue.createElementVNode)("span", null, "🎯 选择模式已开启 - 点击元素进行选择", -1)), (0, vue.createElementVNode)("span", _hoisted_1$2, (0, vue.toDisplayString)($setup.shortcutLabel), 1)], 2);
1214
+ return (0, vue.openBlock)(), (0, vue.createElementBlock)("div", { class: (0, vue.normalizeClass)(["opencode-select-mode-hint", { visible: $setup.visible }]) }, [_cache[0] || (_cache[0] = (0, vue.createStaticVNode)("<span class=\"opencode-hint-main\"><span class=\"opencode-hint-icon\" aria-hidden=\"true\"><svg viewBox=\"0 0 24 24\" width=\"18\" height=\"18\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2\" stroke-linecap=\"round\" stroke-linejoin=\"round\"><circle cx=\"12\" cy=\"12\" r=\"8\"></circle><circle cx=\"12\" cy=\"12\" r=\"2.5\" fill=\"currentColor\"></circle><line x1=\"12\" y1=\"2\" x2=\"12\" y2=\"5\"></line><line x1=\"12\" y1=\"19\" x2=\"12\" y2=\"22\"></line><line x1=\"2\" y1=\"12\" x2=\"5\" y2=\"12\"></line><line x1=\"19\" y1=\"12\" x2=\"22\" y2=\"12\"></line></svg></span><span class=\"opencode-hint-text\">选择模式已开启 · 点击元素进行选择</span></span>", 1)), (0, vue.createElementVNode)("span", _hoisted_1$2, (0, vue.toDisplayString)($setup.shortcutLabel), 1)], 2);
1194
1215
  }
1195
1216
  __vue_sfc__$3.render = __vue_render__$3;
1196
1217
  var SelectHint_vue_default = __vue_sfc__$3;
@@ -2319,6 +2340,7 @@ function usePersistState(options) {
2319
2340
  open: options.open.value,
2320
2341
  minimized: options.minimized.value,
2321
2342
  promptDockVisible: options.promptDockVisible.value,
2343
+ reviewPanelVisible: options.reviewPanelVisible.value,
2322
2344
  bubbleOffset: options.bubbleOffset.value,
2323
2345
  theme: options.theme.value,
2324
2346
  sessionListCollapsed: options.sessionListCollapsed.value,
@@ -2334,6 +2356,7 @@ function usePersistState(options) {
2334
2356
  options.open,
2335
2357
  options.minimized,
2336
2358
  options.promptDockVisible,
2359
+ options.reviewPanelVisible,
2337
2360
  options.bubbleOffset,
2338
2361
  options.theme,
2339
2362
  options.sessionListCollapsed
@@ -2704,6 +2727,7 @@ var __vue_sfc__ = /* @__PURE__ */ (0, vue.defineComponent)(__spreadProps(__sprea
2704
2727
  const localSplitPosition = (0, vue.ref)((_b = (_a = props.splitMode) == null ? void 0 : _a.position) != null ? _b : "right");
2705
2728
  const minimized = (0, vue.ref)(false);
2706
2729
  const promptDockVisible = (0, vue.ref)(true);
2730
+ const reviewPanelVisible = (0, vue.ref)(false);
2707
2731
  const isRestoring = (0, vue.ref)(true);
2708
2732
  const iframeLoaded = (0, vue.ref)(false);
2709
2733
  const splitPanelWidth = (0, vue.ref)(props.splitPanelWidth);
@@ -2711,6 +2735,7 @@ var __vue_sfc__ = /* @__PURE__ */ (0, vue.defineComponent)(__spreadProps(__sprea
2711
2735
  if (!iframeLoaded.value) return;
2712
2736
  sendMessageToIframe(_vite_plugin_opencode_assistant_shared.WIDGET_MSG.PROMPT_DOCK_VISIBILITY, { visible: promptDockVisible.value });
2713
2737
  sendMessageToIframe(_vite_plugin_opencode_assistant_shared.WIDGET_MSG.MINIMIZE_STATE, { minimized: minimized.value });
2738
+ sendMessageToIframe(_vite_plugin_opencode_assistant_shared.WIDGET_MSG.REVIEW_PANEL_TOGGLE, { visible: reviewPanelVisible.value });
2714
2739
  };
2715
2740
  const handleFrameLoaded = () => {
2716
2741
  emit("frame-loaded");
@@ -2830,6 +2855,7 @@ var __vue_sfc__ = /* @__PURE__ */ (0, vue.defineComponent)(__spreadProps(__sprea
2830
2855
  open: (0, vue.toRef)(props, "open"),
2831
2856
  minimized,
2832
2857
  promptDockVisible,
2858
+ reviewPanelVisible,
2833
2859
  bubbleOffset,
2834
2860
  theme: (0, vue.toRef)(props, "theme"),
2835
2861
  sessionListCollapsed: localSessionListCollapsed,
@@ -2862,6 +2888,7 @@ var __vue_sfc__ = /* @__PURE__ */ (0, vue.defineComponent)(__spreadProps(__sprea
2862
2888
  }
2863
2889
  if (state.promptDockVisible !== void 0) promptDockVisible.value = state.promptDockVisible;
2864
2890
  else if (minimized.value) promptDockVisible.value = false;
2891
+ if (state.reviewPanelVisible !== void 0) reviewPanelVisible.value = state.reviewPanelVisible;
2865
2892
  if (state.splitPanelWidth !== void 0 && state.splitPanelWidth !== props.splitPanelWidth) handleResize(state.splitPanelWidth);
2866
2893
  if (state.displayMode !== void 0 && state.displayMode !== props.displayMode) localDisplayMode.value = state.displayMode;
2867
2894
  if (state.splitPosition !== void 0) localSplitPosition.value = state.splitPosition;
@@ -2883,6 +2910,10 @@ var __vue_sfc__ = /* @__PURE__ */ (0, vue.defineComponent)(__spreadProps(__sprea
2883
2910
  promptDockVisible.value = !promptDockVisible.value;
2884
2911
  sendMessageToIframe(_vite_plugin_opencode_assistant_shared.WIDGET_MSG.PROMPT_DOCK_VISIBILITY, { visible: promptDockVisible.value });
2885
2912
  };
2913
+ const handleToggleReviewPanel = () => {
2914
+ reviewPanelVisible.value = !reviewPanelVisible.value;
2915
+ sendMessageToIframe(_vite_plugin_opencode_assistant_shared.WIDGET_MSG.REVIEW_PANEL_TOGGLE, { visible: reviewPanelVisible.value });
2916
+ };
2886
2917
  const handleRefresh = () => {
2887
2918
  window.location.reload();
2888
2919
  };
@@ -3017,6 +3048,7 @@ var __vue_sfc__ = /* @__PURE__ */ (0, vue.defineComponent)(__spreadProps(__sprea
3017
3048
  thinking: (0, vue.toRef)(props, "thinking"),
3018
3049
  minimized,
3019
3050
  promptDockVisible,
3051
+ reviewPanelVisible,
3020
3052
  bubbleOffset,
3021
3053
  mode: effectiveMode,
3022
3054
  displayMode: localDisplayMode,
@@ -3036,6 +3068,7 @@ var __vue_sfc__ = /* @__PURE__ */ (0, vue.defineComponent)(__spreadProps(__sprea
3036
3068
  handleClose,
3037
3069
  handleToggleMinimize,
3038
3070
  handleTogglePromptDock,
3071
+ handleToggleReviewPanel,
3039
3072
  handleToggleSessionList,
3040
3073
  handleToggleTheme,
3041
3074
  handleToggleDisplayMode,
@@ -3091,6 +3124,7 @@ var __vue_sfc__ = /* @__PURE__ */ (0, vue.defineComponent)(__spreadProps(__sprea
3091
3124
  localSplitPosition,
3092
3125
  minimized,
3093
3126
  promptDockVisible,
3127
+ reviewPanelVisible,
3094
3128
  isRestoring,
3095
3129
  iframeLoaded,
3096
3130
  splitPanelWidth,
@@ -3135,6 +3169,7 @@ var __vue_sfc__ = /* @__PURE__ */ (0, vue.defineComponent)(__spreadProps(__sprea
3135
3169
  handleTogglePosition,
3136
3170
  handleToggleMinimize,
3137
3171
  handleTogglePromptDock,
3172
+ handleToggleReviewPanel,
3138
3173
  handleRefresh,
3139
3174
  windowWidth,
3140
3175
  windowHeight,
@@ -3304,7 +3339,7 @@ __vue_sfc__.render = __vue_render__;
3304
3339
  var open_code_widget_default = __vue_sfc__;
3305
3340
  //#endregion
3306
3341
  //#region es/index.mjs
3307
- var version = "1.0.91";
3342
+ var version = "1.0.93";
3308
3343
  function install(app, options) {
3309
3344
  [open_code_widget_default].forEach((item) => {
3310
3345
  if (item.install) app.use(item, options);