Add email subject field
[MAILPOET-2678]
This commit is contained in:
committed by
Veljko V
parent
8c5d9b8865
commit
390a8619ff
@@ -0,0 +1,29 @@
|
||||
import React from 'react';
|
||||
import { t, onChange } from 'common/functions';
|
||||
import { Label, Inputs } from 'settings/components';
|
||||
import { useSetting } from 'settings/store/hooks';
|
||||
|
||||
export default function EmailSubject() {
|
||||
const [enabled] = useSetting('signup_confirmation', 'enabled');
|
||||
const [subject, setSubject] = useSetting('signup_confirmation', 'subject');
|
||||
|
||||
if (!enabled) return null;
|
||||
return (
|
||||
<>
|
||||
<Label
|
||||
title={t('emailSubject')}
|
||||
htmlFor="signup_confirmation-subject"
|
||||
/>
|
||||
<Inputs>
|
||||
<input
|
||||
type="text"
|
||||
size={50}
|
||||
id="signup_confirmation-subject"
|
||||
data-automation-id="signup_confirmation_email_subject"
|
||||
value={subject}
|
||||
onChange={onChange(setSubject)}
|
||||
/>
|
||||
</Inputs>
|
||||
</>
|
||||
);
|
||||
}
|
@@ -1,10 +1,12 @@
|
||||
import React from 'react';
|
||||
import EnableSignupConfirmation from './enable_signup_confirmation';
|
||||
import EmailSubject from './email_subject';
|
||||
|
||||
export default function SignupConfirmation() {
|
||||
return (
|
||||
<div className="mailpoet-settings-grid">
|
||||
<EnableSignupConfirmation />
|
||||
<EmailSubject />
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
Reference in New Issue
Block a user