0
Fork 0
mirror of https://github.com/TryGhost/Ghost.git synced 2025-02-17 23:44:39 -05:00

Fixed signin page test

This commit is contained in:
Peter Zimon 2020-07-23 12:05:55 +02:00
parent 849ecae000
commit 1aa9652970
5 changed files with 13 additions and 7 deletions

View file

@ -155,7 +155,7 @@ export const GlobalStyles = `
text-align: center;
}
.gh-portal-setting-heading {
.gh-portal-input-label {
font-size: 1.3rem;
margin-bottom: 2px;
font-weight: 500;

View file

@ -19,7 +19,11 @@ export const InputFieldStyles = `
transition: all 0.25s ease-in-out;
}
.gh-portal-input:focus {
.gh-portal-input-label.hidden {
display: none;
}
.gh-portal-input-label:focus {
border: none;
box-shadow: 0px 0px 0px 1px #c5c5c5 , 0px 2px 4px 0px rgba(0, 0, 0, 0.07), 0px 1px 1.5px 0px rgba(0, 0, 0, 0.05);
}
@ -29,11 +33,12 @@ export const InputFieldStyles = `
}
`;
function InputField({name, id, label, type, value, placeholder, disabled, onChange, brandColor}) {
function InputField({name, id, label, hideLabel, type, value, placeholder, disabled, onChange, brandColor}) {
id = id || `input-${name}`;
const labelClasses = hideLabel ? 'gh-portal-input-label hidden' : 'gh-portal-input-label';
return (
<>
<label htmlFor={id} className='gh-portal-setting-heading'> {label} </label>
<label htmlFor={id} className={labelClasses}> {label} </label>
<input
id={id}
type={type}

View file

@ -209,7 +209,7 @@ function PlanLabel({showLabel}) {
return null;
}
return (
<label className='gh-portal-setting-heading'>Plan</label>
<label className='gh-portal-input-label'>Plan</label>
);
}

View file

@ -169,7 +169,7 @@ export default class AccountProfilePage extends React.Component {
return (
<div className='flex items-center justify-between' style={{marginTop: '24px'}}>
<div className='flex flex-column flex-grow-1'>
<h3 className='gh-portal-setting-heading'>Newsletter</h3>
<h3 className='gh-portal-input-label'>Newsletter</h3>
<div className='gh-portal-setting-data'>{label}</div>
</div>
<div>

View file

@ -65,7 +65,8 @@ export default class SigninPage extends React.Component {
const field = fields[fieldName];
return (
<InputField
// label = {field.label}
label = {field.label}
hideLabel = {true}
type={field.type}
name={field.name}
placeholder={field.placeholder}