diff options
author | kibigo! <marrus-sh@users.noreply.github.com> | 2017-12-29 14:55:06 -0800 |
---|---|---|
committer | kibigo! <marrus-sh@users.noreply.github.com> | 2018-01-04 18:23:46 -0800 |
commit | 083170bec755920b80c64f9cca2cc419831f66c8 (patch) | |
tree | 7d15f95360fab7e76bad7e8d8f76667215d25b78 /app/javascript/flavours/glitch/features/composer/textarea/suggestions | |
parent | 8713659dffc884c65376091d3731c8074ac581e4 (diff) |
WIP <Compose> Refactor; SCSS ed.
Diffstat (limited to 'app/javascript/flavours/glitch/features/composer/textarea/suggestions')
-rw-r--r-- | app/javascript/flavours/glitch/features/composer/textarea/suggestions/index.js | 8 | ||||
-rw-r--r-- | app/javascript/flavours/glitch/features/composer/textarea/suggestions/item/index.js | 4 |
2 files changed, 7 insertions, 5 deletions
diff --git a/app/javascript/flavours/glitch/features/composer/textarea/suggestions/index.js b/app/javascript/flavours/glitch/features/composer/textarea/suggestions/index.js index b90696910..65ed2c18a 100644 --- a/app/javascript/flavours/glitch/features/composer/textarea/suggestions/index.js +++ b/app/javascript/flavours/glitch/features/composer/textarea/suggestions/index.js @@ -1,5 +1,4 @@ // Package imports. -import classNames from 'classnames'; import PropTypes from 'prop-types'; import React from 'react'; import ImmutablePropTypes from 'react-immutable-proptypes'; @@ -14,10 +13,13 @@ export default function ComposerTextareaSuggestions ({ suggestions, value, }) { - const computedClass = classNames('comoser--textarea--suggestions', { hidden: hidden || suggestions.isEmpty() }); + // The result. return ( - <div className={computedClass}> + <div + className='composer--textarea--suggestions' + hidden={hidden || suggestions.isEmpty()} + > {!hidden ? suggestions.map( (suggestion, index) => ( <ComposerTextareaSuggestionsItem diff --git a/app/javascript/flavours/glitch/features/composer/textarea/suggestions/item/index.js b/app/javascript/flavours/glitch/features/composer/textarea/suggestions/item/index.js index 08c99ed0e..b78f99ee9 100644 --- a/app/javascript/flavours/glitch/features/composer/textarea/suggestions/item/index.js +++ b/app/javascript/flavours/glitch/features/composer/textarea/suggestions/item/index.js @@ -50,10 +50,10 @@ export default class ComposerTextareaSuggestionsItem extends React.Component { // The result. return ( <div - role='button' - tabIndex='0' className={computedClass} onMouseDown={click} + role='button' + tabIndex='0' > { // If the suggestion is an object, then we render an emoji. // Otherwise, we render an account. |