From 56d27400ac421bd9410db781cfb72db56e77f5d2 Mon Sep 17 00:00:00 2001 From: Tom Moor Date: Sat, 21 Oct 2017 12:08:33 -0700 Subject: [PATCH] New Icons --- frontend/components/Icon/BackIcon.js | 23 +++++++++++++++++ frontend/components/Icon/BoldIcon.js | 3 +-- frontend/components/Icon/BulletedListIcon.js | 3 +-- frontend/components/Icon/ChevronIcon.js | 3 +-- frontend/components/Icon/CodeIcon.js | 4 +-- frontend/components/Icon/CollapsedIcon.js | 20 +++++++++++++++ frontend/components/Icon/CollectionIcon.js | 25 +++++++++++++++++++ frontend/components/Icon/DocumentIcon.js | 23 +++++++++++++++++ frontend/components/Icon/EditIcon.js | 20 +++++++++++++++ frontend/components/Icon/Heading1Icon.js | 4 +-- frontend/components/Icon/Heading2Icon.js | 3 +-- frontend/components/Icon/HomeIcon.js | 20 +++++++++++++++ .../components/Icon/HorizontalRuleIcon.js | 20 +++++++++++++++ frontend/components/Icon/ImageIcon.js | 20 +++++++++++++++ frontend/components/Icon/ItalicIcon.js | 3 +-- frontend/components/Icon/LinkIcon.js | 3 +-- frontend/components/Icon/OrderedListIcon.js | 3 +-- frontend/components/Icon/SearchIcon.js | 20 +++++++++++++++ frontend/components/Icon/StarredIcon.js | 20 +++++++++++++++ frontend/components/Icon/StrikethroughIcon.js | 3 +-- frontend/components/Icon/TodoListIcon.js | 20 +++++++++++++++ frontend/components/Icon/UnderlinedIcon.js | 21 ---------------- frontend/menus/BlockMenu.js | 13 ++++++---- 23 files changed, 251 insertions(+), 46 deletions(-) create mode 100644 frontend/components/Icon/BackIcon.js create mode 100644 frontend/components/Icon/CollapsedIcon.js create mode 100644 frontend/components/Icon/CollectionIcon.js create mode 100644 frontend/components/Icon/DocumentIcon.js create mode 100644 frontend/components/Icon/EditIcon.js create mode 100644 frontend/components/Icon/HomeIcon.js create mode 100644 frontend/components/Icon/HorizontalRuleIcon.js create mode 100644 frontend/components/Icon/ImageIcon.js create mode 100644 frontend/components/Icon/SearchIcon.js create mode 100644 frontend/components/Icon/StarredIcon.js create mode 100644 frontend/components/Icon/TodoListIcon.js delete mode 100644 frontend/components/Icon/UnderlinedIcon.js diff --git a/frontend/components/Icon/BackIcon.js b/frontend/components/Icon/BackIcon.js new file mode 100644 index 000000000..bc082e7fd --- /dev/null +++ b/frontend/components/Icon/BackIcon.js @@ -0,0 +1,23 @@ +// @flow +import React from 'react'; +import Icon from './Icon'; +import type { Props } from './Icon'; + +export default function BackIcon(props: Props) { + return ( + + + + + + ); +} diff --git a/frontend/components/Icon/BoldIcon.js b/frontend/components/Icon/BoldIcon.js index 011686bda..284d8daa8 100644 --- a/frontend/components/Icon/BoldIcon.js +++ b/frontend/components/Icon/BoldIcon.js @@ -13,8 +13,7 @@ export default function BoldIcon(props: Props) { width="24" xmlns="http://www.w3.org/2000/svg" > - - + ); diff --git a/frontend/components/Icon/BulletedListIcon.js b/frontend/components/Icon/BulletedListIcon.js index b87afa195..01be8d1f8 100644 --- a/frontend/components/Icon/BulletedListIcon.js +++ b/frontend/components/Icon/BulletedListIcon.js @@ -13,8 +13,7 @@ export default function BulletedListIcon(props: Props) { width="24" xmlns="http://www.w3.org/2000/svg" > - - + ); diff --git a/frontend/components/Icon/ChevronIcon.js b/frontend/components/Icon/ChevronIcon.js index 88453bbce..65e59b550 100644 --- a/frontend/components/Icon/ChevronIcon.js +++ b/frontend/components/Icon/ChevronIcon.js @@ -13,8 +13,7 @@ export default function NextIcon(props: Props) { width="24" xmlns="http://www.w3.org/2000/svg" > - - + ); diff --git a/frontend/components/Icon/CodeIcon.js b/frontend/components/Icon/CodeIcon.js index 1116cb68b..246492684 100644 --- a/frontend/components/Icon/CodeIcon.js +++ b/frontend/components/Icon/CodeIcon.js @@ -13,8 +13,8 @@ export default function CodeIcon(props: Props) { width="24" xmlns="http://www.w3.org/2000/svg" > - - + + {' '} ); diff --git a/frontend/components/Icon/CollapsedIcon.js b/frontend/components/Icon/CollapsedIcon.js new file mode 100644 index 000000000..76ecdcfeb --- /dev/null +++ b/frontend/components/Icon/CollapsedIcon.js @@ -0,0 +1,20 @@ +// @flow +import React from 'react'; +import Icon from './Icon'; +import type { Props } from './Icon'; + +export default function CollapsedIcon(props: Props) { + return ( + + + + + + ); +} diff --git a/frontend/components/Icon/CollectionIcon.js b/frontend/components/Icon/CollectionIcon.js new file mode 100644 index 000000000..eddb11a2d --- /dev/null +++ b/frontend/components/Icon/CollectionIcon.js @@ -0,0 +1,25 @@ +// @flow +import React from 'react'; +import Icon from './Icon'; +import type { Props } from './Icon'; + +export default function CollectionIcon({ + expanded, + ...rest +}: Props & { expanded: boolean }) { + return ( + + + {expanded + ? + : } + + + ); +} diff --git a/frontend/components/Icon/DocumentIcon.js b/frontend/components/Icon/DocumentIcon.js new file mode 100644 index 000000000..8a7dc304c --- /dev/null +++ b/frontend/components/Icon/DocumentIcon.js @@ -0,0 +1,23 @@ +// @flow +import React from 'react'; +import Icon from './Icon'; +import type { Props } from './Icon'; + +export default function DocumentIcon(props: Props) { + return ( + + + + + + ); +} diff --git a/frontend/components/Icon/EditIcon.js b/frontend/components/Icon/EditIcon.js new file mode 100644 index 000000000..e24b9304e --- /dev/null +++ b/frontend/components/Icon/EditIcon.js @@ -0,0 +1,20 @@ +// @flow +import React from 'react'; +import Icon from './Icon'; +import type { Props } from './Icon'; + +export default function EditIcon(props: Props) { + return ( + + + + + + ); +} diff --git a/frontend/components/Icon/Heading1Icon.js b/frontend/components/Icon/Heading1Icon.js index 1dc440549..ea54065ee 100644 --- a/frontend/components/Icon/Heading1Icon.js +++ b/frontend/components/Icon/Heading1Icon.js @@ -13,8 +13,8 @@ export default function Heading1Icon(props: Props) { width="24" xmlns="http://www.w3.org/2000/svg" > - - + + {' '} ); diff --git a/frontend/components/Icon/Heading2Icon.js b/frontend/components/Icon/Heading2Icon.js index 46b115906..1ac85828a 100644 --- a/frontend/components/Icon/Heading2Icon.js +++ b/frontend/components/Icon/Heading2Icon.js @@ -13,8 +13,7 @@ export default function Heading2Icon(props: Props) { width="24" xmlns="http://www.w3.org/2000/svg" > - - + ); diff --git a/frontend/components/Icon/HomeIcon.js b/frontend/components/Icon/HomeIcon.js new file mode 100644 index 000000000..ce807c01a --- /dev/null +++ b/frontend/components/Icon/HomeIcon.js @@ -0,0 +1,20 @@ +// @flow +import React from 'react'; +import Icon from './Icon'; +import type { Props } from './Icon'; + +export default function HomeIcon(props: Props) { + return ( + + + + + + ); +} diff --git a/frontend/components/Icon/HorizontalRuleIcon.js b/frontend/components/Icon/HorizontalRuleIcon.js new file mode 100644 index 000000000..42382a65d --- /dev/null +++ b/frontend/components/Icon/HorizontalRuleIcon.js @@ -0,0 +1,20 @@ +// @flow +import React from 'react'; +import Icon from './Icon'; +import type { Props } from './Icon'; + +export default function HorizontalRuleIcon(props: Props) { + return ( + + + + + + ); +} diff --git a/frontend/components/Icon/ImageIcon.js b/frontend/components/Icon/ImageIcon.js new file mode 100644 index 000000000..9ba5fd5f8 --- /dev/null +++ b/frontend/components/Icon/ImageIcon.js @@ -0,0 +1,20 @@ +// @flow +import React from 'react'; +import Icon from './Icon'; +import type { Props } from './Icon'; + +export default function ImageIcon(props: Props) { + return ( + + + + + + ); +} diff --git a/frontend/components/Icon/ItalicIcon.js b/frontend/components/Icon/ItalicIcon.js index 9b194b6b0..4a550843c 100644 --- a/frontend/components/Icon/ItalicIcon.js +++ b/frontend/components/Icon/ItalicIcon.js @@ -13,8 +13,7 @@ export default function ItalicIcon(props: Props) { width="24" xmlns="http://www.w3.org/2000/svg" > - - + ); diff --git a/frontend/components/Icon/LinkIcon.js b/frontend/components/Icon/LinkIcon.js index 5f4c80e2f..5a8ca7d78 100644 --- a/frontend/components/Icon/LinkIcon.js +++ b/frontend/components/Icon/LinkIcon.js @@ -13,8 +13,7 @@ export default function LinkIcon(props: Props) { width="24" xmlns="http://www.w3.org/2000/svg" > - - + ); diff --git a/frontend/components/Icon/OrderedListIcon.js b/frontend/components/Icon/OrderedListIcon.js index 89e51f225..8bb2836c4 100644 --- a/frontend/components/Icon/OrderedListIcon.js +++ b/frontend/components/Icon/OrderedListIcon.js @@ -13,8 +13,7 @@ export default function OrderedListIcon(props: Props) { width="24" xmlns="http://www.w3.org/2000/svg" > - - + ); diff --git a/frontend/components/Icon/SearchIcon.js b/frontend/components/Icon/SearchIcon.js new file mode 100644 index 000000000..76d523f71 --- /dev/null +++ b/frontend/components/Icon/SearchIcon.js @@ -0,0 +1,20 @@ +// @flow +import React from 'react'; +import Icon from './Icon'; +import type { Props } from './Icon'; + +export default function SearchIcon(props: Props) { + return ( + + + + + + ); +} diff --git a/frontend/components/Icon/StarredIcon.js b/frontend/components/Icon/StarredIcon.js new file mode 100644 index 000000000..fdf6b2e6a --- /dev/null +++ b/frontend/components/Icon/StarredIcon.js @@ -0,0 +1,20 @@ +// @flow +import React from 'react'; +import Icon from './Icon'; +import type { Props } from './Icon'; + +export default function StarredIcon(props: Props) { + return ( + + + + + + ); +} diff --git a/frontend/components/Icon/StrikethroughIcon.js b/frontend/components/Icon/StrikethroughIcon.js index 27c8d1b2c..94bc9448b 100644 --- a/frontend/components/Icon/StrikethroughIcon.js +++ b/frontend/components/Icon/StrikethroughIcon.js @@ -13,8 +13,7 @@ export default function StrikethroughIcon(props: Props) { width="24" xmlns="http://www.w3.org/2000/svg" > - - + ); diff --git a/frontend/components/Icon/TodoListIcon.js b/frontend/components/Icon/TodoListIcon.js new file mode 100644 index 000000000..f6ba15c31 --- /dev/null +++ b/frontend/components/Icon/TodoListIcon.js @@ -0,0 +1,20 @@ +// @flow +import React from 'react'; +import Icon from './Icon'; +import type { Props } from './Icon'; + +export default function TodoListIcon(props: Props) { + return ( + + + + + + ); +} diff --git a/frontend/components/Icon/UnderlinedIcon.js b/frontend/components/Icon/UnderlinedIcon.js deleted file mode 100644 index 14379e98c..000000000 --- a/frontend/components/Icon/UnderlinedIcon.js +++ /dev/null @@ -1,21 +0,0 @@ -// @flow -import React from 'react'; -import Icon from './Icon'; -import type { Props } from './Icon'; - -export default function UnderlinedIcon(props: Props) { - return ( - - - - - - - ); -} diff --git a/frontend/menus/BlockMenu.js b/frontend/menus/BlockMenu.js index 5cd3e6117..ebdd24143 100644 --- a/frontend/menus/BlockMenu.js +++ b/frontend/menus/BlockMenu.js @@ -1,6 +1,9 @@ // @flow import React, { Component } from 'react'; -import Icon from 'components/Icon'; +import ImageIcon from 'components/Icon/ImageIcon'; +import BulletedListIcon from 'components/Icon/BulletedListIcon'; +import HorizontalRuleIcon from 'components/Icon/HorizontalRuleIcon'; +import TodoListIcon from 'components/Icon/TodoListIcon'; import { observer } from 'mobx-react'; import { DropdownMenu, DropdownMenuItem } from 'components/DropdownMenu'; @@ -30,16 +33,16 @@ import { DropdownMenu, DropdownMenuItem } from 'components/DropdownMenu'; {...rest} > - Add images + Add images - Start list + Start list - Start checklist + Start checklist - Add break + Add break );