codexmate 0.1.34 → 0.1.35

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 (47) hide show
  1. package/README.md +15 -1
  2. package/README.vi.md +15 -1
  3. package/README.zh.md +15 -1
  4. package/cli/analytics-export-args.js +7 -0
  5. package/cli/session-usage.js +4 -1
  6. package/cli.js +29 -5
  7. package/lib/data/model-prices.json +1868 -0
  8. package/lib/session-context-health.js +5 -1
  9. package/lib/session-evidence-collections.js +85 -0
  10. package/lib/session-features.js +15 -0
  11. package/lib/session-project-git.js +65 -0
  12. package/lib/session-projects.js +12 -1
  13. package/lib/session-stories.js +67 -0
  14. package/lib/session-usage-ledger.js +77 -0
  15. package/lib/session-usage-pricing.js +42 -0
  16. package/lib/session-usage-report.js +101 -0
  17. package/package.json +4 -1
  18. package/plugins/prompt-templates/computed.mjs +9 -0
  19. package/web-ui/app.js +10 -0
  20. package/web-ui/logic.session-artifacts.mjs +39 -0
  21. package/web-ui/modules/app.methods.agents.mjs +3 -2
  22. package/web-ui/modules/app.methods.session-browser.mjs +35 -0
  23. package/web-ui/modules/app.methods.system-prompt.mjs +16 -7
  24. package/web-ui/modules/app.methods.web-ui-preferences.mjs +5 -0
  25. package/web-ui/modules/i18n/locales/en.mjs +116 -1
  26. package/web-ui/modules/i18n/locales/ja.mjs +116 -1
  27. package/web-ui/modules/i18n/locales/vi.mjs +116 -1
  28. package/web-ui/modules/i18n/locales/zh-tw.mjs +116 -1
  29. package/web-ui/modules/i18n/locales/zh.mjs +116 -1
  30. package/web-ui/modules/session-collections.mjs +65 -0
  31. package/web-ui/modules/session-evidence.mjs +81 -0
  32. package/web-ui/modules/session-features.mjs +15 -1
  33. package/web-ui/modules/session-git.mjs +39 -0
  34. package/web-ui/modules/session-stories.mjs +64 -0
  35. package/web-ui/modules/usage-pricing.mjs +30 -0
  36. package/web-ui/partials/index/layout-footer.html +1 -1
  37. package/web-ui/partials/index/panel-sessions.html +20 -20
  38. package/web-ui/partials/index/panel-usage.html +2 -0
  39. package/web-ui/partials/index/session-features.html +82 -2
  40. package/web-ui/partials/index/thread-handoff.html +73 -62
  41. package/web-ui/partials/index/usage-records.html +41 -0
  42. package/web-ui/res/web-ui-render.precompiled.js +772 -125
  43. package/web-ui/styles/session-features.css +63 -0
  44. package/web-ui/styles/sessions-list.css +74 -0
  45. package/web-ui/styles/sessions-preview.css +106 -68
  46. package/web-ui/styles/sessions-usage.css +8 -0
  47. package/web-ui/styles/theme-violet.css +9 -3
@@ -4885,7 +4885,8 @@ return function render(_ctx, _cache) {
4885
4885
  class: "feature-status",
4886
4886
  "data-status": _ctx.indexReport.job.status
4887
4887
  }, _toDisplayString(_ctx.t('features.status.' + _ctx.indexReport.job.status)), 9 /* TEXT, PROPS */, ["data-status"]),
4888
- _createElementVNode("span", null, _toDisplayString(_ctx.t('features.indexStatus', { count: _ctx.indexReport.indexed, processed: _ctx.indexReport.job.processed, total: _ctx.indexReport.job.candidates })), 1 /* TEXT */)
4888
+ _createElementVNode("span", null, _toDisplayString(_ctx.t('features.indexStatus', { count: _ctx.indexReport.indexed, processed: _ctx.indexReport.job.processed, total: _ctx.indexReport.job.candidates })), 1 /* TEXT */),
4889
+ _createElementVNode("span", { class: "feature-index-time" }, _toDisplayString(_ctx.t('features.indexCatalogTime', { time: _ctx.indexCatalogTime })), 1 /* TEXT */)
4889
4890
  ]))
4890
4891
  : _createCommentVNode("v-if", true),
4891
4892
  _createElementVNode("form", {
@@ -4904,9 +4905,21 @@ return function render(_ctx, _cache) {
4904
4905
  disabled: _ctx.featureBusy || !_ctx.indexQuery.trim() || !_ctx.indexReport?.updatedAt
4905
4906
  }, _toDisplayString(_ctx.t('features.search')), 9 /* TEXT, PROPS */, ["disabled"])
4906
4907
  ], 40 /* PROPS, NEED_HYDRATION */, ["onSubmit"]),
4907
- _createElementVNode("details", { class: "feature-disclosure" }, [
4908
+ _createElementVNode("details", { class: "feature-disclosure feature-index-scope" }, [
4908
4909
  _createElementVNode("summary", null, _toDisplayString(_ctx.t('features.searchScope')), 1 /* TEXT */),
4909
- _createElementVNode("p", { class: "feature-hint" }, _toDisplayString(_ctx.t('features.indexScope')), 1 /* TEXT */)
4910
+ _createElementVNode("p", { class: "feature-hint" }, _toDisplayString(_ctx.t('features.indexScope')), 1 /* TEXT */),
4911
+ (_openBlock(true), _createElementBlock(_Fragment, null, _renderList(_ctx.indexSourceCoverage, (entry) => {
4912
+ return (_openBlock(), _createElementBlock("p", {
4913
+ key: entry.source,
4914
+ class: "feature-hint feature-index-coverage"
4915
+ }, _toDisplayString(_ctx.t('features.indexSourceCoverage', { source: _ctx.t('sessions.source.' + entry.source), count: entry.candidates ?? _ctx.t('features.indexUnknown'), limit: entry.discoveryLimit ?? _ctx.t('features.indexUnknown') })), 1 /* TEXT */))
4916
+ }), 128 /* KEYED_FRAGMENT */)),
4917
+ (!_ctx.indexSourceCoverage.length)
4918
+ ? (_openBlock(), _createElementBlock("p", {
4919
+ key: 0,
4920
+ class: "feature-hint feature-index-unknown"
4921
+ }, _toDisplayString(_ctx.t('features.indexCoverageUnknown')), 1 /* TEXT */))
4922
+ : _createCommentVNode("v-if", true)
4910
4923
  ]),
4911
4924
  (_ctx.indexReport?.failures.length)
4912
4925
  ? (_openBlock(), _createElementBlock("p", {
@@ -4956,7 +4969,15 @@ return function render(_ctx, _cache) {
4956
4969
  type: "button",
4957
4970
  class: "btn-mini",
4958
4971
  onClick: $event => (_ctx.openIndexedMessage(result))
4959
- }, _toDisplayString(_ctx.t('features.source')), 9 /* TEXT, PROPS */, ["onClick"])
4972
+ }, _toDisplayString(_ctx.t('features.source')), 9 /* TEXT, PROPS */, ["onClick"]),
4973
+ _createElementVNode("label", { class: "evidence-select" }, [
4974
+ _createElementVNode("input", {
4975
+ type: "checkbox",
4976
+ checked: _ctx.isEvidenceSelected(result),
4977
+ onChange: $event => (_ctx.toggleEvidence(result))
4978
+ }, null, 40 /* PROPS, NEED_HYDRATION */, ["checked", "onChange"]),
4979
+ _createTextVNode(_toDisplayString(_ctx.t('evidence.select')), 1 /* TEXT */)
4980
+ ])
4960
4981
  ]),
4961
4982
  _createElementVNode("details", { class: "feature-disclosure" }, [
4962
4983
  _createElementVNode("summary", null, _toDisplayString(_ctx.t('features.context')), 1 /* TEXT */),
@@ -4969,9 +4990,200 @@ return function render(_ctx, _cache) {
4969
4990
  : _createCommentVNode("v-if", true)
4970
4991
  ]))
4971
4992
  : _createCommentVNode("v-if", true),
