mirror of
https://git.mirrors.martin98.com/https://github.com/langgenius/dify.git
synced 2025-08-16 06:05:58 +08:00
feat: add optional hidden property to endpoint items and filter hidden endpoints in endpoint card (#19163)
This commit is contained in:
parent
0358859467
commit
623ac7ea6d
@ -149,7 +149,7 @@ const EndpointCard = ({
|
|||||||
</ActionButton>
|
</ActionButton>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
{data.declaration.endpoints.map((endpoint, index) => (
|
{data.declaration.endpoints.filter(endpoint => !endpoint.hidden).map((endpoint, index) => (
|
||||||
<div key={index} className='flex h-6 items-center'>
|
<div key={index} className='flex h-6 items-center'>
|
||||||
<div className='system-xs-regular w-12 shrink-0 text-text-tertiary'>{endpoint.method}</div>
|
<div className='system-xs-regular w-12 shrink-0 text-text-tertiary'>{endpoint.method}</div>
|
||||||
<div className='group/item system-xs-regular flex grow items-center truncate text-text-secondary'>
|
<div className='group/item system-xs-regular flex grow items-center truncate text-text-secondary'>
|
||||||
|
@ -36,6 +36,7 @@ export type PluginEndpointDeclaration = {
|
|||||||
export type EndpointItem = {
|
export type EndpointItem = {
|
||||||
path: string
|
path: string
|
||||||
method: string
|
method: string
|
||||||
|
hidden?: boolean
|
||||||
}
|
}
|
||||||
|
|
||||||
export type EndpointListItem = {
|
export type EndpointListItem = {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user