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

Cleanup unnecessary containers

no refs.
- removed unnecessary `<div>`s
This commit is contained in:
Peter Zimon 2020-09-17 16:19:53 +02:00
parent fb13d12015
commit 4180727d29
7 changed files with 20 additions and 20 deletions

View file

@ -12,8 +12,8 @@ const React = require('react');
const DEV_MODE_DATA = {
showPopup: true,
site: Fixtures.site,
member: Fixtures.member.free,
page: 'signup'
member: Fixtures.member.paid,
page: 'signin'
};
export default class App extends React.Component {
constructor(props) {

View file

@ -86,9 +86,9 @@ export const AccountHomePageStyles = `
const UserAvatar = ({avatar, brandColor}) => {
return (
<div>
<>
<MemberAvatar gravatar={avatar} style={{userIcon: {color: brandColor, width: '56px', height: '56px', padding: '2px'}}} />
</div>
</>
);
};

View file

@ -114,7 +114,7 @@ const PlanConfirmationSection = ({action, member, plan, type, brandColor, onConf
const planStartMessage = `${plan.currency}${plan.price}/${plan.type} Starting ${planStartDate}`;
if (type === 'changePlan') {
return (
<div>
<>
<div className='gh-portal-list outline mb6'>
<section>
<div className='gh-portal-list-detail'>
@ -140,11 +140,11 @@ const PlanConfirmationSection = ({action, member, plan, type, brandColor, onConf
height: '40px'
}}
/>
</div>
</>
);
} else {
return (
<div>
<>
<p>If you confirm and end your subscription now, you can still access it until <strong>{getDateString(subscription.current_period_end)}</strong>.</p>
<ActionButton
onClick={e => onConfirm(e, plan)}
@ -157,7 +157,7 @@ const PlanConfirmationSection = ({action, member, plan, type, brandColor, onConf
height: '40px'
}}
/>
</div>
</>
);
}
};
@ -380,7 +380,7 @@ export default class AccountPlanPage extends React.Component {
const plans = this.plans;
const {selectedPlan, showConfirmation, confirmationPlan, confirmationType} = this.state;
return (
<div>
<>
<div className='gh-portal-content'>
<Header
lastPage={lastPage}
@ -397,7 +397,7 @@ export default class AccountPlanPage extends React.Component {
onPlanCheckout = {(e, name) => this.onPlanCheckout(e, name)}
/>
</div>
</div>
</>
);
}
}

View file

@ -195,7 +195,7 @@ export default class AccountProfilePage extends React.Component {
return null;
}
return (
<div>
<>
<div className='gh-portal-content with-footer'>
{this.renderHeader()}
<div className='gh-portal-section'>
@ -203,7 +203,7 @@ export default class AccountProfilePage extends React.Component {
</div>
</div>
{this.renderAccountFooter()}
</div>
</>
);
}
}

View file

@ -39,14 +39,14 @@ export default class MagicLinkPage extends React.Component {
renderLoginMessage() {
return (
<div>
<>
<div
style={{color: '#3db0ef', fontWeight: 'bold', cursor: 'pointer'}}
onClick={() => this.context.onAction('switchPage', {page: 'signin'})}
>
Back to Log in
</div>
</div>
</>
);
}

View file

@ -137,7 +137,7 @@ export default class SigninPage extends React.Component {
render() {
return (
<div>
<>
<div className='gh-portal-content signin'>
{this.renderFormHeader()}
{this.renderForm()}
@ -146,7 +146,7 @@ export default class SigninPage extends React.Component {
{this.renderSubmitButton()}
{this.renderSignupMessage()}
</footer>
</div>
</>
);
}
}

View file

@ -327,13 +327,13 @@ class SignupPage extends React.Component {
const {site} = this.context;
const plansData = getSitePlans({site});
return (
<div>
<>
<PlansSection
plans={plansData}
selectedPlan={this.state.plan}
onPlanSelect={(e, name) => this.handleSelectPlan(e, name)}
/>
</div>
</>
);
}
@ -414,7 +414,7 @@ class SignupPage extends React.Component {
}
return (
<div>
<>
<div className={'gh-portal-content signup ' + sectionClass}>
{this.renderFormHeader()}
{this.renderForm()}
@ -423,7 +423,7 @@ class SignupPage extends React.Component {
{this.renderSubmitButton()}
{this.renderLoginMessage()}
</footer>
</div>
</>
);
}
}