4993
+ _createElementVNode("details", {
4994
+ class: "feature-disclosure evidence-collections",
4995
+ open: _ctx.collectionsOpen,
4996
+ onToggle: $event => (_ctx.toggleCollections($event))
4997
+ }, [
4998
+ _createElementVNode("summary", null, _toDisplayString(_ctx.t('collections.title')), 1 /* TEXT */),
4999
+ _createElementVNode("p", { class: "feature-hint" }, _toDisplayString(_ctx.t('collections.scope')), 1 /* TEXT */),
5000
+ (_ctx.collectionError)
5001
+ ? (_openBlock(), _createElementBlock("p", {
5002
+ key: 0,
5003
+ class: "form-error",
5004
+ role: "alert"
5005
+ }, _toDisplayString(_ctx.collectionError), 1 /* TEXT */))
5006
+ : _createCommentVNode("v-if", true),
5007
+ (_ctx.collectionBusy)
5008
+ ? (_openBlock(), _createElementBlock("p", {
5009
+ key: 1,
5010
+ role: "status"
5011
+ }, _toDisplayString(_ctx.t('features.loading')), 1 /* TEXT */))
5012
+ : _createCommentVNode("v-if", true),
5013
+ _createElementVNode("ol", { class: "collection-list" }, [
5014
+ (_openBlock(true), _createElementBlock(_Fragment, null, _renderList(_ctx.collections, (item) => {
5015
+ return (_openBlock(), _createElementBlock("li", {
5016
+ key: item.id
5017
+ }, [
5018
+ _createElementVNode("button", {
5019
+ type: "button",
5020
+ class: "btn-mini",
5021
+ onClick: $event => (_ctx.openEvidenceCollection(item)),
5022
+ disabled: _ctx.collectionBusy || _ctx.evidenceBusy,
5023
+ "aria-pressed": _ctx.collectionId === item.id
5024
+ }, _toDisplayString(item.name), 9 /* TEXT, PROPS */, ["onClick", "disabled", "aria-pressed"]),
5025
+ _createElementVNode("span", { class: "feature-count" }, _toDisplayString(item.references.length) + "/100", 1 /* TEXT */),
5026
+ _createElementVNode("button", {
5027
+ type: "button",
5028
+ class: "btn-mini feature-quiet",
5029
+ onClick: $event => (_ctx.removeEvidenceCollection(item)),
5030
+ disabled: _ctx.collectionBusy
5031
+ }, _toDisplayString(_ctx.t('collections.remove')), 9 /* TEXT, PROPS */, ["onClick", "disabled"])
5032
+ ]))
5033
+ }), 128 /* KEYED_FRAGMENT */))
5034
+ ]),
5035
+ (!_ctx.collectionBusy && !_ctx.collections.length)
5036
+ ? (_openBlock(), _createElementBlock("p", {
5037
+ key: 2,
5038
+ class: "feature-hint"
5039
+ }, _toDisplayString(_ctx.t('collections.empty')), 1 /* TEXT */))
5040
+ : _createCommentVNode("v-if", true),
5041
+ (_ctx.evidenceSelections.length)
5042
+ ? (_openBlock(), _createElementBlock("form", {
5043
+ key: 3,
5044
+ class: "feature-editor collection-editor",
5045
+ onSubmit: _withModifiers($event => (_ctx.saveEvidenceCollection(false)), ["prevent"])
5046
+ }, [
5047
+ _createElementVNode("label", null, [
5048
+ _createTextVNode(_toDisplayString(_ctx.t('collections.name')), 1 /* TEXT */),
5049
+ _withDirectives(_createElementVNode("input", {
5050
+ "onUpdate:modelValue": $event => ((_ctx.collectionName) = $event),
5051
+ maxlength: "160",
5052
+ required: ""
5053
+ }, null, 8 /* PROPS */, ["onUpdate:modelValue"]), [
5054
+ [_vModelText, _ctx.collectionName]
5055
+ ])
5056
+ ]),
5057
+ _createElementVNode("div", { class: "feature-actions" }, [
5058
+ _createElementVNode("button", {
5059
+ class: "btn-mini",
5060
+ disabled: _ctx.collectionBusy || _ctx.evidenceBusy || !_ctx.collectionName.trim()
5061
+ }, _toDisplayString(_ctx.t('collections.save')), 9 /* TEXT, PROPS */, ["disabled"]),
5062
+ (_ctx.collectionId)
5063
+ ? (_openBlock(), _createElementBlock("button", {
5064
+ key: 0,
5065
+ type: "button",
5066
+ class: "btn-mini feature-quiet",
5067
+ onClick: $event => (_ctx.saveEvidenceCollection(true)),
5068
+ disabled: _ctx.collectionBusy || _ctx.evidenceBusy || !_ctx.collectionName.trim()
5069
+ }, _toDisplayString(_ctx.t('collections.saveAs')), 9 /* TEXT, PROPS */, ["onClick", "disabled"]))
5070
+ : _createCommentVNode("v-if", true)
5071
+ ])
5072
+ ], 40 /* PROPS, NEED_HYDRATION */, ["onSubmit"]))
5073
+ : _createCommentVNode("v-if", true),
5074
+ _createElementVNode("button", {
5075
+ type: "button",
5076
+ class: "btn-mini feature-quiet",
5077
+ onClick: _ctx.loadEvidenceCollections,
5078
+ disabled: _ctx.collectionBusy
5079
+ }, _toDisplayString(_ctx.t('collections.refresh')), 9 /* TEXT, PROPS */, ["onClick", "disabled"])
5080
+ ], 40 /* PROPS, NEED_HYDRATION */, ["open", "onToggle"]),
5081
+ (_ctx.evidenceSelections.length)
5082
+ ? (_openBlock(), _createElementBlock("section", {
5083
+ key: 2,
5084
+ class: "evidence-basket",
5085
+ "aria-label": _ctx.t('evidence.title')
5086
+ }, [
5087
+ _createElementVNode("div", { class: "feature-section-heading" }, [
5088
+ _createElementVNode("h3", null, _toDisplayString(_ctx.t('evidence.title')), 1 /* TEXT */),
5089
+ _createElementVNode("span", { class: "feature-count" }, _toDisplayString(_ctx.evidenceSelections.length) + "/100", 1 /* TEXT */)
5090
+ ]),
5091
+ _createElementVNode("p", { class: "feature-hint" }, _toDisplayString(_ctx.t('evidence.memory')), 1 /* TEXT */),
5092
+ _createElementVNode("ol", { class: "evidence-list" }, [
5093
+ (_openBlock(true), _createElementBlock(_Fragment, null, _renderList(_ctx.evidenceSelections, (item) => {
5094
+ return (_openBlock(), _createElementBlock("li", {
5095
+ key: _ctx.evidenceKey(item)
5096
+ }, [
5097
+ _createElementVNode("span", null, [
5098
+ _createElementVNode("strong", null, _toDisplayString(item.session.title || item.session.sessionId), 1 /* TEXT */),
5099
+ _createElementVNode("small", { class: "feature-meta" }, _toDisplayString(item.session.source) + " · " + _toDisplayString(item.nodeId), 1 /* TEXT */),
5100
+ (item.state)
5101
+ ? (_openBlock(), _createElementBlock("small", {
5102
+ key: 0,
5103
+ class: "collection-source-state",
5104
+ "data-state": item.state
5105
+ }, _toDisplayString(_ctx.t('collections.state.' + item.state)), 9 /* TEXT, PROPS */, ["data-state"]))
5106
+ : _createCommentVNode("v-if", true)
5107
+ ]),
5108
+ _createElementVNode("button", {
5109
+ type: "button",
5110
+ class: "btn-mini feature-quiet",
5111
+ onClick: $event => (_ctx.openIndexedMessage(item))
5112
+ }, _toDisplayString(_ctx.t('features.source')), 9 /* TEXT, PROPS */, ["onClick"]),
5113
+ _createElementVNode("button", {
5114
+ type: "button",
5115
+ class: "btn-mini",
5116
+ onClick: $event => (_ctx.toggleEvidence(item))
5117
+ }, _toDisplayString(_ctx.t('evidence.remove')), 9 /* TEXT, PROPS */, ["onClick"])
5118
+ ]))
5119
+ }), 128 /* KEYED_FRAGMENT */))
5120
+ ]),
5121
+ _createElementVNode("form", {
5122
+ class: "feature-actions feature-search-form evidence-generator",
5123
+ onSubmit: _withModifiers(_ctx.generateEvidencePack, ["prevent"])
5124
+ }, [
5125
+ _withDirectives(_createElementVNode("input", {
5126
+ "onUpdate:modelValue": $event => ((_ctx.evidenceGoal) = $event),
5127
+ "aria-label": _ctx.t('evidence.goal'),
5128
+ placeholder: _ctx.t('evidence.goal')
5129
+ }, null, 8 /* PROPS */, ["onUpdate:modelValue", "aria-label", "placeholder"]), [
5130
+ [_vModelText, _ctx.evidenceGoal]
5131
+ ]),
5132
+ _withDirectives(_createElementVNode("select", {
5133
+ "onUpdate:modelValue": $event => ((_ctx.evidenceFormat) = $event),
5134
+ "aria-label": _ctx.t('artifacts.format')
5135
+ }, [
5136
+ _createElementVNode("option", { value: "evidence" }, _toDisplayString(_ctx.t('evidence.title')), 1 /* TEXT */),
5137
+ _createElementVNode("option", { value: "receipt" }, _toDisplayString(_ctx.t('artifacts.receipt')), 1 /* TEXT */),
5138
+ _createElementVNode("option", { value: "relay" }, _toDisplayString(_ctx.t('artifacts.relay')), 1 /* TEXT */)
5139
+ ], 8 /* PROPS */, ["onUpdate:modelValue", "aria-label"]), [
5140
+ [_vModelSelect, _ctx.evidenceFormat]
5141
+ ]),
5142
+ (_ctx.evidenceFormat !== 'evidence')
5143
+ ? _withDirectives((_openBlock(), _createElementBlock("textarea", {
5144
+ key: 0,
5145
+ "onUpdate:modelValue": $event => ((_ctx.evidenceNote) = $event),
5146
+ class: "evidence-generator-note",
5147
+ rows: "3",
5148
+ maxlength: "4000",
5149
+ "aria-label": _ctx.t('artifacts.note'),
5150
+ placeholder: _ctx.t('artifacts.notePlaceholder')
5151
+ }, null, 8 /* PROPS */, ["onUpdate:modelValue", "aria-label", "placeholder"])), [
5152
+ [_vModelText, _ctx.evidenceNote]
5153
+ ])
5154
+ : _createCommentVNode("v-if", true),
5155
+ _createElementVNode("button", {
5156
+ class: "btn-mini feature-primary",
5157
+ disabled: _ctx.evidenceBusy
5158
+ }, _toDisplayString(_ctx.evidenceBusy ? _ctx.t('features.loading') : _ctx.evidenceFormat === 'evidence' ? _ctx.t('evidence.generate') : _ctx.t('artifacts.generate.' + _ctx.evidenceFormat)), 9 /* TEXT, PROPS */, ["disabled"])
5159
+ ], 40 /* PROPS, NEED_HYDRATION */, ["onSubmit"]),
5160
+ (_ctx.evidenceError)
5161
+ ? (_openBlock(), _createElementBlock("p", {
5162
+ key: 0,
5163
+ class: "form-error",
5164
+ role: "alert"
5165
+ }, _toDisplayString(_ctx.evidenceError), 1 /* TEXT */))
5166
+ : _createCommentVNode("v-if", true),
5167
+ (_ctx.evidencePack)
5168
+ ? (_openBlock(), _createElementBlock("details", {
5169
+ key: 1,
5170
+ class: "feature-disclosure evidence-preview",
5171
+ open: ""
5172
+ }, [
5173
+ _createElementVNode("summary", null, _toDisplayString(_ctx.t('evidence.preview', { count: _ctx.evidencePack.length })), 1 /* TEXT */),
5174
+ _createElementVNode("pre", null, _toDisplayString(_ctx.evidencePack), 1 /* TEXT */),
5175
+ _createElementVNode("button", {
5176
+ type: "button",
5177
+ class: "btn-mini",
5178
+ onClick: _ctx.downloadEvidencePack
5179
+ }, _toDisplayString(_ctx.t('evidence.download')), 9 /* TEXT, PROPS */, ["onClick"])
5180
+ ]))
5181
+ : _createCommentVNode("v-if", true)
5182
+ ], 8 /* PROPS */, ["aria-label"]))
5183
+ : _createCommentVNode("v-if", true),
4972
5184
  (_ctx.featureView === 'projects')
