Skip to content

Commit

Permalink
Merge pull request #7865 from sahil143/odc-5346
Browse files Browse the repository at this point in the history
Bug 1917658: add tech preview badge for camel K operator instances
  • Loading branch information
openshift-merge-robot committed Jan 19, 2021
2 parents 251268d + cfcd93c commit 078c69a
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 2 deletions.
Expand Up @@ -2,7 +2,7 @@ import * as React from 'react';
import { Helmet } from 'react-helmet';
import { RouteComponentProps } from 'react-router';
import { useTranslation } from 'react-i18next';
import { PageBody } from '@console/shared';
import { PageBody, TechPreviewBadge } from '@console/shared';
import { LoadingInline, PageHeading } from '@console/internal/components/utils';
import NamespacedPage, {
NamespacedPageVariants,
Expand Down Expand Up @@ -36,7 +36,10 @@ const EventSourcePage: React.FC<EventSourcePageProps> = ({ match, location }) =>
<Helmet>
<title>{t('knative-plugin~Event Source')}</title>
</Helmet>
<PageHeading title={t('knative-plugin~Create Event Source')}>
<PageHeading
title={t('knative-plugin~Create Event Source')}
badge={isKameletSource ? <TechPreviewBadge /> : null}
>
{t(
'knative-plugin~Create an Event source to register interest in a class of events from a particular system. Configure using the YAML and form views.',
)}
Expand Down
19 changes: 19 additions & 0 deletions frontend/packages/knative-plugin/src/models.ts
@@ -1,6 +1,7 @@
import { chart_color_cyan_400 as knativeServingColor } from '@patternfly/react-tokens/dist/js/chart_color_cyan_400';
import { chart_color_red_300 as knativeEventingColor } from '@patternfly/react-tokens/dist/js/chart_color_red_300';
import { K8sKind } from '@console/internal/module/k8s';
import { BadgeType } from '@console/shared/src/components/badges/badge-factory';
import {
KNATIVE_EVENT_SOURCE_APIGROUP,
KNATIVE_EVENT_SOURCE_APIGROUP_DEP,
Expand Down Expand Up @@ -291,6 +292,7 @@ export const CamelIntegrationModel: K8sKind = {
namespaced: true,
crd: true,
color: knativeEventingColor.value,
badge: BadgeType.TECH,
};

export const KafkaModel: K8sKind = {
Expand Down Expand Up @@ -333,6 +335,7 @@ export const CamelKameletBindingModel: K8sKind = {
namespaced: true,
crd: true,
color: knativeEventingColor.value,
badge: BadgeType.TECH,
};

export const CamelKameletModel: K8sKind = {
Expand All @@ -347,4 +350,20 @@ export const CamelKameletModel: K8sKind = {
namespaced: true,
crd: true,
color: knativeEventingColor.value,
badge: BadgeType.TECH,
};

export const CamelIntegrationPlatformModel: K8sKind = {
apiGroup: CAMEL_APIGROUP,
apiVersion,
kind: 'IntegrationPlatform',
label: 'Integration Platform',
labelPlural: 'Integration Platforms',
plural: 'integrationplatforms',
id: 'integrationplatform',
abbr: 'IP',
namespaced: true,
crd: true,
color: knativeEventingColor.value,
badge: BadgeType.TECH,
};

0 comments on commit 078c69a

Please sign in to comment.