Keep chat workspace above Android navigation and use pane chat color
This commit is contained in:
@@ -243,34 +243,46 @@ mixin _ChatScreenWorkspace on State<ChatScreen> {
|
||||
onSelected: _openBelow,
|
||||
);
|
||||
|
||||
Widget _workspaceView() => ChatWorkspace(
|
||||
key: _workspaceKey,
|
||||
controller: _workspace,
|
||||
shortcutsEnabled: _workspaceVisible,
|
||||
singlePane: !showsListBesideDetail(context),
|
||||
mobilePeeks: !showsListBesideDetail(context),
|
||||
paneTitle: (pane) =>
|
||||
'${_rowFor(pane.sessionId)?['title'] ?? pane.sessionId}',
|
||||
onFocusPane: (pane) => _composerFocus.request(pane.sessionId),
|
||||
paneBuilder: (context, pane, active) => Semantics(
|
||||
selected: active,
|
||||
child: DecoratedBox(
|
||||
position: DecorationPosition.foreground,
|
||||
decoration: BoxDecoration(
|
||||
border: Border.all(
|
||||
color: _workspace.paneCount > 1 && active
|
||||
? (chatControlsStyleOf(context) == ChatControlsStyle.cupertino
|
||||
? CupertinoTheme.of(context).primaryColor
|
||||
: Theme.of(context).colorScheme.primary)
|
||||
: Colors.transparent,
|
||||
Widget _workspaceView() => SafeArea(
|
||||
top: false,
|
||||
child: ChatWorkspace(
|
||||
key: _workspaceKey,
|
||||
controller: _workspace,
|
||||
shortcutsEnabled: _workspaceVisible,
|
||||
singlePane: !showsListBesideDetail(context),
|
||||
mobilePeeks: !showsListBesideDetail(context),
|
||||
paneTitle: (pane) =>
|
||||
'${_rowFor(pane.sessionId)?['title'] ?? pane.sessionId}',
|
||||
onFocusPane: (pane) => _composerFocus.request(pane.sessionId),
|
||||
paneBuilder: (context, pane, active) => Semantics(
|
||||
selected: active,
|
||||
child: DecoratedBox(
|
||||
position: DecorationPosition.foreground,
|
||||
decoration: BoxDecoration(
|
||||
border: Border.all(
|
||||
color: _workspace.paneCount > 1 && active
|
||||
? chatColorShade(
|
||||
context,
|
||||
chatSessionColor(_rowFor(pane.sessionId)),
|
||||
) ??
|
||||
(chatControlsStyleOf(context) ==
|
||||
ChatControlsStyle.cupertino
|
||||
? CupertinoTheme.of(context).primaryColor
|
||||
: Theme.of(context).colorScheme.primary)
|
||||
: Colors.transparent,
|
||||
),
|
||||
),
|
||||
child: DetailPane(
|
||||
key: ValueKey('chat-pane-detail-${pane.id}'),
|
||||
destination: AppDestination.chat,
|
||||
implyBack: false,
|
||||
builder: (context) => _thread(
|
||||
pane.sessionId,
|
||||
_back,
|
||||
pane: pane,
|
||||
paneContext: context,
|
||||
),
|
||||
),
|
||||
),
|
||||
child: DetailPane(
|
||||
key: ValueKey('chat-pane-detail-${pane.id}'),
|
||||
destination: AppDestination.chat,
|
||||
implyBack: false,
|
||||
builder: (context) =>
|
||||
_thread(pane.sessionId, _back, pane: pane, paneContext: context),
|
||||
),
|
||||
),
|
||||
),
|
||||
|
||||
Reference in New Issue
Block a user