-
Notifications
You must be signed in to change notification settings - Fork 8
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'enhance/ai-onboarding' into PRESS2-1233-merge-component…
…s-aionboarding
- Loading branch information
Showing
13 changed files
with
200 additions
and
45 deletions.
There are no files selected for viewing
32 changes: 32 additions & 0 deletions
32
src/OnboardingSPA/components/Button/NextButtonSiteGen/index.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
import { useNavigate } from 'react-router-dom'; | ||
|
||
import { useSelect } from '@wordpress/data'; | ||
import { Button } from '@wordpress/components'; | ||
import { store as nfdOnboardingStore } from '../../../store'; | ||
import classNames from 'classnames'; | ||
|
||
const NextButtonSiteGen = ( { text, className } ) => { | ||
const navigate = useNavigate(); | ||
const { nextStep } = useSelect( ( select ) => { | ||
return { | ||
nextStep: select( nfdOnboardingStore ).getNextStep(), | ||
}; | ||
} ); | ||
return ( | ||
<Button | ||
className={ classNames( | ||
'nfd-onboarding-button--site-gen-next', | ||
className | ||
) } | ||
onClick={ () => { | ||
if ( nextStep ) { | ||
navigate( nextStep.path ); | ||
} | ||
} } | ||
> | ||
{ text } | ||
</Button> | ||
); | ||
}; | ||
|
||
export default NextButtonSiteGen; |
25 changes: 25 additions & 0 deletions
25
src/OnboardingSPA/components/Button/NextButtonSiteGen/stylesheet.scss
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
.nfd-onboarding-button { | ||
|
||
&--site-gen-next { | ||
display: block; | ||
background-color: var(--nfd-onboarding-primary); | ||
color: var(--nfd-onboarding-secondary); | ||
text-align: center; | ||
width: 164px; | ||
height: 50px; | ||
font-size: clamp(0.5rem, 0.3864rem + 0.5682vw, 1.75rem); | ||
margin-top: 24px; | ||
border-radius: 6px; | ||
|
||
@media (min-width: 2600px ) { | ||
width: 250px; | ||
height: 76px; | ||
} | ||
|
||
@media (max-width: #{ ($break-small) }) { | ||
width: 100px; | ||
height: 30px; | ||
margin-top: 10px; | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
import { __ } from '@wordpress/i18n'; | ||
|
||
const getContents = () => { | ||
return { | ||
heading: __( 'Website Creator for WordPress', 'wp-module-onboarding' ), | ||
subHeading: __( | ||
'Tell our AI engine what kind of site you want to make and let it handle the content and design for you.', | ||
'wp-module-onboarding' | ||
), | ||
buttonText: __( 'Get Started', 'wp-module-onboarding' ), | ||
}; | ||
}; | ||
|
||
export default getContents; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,85 @@ | ||
.nfd-onboarding-step { | ||
|
||
&--site-gen { | ||
|
||
&__welcome { | ||
display: flex; | ||
justify-content: center; | ||
|
||
&__container { | ||
display: flex; | ||
flex-direction: column; | ||
align-items: center; | ||
justify-content: center; | ||
width: 500px; | ||
|
||
@media (max-width: #{ ($break-small) }) { | ||
margin: 16px; | ||
} | ||
|
||
@media (min-width: 2600px ) { | ||
width: 1000px; | ||
} | ||
|
||
&__animation { | ||
background-image: var(--sitegen-ai-animation); | ||
background-repeat: no-repeat; | ||
background-size: cover; | ||
width: 250px; | ||
height: 183px; | ||
} | ||
|
||
&__heading { | ||
display: flex; | ||
flex-direction: row; | ||
width: 100%; | ||
padding: 0; | ||
justify-content: center; | ||
align-items: center; | ||
|
||
&__image { | ||
height: 36px; | ||
width: 42px; | ||
background-image: var(--sitegen-ai-icon); | ||
background-repeat: no-repeat; | ||
background-size: cover; | ||
|
||
@media (max-width: #{ ($break-small) }) { | ||
width: 32px; | ||
height: 27px; | ||
} | ||
|
||
@media (min-width: 2600px ) { | ||
width: 100px; | ||
height: 86px; | ||
} | ||
|
||
} | ||
|
||
&__text { | ||
color: var(--nfd-onboarding-primary); | ||
font-size: clamp(0.875rem, 0.6818rem + 0.9659vw, 3rem); | ||
margin-left: 15px; | ||
white-space: normal; | ||
line-height: 1; | ||
} | ||
} | ||
|
||
&__sub-heading { | ||
width: 100%; | ||
margin: 10px; | ||
padding: 0; | ||
|
||
&__text { | ||
text-align: center; | ||
color: var(--nfd-onboarding-primary); | ||
font-size: clamp(0.875rem, 0.7727rem + 0.5114vw, 2rem); | ||
margin: 0; | ||
padding: 0; | ||
} | ||
} | ||
} | ||
} | ||
|
||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters