From 488cb722b38ed1e90655585be144d45eb50e0149 Mon Sep 17 00:00:00 2001 From: "dave.snider@gmail.com" Date: Fri, 13 Apr 2018 13:10:28 -0700 Subject: [PATCH] Editor icon set (#671) Editor icons. --- CHANGELOG.md | 3 +- src-docs/src/views/icon/icons.js | 14 + .../icon/__snapshots__/icon.test.js.snap | 294 ++++++++++++++++++ .../icon/assets/editor_align_center.svg | 8 + .../icon/assets/editor_align_left.svg | 8 + .../icon/assets/editor_align_right.svg | 8 + src/components/icon/assets/editor_bold.svg | 8 + .../icon/assets/editor_code_block.svg | 8 + src/components/icon/assets/editor_comment.svg | 8 + src/components/icon/assets/editor_heading.svg | 8 + src/components/icon/assets/editor_italic.svg | 8 + src/components/icon/assets/editor_link.svg | 8 + .../icon/assets/editor_ordered_list.svg | 8 + src/components/icon/assets/editor_redo.svg | 8 + src/components/icon/assets/editor_strike.svg | 8 + src/components/icon/assets/editor_table.svg | 8 + .../icon/assets/editor_underline.svg | 8 + src/components/icon/assets/editor_undo.svg | 8 + .../icon/assets/editor_unordered_list.svg | 8 + src/components/icon/icon.js | 28 ++ src/components/icon/index.d.ts | 14 + 21 files changed, 480 insertions(+), 1 deletion(-) create mode 100644 src/components/icon/assets/editor_align_center.svg create mode 100644 src/components/icon/assets/editor_align_left.svg create mode 100644 src/components/icon/assets/editor_align_right.svg create mode 100644 src/components/icon/assets/editor_bold.svg create mode 100644 src/components/icon/assets/editor_code_block.svg create mode 100644 src/components/icon/assets/editor_comment.svg create mode 100644 src/components/icon/assets/editor_heading.svg create mode 100644 src/components/icon/assets/editor_italic.svg create mode 100644 src/components/icon/assets/editor_link.svg create mode 100644 src/components/icon/assets/editor_ordered_list.svg create mode 100644 src/components/icon/assets/editor_redo.svg create mode 100644 src/components/icon/assets/editor_strike.svg create mode 100644 src/components/icon/assets/editor_table.svg create mode 100644 src/components/icon/assets/editor_underline.svg create mode 100644 src/components/icon/assets/editor_undo.svg create mode 100644 src/components/icon/assets/editor_unordered_list.svg diff --git a/CHANGELOG.md b/CHANGELOG.md index 647d74ba251..a553146249f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,7 @@ ## [`master`](https://github.com/elastic/eui/tree/master) -- Added `euiDatePicker` component for date/time input ([#644](https://github.com/elastic/eui/pull/644)) +- Added `EuiDatePicker` component for date/time input ([#644](https://github.com/elastic/eui/pull/644)) +- Added editor icon set to `EuiIcon` ([#671](https://github.com/elastic/eui/pull/671)) ## [`0.0.41`](https://github.com/elastic/eui/tree/v0.0.41) diff --git a/src-docs/src/views/icon/icons.js b/src-docs/src/views/icon/icons.js index 0ddbe8d3f7d..657b9dc5cb7 100644 --- a/src-docs/src/views/icon/icons.js +++ b/src-docs/src/views/icon/icons.js @@ -35,6 +35,20 @@ const iconTypes = [ 'cross', 'document', 'dot', + 'editorAlignCenter', + 'editorAlignLeft', + 'editorAlignRight', + 'editorBold', + 'editorCodeBlock', + 'editorComment', + 'editorHeading', + 'editorItalic', + 'editorLink', + 'editorStrike', + 'editorTable', + 'editorUnderline', + 'editorOrderedList', + 'editorUnorderedList', 'empty', 'exit', 'expand', diff --git a/src/components/icon/__snapshots__/icon.test.js.snap b/src/components/icon/__snapshots__/icon.test.js.snap index 38b1252df1e..4522de02de6 100644 --- a/src/components/icon/__snapshots__/icon.test.js.snap +++ b/src/components/icon/__snapshots__/icon.test.js.snap @@ -1191,6 +1191,300 @@ exports[`EuiIcon renders type dot 1`] = ` `; +exports[`EuiIcon renders type editorAlignCenter 1`] = ` + + + + + + +`; + +exports[`EuiIcon renders type editorAlignLeft 1`] = ` + + + + + + +`; + +exports[`EuiIcon renders type editorAlignRight 1`] = ` + + + + + + +`; + +exports[`EuiIcon renders type editorBold 1`] = ` + + + + + + +`; + +exports[`EuiIcon renders type editorCodeBlock 1`] = ` + + + + + + +`; + +exports[`EuiIcon renders type editorComment 1`] = ` + + + + + + +`; + +exports[`EuiIcon renders type editorHeading 1`] = ` + + + + + + +`; + +exports[`EuiIcon renders type editorItalic 1`] = ` + + + + + + +`; + +exports[`EuiIcon renders type editorLink 1`] = ` + + + + + + +`; + +exports[`EuiIcon renders type editorOrderedList 1`] = ` + + + + + + +`; + +exports[`EuiIcon renders type editorStrike 1`] = ` + + + + + + +`; + +exports[`EuiIcon renders type editorTable 1`] = ` + + + + + + +`; + +exports[`EuiIcon renders type editorUnderline 1`] = ` + + + + + + +`; + +exports[`EuiIcon renders type editorUnorderedList 1`] = ` + + + + + + +`; + exports[`EuiIcon renders type empty 1`] = ` + + + + + + + diff --git a/src/components/icon/assets/editor_align_left.svg b/src/components/icon/assets/editor_align_left.svg new file mode 100644 index 00000000000..0f34f60b7ae --- /dev/null +++ b/src/components/icon/assets/editor_align_left.svg @@ -0,0 +1,8 @@ + + + + + + + + diff --git a/src/components/icon/assets/editor_align_right.svg b/src/components/icon/assets/editor_align_right.svg new file mode 100644 index 00000000000..5c9160999bd --- /dev/null +++ b/src/components/icon/assets/editor_align_right.svg @@ -0,0 +1,8 @@ + + + + + + + + diff --git a/src/components/icon/assets/editor_bold.svg b/src/components/icon/assets/editor_bold.svg new file mode 100644 index 00000000000..10083e63ee7 --- /dev/null +++ b/src/components/icon/assets/editor_bold.svg @@ -0,0 +1,8 @@ + + + + + + + + diff --git a/src/components/icon/assets/editor_code_block.svg b/src/components/icon/assets/editor_code_block.svg new file mode 100644 index 00000000000..609b6e808ac --- /dev/null +++ b/src/components/icon/assets/editor_code_block.svg @@ -0,0 +1,8 @@ + + + + + + + + diff --git a/src/components/icon/assets/editor_comment.svg b/src/components/icon/assets/editor_comment.svg new file mode 100644 index 00000000000..7e5ddfb396d --- /dev/null +++ b/src/components/icon/assets/editor_comment.svg @@ -0,0 +1,8 @@ + + + + + + + + diff --git a/src/components/icon/assets/editor_heading.svg b/src/components/icon/assets/editor_heading.svg new file mode 100644 index 00000000000..6b11d95ab0e --- /dev/null +++ b/src/components/icon/assets/editor_heading.svg @@ -0,0 +1,8 @@ + + + + + + + + diff --git a/src/components/icon/assets/editor_italic.svg b/src/components/icon/assets/editor_italic.svg new file mode 100644 index 00000000000..302169e0be9 --- /dev/null +++ b/src/components/icon/assets/editor_italic.svg @@ -0,0 +1,8 @@ + + + + + + + + diff --git a/src/components/icon/assets/editor_link.svg b/src/components/icon/assets/editor_link.svg new file mode 100644 index 00000000000..49a8e55570e --- /dev/null +++ b/src/components/icon/assets/editor_link.svg @@ -0,0 +1,8 @@ + + + + + + + + diff --git a/src/components/icon/assets/editor_ordered_list.svg b/src/components/icon/assets/editor_ordered_list.svg new file mode 100644 index 00000000000..76238375cd7 --- /dev/null +++ b/src/components/icon/assets/editor_ordered_list.svg @@ -0,0 +1,8 @@ + + + + + + + + diff --git a/src/components/icon/assets/editor_redo.svg b/src/components/icon/assets/editor_redo.svg new file mode 100644 index 00000000000..b9105d0e8f2 --- /dev/null +++ b/src/components/icon/assets/editor_redo.svg @@ -0,0 +1,8 @@ + + + + + + + + diff --git a/src/components/icon/assets/editor_strike.svg b/src/components/icon/assets/editor_strike.svg new file mode 100644 index 00000000000..e926ae70c4a --- /dev/null +++ b/src/components/icon/assets/editor_strike.svg @@ -0,0 +1,8 @@ + + + + + + + + diff --git a/src/components/icon/assets/editor_table.svg b/src/components/icon/assets/editor_table.svg new file mode 100644 index 00000000000..c68170187e1 --- /dev/null +++ b/src/components/icon/assets/editor_table.svg @@ -0,0 +1,8 @@ + + + + + + + + diff --git a/src/components/icon/assets/editor_underline.svg b/src/components/icon/assets/editor_underline.svg new file mode 100644 index 00000000000..46aeebc2766 --- /dev/null +++ b/src/components/icon/assets/editor_underline.svg @@ -0,0 +1,8 @@ + + + + + + + + diff --git a/src/components/icon/assets/editor_undo.svg b/src/components/icon/assets/editor_undo.svg new file mode 100644 index 00000000000..5697a2b8f90 --- /dev/null +++ b/src/components/icon/assets/editor_undo.svg @@ -0,0 +1,8 @@ + + + + + + + + diff --git a/src/components/icon/assets/editor_unordered_list.svg b/src/components/icon/assets/editor_unordered_list.svg new file mode 100644 index 00000000000..3c85cfcb042 --- /dev/null +++ b/src/components/icon/assets/editor_unordered_list.svg @@ -0,0 +1,8 @@ + + + + + + + + diff --git a/src/components/icon/icon.js b/src/components/icon/icon.js index 8d85aea7c54..da9e3370ac3 100644 --- a/src/components/icon/icon.js +++ b/src/components/icon/icon.js @@ -40,6 +40,20 @@ import devToolsApp from './assets/app_devtools.svg'; import discoverApp from './assets/app_discover.svg'; import document from './assets/document.svg'; import dot from './assets/dot.svg'; +import editorAlignCenter from './assets/editor_align_center.svg'; +import editorAlignLeft from './assets/editor_align_left.svg'; +import editorAlignRight from './assets/editor_align_right.svg'; +import editorBold from './assets/editor_bold.svg'; +import editorCodeBlock from './assets/editor_code_block.svg'; +import editorComment from './assets/editor_comment.svg'; +import editorHeading from './assets/editor_heading.svg'; +import editorItalic from './assets/editor_italic.svg'; +import editorLink from './assets/editor_link.svg'; +import editorStrike from './assets/editor_strike.svg'; +import editorTable from './assets/editor_table.svg'; +import editorUnderline from './assets/editor_underline.svg'; +import editorOrderedList from './assets/editor_ordered_list.svg'; +import editorUnorderedList from './assets/editor_unordered_list.svg'; import empty from './assets/empty.svg'; import exit from './assets/exit.svg'; import expand from './assets/expand.svg'; @@ -192,6 +206,20 @@ const typeToIconMap = { discoverApp, document, dot, + editorAlignCenter, + editorAlignLeft, + editorAlignRight, + editorBold, + editorCodeBlock, + editorComment, + editorHeading, + editorItalic, + editorLink, + editorStrike, + editorTable, + editorUnderline, + editorOrderedList, + editorUnorderedList, empty, exit, expand, diff --git a/src/components/icon/index.d.ts b/src/components/icon/index.d.ts index b3645673c06..bccb88cd9f4 100644 --- a/src/components/icon/index.d.ts +++ b/src/components/icon/index.d.ts @@ -43,6 +43,20 @@ declare module '@elastic/eui' { | 'discoverApp' | 'document' | 'dot' + | 'editorAlignCenter' + | 'editorAlignLeft' + | 'editorAlignRight' + | 'editorBold' + | 'editorCodeBlock' + | 'editorComment' + | 'editorHeading' + | 'editorItalic' + | 'editorLink' + | 'editorStrike' + | 'editorTable' + | 'editorUnderline' + | 'editorOrderedList' + | 'editorUnorderedList' | 'empty' | 'exit' | 'expand'