diff --git a/frontend/src/lib/components/CenteredPage.svelte b/frontend/src/lib/components/CenteredPage.svelte index 79143e5266..ab79a0c0e9 100644 --- a/frontend/src/lib/components/CenteredPage.svelte +++ b/frontend/src/lib/components/CenteredPage.svelte @@ -4,14 +4,19 @@ interface Props { class?: string children?: import('svelte').Snippet<[{ width: number }]> + wrapperClasses?: string + handleOverflow?: boolean } - let { class: clazz = '', children }: Props = $props() + let { class: clazz = '', children, wrapperClasses = '', handleOverflow = true }: Props = $props() let width = $state(0) -
+
{@render children?.({ width })}
diff --git a/frontend/src/lib/components/ForkWorkspaceBanner.svelte b/frontend/src/lib/components/ForkWorkspaceBanner.svelte index 8baf7281ea..1305be849e 100644 --- a/frontend/src/lib/components/ForkWorkspaceBanner.svelte +++ b/frontend/src/lib/components/ForkWorkspaceBanner.svelte @@ -68,10 +68,7 @@ } } - function forkAheadBehindMessage( - changesAhead: number, - changesBehind: number, - ) { + function forkAheadBehindMessage(changesAhead: number, changesBehind: number) { let msg: string[] = [] if (changesAhead > 0 || changesBehind > 0) { msg.push('This fork is ') @@ -86,11 +83,11 @@ {#if isFork} -
+
- +
Fork of {parentWorkspaceData?.name} ({parentWorkspaceId}) @@ -106,17 +103,17 @@ {:else if comparison}
{#if comparison.summary.total_diffs > 0} - + {forkAheadBehindMessage( comparison.summary.total_ahead, - comparison.summary.total_behind, + comparison.summary.total_behind )} - {parentWorkspaceId} over {comparison.summary - .total_diffs} items: + {parentWorkspaceId} over {comparison + .summary.total_diffs} items:
{#if comparison.summary.scripts_changed > 0} - + {comparison.summary.scripts_changed} script{comparison.summary .scripts_changed !== 1 ? 's' @@ -124,21 +121,21 @@ {/if} {#if comparison.summary.flows_changed > 0} - + {comparison.summary.flows_changed} flow{comparison.summary.flows_changed !== 1 ? 's' : ''} {/if} {#if comparison.summary.apps_changed > 0} - + {comparison.summary.apps_changed} app{comparison.summary.apps_changed !== 1 ? 's' : ''} {/if} {#if comparison.summary.resources_changed > 0} - + {comparison.summary.resources_changed} resource{comparison.summary .resources_changed !== 1 ? 's' @@ -146,7 +143,7 @@ {/if} {#if comparison.summary.variables_changed > 0} - + {comparison.summary.variables_changed} variable{comparison.summary .variables_changed !== 1 ? 's' @@ -167,9 +164,12 @@
{/if} {:else if comparison.skipped_comparison} - This fork was created before the addition of certain windmill features, and therefore the changes with its parent workspace cannot be displayed. + + This fork was created before the addition of certain windmill features, and + therefore the changes with its parent workspace cannot be displayed. {:else} - Everything is up to date + Everything is up to date {/if}
{/if} diff --git a/frontend/src/lib/components/copilot/chat/AiChatLayout.svelte b/frontend/src/lib/components/copilot/chat/AiChatLayout.svelte index 1a1fb92baf..a313e0fb94 100644 --- a/frontend/src/lib/components/copilot/chat/AiChatLayout.svelte +++ b/frontend/src/lib/components/copilot/chat/AiChatLayout.svelte @@ -8,6 +8,8 @@ import { loadCopilot } from '$lib/aiStore' import { aiChatManager } from './AIChatManager.svelte' import { onDestroy } from 'svelte' + import Button from '$lib/components/common/button/Button.svelte' + import { Menu } from 'lucide-svelte' interface Props { noPadding?: boolean @@ -47,49 +49,32 @@ {#if !disableAi} - +
-
-
+
+
- +
-
+
{@render children?.()}
diff --git a/frontend/src/lib/components/home/ItemsList.svelte b/frontend/src/lib/components/home/ItemsList.svelte index 8f46ded01f..71d61fd890 100644 --- a/frontend/src/lib/components/home/ItemsList.svelte +++ b/frontend/src/lib/components/home/ItemsList.svelte @@ -362,7 +362,7 @@ - +
{ // Check if there's a tutorial parameter in the URL @@ -259,105 +263,110 @@ - -
- {#if $workspaceStore == 'admins'} -
+
+ +
+ {#if $workspaceStore == 'admins'} +
- - The Admins workspace is for admins only and contains scripts whose purpose is to manage your - Windmill instance, such as keeping resource types up to date. - - {/if} - - {#if !$userStore?.operator} - Create a - - {#if HOME_SHOW_CREATE_FLOW}{/if} - {#if HOME_SHOW_CREATE_APP}{/if} + + The Admins workspace is for admins only and contains scripts whose purpose is to manage your + Windmill instance, such as keeping resource types up to date. + {/if} - + + {#if !$userStore?.operator} + Create a + + {#if HOME_SHOW_CREATE_FLOW}{/if} + {#if HOME_SHOW_CREATE_APP}{/if} + {/if} + - + - {#if !$userStore?.operator} -
- - - {#if HOME_SHOW_HUB} - - {/if} - -
- {/if} - {#if tab == 'hub'} -
-
- {#snippet toggleKinds()} - { - setQuery($page.url, 'kind', v, window.location.hash) - }} - noWFull - > - {#snippet children({ item })} - - - - {/snippet} - - - {/snippet} - - {#if subtab == 'script'} - viewCode(e.detail)}> - {#snippet children()} - {@render toggleKinds?.()} - {/snippet} - - {:else if subtab == 'flow'} - viewFlow(e.detail)}> - {#snippet children()} - {@render toggleKinds?.()} - {/snippet} - - {:else if subtab == 'app'} - viewApp(e.detail)}> - {#snippet children()} - {@render toggleKinds?.()} - {/snippet} - - {/if} + {#if !$userStore?.operator} +
+ + + {#if HOME_SHOW_HUB} + + {/if} +
-
+ {/if} + {#if tab == 'hub'} +
+
+ {#snippet toggleKinds()} + { + setQuery($page.url, 'kind', v, window.location.hash) + }} + noWFull + > + {#snippet children({ item })} + + + + {/snippet} + + + {/snippet} + + {#if subtab == 'script'} + viewCode(e.detail)}> + {#snippet children()} + {@render toggleKinds?.()} + {/snippet} + + {:else if subtab == 'flow'} + viewFlow(e.detail)}> + {#snippet children()} + {@render toggleKinds?.()} + {/snippet} + + {:else if subtab == 'app'} + viewApp(e.detail)}> + {#snippet children()} + {@render toggleKinds?.()} + {/snippet} + + {/if} +
+
+ {/if} +
+ + {#if tab == 'workspace'} + {/if}
-{#if tab == 'workspace'} - -{/if} -