Skip to content

Commit 7e0a4ad

Browse files
feat: add commercial support and training page (#694)
## This PR - adds a support and training page. - light/dark mode support - mobile friendly - consolidate card styles - added commercial support requirements ### Related Issues Fixes #390 ### Notes Direct link to the preview: https://deploy-preview-694--openfeature.netlify.app/support-training This is a continuation of @thisisobate [PR](#416). I intended to push to that fork. Sorry, I didn't intend to hijack your PR. If you'd prefer, I can close this, and we can keep working on the one you started. ### Follow-up Tasks Post in the OpenFeature Slack channel requesting vendors add themselves. --------- Signed-off-by: thisisobate <[email protected]> Signed-off-by: Michael Beemer <[email protected]> Co-authored-by: thisisobate <[email protected]>
1 parent 4116d48 commit 7e0a4ad

File tree

11 files changed

+260
-43
lines changed

11 files changed

+260
-43
lines changed

docusaurus.config.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -73,6 +73,10 @@ const themeConfig: ThemeCommonConfig & AlgoliaThemeConfig = {
7373
docsPluginId: 'community',
7474
label: 'Community',
7575
},
76+
{
77+
to: '/support-training',
78+
label: 'Support & Training',
79+
},
7680
{
7781
type: 'doc',
7882
docId: 'tutorials/five-minutes-to-feature-flags',

src/components/custom/OpenFeatureComponentCard/index.tsx

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,6 @@
1-
import clsx from 'clsx';
21
import React from 'react';
32
import { FontAwesomeCardData, SvgCardData, SvgOrFonticon } from '../SvgOrFonticon';
43
import { faCircleCheck, faSadCry } from '@fortawesome/free-regular-svg-icons';
5-
import styles from './styles.module.css';
64
import { FontAwesomeIcon } from '@fortawesome/react-fontawesome';
75
import Link from '@docusaurus/Link';
86

@@ -23,7 +21,6 @@ type CardData = {
2321
};
2422

2523
export type OpenFeatureComponentCardData = CardData & (SvgCardData | FontAwesomeCardData);
26-
2724
/**
2825
* A card to be used for linking (externally or internally) to specific technologies (SDKs, hooks, providers)
2926
*/
@@ -32,13 +29,13 @@ export class OpenFeatureComponentCard extends React.Component<OpenFeatureCompone
3229
const props = this.props as CardData & Partial<SvgCardData & FontAwesomeCardData>;
3330
const external = props.href.startsWith('http');
3431
return (
35-
<Link to={props.href} style={{ position: 'relative' }} className={clsx('card padding--lg', styles.cardContainer)}>
32+
<Link to={props.href} style={{ position: 'relative' }} className={'card padding--lg card-container'}>
3633
<div style={{ height: 0, position: 'absolute', right: 20, top: 20 }}>{external ? '🔗' : ''}</div>
3734

3835
<SvgOrFonticon svg={props.svg} iconDefinition={props.iconDefinition} />
39-
<h1 className={clsx('text--truncate', styles.cardTitle)}>{this.props.title}</h1>
40-
<h2 className={clsx(styles.cardDescription)}>{this.props.description}</h2>
41-
<div className={clsx(styles.vendorOfficialContainer)}>
36+
<h1 className={'text--truncate text-lg'}>{this.props.title}</h1>
37+
<h2 className={'text-sm'}>{this.props.description}</h2>
38+
<div className={'flex justify-end'}>
4239
{props.vendorOfficial ? (
4340
<FontAwesomeIcon icon={faCircleCheck} title="Official, vendor-supported provider" />
4441
) : (

src/components/custom/OpenFeatureComponentCard/styles.module.css

Lines changed: 0 additions & 36 deletions
This file was deleted.

src/css/custom.css

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,25 @@
5050
text-align: left;
5151
}
5252

53+
.card-container {
54+
--ifm-link-color: var(--ifm-color-emphasis-800);
55+
--ifm-link-hover-color: var(--ifm-color-emphasis-700);
56+
--ifm-link-hover-decoration: none;
57+
58+
box-shadow: 0 1.5px 3px 0 rgb(0 0 0 / 15%);
59+
border: 1px solid var(--ifm-color-emphasis-200);
60+
transition: all var(--ifm-transition-fast) ease;
61+
transition-property: border, box-shadow;
62+
}
63+
64+
.card-container:hover {
65+
border-color: var(--ifm-color-primary);
66+
box-shadow: 0 3px 6px 0 rgb(0 0 0 / 20%);
67+
}
68+
69+
.card-container *:last-child {
70+
margin-bottom: 0;
71+
}
5372
.code-block-diff-remove-line{
5473
background-color: #ff00001f;
5574
display: block;
Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
import type { ComponentType, SVGProps } from 'react';
2+
3+
import DevCycleSvg from '@site/static/img/vendors/devcycle.svg';
4+
import FliptSvg from '@site/static/img/vendors/flipt.svg';
5+
import FlagsmithSvg from '@site/static/img/vendors/flagsmith.svg';
6+
import LaunchDarklySvg from '@site/static/img/vendors/launchdarkly.svg';
7+
8+
type CommercialSupportType = {
9+
name: string;
10+
href: string;
11+
svg?: ComponentType<SVGProps<SVGSVGElement>>;
12+
};
13+
14+
/**
15+
* Companies that provide commercial support for OpenFeature should be
16+
* added to this list alphabetically by company name. The extent of the
17+
* support provided is the responsibility of each company to define.
18+
*
19+
* The minimum requirements for adding a company to this list are:
20+
* - At least one supported provider listed in the OpenFeature ecosystem
21+
* - Publicly available mention of OpenFeature support on the company's website or documentation
22+
*/
23+
export const CommercialSupportList: CommercialSupportType[] = [
24+
{
25+
name: 'DevCycle',
26+
href: 'https://docs.devcycle.com/integrations/openfeature',
27+
svg: DevCycleSvg,
28+
},
29+
{
30+
name: 'Flagsmith',
31+
href: 'https://www.flagsmith.com/openfeature',
32+
svg: FlagsmithSvg,
33+
},
34+
{
35+
name: 'Flipt',
36+
href: 'https://docs.flipt.io/integration/openfeature',
37+
svg: FliptSvg,
38+
},
39+
{
40+
name: 'LaunchDarkly',
41+
href: 'https://docs.launchdarkly.com/sdk/openfeature/',
42+
svg: LaunchDarklySvg,
43+
},
44+
].sort((a, b) => a.name.localeCompare(b.name));

src/datasets/support/training.ts

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
import { IconDefinition as BrandsIconDefinition } from '@fortawesome/free-brands-svg-icons';
2+
import { IconDefinition as FreeIconDefinition } from '@fortawesome/free-solid-svg-icons';
3+
import { faYoutube } from '@fortawesome/free-brands-svg-icons';
4+
5+
type ResourcesType = {
6+
title: string;
7+
description?: string;
8+
href: string;
9+
iconDefinition?: BrandsIconDefinition | FreeIconDefinition;
10+
};
11+
12+
export const TrainingResources: ResourcesType[] = [
13+
{
14+
title: 'OpenFeature Fundamentals',
15+
description: 'An introduction to the core concepts of OpenFeature',
16+
href: 'https://www.youtube.com/watch?v=heQ83k15ZE4&list=PLiQt8D1ofl8zs2zoiMNI8WRdNQ8GUy84I',
17+
iconDefinition: faYoutube,
18+
},
19+
];

src/pages/support-training.tsx

Lines changed: 64 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,64 @@
1+
import React from 'react';
2+
import { OpenFeatureComponentCard } from '../components/custom/OpenFeatureComponentCard';
3+
import Layout from '@theme/Layout';
4+
import { CommercialSupportList } from '../datasets/support/commercial-support';
5+
import { TrainingResources } from '../datasets/support/training';
6+
import Link from '@docusaurus/Link';
7+
8+
export default function Support(): JSX.Element {
9+
return (
10+
<Layout title="Support" description="Support and Training">
11+
<section className="max-w-6xl mx-auto m-16 px-16 xl:px-0">
12+
<div className="text-center">
13+
<h1>Support & Training</h1>
14+
</div>
15+
<div className="mb-16">
16+
<h3>Courses</h3>
17+
<div className="flex flex-wrap gap-8 justify-center md:justify-start">
18+
{TrainingResources.map((resource) => (
19+
<OpenFeatureComponentCard
20+
title={resource.title}
21+
href={resource.href}
22+
description={resource.description}
23+
iconDefinition={resource.iconDefinition}
24+
/>
25+
))}
26+
</div>
27+
</div>
28+
<div className="mb-16">
29+
<h3>Commercial support</h3>
30+
<div className="flex flex-wrap gap-8 justify-center md:justify-start">
31+
{CommercialSupportList.map(({ href, name, svg: Svg }) => (
32+
<Link
33+
to={href}
34+
title={name}
35+
className="card card-container padding--lg dark:bg-white w-[362px] h-44 relative"
36+
>
37+
<div style={{ height: 0, position: 'absolute', right: 10, top: 10 }}>{'🔗'}</div>
38+
<div className="flex justify-center items-center h-full">
39+
<Svg className="w-full h-full" />
40+
</div>
41+
</Link>
42+
))}
43+
</div>
44+
</div>
45+
<div className="mb-16">
46+
<h3>Add a resource</h3>
47+
<p>
48+
If you have developed an OpenFeature training program or offer related services, you can add yourself to
49+
this page with a pull request.
50+
</p>
51+
<div className="flex justify-center mt-16">
52+
<Link
53+
className="btn text-white hover:text-white bg-purple-600 hover:bg-purple-700 w-full mb-4 sm:w-auto sm:mb-0"
54+
to="https://github.com/open-feature/openfeature.dev"
55+
>
56+
Add your company
57+
</Link>
58+
</div>
59+
</div>
60+
</section>
61+
</Layout>
62+
);
63+
}
64+

static/img/vendors/devcycle.svg

Lines changed: 44 additions & 0 deletions
Loading

0 commit comments

Comments
 (0)