From 67b1b5f86c8173d923250294494178f46c003985 Mon Sep 17 00:00:00 2001 From: weibaohui Date: Sun, 12 Jan 2025 11:10:15 +0800 Subject: [PATCH] =?UTF-8?q?refactor(pages):=20=E9=87=8D=E6=9E=84=20API=20?= =?UTF-8?q?=E6=96=87=E6=A1=A3=E9=A1=B5=E9=9D=A2=E5=B8=83=E5=B1=80=E5=92=8C?= =?UTF-8?q?=E5=8A=9F=E8=83=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit -移除了 searchConfig 中的 selectFirst 属性 - 调整了 aside 的最小和最大宽度- 重新组织了页面结构,增加了基本属性和详细描述的分离 - 添加了属性、类型和描述的单独展示区域 -增加了翻译内容的展示 - 优化了 markdown 渲染选项 --- assets/pages/cluster/api_service.json | 64 ++++++++++++++--- assets/pages/cluster/cluster_role.json | 64 ++++++++++++++--- .../pages/cluster/cluster_role_binding.json | 64 ++++++++++++++--- assets/pages/cluster/csi_node.json | 64 ++++++++++++++--- assets/pages/cluster/flow_schema.json | 64 ++++++++++++++--- assets/pages/cluster/ingress_class.json | 64 ++++++++++++++--- assets/pages/cluster/mutating_webhook.json | 64 ++++++++++++++--- assets/pages/cluster/node.json | 64 ++++++++++++++--- assets/pages/cluster/ns.json | 64 ++++++++++++++--- assets/pages/cluster/priority_class.json | 64 ++++++++++++++--- .../pages/cluster/priority_level_config.json | 64 ++++++++++++++--- assets/pages/cluster/pv.json | 64 ++++++++++++++--- assets/pages/cluster/runtime_class.json | 64 ++++++++++++++--- assets/pages/cluster/storage_class.json | 64 ++++++++++++++--- assets/pages/cluster/validation_webhook.json | 64 ++++++++++++++--- assets/pages/crd/cluster_cr.json | 64 ++++++++++++++--- assets/pages/crd/crd.json | 64 ++++++++++++++--- assets/pages/crd/crontab.json | 64 ++++++++++++++--- assets/pages/crd/namespaced_cr.json | 64 ++++++++++++++--- assets/pages/ns/configmap.json | 64 ++++++++++++++--- assets/pages/ns/cronjob.json | 64 ++++++++++++++--- assets/pages/ns/daemonset.json | 64 ++++++++++++++--- assets/pages/ns/deploy.json | 68 +++++++++++++++---- assets/pages/ns/endpoint.json | 64 ++++++++++++++--- assets/pages/ns/endpointslice.json | 64 ++++++++++++++--- assets/pages/ns/event.json | 64 ++++++++++++++--- assets/pages/ns/hpa.json | 64 ++++++++++++++--- assets/pages/ns/ing.json | 64 ++++++++++++++--- assets/pages/ns/job.json | 64 ++++++++++++++--- assets/pages/ns/lease.json | 64 ++++++++++++++--- assets/pages/ns/limit_range.json | 64 ++++++++++++++--- assets/pages/ns/network_policy.json | 64 ++++++++++++++--- assets/pages/ns/pdb.json | 64 ++++++++++++++--- assets/pages/ns/pod.json | 68 +++++++++++++++---- assets/pages/ns/pvc.json | 64 ++++++++++++++--- assets/pages/ns/rc.json | 64 ++++++++++++++--- assets/pages/ns/replicaset.json | 64 ++++++++++++++--- assets/pages/ns/resource_quota.json | 64 ++++++++++++++--- assets/pages/ns/role.json | 64 ++++++++++++++--- assets/pages/ns/role_binding.json | 64 ++++++++++++++--- assets/pages/ns/secret.json | 64 ++++++++++++++--- assets/pages/ns/service_account.json | 64 ++++++++++++++--- assets/pages/ns/statefulset.json | 64 ++++++++++++++--- 43 files changed, 2283 insertions(+), 477 deletions(-) diff --git a/assets/pages/cluster/api_service.json b/assets/pages/cluster/api_service.json index 854486a..066afe6 100644 --- a/assets/pages/cluster/api_service.json +++ b/assets/pages/cluster/api_service.json @@ -584,18 +584,28 @@ "searchConfig": { "sticky": true }, - "selectFirst": true, "heightAuto": true, "inputClassName": "no-border no-padder mt-1", "source": "get:/k8s/doc/gvk/${apiVersion|base64Encode}/$kind", "onEvent": { "change": { "actions": [ + { + "componentId": "basic", + "actionType": "reload", + "data": { + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" + } + }, { "componentId": "detail", "actionType": "reload", "data": { - "description": "${event.data.item.description}" + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" } } ] @@ -612,11 +622,16 @@ "body": [ { "type": "service", - "api": "post:/k8s/doc/detail", + "id": "basic", "body": [ + { + "type": "tpl", + "tpl": "
属性: ${id}", + "visibleOn": "${id}" + }, { "type": "button", - "label": "${id}-属性用法举例", + "label": "示例", "level": "link", "icon": "fas fa-lightbulb text-warning", "actionType": "drawer", @@ -634,20 +649,47 @@ "kind": "${kind}", "group": "${group}", "version": "${version}", - "id": "${id}" + "field": "${id}" } } ] - } + }, + "visibleOn": "${id}" + }, + { + "type": "tpl", + "tpl": "
类型: ${type}", + "visibleOn": "${type}" }, { "type": "tpl", - "tpl": "属性:${id}[${type}]

描述:${description}

翻译:${translate?translate:''}", - "wrapperComponent": "", - "inline": false + "tpl": "
描述: ${description}", + "visibleOn": "${description}" } - ], - "id": "detail" + ] + }, + { + "type": "service", + "id": "detail", + "api": "post:/k8s/doc/detail", + "body": [ + { + "type": "divider", + "title": "描述翻译", + "titlePosition": "center", + "visibleOn": "${translate}" + }, + { + "type": "markdown", + "value": "${translate|raw}", + "options": { + "linkify": true, + "html": true, + "breaks": true + }, + "visibleOn": "${translate}" + } + ] } ] } diff --git a/assets/pages/cluster/cluster_role.json b/assets/pages/cluster/cluster_role.json index 51b843c..bc96210 100644 --- a/assets/pages/cluster/cluster_role.json +++ b/assets/pages/cluster/cluster_role.json @@ -584,18 +584,28 @@ "searchConfig": { "sticky": true }, - "selectFirst": true, "heightAuto": true, "inputClassName": "no-border no-padder mt-1", "source": "get:/k8s/doc/gvk/${apiVersion|base64Encode}/$kind", "onEvent": { "change": { "actions": [ + { + "componentId": "basic", + "actionType": "reload", + "data": { + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" + } + }, { "componentId": "detail", "actionType": "reload", "data": { - "description": "${event.data.item.description}" + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" } } ] @@ -612,11 +622,16 @@ "body": [ { "type": "service", - "api": "post:/k8s/doc/detail", + "id": "basic", "body": [ + { + "type": "tpl", + "tpl": "
属性: ${id}", + "visibleOn": "${id}" + }, { "type": "button", - "label": "${id}-属性用法举例", + "label": "示例", "level": "link", "icon": "fas fa-lightbulb text-warning", "actionType": "drawer", @@ -634,20 +649,47 @@ "kind": "${kind}", "group": "${group}", "version": "${version}", - "id": "${id}" + "field": "${id}" } } ] - } + }, + "visibleOn": "${id}" + }, + { + "type": "tpl", + "tpl": "
类型: ${type}", + "visibleOn": "${type}" }, { "type": "tpl", - "tpl": "属性:${id}[${type}]

描述:${description}

翻译:${translate?translate:''}", - "wrapperComponent": "", - "inline": false + "tpl": "
描述: ${description}", + "visibleOn": "${description}" } - ], - "id": "detail" + ] + }, + { + "type": "service", + "id": "detail", + "api": "post:/k8s/doc/detail", + "body": [ + { + "type": "divider", + "title": "描述翻译", + "titlePosition": "center", + "visibleOn": "${translate}" + }, + { + "type": "markdown", + "value": "${translate|raw}", + "options": { + "linkify": true, + "html": true, + "breaks": true + }, + "visibleOn": "${translate}" + } + ] } ] } diff --git a/assets/pages/cluster/cluster_role_binding.json b/assets/pages/cluster/cluster_role_binding.json index 776f8b7..2699efe 100644 --- a/assets/pages/cluster/cluster_role_binding.json +++ b/assets/pages/cluster/cluster_role_binding.json @@ -584,18 +584,28 @@ "searchConfig": { "sticky": true }, - "selectFirst": true, "heightAuto": true, "inputClassName": "no-border no-padder mt-1", "source": "get:/k8s/doc/gvk/${apiVersion|base64Encode}/$kind", "onEvent": { "change": { "actions": [ + { + "componentId": "basic", + "actionType": "reload", + "data": { + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" + } + }, { "componentId": "detail", "actionType": "reload", "data": { - "description": "${event.data.item.description}" + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" } } ] @@ -612,11 +622,16 @@ "body": [ { "type": "service", - "api": "post:/k8s/doc/detail", + "id": "basic", "body": [ + { + "type": "tpl", + "tpl": "
属性: ${id}", + "visibleOn": "${id}" + }, { "type": "button", - "label": "${id}-属性用法举例", + "label": "示例", "level": "link", "icon": "fas fa-lightbulb text-warning", "actionType": "drawer", @@ -634,20 +649,47 @@ "kind": "${kind}", "group": "${group}", "version": "${version}", - "id": "${id}" + "field": "${id}" } } ] - } + }, + "visibleOn": "${id}" + }, + { + "type": "tpl", + "tpl": "
类型: ${type}", + "visibleOn": "${type}" }, { "type": "tpl", - "tpl": "属性:${id}[${type}]

描述:${description}

翻译:${translate?translate:''}", - "wrapperComponent": "", - "inline": false + "tpl": "
描述: ${description}", + "visibleOn": "${description}" } - ], - "id": "detail" + ] + }, + { + "type": "service", + "id": "detail", + "api": "post:/k8s/doc/detail", + "body": [ + { + "type": "divider", + "title": "描述翻译", + "titlePosition": "center", + "visibleOn": "${translate}" + }, + { + "type": "markdown", + "value": "${translate|raw}", + "options": { + "linkify": true, + "html": true, + "breaks": true + }, + "visibleOn": "${translate}" + } + ] } ] } diff --git a/assets/pages/cluster/csi_node.json b/assets/pages/cluster/csi_node.json index 703a9e1..0de187b 100644 --- a/assets/pages/cluster/csi_node.json +++ b/assets/pages/cluster/csi_node.json @@ -584,18 +584,28 @@ "searchConfig": { "sticky": true }, - "selectFirst": true, "heightAuto": true, "inputClassName": "no-border no-padder mt-1", "source": "get:/k8s/doc/gvk/${apiVersion|base64Encode}/$kind", "onEvent": { "change": { "actions": [ + { + "componentId": "basic", + "actionType": "reload", + "data": { + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" + } + }, { "componentId": "detail", "actionType": "reload", "data": { - "description": "${event.data.item.description}" + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" } } ] @@ -612,11 +622,16 @@ "body": [ { "type": "service", - "api": "post:/k8s/doc/detail", + "id": "basic", "body": [ + { + "type": "tpl", + "tpl": "
属性: ${id}", + "visibleOn": "${id}" + }, { "type": "button", - "label": "${id}-属性用法举例", + "label": "示例", "level": "link", "icon": "fas fa-lightbulb text-warning", "actionType": "drawer", @@ -634,20 +649,47 @@ "kind": "${kind}", "group": "${group}", "version": "${version}", - "id": "${id}" + "field": "${id}" } } ] - } + }, + "visibleOn": "${id}" + }, + { + "type": "tpl", + "tpl": "
类型: ${type}", + "visibleOn": "${type}" }, { "type": "tpl", - "tpl": "属性:${id}[${type}]

描述:${description}

翻译:${translate?translate:''}", - "wrapperComponent": "", - "inline": false + "tpl": "
描述: ${description}", + "visibleOn": "${description}" } - ], - "id": "detail" + ] + }, + { + "type": "service", + "id": "detail", + "api": "post:/k8s/doc/detail", + "body": [ + { + "type": "divider", + "title": "描述翻译", + "titlePosition": "center", + "visibleOn": "${translate}" + }, + { + "type": "markdown", + "value": "${translate|raw}", + "options": { + "linkify": true, + "html": true, + "breaks": true + }, + "visibleOn": "${translate}" + } + ] } ] } diff --git a/assets/pages/cluster/flow_schema.json b/assets/pages/cluster/flow_schema.json index 8980348..dc1f1fe 100644 --- a/assets/pages/cluster/flow_schema.json +++ b/assets/pages/cluster/flow_schema.json @@ -584,18 +584,28 @@ "searchConfig": { "sticky": true }, - "selectFirst": true, "heightAuto": true, "inputClassName": "no-border no-padder mt-1", "source": "get:/k8s/doc/gvk/${apiVersion|base64Encode}/$kind", "onEvent": { "change": { "actions": [ + { + "componentId": "basic", + "actionType": "reload", + "data": { + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" + } + }, { "componentId": "detail", "actionType": "reload", "data": { - "description": "${event.data.item.description}" + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" } } ] @@ -612,11 +622,16 @@ "body": [ { "type": "service", - "api": "post:/k8s/doc/detail", + "id": "basic", "body": [ + { + "type": "tpl", + "tpl": "
属性: ${id}", + "visibleOn": "${id}" + }, { "type": "button", - "label": "${id}-属性用法举例", + "label": "示例", "level": "link", "icon": "fas fa-lightbulb text-warning", "actionType": "drawer", @@ -634,20 +649,47 @@ "kind": "${kind}", "group": "${group}", "version": "${version}", - "id": "${id}" + "field": "${id}" } } ] - } + }, + "visibleOn": "${id}" + }, + { + "type": "tpl", + "tpl": "
类型: ${type}", + "visibleOn": "${type}" }, { "type": "tpl", - "tpl": "属性:${id}[${type}]

描述:${description}

翻译:${translate?translate:''}", - "wrapperComponent": "", - "inline": false + "tpl": "
描述: ${description}", + "visibleOn": "${description}" } - ], - "id": "detail" + ] + }, + { + "type": "service", + "id": "detail", + "api": "post:/k8s/doc/detail", + "body": [ + { + "type": "divider", + "title": "描述翻译", + "titlePosition": "center", + "visibleOn": "${translate}" + }, + { + "type": "markdown", + "value": "${translate|raw}", + "options": { + "linkify": true, + "html": true, + "breaks": true + }, + "visibleOn": "${translate}" + } + ] } ] } diff --git a/assets/pages/cluster/ingress_class.json b/assets/pages/cluster/ingress_class.json index 3316bc3..c24249e 100644 --- a/assets/pages/cluster/ingress_class.json +++ b/assets/pages/cluster/ingress_class.json @@ -584,18 +584,28 @@ "searchConfig": { "sticky": true }, - "selectFirst": true, "heightAuto": true, "inputClassName": "no-border no-padder mt-1", "source": "get:/k8s/doc/gvk/${apiVersion|base64Encode}/$kind", "onEvent": { "change": { "actions": [ + { + "componentId": "basic", + "actionType": "reload", + "data": { + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" + } + }, { "componentId": "detail", "actionType": "reload", "data": { - "description": "${event.data.item.description}" + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" } } ] @@ -612,11 +622,16 @@ "body": [ { "type": "service", - "api": "post:/k8s/doc/detail", + "id": "basic", "body": [ + { + "type": "tpl", + "tpl": "
属性: ${id}", + "visibleOn": "${id}" + }, { "type": "button", - "label": "${id}-属性用法举例", + "label": "示例", "level": "link", "icon": "fas fa-lightbulb text-warning", "actionType": "drawer", @@ -634,20 +649,47 @@ "kind": "${kind}", "group": "${group}", "version": "${version}", - "id": "${id}" + "field": "${id}" } } ] - } + }, + "visibleOn": "${id}" + }, + { + "type": "tpl", + "tpl": "
类型: ${type}", + "visibleOn": "${type}" }, { "type": "tpl", - "tpl": "属性:${id}[${type}]

描述:${description}

翻译:${translate?translate:''}", - "wrapperComponent": "", - "inline": false + "tpl": "
描述: ${description}", + "visibleOn": "${description}" } - ], - "id": "detail" + ] + }, + { + "type": "service", + "id": "detail", + "api": "post:/k8s/doc/detail", + "body": [ + { + "type": "divider", + "title": "描述翻译", + "titlePosition": "center", + "visibleOn": "${translate}" + }, + { + "type": "markdown", + "value": "${translate|raw}", + "options": { + "linkify": true, + "html": true, + "breaks": true + }, + "visibleOn": "${translate}" + } + ] } ] } diff --git a/assets/pages/cluster/mutating_webhook.json b/assets/pages/cluster/mutating_webhook.json index 72c2daa..0e9447d 100644 --- a/assets/pages/cluster/mutating_webhook.json +++ b/assets/pages/cluster/mutating_webhook.json @@ -584,18 +584,28 @@ "searchConfig": { "sticky": true }, - "selectFirst": true, "heightAuto": true, "inputClassName": "no-border no-padder mt-1", "source": "get:/k8s/doc/gvk/${apiVersion|base64Encode}/$kind", "onEvent": { "change": { "actions": [ + { + "componentId": "basic", + "actionType": "reload", + "data": { + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" + } + }, { "componentId": "detail", "actionType": "reload", "data": { - "description": "${event.data.item.description}" + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" } } ] @@ -612,11 +622,16 @@ "body": [ { "type": "service", - "api": "post:/k8s/doc/detail", + "id": "basic", "body": [ + { + "type": "tpl", + "tpl": "
属性: ${id}", + "visibleOn": "${id}" + }, { "type": "button", - "label": "${id}-属性用法举例", + "label": "示例", "level": "link", "icon": "fas fa-lightbulb text-warning", "actionType": "drawer", @@ -634,20 +649,47 @@ "kind": "${kind}", "group": "${group}", "version": "${version}", - "id": "${id}" + "field": "${id}" } } ] - } + }, + "visibleOn": "${id}" + }, + { + "type": "tpl", + "tpl": "
类型: ${type}", + "visibleOn": "${type}" }, { "type": "tpl", - "tpl": "属性:${id}[${type}]

描述:${description}

翻译:${translate?translate:''}", - "wrapperComponent": "", - "inline": false + "tpl": "
描述: ${description}", + "visibleOn": "${description}" } - ], - "id": "detail" + ] + }, + { + "type": "service", + "id": "detail", + "api": "post:/k8s/doc/detail", + "body": [ + { + "type": "divider", + "title": "描述翻译", + "titlePosition": "center", + "visibleOn": "${translate}" + }, + { + "type": "markdown", + "value": "${translate|raw}", + "options": { + "linkify": true, + "html": true, + "breaks": true + }, + "visibleOn": "${translate}" + } + ] } ] } diff --git a/assets/pages/cluster/node.json b/assets/pages/cluster/node.json index bc77171..280f0cb 100644 --- a/assets/pages/cluster/node.json +++ b/assets/pages/cluster/node.json @@ -655,18 +655,28 @@ "searchConfig": { "sticky": true }, - "selectFirst": true, "heightAuto": true, "inputClassName": "no-border no-padder mt-1", "source": "get:/k8s/doc/gvk/${apiVersion|base64Encode}/$kind", "onEvent": { "change": { "actions": [ + { + "componentId": "basic", + "actionType": "reload", + "data": { + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" + } + }, { "componentId": "detail", "actionType": "reload", "data": { - "description": "${event.data.item.description}" + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" } } ] @@ -683,11 +693,16 @@ "body": [ { "type": "service", - "api": "post:/k8s/doc/detail", + "id": "basic", "body": [ + { + "type": "tpl", + "tpl": "
属性: ${id}", + "visibleOn": "${id}" + }, { "type": "button", - "label": "${id}-属性用法举例", + "label": "示例", "level": "link", "icon": "fas fa-lightbulb text-warning", "actionType": "drawer", @@ -705,20 +720,47 @@ "kind": "${kind}", "group": "${group}", "version": "${version}", - "id": "${id}" + "field": "${id}" } } ] - } + }, + "visibleOn": "${id}" + }, + { + "type": "tpl", + "tpl": "
类型: ${type}", + "visibleOn": "${type}" }, { "type": "tpl", - "tpl": "属性:${id}[${type}]

描述:${description}

翻译:${translate?translate:''}", - "wrapperComponent": "", - "inline": false + "tpl": "
描述: ${description}", + "visibleOn": "${description}" } - ], - "id": "detail" + ] + }, + { + "type": "service", + "id": "detail", + "api": "post:/k8s/doc/detail", + "body": [ + { + "type": "divider", + "title": "描述翻译", + "titlePosition": "center", + "visibleOn": "${translate}" + }, + { + "type": "markdown", + "value": "${translate|raw}", + "options": { + "linkify": true, + "html": true, + "breaks": true + }, + "visibleOn": "${translate}" + } + ] } ] } diff --git a/assets/pages/cluster/ns.json b/assets/pages/cluster/ns.json index adf1f3e..9d60637 100644 --- a/assets/pages/cluster/ns.json +++ b/assets/pages/cluster/ns.json @@ -584,18 +584,28 @@ "searchConfig": { "sticky": true }, - "selectFirst": true, "heightAuto": true, "inputClassName": "no-border no-padder mt-1", "source": "get:/k8s/doc/gvk/${apiVersion|base64Encode}/$kind", "onEvent": { "change": { "actions": [ + { + "componentId": "basic", + "actionType": "reload", + "data": { + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" + } + }, { "componentId": "detail", "actionType": "reload", "data": { - "description": "${event.data.item.description}" + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" } } ] @@ -612,11 +622,16 @@ "body": [ { "type": "service", - "api": "post:/k8s/doc/detail", + "id": "basic", "body": [ + { + "type": "tpl", + "tpl": "
属性: ${id}", + "visibleOn": "${id}" + }, { "type": "button", - "label": "${id}-属性用法举例", + "label": "示例", "level": "link", "icon": "fas fa-lightbulb text-warning", "actionType": "drawer", @@ -634,20 +649,47 @@ "kind": "${kind}", "group": "${group}", "version": "${version}", - "id": "${id}" + "field": "${id}" } } ] - } + }, + "visibleOn": "${id}" + }, + { + "type": "tpl", + "tpl": "
类型: ${type}", + "visibleOn": "${type}" }, { "type": "tpl", - "tpl": "属性:${id}[${type}]

描述:${description}

翻译:${translate?translate:''}", - "wrapperComponent": "", - "inline": false + "tpl": "
描述: ${description}", + "visibleOn": "${description}" } - ], - "id": "detail" + ] + }, + { + "type": "service", + "id": "detail", + "api": "post:/k8s/doc/detail", + "body": [ + { + "type": "divider", + "title": "描述翻译", + "titlePosition": "center", + "visibleOn": "${translate}" + }, + { + "type": "markdown", + "value": "${translate|raw}", + "options": { + "linkify": true, + "html": true, + "breaks": true + }, + "visibleOn": "${translate}" + } + ] } ] } diff --git a/assets/pages/cluster/priority_class.json b/assets/pages/cluster/priority_class.json index c16e7e9..98c74ac 100644 --- a/assets/pages/cluster/priority_class.json +++ b/assets/pages/cluster/priority_class.json @@ -584,18 +584,28 @@ "searchConfig": { "sticky": true }, - "selectFirst": true, "heightAuto": true, "inputClassName": "no-border no-padder mt-1", "source": "get:/k8s/doc/gvk/${apiVersion|base64Encode}/$kind", "onEvent": { "change": { "actions": [ + { + "componentId": "basic", + "actionType": "reload", + "data": { + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" + } + }, { "componentId": "detail", "actionType": "reload", "data": { - "description": "${event.data.item.description}" + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" } } ] @@ -612,11 +622,16 @@ "body": [ { "type": "service", - "api": "post:/k8s/doc/detail", + "id": "basic", "body": [ + { + "type": "tpl", + "tpl": "
属性: ${id}", + "visibleOn": "${id}" + }, { "type": "button", - "label": "${id}-属性用法举例", + "label": "示例", "level": "link", "icon": "fas fa-lightbulb text-warning", "actionType": "drawer", @@ -634,20 +649,47 @@ "kind": "${kind}", "group": "${group}", "version": "${version}", - "id": "${id}" + "field": "${id}" } } ] - } + }, + "visibleOn": "${id}" + }, + { + "type": "tpl", + "tpl": "
类型: ${type}", + "visibleOn": "${type}" }, { "type": "tpl", - "tpl": "属性:${id}[${type}]

描述:${description}

翻译:${translate?translate:''}", - "wrapperComponent": "", - "inline": false + "tpl": "
描述: ${description}", + "visibleOn": "${description}" } - ], - "id": "detail" + ] + }, + { + "type": "service", + "id": "detail", + "api": "post:/k8s/doc/detail", + "body": [ + { + "type": "divider", + "title": "描述翻译", + "titlePosition": "center", + "visibleOn": "${translate}" + }, + { + "type": "markdown", + "value": "${translate|raw}", + "options": { + "linkify": true, + "html": true, + "breaks": true + }, + "visibleOn": "${translate}" + } + ] } ] } diff --git a/assets/pages/cluster/priority_level_config.json b/assets/pages/cluster/priority_level_config.json index daf48a5..225cbfc 100644 --- a/assets/pages/cluster/priority_level_config.json +++ b/assets/pages/cluster/priority_level_config.json @@ -584,18 +584,28 @@ "searchConfig": { "sticky": true }, - "selectFirst": true, "heightAuto": true, "inputClassName": "no-border no-padder mt-1", "source": "get:/k8s/doc/gvk/${apiVersion|base64Encode}/$kind", "onEvent": { "change": { "actions": [ + { + "componentId": "basic", + "actionType": "reload", + "data": { + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" + } + }, { "componentId": "detail", "actionType": "reload", "data": { - "description": "${event.data.item.description}" + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" } } ] @@ -612,11 +622,16 @@ "body": [ { "type": "service", - "api": "post:/k8s/doc/detail", + "id": "basic", "body": [ + { + "type": "tpl", + "tpl": "
属性: ${id}", + "visibleOn": "${id}" + }, { "type": "button", - "label": "${id}-属性用法举例", + "label": "示例", "level": "link", "icon": "fas fa-lightbulb text-warning", "actionType": "drawer", @@ -634,20 +649,47 @@ "kind": "${kind}", "group": "${group}", "version": "${version}", - "id": "${id}" + "field": "${id}" } } ] - } + }, + "visibleOn": "${id}" + }, + { + "type": "tpl", + "tpl": "
类型: ${type}", + "visibleOn": "${type}" }, { "type": "tpl", - "tpl": "属性:${id}[${type}]

描述:${description}

翻译:${translate?translate:''}", - "wrapperComponent": "", - "inline": false + "tpl": "
描述: ${description}", + "visibleOn": "${description}" } - ], - "id": "detail" + ] + }, + { + "type": "service", + "id": "detail", + "api": "post:/k8s/doc/detail", + "body": [ + { + "type": "divider", + "title": "描述翻译", + "titlePosition": "center", + "visibleOn": "${translate}" + }, + { + "type": "markdown", + "value": "${translate|raw}", + "options": { + "linkify": true, + "html": true, + "breaks": true + }, + "visibleOn": "${translate}" + } + ] } ] } diff --git a/assets/pages/cluster/pv.json b/assets/pages/cluster/pv.json index a116835..d7c2498 100644 --- a/assets/pages/cluster/pv.json +++ b/assets/pages/cluster/pv.json @@ -584,18 +584,28 @@ "searchConfig": { "sticky": true }, - "selectFirst": true, "heightAuto": true, "inputClassName": "no-border no-padder mt-1", "source": "get:/k8s/doc/gvk/${apiVersion|base64Encode}/$kind", "onEvent": { "change": { "actions": [ + { + "componentId": "basic", + "actionType": "reload", + "data": { + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" + } + }, { "componentId": "detail", "actionType": "reload", "data": { - "description": "${event.data.item.description}" + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" } } ] @@ -612,11 +622,16 @@ "body": [ { "type": "service", - "api": "post:/k8s/doc/detail", + "id": "basic", "body": [ + { + "type": "tpl", + "tpl": "
属性: ${id}", + "visibleOn": "${id}" + }, { "type": "button", - "label": "${id}-属性用法举例", + "label": "示例", "level": "link", "icon": "fas fa-lightbulb text-warning", "actionType": "drawer", @@ -634,20 +649,47 @@ "kind": "${kind}", "group": "${group}", "version": "${version}", - "id": "${id}" + "field": "${id}" } } ] - } + }, + "visibleOn": "${id}" + }, + { + "type": "tpl", + "tpl": "
类型: ${type}", + "visibleOn": "${type}" }, { "type": "tpl", - "tpl": "属性:${id}[${type}]

描述:${description}

翻译:${translate?translate:''}", - "wrapperComponent": "", - "inline": false + "tpl": "
描述: ${description}", + "visibleOn": "${description}" } - ], - "id": "detail" + ] + }, + { + "type": "service", + "id": "detail", + "api": "post:/k8s/doc/detail", + "body": [ + { + "type": "divider", + "title": "描述翻译", + "titlePosition": "center", + "visibleOn": "${translate}" + }, + { + "type": "markdown", + "value": "${translate|raw}", + "options": { + "linkify": true, + "html": true, + "breaks": true + }, + "visibleOn": "${translate}" + } + ] } ] } diff --git a/assets/pages/cluster/runtime_class.json b/assets/pages/cluster/runtime_class.json index afa73bb..c24a944 100644 --- a/assets/pages/cluster/runtime_class.json +++ b/assets/pages/cluster/runtime_class.json @@ -584,18 +584,28 @@ "searchConfig": { "sticky": true }, - "selectFirst": true, "heightAuto": true, "inputClassName": "no-border no-padder mt-1", "source": "get:/k8s/doc/gvk/${apiVersion|base64Encode}/$kind", "onEvent": { "change": { "actions": [ + { + "componentId": "basic", + "actionType": "reload", + "data": { + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" + } + }, { "componentId": "detail", "actionType": "reload", "data": { - "description": "${event.data.item.description}" + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" } } ] @@ -612,11 +622,16 @@ "body": [ { "type": "service", - "api": "post:/k8s/doc/detail", + "id": "basic", "body": [ + { + "type": "tpl", + "tpl": "
属性: ${id}", + "visibleOn": "${id}" + }, { "type": "button", - "label": "${id}-属性用法举例", + "label": "示例", "level": "link", "icon": "fas fa-lightbulb text-warning", "actionType": "drawer", @@ -634,20 +649,47 @@ "kind": "${kind}", "group": "${group}", "version": "${version}", - "id": "${id}" + "field": "${id}" } } ] - } + }, + "visibleOn": "${id}" + }, + { + "type": "tpl", + "tpl": "
类型: ${type}", + "visibleOn": "${type}" }, { "type": "tpl", - "tpl": "属性:${id}[${type}]

描述:${description}

翻译:${translate?translate:''}", - "wrapperComponent": "", - "inline": false + "tpl": "
描述: ${description}", + "visibleOn": "${description}" } - ], - "id": "detail" + ] + }, + { + "type": "service", + "id": "detail", + "api": "post:/k8s/doc/detail", + "body": [ + { + "type": "divider", + "title": "描述翻译", + "titlePosition": "center", + "visibleOn": "${translate}" + }, + { + "type": "markdown", + "value": "${translate|raw}", + "options": { + "linkify": true, + "html": true, + "breaks": true + }, + "visibleOn": "${translate}" + } + ] } ] } diff --git a/assets/pages/cluster/storage_class.json b/assets/pages/cluster/storage_class.json index 3ddea23..a95458a 100644 --- a/assets/pages/cluster/storage_class.json +++ b/assets/pages/cluster/storage_class.json @@ -584,18 +584,28 @@ "searchConfig": { "sticky": true }, - "selectFirst": true, "heightAuto": true, "inputClassName": "no-border no-padder mt-1", "source": "get:/k8s/doc/gvk/${apiVersion|base64Encode}/$kind", "onEvent": { "change": { "actions": [ + { + "componentId": "basic", + "actionType": "reload", + "data": { + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" + } + }, { "componentId": "detail", "actionType": "reload", "data": { - "description": "${event.data.item.description}" + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" } } ] @@ -612,11 +622,16 @@ "body": [ { "type": "service", - "api": "post:/k8s/doc/detail", + "id": "basic", "body": [ + { + "type": "tpl", + "tpl": "
属性: ${id}", + "visibleOn": "${id}" + }, { "type": "button", - "label": "${id}-属性用法举例", + "label": "示例", "level": "link", "icon": "fas fa-lightbulb text-warning", "actionType": "drawer", @@ -634,20 +649,47 @@ "kind": "${kind}", "group": "${group}", "version": "${version}", - "id": "${id}" + "field": "${id}" } } ] - } + }, + "visibleOn": "${id}" + }, + { + "type": "tpl", + "tpl": "
类型: ${type}", + "visibleOn": "${type}" }, { "type": "tpl", - "tpl": "属性:${id}[${type}]

描述:${description}

翻译:${translate?translate:''}", - "wrapperComponent": "", - "inline": false + "tpl": "
描述: ${description}", + "visibleOn": "${description}" } - ], - "id": "detail" + ] + }, + { + "type": "service", + "id": "detail", + "api": "post:/k8s/doc/detail", + "body": [ + { + "type": "divider", + "title": "描述翻译", + "titlePosition": "center", + "visibleOn": "${translate}" + }, + { + "type": "markdown", + "value": "${translate|raw}", + "options": { + "linkify": true, + "html": true, + "breaks": true + }, + "visibleOn": "${translate}" + } + ] } ] } diff --git a/assets/pages/cluster/validation_webhook.json b/assets/pages/cluster/validation_webhook.json index 69478c9..727d8cb 100644 --- a/assets/pages/cluster/validation_webhook.json +++ b/assets/pages/cluster/validation_webhook.json @@ -584,18 +584,28 @@ "searchConfig": { "sticky": true }, - "selectFirst": true, "heightAuto": true, "inputClassName": "no-border no-padder mt-1", "source": "get:/k8s/doc/gvk/${apiVersion|base64Encode}/$kind", "onEvent": { "change": { "actions": [ + { + "componentId": "basic", + "actionType": "reload", + "data": { + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" + } + }, { "componentId": "detail", "actionType": "reload", "data": { - "description": "${event.data.item.description}" + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" } } ] @@ -612,11 +622,16 @@ "body": [ { "type": "service", - "api": "post:/k8s/doc/detail", + "id": "basic", "body": [ + { + "type": "tpl", + "tpl": "
属性: ${id}", + "visibleOn": "${id}" + }, { "type": "button", - "label": "${id}-属性用法举例", + "label": "示例", "level": "link", "icon": "fas fa-lightbulb text-warning", "actionType": "drawer", @@ -634,20 +649,47 @@ "kind": "${kind}", "group": "${group}", "version": "${version}", - "id": "${id}" + "field": "${id}" } } ] - } + }, + "visibleOn": "${id}" + }, + { + "type": "tpl", + "tpl": "
类型: ${type}", + "visibleOn": "${type}" }, { "type": "tpl", - "tpl": "属性:${id}[${type}]

描述:${description}

翻译:${translate?translate:''}", - "wrapperComponent": "", - "inline": false + "tpl": "
描述: ${description}", + "visibleOn": "${description}" } - ], - "id": "detail" + ] + }, + { + "type": "service", + "id": "detail", + "api": "post:/k8s/doc/detail", + "body": [ + { + "type": "divider", + "title": "描述翻译", + "titlePosition": "center", + "visibleOn": "${translate}" + }, + { + "type": "markdown", + "value": "${translate|raw}", + "options": { + "linkify": true, + "html": true, + "breaks": true + }, + "visibleOn": "${translate}" + } + ] } ] } diff --git a/assets/pages/crd/cluster_cr.json b/assets/pages/crd/cluster_cr.json index 50052c1..d3ea24a 100644 --- a/assets/pages/crd/cluster_cr.json +++ b/assets/pages/crd/cluster_cr.json @@ -598,18 +598,28 @@ "searchConfig": { "sticky": true }, - "selectFirst": true, "heightAuto": true, "inputClassName": "no-border no-padder mt-1", "source": "get:/k8s/doc/gvk/${apiVersion|base64Encode}/$kind", "onEvent": { "change": { "actions": [ + { + "componentId": "basic", + "actionType": "reload", + "data": { + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" + } + }, { "componentId": "detail", "actionType": "reload", "data": { - "description": "${event.data.item.description}" + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" } } ] @@ -626,11 +636,16 @@ "body": [ { "type": "service", - "api": "post:/k8s/doc/detail", + "id": "basic", "body": [ + { + "type": "tpl", + "tpl": "
属性: ${id}", + "visibleOn": "${id}" + }, { "type": "button", - "label": "${id}-属性用法举例", + "label": "示例", "level": "link", "icon": "fas fa-lightbulb text-warning", "actionType": "drawer", @@ -648,20 +663,47 @@ "kind": "${kind}", "group": "${group}", "version": "${version}", - "id": "${id}" + "field": "${id}" } } ] - } + }, + "visibleOn": "${id}" + }, + { + "type": "tpl", + "tpl": "
类型: ${type}", + "visibleOn": "${type}" }, { "type": "tpl", - "tpl": "属性:${id}[${type}]

描述:${description}

翻译:${translate?translate:''}", - "wrapperComponent": "", - "inline": false + "tpl": "
描述: ${description}", + "visibleOn": "${description}" } - ], - "id": "detail" + ] + }, + { + "type": "service", + "id": "detail", + "api": "post:/k8s/doc/detail", + "body": [ + { + "type": "divider", + "title": "描述翻译", + "titlePosition": "center", + "visibleOn": "${translate}" + }, + { + "type": "markdown", + "value": "${translate|raw}", + "options": { + "linkify": true, + "html": true, + "breaks": true + }, + "visibleOn": "${translate}" + } + ] } ] } diff --git a/assets/pages/crd/crd.json b/assets/pages/crd/crd.json index 28d3330..ac932e1 100644 --- a/assets/pages/crd/crd.json +++ b/assets/pages/crd/crd.json @@ -584,18 +584,28 @@ "searchConfig": { "sticky": true }, - "selectFirst": true, "heightAuto": true, "inputClassName": "no-border no-padder mt-1", "source": "get:/k8s/doc/gvk/${apiVersion|base64Encode}/$kind", "onEvent": { "change": { "actions": [ + { + "componentId": "basic", + "actionType": "reload", + "data": { + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" + } + }, { "componentId": "detail", "actionType": "reload", "data": { - "description": "${event.data.item.description}" + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" } } ] @@ -612,11 +622,16 @@ "body": [ { "type": "service", - "api": "post:/k8s/doc/detail", + "id": "basic", "body": [ + { + "type": "tpl", + "tpl": "
属性: ${id}", + "visibleOn": "${id}" + }, { "type": "button", - "label": "${id}-属性用法举例", + "label": "示例", "level": "link", "icon": "fas fa-lightbulb text-warning", "actionType": "drawer", @@ -634,20 +649,47 @@ "kind": "${kind}", "group": "${group}", "version": "${version}", - "id": "${id}" + "field": "${id}" } } ] - } + }, + "visibleOn": "${id}" + }, + { + "type": "tpl", + "tpl": "
类型: ${type}", + "visibleOn": "${type}" }, { "type": "tpl", - "tpl": "属性:${id}[${type}]

描述:${description}

翻译:${translate?translate:''}", - "wrapperComponent": "", - "inline": false + "tpl": "
描述: ${description}", + "visibleOn": "${description}" } - ], - "id": "detail" + ] + }, + { + "type": "service", + "id": "detail", + "api": "post:/k8s/doc/detail", + "body": [ + { + "type": "divider", + "title": "描述翻译", + "titlePosition": "center", + "visibleOn": "${translate}" + }, + { + "type": "markdown", + "value": "${translate|raw}", + "options": { + "linkify": true, + "html": true, + "breaks": true + }, + "visibleOn": "${translate}" + } + ] } ] } diff --git a/assets/pages/crd/crontab.json b/assets/pages/crd/crontab.json index 5b89cee..e6d8155 100644 --- a/assets/pages/crd/crontab.json +++ b/assets/pages/crd/crontab.json @@ -637,18 +637,28 @@ "searchConfig": { "sticky": true }, - "selectFirst": true, "heightAuto": true, "inputClassName": "no-border no-padder mt-1", "source": "get:/k8s/doc/gvk/${apiVersion|base64Encode}/$kind", "onEvent": { "change": { "actions": [ + { + "componentId": "basic", + "actionType": "reload", + "data": { + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" + } + }, { "componentId": "detail", "actionType": "reload", "data": { - "description": "${event.data.item.description}" + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" } } ] @@ -665,11 +675,16 @@ "body": [ { "type": "service", - "api": "post:/k8s/doc/detail", + "id": "basic", "body": [ + { + "type": "tpl", + "tpl": "
属性: ${id}", + "visibleOn": "${id}" + }, { "type": "button", - "label": "${id}-属性用法举例", + "label": "示例", "level": "link", "icon": "fas fa-lightbulb text-warning", "actionType": "drawer", @@ -687,20 +702,47 @@ "kind": "${kind}", "group": "${group}", "version": "${version}", - "id": "${id}" + "field": "${id}" } } ] - } + }, + "visibleOn": "${id}" + }, + { + "type": "tpl", + "tpl": "
类型: ${type}", + "visibleOn": "${type}" }, { "type": "tpl", - "tpl": "属性:${id}[${type}]

描述:${description}

翻译:${translate?translate:''}", - "wrapperComponent": "", - "inline": false + "tpl": "
描述: ${description}", + "visibleOn": "${description}" } - ], - "id": "detail" + ] + }, + { + "type": "service", + "id": "detail", + "api": "post:/k8s/doc/detail", + "body": [ + { + "type": "divider", + "title": "描述翻译", + "titlePosition": "center", + "visibleOn": "${translate}" + }, + { + "type": "markdown", + "value": "${translate|raw}", + "options": { + "linkify": true, + "html": true, + "breaks": true + }, + "visibleOn": "${translate}" + } + ] } ] } diff --git a/assets/pages/crd/namespaced_cr.json b/assets/pages/crd/namespaced_cr.json index aacffd1..880a770 100644 --- a/assets/pages/crd/namespaced_cr.json +++ b/assets/pages/crd/namespaced_cr.json @@ -633,18 +633,28 @@ "searchConfig": { "sticky": true }, - "selectFirst": true, "heightAuto": true, "inputClassName": "no-border no-padder mt-1", "source": "get:/k8s/doc/gvk/${apiVersion|base64Encode}/$kind", "onEvent": { "change": { "actions": [ + { + "componentId": "basic", + "actionType": "reload", + "data": { + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" + } + }, { "componentId": "detail", "actionType": "reload", "data": { - "description": "${event.data.item.description}" + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" } } ] @@ -661,11 +671,16 @@ "body": [ { "type": "service", - "api": "post:/k8s/doc/detail", + "id": "basic", "body": [ + { + "type": "tpl", + "tpl": "
属性: ${id}", + "visibleOn": "${id}" + }, { "type": "button", - "label": "${id}-属性用法举例", + "label": "示例", "level": "link", "icon": "fas fa-lightbulb text-warning", "actionType": "drawer", @@ -683,20 +698,47 @@ "kind": "${kind}", "group": "${group}", "version": "${version}", - "id": "${id}" + "field": "${id}" } } ] - } + }, + "visibleOn": "${id}" + }, + { + "type": "tpl", + "tpl": "
类型: ${type}", + "visibleOn": "${type}" }, { "type": "tpl", - "tpl": "属性:${id}[${type}]

描述:${description}

翻译:${translate?translate:''}", - "wrapperComponent": "", - "inline": false + "tpl": "
描述: ${description}", + "visibleOn": "${description}" } - ], - "id": "detail" + ] + }, + { + "type": "service", + "id": "detail", + "api": "post:/k8s/doc/detail", + "body": [ + { + "type": "divider", + "title": "描述翻译", + "titlePosition": "center", + "visibleOn": "${translate}" + }, + { + "type": "markdown", + "value": "${translate|raw}", + "options": { + "linkify": true, + "html": true, + "breaks": true + }, + "visibleOn": "${translate}" + } + ] } ] } diff --git a/assets/pages/ns/configmap.json b/assets/pages/ns/configmap.json index 2574368..7361dff 100644 --- a/assets/pages/ns/configmap.json +++ b/assets/pages/ns/configmap.json @@ -634,18 +634,28 @@ "searchConfig": { "sticky": true }, - "selectFirst": true, "heightAuto": true, "inputClassName": "no-border no-padder mt-1", "source": "get:/k8s/doc/gvk/${apiVersion|base64Encode}/$kind", "onEvent": { "change": { "actions": [ + { + "componentId": "basic", + "actionType": "reload", + "data": { + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" + } + }, { "componentId": "detail", "actionType": "reload", "data": { - "description": "${event.data.item.description}" + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" } } ] @@ -662,11 +672,16 @@ "body": [ { "type": "service", - "api": "post:/k8s/doc/detail", + "id": "basic", "body": [ + { + "type": "tpl", + "tpl": "
属性: ${id}", + "visibleOn": "${id}" + }, { "type": "button", - "label": "${id}-属性用法举例", + "label": "示例", "level": "link", "icon": "fas fa-lightbulb text-warning", "actionType": "drawer", @@ -684,20 +699,47 @@ "kind": "${kind}", "group": "${group}", "version": "${version}", - "id": "${id}" + "field": "${id}" } } ] - } + }, + "visibleOn": "${id}" + }, + { + "type": "tpl", + "tpl": "
类型: ${type}", + "visibleOn": "${type}" }, { "type": "tpl", - "tpl": "属性:${id}[${type}]

描述:${description}

翻译:${translate?translate:''}", - "wrapperComponent": "", - "inline": false + "tpl": "
描述: ${description}", + "visibleOn": "${description}" } - ], - "id": "detail" + ] + }, + { + "type": "service", + "id": "detail", + "api": "post:/k8s/doc/detail", + "body": [ + { + "type": "divider", + "title": "描述翻译", + "titlePosition": "center", + "visibleOn": "${translate}" + }, + { + "type": "markdown", + "value": "${translate|raw}", + "options": { + "linkify": true, + "html": true, + "breaks": true + }, + "visibleOn": "${translate}" + } + ] } ] } diff --git a/assets/pages/ns/cronjob.json b/assets/pages/ns/cronjob.json index d4ce692..3d70397 100644 --- a/assets/pages/ns/cronjob.json +++ b/assets/pages/ns/cronjob.json @@ -637,18 +637,28 @@ "searchConfig": { "sticky": true }, - "selectFirst": true, "heightAuto": true, "inputClassName": "no-border no-padder mt-1", "source": "get:/k8s/doc/gvk/${apiVersion|base64Encode}/$kind", "onEvent": { "change": { "actions": [ + { + "componentId": "basic", + "actionType": "reload", + "data": { + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" + } + }, { "componentId": "detail", "actionType": "reload", "data": { - "description": "${event.data.item.description}" + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" } } ] @@ -665,11 +675,16 @@ "body": [ { "type": "service", - "api": "post:/k8s/doc/detail", + "id": "basic", "body": [ + { + "type": "tpl", + "tpl": "
属性: ${id}", + "visibleOn": "${id}" + }, { "type": "button", - "label": "${id}-属性用法举例", + "label": "示例", "level": "link", "icon": "fas fa-lightbulb text-warning", "actionType": "drawer", @@ -687,20 +702,47 @@ "kind": "${kind}", "group": "${group}", "version": "${version}", - "id": "${id}" + "field": "${id}" } } ] - } + }, + "visibleOn": "${id}" + }, + { + "type": "tpl", + "tpl": "
类型: ${type}", + "visibleOn": "${type}" }, { "type": "tpl", - "tpl": "属性:${id}[${type}]

描述:${description}

翻译:${translate?translate:''}", - "wrapperComponent": "", - "inline": false + "tpl": "
描述: ${description}", + "visibleOn": "${description}" } - ], - "id": "detail" + ] + }, + { + "type": "service", + "id": "detail", + "api": "post:/k8s/doc/detail", + "body": [ + { + "type": "divider", + "title": "描述翻译", + "titlePosition": "center", + "visibleOn": "${translate}" + }, + { + "type": "markdown", + "value": "${translate|raw}", + "options": { + "linkify": true, + "html": true, + "breaks": true + }, + "visibleOn": "${translate}" + } + ] } ] } diff --git a/assets/pages/ns/daemonset.json b/assets/pages/ns/daemonset.json index 36fd668..b3436d7 100644 --- a/assets/pages/ns/daemonset.json +++ b/assets/pages/ns/daemonset.json @@ -645,18 +645,28 @@ "searchConfig": { "sticky": true }, - "selectFirst": true, "heightAuto": true, "inputClassName": "no-border no-padder mt-1", "source": "get:/k8s/doc/gvk/${apiVersion|base64Encode}/$kind", "onEvent": { "change": { "actions": [ + { + "componentId": "basic", + "actionType": "reload", + "data": { + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" + } + }, { "componentId": "detail", "actionType": "reload", "data": { - "description": "${event.data.item.description}" + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" } } ] @@ -673,11 +683,16 @@ "body": [ { "type": "service", - "api": "post:/k8s/doc/detail", + "id": "basic", "body": [ + { + "type": "tpl", + "tpl": "
属性: ${id}", + "visibleOn": "${id}" + }, { "type": "button", - "label": "${id}-属性用法举例", + "label": "示例", "level": "link", "icon": "fas fa-lightbulb text-warning", "actionType": "drawer", @@ -695,20 +710,47 @@ "kind": "${kind}", "group": "${group}", "version": "${version}", - "id": "${id}" + "field": "${id}" } } ] - } + }, + "visibleOn": "${id}" + }, + { + "type": "tpl", + "tpl": "
类型: ${type}", + "visibleOn": "${type}" }, { "type": "tpl", - "tpl": "属性:${id}[${type}]

描述:${description}

翻译:${translate?translate:''}", - "wrapperComponent": "", - "inline": false + "tpl": "
描述: ${description}", + "visibleOn": "${description}" } - ], - "id": "detail" + ] + }, + { + "type": "service", + "id": "detail", + "api": "post:/k8s/doc/detail", + "body": [ + { + "type": "divider", + "title": "描述翻译", + "titlePosition": "center", + "visibleOn": "${translate}" + }, + { + "type": "markdown", + "value": "${translate|raw}", + "options": { + "linkify": true, + "html": true, + "breaks": true + }, + "visibleOn": "${translate}" + } + ] } ] } diff --git a/assets/pages/ns/deploy.json b/assets/pages/ns/deploy.json index f31f7ed..4ac941e 100644 --- a/assets/pages/ns/deploy.json +++ b/assets/pages/ns/deploy.json @@ -674,8 +674,8 @@ "type": "page", "asideResizor": true, "asideSticky": false, - "asideMinWidth": 300, - "asideMaxWidth": 600, + "asideMinWidth": 150, + "asideMaxWidth": 400, "aside": [ { "type": "input-tree", @@ -688,18 +688,28 @@ "searchConfig": { "sticky": true }, - "selectFirst": true, "heightAuto": true, "inputClassName": "no-border no-padder mt-1", "source": "get:/k8s/doc/gvk/${apiVersion|base64Encode}/$kind", "onEvent": { "change": { "actions": [ + { + "componentId": "basic", + "actionType": "reload", + "data": { + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" + } + }, { "componentId": "detail", "actionType": "reload", "data": { - "description": "${event.data.item.description}" + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" } } ] @@ -716,11 +726,16 @@ "body": [ { "type": "service", - "api": "post:/k8s/doc/detail", + "id": "basic", "body": [ + { + "type": "tpl", + "tpl": "
属性: ${id}", + "visibleOn": "${id}" + }, { "type": "button", - "label": "${id}-属性用法举例", + "label": "示例", "level": "link", "icon": "fas fa-lightbulb text-warning", "actionType": "drawer", @@ -738,20 +753,47 @@ "kind": "${kind}", "group": "${group}", "version": "${version}", - "id": "${id}" + "field": "${id}" } } ] - } + }, + "visibleOn": "${id}" + }, + { + "type": "tpl", + "tpl": "
类型: ${type}", + "visibleOn": "${type}" }, { "type": "tpl", - "tpl": "属性:${id}[${type}]

描述:${description}

翻译:${translate?translate:''}", - "wrapperComponent": "", - "inline": false + "tpl": "
描述: ${description}", + "visibleOn": "${description}" } - ], - "id": "detail" + ] + }, + { + "type": "service", + "id": "detail", + "api": "post:/k8s/doc/detail", + "body": [ + { + "type": "divider", + "title": "描述翻译", + "titlePosition": "center", + "visibleOn": "${translate}" + }, + { + "type": "markdown", + "value": "${translate|raw}", + "options": { + "linkify": true, + "html": true, + "breaks": true + }, + "visibleOn": "${translate}" + } + ] } ] } diff --git a/assets/pages/ns/endpoint.json b/assets/pages/ns/endpoint.json index 74166ea..b9f7eb9 100644 --- a/assets/pages/ns/endpoint.json +++ b/assets/pages/ns/endpoint.json @@ -637,18 +637,28 @@ "searchConfig": { "sticky": true }, - "selectFirst": true, "heightAuto": true, "inputClassName": "no-border no-padder mt-1", "source": "get:/k8s/doc/gvk/${apiVersion|base64Encode}/$kind", "onEvent": { "change": { "actions": [ + { + "componentId": "basic", + "actionType": "reload", + "data": { + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" + } + }, { "componentId": "detail", "actionType": "reload", "data": { - "description": "${event.data.item.description}" + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" } } ] @@ -665,11 +675,16 @@ "body": [ { "type": "service", - "api": "post:/k8s/doc/detail", + "id": "basic", "body": [ + { + "type": "tpl", + "tpl": "
属性: ${id}", + "visibleOn": "${id}" + }, { "type": "button", - "label": "${id}-属性用法举例", + "label": "示例", "level": "link", "icon": "fas fa-lightbulb text-warning", "actionType": "drawer", @@ -687,20 +702,47 @@ "kind": "${kind}", "group": "${group}", "version": "${version}", - "id": "${id}" + "field": "${id}" } } ] - } + }, + "visibleOn": "${id}" + }, + { + "type": "tpl", + "tpl": "
类型: ${type}", + "visibleOn": "${type}" }, { "type": "tpl", - "tpl": "属性:${id}[${type}]

描述:${description}

翻译:${translate?translate:''}", - "wrapperComponent": "", - "inline": false + "tpl": "
描述: ${description}", + "visibleOn": "${description}" } - ], - "id": "detail" + ] + }, + { + "type": "service", + "id": "detail", + "api": "post:/k8s/doc/detail", + "body": [ + { + "type": "divider", + "title": "描述翻译", + "titlePosition": "center", + "visibleOn": "${translate}" + }, + { + "type": "markdown", + "value": "${translate|raw}", + "options": { + "linkify": true, + "html": true, + "breaks": true + }, + "visibleOn": "${translate}" + } + ] } ] } diff --git a/assets/pages/ns/endpointslice.json b/assets/pages/ns/endpointslice.json index 776e7c8..387c76c 100644 --- a/assets/pages/ns/endpointslice.json +++ b/assets/pages/ns/endpointslice.json @@ -637,18 +637,28 @@ "searchConfig": { "sticky": true }, - "selectFirst": true, "heightAuto": true, "inputClassName": "no-border no-padder mt-1", "source": "get:/k8s/doc/gvk/${apiVersion|base64Encode}/$kind", "onEvent": { "change": { "actions": [ + { + "componentId": "basic", + "actionType": "reload", + "data": { + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" + } + }, { "componentId": "detail", "actionType": "reload", "data": { - "description": "${event.data.item.description}" + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" } } ] @@ -665,11 +675,16 @@ "body": [ { "type": "service", - "api": "post:/k8s/doc/detail", + "id": "basic", "body": [ + { + "type": "tpl", + "tpl": "
属性: ${id}", + "visibleOn": "${id}" + }, { "type": "button", - "label": "${id}-属性用法举例", + "label": "示例", "level": "link", "icon": "fas fa-lightbulb text-warning", "actionType": "drawer", @@ -687,20 +702,47 @@ "kind": "${kind}", "group": "${group}", "version": "${version}", - "id": "${id}" + "field": "${id}" } } ] - } + }, + "visibleOn": "${id}" + }, + { + "type": "tpl", + "tpl": "
类型: ${type}", + "visibleOn": "${type}" }, { "type": "tpl", - "tpl": "属性:${id}[${type}]

描述:${description}

翻译:${translate?translate:''}", - "wrapperComponent": "", - "inline": false + "tpl": "
描述: ${description}", + "visibleOn": "${description}" } - ], - "id": "detail" + ] + }, + { + "type": "service", + "id": "detail", + "api": "post:/k8s/doc/detail", + "body": [ + { + "type": "divider", + "title": "描述翻译", + "titlePosition": "center", + "visibleOn": "${translate}" + }, + { + "type": "markdown", + "value": "${translate|raw}", + "options": { + "linkify": true, + "html": true, + "breaks": true + }, + "visibleOn": "${translate}" + } + ] } ] } diff --git a/assets/pages/ns/event.json b/assets/pages/ns/event.json index a042e57..cb7496e 100644 --- a/assets/pages/ns/event.json +++ b/assets/pages/ns/event.json @@ -650,18 +650,28 @@ "searchConfig": { "sticky": true }, - "selectFirst": true, "heightAuto": true, "inputClassName": "no-border no-padder mt-1", "source": "get:/k8s/doc/gvk/${apiVersion|base64Encode}/$kind", "onEvent": { "change": { "actions": [ + { + "componentId": "basic", + "actionType": "reload", + "data": { + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" + } + }, { "componentId": "detail", "actionType": "reload", "data": { - "description": "${event.data.item.description}" + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" } } ] @@ -678,11 +688,16 @@ "body": [ { "type": "service", - "api": "post:/k8s/doc/detail", + "id": "basic", "body": [ + { + "type": "tpl", + "tpl": "
属性: ${id}", + "visibleOn": "${id}" + }, { "type": "button", - "label": "${id}-属性用法举例", + "label": "示例", "level": "link", "icon": "fas fa-lightbulb text-warning", "actionType": "drawer", @@ -700,20 +715,47 @@ "kind": "${kind}", "group": "${group}", "version": "${version}", - "id": "${id}" + "field": "${id}" } } ] - } + }, + "visibleOn": "${id}" + }, + { + "type": "tpl", + "tpl": "
类型: ${type}", + "visibleOn": "${type}" }, { "type": "tpl", - "tpl": "属性:${id}[${type}]

描述:${description}

翻译:${translate?translate:''}", - "wrapperComponent": "", - "inline": false + "tpl": "
描述: ${description}", + "visibleOn": "${description}" } - ], - "id": "detail" + ] + }, + { + "type": "service", + "id": "detail", + "api": "post:/k8s/doc/detail", + "body": [ + { + "type": "divider", + "title": "描述翻译", + "titlePosition": "center", + "visibleOn": "${translate}" + }, + { + "type": "markdown", + "value": "${translate|raw}", + "options": { + "linkify": true, + "html": true, + "breaks": true + }, + "visibleOn": "${translate}" + } + ] } ] } diff --git a/assets/pages/ns/hpa.json b/assets/pages/ns/hpa.json index 25318b9..335bb19 100644 --- a/assets/pages/ns/hpa.json +++ b/assets/pages/ns/hpa.json @@ -637,18 +637,28 @@ "searchConfig": { "sticky": true }, - "selectFirst": true, "heightAuto": true, "inputClassName": "no-border no-padder mt-1", "source": "get:/k8s/doc/gvk/${apiVersion|base64Encode}/$kind", "onEvent": { "change": { "actions": [ + { + "componentId": "basic", + "actionType": "reload", + "data": { + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" + } + }, { "componentId": "detail", "actionType": "reload", "data": { - "description": "${event.data.item.description}" + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" } } ] @@ -665,11 +675,16 @@ "body": [ { "type": "service", - "api": "post:/k8s/doc/detail", + "id": "basic", "body": [ + { + "type": "tpl", + "tpl": "
属性: ${id}", + "visibleOn": "${id}" + }, { "type": "button", - "label": "${id}-属性用法举例", + "label": "示例", "level": "link", "icon": "fas fa-lightbulb text-warning", "actionType": "drawer", @@ -687,20 +702,47 @@ "kind": "${kind}", "group": "${group}", "version": "${version}", - "id": "${id}" + "field": "${id}" } } ] - } + }, + "visibleOn": "${id}" + }, + { + "type": "tpl", + "tpl": "
类型: ${type}", + "visibleOn": "${type}" }, { "type": "tpl", - "tpl": "属性:${id}[${type}]

描述:${description}

翻译:${translate?translate:''}", - "wrapperComponent": "", - "inline": false + "tpl": "
描述: ${description}", + "visibleOn": "${description}" } - ], - "id": "detail" + ] + }, + { + "type": "service", + "id": "detail", + "api": "post:/k8s/doc/detail", + "body": [ + { + "type": "divider", + "title": "描述翻译", + "titlePosition": "center", + "visibleOn": "${translate}" + }, + { + "type": "markdown", + "value": "${translate|raw}", + "options": { + "linkify": true, + "html": true, + "breaks": true + }, + "visibleOn": "${translate}" + } + ] } ] } diff --git a/assets/pages/ns/ing.json b/assets/pages/ns/ing.json index 7c9d5bb..486384c 100644 --- a/assets/pages/ns/ing.json +++ b/assets/pages/ns/ing.json @@ -637,18 +637,28 @@ "searchConfig": { "sticky": true }, - "selectFirst": true, "heightAuto": true, "inputClassName": "no-border no-padder mt-1", "source": "get:/k8s/doc/gvk/${apiVersion|base64Encode}/$kind", "onEvent": { "change": { "actions": [ + { + "componentId": "basic", + "actionType": "reload", + "data": { + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" + } + }, { "componentId": "detail", "actionType": "reload", "data": { - "description": "${event.data.item.description}" + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" } } ] @@ -665,11 +675,16 @@ "body": [ { "type": "service", - "api": "post:/k8s/doc/detail", + "id": "basic", "body": [ + { + "type": "tpl", + "tpl": "
属性: ${id}", + "visibleOn": "${id}" + }, { "type": "button", - "label": "${id}-属性用法举例", + "label": "示例", "level": "link", "icon": "fas fa-lightbulb text-warning", "actionType": "drawer", @@ -687,20 +702,47 @@ "kind": "${kind}", "group": "${group}", "version": "${version}", - "id": "${id}" + "field": "${id}" } } ] - } + }, + "visibleOn": "${id}" + }, + { + "type": "tpl", + "tpl": "
类型: ${type}", + "visibleOn": "${type}" }, { "type": "tpl", - "tpl": "属性:${id}[${type}]

描述:${description}

翻译:${translate?translate:''}", - "wrapperComponent": "", - "inline": false + "tpl": "
描述: ${description}", + "visibleOn": "${description}" } - ], - "id": "detail" + ] + }, + { + "type": "service", + "id": "detail", + "api": "post:/k8s/doc/detail", + "body": [ + { + "type": "divider", + "title": "描述翻译", + "titlePosition": "center", + "visibleOn": "${translate}" + }, + { + "type": "markdown", + "value": "${translate|raw}", + "options": { + "linkify": true, + "html": true, + "breaks": true + }, + "visibleOn": "${translate}" + } + ] } ] } diff --git a/assets/pages/ns/job.json b/assets/pages/ns/job.json index b4916fa..0733dba 100644 --- a/assets/pages/ns/job.json +++ b/assets/pages/ns/job.json @@ -637,18 +637,28 @@ "searchConfig": { "sticky": true }, - "selectFirst": true, "heightAuto": true, "inputClassName": "no-border no-padder mt-1", "source": "get:/k8s/doc/gvk/${apiVersion|base64Encode}/$kind", "onEvent": { "change": { "actions": [ + { + "componentId": "basic", + "actionType": "reload", + "data": { + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" + } + }, { "componentId": "detail", "actionType": "reload", "data": { - "description": "${event.data.item.description}" + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" } } ] @@ -665,11 +675,16 @@ "body": [ { "type": "service", - "api": "post:/k8s/doc/detail", + "id": "basic", "body": [ + { + "type": "tpl", + "tpl": "
属性: ${id}", + "visibleOn": "${id}" + }, { "type": "button", - "label": "${id}-属性用法举例", + "label": "示例", "level": "link", "icon": "fas fa-lightbulb text-warning", "actionType": "drawer", @@ -687,20 +702,47 @@ "kind": "${kind}", "group": "${group}", "version": "${version}", - "id": "${id}" + "field": "${id}" } } ] - } + }, + "visibleOn": "${id}" + }, + { + "type": "tpl", + "tpl": "
类型: ${type}", + "visibleOn": "${type}" }, { "type": "tpl", - "tpl": "属性:${id}[${type}]

描述:${description}

翻译:${translate?translate:''}", - "wrapperComponent": "", - "inline": false + "tpl": "
描述: ${description}", + "visibleOn": "${description}" } - ], - "id": "detail" + ] + }, + { + "type": "service", + "id": "detail", + "api": "post:/k8s/doc/detail", + "body": [ + { + "type": "divider", + "title": "描述翻译", + "titlePosition": "center", + "visibleOn": "${translate}" + }, + { + "type": "markdown", + "value": "${translate|raw}", + "options": { + "linkify": true, + "html": true, + "breaks": true + }, + "visibleOn": "${translate}" + } + ] } ] } diff --git a/assets/pages/ns/lease.json b/assets/pages/ns/lease.json index fe24a7c..0759fd9 100644 --- a/assets/pages/ns/lease.json +++ b/assets/pages/ns/lease.json @@ -637,18 +637,28 @@ "searchConfig": { "sticky": true }, - "selectFirst": true, "heightAuto": true, "inputClassName": "no-border no-padder mt-1", "source": "get:/k8s/doc/gvk/${apiVersion|base64Encode}/$kind", "onEvent": { "change": { "actions": [ + { + "componentId": "basic", + "actionType": "reload", + "data": { + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" + } + }, { "componentId": "detail", "actionType": "reload", "data": { - "description": "${event.data.item.description}" + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" } } ] @@ -665,11 +675,16 @@ "body": [ { "type": "service", - "api": "post:/k8s/doc/detail", + "id": "basic", "body": [ + { + "type": "tpl", + "tpl": "
属性: ${id}", + "visibleOn": "${id}" + }, { "type": "button", - "label": "${id}-属性用法举例", + "label": "示例", "level": "link", "icon": "fas fa-lightbulb text-warning", "actionType": "drawer", @@ -687,20 +702,47 @@ "kind": "${kind}", "group": "${group}", "version": "${version}", - "id": "${id}" + "field": "${id}" } } ] - } + }, + "visibleOn": "${id}" + }, + { + "type": "tpl", + "tpl": "
类型: ${type}", + "visibleOn": "${type}" }, { "type": "tpl", - "tpl": "属性:${id}[${type}]

描述:${description}

翻译:${translate?translate:''}", - "wrapperComponent": "", - "inline": false + "tpl": "
描述: ${description}", + "visibleOn": "${description}" } - ], - "id": "detail" + ] + }, + { + "type": "service", + "id": "detail", + "api": "post:/k8s/doc/detail", + "body": [ + { + "type": "divider", + "title": "描述翻译", + "titlePosition": "center", + "visibleOn": "${translate}" + }, + { + "type": "markdown", + "value": "${translate|raw}", + "options": { + "linkify": true, + "html": true, + "breaks": true + }, + "visibleOn": "${translate}" + } + ] } ] } diff --git a/assets/pages/ns/limit_range.json b/assets/pages/ns/limit_range.json index d1c6f96..69a14db 100644 --- a/assets/pages/ns/limit_range.json +++ b/assets/pages/ns/limit_range.json @@ -637,18 +637,28 @@ "searchConfig": { "sticky": true }, - "selectFirst": true, "heightAuto": true, "inputClassName": "no-border no-padder mt-1", "source": "get:/k8s/doc/gvk/${apiVersion|base64Encode}/$kind", "onEvent": { "change": { "actions": [ + { + "componentId": "basic", + "actionType": "reload", + "data": { + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" + } + }, { "componentId": "detail", "actionType": "reload", "data": { - "description": "${event.data.item.description}" + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" } } ] @@ -665,11 +675,16 @@ "body": [ { "type": "service", - "api": "post:/k8s/doc/detail", + "id": "basic", "body": [ + { + "type": "tpl", + "tpl": "
属性: ${id}", + "visibleOn": "${id}" + }, { "type": "button", - "label": "${id}-属性用法举例", + "label": "示例", "level": "link", "icon": "fas fa-lightbulb text-warning", "actionType": "drawer", @@ -687,20 +702,47 @@ "kind": "${kind}", "group": "${group}", "version": "${version}", - "id": "${id}" + "field": "${id}" } } ] - } + }, + "visibleOn": "${id}" + }, + { + "type": "tpl", + "tpl": "
类型: ${type}", + "visibleOn": "${type}" }, { "type": "tpl", - "tpl": "属性:${id}[${type}]

描述:${description}

翻译:${translate?translate:''}", - "wrapperComponent": "", - "inline": false + "tpl": "
描述: ${description}", + "visibleOn": "${description}" } - ], - "id": "detail" + ] + }, + { + "type": "service", + "id": "detail", + "api": "post:/k8s/doc/detail", + "body": [ + { + "type": "divider", + "title": "描述翻译", + "titlePosition": "center", + "visibleOn": "${translate}" + }, + { + "type": "markdown", + "value": "${translate|raw}", + "options": { + "linkify": true, + "html": true, + "breaks": true + }, + "visibleOn": "${translate}" + } + ] } ] } diff --git a/assets/pages/ns/network_policy.json b/assets/pages/ns/network_policy.json index e8faeae..1fae87e 100644 --- a/assets/pages/ns/network_policy.json +++ b/assets/pages/ns/network_policy.json @@ -637,18 +637,28 @@ "searchConfig": { "sticky": true }, - "selectFirst": true, "heightAuto": true, "inputClassName": "no-border no-padder mt-1", "source": "get:/k8s/doc/gvk/${apiVersion|base64Encode}/$kind", "onEvent": { "change": { "actions": [ + { + "componentId": "basic", + "actionType": "reload", + "data": { + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" + } + }, { "componentId": "detail", "actionType": "reload", "data": { - "description": "${event.data.item.description}" + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" } } ] @@ -665,11 +675,16 @@ "body": [ { "type": "service", - "api": "post:/k8s/doc/detail", + "id": "basic", "body": [ + { + "type": "tpl", + "tpl": "
属性: ${id}", + "visibleOn": "${id}" + }, { "type": "button", - "label": "${id}-属性用法举例", + "label": "示例", "level": "link", "icon": "fas fa-lightbulb text-warning", "actionType": "drawer", @@ -687,20 +702,47 @@ "kind": "${kind}", "group": "${group}", "version": "${version}", - "id": "${id}" + "field": "${id}" } } ] - } + }, + "visibleOn": "${id}" + }, + { + "type": "tpl", + "tpl": "
类型: ${type}", + "visibleOn": "${type}" }, { "type": "tpl", - "tpl": "属性:${id}[${type}]

描述:${description}

翻译:${translate?translate:''}", - "wrapperComponent": "", - "inline": false + "tpl": "
描述: ${description}", + "visibleOn": "${description}" } - ], - "id": "detail" + ] + }, + { + "type": "service", + "id": "detail", + "api": "post:/k8s/doc/detail", + "body": [ + { + "type": "divider", + "title": "描述翻译", + "titlePosition": "center", + "visibleOn": "${translate}" + }, + { + "type": "markdown", + "value": "${translate|raw}", + "options": { + "linkify": true, + "html": true, + "breaks": true + }, + "visibleOn": "${translate}" + } + ] } ] } diff --git a/assets/pages/ns/pdb.json b/assets/pages/ns/pdb.json index 10b9f44..552d137 100644 --- a/assets/pages/ns/pdb.json +++ b/assets/pages/ns/pdb.json @@ -637,18 +637,28 @@ "searchConfig": { "sticky": true }, - "selectFirst": true, "heightAuto": true, "inputClassName": "no-border no-padder mt-1", "source": "get:/k8s/doc/gvk/${apiVersion|base64Encode}/$kind", "onEvent": { "change": { "actions": [ + { + "componentId": "basic", + "actionType": "reload", + "data": { + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" + } + }, { "componentId": "detail", "actionType": "reload", "data": { - "description": "${event.data.item.description}" + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" } } ] @@ -665,11 +675,16 @@ "body": [ { "type": "service", - "api": "post:/k8s/doc/detail", + "id": "basic", "body": [ + { + "type": "tpl", + "tpl": "
属性: ${id}", + "visibleOn": "${id}" + }, { "type": "button", - "label": "${id}-属性用法举例", + "label": "示例", "level": "link", "icon": "fas fa-lightbulb text-warning", "actionType": "drawer", @@ -687,20 +702,47 @@ "kind": "${kind}", "group": "${group}", "version": "${version}", - "id": "${id}" + "field": "${id}" } } ] - } + }, + "visibleOn": "${id}" + }, + { + "type": "tpl", + "tpl": "
类型: ${type}", + "visibleOn": "${type}" }, { "type": "tpl", - "tpl": "属性:${id}[${type}]

描述:${description}

翻译:${translate?translate:''}", - "wrapperComponent": "", - "inline": false + "tpl": "
描述: ${description}", + "visibleOn": "${description}" } - ], - "id": "detail" + ] + }, + { + "type": "service", + "id": "detail", + "api": "post:/k8s/doc/detail", + "body": [ + { + "type": "divider", + "title": "描述翻译", + "titlePosition": "center", + "visibleOn": "${translate}" + }, + { + "type": "markdown", + "value": "${translate|raw}", + "options": { + "linkify": true, + "html": true, + "breaks": true + }, + "visibleOn": "${translate}" + } + ] } ] } diff --git a/assets/pages/ns/pod.json b/assets/pages/ns/pod.json index 590f9bd..f0767d1 100644 --- a/assets/pages/ns/pod.json +++ b/assets/pages/ns/pod.json @@ -674,8 +674,8 @@ "type": "page", "asideResizor": true, "asideSticky": false, - "asideMinWidth": 300, - "asideMaxWidth": 600, + "asideMinWidth": 150, + "asideMaxWidth": 400, "aside": [ { "type": "input-tree", @@ -688,18 +688,28 @@ "searchConfig": { "sticky": true }, - "selectFirst": true, "heightAuto": true, "inputClassName": "no-border no-padder mt-1", "source": "get:/k8s/doc/gvk/${apiVersion|base64Encode}/$kind", "onEvent": { "change": { "actions": [ + { + "componentId": "basic", + "actionType": "reload", + "data": { + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" + } + }, { "componentId": "detail", "actionType": "reload", "data": { - "description": "${event.data.item.description}" + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" } } ] @@ -716,11 +726,16 @@ "body": [ { "type": "service", - "api": "post:/k8s/doc/detail", + "id": "basic", "body": [ + { + "type": "tpl", + "tpl": "
属性: ${id}", + "visibleOn": "${id}" + }, { "type": "button", - "label": "${id}-属性用法举例", + "label": "示例", "level": "link", "icon": "fas fa-lightbulb text-warning", "actionType": "drawer", @@ -738,20 +753,47 @@ "kind": "${kind}", "group": "${group}", "version": "${version}", - "id": "${id}" + "field": "${id}" } } ] - } + }, + "visibleOn": "${id}" + }, + { + "type": "tpl", + "tpl": "
类型: ${type}", + "visibleOn": "${type}" }, { "type": "tpl", - "tpl": "属性:${id}[${type}]

描述:${description}

翻译:${translate?translate:''}", - "wrapperComponent": "", - "inline": false + "tpl": "
描述: ${description}", + "visibleOn": "${description}" } - ], - "id": "detail" + ] + }, + { + "type": "service", + "id": "detail", + "api": "post:/k8s/doc/detail", + "body": [ + { + "type": "divider", + "title": "描述翻译", + "titlePosition": "center", + "visibleOn": "${translate}" + }, + { + "type": "markdown", + "value": "${translate|raw}", + "options": { + "linkify": true, + "html": true, + "breaks": true + }, + "visibleOn": "${translate}" + } + ] } ] } diff --git a/assets/pages/ns/pvc.json b/assets/pages/ns/pvc.json index 64262dd..3cf53f4 100644 --- a/assets/pages/ns/pvc.json +++ b/assets/pages/ns/pvc.json @@ -637,18 +637,28 @@ "searchConfig": { "sticky": true }, - "selectFirst": true, "heightAuto": true, "inputClassName": "no-border no-padder mt-1", "source": "get:/k8s/doc/gvk/${apiVersion|base64Encode}/$kind", "onEvent": { "change": { "actions": [ + { + "componentId": "basic", + "actionType": "reload", + "data": { + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" + } + }, { "componentId": "detail", "actionType": "reload", "data": { - "description": "${event.data.item.description}" + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" } } ] @@ -665,11 +675,16 @@ "body": [ { "type": "service", - "api": "post:/k8s/doc/detail", + "id": "basic", "body": [ + { + "type": "tpl", + "tpl": "
属性: ${id}", + "visibleOn": "${id}" + }, { "type": "button", - "label": "${id}-属性用法举例", + "label": "示例", "level": "link", "icon": "fas fa-lightbulb text-warning", "actionType": "drawer", @@ -687,20 +702,47 @@ "kind": "${kind}", "group": "${group}", "version": "${version}", - "id": "${id}" + "field": "${id}" } } ] - } + }, + "visibleOn": "${id}" + }, + { + "type": "tpl", + "tpl": "
类型: ${type}", + "visibleOn": "${type}" }, { "type": "tpl", - "tpl": "属性:${id}[${type}]

描述:${description}

翻译:${translate?translate:''}", - "wrapperComponent": "", - "inline": false + "tpl": "
描述: ${description}", + "visibleOn": "${description}" } - ], - "id": "detail" + ] + }, + { + "type": "service", + "id": "detail", + "api": "post:/k8s/doc/detail", + "body": [ + { + "type": "divider", + "title": "描述翻译", + "titlePosition": "center", + "visibleOn": "${translate}" + }, + { + "type": "markdown", + "value": "${translate|raw}", + "options": { + "linkify": true, + "html": true, + "breaks": true + }, + "visibleOn": "${translate}" + } + ] } ] } diff --git a/assets/pages/ns/rc.json b/assets/pages/ns/rc.json index e601143..7702893 100644 --- a/assets/pages/ns/rc.json +++ b/assets/pages/ns/rc.json @@ -637,18 +637,28 @@ "searchConfig": { "sticky": true }, - "selectFirst": true, "heightAuto": true, "inputClassName": "no-border no-padder mt-1", "source": "get:/k8s/doc/gvk/${apiVersion|base64Encode}/$kind", "onEvent": { "change": { "actions": [ + { + "componentId": "basic", + "actionType": "reload", + "data": { + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" + } + }, { "componentId": "detail", "actionType": "reload", "data": { - "description": "${event.data.item.description}" + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" } } ] @@ -665,11 +675,16 @@ "body": [ { "type": "service", - "api": "post:/k8s/doc/detail", + "id": "basic", "body": [ + { + "type": "tpl", + "tpl": "
属性: ${id}", + "visibleOn": "${id}" + }, { "type": "button", - "label": "${id}-属性用法举例", + "label": "示例", "level": "link", "icon": "fas fa-lightbulb text-warning", "actionType": "drawer", @@ -687,20 +702,47 @@ "kind": "${kind}", "group": "${group}", "version": "${version}", - "id": "${id}" + "field": "${id}" } } ] - } + }, + "visibleOn": "${id}" + }, + { + "type": "tpl", + "tpl": "
类型: ${type}", + "visibleOn": "${type}" }, { "type": "tpl", - "tpl": "属性:${id}[${type}]

描述:${description}

翻译:${translate?translate:''}", - "wrapperComponent": "", - "inline": false + "tpl": "
描述: ${description}", + "visibleOn": "${description}" } - ], - "id": "detail" + ] + }, + { + "type": "service", + "id": "detail", + "api": "post:/k8s/doc/detail", + "body": [ + { + "type": "divider", + "title": "描述翻译", + "titlePosition": "center", + "visibleOn": "${translate}" + }, + { + "type": "markdown", + "value": "${translate|raw}", + "options": { + "linkify": true, + "html": true, + "breaks": true + }, + "visibleOn": "${translate}" + } + ] } ] } diff --git a/assets/pages/ns/replicaset.json b/assets/pages/ns/replicaset.json index 5b5c0a1..e5d2959 100644 --- a/assets/pages/ns/replicaset.json +++ b/assets/pages/ns/replicaset.json @@ -645,18 +645,28 @@ "searchConfig": { "sticky": true }, - "selectFirst": true, "heightAuto": true, "inputClassName": "no-border no-padder mt-1", "source": "get:/k8s/doc/gvk/${apiVersion|base64Encode}/$kind", "onEvent": { "change": { "actions": [ + { + "componentId": "basic", + "actionType": "reload", + "data": { + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" + } + }, { "componentId": "detail", "actionType": "reload", "data": { - "description": "${event.data.item.description}" + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" } } ] @@ -673,11 +683,16 @@ "body": [ { "type": "service", - "api": "post:/k8s/doc/detail", + "id": "basic", "body": [ + { + "type": "tpl", + "tpl": "
属性: ${id}", + "visibleOn": "${id}" + }, { "type": "button", - "label": "${id}-属性用法举例", + "label": "示例", "level": "link", "icon": "fas fa-lightbulb text-warning", "actionType": "drawer", @@ -695,20 +710,47 @@ "kind": "${kind}", "group": "${group}", "version": "${version}", - "id": "${id}" + "field": "${id}" } } ] - } + }, + "visibleOn": "${id}" + }, + { + "type": "tpl", + "tpl": "
类型: ${type}", + "visibleOn": "${type}" }, { "type": "tpl", - "tpl": "属性:${id}[${type}]

描述:${description}

翻译:${translate?translate:''}", - "wrapperComponent": "", - "inline": false + "tpl": "
描述: ${description}", + "visibleOn": "${description}" } - ], - "id": "detail" + ] + }, + { + "type": "service", + "id": "detail", + "api": "post:/k8s/doc/detail", + "body": [ + { + "type": "divider", + "title": "描述翻译", + "titlePosition": "center", + "visibleOn": "${translate}" + }, + { + "type": "markdown", + "value": "${translate|raw}", + "options": { + "linkify": true, + "html": true, + "breaks": true + }, + "visibleOn": "${translate}" + } + ] } ] } diff --git a/assets/pages/ns/resource_quota.json b/assets/pages/ns/resource_quota.json index 3e4607f..a5c9bd4 100644 --- a/assets/pages/ns/resource_quota.json +++ b/assets/pages/ns/resource_quota.json @@ -637,18 +637,28 @@ "searchConfig": { "sticky": true }, - "selectFirst": true, "heightAuto": true, "inputClassName": "no-border no-padder mt-1", "source": "get:/k8s/doc/gvk/${apiVersion|base64Encode}/$kind", "onEvent": { "change": { "actions": [ + { + "componentId": "basic", + "actionType": "reload", + "data": { + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" + } + }, { "componentId": "detail", "actionType": "reload", "data": { - "description": "${event.data.item.description}" + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" } } ] @@ -665,11 +675,16 @@ "body": [ { "type": "service", - "api": "post:/k8s/doc/detail", + "id": "basic", "body": [ + { + "type": "tpl", + "tpl": "
属性: ${id}", + "visibleOn": "${id}" + }, { "type": "button", - "label": "${id}-属性用法举例", + "label": "示例", "level": "link", "icon": "fas fa-lightbulb text-warning", "actionType": "drawer", @@ -687,20 +702,47 @@ "kind": "${kind}", "group": "${group}", "version": "${version}", - "id": "${id}" + "field": "${id}" } } ] - } + }, + "visibleOn": "${id}" + }, + { + "type": "tpl", + "tpl": "
类型: ${type}", + "visibleOn": "${type}" }, { "type": "tpl", - "tpl": "属性:${id}[${type}]

描述:${description}

翻译:${translate?translate:''}", - "wrapperComponent": "", - "inline": false + "tpl": "
描述: ${description}", + "visibleOn": "${description}" } - ], - "id": "detail" + ] + }, + { + "type": "service", + "id": "detail", + "api": "post:/k8s/doc/detail", + "body": [ + { + "type": "divider", + "title": "描述翻译", + "titlePosition": "center", + "visibleOn": "${translate}" + }, + { + "type": "markdown", + "value": "${translate|raw}", + "options": { + "linkify": true, + "html": true, + "breaks": true + }, + "visibleOn": "${translate}" + } + ] } ] } diff --git a/assets/pages/ns/role.json b/assets/pages/ns/role.json index 4aef431..a5e4589 100644 --- a/assets/pages/ns/role.json +++ b/assets/pages/ns/role.json @@ -637,18 +637,28 @@ "searchConfig": { "sticky": true }, - "selectFirst": true, "heightAuto": true, "inputClassName": "no-border no-padder mt-1", "source": "get:/k8s/doc/gvk/${apiVersion|base64Encode}/$kind", "onEvent": { "change": { "actions": [ + { + "componentId": "basic", + "actionType": "reload", + "data": { + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" + } + }, { "componentId": "detail", "actionType": "reload", "data": { - "description": "${event.data.item.description}" + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" } } ] @@ -665,11 +675,16 @@ "body": [ { "type": "service", - "api": "post:/k8s/doc/detail", + "id": "basic", "body": [ + { + "type": "tpl", + "tpl": "
属性: ${id}", + "visibleOn": "${id}" + }, { "type": "button", - "label": "${id}-属性用法举例", + "label": "示例", "level": "link", "icon": "fas fa-lightbulb text-warning", "actionType": "drawer", @@ -687,20 +702,47 @@ "kind": "${kind}", "group": "${group}", "version": "${version}", - "id": "${id}" + "field": "${id}" } } ] - } + }, + "visibleOn": "${id}" + }, + { + "type": "tpl", + "tpl": "
类型: ${type}", + "visibleOn": "${type}" }, { "type": "tpl", - "tpl": "属性:${id}[${type}]

描述:${description}

翻译:${translate?translate:''}", - "wrapperComponent": "", - "inline": false + "tpl": "
描述: ${description}", + "visibleOn": "${description}" } - ], - "id": "detail" + ] + }, + { + "type": "service", + "id": "detail", + "api": "post:/k8s/doc/detail", + "body": [ + { + "type": "divider", + "title": "描述翻译", + "titlePosition": "center", + "visibleOn": "${translate}" + }, + { + "type": "markdown", + "value": "${translate|raw}", + "options": { + "linkify": true, + "html": true, + "breaks": true + }, + "visibleOn": "${translate}" + } + ] } ] } diff --git a/assets/pages/ns/role_binding.json b/assets/pages/ns/role_binding.json index 961707f..6d429d9 100644 --- a/assets/pages/ns/role_binding.json +++ b/assets/pages/ns/role_binding.json @@ -637,18 +637,28 @@ "searchConfig": { "sticky": true }, - "selectFirst": true, "heightAuto": true, "inputClassName": "no-border no-padder mt-1", "source": "get:/k8s/doc/gvk/${apiVersion|base64Encode}/$kind", "onEvent": { "change": { "actions": [ + { + "componentId": "basic", + "actionType": "reload", + "data": { + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" + } + }, { "componentId": "detail", "actionType": "reload", "data": { - "description": "${event.data.item.description}" + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" } } ] @@ -665,11 +675,16 @@ "body": [ { "type": "service", - "api": "post:/k8s/doc/detail", + "id": "basic", "body": [ + { + "type": "tpl", + "tpl": "
属性: ${id}", + "visibleOn": "${id}" + }, { "type": "button", - "label": "${id}-属性用法举例", + "label": "示例", "level": "link", "icon": "fas fa-lightbulb text-warning", "actionType": "drawer", @@ -687,20 +702,47 @@ "kind": "${kind}", "group": "${group}", "version": "${version}", - "id": "${id}" + "field": "${id}" } } ] - } + }, + "visibleOn": "${id}" + }, + { + "type": "tpl", + "tpl": "
类型: ${type}", + "visibleOn": "${type}" }, { "type": "tpl", - "tpl": "属性:${id}[${type}]

描述:${description}

翻译:${translate?translate:''}", - "wrapperComponent": "", - "inline": false + "tpl": "
描述: ${description}", + "visibleOn": "${description}" } - ], - "id": "detail" + ] + }, + { + "type": "service", + "id": "detail", + "api": "post:/k8s/doc/detail", + "body": [ + { + "type": "divider", + "title": "描述翻译", + "titlePosition": "center", + "visibleOn": "${translate}" + }, + { + "type": "markdown", + "value": "${translate|raw}", + "options": { + "linkify": true, + "html": true, + "breaks": true + }, + "visibleOn": "${translate}" + } + ] } ] } diff --git a/assets/pages/ns/secret.json b/assets/pages/ns/secret.json index 06ba772..9ac8bcf 100644 --- a/assets/pages/ns/secret.json +++ b/assets/pages/ns/secret.json @@ -637,18 +637,28 @@ "searchConfig": { "sticky": true }, - "selectFirst": true, "heightAuto": true, "inputClassName": "no-border no-padder mt-1", "source": "get:/k8s/doc/gvk/${apiVersion|base64Encode}/$kind", "onEvent": { "change": { "actions": [ + { + "componentId": "basic", + "actionType": "reload", + "data": { + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" + } + }, { "componentId": "detail", "actionType": "reload", "data": { - "description": "${event.data.item.description}" + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" } } ] @@ -665,11 +675,16 @@ "body": [ { "type": "service", - "api": "post:/k8s/doc/detail", + "id": "basic", "body": [ + { + "type": "tpl", + "tpl": "
属性: ${id}", + "visibleOn": "${id}" + }, { "type": "button", - "label": "${id}-属性用法举例", + "label": "示例", "level": "link", "icon": "fas fa-lightbulb text-warning", "actionType": "drawer", @@ -687,20 +702,47 @@ "kind": "${kind}", "group": "${group}", "version": "${version}", - "id": "${id}" + "field": "${id}" } } ] - } + }, + "visibleOn": "${id}" + }, + { + "type": "tpl", + "tpl": "
类型: ${type}", + "visibleOn": "${type}" }, { "type": "tpl", - "tpl": "属性:${id}[${type}]

描述:${description}

翻译:${translate?translate:''}", - "wrapperComponent": "", - "inline": false + "tpl": "
描述: ${description}", + "visibleOn": "${description}" } - ], - "id": "detail" + ] + }, + { + "type": "service", + "id": "detail", + "api": "post:/k8s/doc/detail", + "body": [ + { + "type": "divider", + "title": "描述翻译", + "titlePosition": "center", + "visibleOn": "${translate}" + }, + { + "type": "markdown", + "value": "${translate|raw}", + "options": { + "linkify": true, + "html": true, + "breaks": true + }, + "visibleOn": "${translate}" + } + ] } ] } diff --git a/assets/pages/ns/service_account.json b/assets/pages/ns/service_account.json index bd2c17a..dfb811e 100644 --- a/assets/pages/ns/service_account.json +++ b/assets/pages/ns/service_account.json @@ -637,18 +637,28 @@ "searchConfig": { "sticky": true }, - "selectFirst": true, "heightAuto": true, "inputClassName": "no-border no-padder mt-1", "source": "get:/k8s/doc/gvk/${apiVersion|base64Encode}/$kind", "onEvent": { "change": { "actions": [ + { + "componentId": "basic", + "actionType": "reload", + "data": { + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" + } + }, { "componentId": "detail", "actionType": "reload", "data": { - "description": "${event.data.item.description}" + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" } } ] @@ -665,11 +675,16 @@ "body": [ { "type": "service", - "api": "post:/k8s/doc/detail", + "id": "basic", "body": [ + { + "type": "tpl", + "tpl": "
属性: ${id}", + "visibleOn": "${id}" + }, { "type": "button", - "label": "${id}-属性用法举例", + "label": "示例", "level": "link", "icon": "fas fa-lightbulb text-warning", "actionType": "drawer", @@ -687,20 +702,47 @@ "kind": "${kind}", "group": "${group}", "version": "${version}", - "id": "${id}" + "field": "${id}" } } ] - } + }, + "visibleOn": "${id}" + }, + { + "type": "tpl", + "tpl": "
类型: ${type}", + "visibleOn": "${type}" }, { "type": "tpl", - "tpl": "属性:${id}[${type}]

描述:${description}

翻译:${translate?translate:''}", - "wrapperComponent": "", - "inline": false + "tpl": "
描述: ${description}", + "visibleOn": "${description}" } - ], - "id": "detail" + ] + }, + { + "type": "service", + "id": "detail", + "api": "post:/k8s/doc/detail", + "body": [ + { + "type": "divider", + "title": "描述翻译", + "titlePosition": "center", + "visibleOn": "${translate}" + }, + { + "type": "markdown", + "value": "${translate|raw}", + "options": { + "linkify": true, + "html": true, + "breaks": true + }, + "visibleOn": "${translate}" + } + ] } ] } diff --git a/assets/pages/ns/statefulset.json b/assets/pages/ns/statefulset.json index 61191bf..5786fe0 100644 --- a/assets/pages/ns/statefulset.json +++ b/assets/pages/ns/statefulset.json @@ -670,18 +670,28 @@ "searchConfig": { "sticky": true }, - "selectFirst": true, "heightAuto": true, "inputClassName": "no-border no-padder mt-1", "source": "get:/k8s/doc/gvk/${apiVersion|base64Encode}/$kind", "onEvent": { "change": { "actions": [ + { + "componentId": "basic", + "actionType": "reload", + "data": { + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" + } + }, { "componentId": "detail", "actionType": "reload", "data": { - "description": "${event.data.item.description}" + "description": "${event.data.item.description}", + "id": "${event.data.item.id}", + "type": "${event.data.item.type}" } } ] @@ -698,11 +708,16 @@ "body": [ { "type": "service", - "api": "post:/k8s/doc/detail", + "id": "basic", "body": [ + { + "type": "tpl", + "tpl": "
属性: ${id}", + "visibleOn": "${id}" + }, { "type": "button", - "label": "${id}-属性用法举例", + "label": "示例", "level": "link", "icon": "fas fa-lightbulb text-warning", "actionType": "drawer", @@ -720,20 +735,47 @@ "kind": "${kind}", "group": "${group}", "version": "${version}", - "id": "${id}" + "field": "${id}" } } ] - } + }, + "visibleOn": "${id}" + }, + { + "type": "tpl", + "tpl": "
类型: ${type}", + "visibleOn": "${type}" }, { "type": "tpl", - "tpl": "属性:${id}[${type}]

描述:${description}

翻译:${translate?translate:''}", - "wrapperComponent": "", - "inline": false + "tpl": "
描述: ${description}", + "visibleOn": "${description}" } - ], - "id": "detail" + ] + }, + { + "type": "service", + "id": "detail", + "api": "post:/k8s/doc/detail", + "body": [ + { + "type": "divider", + "title": "描述翻译", + "titlePosition": "center", + "visibleOn": "${translate}" + }, + { + "type": "markdown", + "value": "${translate|raw}", + "options": { + "linkify": true, + "html": true, + "breaks": true + }, + "visibleOn": "${translate}" + } + ] } ] }