From d28bfeeda5dae5279214f9401ad3454901a57af1 Mon Sep 17 00:00:00 2001 From: Andrew Couch Date: Mon, 6 Nov 2017 16:16:51 -0500 Subject: [PATCH] ui: demo of UI CCL component --- .../views/shared/components/licenseType/index.tsx | 14 ++++++++++++++ pkg/ui/src/views/app/containers/layout/index.tsx | 2 ++ .../views/shared/components/licenseType/index.tsx | 14 ++++++++++++++ 3 files changed, 30 insertions(+) create mode 100644 pkg/ui/ccl/src/views/shared/components/licenseType/index.tsx create mode 100644 pkg/ui/src/views/shared/components/licenseType/index.tsx diff --git a/pkg/ui/ccl/src/views/shared/components/licenseType/index.tsx b/pkg/ui/ccl/src/views/shared/components/licenseType/index.tsx new file mode 100644 index 000000000000..b993834b8725 --- /dev/null +++ b/pkg/ui/ccl/src/views/shared/components/licenseType/index.tsx @@ -0,0 +1,14 @@ +import React from "react"; + +/** + * LicenseType is an indicator showing the current build license. + */ +export default class LicenseType extends React.Component<{}, {}> { + render() { + return ( +
+

CCL

+
+ ); + } +} diff --git a/pkg/ui/src/views/app/containers/layout/index.tsx b/pkg/ui/src/views/app/containers/layout/index.tsx index b3ad607d6b13..fe5581c8f2ae 100644 --- a/pkg/ui/src/views/app/containers/layout/index.tsx +++ b/pkg/ui/src/views/app/containers/layout/index.tsx @@ -7,6 +7,7 @@ import { TitledComponent } from "src/interfaces/layout"; import NavigationBar from "src/views/app/components/layoutSidebar"; import TimeWindowManager from "src/views/app/containers/timewindow"; import AlertBanner from "src/views/app/containers/alertBanner"; +import LicenseType from "src/views/shared/components/licenseType"; function isTitledComponent(obj: Object | TitledComponent): obj is TitledComponent { return obj && _.isFunction((obj as TitledComponent).title); @@ -39,6 +40,7 @@ export default class extends React.Component { + { // TODO(mrtracy): The title can be moved down to individual pages, // it is not always the top element on the page (for example, on diff --git a/pkg/ui/src/views/shared/components/licenseType/index.tsx b/pkg/ui/src/views/shared/components/licenseType/index.tsx new file mode 100644 index 000000000000..f7b65a3b393a --- /dev/null +++ b/pkg/ui/src/views/shared/components/licenseType/index.tsx @@ -0,0 +1,14 @@ +import React from "react"; + +/** + * LicenseType is an indicator showing the current build license. + */ +export default class LicenseType extends React.Component<{}, {}> { + render() { + return ( +
+

OSS

+
+ ); + } +}