Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

added react joyride tour configuration #6767

Merged
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,9 @@ import RootStore from 'Stores/index';
import AppStore from 'Stores/app-store';
import { connect } from 'Stores/connect';
import WorkspaceWrapper from './workspace-wrapper';
import ReactJoyride from 'react-joyride';
import classNames from 'classnames';
import { BOT_BUILDER_TOUR } from '../joyride-config';

type TBotBuilder = {
app: AppStore;
Expand All @@ -19,17 +21,39 @@ const BotBuilder = ({ app, active_tab }: TBotBuilder) => {
}, []);

return (
<div className={classNames('bot-builder', { 'bot-builder--active': active_tab === 1 })}>
<div
id='scratch_div'
style={{
width: 'calc(100vw - 3.2rem)',
height: 'var(--bot-content-height)',
}}
>
<WorkspaceWrapper />
<>
<div className={classNames('bot-builder', { 'bot-builder--active': active_tab === 1 })}>
<div
id='scratch_div'
style={{
width: 'calc(100vw - 3.2rem)',
height: 'var(--bot-content-height)',
}}
>
<WorkspaceWrapper />
{active_tab === 1 && (
<ReactJoyride
steps={BOT_BUILDER_TOUR}
continuous={true}
showProgress={true}
styles={{
options: {
arrowColor: 'var(--text-general)',
backgroundColor: 'var(--text-general)',
overlayColor: 'rgba(0, 0, 0, 0.5)',
primaryColor: '#FF444F',
farabi-deriv marked this conversation as resolved.
Show resolved Hide resolved
textColor: 'white',
spotlightShadow: '0 0 15px rgba(0, 0, 0, 0.5)',
},
buttonClose: {
color: 'white',
},
}}
/>
)}
</div>
</div>
</div>
</>
);
};

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
justify-content: space-between;
align-items: center;
padding: 5px 6px;
z-index: 1;

&__btn {
background-color: var(--button-primary-default) !important;
Expand Down
13 changes: 13 additions & 0 deletions packages/bot-web-ui/src/components/dashboard/dashboard.scss
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@
width: 23.6rem;
padding: 0.8rem;
background: var(--general-main-1);
z-index: 1;
.db-toolbox {
&__title {