remove emojis from reporting (#6042)

This commit is contained in:
saltrafael 2021-05-12 11:19:45 -03:00 committed by GitHub
parent c24c016eb7
commit 355dd8e755
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 7 additions and 2 deletions

View file

@ -47,6 +47,7 @@ type Props = {
disabled?: boolean,
onChange: (any) => void,
value?: string | number,
noEmojis?: boolean,
};
export class FormField extends React.PureComponent<Props> {
@ -92,6 +93,7 @@ export class FormField extends React.PureComponent<Props> {
textAreaMaxLength,
quickActionLabel,
quickActionHandler,
noEmojis,
...inputProps
} = this.props;
const errorMessage = typeof error === 'object' ? error.message : error;
@ -272,7 +274,7 @@ export class FormField extends React.PureComponent<Props> {
{...inputProps}
/>
<div className="form-field__textarea-info">
<div className="form-field__quick-emojis">
{!noEmojis && <div className="form-field__quick-emojis">
{QUICK_EMOJIS.map((emoji) => (
<Button
key={emoji}
@ -287,7 +289,7 @@ export class FormField extends React.PureComponent<Props> {
}}
/>
))}
</div>
</div>}
{countInfo}
</div>
</fieldset-section>

View file

@ -377,6 +377,7 @@ export default function ReportContent(props: Props) {
onChange={(e) => updateInput('relationship_to_copyrighted_content', e.target.value)}
charCount={input.relationship_to_copyrighted_content.length}
textAreaMaxLength={FF_MAX_CHARS_REPORT_CONTENT_DETAILS}
noEmojis
/>
<FormField
type="checkbox"
@ -449,6 +450,7 @@ export default function ReportContent(props: Props) {
value={input.clarification}
textAreaMaxLength={FF_MAX_CHARS_REPORT_CONTENT_DETAILS}
onChange={(e) => updateInput('clarification', e.target.value)}
noEmojis
/>
</div>
);
@ -491,6 +493,7 @@ export default function ReportContent(props: Props) {
charCount={input.additionalDetails.length}
textAreaMaxLength={FF_MAX_CHARS_REPORT_CONTENT_DETAILS}
placeholder={__('Provide additional details')}
noEmojis
/>
</div>
</>