Skip to content

Commit 9e09491

Browse files
committed
feat(frontend): add Deploy MCP button and update reka-ui to 2.8.0
1 parent 0989f29 commit 9e09491

File tree

6 files changed

+77
-58
lines changed

6 files changed

+77
-58
lines changed

package-lock.json

Lines changed: 6 additions & 42 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

services/frontend/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@
2626
"mitt": "^3.0.1",
2727
"pinia": "^3.0.4",
2828
"prismjs": "^1.30.0",
29-
"reka-ui": "^2.7.0",
29+
"reka-ui": "^2.8.0",
3030
"tailwind-merge": "^3.4.0",
3131
"tailwindcss-animate": "^1.0.7",
3232
"vee-validate": "^4.15.1",

services/frontend/src/i18n/locales/en/mcp-installations.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,8 @@ export default {
7777
view: 'View Details',
7878
configure: 'Configure',
7979
remove: 'Remove Installation',
80-
openMenu: 'Open menu'
80+
openMenu: 'Open menu',
81+
deployMcp: 'Deploy MCP'
8182
},
8283

8384
buttons: {

services/frontend/src/views/dashboard/index.vue

Lines changed: 25 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ import { useI18n } from 'vue-i18n'
44
import { useRouter } from 'vue-router'
55
import NavbarLayout from '@/components/NavbarLayout.vue'
66
import { Button } from '@/components/ui/button'
7+
import { ButtonGroup } from '@/components/ui/button-group'
78
import { toast } from 'vue-sonner'
89
import { useEventBus } from '@/composables/useEventBus'
910
import { useBreadcrumbs } from '@/composables/useBreadcrumbs'
@@ -49,6 +50,11 @@ const isConfigModalOpen = ref(false)
4950
// Computed
5051
const hasInstallations = computed(() => installations.value.length > 0)
5152
53+
// Show Deploy MCP button only if team allows GitHub MCP
54+
const showDeployButton = computed(() => {
55+
return selectedTeam.value?.allow_github_mcp === true
56+
})
57+
5258
// Watch for team changes to reconnect stream
5359
watch(selectedTeam, (newTeam) => {
5460
if (newTeam) {
@@ -138,6 +144,10 @@ const handleInstallServer = () => {
138144
router.push('/mcp-server/install')
139145
}
140146
147+
const handleDeployMcp = () => {
148+
router.push('/deploy')
149+
}
150+
141151
const handleOpenConfigModal = () => {
142152
// If walkthrough step 2 is active, finish the walkthrough
143153
if (showWalkthroughStep2.value) {
@@ -365,20 +375,28 @@ onUnmounted(() => {
365375
<Button
366376
id="get-configuration-button"
367377
@click="handleOpenConfigModal"
368-
variant="outline"
369378
:class="[
370379
'flex items-center justify-center gap-2',
371380
showStep2ButtonHighZIndex ? 'relative z-[10000]' : ''
372381
]"
373382
>
374383
{{ t('satelliteConfig.button.getConfiguration') }}
375384
</Button>
376-
<Button
377-
@click="handleInstallServer"
378-
class="flex items-center justify-center gap-2"
379-
>
380-
{{ t('mcpInstallations.featuredList.browseCatalog') }}
381-
</Button>
385+
<ButtonGroup>
386+
<Button
387+
v-if="showDeployButton"
388+
@click="handleDeployMcp"
389+
variant="outline"
390+
>
391+
{{ t('mcpInstallations.actions.deployMcp') }}
392+
</Button>
393+
<Button
394+
@click="handleInstallServer"
395+
variant="outline"
396+
>
397+
{{ t('mcpInstallations.featuredList.browseCatalog') }}
398+
</Button>
399+
</ButtonGroup>
382400
</div>
383401
</div>
384402

services/frontend/src/views/mcp-server/index.vue

Lines changed: 25 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ import { useRouter } from 'vue-router'
55
import NavbarLayout from '@/components/NavbarLayout.vue'
66
import { DsPageHeading } from '@/components/ui/ds-page-heading'
77
import { Button } from '@/components/ui/button'
8+
import { ButtonGroup } from '@/components/ui/button-group'
89
import { toast } from 'vue-sonner'
910
import { useEventBus } from '@/composables/useEventBus'
1011
import { useInstallationsStream } from '@/composables/mcp-server'
@@ -33,6 +34,11 @@ const {
3334
// Computed
3435
const hasInstallations = computed(() => installations.value.length > 0)
3536
37+
// Show Deploy MCP button only if team allows GitHub MCP
38+
const showDeployButton = computed(() => {
39+
return selectedTeam.value?.allow_github_mcp === true
40+
})
41+
3642
// Watch for team changes to reconnect stream
3743
watch(selectedTeam, (newTeam) => {
3844
if (newTeam) {
@@ -45,6 +51,10 @@ const handleInstallServer = () => {
4551
router.push('/mcp-server/install')
4652
}
4753
54+
const handleDeployMcp = () => {
55+
router.push('/deploy')
56+
}
57+
4858
const handleViewInstallation = (serverId: string) => {
4959
router.push(`/mcp-server/view/${serverId}`)
5060
}
@@ -187,13 +197,21 @@ onUnmounted(() => {
187197
<NavbarLayout>
188198
<DsPageHeading :title="t('mcpInstallations.title')">
189199
<template #actions>
190-
<Button
191-
v-if="selectedTeam"
192-
@click="handleInstallServer"
193-
class="flex items-center gap-2"
194-
>
195-
{{ t('mcpInstallations.featuredList.browseCatalog') }}
196-
</Button>
200+
<ButtonGroup v-if="selectedTeam">
201+
<Button
202+
v-if="showDeployButton"
203+
@click="handleDeployMcp"
204+
variant="outline"
205+
>
206+
{{ t('mcpInstallations.actions.deployMcp') }}
207+
</Button>
208+
<Button
209+
@click="handleInstallServer"
210+
variant="outline"
211+
>
212+
{{ t('mcpInstallations.featuredList.browseCatalog') }}
213+
</Button>
214+
</ButtonGroup>
197215
</template>
198216
</DsPageHeading>
199217

services/frontend/src/views/mcp-server/search.vue

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ import { Button } from '@/components/ui/button'
77
import { Alert, AlertDescription } from '@/components/ui/alert'
88
import { Skeleton } from '@/components/ui/skeleton'
99
import { useBreadcrumbs } from '@/composables/useBreadcrumbs'
10+
import { useTeamContext } from '@/composables/useTeamContext'
1011
import NavbarLayout from '@/components/NavbarLayout.vue'
1112
import McpServerSquareCard from '@/components/mcp-server/McpServerSquareCard.vue'
1213
import FeaturedMcpServers from '@/components/mcp-server/FeaturedMcpServers.vue'
@@ -19,6 +20,9 @@ const { t } = useI18n()
1920
const router = useRouter()
2021
const { setBreadcrumbs } = useBreadcrumbs()
2122
23+
// Team context using composable
24+
const { selectedTeam } = useTeamContext()
25+
2226
// State
2327
const isLoading = ref(false)
2428
const isLoadingCategories = ref(false)
@@ -50,6 +54,11 @@ const shouldShowResults = computed(() => {
5054
return hasSearched.value && filteredServers.value.length > 0
5155
})
5256
57+
// Show Deploy MCP button only if team allows GitHub MCP
58+
const showDeployButton = computed(() => {
59+
return selectedTeam.value?.allow_github_mcp === true
60+
})
61+
5362
// Methods
5463
const loadCategories = async () => {
5564
try {
@@ -212,6 +221,15 @@ onMounted(() => {
212221
>
213222
{{ t('mcpInstallations.wizard.server.viewAllServers') }}
214223
</Button>
224+
<Button
225+
v-if="showDeployButton"
226+
variant="outline"
227+
size="sm"
228+
class="bg-black text-white border-black hover:bg-black/90 hover:border-black hover:text-white"
229+
@click="router.push('/deploy')"
230+
>
231+
{{ t('mcpInstallations.actions.deployMcp') }}
232+
</Button>
215233
</div>
216234
</div>
217235

0 commit comments

Comments
 (0)