4973
5185
  ? (_openBlock(), _createElementBlock("div", {
4974
- key: 2,
5186
+ key: 3,
4975
5187
  class: "feature-content"
4976
5188
  }, [
4977
5189
  _createElementVNode("div", { class: "feature-section-heading" }, [
@@ -5037,6 +5249,191 @@ return function render(_ctx, _cache) {
5037
5249
  class: "feature-hint"
5038
5250
  }, _toDisplayString(_ctx.t('features.partial')), 1 /* TEXT */))
5039
5251
  : _createCommentVNode("v-if", true),
5252
+ (_ctx.projectSelected)
5253
+ ? (_openBlock(), _createElementBlock("details", {
5254
+ key: 1,
5255
+ class: "feature-disclosure project-git",
5256
+ onToggle: $event => (_ctx.toggleProjectGit($event))
5257
+ }, [
5258
+ _createElementVNode("summary", null, _toDisplayString(_ctx.t('git.title')), 1 /* TEXT */),
5259
+ _createElementVNode("p", { class: "feature-hint" }, _toDisplayString(_ctx.t('git.scope')), 1 /* TEXT */),
5260
+ (_ctx.projectGitError)
5261
+ ? (_openBlock(), _createElementBlock("p", {
5262
+ key: 0,
5263
+ class: "form-error",
5264
+ role: "alert"
5265
+ }, _toDisplayString(_ctx.projectGitError), 1 /* TEXT */))
5266
+ : _createCommentVNode("v-if", true),
5267
+ (_ctx.projectGitBusy)
5268
+ ? (_openBlock(), _createElementBlock("p", {
5269
+ key: 1,
5270
+ role: "status"
5271
+ }, _toDisplayString(_ctx.t('features.loading')), 1 /* TEXT */))
5272
+ : _createCommentVNode("v-if", true),
5273
+ (_ctx.projectGit)
5274
+ ? (_openBlock(), _createElementBlock(_Fragment, { key: 2 }, [
5275
+ _createElementVNode("p", { class: "feature-meta" }, _toDisplayString(_ctx.t('git.status.' + _ctx.projectGit.status)) + " · " + _toDisplayString(_ctx.t('features.readAt', { time: _ctx.projectGit.readAt })), 1 /* TEXT */),
5276
+ (_ctx.projectGit.root)
5277
+ ? (_openBlock(), _createElementBlock(_Fragment, { key: 0 }, [
5278
+ _createElementVNode("p", { class: "feature-path" }, _toDisplayString(_ctx.projectGit.root), 1 /* TEXT */),
5279
+ _createElementVNode("p", { class: "feature-meta" }, [
5280
+ _createTextVNode(_toDisplayString(_ctx.projectGit.branch || _ctx.t('git.detached')) + " · ", 1 /* TEXT */),
5281
+ _createElementVNode("code", null, _toDisplayString(_ctx.projectGit.head || _ctx.t('git.noHead')), 1 /* TEXT */),
5282
+ _createTextVNode(" · " + _toDisplayString(_ctx.t('git.changes', { count: _ctx.projectGit.changedFiles })), 1 /* TEXT */)
5283
+ ]),
5284
+ _createElementVNode("ul", { class: "git-change-list" }, [
5285
+ (_openBlock(true), _createElementBlock(_Fragment, null, _renderList(_ctx.projectGit.changes, (change) => {
5286
+ return (_openBlock(), _createElementBlock("li", {
5287
+ key: change.path
5288
+ }, [
5289
+ _createElementVNode("code", null, _toDisplayString(change.status), 1 /* TEXT */),
5290
+ _createTextVNode(" " + _toDisplayString(change.path), 1 /* TEXT */)
5291
+ ]))
5292
+ }), 128 /* KEYED_FRAGMENT */))
5293
+ ]),
5294
+ (_ctx.projectGit.changesTruncated || _ctx.projectGit.commitsTruncated)
5295
+ ? (_openBlock(), _createElementBlock("p", {
5296
+ key: 0,
5297
+ class: "feature-hint"
5298
+ }, _toDisplayString(_ctx.t('git.truncated')), 1 /* TEXT */))
5299
+ : _createCommentVNode("v-if", true),
5300
+ _createElementVNode("ol", { class: "git-commit-list" }, [
5301
+ (_openBlock(true), _createElementBlock(_Fragment, null, _renderList(_ctx.projectGit.commits, (commit) => {
5302
+ return (_openBlock(), _createElementBlock("li", {
5303
+ key: commit.sha
5304
+ }, [
5305
+ _createElementVNode("button", {
5306
+ type: "button",
5307
+ class: "btn-mini",
5308
+ onClick: $event => (_ctx.loadProjectGitCommit(commit.sha)),
5309
+ disabled: _ctx.projectGitBusy
5310
+ }, [
5311
+ _createElementVNode("code", null, _toDisplayString(commit.sha.slice(0, 8)), 1 /* TEXT */),
5312
+ _createTextVNode(" " + _toDisplayString(commit.subject), 1 /* TEXT */)
5313
+ ], 8 /* PROPS */, ["onClick", "disabled"]),
5314
+ _createElementVNode("small", { class: "feature-meta" }, _toDisplayString(commit.timestamp), 1 /* TEXT */),
5315
+ _createElementVNode("div", { class: "feature-link-list" }, [
5316
+ (_openBlock(true), _createElementBlock(_Fragment, null, _renderList(commit.candidates, (session) => {
5317
+ return (_openBlock(), _createElementBlock("button", {
5318
+ key: session.source + session.sessionId,
5319
+ type: "button",
5320
+ onClick: $event => (_ctx.selectSession(session))
5321
+ }, _toDisplayString(_ctx.t('git.candidate')) + ": " + _toDisplayString(session.source) + " · " + _toDisplayString(session.title || session.sessionId), 9 /* TEXT, PROPS */, ["onClick"]))
5322
+ }), 128 /* KEYED_FRAGMENT */))
5323
+ ])
5324
+ ]))
5325
+ }), 128 /* KEYED_FRAGMENT */))
5326
+ ]),
5327
+ (_ctx.projectGitCommit)
5328
+ ? (_openBlock(), _createElementBlock("pre", {
5329
+ key: 1,
5330
+ class: "feature-code git-commit-stat"
5331
+ }, _toDisplayString(_ctx.projectGitCommit.sha) + "\n" + _toDisplayString(_ctx.projectGitCommit.stat), 1 /* TEXT */))
5332
+ : _createCommentVNode("v-if", true),
5333
+ (_ctx.projectGitCommit)
5334
+ ? (_openBlock(), _createElementBlock("section", {
5335
+ key: 2,
5336
+ class: "project-stories",
5337
+ "aria-label": _ctx.t('stories.title')
5338
+ }, [
5339
+ _createElementVNode("h4", null, _toDisplayString(_ctx.t('stories.title')), 1 /* TEXT */),
5340
+ _createElementVNode("p", { class: "feature-hint" }, _toDisplayString(_ctx.t('stories.scope')), 1 /* TEXT */),
5341
+ (_ctx.storyError)
5342
+ ? (_openBlock(), _createElementBlock("p", {
5343
+ key: 0,
5344
+ class: "form-error",
5345
+ role: "alert"
5346
+ }, _toDisplayString(_ctx.storyError), 1 /* TEXT */))
5347
+ : _createCommentVNode("v-if", true),
5348
+ (_ctx.storyBusy)
5349
+ ? (_openBlock(), _createElementBlock("p", {
5350
+ key: 1,
5351
+ role: "status"
5352
+ }, _toDisplayString(_ctx.t('features.loading')), 1 /* TEXT */))
5353
+ : _createCommentVNode("v-if", true),
5354
+ (_openBlock(true), _createElementBlock(_Fragment, null, _renderList(_ctx.commitStories, (item) => {
5355
+ return (_openBlock(), _createElementBlock("article", {
5356
+ key: item.id,
5357
+ class: "story-record"
5358
+ }, [
5359
+ _createElementVNode("p", { class: "feature-meta" }, _toDisplayString(_ctx.t('stories.linked')) + " · " + _toDisplayString(item.session.source), 1 /* TEXT */),
5360
+ (item.available)
5361
+ ? (_openBlock(), _createElementBlock("button", {
5362
+ key: 0,
5363
+ type: "button",
5364
+ class: "btn-mini",
5365
+ onClick: $event => (_ctx.selectSession(item.session))
5366
+ }, _toDisplayString(item.session.title || item.session.sessionId), 9 /* TEXT, PROPS */, ["onClick"]))
5367
+ : (_openBlock(), _createElementBlock("p", {
5368
+ key: 1,
5369
+ class: "feature-hint"
5370
+ }, _toDisplayString(item.session.title || item.session.sessionId) + " · " + _toDisplayString(_ctx.t('stories.unavailable')), 1 /* TEXT */)),
5371
+ _createElementVNode("p", { class: "feature-note" }, _toDisplayString(item.note), 1 /* TEXT */),
5372
+ _createElementVNode("button", {
5373
+ type: "button",
5374
+ class: "btn-mini feature-quiet",
5375
+ onClick: $event => (_ctx.removeProjectStory(item)),
5376
+ disabled: _ctx.storyBusy
5377
+ }, _toDisplayString(_ctx.t('stories.remove')), 9 /* TEXT, PROPS */, ["onClick", "disabled"])
5378
+ ]))
5379
+ }), 128 /* KEYED_FRAGMENT */)),
5380
+ _createElementVNode("form", {
5381
+ class: "feature-editor story-editor",
5382
+ onSubmit: _withModifiers(_ctx.saveProjectStory, ["prevent"])
5383
+ }, [
5384
+ _createElementVNode("label", null, [
5385
+ _createTextVNode(_toDisplayString(_ctx.t('stories.session')), 1 /* TEXT */),
5386
+ _withDirectives(_createElementVNode("select", {
5387
+ "onUpdate:modelValue": $event => ((_ctx.storySession) = $event),
5388
+ disabled: _ctx.storyBusy
5389
+ }, [
5390
+ _createElementVNode("option", { value: "" }, _toDisplayString(_ctx.t('stories.choose')), 1 /* TEXT */),
5391
+ (_openBlock(true), _createElementBlock(_Fragment, null, _renderList(_ctx.storySessions, (session) => {
5392
+ return (_openBlock(), _createElementBlock("option", {
5393
+ key: _ctx.storySessionKey(session),
5394
+ value: _ctx.storySessionKey(session)
5395
+ }, _toDisplayString(session.source) + " · " + _toDisplayString(session.title || session.sessionId), 9 /* TEXT, PROPS */, ["value"]))
5396
+ }), 128 /* KEYED_FRAGMENT */))
5397
+ ], 8 /* PROPS */, ["onUpdate:modelValue", "disabled"]), [
5398
+ [_vModelSelect, _ctx.storySession]
5399
+ ])
5400
+ ]),
5401
+ _createElementVNode("label", null, [
5402
+ _createTextVNode(_toDisplayString(_ctx.t('stories.note')), 1 /* TEXT */),
5403
+ _withDirectives(_createElementVNode("textarea", {
5404
+ "onUpdate:modelValue": $event => ((_ctx.storyNote) = $event),
5405
+ maxlength: "4000"
5406
+ }, null, 8 /* PROPS */, ["onUpdate:modelValue"]), [
5407
+ [_vModelText, _ctx.storyNote]
5408
+ ])
5409
+ ]),
5410
+ _createElementVNode("div", { class: "feature-actions" }, [
5411
+ _createElementVNode("button", {
5412
+ class: "btn-mini",
5413
+ disabled: _ctx.storyBusy || !_ctx.storySession
5414
+ }, _toDisplayString(_ctx.t('stories.save')), 9 /* TEXT, PROPS */, ["disabled"]),
5415
+ _createElementVNode("button", {
5416
+ type: "button",
5417
+ class: "btn-mini feature-quiet",
5418
+ onClick: _ctx.loadProjectStories,
5419
+ disabled: _ctx.storyBusy
5420
+ }, _toDisplayString(_ctx.t('stories.refresh')), 9 /* TEXT, PROPS */, ["onClick", "disabled"])
5421
+ ])
5422
+ ], 40 /* PROPS, NEED_HYDRATION */, ["onSubmit"])
5423
+ ], 8 /* PROPS */, ["aria-label"]))
5424
+ : _createCommentVNode("v-if", true)
5425
+ ], 64 /* STABLE_FRAGMENT */))
5426
+ : _createCommentVNode("v-if", true)
5427
+ ], 64 /* STABLE_FRAGMENT */))
5428
+ : _createCommentVNode("v-if", true),
5429
+ _createElementVNode("button", {
5430
+ type: "button",
5431
+ class: "btn-mini",
5432
+ onClick: _ctx.loadProjectGit,
5433
+ disabled: _ctx.projectGitBusy
5434
+ }, _toDisplayString(_ctx.t('git.refresh')), 9 /* TEXT, PROPS */, ["onClick", "disabled"])
5435
+ ], 40 /* PROPS, NEED_HYDRATION */, ["onToggle"]))
5436
+ : _createCommentVNode("v-if", true),
5040
5437
  _createElementVNode("div", { class: "feature-project-sessions" }, [
5041
5438
  (_openBlock(true), _createElementBlock(_Fragment, null, _renderList(_ctx.projectReport.detail.sessions, (session) => {
5042
5439
  return (_openBlock(), _createElementBlock("article", {
@@ -5104,7 +5501,7 @@ return function render(_ctx, _cache) {
5104
5501
  ]),
5105
5502
  (_ctx.projectSelected)
5106
5503
  ? (_openBlock(), _createElementBlock("details", {
5107
- key: 1,
5504
+ key: 2,
5108
5505
  class: "feature-disclosure"
5109
5506
  }, [
5110
5507
  _createElementVNode("summary", null, _toDisplayString(_ctx.t('features.projectMapping')), 1 /* TEXT */),
@@ -5134,7 +5531,7 @@ return function render(_ctx, _cache) {
5134
5531
  : _createCommentVNode("v-if", true),
5135
5532
  (_ctx.featureView === 'bookmarks')
5136
5533
  ? (_openBlock(), _createElementBlock("div", {
5137
- key: 3,
5534
+ key: 4,
5138
5535
  class: "feature-content"
5139
5536
  }, [
5140
5537
  _createElementVNode("div", { class: "feature-section-heading" }, [
@@ -5610,21 +6007,7 @@ return function render(_ctx, _cache) {
5610
6007
  title: _ctx.parseSessionTitleInfo(session).location
5611
6008
  }, _toDisplayString(_ctx.parseSessionTitleInfo(session).location), 9 /* TEXT, PROPS */, ["title"]))
5612
6009
  : _createCommentVNode("v-if", true)
5613
- ]),
5614
- _createElementVNode("span", { class: "session-count-badge" }, _toDisplayString(session.messageCount == null ? '...' : session.messageCount), 1 /* TEXT */),
5615
- (session.match && session.match.hit)
5616
- ? (_openBlock(), _createElementBlock("span", {
5617
- key: 0,
5618
- class: "session-match-badge"
5619
- }, _toDisplayString(session.match.count), 1 /* TEXT */))
5620
- : _createCommentVNode("v-if", true),
5621
- (_ctx.sessionContextUtilization[_ctx.getSessionExportKey(session)] && _ctx.sessionContextUtilization[_ctx.getSessionExportKey(session)].percent > 0)
5622
- ? (_openBlock(), _createElementBlock("span", {
5623
- key: 1,
5624
- class: _normalizeClass(['session-context-badge', 'session-context-' + _ctx.sessionContextUtilization[_ctx.getSessionExportKey(session)].level]),
5625
- title: 'Context: ' + _ctx.sessionContextUtilization[_ctx.getSessionExportKey(session)].percent + '%'
5626
- }, _toDisplayString(_ctx.sessionContextUtilization[_ctx.getSessionExportKey(session)].percent) + "% ", 11 /* TEXT, CLASS, PROPS */, ["title"]))
5627
- : _createCommentVNode("v-if", true)
6010
+ ])
5628
6011
  ]),
5629
6012
  _createElementVNode("div", { class: "session-item-actions" }, [
5630
6013
  _createElementVNode("button", {
@@ -5691,15 +6074,29 @@ return function render(_ctx, _cache) {
5691
6074
  "data-source": session.source
5692
6075
  }, _toDisplayString(session.sourceLabel), 9 /* TEXT, PROPS */, ["data-source"]),
5693
6076
  _createElementVNode("span", { class: "session-item-time" }, _toDisplayString(session.updatedAtLabel || session.updatedAt || _ctx.t('sessions.unknownTime')), 1 /* TEXT */),
5694
- (_ctx.getSessionHotLabel(session))
6077
+ _createElementVNode("span", { class: "session-count-badge" }, _toDisplayString(session.messageCount == null ? '...' : session.messageCount), 1 /* TEXT */),
6078
+ (session.match && session.match.hit)
5695
6079
  ? (_openBlock(), _createElementBlock("span", {
5696
6080
  key: 0,
6081
+ class: "session-match-badge"
6082
+ }, _toDisplayString(session.match.count), 1 /* TEXT */))
6083
+ : _createCommentVNode("v-if", true),
6084
+ (_ctx.sessionContextUtilization[_ctx.getSessionExportKey(session)] && _ctx.sessionContextUtilization[_ctx.getSessionExportKey(session)].percent > 0)
6085
+ ? (_openBlock(), _createElementBlock("span", {
6086
+ key: 1,
6087
+ class: _normalizeClass(['session-context-badge', 'session-context-' + _ctx.sessionContextUtilization[_ctx.getSessionExportKey(session)].level]),
6088
+ title: 'Context: ' + _ctx.sessionContextUtilization[_ctx.getSessionExportKey(session)].percent + '%'
6089
+ }, _toDisplayString(_ctx.sessionContextUtilization[_ctx.getSessionExportKey(session)].percent) + "% ", 11 /* TEXT, CLASS, PROPS */, ["title"]))
6090
+ : _createCommentVNode("v-if", true),
6091
+ (_ctx.getSessionHotLabel(session))
6092
+ ? (_openBlock(), _createElementBlock("span", {
6093
+ key: 2,
5697
6094
  class: "session-item-hot"
5698
6095
  }, _toDisplayString(_ctx.getSessionHotLabel(session)), 1 /* TEXT */))
5699
6096
  : _createCommentVNode("v-if", true),
5700
6097
  (session.match && session.match.snippets && session.match.snippets.length)
5701
6098
  ? (_openBlock(), _createElementBlock("div", {
5702
- key: 1,
6099
+ key: 3,
5703
6100
  class: "session-match-snippets"
5704
6101
  }, [
5705
6102
  (_openBlock(true), _createElementBlock(_Fragment, null, _renderList(session.match.snippets.slice(0, 2), (snip, si) => {
@@ -5840,7 +6237,7 @@ return function render(_ctx, _cache) {
5840
6237
  (_ctx.handoffCopyText)
5841
6238
  ? (_openBlock(), _createElementBlock("label", {
5842
6239
  key: 2,
5843
- class: "session-workspace-card session-workspace-card-wide"
6240
+ class: "thread-handoff-copy session-workspace-card-wide"
5844
6241
  }, [
5845
6242
  _createElementVNode("span", { class: "session-workspace-card-title" }, "卡片文本(未发送,可手动复制)"),
5846
6243
  _createElementVNode("textarea", {
@@ -5853,19 +6250,27 @@ return function render(_ctx, _cache) {
5853
6250
  ]))
5854
6251
  : _createCommentVNode("v-if", true),
5855
6252
  _createElementVNode("p", { class: "session-workspace-subtitle session-workspace-card-wide" }, "复制不会自动发送。读取确认由目标代理通过 CLI ack 提交。"),
5856
- _createElementVNode("div", { class: "feature-actions" }, [
5857
- _createElementVNode("button", {
5858
- type: "button",
5859
- class: "btn-mini",
5860
- onClick: _ctx.generateSelectedHandoff,
5861
- disabled: _ctx.featureBusy || !_ctx.selectedContextIds.length
5862
- }, _toDisplayString(_ctx.t('features.generateDraft', { count: _ctx.selectedContextIds.length })), 9 /* TEXT, PROPS */, ["onClick", "disabled"])
5863
- ]),
6253
+ (_ctx.selectedContextIds.length)
6254
+ ? (_openBlock(), _createElementBlock("div", {
6255
+ key: 3,
6256
+ class: "feature-actions"
6257
+ }, [
6258
+ _createElementVNode("button", {
6259
+ type: "button",
6260
+ class: "btn-mini",
6261
+ onClick: _ctx.generateSelectedHandoff,
6262
+ disabled: _ctx.featureBusy || !_ctx.selectedContextIds.length
6263
+ }, _toDisplayString(_ctx.t('features.generateDraft', { count: _ctx.selectedContextIds.length })), 9 /* TEXT, PROPS */, ["onClick", "disabled"])
6264
+ ]))
6265
+ : _createCommentVNode("v-if", true),
5864
6266
  (_ctx.handoffDraftEvidence.length)
5865
- ? (_openBlock(), _createElementBlock("p", { key: 3 }, _toDisplayString(_ctx.t('features.draftReview')), 1 /* TEXT */))
6267
+ ? (_openBlock(), _createElementBlock("p", { key: 4 }, _toDisplayString(_ctx.t('features.draftReview')), 1 /* TEXT */))
5866
6268
  : _createCommentVNode("v-if", true),
5867
6269
  (_ctx.handoffUnverified.length)
5868
- ? (_openBlock(), _createElementBlock("details", { key: 4 }, [
6270
+ ? (_openBlock(), _createElementBlock("details", {
6271
+ key: 5,
6272
+ class: "thread-handoff-audit"
6273
+ }, [
5869
6274
  _createElementVNode("summary", null, _toDisplayString(_ctx.t('features.unverified', { count: _ctx.handoffUnverified.length })), 1 /* TEXT */),
5870
6275
  (_openBlock(true), _createElementBlock(_Fragment, null, _renderList(_ctx.handoffUnverified, (text, index) => {
5871
6276
  return (_openBlock(), _createElementBlock("pre", { key: index }, _toDisplayString(text), 1 /* TEXT */))
@@ -5873,7 +6278,10 @@ return function render(_ctx, _cache) {
5873
6278
  ]))
5874
6279
  : _createCommentVNode("v-if", true),
5875
6280
  (_ctx.handoffDraftEvidence.length)
5876
- ? (_openBlock(), _createElementBlock("ul", { key: 5 }, [
6281
+ ? (_openBlock(), _createElementBlock("ul", {
6282
+ key: 6,
6283
+ class: "thread-handoff-evidence"
6284
+ }, [
5877
6285
  (_openBlock(true), _createElementBlock(_Fragment, null, _renderList(_ctx.handoffDraftEvidence, (item) => {
5878
6286
  return (_openBlock(), _createElementBlock("li", {
5879
6287
  key: item.nodeId
@@ -5887,67 +6295,125 @@ return function render(_ctx, _cache) {
5887
6295
  }), 128 /* KEYED_FRAGMENT */))
5888
6296
  ]))
5889
6297
  : _createCommentVNode("v-if", true),
5890
- (_ctx.handoffLoading)
5891
- ? (_openBlock(), _createElementBlock("p", {
5892
- key: 6,
5893
- class: "session-workspace-card-wide",
5894
- role: "status"
5895
- }, "正在加载交接历史…"))
5896
- : (!_ctx.handoffError && !_ctx.handoffRecords.length)
6298
+ _createElementVNode("section", {
6299
+ class: "thread-handoff-history session-workspace-card-wide",
6300
+ "aria-label": "交接历史"
6301
+ }, [
6302
+ _createElementVNode("h3", null, "交接历史"),
6303
+ (_ctx.handoffLoading)
5897
6304
  ? (_openBlock(), _createElementBlock("p", {
5898
- key: 7,
5899
- class: "session-workspace-empty session-workspace-card-wide"
5900
- }, "暂无交接记录"))
5901
- : _createCommentVNode("v-if", true),
5902
- (_ctx.handoffRecords.length)
5903
- ? (_openBlock(), _createElementBlock("ol", {
5904
- key: 8,
5905
- class: "session-workspace-list session-workspace-card-wide"
5906
- }, [
5907
- (_openBlock(true), _createElementBlock(_Fragment, null, _renderList(_ctx.handoffRecords, (record) => {
5908
- return (_openBlock(), _createElementBlock("li", {
5909
- key: record.id,
5910
- class: "session-workspace-card"
5911
- }, [
5912
- _createElementVNode("div", { class: "session-workspace-card-title" }, _toDisplayString(record.target) + " · " + _toDisplayString(_ctx.handoffStatusLabel(record.status)), 1 /* TEXT */),
5913
- _createElementVNode("div", null, [
5914
- _createTextVNode("交接标识:"),
5915
- _createElementVNode("code", null, _toDisplayString(record.id), 1 /* TEXT */)
5916
- ]),
5917
- _createElementVNode("div", null, "创建时间:" + _toDisplayString(record.createdAt) + " · 投递耗时:" + _toDisplayString(record.durationMs) + " 毫秒 · 写入耗时:" + _toDisplayString(record.writeDurationMs || 0) + " 毫秒", 1 /* TEXT */),
5918
- _createElementVNode("div", null, "交接路径:" + _toDisplayString(record.route === 'mcp' ? 'MCP 工具' : '文件级') + " · 文件回退:" + _toDisplayString(record.fallback ? '是' : '否'), 1 /* TEXT */),
5919
- (record.mcp)
5920
- ? (_openBlock(), _createElementBlock("div", { key: 0 }, "服务:" + _toDisplayString(record.mcp.server) + " · 工具:" + _toDisplayString(record.mcp.tool), 1 /* TEXT */))
5921
- : _createCommentVNode("v-if", true),
5922
- _createElementVNode("div", null, "写入结果:" + _toDisplayString(record.writeResult === 'written' ? '已写入' : (record.writeResult === 'failed_or_unconfirmed' ? '失败或结果未确认(不重试)' : '未执行写入')), 1 /* TEXT */),
5923
- (record.filePath)
5924
- ? (_openBlock(), _createElementBlock("div", { key: 1 }, [
5925
- _createTextVNode("文件位置:"),
5926
- _createElementVNode("code", null, _toDisplayString(record.filePath), 1 /* TEXT */)
5927
- ]))
5928
- : _createCommentVNode("v-if", true),
5929
- (record.reason)
5930
- ? (_openBlock(), _createElementBlock("div", { key: 2 }, "原因:" + _toDisplayString(record.reason), 1 /* TEXT */))
5931
- : _createCommentVNode("v-if", true),
5932
- (record.readConfirmation)
5933
- ? (_openBlock(), _createElementBlock("div", { key: 3 }, [
5934
- _createElementVNode("div", null, "读取代理:" + _toDisplayString(record.readConfirmation.agent) + " · 确认时间:" + _toDisplayString(record.readConfirmation.at), 1 /* TEXT */),
5935
- _createElementVNode("div", null, "读取证据:" + _toDisplayString(record.readConfirmation.evidence), 1 /* TEXT */)
5936
- ]))
5937
- : _createCommentVNode("v-if", true),
5938
- (_openBlock(true), _createElementBlock(_Fragment, null, _renderList(record.discoveryWarnings || [], (warning, index) => {
5939
- return (_openBlock(), _createElementBlock("div", { key: index }, "探测提示:" + _toDisplayString(warning.source) + " · " + _toDisplayString(warning.reason), 1 /* TEXT */))
5940
- }), 128 /* KEYED_FRAGMENT */)),
5941
- _createElementVNode("button", {
5942
- class: "btn-mini",
5943
- type: "button",
5944
- onClick: $event => (_ctx.copyThreadHandoff(record)),
5945
- disabled: _ctx.handoffBusy || _ctx.handoffLoading
5946
- }, _toDisplayString(record.route === 'mcp' ? '回退文件并复制卡片' : '复制卡片'), 9 /* TEXT, PROPS */, ["onClick", "disabled"])
5947
- ]))
5948
- }), 128 /* KEYED_FRAGMENT */))
5949
- ]))
5950
- : _createCommentVNode("v-if", true)
6305
+ key: 0,
6306
+ class: "session-workspace-card-wide",
6307
+ role: "status"
6308
+ }, "正在加载交接历史…"))
6309
+ : (!_ctx.handoffError && !_ctx.handoffRecords.length)
6310
+ ? (_openBlock(), _createElementBlock("p", {
6311
+ key: 1,
6312
+ class: "session-workspace-empty session-workspace-card-wide"
6313
+ }, "暂无交接记录"))
6314
+ : _createCommentVNode("v-if", true),
6315
+ (_ctx.handoffRecords.length)
6316
+ ? (_openBlock(), _createElementBlock("ol", {
6317
+ key: 2,
6318
+ class: "session-workspace-list session-workspace-card-wide"
6319
+ }, [
6320
+ (_openBlock(true), _createElementBlock(_Fragment, null, _renderList(_ctx.handoffRecords, (record) => {
6321
+ return (_openBlock(), _createElementBlock("li", {
6322
+ key: record.id,
6323
+ class: "session-workspace-card thread-handoff-record"
6324
+ }, [
6325
+ _createElementVNode("div", { class: "thread-handoff-record-heading" }, [
6326
+ _createElementVNode("div", { class: "thread-handoff-record-title" }, [
6327
+ _createElementVNode("strong", null, _toDisplayString(record.target), 1 /* TEXT */),
6328
+ _createElementVNode("span", { class: "thread-handoff-record-status" }, _toDisplayString(_ctx.handoffStatusLabel(record.status)), 1 /* TEXT */)
6329
+ ]),
6330
+ _createElementVNode("button", {
6331
+ class: "btn-mini",
6332
+ type: "button",
6333
+ onClick: $event => (_ctx.copyThreadHandoff(record)),
6334
+ disabled: _ctx.handoffBusy || _ctx.handoffLoading
6335
+ }, _toDisplayString(record.route === 'mcp' ? '回退文件并复制卡片' : '复制卡片'), 9 /* TEXT, PROPS */, ["onClick", "disabled"])
6336
+ ]),
6337
+ _createElementVNode("p", { class: "thread-handoff-record-route" }, _toDisplayString(record.route === 'mcp' ? 'MCP 工具' : '文件级') + " · " + _toDisplayString(record.writeResult === 'written' ? '已写入' : (record.writeResult === 'failed_or_unconfirmed' ? '失败或结果未确认(不重试)' : '未执行写入')), 1 /* TEXT */),
6338
+ (record.reason)
6339
+ ? (_openBlock(), _createElementBlock("p", {
6340
+ key: 0,
6341
+ class: "thread-handoff-record-reason"
6342
+ }, "原因:" + _toDisplayString(record.reason), 1 /* TEXT */))
6343
+ : _createCommentVNode("v-if", true),
6344
+ (record.readConfirmation)
6345
+ ? (_openBlock(), _createElementBlock("p", {
6346
+ key: 1,
6347
+ class: "thread-handoff-read-proof"
6348
+ }, [
6349
+ _createTextVNode("读取证据:"),
6350
+ _createElementVNode("span", null, _toDisplayString(record.readConfirmation.evidence), 1 /* TEXT */)
6351
+ ]))
6352
+ : _createCommentVNode("v-if", true),
6353
+ _createElementVNode("details", { class: "thread-handoff-audit" }, [
6354
+ _createElementVNode("summary", null, "投递详情"),
6355
+ _createElementVNode("dl", null, [
6356
+ _createElementVNode("div", null, [
6357
+ _createElementVNode("dt", null, "交接标识"),
6358
+ _createElementVNode("dd", null, [
6359
+ _createElementVNode("code", null, _toDisplayString(record.id), 1 /* TEXT */)
6360
+ ])
6361
+ ]),
6362
+ _createElementVNode("div", null, [
6363
+ _createElementVNode("dt", null, "创建时间"),
6364
+ _createElementVNode("dd", null, _toDisplayString(record.createdAt), 1 /* TEXT */)
6365
+ ]),
6366
+ _createElementVNode("div", null, [
6367
+ _createElementVNode("dt", null, "投递耗时"),
6368
+ _createElementVNode("dd", null, _toDisplayString(record.durationMs) + " 毫秒", 1 /* TEXT */)
6369
+ ]),
6370
+ _createElementVNode("div", null, [
6371
+ _createElementVNode("dt", null, "写入耗时"),
6372
+ _createElementVNode("dd", null, _toDisplayString(record.writeDurationMs || 0) + " 毫秒", 1 /* TEXT */)
6373
+ ]),
6374
+ _createElementVNode("div", null, [
6375
+ _createElementVNode("dt", null, "文件回退"),
6376
+ _createElementVNode("dd", null, _toDisplayString(record.fallback ? '是' : '否'), 1 /* TEXT */)
6377
+ ]),
6378
+ (record.mcp)
6379
+ ? (_openBlock(), _createElementBlock("div", { key: 0 }, [
6380
+ _createElementVNode("dt", null, "MCP 服务"),
6381
+ _createElementVNode("dd", null, _toDisplayString(record.mcp.server) + " · " + _toDisplayString(record.mcp.tool), 1 /* TEXT */)
6382
+ ]))
6383
+ : _createCommentVNode("v-if", true),
6384
+ (record.filePath)
6385
+ ? (_openBlock(), _createElementBlock("div", { key: 1 }, [
6386
+ _createElementVNode("dt", null, "文件位置"),
6387
+ _createElementVNode("dd", null, [
6388
+ _createElementVNode("code", null, _toDisplayString(record.filePath), 1 /* TEXT */)
6389
+ ])
6390
+ ]))
6391
+ : _createCommentVNode("v-if", true),
6392
+ (record.readConfirmation)
6393
+ ? (_openBlock(), _createElementBlock("div", { key: 2 }, [
6394
+ _createElementVNode("dt", null, "读取代理"),
6395
+ _createElementVNode("dd", null, _toDisplayString(record.readConfirmation.agent), 1 /* TEXT */)
6396
+ ]))
6397
+ : _createCommentVNode("v-if", true),
6398
+ (record.readConfirmation)
6399
+ ? (_openBlock(), _createElementBlock("div", { key: 3 }, [
6400
+ _createElementVNode("dt", null, "确认时间"),
6401
+ _createElementVNode("dd", null, _toDisplayString(record.readConfirmation.at), 1 /* TEXT */)
6402
+ ]))
6403
+ : _createCommentVNode("v-if", true),
6404
+ (_openBlock(true), _createElementBlock(_Fragment, null, _renderList(record.discoveryWarnings || [], (warning, index) => {
6405
+ return (_openBlock(), _createElementBlock("div", { key: index }, [
6406
+ _createElementVNode("dt", null, "探测提示"),
6407
+ _createElementVNode("dd", null, _toDisplayString(warning.source) + " · " + _toDisplayString(warning.reason), 1 /* TEXT */)
6408
+ ]))
6409
+ }), 128 /* KEYED_FRAGMENT */))
6410
+ ])
6411
+ ])
6412
+ ]))
6413
+ }), 128 /* KEYED_FRAGMENT */))
6414
+ ]))
6415
+ : _createCommentVNode("v-if", true)
6416
+ ])
5951
6417
  ]))
5952
6418
  : _createCommentVNode("v-if", true)
5953
6419
  ], 40 /* PROPS, NEED_HYDRATION */, ["open", "onToggle"]))
@@ -6659,38 +7125,38 @@ return function render(_ctx, _cache) {
6659
7125
  _createElementVNode("div", { class: "session-msg-meta" }, [
6660
7126
  _createElementVNode("span", { class: "session-msg-role" }, _toDisplayString(msg.roleLabel || (msg.normalizedRole === 'user' ? _ctx.t('sessions.roleLabel.user') : (msg.normalizedRole === 'system' ? _ctx.t('sessions.roleLabel.system') : _ctx.t('sessions.roleLabel.assistant')))), 1 /* TEXT */),
6661
7127
  _createElementVNode("span", { class: "session-msg-time" }, _toDisplayString(msg.timestamp || ''), 1 /* TEXT */)
6662
- ])
7128
+ ]),
7129
+ (msg.normalizedRole === 'user')
7130
+ ? (_openBlock(), _createElementBlock("button", {
7131
+ key: 0,
7132
+ type: "button",
7133
+ class: "session-msg-copy",
7134
+ onClick: $event => (_ctx.copySessionMessage(msg)),
7135
+ "aria-label": _ctx.t('sessions.preview.copyMessage'),
7136
+ title: _ctx.t('sessions.preview.copyMessage')
7137
+ }, [
7138
+ (_openBlock(), _createElementBlock("svg", {
7139
+ viewBox: "0 0 24 24",
7140
+ fill: "none",
7141
+ stroke: "currentColor",
7142
+ "stroke-width": "2"
7143
+ }, [
7144
+ _createElementVNode("rect", {
7145
+ x: "8",
7146
+ y: "8",
7147
+ width: "12",
7148
+ height: "12",
7149
+ rx: "2"
7150
+ }),
7151
+ _createElementVNode("path", { d: "M16 8V6a2 2 0 0 0-2-2H6a2 2 0 0 0-2 2v8a2 2 0 0 0 2 2h2" })
7152
+ ]))
7153
+ ], 8 /* PROPS */, ["onClick", "aria-label", "title"]))
7154
+ : _createCommentVNode("v-if", true)
6663
7155
  ]),
6664
7156
  _createElementVNode("div", {
6665
7157
  class: "session-msg-content",
6666
7158
  innerHTML: msg.text || ''
6667
- }, null, 8 /* PROPS */, ["innerHTML"]),
6668
- (msg.normalizedRole === 'user')
6669
- ? (_openBlock(), _createElementBlock("button", {
6670
- key: 0,
6671
- type: "button",
6672
- class: "session-msg-copy",
6673
- onClick: $event => (_ctx.copySessionMessage(msg)),
6674
- "aria-label": _ctx.t('sessions.preview.copyMessage'),
6675
- title: _ctx.t('sessions.preview.copyMessage')
6676
- }, [
6677
- (_openBlock(), _createElementBlock("svg", {
6678
- viewBox: "0 0 24 24",
6679
- fill: "none",
6680
- stroke: "currentColor",
6681
- "stroke-width": "2"
6682
- }, [
6683
- _createElementVNode("rect", {
6684
- x: "8",
6685
- y: "8",
6686
- width: "12",
6687
- height: "12",
6688
- rx: "2"
6689
- }),
6690
- _createElementVNode("path", { d: "M16 8V6a2 2 0 0 0-2-2H6a2 2 0 0 0-2 2v8a2 2 0 0 0 2 2h2" })
6691
- ]))
6692
- ], 8 /* PROPS */, ["onClick", "aria-label", "title"]))
6693
- : _createCommentVNode("v-if", true)
7159
+ }, null, 8 /* PROPS */, ["innerHTML"])
6694
7160
  ], 10 /* CLASS, PROPS */, ["data-message-key"]))
6695
7161
  _item.memo = _memo
6696
7162
  return _item
@@ -6872,6 +7338,187 @@ return function render(_ctx, _cache) {
6872
7338
  ], 8 /* PROPS */, ["onClick", "disabled", "title"])
6873
7339
  ], 8 /* PROPS */, ["aria-label"])
6874
7340
  ]),
7341
+ _createElementVNode("details", {
7342
+ class: "usage-card usage-records",
7343
+ id: "usage-records-report",
7344
+ onToggle: $event => (_ctx.toggleUsageRecords($event))
7345
+ }, [
7346
+ _createElementVNode("summary", null, _toDisplayString(_ctx.t('usage.records.title')), 1 /* TEXT */),
7347
+ _createElementVNode("p", { class: "usage-list-meta" }, _toDisplayString(_ctx.t('usage.records.scope')), 1 /* TEXT */),
7348
+ (_ctx.usageRecordsLoading)
7349
+ ? (_openBlock(), _createElementBlock("p", {
7350
+ key: 0,
7351
+ role: "status"
7352
+ }, _toDisplayString(_ctx.t('usage.loading')), 1 /* TEXT */))
7353
+ : _createCommentVNode("v-if", true),
7354
+ (_ctx.usageRecordsError)
7355
+ ? (_openBlock(), _createElementBlock("p", {
7356
+ key: 1,
7357
+ role: "alert"
7358
+ }, _toDisplayString(_ctx.usageRecordsError), 1 /* TEXT */))
7359
+ : _createCommentVNode("v-if", true),
7360
+ (_ctx.usageRecords)
7361
+ ? (_openBlock(), _createElementBlock(_Fragment, { key: 2 }, [
7362
+ _createElementVNode("p", { class: "usage-list-meta" }, _toDisplayString(_ctx.t('usage.records.coverage', { scanned: _ctx.usageRecords.summary.scannedSessions, candidates: _ctx.usageRecords.summary.candidateSessions, unreported: _ctx.usageRecords.summary.unreportedSessions, unsupported: _ctx.usageRecords.summary.unsupportedSessions })), 1 /* TEXT */),
7363
+ (_ctx.usageRecords.summary.failedSessions.length)
7364
+ ? (_openBlock(), _createElementBlock("p", {
7365
+ key: 0,
7366
+ role: "alert"
7367
+ }, _toDisplayString(_ctx.t('usage.records.failed', { count: _ctx.usageRecords.summary.failedSessions.length })), 1 /* TEXT */))
7368
+ : _createCommentVNode("v-if", true),
7369
+ _createElementVNode("div", { class: "usage-kpi-grid" }, [
7370
+ _createElementVNode("div", { class: "usage-kpi-card" }, [
7371
+ _createElementVNode("div", { class: "usage-kpi-label" }, _toDisplayString(_ctx.t('usage.records.total')), 1 /* TEXT */),
7372
+ _createElementVNode("div", { class: "usage-kpi-value" }, _toDisplayString(_ctx.formatUsageRecordCount(_ctx.usageRecords.summary.totalTokens)), 1 /* TEXT */)
7373
+ ]),
7374
+ _createElementVNode("div", { class: "usage-kpi-card" }, [
7375
+ _createElementVNode("div", { class: "usage-kpi-label" }, _toDisplayString(_ctx.t('usage.records.estimated')), 1 /* TEXT */),
7376
+ _createElementVNode("div", { class: "usage-kpi-value" }, _toDisplayString(_ctx.formatUsageRecordCount(_ctx.usageRecords.summary.estimatedTextTokens)), 1 /* TEXT */)
7377
+ ]),
7378
+ _createElementVNode("div", { class: "usage-kpi-card" }, [
7379
+ _createElementVNode("div", { class: "usage-kpi-label" }, _toDisplayString(_ctx.t('usage.records.cacheRead')), 1 /* TEXT */),
7380
+ _createElementVNode("div", { class: "usage-kpi-value" }, _toDisplayString(_ctx.formatUsageRecordCount(_ctx.usageRecords.summary.cachedInputTokens)), 1 /* TEXT */)
7381
+ ]),
7382
+ _createElementVNode("div", { class: "usage-kpi-card" }, [
7383
+ _createElementVNode("div", { class: "usage-kpi-label" }, _toDisplayString(_ctx.t('usage.records.cacheWrite')), 1 /* TEXT */),
7384
+ _createElementVNode("div", { class: "usage-kpi-value" }, _toDisplayString(_ctx.formatUsageRecordCount(_ctx.usageRecords.summary.cacheCreationInputTokens)), 1 /* TEXT */)
7385
+ ])
7386
+ ]),
7387
+ (_ctx.usageRecords.summary.undatedTokens)
7388
+ ? (_openBlock(), _createElementBlock("p", {
7389
+ key: 1,
7390
+ class: "usage-list-meta"
7391
+ }, _toDisplayString(_ctx.t('usage.records.undated', { tokens: _ctx.usageRecords.summary.undatedTokens })), 1 /* TEXT */))
7392
+ : _createCommentVNode("v-if", true),
7393
+ _createElementVNode("div", { class: "usage-records-table" }, [
7394
+ _createElementVNode("table", null, [
7395
+ _createElementVNode("thead", null, [
7396
+ _createElementVNode("tr", null, [
7397
+ _createElementVNode("th", null, _toDisplayString(_ctx.t('usage.records.date')), 1 /* TEXT */),
7398
+ _createElementVNode("th", null, _toDisplayString(_ctx.t('usage.records.source')), 1 /* TEXT */),
7399
+ _createElementVNode("th", null, _toDisplayString(_ctx.t('usage.records.model')), 1 /* TEXT */),
7400
+ _createElementVNode("th", null, _toDisplayString(_ctx.t('usage.records.input')), 1 /* TEXT */),
7401
+ _createElementVNode("th", null, _toDisplayString(_ctx.t('usage.records.cacheRead')), 1 /* TEXT */),
7402
+ _createElementVNode("th", null, _toDisplayString(_ctx.t('usage.records.cacheWrite')), 1 /* TEXT */),
7403
+ _createElementVNode("th", null, _toDisplayString(_ctx.t('usage.records.output')), 1 /* TEXT */),
7404
+ _createElementVNode("th", null, _toDisplayString(_ctx.t('usage.records.total')), 1 /* TEXT */)
7405
+ ])
7406
+ ]),
7407
+ _createElementVNode("tbody", null, [
7408
+ (_openBlock(true), _createElementBlock(_Fragment, null, _renderList(_ctx.usageRecords.rows, (row) => {
7409
+ return (_openBlock(), _createElementBlock("tr", {
7410
+ key: row.date + ':' + row.source + ':' + row.model
7411
+ }, [
7412
+ _createElementVNode("td", null, _toDisplayString(row.date || _ctx.t('usage.records.unknown')), 1 /* TEXT */),
7413
+ _createElementVNode("td", null, _toDisplayString(row.source), 1 /* TEXT */),
7414
+ _createElementVNode("td", null, _toDisplayString(row.model), 1 /* TEXT */),
7415
+ _createElementVNode("td", null, _toDisplayString(_ctx.formatUsageRecordCount(row.inputTokens)), 1 /* TEXT */),
7416
+ _createElementVNode("td", null, _toDisplayString(_ctx.formatUsageRecordCount(row.cachedInputTokens)), 1 /* TEXT */),
7417
+ _createElementVNode("td", null, _toDisplayString(_ctx.formatUsageRecordCount(row.cacheCreationInputTokens)), 1 /* TEXT */),
7418
+ _createElementVNode("td", null, _toDisplayString(_ctx.formatUsageRecordCount(row.outputTokens)), 1 /* TEXT */),
7419
+ _createElementVNode("td", null, _toDisplayString(_ctx.formatUsageRecordCount(row.totalTokens)), 1 /* TEXT */)
7420
+ ]))
7421
+ }), 128 /* KEYED_FRAGMENT */))
7422
+ ])
7423
+ ])
7424
+ ]),
7425
+ (!_ctx.usageRecords.rows.length)
7426
+ ? (_openBlock(), _createElementBlock("p", { key: 2 }, _toDisplayString(_ctx.t('usage.empty')), 1 /* TEXT */))
7427
+ : _createCommentVNode("v-if", true)
7428
+ ], 64 /* STABLE_FRAGMENT */))
7429
+ : _createCommentVNode("v-if", true),
7430
+ (!_ctx.usageRecordsLoading)
7431
+ ? (_openBlock(), _createElementBlock("button", {
7432
+ key: 3,
7433
+ type: "button",
7434
+ class: "btn-mini",
7435
+ onClick: $event => (_ctx.loadUsageRecords({ forceRefresh: true }))
7436
+ }, _toDisplayString(_ctx.t('usage.refresh')), 9 /* TEXT, PROPS */, ["onClick"]))
7437
+ : _createCommentVNode("v-if", true)
7438
+ ], 40 /* PROPS, NEED_HYDRATION */, ["onToggle"]),
7439
+ _createElementVNode("details", {
7440
+ class: "usage-card usage-pricing",
7441
+ id: "usage-price-reference",
7442
+ onToggle: $event => (_ctx.toggleUsagePricing($event))
7443
+ }, [
7444
+ _createElementVNode("summary", null, _toDisplayString(_ctx.t('pricing.title')), 1 /* TEXT */),
7445
+ _createElementVNode("p", { class: "usage-list-meta" }, _toDisplayString(_ctx.t('pricing.scope')), 1 /* TEXT */),
7446
+ (_ctx.usagePricingBusy)
7447
+ ? (_openBlock(), _createElementBlock("p", {
7448
+ key: 0,
7449
+ role: "status"
7450
+ }, _toDisplayString(_ctx.t('usage.loading')), 1 /* TEXT */))
7451
+ : _createCommentVNode("v-if", true),
7452
+ (_ctx.usagePricingError)
7453
+ ? (_openBlock(), _createElementBlock("p", {
7454
+ key: 1,
7455
+ role: "alert"
7456
+ }, _toDisplayString(_ctx.usagePricingError), 1 /* TEXT */))
7457
+ : _createCommentVNode("v-if", true),
7458
+ (_ctx.usagePricing)
7459
+ ? (_openBlock(), _createElementBlock(_Fragment, { key: 2 }, [
7460
+ _createElementVNode("p", { class: "usage-price-total" }, _toDisplayString(_ctx.t('pricing.total')) + ": " + _toDisplayString(_ctx.formatPriceUsd(_ctx.usagePricing.summary.estimatedUsd)), 1 /* TEXT */),
7461
+ _createElementVNode("p", { class: "usage-list-meta" }, _toDisplayString(_ctx.t('pricing.coverage', { known: _ctx.usagePricing.summary.pricedRows, unknown: _ctx.usagePricing.summary.unknownRows, failed: _ctx.usagePricing.summary.failedSessions, unreported: _ctx.usagePricing.summary.unreportedSessions, unsupported: _ctx.usagePricing.summary.unsupportedSessions })) + " · " + _toDisplayString(_ctx.t('pricing.subtotal')) + ": " + _toDisplayString(_ctx.formatPriceUsd(_ctx.usagePricing.summary.knownSubtotalUsd)), 1 /* TEXT */),
7462
+ _createElementVNode("p", { class: "usage-list-meta" }, [
7463
+ _createElementVNode("a", {
7464
+ href: _ctx.usagePricing.priceSource.repository,
7465
+ target: "_blank",
7466
+ rel: "noopener noreferrer"
7467
+ }, "Wei-Shaw/model-price-repo", 8 /* PROPS */, ["href"]),
7468
+ _createTextVNode(" · " + _toDisplayString(_ctx.usagePricing.priceSource.sourceUpdatedAt) + " · ", 1 /* TEXT */),
7469
+ _createElementVNode("code", null, _toDisplayString(_ctx.usagePricing.priceSource.commit.slice(0, 12)), 1 /* TEXT */)
7470
+ ]),
7471
+ _createElementVNode("div", { class: "usage-records-table" }, [
7472
+ _createElementVNode("table", null, [
7473
+ _createElementVNode("thead", null, [
7474
+ _createElementVNode("tr", null, [
7475
+ _createElementVNode("th", null, _toDisplayString(_ctx.t('usage.records.date')), 1 /* TEXT */),
7476
+ _createElementVNode("th", null, _toDisplayString(_ctx.t('usage.records.source')), 1 /* TEXT */),
7477
+ _createElementVNode("th", null, _toDisplayString(_ctx.t('usage.records.model')), 1 /* TEXT */),
7478
+ _createElementVNode("th", null, _toDisplayString(_ctx.t('pricing.total')), 1 /* TEXT */),
7479
+ _createElementVNode("th", null, _toDisplayString(_ctx.t('pricing.basis')), 1 /* TEXT */)
7480
+ ])
7481
+ ]),
7482
+ _createElementVNode("tbody", null, [
7483
+ (_openBlock(true), _createElementBlock(_Fragment, null, _renderList(_ctx.usagePricing.rows, (row) => {
7484
+ return (_openBlock(), _createElementBlock("tr", {
7485
+ key: row.date + ':' + row.source + ':' + row.model
7486
+ }, [
7487
+ _createElementVNode("td", null, _toDisplayString(row.date || _ctx.t('usage.records.unknown')), 1 /* TEXT */),
7488
+ _createElementVNode("td", null, _toDisplayString(row.source), 1 /* TEXT */),
7489
+ _createElementVNode("td", null, _toDisplayString(row.model), 1 /* TEXT */),
7490
+ _createElementVNode("td", null, _toDisplayString(_ctx.formatPriceUsd(row.estimatedUsd)), 1 /* TEXT */),
7491
+ _createElementVNode("td", null, [
7492
+ _createTextVNode(_toDisplayString(_ctx.t('pricing.reason.' + row.reason)), 1 /* TEXT */),
7493
+ (row.rates)
7494
+ ? (_openBlock(), _createElementBlock("span", {
7495
+ key: 0,
7496
+ class: "usage-price-rates"
7497
+ }, _toDisplayString(_ctx.t('pricing.rates', { input: _ctx.formatTokenRate(row.rates.input_cost_per_token), output: _ctx.formatTokenRate(row.rates.output_cost_per_token), cached: _ctx.formatTokenRate(row.rates.cache_read_input_token_cost), created: _ctx.formatTokenRate(row.rates.cache_creation_input_token_cost) })), 1 /* TEXT */))
7498
+ : _createCommentVNode("v-if", true)
7499
+ ])
7500
+ ]))
7501
+ }), 128 /* KEYED_FRAGMENT */))
7502
+ ])
7503
+ ])
7504
+ ]),
7505
+ (!_ctx.usagePricing.rows.length)
7506
+ ? (_openBlock(), _createElementBlock("p", { key: 0 }, _toDisplayString(_ctx.t('usage.empty')), 1 /* TEXT */))
7507
+ : _createCommentVNode("v-if", true),
7508
+ _createElementVNode("button", {
7509
+ type: "button",
7510
+ class: "btn-mini",
7511
+ onClick: _ctx.downloadUsagePricing
7512
+ }, _toDisplayString(_ctx.t('pricing.download')), 9 /* TEXT, PROPS */, ["onClick"])
7513
+ ], 64 /* STABLE_FRAGMENT */))
7514
+ : _createCommentVNode("v-if", true),
7515
+ _createElementVNode("button", {
7516
+ type: "button",
7517
+ class: "btn-mini",
7518
+ onClick: _ctx.loadUsagePricing,
7519
+ disabled: _ctx.usagePricingBusy
7520
+ }, _toDisplayString(_ctx.t('usage.refresh')), 9 /* TEXT, PROPS */, ["onClick", "disabled"])
7521
+ ], 40 /* PROPS, NEED_HYDRATION */, ["onToggle"]),
6875
7522
  (_ctx.sessionsUsageLoading && !_ctx.sessionsUsageList.length)
6876
7523
  ? (_openBlock(), _createElementBlock("div", {
6877
7524
  key: 0,
@@ -10646,7 +11293,7 @@ return function render(_ctx, _cache) {
10646
11293
  ]))
10647
11294
  : _createCommentVNode("v-if", true),
10648
11295
  _createCommentVNode(" 加载状态 "),
10649
- (_ctx.loading && _ctx.mainTab !== 'usage')
11296
+ (_ctx.loading && _ctx.mainTab !== 'usage' && _ctx.mainTab !== 'prompts')
10650
11297
  ? (_openBlock(), _createElementBlock("div", {
10651
11298
  key: 4,
10652
11299
  class: "state-message app-loading-state"