Skip to content

Commit 22328e8

Browse files
Merge pull request #28 from stormikph/tutorial
Tutorial
2 parents 2a650b9 + 4ec8866 commit 22328e8

File tree

13 files changed

+86
-38
lines changed

13 files changed

+86
-38
lines changed

app/src/components/bottom/BottomPanel.tsx

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
11
import React, { useContext } from 'react';
2-
// import { StateContext } from '../../context/context';
2+
import { StateContext } from '../../context/context';
33
import BottomTabs from './BottomTabs';
44
import { Resizable } from 're-resizable';
55

6+
67
// const IPC = require('electron').ipcRenderer;
78

89
const BottomPanel = () => {

app/src/components/bottom/BottomTabs.tsx

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,7 @@ const useStyles = makeStyles(theme => ({
8383
backgroundColor: '#333333',
8484
height: '100%',
8585
color: '#fff',
86-
boxShadow: '0 3px 6px rgba(0,0,0,0.16), 0 3px 6px rgba(0,0,0,0.23)'
86+
boxShadow: '0 3px 6px rgba(0,0,0,0.16), 0 3px 6px rgba(0,0,0,0.23)',
8787
},
8888
bottomHeader: {
8989
flex: 1,
@@ -92,7 +92,8 @@ const useStyles = makeStyles(theme => ({
9292
Width: '200px'
9393
},
9494
tabsRoot: {
95-
borderBottom: '0.5px solid #424242'
95+
borderBottom: '0.5px solid #424242',
96+
minHeight: '50%'
9697
},
9798
tabsIndicator: {
9899
backgroundColor: '#1de9b6'
@@ -129,10 +130,10 @@ const useStyles = makeStyles(theme => ({
129130
},
130131
tabSelected: {},
131132
typography: {
132-
padding: theme.spacing(3) // JZ: updated syntax as per deprecation warning
133+
padding: theme.spacing(3)
133134
},
134135
padding: {
135-
padding: `0 ${theme.spacing(2)}px` // JZ: updated syntax as per deprecation warning
136+
padding: `0 ${theme.spacing(2)}px`
136137
},
137138
switch: {
138139
marginRight: '10px',

app/src/public/styles/style.css

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -248,13 +248,10 @@ RIGHT COLUMN
248248
transition: width 250ms ease-in-out;
249249
width: 100%;
250250
height: 100%;
251-
min-height: 500px;
252-
/* display: flex;
253-
flex-direction: row; */
251+
min-height: 100%;
252+
/* display: flex; */
253+
/* flex-direction: row; */
254254
background-color: #fcfcfc;
255-
/* box-shadow: 0 -5px 7px 2px rgb(255, 0, 0); */
256-
/* margin-right: 100px;
257-
padding-right: 10px; */
258255
}
259256

260257
.htmlattr {

app/src/tutorial/Canvas.tsx

Lines changed: 27 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2,19 +2,40 @@ import React from 'react';
22
import { Link, RouteComponentProps } from 'react-router-dom';
33

44
// import Grid from '@material-ui/core/Grid';
5+
import { makeStyles } from '@material-ui/core/styles';
56

6-
// import ComponentPanel from '../components/left/ComponentPanel';
7-
// import HTMLPanel from '../components/left/HTMLPanel';
8-
9-
// Left-hand portion of the app, where component options are displayed
7+
//images
8+
import canvas1 from '../../../resources/canvas_tutorial_images/canvas1.png';
9+
import drag1 from '../../../resources/canvas_tutorial_images/drag1.png';
1010

1111
const Canvas: React.FC<{
1212
classes: any;
1313
setPage: Function;
1414
}> = ({ classes, setPage }) => {
1515
return (
16-
<div>
17-
Canvas
16+
<div className={classes.wrapper}>
17+
<h1 className={classes.title}>Canvas Tutorial</h1>
18+
19+
<div className={classes.wrapper}>
20+
<h1 className={classes.title}>Canvas</h1>
21+
<p className={classes.text}>The canvas is located at the center of the page. </p>
22+
23+
<div className={classes.imgWrapper}>
24+
<img className={classes.img} src={canvas1}/>
25+
</div>
26+
27+
<h1 className={classes.title}>Drag-n-Drop</h1>
28+
<p className={classes.text}>The drag-n-drop functionality is implemented for the canvas to be populated.</p>
29+
<p className={classes.text}>This functionality can be located on the entire left container of the application.</p>
30+
<p className={classes.text}>Select a given HTML tag or a custom HTML tag, click and hold to drag on to a reusable components or page.</p>
31+
32+
<div className={classes.imgWrapper}>
33+
<img className={classes.img} src={drag1}/>
34+
</div>
35+
36+
<p className={classes.text}>Select a reusable component, click and hold to drag on to a page.</p>
37+
<p className={classes.text}>Drag the selected item on to the center canvas.</p>
38+
</div>
1839
</div>
1940
);
2041
};

app/src/tutorial/CodePreview.tsx

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -2,19 +2,21 @@ import React from 'react';
22
import { Link, RouteComponentProps } from 'react-router-dom';
33

44
// import Grid from '@material-ui/core/Grid';
5-
6-
// import ComponentPanel from '../components/left/ComponentPanel';
7-
// import HTMLPanel from '../components/left/HTMLPanel';
8-
9-
// Left-hand portion of the app, where component options are displayed
5+
import { makeStyles } from '@material-ui/core/styles';
106

117
const CodePreview: React.FC<{
128
classes: any;
139
setPage: Function;
1410
}> = ({ classes, setPage }) => {
1511
return (
16-
<div>
17-
CodePreview
12+
<div className={classes.wrapper}>
13+
<h1 className={classes.title}>Code Preview</h1>
14+
<div className={classes.wrapper}>
15+
<p className={classes.text}>The code preview is located at the bottom center of the page on the first tab.</p>
16+
<p className={classes.text}>In the preview, the code will load functional components.</p>
17+
<p className={classes.text}>This preview will populate and generate in real-time as you use the drag-n-drop functionality with the canvas.</p>
18+
<p className={classes.text}>To learn more about the canvas, find the tutorial labeled "Canvas".</p>
19+
</div>
1820
</div>
1921
);
2022
};

app/src/tutorial/ReusableComponents.tsx

Lines changed: 32 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2,19 +2,45 @@ import React from 'react';
22
import { Link, RouteComponentProps } from 'react-router-dom';
33

44
// import Grid from '@material-ui/core/Grid';
5+
import { makeStyles } from '@material-ui/core/styles';
56

6-
// import ComponentPanel from '../components/left/ComponentPanel';
7-
// import HTMLPanel from '../components/left/HTMLPanel';
8-
9-
// Left-hand portion of the app, where component options are displayed
7+
//images
8+
import reusablecomponents1 from '../../../resources/reusable_components_tutorial_images/reusablecomponents1.png';
9+
import reusablecomponents2 from '../../../resources/reusable_components_tutorial_images/reusablecomponents2.png';
10+
import reusablecomponents3 from '../../../resources/reusable_components_tutorial_images/reusablecomponents3.png';
1011

1112
const ReusableComponents: React.FC<{
1213
classes: any;
1314
setPage: Function;
1415
}> = ({ classes, setPage }) => {
1516
return (
16-
<div>
17-
ReusableComponents
17+
<div className={classes.wrapper}>
18+
<h1 className={classes.title}>Reusable Components Tutorial</h1>
19+
20+
<div className={classes.wrapper}>
21+
<h1 className={classes.title}>Reusable Components</h1>
22+
<p className={classes.text}>To add a Reusable Component, use the top left input form to name a Component. Then select add to create a new Component.</p>
23+
24+
<div className={classes.imgWrapper}>
25+
<img src={reusablecomponents1} />
26+
</div>
27+
<p className={classes.text}>The Components you create will populate the left container under the section called 'Reusable Components'.</p>
28+
29+
<div className={classes.imgWrapper}>
30+
<img src={reusablecomponents2} />
31+
</div>
32+
33+
<p className={classes.text}>After creating the desired Component, you can now use the components with the drag-n-drop functionality.
34+
If you'd like to know about about the drag-n-drop functionality, please locate the tag Canvas Tutorial for more information on how it works.
35+
</p>
36+
37+
<div className={classes.imgWrapper}>
38+
<img src={reusablecomponents3} />
39+
</div>
40+
41+
<p className={classes.text}>You can place a reusable component inside Pages and populate the component itself with the HTML Elements.</p>
42+
43+
</div>
1844
</div>
1945
);
2046
};

package.json

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -6,27 +6,27 @@
66
"main": "app/electron/main.js",
77
"author": "OS Labs",
88
"contributors": [
9+
"Aaron Bumanglag",
910
"Adam Singer",
11+
"Andrew Cho",
12+
"Brian Han",
1013
"Charles Finocchiaro",
1114
"Chelsey Fewer",
1215
"Christian Padilla",
16+
"Diego Vazquez",
1317
"Eliot Nguyen",
18+
"Fredo Chen",
1419
"Jesse Zuniga",
20+
"Jin Soo Lim",
1521
"Mitchel Severe",
1622
"Natalie Vick",
1723
"Sean Sadykoff",
1824
"Shlomo Porges",
25+
"Stormi Hashimoto",
1926
"Sophia Huttner",
2027
"Tolga Mizrakci",
2128
"Tony Ito-Cole",
22-
"Tyler Sullberg",
23-
"Fredo Chen",
24-
"Aaron Bumanglag",
25-
"Andrew Cho",
26-
"Brian Han",
27-
"Diego Vazquez",
28-
"Jin Soo Lim",
29-
"Stormi Hashimoto"
29+
"Tyler Sullberg"
3030
],
3131
"scripts": {
3232
"postinstall": "ELECTRON_BUILDER_ALLOW_UNRESOLVED_DEPENDENCIES=true electron-builder install-app-deps",
269 KB
Loading
43 KB
Loading

resources/reactype4.png

795 KB
Loading
Loading
Loading
Loading

0 commit comments

Comments
 (0)