File tree Expand file tree Collapse file tree 1 file changed +16
-9
lines changed
packages/tui/internal/components/chat Expand file tree Collapse file tree 1 file changed +16
-9
lines changed Original file line number Diff line number Diff line change @@ -448,23 +448,30 @@ func (m *messagesComponent) renderHeader() string {
448448 Render (formatTokensAndCost (tokens , contextWindow , cost , isSubscriptionModel ))
449449
450450 background := t .Background ()
451- share = layout .Render (
451+
452+ var items []layout.FlexItem
453+ justify := layout .JustifyEnd
454+
455+ if m .app .Config .Share != opencode .ConfigShareDisabled {
456+ items = append (items , layout.FlexItem {View : share })
457+ justify = layout .JustifySpaceBetween
458+ }
459+
460+ items = append (items , layout.FlexItem {View : sessionInfo })
461+
462+ headerRow := layout .Render (
452463 layout.FlexOptions {
453464 Background : & background ,
454465 Direction : layout .Row ,
455- Justify : layout . JustifySpaceBetween ,
466+ Justify : justify ,
456467 Align : layout .AlignStretch ,
457468 Width : headerWidth - 6 ,
458469 },
459- layout.FlexItem {
460- View : share ,
461- },
462- layout.FlexItem {
463- View : sessionInfo ,
464- },
470+ items ... ,
465471 )
466472
467- headerLines = append (headerLines , share )
473+ headerLines = append (headerLines , headerRow )
474+
468475 header := strings .Join (headerLines , "\n " )
469476 header = styles .NewStyle ().
470477 Background (t .Background ()).
You can’t perform that action at this time.
0 commit comments