UNPKG

@openshift-console/dynamic-plugin-sdk-webpack

Version:

Provides webpack ConsoleRemotePlugin used to build all dynamic plugin assets.

1,675 lines (1,674 loc) 139 kB
{ "$schema": "http://json-schema.org/draft-07/schema#", "type": "array", "items": { "anyOf": [ { "$ref": "#/definitions/SupportedExtension" }, { "$ref": "#/definitions/CustomExtension" } ] }, "description": "Schema of Console plugin's `console-extensions.json` file.", "definitions": { "SupportedExtension": { "anyOf": [ { "$ref": "#/definitions/FeatureFlag" }, { "$ref": "#/definitions/ModelFeatureFlag" }, { "$ref": "#/definitions/FeatureFlagHookProvider" }, { "$ref": "#/definitions/ReduxReducer" }, { "$ref": "#/definitions/ContextProvider" }, { "$ref": "#/definitions/StandaloneRoutePage" }, { "$ref": "#/definitions/PVCCreateProp" }, { "$ref": "#/definitions/PVCStatus" }, { "$ref": "#/definitions/PVCAlert" }, { "$ref": "#/definitions/PVCDelete" }, { "$ref": "#/definitions/YAMLTemplate" }, { "$ref": "#/definitions/AddAction" }, { "$ref": "#/definitions/AddActionGroup" }, { "$ref": "#/definitions/ImportEnvironment" }, { "$ref": "#/definitions/ClusterGlobalConfig" }, { "$ref": "#/definitions/HrefNavItem" }, { "$ref": "#/definitions/ResourceNSNavItem" }, { "$ref": "#/definitions/ResourceClusterNavItem" }, { "$ref": "#/definitions/Separator" }, { "$ref": "#/definitions/NavSection" }, { "$ref": "#/definitions/FileUpload" }, { "$ref": "#/definitions/ModelMetadata" }, { "$ref": "#/definitions/AlertAction" }, { "$ref": "#/definitions/StorageProvider" }, { "$ref": "#/definitions/TelemetryListener" }, { "$ref": "#/definitions/SupportedCatalogExtensions" }, { "$ref": "#/definitions/SupportedActionExtensions" }, { "$ref": "#/definitions/SupportedTopologyDetailsExtensions" }, { "$ref": "#/definitions/RoutePage" }, { "$ref": "#/definitions/ResourceListPage" }, { "$ref": "#/definitions/ResourceTabPage" }, { "$ref": "#/definitions/ResourceDetailsPage" }, { "$ref": "#/definitions/DashboardsTab" }, { "$ref": "#/definitions/DashboardsCard" }, { "$ref": "#/definitions/DashboardsOverviewHealthPrometheusSubsystem" }, { "$ref": "#/definitions/DashboardsOverviewHealthURLSubsystem" }, { "$ref": "#/definitions/DashboardsOverviewHealthResourceSubsystem" }, { "$ref": "#/definitions/DashboardsOverviewHealthOperator" }, { "$ref": "#/definitions/DashboardsInventoryItemGroup" }, { "$ref": "#/definitions/DashboardsOverviewInventoryItem" }, { "$ref": "#/definitions/DashboardsOverviewInventoryItemReplacement" }, { "$ref": "#/definitions/DashboardsProjectOverviewInventoryItem" }, { "$ref": "#/definitions/DashboardsOverviewResourceActivity" }, { "$ref": "#/definitions/DashboardsOverviewPrometheusActivity" }, { "$ref": "#/definitions/TopologyComponentFactory" }, { "$ref": "#/definitions/TopologyCreateConnector" }, { "$ref": "#/definitions/TopologyDataModelFactory" }, { "$ref": "#/definitions/TopologyDisplayFilters" }, { "$ref": "#/definitions/TopologyDecoratorProvider" }, { "$ref": "#/definitions/TopologyRelationshipProvider" }, { "$ref": "#/definitions/CreateResource" }, { "$ref": "#/definitions/UserPreferenceGroup" }, { "$ref": "#/definitions/UserPreferenceItem" }, { "$ref": "#/definitions/Perspective" }, { "$ref": "#/definitions/HorizontalNavTab" }, { "$ref": "#/definitions/NavTab" }, { "$ref": "#/definitions/ClusterOverviewInventoryItem" }, { "$ref": "#/definitions/ClusterOverviewUtilizationItem" }, { "$ref": "#/definitions/ClusterOverviewMultilineUtilizationItem" }, { "$ref": "#/definitions/OverviewDetailItem" }, { "$ref": "#/definitions/CustomOverviewDetailItem" }, { "$ref": "#/definitions/ProjectOverviewUtilizationItem" }, { "$ref": "#/definitions/ProjectOverviewInventoryItem" }, { "$ref": "#/definitions/StorageClassProvisioner" }, { "$ref": "#/definitions/DetailsItem" }, { "$ref": "#/definitions/CreateProjectModal" } ] }, "FeatureFlag": { "type": "object", "additionalProperties": false, "properties": { "type": { "type": "string", "const": "console.flag" }, "properties": { "type": "object", "properties": { "handler": { "$ref": "#/definitions/EncodedCodeRef", "description": "Used to set/unset arbitrary feature flags." } }, "required": [ "handler" ], "additionalProperties": false }, "flags": { "$ref": "#/definitions/ExtensionFlags" } }, "required": [ "properties", "type" ], "description": "Gives full control over Console feature flags." }, "EncodedCodeRef": { "type": "object", "properties": { "$codeRef": { "type": "string" } }, "required": [ "$codeRef" ], "additionalProperties": false, "description": "Code reference, encoded as an object literal.\n\nThe value of the `$codeRef` property should be formatted as `moduleName.exportName` (referring to a named export) or `moduleName` (referring to the `default` export)." }, "ExtensionFlags": { "type": "object", "properties": { "required": { "type": "array", "items": { "type": "string" } }, "disallowed": { "type": "array", "items": { "type": "string" } } }, "additionalProperties": false, "description": "Console feature flags used to gate extension instances." }, "ModelFeatureFlag": { "type": "object", "additionalProperties": false, "properties": { "type": { "type": "string", "const": "console.flag/model" }, "properties": { "type": "object", "properties": { "flag": { "type": "string", "description": "The name of the flag to set once the CRD is detected." }, "model": { "$ref": "#/definitions/ExtensionK8sModel", "description": "The model which refers to a `CustomResourceDefinition`." } }, "required": [ "flag", "model" ], "additionalProperties": false }, "flags": { "$ref": "#/definitions/ExtensionFlags" } }, "required": [ "properties", "type" ], "description": "Adds new Console feature flag driven by the presence of a CRD on the cluster." }, "ExtensionK8sModel": { "type": "object", "properties": { "group": { "type": "string" }, "version": { "type": "string" }, "kind": { "type": "string" } }, "required": [ "group", "version", "kind" ], "additionalProperties": false }, "FeatureFlagHookProvider": { "type": "object", "additionalProperties": false, "properties": { "type": { "type": "string", "const": "console.flag/hookProvider" }, "properties": { "type": "object", "properties": { "handler": { "$ref": "#/definitions/EncodedCodeRef", "description": "Used to set/unset arbitrary feature flags." } }, "required": [ "handler" ], "additionalProperties": false }, "flags": { "$ref": "#/definitions/ExtensionFlags" } }, "required": [ "properties", "type" ], "description": "Gives full control over Console feature flags with hook handlers." }, "ReduxReducer": { "type": "object", "additionalProperties": false, "properties": { "type": { "type": "string", "const": "console.redux-reducer" }, "properties": { "type": "object", "properties": { "scope": { "type": "string", "description": "The key to represent the reducer-managed substate within the Redux state object." }, "reducer": { "$ref": "#/definitions/EncodedCodeRef", "description": "The reducer function, operating on the reducer-managed substate." } }, "required": [ "scope", "reducer" ], "additionalProperties": false }, "flags": { "$ref": "#/definitions/ExtensionFlags" } }, "required": [ "properties", "type" ], "description": "Adds new reducer to Console Redux store which operates on `plugins.<scope>` substate." }, "ContextProvider": { "type": "object", "additionalProperties": false, "properties": { "type": { "type": "string", "const": "console.context-provider" }, "properties": { "type": "object", "properties": { "provider": { "$ref": "#/definitions/EncodedCodeRef", "description": "Context Provider component." }, "useValueHook": { "$ref": "#/definitions/EncodedCodeRef", "description": "Hook for the Context value." } }, "required": [ "provider", "useValueHook" ], "additionalProperties": false }, "flags": { "$ref": "#/definitions/ExtensionFlags" } }, "required": [ "properties", "type" ], "description": "Adds new React context provider to Console application root." }, "StandaloneRoutePage": { "type": "object", "additionalProperties": false, "properties": { "type": { "type": "string", "const": "console.page/route/standalone" }, "properties": { "type": "object", "properties": { "component": { "$ref": "#/definitions/EncodedCodeRef", "description": "The component to be rendered when the route matches." }, "path": { "anyOf": [ { "type": "string" }, { "type": "array", "items": { "type": "string" } } ], "description": "Valid URL path or array of paths that `path-to-regexp@^1.7.0` understands." }, "exact": { "type": "boolean", "description": "When true, will only match if the path matches the `location.pathname` exactly." } }, "required": [ "component", "path" ], "additionalProperties": false }, "flags": { "$ref": "#/definitions/ExtensionFlags" } }, "required": [ "properties", "type" ], "description": "Adds new standalone page (rendered outside the common page layout) to Console router.\n\nUnder the hood we use React Router. See https://v5.reactrouter.com/" }, "PVCCreateProp": { "type": "object", "additionalProperties": false, "properties": { "type": { "type": "string", "const": "console.pvc/create-prop" }, "properties": { "type": "object", "properties": { "label": { "type": "string", "description": "Label for the create prop action." }, "path": { "type": "string", "description": "Path for the create prop action." } }, "required": [ "label", "path" ], "additionalProperties": false }, "flags": { "$ref": "#/definitions/ExtensionFlags" } }, "required": [ "properties", "type" ], "description": "This extension can be used to specify additional properties that will be used when creating PVC resources on the PVC list page." }, "PVCStatus": { "type": "object", "additionalProperties": false, "properties": { "type": { "type": "string", "const": "console.pvc/status" }, "properties": { "type": "object", "properties": { "priority": { "type": "number", "description": "Priority for the status component. Bigger value means higher priority." }, "status": { "$ref": "#/definitions/EncodedCodeRef", "description": "The status component." }, "predicate": { "$ref": "#/definitions/EncodedCodeRef", "description": "Predicate that tells whether to render the status component or not." } }, "required": [ "priority", "status", "predicate" ], "additionalProperties": false }, "flags": { "$ref": "#/definitions/ExtensionFlags" } }, "required": [ "properties", "type" ], "description": "This extension can be used to contribute an additional status component for PVC resources on the cluster dashboard page." }, "PVCAlert": { "type": "object", "additionalProperties": false, "properties": { "type": { "type": "string", "const": "console.pvc/alert" }, "properties": { "type": "object", "properties": { "alert": { "$ref": "#/definitions/EncodedCodeRef", "description": "The alert component." } }, "required": [ "alert" ], "additionalProperties": false }, "flags": { "$ref": "#/definitions/ExtensionFlags" } }, "required": [ "properties", "type" ], "description": "This extension can be used to contribute custom alerts on the PVC details page." }, "PVCDelete": { "type": "object", "additionalProperties": false, "properties": { "type": { "type": "string", "const": "console.pvc/delete" }, "properties": { "type": "object", "properties": { "predicate": { "$ref": "#/definitions/EncodedCodeRef", "description": "Predicate that tells whether to use the extension or not." }, "onPVCKill": { "$ref": "#/definitions/EncodedCodeRef", "description": "Method for the PVC delete operation." }, "alert": { "$ref": "#/definitions/EncodedCodeRef", "description": "Alert component to show additional information." } }, "required": [ "predicate", "onPVCKill", "alert" ], "additionalProperties": false }, "flags": { "$ref": "#/definitions/ExtensionFlags" } }, "required": [ "properties", "type" ], "description": "This extension allows hooking into deleting PVC resources. It can provide an alert with additional information and custom PVC delete logic." }, "YAMLTemplate": { "type": "object", "additionalProperties": false, "properties": { "type": { "type": "string", "const": "console.yaml-template" }, "properties": { "type": "object", "properties": { "model": { "$ref": "#/definitions/ExtensionK8sModel", "description": "Model associated with the template." }, "template": { "$ref": "#/definitions/EncodedCodeRef", "description": "The YAML template." }, "name": { "type": "string", "description": "The name of the template. Use the name `default` to mark this as the default template." } }, "required": [ "model", "template", "name" ], "additionalProperties": false }, "flags": { "$ref": "#/definitions/ExtensionFlags" } }, "required": [ "properties", "type" ], "description": "YAML templates for editing resources via the yaml editor." }, "AddAction": { "type": "object", "additionalProperties": false, "properties": { "type": { "type": "string", "const": "dev-console.add/action" }, "properties": { "type": "object", "properties": { "id": { "type": "string", "description": "ID used to identify the action." }, "groupId": { "type": "string", "description": "IDs used to identify the action groups the action would belong to." }, "label": { "type": "string", "description": "The label of the action" }, "description": { "type": "string", "description": "The description of the action." }, "href": { "type": "string", "description": "The href to navigate to." }, "callback": { "$ref": "#/definitions/EncodedCodeRef", "description": "A callback that performs an action on click" }, "icon": { "$ref": "#/definitions/EncodedCodeRef", "description": "The perspective display icon. If possible, use a PatternFly icon for consistent icon colours and styling." }, "accessReview": { "type": "array", "items": { "$ref": "#/definitions/AccessReviewResourceAttributes" }, "description": "Optional access review to control visibility / enablement of the action." } }, "required": [ "id", "label", "description" ], "additionalProperties": false }, "flags": { "$ref": "#/definitions/ExtensionFlags" } }, "required": [ "properties", "type" ], "description": "This extension allows plugins to contribute an add action item to the add page of developer perspective. For example, a Serverless plugin can add a new action item for adding serverless functions to the add page of developer console." }, "AccessReviewResourceAttributes": { "type": "object", "properties": { "group": { "type": "string" }, "resource": { "type": "string" }, "subresource": { "type": "string" }, "verb": { "$ref": "#/definitions/K8sVerb" }, "name": { "type": "string" }, "namespace": { "type": "string" } }, "additionalProperties": false }, "K8sVerb": { "type": "string", "enum": [ "create", "get", "list", "update", "patch", "delete", "deletecollection", "watch", "impersonate" ] }, "AddActionGroup": { "type": "object", "additionalProperties": false, "properties": { "type": { "type": "string", "const": "dev-console.add/action-group" }, "properties": { "type": "object", "properties": { "id": { "type": "string", "description": "ID used to identify the action group." }, "name": { "type": "string", "description": "The title of the action group" }, "insertBefore": { "type": "string", "description": "ID of action group before which this group should be placed" }, "insertAfter": { "type": "string", "description": "ID of action group after which this group should be placed" }, "icon": { "anyOf": [ { "$ref": "#/definitions/EncodedCodeRef" }, { "type": "string" } ], "description": "The perspective display icon." } }, "required": [ "id", "name" ], "additionalProperties": false }, "flags": { "$ref": "#/definitions/ExtensionFlags" } }, "required": [ "properties", "type" ], "description": "This extension allows plugins to contibute a group in the add page of developer console. Groups can be referenced by actions, which will be grouped together in the add action page based on their extension definition. For example, a Serverless plugin can contribute a Serverless group and together with multiple add actions." }, "ImportEnvironment": { "type": "object", "additionalProperties": false, "properties": { "type": { "type": "string", "const": "dev-console.import/environment" }, "properties": { "type": "object", "properties": { "imageStreamName": { "type": "string", "description": "Name of the image stream to provide custom environment variables for" }, "imageStreamTags": { "type": "array", "items": { "type": "string" }, "description": "List of supported image stream tags" }, "environments": { "type": "array", "items": { "$ref": "#/definitions/ImageEnvironment" }, "description": "List of environment variables" } }, "required": [ "imageStreamName", "imageStreamTags", "environments" ], "additionalProperties": false }, "flags": { "$ref": "#/definitions/ExtensionFlags" } }, "required": [ "properties", "type" ], "description": "This extension can be used to specify extra build environment variable fields under the builder image selector in the dev console git import form. When set, the fields will override environment variables of the same name in the build section." }, "ImageEnvironment": { "type": "object", "properties": { "key": { "type": "string", "description": "Environment variable key" }, "label": { "type": "string", "description": "The input field's label" }, "defaultValue": { "type": "string", "description": "Default value to use as a placeholder" }, "description": { "type": "string", "description": "Description of the environment variable" } }, "required": [ "key", "label" ], "additionalProperties": false }, "ClusterGlobalConfig": { "type": "object", "additionalProperties": false, "properties": { "type": { "type": "string", "const": "console.global-config" }, "properties": { "type": "object", "properties": { "id": { "type": "string", "description": "Unique identifier for the cluster config resource instance." }, "name": { "type": "string", "description": "The name of the cluster config resource instance." }, "model": { "$ref": "#/definitions/ExtensionK8sModel", "description": "The model which refers to a cluster config resource." }, "namespace": { "type": "string", "description": "The namespace of the cluster config resource instance." } }, "required": [ "id", "name", "model", "namespace" ], "additionalProperties": false }, "flags": { "$ref": "#/definitions/ExtensionFlags" } }, "required": [ "properties", "type" ], "description": "This extension identifies a resource used to manage the configuration of the cluster. A link to the resource will be added to the Administration - Cluster Settings - Configuration page." }, "HrefNavItem": { "type": "object", "additionalProperties": false, "properties": { "type": { "type": "string", "const": "console.navigation/href" }, "properties": { "type": "object", "additionalProperties": false, "properties": { "name": { "type": "string", "description": "The name of this item." }, "href": { "type": "string", "description": "The link href value." }, "namespaced": { "type": "boolean", "description": "if true, adds /ns/active-namespace to the end" }, "prefixNamespaced": { "type": "boolean", "description": "if true, adds /k8s/ns/active-namespace to the begining" }, "id": { "type": "string", "description": "A unique identifier for this item." }, "perspective": { "type": "string", "description": "The perspective ID to which this item belongs to. If not specified, contributes to the default perspective." }, "section": { "type": "string", "description": "Navigation section to which this item belongs to. If not specified, render this item as a top level link." }, "dataAttributes": { "type": "object", "additionalProperties": { "type": "string" }, "description": "Adds data attributes to the DOM." }, "startsWith": { "type": "array", "items": { "type": "string" }, "description": "Mark this item as active when the URL starts with one of these paths." }, "insertBefore": { "anyOf": [ { "type": "string" }, { "type": "array", "items": { "type": "string" } } ], "description": "Insert this item before the item referenced here. For arrays, the first one found in order is used." }, "insertAfter": { "anyOf": [ { "type": "string" }, { "type": "array", "items": { "type": "string" } } ], "description": "Insert this item after the item referenced here. For arrays, the first one found in order is used. `insertBefore` takes precedence." } }, "required": [ "href", "id", "name" ] }, "flags": { "$ref": "#/definitions/ExtensionFlags" } }, "required": [ "properties", "type" ], "description": "This extension can be used to contribute a navigation item that points to a specific link in the UI." }, "ResourceNSNavItem": { "type": "object", "additionalProperties": false, "properties": { "type": { "type": "string", "const": "console.navigation/resource-ns" }, "properties": { "type": "object", "additionalProperties": false, "properties": { "name": { "type": "string", "description": "Overrides the default name. If not supplied the name of the link will equal the plural value of the model." }, "model": { "$ref": "#/definitions/ExtensionK8sModel", "description": "The model for which this nav item links to." }, "id": { "type": "string", "description": "A unique identifier for this item." }, "perspective": { "type": "string", "description": "The perspective ID to which this item belongs to. If not specified, contributes to the default perspective." }, "section": { "type": "string", "description": "Navigation section to which this item belongs to. If not specified, render this item as a top level link." }, "dataAttributes": { "type": "object", "additionalProperties": { "type": "string" }, "description": "Adds data attributes to the DOM." }, "startsWith": { "type": "array", "items": { "type": "string" }, "description": "Mark this item as active when the URL starts with one of these paths." }, "insertBefore": { "anyOf": [ { "type": "string" }, { "type": "array", "items": { "type": "string" } } ], "description": "Insert this item before the item referenced here. For arrays, the first one found in order is used." }, "insertAfter": { "anyOf": [ { "type": "string" }, { "type": "array", "items": { "type": "string" } } ], "description": "Insert this item after the item referenced here. For arrays, the first one found in order is used. `insertBefore` takes precedence." } }, "required": [ "id", "model" ] }, "flags": { "$ref": "#/definitions/ExtensionFlags" } }, "required": [ "properties", "type" ], "description": "This extension can be used to contribute a navigation item that points to a namespaced resource details page. The K8s model of that resource can be used to define the navigation item." }, "ResourceClusterNavItem": { "type": "object", "additionalProperties": false, "properties": { "type": { "type": "string", "const": "console.navigation/resource-cluster" }, "properties": { "type": "object", "additionalProperties": false, "properties": { "name": { "type": "string", "description": "Overrides the default name. If not supplied the name of the link will equal the plural value of the model." }, "model": { "$ref": "#/definitions/ExtensionK8sModel", "description": "The model for which this nav item links to." }, "id": { "type": "string", "description": "A unique identifier for this item." }, "perspective": { "type": "string", "description": "The perspective ID to which this item belongs to. If not specified, contributes to the default perspective." }, "section": { "type": "string", "description": "Navigation section to which this item belongs to. If not specified, render this item as a top level link." }, "dataAttributes": { "type": "object", "additionalProperties": { "type": "string" }, "description": "Adds data attributes to the DOM." }, "startsWith": { "type": "array", "items": { "type": "string" }, "description": "Mark this item as active when the URL starts with one of these paths." }, "insertBefore": { "anyOf": [ { "type": "string" }, { "type": "array", "items": { "type": "string" } } ], "description": "Insert this item before the item referenced here. For arrays, the first one found in order is used." }, "insertAfter": { "anyOf": [ { "type": "string" }, { "type": "array", "items": { "type": "string" } } ], "description": "Insert this item after the item referenced here. For arrays, the first one found in order is used. `insertBefore` takes precedence." } }, "required": [ "id", "model" ] }, "flags": { "$ref": "#/definitions/ExtensionFlags" } }, "required": [ "properties", "type" ], "description": "This extension can be used to contribute a navigation item that points to a cluster resource details page. The K8s model of that resource can be used to define the navigation item." }, "Separator": { "type": "object", "additionalProperties": false, "properties": { "type": { "type": "string", "const": "console.navigation/separator" }, "properties": { "type": "object", "properties": { "id": { "type": "string", "description": "A unique identifier for this item." }, "perspective": { "type": "string", "description": "The perspective ID to which this item belongs to. If not specified, contributes to the default perspective." }, "section": { "type": "string", "description": "Navigation section to which this item belongs to. If not specified, render this item as a top level link." }, "dataAttributes": { "type": "object", "additionalProperties": { "type": "string" }, "description": "Adds data attributes to the DOM." }, "insertBefore": { "anyOf": [ { "type": "string" }, { "type": "array", "items": { "type": "string" } } ], "description": "Insert this item before the item referenced here. For arrays, the first one found in order is used." }, "insertAfter": { "anyOf": [ { "type": "string" }, { "type": "array", "items": { "type": "string" } } ], "description": "Insert this item after the item referenced here. For arrays, the first one found in order is used. `insertBefore` takes precedence." } }, "required": [ "id" ], "additionalProperties": false }, "flags": { "$ref": "#/definitions/ExtensionFlags" } }, "required": [ "properties", "type" ], "description": "This extension can be used to add a separator between navigation items in the navigation." }, "NavSection": { "type": "object", "additionalProperties": false, "properties": { "type": { "type": "string", "const": "console.navigation/section" }, "properties": { "type": "object", "additionalProperties": false, "properties": { "name": { "type": "string", "description": "Name of this section. If not supplied, only a separator will be shown above the section." }, "id": { "type": "string", "description": "A unique identifier for this item." }, "perspective": { "type": "string", "description": "The perspective ID to which this item belongs to. If not specified, contributes to the default perspective." }, "dataAttributes": { "type": "object", "additionalProperties": { "type": "string" }, "description": "Adds data attributes to the DOM." }, "insertBefore": { "anyOf": [ { "type": "string" }, { "type": "array", "items": { "type": "string" } } ], "description": "Insert this item before the item referenced here. For arrays, the first one found in order is used." }, "insertAfter": { "anyOf": [ { "type": "string" }, { "type": "array", "items": { "type": "string" } } ], "description": "Insert this item after the item referenced here. For arrays, the first one found in order is used. `insertBefore` takes precedence." } }, "required": [ "id" ] }, "flags": { "$ref": "#/definitions/ExtensionFlags" } }, "required": [ "properties", "type" ], "description": "This extension can be used to define a new section of navigation items in the navigation tab." }, "FileUpload": { "type": "object", "additionalProperties": false, "properties": { "type": { "type": "string", "const": "console.file-upload" }, "properties": { "type": "object", "properties": { "fileExtensions": { "type": "array", "items": { "type": "string" }, "description": "Supported file extensions." }, "handler": { "$ref": "#/definitions/EncodedCodeRef", "description": "Function which handles the file drop action." } }, "required": [ "fileExtensions", "handler" ], "additionalProperties": false }, "flags": { "$ref": "#/definitions/ExtensionFlags" } }, "required": [ "properties", "type" ], "description": "This extension can be used to provide a handler for the file drop action on specific file extensions." }, "ModelMetadata": { "type": "object", "additionalProperties": false, "properties": { "type": { "type": "string", "const": "console.model-metadata" }, "properties": { "type": "object", "properties": { "model": { "$ref": "#/definitions/ExtensionK8sGroupModel", "description": "The model to customize. May specify only a group, or optional version and kind." }, "badge": { "$ref": "#/definitions/ModelBadge", "description": "Whether to consider this model reference as tech preview or dev preview." }, "color": { "type": "string", "description": "The color to associate to this model." }, "label": { "type": "string", "description": "Override the label. Requires `kind` be provided." }, "labelPlural": { "type": "string", "description": "Override the plural label. Requires `kind` be provided." }, "abbr": { "type": "string", "description": "Customize the abbreviation. Defaults to All uppercase chars in the kind up to 4 characters long. Requires `kind` be provided." } }, "required": [ "model" ], "additionalProperties": false }, "flags": { "$ref": "#/definitions/ExtensionFlags" } }, "required": [ "properties", "type" ], "description": "Customize the display of models by overriding values retrieved and generated through API discovery." }, "ExtensionK8sGroupModel": { "type": "object", "properties": { "group": { "type": "string" }, "version": { "type": "string" }, "kind": { "type": "string" } }, "required": [ "group" ], "additionalProperties": false }, "ModelBadge": { "type": "string", "enum": [ "dev", "tech" ] }, "AlertAction": { "type": "object", "additionalProperties": false, "properties": { "type": { "type": "string", "const": "console.alert-action" }, "properties": { "type": "object", "properties": { "alert": { "type": "string", "description": "Alert name as defined by `alert.rule.name` property" }, "text": { "type": "string", "description": "Action text" }, "action": { "$ref": "#/definitions/EncodedCodeRef", "description": "Function to perform side effect" } }, "required": [ "alert", "text", "action" ], "additionalProperties": false }, "flags": { "$ref": "#/definitions/ExtensionFlags" } }, "required": [ "properties", "type" ], "description": "This extension can be used to trigger a specific action when a specific Prometheus alert is observed by the Console based on its `rule.name` value." }, "StorageProvider": { "type": "object", "additionalProperties": false, "properties": { "type": { "type": "string", "const": "console.storage-provider" }, "properties": { "type": "object", "properties": { "name": { "type": "string", "description": "Displayed name of the provider." }, "Component": { "$ref": "#/definitions/EncodedCodeRef", "description": "Provider specific component to render." } }, "required": [ "name", "Component" ], "additionalProperties": false }, "flags": { "$ref": "#/definitions/ExtensionFlags" } }, "required": [ "properties", "type" ], "description": "This extension can be used to contribute a new storage provider to select, when attaching storage and a provider specific component." }, "TelemetryListener": { "type": "object", "additionalProperties": false, "properties": { "type": { "type": "string", "const": "console.telemetry/listener" }, "properties": { "type": "object", "properties": { "listener": { "$ref": "#/definitions/EncodedCodeRef", "description": "Listen for telemetry events" } }, "required": [ "listener" ], "additionalProperties": false }, "flags": { "$ref": "#/definitions/ExtensionFlags" } }, "required": [ "properties", "type" ], "description": "This component can be used to register a listener function receiving telemetry events. These events include user identification, page navigation, and other application specific events. The listener may use this data for reporting and analytics purposes." }, "SupportedCatalogExtensions": { "anyOf": [ { "$ref": "#/definitions/CatalogItemType" }, { "$ref": "#/definitions/CatalogItemTypeMetadata" }, { "$ref": "#/definitions/CatalogItemProvider" }, { "$ref": "#/definitions/CatalogItemFilter" }, { "$ref": "#/definitions/CatalogItemMetadataProvider" } ] }, "CatalogItemType": { "type": "object", "additionalProperties": false, "properties": { "type": { "type": "string", "const": "console.catalog/item-type" }, "properties": { "type": "object", "properties": { "type": { "type": "string", "description": "Type for the catalog item." }, "title": { "type": "string", "description": "Title for the catalog item." }, "catalogDescription": { "anyOf": [ { "type": "string" }, { "$ref": "#/definitions/EncodedCodeRef" } ], "description": "Description for the type specific catalog." }, "typeDescription": { "type": "string", "description": "Description for the catalog item type." }, "filters": { "type": "array", "items": { "$ref": "#/definitions/CatalogItemAttribute" }, "description": "Custom filters specific to the catalog item." }, "groupings": { "type": "array", "items": { "$ref": "#/definitions/CatalogItemAttribute" }, "description": "Custom groupings specific to the catalog item." } }, "required": [