mirror of
https://github.com/bigcapitalhq/bigcapital.git
synced 2026-02-21 15:20:34 +00:00
feat: optimize register setup page.
This commit is contained in:
@@ -1,9 +1,8 @@
|
|||||||
import React, { useState, useCallback } from 'react';
|
import React, { useCallback } from 'react';
|
||||||
import { Icon, For } from 'components';
|
import { Icon, For } from 'components';
|
||||||
import { FormattedMessage as T } from 'react-intl';
|
import { FormattedMessage as T } from 'react-intl';
|
||||||
|
|
||||||
import withAuthenticationActions from 'containers/Authentication/withAuthenticationActions';
|
import withAuthenticationActions from 'containers/Authentication/withAuthenticationActions';
|
||||||
|
import withAuthentication from 'containers/Authentication/withAuthentication';
|
||||||
import footerLinks from 'config/footerLinks';
|
import footerLinks from 'config/footerLinks';
|
||||||
import { compose } from 'utils';
|
import { compose } from 'utils';
|
||||||
|
|
||||||
@@ -22,6 +21,9 @@ function FooterLinkItem({ title, link }) {
|
|||||||
function SetupLeftSection({
|
function SetupLeftSection({
|
||||||
// #withAuthenticationActions
|
// #withAuthenticationActions
|
||||||
requestLogout,
|
requestLogout,
|
||||||
|
|
||||||
|
// #withAuthentication
|
||||||
|
currentOrganizationId
|
||||||
}) {
|
}) {
|
||||||
const onClickLogout = useCallback(() => {
|
const onClickLogout = useCallback(() => {
|
||||||
requestLogout();
|
requestLogout();
|
||||||
@@ -43,7 +45,7 @@ function SetupLeftSection({
|
|||||||
</p>
|
</p>
|
||||||
|
|
||||||
<div className={'content__organization'}>
|
<div className={'content__organization'}>
|
||||||
<span class="organization-id">Your oragnization ID: <span class="id">12342313</span>,</span><br />
|
<span class="organization-id">Your oragnization ID: <span class="id">{ currentOrganizationId }</span>,</span><br />
|
||||||
<span class="signout"><a onClick={onClickLogout} href="#"><T id={'sign_out'} /></a></span>
|
<span class="signout"><a onClick={onClickLogout} href="#"><T id={'sign_out'} /></a></span>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
@@ -65,4 +67,5 @@ function SetupLeftSection({
|
|||||||
|
|
||||||
export default compose(
|
export default compose(
|
||||||
withAuthenticationActions,
|
withAuthenticationActions,
|
||||||
|
withAuthentication(({ currentOrganizationId }) => ({ currentOrganizationId })),
|
||||||
)(SetupLeftSection);
|
)(SetupLeftSection);
|
||||||
|
|||||||
@@ -56,6 +56,7 @@ function SetupSubscriptionForm({
|
|||||||
<BillingPlans title={'a_select_a_plan'} formik={formik} />
|
<BillingPlans title={'a_select_a_plan'} formik={formik} />
|
||||||
<BillingPeriods title={'b_choose_your_billing'} formik={formik} />
|
<BillingPeriods title={'b_choose_your_billing'} formik={formik} />
|
||||||
<BillingPaymentmethod title={'c_payment_methods'} formik={formik} />
|
<BillingPaymentmethod title={'c_payment_methods'} formik={formik} />
|
||||||
|
|
||||||
<div className={'subscribe-button'}>
|
<div className={'subscribe-button'}>
|
||||||
<Button
|
<Button
|
||||||
intent={Intent.PRIMARY}
|
intent={Intent.PRIMARY}
|
||||||
|
|||||||
@@ -11,7 +11,7 @@ function LicenseTab({
|
|||||||
<h4>
|
<h4>
|
||||||
<T id={'license_code'} />
|
<T id={'license_code'} />
|
||||||
</h4>
|
</h4>
|
||||||
<p className={'bg-message'}>
|
<p className="paragraph">
|
||||||
<T id={'cards_will_be_charged'} />
|
<T id={'cards_will_be_charged'} />
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
|
|||||||
@@ -4,11 +4,11 @@ import { PaymentMethodTabs } from './SubscriptionTabs';
|
|||||||
|
|
||||||
export const BillingPaymentmethod = ({ formik, title }) => {
|
export const BillingPaymentmethod = ({ formik, title }) => {
|
||||||
return (
|
return (
|
||||||
<section>
|
<section class="billing-section">
|
||||||
<h1 className={'bg-title'}>
|
<h1 className={'bg-title'}>
|
||||||
<T id={title} />
|
<T id={title} />
|
||||||
</h1>
|
</h1>
|
||||||
<p className={'bg-message'}>
|
<p className='paragraph'>
|
||||||
<T id={'please_enter_your_preferred_payment_method'} />
|
<T id={'please_enter_your_preferred_payment_method'} />
|
||||||
</p>
|
</p>
|
||||||
<PaymentMethodTabs formik={formik} />
|
<PaymentMethodTabs formik={formik} />
|
||||||
|
|||||||
@@ -15,6 +15,7 @@ function BillingPeriod({ price, period, currency, onSelected, selected }) {
|
|||||||
<span className={'bg-period'}>
|
<span className={'bg-period'}>
|
||||||
<T id={period} />
|
<T id={period} />
|
||||||
</span>
|
</span>
|
||||||
|
|
||||||
<div className={'plan-price'}>
|
<div className={'plan-price'}>
|
||||||
<span className={'amount'}>
|
<span className={'amount'}>
|
||||||
{price} {currency}
|
{price} {currency}
|
||||||
@@ -43,11 +44,11 @@ function BillingPeriods({ formik, title, selected = 1 }) {
|
|||||||
});
|
});
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<section>
|
<section class="billing-section">
|
||||||
<h1 className={'bg-title'}>
|
<h1 className={'bg-title'}>
|
||||||
<T id={title} />
|
<T id={title} />
|
||||||
</h1>
|
</h1>
|
||||||
<p className={'bg-message'}>
|
<p className='paragraph'>
|
||||||
<T id={'please_enter_your_preferred_payment_method'} />
|
<T id={'please_enter_your_preferred_payment_method'} />
|
||||||
</p>
|
</p>
|
||||||
<div className={'payment-method-continer'} ref={billingRef}>
|
<div className={'payment-method-continer'} ref={billingRef}>
|
||||||
|
|||||||
@@ -61,11 +61,11 @@ function BillingPlans({ formik, title, selected = 1 }) {
|
|||||||
});
|
});
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<section>
|
<section class="billing-section">
|
||||||
<h1 className={'bg-title'}>
|
<h1 className={'bg-title'}>
|
||||||
<T id={title} />
|
<T id={title} />
|
||||||
</h1>
|
</h1>
|
||||||
<p className={'bg-message '}>
|
<p className='paragraph'>
|
||||||
<T id={'please_enter_your_preferred_payment_method'} />
|
<T id={'please_enter_your_preferred_payment_method'} />
|
||||||
</p>
|
</p>
|
||||||
<div className={'billing-form__plan-container'} ref={planRef}>
|
<div className={'billing-form__plan-container'} ref={planRef}>
|
||||||
|
|||||||
@@ -709,7 +709,7 @@ export default {
|
|||||||
please_enter_your_preferred_payment_method:
|
please_enter_your_preferred_payment_method:
|
||||||
'Please enter your preferred payment method below. You can use a credit / debit card or prepay through PayPal. ',
|
'Please enter your preferred payment method below. You can use a credit / debit card or prepay through PayPal. ',
|
||||||
cards_will_be_charged:
|
cards_will_be_charged:
|
||||||
'Cards will be charged either at the end of the month or whenever your balance exceeds the usage threshold.All major credit / debit cards accepted.',
|
'Cards will be charged either at the end of the month or whenever your balance exceeds the usage threshold. All major credit / debit cards accepted.',
|
||||||
license_number: 'License number',
|
license_number: 'License number',
|
||||||
subscribe: 'Subscribe',
|
subscribe: 'Subscribe',
|
||||||
year_per: 'year',
|
year_per: 'year',
|
||||||
|
|||||||
@@ -11,4 +11,9 @@ body{
|
|||||||
.divider{
|
.divider{
|
||||||
border-top: 1px solid #e8e8e8;
|
border-top: 1px solid #e8e8e8;
|
||||||
height: 1px;
|
height: 1px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.paragraph{
|
||||||
|
line-height: 1.5;
|
||||||
|
font-size: 14px;
|
||||||
}
|
}
|
||||||
@@ -1,18 +1,19 @@
|
|||||||
* {
|
|
||||||
box-sizing: border-box;
|
|
||||||
margin: 0;
|
|
||||||
padding: 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
.billing-form {
|
.billing-form {
|
||||||
padding: 25px 45px;
|
padding: 25px 45px;
|
||||||
width: 800px;
|
width: 800px;
|
||||||
margin: 0 auto;
|
margin: 0 auto;
|
||||||
|
|
||||||
|
.billing-section{
|
||||||
|
margin-bottom: 30px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.paragraph + .billing-form__plan-container{
|
||||||
|
margin-top: 20px;
|
||||||
|
}
|
||||||
|
|
||||||
&__plan-container {
|
&__plan-container {
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-flow: row wrap;
|
flex-flow: row wrap;
|
||||||
margin-bottom: 30px;
|
|
||||||
|
|
||||||
.plan-wrapper {
|
.plan-wrapper {
|
||||||
display: flex;
|
display: flex;
|
||||||
@@ -76,8 +77,14 @@
|
|||||||
background-color: #fcfdff;
|
background-color: #fcfdff;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.paragraph + .payment-method-continer{
|
||||||
|
margin-top: 20px;
|
||||||
|
}
|
||||||
|
|
||||||
.payment-method-continer {
|
.payment-method-continer {
|
||||||
margin-bottom: 30px;
|
margin-bottom: 30px;
|
||||||
|
|
||||||
.period-container {
|
.period-container {
|
||||||
display: inline-flex;
|
display: inline-flex;
|
||||||
background-color: #fcfdff;
|
background-color: #fcfdff;
|
||||||
@@ -110,22 +117,12 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// .bg-title {
|
|
||||||
// font-size: 22px;
|
|
||||||
// font-weight: 400;
|
|
||||||
// color: #666666;
|
|
||||||
// }
|
|
||||||
// .bg-message {
|
|
||||||
// margin-bottom: 23px;
|
|
||||||
// font-size: 14px;
|
|
||||||
// }
|
|
||||||
.license-container {
|
.license-container {
|
||||||
.bp3-form-group {
|
|
||||||
margin-bottom: 20px;
|
.form-group-license_code{
|
||||||
.bp3-label {
|
margin-top: 20px;
|
||||||
margin-bottom: 15px;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.bp3-form-content {
|
.bp3-form-content {
|
||||||
.bp3-input-group {
|
.bp3-input-group {
|
||||||
display: block;
|
display: block;
|
||||||
|
|||||||
@@ -20,7 +20,7 @@
|
|||||||
|
|
||||||
h1{
|
h1{
|
||||||
font-size: 22px;
|
font-size: 22px;
|
||||||
font-weight: 600;
|
font-weight: 500;
|
||||||
color: #6d6d6d;
|
color: #6d6d6d;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user