-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(open-api): add servers display if set
INT-407
- Loading branch information
Showing
3 changed files
with
28 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
23 changes: 23 additions & 0 deletions
23
src/.vuepress/theme/client/components/global/OpenApiServers.vue
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
<template> | ||
<ul | ||
v-if="servers?.length" | ||
class="open-api-servers"> | ||
<li | ||
v-for="(server, index) in servers" | ||
:key="index"> | ||
<code>{{ server.url }}</code> | ||
<Markdown | ||
v-if="server.description" | ||
:content="server.description" /> | ||
</li> | ||
</ul> | ||
</template> | ||
|
||
<script setup lang="ts"> | ||
import {type OpenAPIV3_1 as OpenApiType} from 'openapi-types'; | ||
import Markdown from './Markdown.vue'; | ||
defineProps<{ | ||
servers: OpenApiType.Document['servers']; | ||
}>(); | ||
</script> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters