File tree Expand file tree Collapse file tree 4 files changed +20
-5
lines changed Expand file tree Collapse file tree 4 files changed +20
-5
lines changed Original file line number Diff line number Diff line change @@ -90,4 +90,6 @@ ENV BODY_SIZE_LIMIT=15728640
9090COPY --from=builder --chown=1000 /app/build /app/build
9191COPY --from=builder --chown=1000 /app/node_modules /app/node_modules
9292
93+ RUN apt -y update && apt-get install -y curl dnsutils
94+
9395CMD ["/bin/bash" , "-c" , "/app/entrypoint.sh" ]
Original file line number Diff line number Diff line change 2525 toggleServer ,
2626 } from " $lib/stores/mcpServers" ;
2727 import { getMcpServerFaviconUrl } from " $lib/utils/favicon" ;
28+ import { page } from " $app/state" ;
2829
2930 interface Props {
3031 files? : File [];
7677 let fileInputEl: HTMLInputElement | undefined = $state ();
7778 let isUrlModalOpen = $state (false );
7879 let isMcpManagerOpen = $state (false );
80+ let isDropdownOpen = $state (false );
7981
8082 function openPickerWithAccept(accept : string ) {
8183 if (! fileInputEl ) return ;
107109 : Promise .resolve ();
108110
109111 async function focusTextarea() {
112+ if (page .data .shared && page .data .loginEnabled && ! page .data .user ) return ;
110113 if (! textareaElement || textareaElement .disabled || isVirtualKeyboard ()) return ;
111114 if (typeof document !== " undefined" && document .activeElement === textareaElement ) return ;
112115
177180 }
178181
179182 function handleFocus() {
183+ if (requireAuthUser ()) {
184+ return ;
185+ }
180186 if (blurTimeout ) {
181187 clearTimeout (blurTimeout );
182188 blurTimeout = null ;
251257 accept ={mimeTypes .join (" ," )}
252258 />
253259
254- <DropdownMenu .Root >
260+ <DropdownMenu .Root
261+ bind:open ={isDropdownOpen }
262+ onOpenChange ={(open ) => {
263+ if (open && requireAuthUser ()) {
264+ isDropdownOpen = false ;
265+ return ;
266+ }
267+ isDropdownOpen = open ;
268+ }}
269+ >
255270 <DropdownMenu .Trigger
256271 class =" btn size-7 rounded-full border bg-white text-black shadow transition-none enabled:hover:bg-white enabled:hover:shadow-inner dark:border-transparent dark:bg-gray-600/50 dark:text-white dark:hover:enabled:bg-gray-600"
257272 disabled ={loading }
Original file line number Diff line number Diff line change 8282 const txt = await res .text ();
8383 throw new Error (txt || ` Failed to fetch (${res .status }) ` );
8484 }
85- const forwardedType =
86- res .headers .get (" x-forwarded-content-type" );
85+ const forwardedType = res .headers .get (" x-forwarded-content-type" );
8786 const blob = await res .blob ();
8887 const mimeType = pickSafeMime (forwardedType , blob .type , trimmed );
8988 // Optional client-side mime filter (same wildcard semantics as dropzone)
Original file line number Diff line number Diff line change @@ -91,8 +91,7 @@ export async function loadAttachmentsFromUrls(
9191 return ;
9292 }
9393
94- const forwardedType =
95- response . headers . get ( "x-forwarded-content-type" ) ;
94+ const forwardedType = response . headers . get ( "x-forwarded-content-type" ) ;
9695 const blob = await response . blob ( ) ;
9796 const mimeType = pickSafeMime ( forwardedType , blob . type , url ) ;
9897 const contentDisposition = response . headers . get ( "content-disposition" ) ;
You can’t perform that action at this time.
0 commit comments