From 38665cc34ddec35abe01335c63d7afa899dc359a Mon Sep 17 00:00:00 2001 From: Sean Date: Tue, 20 Nov 2018 18:11:43 -0500 Subject: [PATCH] Dropdown updates (#585) * Add dropdown icons * remove cursor pointer from icons --- components/BackgroundSelect.js | 53 +++++++++----------------- components/Dropdown.js | 68 ++++++++++++++++++++++++++++++---- components/Editor.js | 4 ++ components/Settings.js | 8 +++- components/svg/Language.js | 10 +++++ components/svg/Theme.js | 10 +++++ 6 files changed, 108 insertions(+), 45 deletions(-) create mode 100644 components/svg/Language.js create mode 100644 components/svg/Theme.js diff --git a/components/BackgroundSelect.js b/components/BackgroundSelect.js index 63aeac6..d37a430 100644 --- a/components/BackgroundSelect.js +++ b/components/BackgroundSelect.js @@ -47,42 +47,39 @@ class BackgroundSelect extends React.Component { } render() { - let background = this.props.color - background = - typeof background === 'string' - ? background + const { color, mode, image, onChange, aspectRatio } = this.props + const { isVisible, mounted } = this.state + + let background = + typeof color === 'string' + ? color .replace(/&/g, '&') .replace(//g, '>') .replace(/"/g, '"') .replace(/'/g, ''') .replace(/\//g, '/') - : background + : color if (!validateColor(background)) { background = DEFAULT_BG_COLOR } - const { mode, image } = this.props - return (
-
-
- BG -
+
-