From c52d5e108434f857f79926723732522ee38f6a91 Mon Sep 17 00:00:00 2001 From: Brandon Millman Date: Sun, 10 Jun 2018 19:49:40 -0700 Subject: Refactor into BulletedItemList component --- .../website/ts/pages/jobs/bulleted_item_list.tsx | 30 ++++++++++++++++++++++ packages/website/ts/pages/jobs/values.tsx | 27 +++---------------- 2 files changed, 33 insertions(+), 24 deletions(-) create mode 100644 packages/website/ts/pages/jobs/bulleted_item_list.tsx (limited to 'packages/website') diff --git a/packages/website/ts/pages/jobs/bulleted_item_list.tsx b/packages/website/ts/pages/jobs/bulleted_item_list.tsx new file mode 100644 index 000000000..108f31e00 --- /dev/null +++ b/packages/website/ts/pages/jobs/bulleted_item_list.tsx @@ -0,0 +1,30 @@ +import { colors } from '@0xproject/react-shared'; +import * as _ from 'lodash'; +import * as React from 'react'; + +import { BulletedItem, BulletedItemProps } from 'ts/pages/jobs/bulleted_item'; + +export interface BulletedItemListProps { + headerText: string; + bulletedItems: BulletedItemProps[]; +} +export const BulletedItemList = (props: BulletedItemListProps) => { + return ( +
+
+ {props.headerText} +
+
+ {_.map(props.bulletedItems, bulletedItemProps => { + return ( + + ); + })} +
+
+ ); +}; diff --git a/packages/website/ts/pages/jobs/values.tsx b/packages/website/ts/pages/jobs/values.tsx index 9bb98d016..37e62d23b 100644 --- a/packages/website/ts/pages/jobs/values.tsx +++ b/packages/website/ts/pages/jobs/values.tsx @@ -2,7 +2,8 @@ import { colors } from '@0xproject/react-shared'; import * as _ from 'lodash'; import * as React from 'react'; -import { BulletedItem, BulletedItemProps } from 'ts/pages/jobs/bulleted_item'; +import { BulletedItemProps } from 'ts/pages/jobs/bulleted_item'; +import { BulletedItemList } from 'ts/pages/jobs/bulleted_item_list'; const BULLETED_ITEMS: BulletedItemProps[] = [ { @@ -22,26 +23,4 @@ const BULLETED_ITEMS: BulletedItemProps[] = [ }, ]; -export const Values = () => { - const isSmallScreen = false; - return ( -
-
-
- Our Values -
-
- {_.map(BULLETED_ITEMS, bulletedItemProps => { - return ( - - ); - })} -
-
-
- ); -}; +export const Values = () => ; -- cgit v1.2.3