@npm_leadtech/legal-lib-components 7.60.0 → 7.61.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/css/styles.css +17 -0
- package/dist/src/components/atoms/FeatureItem/FeatureItem.d.ts +3 -0
- package/dist/src/components/atoms/FeatureItem/FeatureItem.js +5 -0
- package/dist/src/components/atoms/FeatureItem/FeatureItem.styled.d.ts +1 -0
- package/dist/src/components/atoms/FeatureItem/FeatureItem.styled.js +18 -0
- package/dist/src/components/atoms/FeatureItem/FeatureItem.styled.ts +19 -0
- package/dist/src/components/atoms/FeatureItem/FeatureItem.tsx +12 -0
- package/dist/src/components/atoms/FeatureItem/FeatureItemProps.d.ts +9 -0
- package/dist/src/components/atoms/FeatureItem/FeatureItemProps.js +1 -0
- package/dist/src/components/atoms/FeatureItem/FeatureItemProps.ts +10 -0
- package/dist/src/components/atoms/FeatureItem/index.d.ts +2 -0
- package/dist/src/components/atoms/FeatureItem/index.js +2 -0
- package/dist/src/components/atoms/FeatureItem/index.ts +2 -0
- package/dist/src/components/atoms/PlanCard/PlanCard.d.ts +3 -0
- package/dist/src/components/atoms/PlanCard/PlanCard.js +6 -0
- package/dist/src/components/atoms/PlanCard/PlanCard.styled.d.ts +8 -0
- package/dist/src/components/atoms/PlanCard/PlanCard.styled.js +75 -0
- package/dist/src/components/atoms/PlanCard/PlanCard.styled.ts +83 -0
- package/dist/src/components/atoms/PlanCard/PlanCard.tsx +42 -0
- package/dist/src/components/atoms/PlanCard/PlanCardProps.d.ts +23 -0
- package/dist/src/components/atoms/PlanCard/PlanCardProps.js +1 -0
- package/dist/src/components/atoms/PlanCard/PlanCardProps.ts +26 -0
- package/dist/src/components/atoms/PlanCard/index.d.ts +2 -0
- package/dist/src/components/atoms/PlanCard/index.js +2 -0
- package/dist/src/components/atoms/PlanCard/index.ts +2 -0
- package/dist/src/components/atoms/index.d.ts +2 -0
- package/dist/src/components/atoms/index.js +2 -0
- package/dist/src/components/atoms/index.ts +2 -0
- package/dist/src/components/pages/PricingPlansPage/PricingPlansPage.d.ts +3 -0
- package/dist/src/components/pages/PricingPlansPage/PricingPlansPage.js +8 -0
- package/dist/src/components/pages/PricingPlansPage/PricingPlansPage.styled.d.ts +16 -0
- package/dist/src/components/pages/PricingPlansPage/PricingPlansPage.styled.js +87 -0
- package/dist/src/components/pages/PricingPlansPage/PricingPlansPage.styled.ts +106 -0
- package/dist/src/components/pages/PricingPlansPage/PricingPlansPage.tsx +64 -0
- package/dist/src/components/pages/PricingPlansPage/PricingPlansPageProps.d.ts +7 -0
- package/dist/src/components/pages/PricingPlansPage/PricingPlansPageProps.js +1 -0
- package/dist/src/components/pages/PricingPlansPage/PricingPlansPageProps.ts +8 -0
- package/dist/src/components/pages/PricingPlansPage/index.d.ts +2 -0
- package/dist/src/components/pages/PricingPlansPage/index.js +2 -0
- package/dist/src/components/pages/PricingPlansPage/index.ts +2 -0
- package/dist/src/components/pages/index.d.ts +1 -0
- package/dist/src/components/pages/index.js +1 -0
- package/dist/src/components/pages/index.ts +1 -0
- package/dist/src/globalStyles/themes.scss +18 -0
- package/dist/tsconfig.build.tsbuildinfo +1 -1
- package/package.json +2 -1
|
@@ -0,0 +1,106 @@
|
|
|
1
|
+
import styled, { css } from 'styled-components'
|
|
2
|
+
|
|
3
|
+
type PlanWrapperProps = {
|
|
4
|
+
isActive: boolean
|
|
5
|
+
isHighlighted?: boolean
|
|
6
|
+
}
|
|
7
|
+
|
|
8
|
+
type SelectorButton = {
|
|
9
|
+
isActive: boolean
|
|
10
|
+
dataQa: string
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
export const PricingContainerStyled = styled.section`
|
|
14
|
+
margin: 0 auto 0 auto;
|
|
15
|
+
display: flex;
|
|
16
|
+
flex-direction: column;
|
|
17
|
+
justify-content: center;
|
|
18
|
+
align-items: center;
|
|
19
|
+
max-width: 996px;
|
|
20
|
+
gap: 1.5rem;
|
|
21
|
+
margin-bottom: 3rem;
|
|
22
|
+
padding: 0 1.5rem;
|
|
23
|
+
`
|
|
24
|
+
|
|
25
|
+
export const PlanSelector = styled.div`
|
|
26
|
+
display: flex;
|
|
27
|
+
justify-content: center;
|
|
28
|
+
gap: 0.5rem;
|
|
29
|
+
border-radius: 1rem;
|
|
30
|
+
padding: 0.5rem;
|
|
31
|
+
|
|
32
|
+
@media (min-width: 768px) {
|
|
33
|
+
display: none;
|
|
34
|
+
}
|
|
35
|
+
`
|
|
36
|
+
|
|
37
|
+
export const SelectorButton = styled.button<SelectorButton>`
|
|
38
|
+
padding: 0.5rem;
|
|
39
|
+
border-radius: 0.5rem;
|
|
40
|
+
border: none;
|
|
41
|
+
outline: inherit;
|
|
42
|
+
flex: 1;
|
|
43
|
+
font-size: 12px;
|
|
44
|
+
font-weight: 700;
|
|
45
|
+
background-color: var(--neutral-neutral-4);
|
|
46
|
+
color: var(--neutral-neutral-1);
|
|
47
|
+
cursor: pointer;
|
|
48
|
+
transition: background-color 0.3s;
|
|
49
|
+
|
|
50
|
+
${({ isActive }) =>
|
|
51
|
+
isActive &&
|
|
52
|
+
css`
|
|
53
|
+
background-color: var(--primary-main);
|
|
54
|
+
color: white;
|
|
55
|
+
`}
|
|
56
|
+
`
|
|
57
|
+
|
|
58
|
+
export const PlansWrapper = styled.div`
|
|
59
|
+
display: flex;
|
|
60
|
+
height: 100%;
|
|
61
|
+
gap: 1rem;
|
|
62
|
+
width: 100%;
|
|
63
|
+
max-width: 327px;
|
|
64
|
+
|
|
65
|
+
@media (min-width: 768px) {
|
|
66
|
+
max-width: none;
|
|
67
|
+
gap: 20px;
|
|
68
|
+
}
|
|
69
|
+
`
|
|
70
|
+
|
|
71
|
+
export const PlanWrapper = styled.div<PlanWrapperProps>`
|
|
72
|
+
max-width: 327px;
|
|
73
|
+
border-radius: 1rem;
|
|
74
|
+
flex: 1;
|
|
75
|
+
display: ${({ isActive }) => (isActive ? 'block' : 'none')};
|
|
76
|
+
background-color: white;
|
|
77
|
+
|
|
78
|
+
${({ isHighlighted }) =>
|
|
79
|
+
isHighlighted &&
|
|
80
|
+
css`
|
|
81
|
+
border: 2px solid var(--primary-main);
|
|
82
|
+
`}
|
|
83
|
+
|
|
84
|
+
@media (min-width: 768px) {
|
|
85
|
+
display: block;
|
|
86
|
+
max-width: none;
|
|
87
|
+
}
|
|
88
|
+
`
|
|
89
|
+
|
|
90
|
+
export const FeaturesSection = styled.div`
|
|
91
|
+
width: 100%;
|
|
92
|
+
`
|
|
93
|
+
|
|
94
|
+
export const FeaturesGrid = styled.ul`
|
|
95
|
+
display: grid;
|
|
96
|
+
grid-template-columns: repeat(2, 1fr);
|
|
97
|
+
gap: 0.5rem;
|
|
98
|
+
list-style: none;
|
|
99
|
+
padding: 0;
|
|
100
|
+
margin: 0;
|
|
101
|
+
|
|
102
|
+
@media (min-width: 768px) {
|
|
103
|
+
display: flex;
|
|
104
|
+
justify-content: center;
|
|
105
|
+
}
|
|
106
|
+
`
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
import { FeatureItem, PlanCard } from '../../atoms'
|
|
2
|
+
import {
|
|
3
|
+
FeaturesGrid,
|
|
4
|
+
FeaturesSection,
|
|
5
|
+
PlanSelector,
|
|
6
|
+
PlanWrapper,
|
|
7
|
+
PlansWrapper,
|
|
8
|
+
PricingContainerStyled,
|
|
9
|
+
SelectorButton
|
|
10
|
+
} from './PricingPlansPage.styled'
|
|
11
|
+
import { PricingPlansPageProps } from './PricingPlansPageProps'
|
|
12
|
+
import React from 'react'
|
|
13
|
+
|
|
14
|
+
export const PricingPlansPage: React.FC<PricingPlansPageProps> = ({
|
|
15
|
+
subscriptionPlans,
|
|
16
|
+
features,
|
|
17
|
+
onPlanSelect,
|
|
18
|
+
header
|
|
19
|
+
}) => {
|
|
20
|
+
const [activePlanIndex, setActivePlanIndex] = React.useState(0)
|
|
21
|
+
|
|
22
|
+
return (
|
|
23
|
+
<>
|
|
24
|
+
{header}
|
|
25
|
+
{subscriptionPlans?.length > 0 && (
|
|
26
|
+
<PricingContainerStyled>
|
|
27
|
+
<PlanSelector>
|
|
28
|
+
{subscriptionPlans.map((plan, index) => (
|
|
29
|
+
<SelectorButton
|
|
30
|
+
key={`selector-${plan?.pricingLabel}`}
|
|
31
|
+
isActive={index === activePlanIndex}
|
|
32
|
+
onClick={() => setActivePlanIndex(index)}
|
|
33
|
+
dataQa={`selector-${plan.subscription_type?.name.replaceAll(' ', '')}`}
|
|
34
|
+
>
|
|
35
|
+
{plan?.subscription_type?.name}
|
|
36
|
+
</SelectorButton>
|
|
37
|
+
))}
|
|
38
|
+
</PlanSelector>
|
|
39
|
+
<PlansWrapper>
|
|
40
|
+
{subscriptionPlans.map((plan, index) => (
|
|
41
|
+
<PlanWrapper
|
|
42
|
+
key={plan.pricingLabel}
|
|
43
|
+
isHighlighted={plan.highlightPlan}
|
|
44
|
+
isActive={index === activePlanIndex}
|
|
45
|
+
className={`pricing-plan__element-container ${plan?.highlightPlan ? 'highlight' : ''} ${index === activePlanIndex ? 'active' : ''}`}
|
|
46
|
+
>
|
|
47
|
+
<PlanCard onSelect={onPlanSelect ?? (() => {})} plan={plan} />
|
|
48
|
+
</PlanWrapper>
|
|
49
|
+
))}
|
|
50
|
+
</PlansWrapper>
|
|
51
|
+
{features && features.length > 0 && (
|
|
52
|
+
<FeaturesSection>
|
|
53
|
+
<FeaturesGrid>
|
|
54
|
+
{features.map((feature) => (
|
|
55
|
+
<FeatureItem feature={feature} key={feature.description} />
|
|
56
|
+
))}
|
|
57
|
+
</FeaturesGrid>
|
|
58
|
+
</FeaturesSection>
|
|
59
|
+
)}
|
|
60
|
+
</PricingContainerStyled>
|
|
61
|
+
)}
|
|
62
|
+
</>
|
|
63
|
+
)
|
|
64
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -319,6 +319,24 @@ html[data-theme='lawdistrictonline'] {
|
|
|
319
319
|
}
|
|
320
320
|
|
|
321
321
|
html[data-theme='legalfinity'] {
|
|
322
|
+
--button: #1039f5;
|
|
323
|
+
--button-secondary: #1039f5;
|
|
324
|
+
--button-hover: #3970ff;
|
|
325
|
+
--button-tertiary: #3970ff;
|
|
326
|
+
--button-2: #07144b;
|
|
327
|
+
--button-4: #07144b;
|
|
328
|
+
--button-2-hover: #163399;
|
|
329
|
+
--button-4-hover: #163399;
|
|
330
|
+
--snackbar-success-color: #163399;
|
|
331
|
+
--button-4-color: #e9f5ff;
|
|
332
|
+
--button-secondary-hover: #d7ecff;
|
|
333
|
+
--feeback-success: #d7ecff;
|
|
334
|
+
--button-tertiary-hover: #b7daff;
|
|
335
|
+
--snackbar-success-bg: #8bc1ff;
|
|
336
|
+
--snackbar-success-border: #5e99ff;
|
|
337
|
+
--snackbar-reminder-bg: #f98116;
|
|
338
|
+
--snackbar-reminder-border: #ea660c;
|
|
339
|
+
|
|
322
340
|
--primary-main-light-6: #e9f5ff;
|
|
323
341
|
--primary-main-light-5: #d7ecff;
|
|
324
342
|
--primary-main-light-4: #b7daff;
|