feat(FN-4403): complete Step 1 — move mobile rooms action to footer
Fusion-Task-Id: FN-4403 Fusion-Task-Lineage: 9bbfbed9-c40b-4ad2-a739-c8d93f9f691f
This commit is contained in:
@@ -2313,17 +2313,19 @@ export function ChatView({ projectId, addToast, experimentalFeatures }: ChatView
|
|||||||
</>
|
</>
|
||||||
) : (
|
) : (
|
||||||
<div className="chat-sidebar-rooms" data-testid="chat-sidebar-rooms">
|
<div className="chat-sidebar-rooms" data-testid="chat-sidebar-rooms">
|
||||||
<div className="chat-sidebar-rooms-header">
|
{!isMobile && (
|
||||||
<button
|
<div className="chat-sidebar-rooms-header" data-testid="chat-sidebar-rooms-header">
|
||||||
type="button"
|
<button
|
||||||
className="btn btn-sm btn-primary"
|
type="button"
|
||||||
data-testid="chat-create-room-btn"
|
className="btn btn-sm btn-primary"
|
||||||
onClick={() => setCreateRoomOpen(true)}
|
data-testid="chat-create-room-btn"
|
||||||
>
|
onClick={() => setCreateRoomOpen(true)}
|
||||||
<Plus size={14} />
|
>
|
||||||
Create room
|
<Plus size={14} />
|
||||||
</button>
|
Create room
|
||||||
</div>
|
</button>
|
||||||
|
</div>
|
||||||
|
)}
|
||||||
{rooms.rooms.length === 0 ? (
|
{rooms.rooms.length === 0 ? (
|
||||||
<div className="chat-sidebar-rooms-empty" data-testid="chat-sidebar-rooms-empty">
|
<div className="chat-sidebar-rooms-empty" data-testid="chat-sidebar-rooms-empty">
|
||||||
No rooms yet.
|
No rooms yet.
|
||||||
@@ -2382,17 +2384,32 @@ export function ChatView({ projectId, addToast, experimentalFeatures }: ChatView
|
|||||||
)}
|
)}
|
||||||
</div>
|
</div>
|
||||||
)}
|
)}
|
||||||
{/* Mobile footer with New Chat action */}
|
{chatScope === "rooms" ? (
|
||||||
<div className="chat-sidebar-footer">
|
isMobile ? (
|
||||||
<button
|
<div className="chat-sidebar-footer">
|
||||||
className="btn btn-sm btn-primary chat-sidebar-footer-btn"
|
<button
|
||||||
onClick={() => setShowNewDialog(true)}
|
type="button"
|
||||||
data-testid="chat-new-btn"
|
className="btn btn-sm btn-primary chat-sidebar-footer-btn"
|
||||||
>
|
data-testid="chat-create-room-btn"
|
||||||
<Plus size={14} />
|
onClick={() => setCreateRoomOpen(true)}
|
||||||
New Chat
|
>
|
||||||
</button>
|
<Plus size={14} />
|
||||||
</div>
|
Create room
|
||||||
|
</button>
|
||||||
|
</div>
|
||||||
|
) : null
|
||||||
|
) : (
|
||||||
|
<div className="chat-sidebar-footer">
|
||||||
|
<button
|
||||||
|
className="btn btn-sm btn-primary chat-sidebar-footer-btn"
|
||||||
|
onClick={() => setShowNewDialog(true)}
|
||||||
|
data-testid="chat-new-btn"
|
||||||
|
>
|
||||||
|
<Plus size={14} />
|
||||||
|
New Chat
|
||||||
|
</button>
|
||||||
|
</div>
|
||||||
|
)}
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
{!isMobile && sidebarVisible && (
|
{!isMobile && sidebarVisible && (
|
||||||
|
|||||||
Reference in New Issue
Block a user