Skip to content

Commit c26cf38

Browse files
committed
fix more problems on mobile
1 parent 9e7af64 commit c26cf38

File tree

3 files changed

+166
-142
lines changed

3 files changed

+166
-142
lines changed

examples/server/public/index.html

Lines changed: 159 additions & 135 deletions
Large diffs are not rendered by default.

examples/server/webui/index.html

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
<!-- sidebar -->
1616
<div class="drawer-side h-screen lg:h-screen z-50 lg:max-w-64">
1717
<label for="toggle-drawer" aria-label="close sidebar" class="drawer-overlay"></label>
18-
<div class="flex flex-col bg-base-200 min-h-full py-4 px-4">
18+
<div class="flex flex-col bg-base-200 min-h-full max-w-[calc(100vw-2em)] py-4 px-4">
1919
<div class="flex flex-row items-center justify-between mb-4 mt-4">
2020
<h2 class="font-bold ml-4">Conversations</h2>
2121

@@ -63,15 +63,15 @@ <h2 class="font-bold ml-4">Conversations</h2>
6363
<div class="flex items-center">
6464
<div v-if="messages.length > 0" class="dropdown dropdown-end">
6565
<!-- "more" button -->
66-
<div tabindex="0" role="button" class="btn m-1">
66+
<button tabindex="0" role="button" class="btn m-1" :disabled="isGenerating">
6767
<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" fill="currentColor" class="bi bi-three-dots-vertical" viewBox="0 0 16 16">
6868
<path d="M9.5 13a1.5 1.5 0 1 1-3 0 1.5 1.5 0 0 1 3 0m0-5a1.5 1.5 0 1 1-3 0 1.5 1.5 0 0 1 3 0m0-5a1.5 1.5 0 1 1-3 0 1.5 1.5 0 0 1 3 0"/>
6969
</svg>
70-
</div>
70+
</button>
7171
<!-- "more" dropdown menu -->
7272
<ul tabindex="0" class="dropdown-content menu bg-base-100 rounded-box z-[1] w-52 p-2 shadow">
73-
<li @click="downloadConv(viewingConvId)" :disabled="isGenerating"><a>Download</a></li>
74-
<li class="text-error" @click="deleteConv(viewingConvId)" :disabled="isGenerating"><a>Delete</a></li>
73+
<li @click="downloadConv(viewingConvId)"><a>Download</a></li>
74+
<li class="text-error" @click="deleteConv(viewingConvId)"><a>Delete</a></li>
7575
</ul>
7676
</div>
7777
<button class="btn" @click="showConfigDialog = true" :disabled="isGenerating">
@@ -132,7 +132,7 @@ <h2 class="font-bold ml-4">Conversations</h2>
132132
<!-- textarea for editing message -->
133133
<template v-if="editingMsg && editingMsg.id === msg.id">
134134
<textarea
135-
class="textarea textarea-bordered bg-base-100 text-base-content w-96"
135+
class="textarea textarea-bordered bg-base-100 text-base-content w-[calc(90vw-8em)] lg:w-96"
136136
v-model="msg.content"></textarea>
137137
<br/>
138138
<button class="btn btn-ghost mt-2 mr-2" @click="editingMsg = null">Cancel</button>

examples/server/webui/src/styles.css

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
}
1313

1414
.show-on-hover {
15-
@apply opacity-0 group-hover:opacity-100;
15+
@apply md:opacity-0 md:group-hover:opacity-100;
1616
}
1717
.btn-mini {
1818
@apply cursor-pointer hover:shadow-md;

0 commit comments

Comments
 (0)