Merge branch 'questionnaire' into 'main'
feat: add yandex metric, smartlook manage See merge request witapp/aura-webapp!37
This commit is contained in:
commit
5df6445233
@ -31,10 +31,13 @@ function PaymentTable({ subPlan, buttonClick }: IPaymentTableProps) {
|
|||||||
<hr />
|
<hr />
|
||||||
<div className={styles["table-element"]}>
|
<div className={styles["table-element"]}>
|
||||||
<p>Your cost per 2 weeks after trial</p>
|
<p>Your cost per 2 weeks after trial</p>
|
||||||
|
<div>
|
||||||
|
<span className={styles.discount}>$65</span>
|
||||||
<span>${subPlan.price_cents / 100}</span>
|
<span>${subPlan.price_cents / 100}</span>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
</div>
|
||||||
<CustomButton className={styles.button} onClick={buttonClick}>
|
<CustomButton className={styles.button} onClick={buttonClick}>
|
||||||
get my reading
|
get my reading
|
||||||
</CustomButton>
|
</CustomButton>
|
||||||
|
|||||||
@ -81,3 +81,13 @@
|
|||||||
text-decoration: underline;
|
text-decoration: underline;
|
||||||
font-weight: 600;
|
font-weight: 600;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.discount {
|
||||||
|
text-decoration: line-through;
|
||||||
|
align-self: flex-end;
|
||||||
|
font-weight: 400;
|
||||||
|
font-size: 12px;
|
||||||
|
line-height: 22px;
|
||||||
|
color: rgb(130, 130, 130);
|
||||||
|
margin-right: 4px;
|
||||||
|
}
|
||||||
|
|||||||
@ -1,14 +1,34 @@
|
|||||||
import Title from "@/components/Title";
|
import Title from "@/components/Title";
|
||||||
import styles from "./styles.module.css";
|
import styles from "./styles.module.css";
|
||||||
import CustomButton from "../CustomButton";
|
import CustomButton from "../CustomButton";
|
||||||
|
import { useEffect, useState } from "react";
|
||||||
|
import { yourReadingList } from "@/data/yourReading";
|
||||||
|
|
||||||
interface IYourReadingProps {
|
interface IYourReadingProps {
|
||||||
gender: string;
|
gender: string;
|
||||||
zodiacSign: string;
|
zodiacSign: string;
|
||||||
|
singleOrWithPartner: "single" | "partner";
|
||||||
buttonClick: () => void;
|
buttonClick: () => void;
|
||||||
}
|
}
|
||||||
|
|
||||||
function YourReading({ gender, zodiacSign, buttonClick }: IYourReadingProps) {
|
function YourReading({
|
||||||
|
gender,
|
||||||
|
zodiacSign,
|
||||||
|
singleOrWithPartner = "single",
|
||||||
|
buttonClick,
|
||||||
|
}: IYourReadingProps) {
|
||||||
|
const [points, setPoints] = useState(yourReadingList);
|
||||||
|
|
||||||
|
useEffect(() => {
|
||||||
|
if (singleOrWithPartner === "single") {
|
||||||
|
return setPoints([
|
||||||
|
...yourReadingList.slice(-2),
|
||||||
|
...yourReadingList.slice(0, -2),
|
||||||
|
]);
|
||||||
|
}
|
||||||
|
return setPoints(yourReadingList);
|
||||||
|
}, [singleOrWithPartner]);
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div className={styles["your-reading"]}>
|
<div className={styles["your-reading"]}>
|
||||||
<Title variant="h3" className={styles.title}>
|
<Title variant="h3" className={styles.title}>
|
||||||
@ -25,36 +45,11 @@ function YourReading({ gender, zodiacSign, buttonClick }: IYourReadingProps) {
|
|||||||
Content
|
Content
|
||||||
</Title>
|
</Title>
|
||||||
<ol>
|
<ol>
|
||||||
<li>
|
{points.map((point, index) => (
|
||||||
<p>Compatibility with your partner in other areas of your life.</p>
|
<li key={index}>
|
||||||
</li>
|
<p>{point}</p>
|
||||||
<li>
|
|
||||||
<p>
|
|
||||||
Deep analysis of the relationships with your partner based on a
|
|
||||||
unique birth chart matching system
|
|
||||||
</p>
|
|
||||||
</li>
|
|
||||||
<li>
|
|
||||||
<p>
|
|
||||||
Simple and actionable guide to improving your relationship with
|
|
||||||
your partner
|
|
||||||
</p>
|
|
||||||
</li>
|
|
||||||
<li>
|
|
||||||
<p>
|
|
||||||
Warning about astrological events and practical advice that will
|
|
||||||
help you get through this period well
|
|
||||||
</p>
|
|
||||||
</li>
|
|
||||||
<li>
|
|
||||||
<p>Your horoscope and upcoming events for 2024</p>
|
|
||||||
</li>
|
|
||||||
<li>
|
|
||||||
<p>
|
|
||||||
Your unique strengths and weaknesses and how to get the most out
|
|
||||||
of them
|
|
||||||
</p>
|
|
||||||
</li>
|
</li>
|
||||||
|
))}
|
||||||
</ol>
|
</ol>
|
||||||
<Title variant="h5" className={styles["secondary-title"]}>
|
<Title variant="h5" className={styles["secondary-title"]}>
|
||||||
Personality
|
Personality
|
||||||
|
|||||||
@ -43,7 +43,7 @@ function TrialPaymentPage() {
|
|||||||
activeSubPlanFromStore
|
activeSubPlanFromStore
|
||||||
);
|
);
|
||||||
const [marginTopTitle, setMarginTopTitle] = useState<number>(360);
|
const [marginTopTitle, setMarginTopTitle] = useState<number>(360);
|
||||||
const [informationConditional, setInformationConditional] = useState<
|
const [singleOrWithPartner, setSingleOrWithPartner] = useState<
|
||||||
"single" | "partner"
|
"single" | "partner"
|
||||||
>("single");
|
>("single");
|
||||||
const { subPlan } = useParams();
|
const { subPlan } = useParams();
|
||||||
@ -88,10 +88,10 @@ function TrialPaymentPage() {
|
|||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
if (["relationship", "married"].includes(flowChoice)) {
|
if (["relationship", "married"].includes(flowChoice)) {
|
||||||
setMarginTopTitle(460);
|
setMarginTopTitle(460);
|
||||||
setInformationConditional("partner");
|
setSingleOrWithPartner("partner");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
setInformationConditional("single");
|
setSingleOrWithPartner("single");
|
||||||
setMarginTopTitle(340);
|
setMarginTopTitle(340);
|
||||||
}, [flowChoice]);
|
}, [flowChoice]);
|
||||||
|
|
||||||
@ -110,7 +110,7 @@ function TrialPaymentPage() {
|
|||||||
return (
|
return (
|
||||||
<section className={`${styles.page} page`}>
|
<section className={`${styles.page} page`}>
|
||||||
<Header buttonClick={handleNext} />
|
<Header buttonClick={handleNext} />
|
||||||
{informationConditional === "partner" && (
|
{singleOrWithPartner === "partner" && (
|
||||||
<WithPartnerInformation
|
<WithPartnerInformation
|
||||||
zodiacSign={zodiacSign}
|
zodiacSign={zodiacSign}
|
||||||
gender={gender}
|
gender={gender}
|
||||||
@ -122,7 +122,7 @@ function TrialPaymentPage() {
|
|||||||
partnerZodiacSign={partnerZodiacSign}
|
partnerZodiacSign={partnerZodiacSign}
|
||||||
/>
|
/>
|
||||||
)}
|
)}
|
||||||
{informationConditional === "single" && (
|
{singleOrWithPartner === "single" && (
|
||||||
<PersonalInformation
|
<PersonalInformation
|
||||||
zodiacSign={zodiacSign}
|
zodiacSign={zodiacSign}
|
||||||
gender={gender}
|
gender={gender}
|
||||||
@ -143,6 +143,7 @@ function TrialPaymentPage() {
|
|||||||
gender={gender}
|
gender={gender}
|
||||||
zodiacSign={zodiacSign}
|
zodiacSign={zodiacSign}
|
||||||
buttonClick={handleNext}
|
buttonClick={handleNext}
|
||||||
|
singleOrWithPartner={singleOrWithPartner}
|
||||||
/>
|
/>
|
||||||
<Reviews />
|
<Reviews />
|
||||||
<YouGet />
|
<YouGet />
|
||||||
|
|||||||
8
src/data/yourReading.ts
Executable file
8
src/data/yourReading.ts
Executable file
@ -0,0 +1,8 @@
|
|||||||
|
export const yourReadingList = [
|
||||||
|
"Compatibility with your partner in other areas of your life.",
|
||||||
|
"Deep analysis of the relationships with your partner based on a unique birth chart matching system",
|
||||||
|
"Simple and actionable guide to improving your relationship with your partner",
|
||||||
|
"Warning about astrological events and practical advice that will help you get through this period well",
|
||||||
|
"Your horoscope and upcoming events for 2024",
|
||||||
|
"Your unique strengths and weaknesses and how to get the most out of them",
|
||||||
|
];
|
||||||
Loading…
Reference in New Issue
Block a user