Skip to content

Commit c0d2e76

Browse files
authored
Merge pull request #301 from open-source-labs/dev
Merge v17.0.0 into master
2 parents 6569971 + 7a2218e commit c0d2e76

File tree

294 files changed

+2267
-134761
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

294 files changed

+2267
-134761
lines changed

README.fr.md

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,10 +18,10 @@
1818
</a>
1919
<a href="https://travis-ci.com/oslabs-beta/reactime">
2020
<img src="https://travis-ci.com/oslabs-beta/reactime.svg?branch=master" alt="Build Status">
21-
</a>
21+
</a>
2222
<a href="http://badge.fury.io/js/reactime">
2323
<img src="https://badge.fury.io/js/reactime.svg" alt="npm version">
24-
</a>
24+
</a>
2525
<img src="https://img.shields.io/badge/babel%20preset-airbnb-ff69b4" alt="BabelPresetPrefs">
2626
<img src="https://img.shields.io/badge/linted%20with-eslint-blueviolet" alt="LintPrefs">
2727
</p>
@@ -40,7 +40,7 @@
4040
</p>
4141

4242
<p align="center">
43-
  <a href="#how-to-use">Manuel</a> • <a href="#features">Caractéristiques</a> • <a href="https://reactime.io">Website</a> • <a href="#readmore">En savoir plus</a>
43+
  <a href="#how-to-use">Manuel</a> • <a href="#features">Caractéristiques</a> • <a href="https://reactime.dev">Website</a> • <a href="#readmore">En savoir plus</a>
4444
</p>
4545

4646
Actuellement, Reactime est compatible avec les applications React qui utilisent des composants à état (stateful) et Hooks, avec un support en version bêta de Recoil et de pour le Context API.
@@ -131,6 +131,10 @@ Après avoir cloné ce référentiel, les développeurs peuvent simplement exéc
131131

132132
## <b>Auteurs</b>
133133

134+
- **Ben Margolius** - [@benmarg](https://github.com/benmarg)
135+
- **Eric Yun** - [@ericsngyun](https://github.com/ericsngyun)
136+
- **James Nghiem** - [@jemzir](https://github.com/jemzir)
137+
- **Wilton Lee** - [@wiltonlee948](https://github.com/wiltonlee948)
134138
- **David Kim** - [@codejunkie7](https://github.com/codejunkie7)
135139
- **Robby Tipton** - [@RobbyTipton](https://github.com/RobbyTipton)
136140
- **Kevin HoEun Lee** - [@khobread](https://github.com/khobread)

README.md

Lines changed: 125 additions & 49 deletions
Large diffs are not rendered by default.

README.rus.md

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -106,7 +106,10 @@ Reactime beta поддерживает приложения, написанны
106106
- [Deep in Weeds with Reactime, Concurrent React_fiberRoot, and Browser History Caching](https://itnext.io/deep-in-the-weeds-with-reactime-concurrent-react-fiberroot-and-browser-history-caching-7ce9d7300abb)
107107

108108
## <b>Авторы</b>
109-
109+
- **Ben Margolius** - [@benmarg](https://github.com/benmarg)
110+
- **Eric Yun** - [@ericsngyun](https://github.com/ericsngyun)
111+
- **James Nghiem** - [@jemzir](https://github.com/jemzir)
112+
- **Wilton Lee** - [@wiltonlee948](https://github.com/wiltonlee948)
110113
- **David Kim** - [@codejunkie7](https://github.com/codejunkie7)
111114
- **Robby Tipton** - [@RobbyTipton](https://github.com/RobbyTipton)
112115
- **Kevin HoEun Lee** - [@khobread](https://github.com/khobread)

demo-app/src/client/Router.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,8 @@ ReactDOM.render(
1212
<BrowserRouter>
1313
<Nav />
1414
<Routes>
15-
<Route path="/tictactoe" element={<Board />}/>
16-
<Route path="/" element={<Home />}/>
17-
<Route path="/buttons" element={<Buttons />}/>
15+
<Route path="/tictactoe" element={<Board />}/>
16+
<Route path="/" element={<Home />}/>
17+
<Route path="/buttons" element={<Buttons />}/>
1818
</Routes>
1919
</BrowserRouter>, root);

demo-app/webpack.config.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,7 @@ module.exports = {
4141
}),
4242
],
4343
devServer: {
44+
historyApiFallback: true,
4445
static: {
4546
directory: path.join(__dirname, './dist'),
4647
},

package.json

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,10 @@
55
"transform": {
66
"^.+\\.(js|ts|tsx)$": "ts-jest"
77
},
8-
"transformIgnorePatterns": ["/node_modules/(?!d3|d3-array|internmap|delaunator|robust-predicates)"],
8+
"testPathIgnorePatterns": ["www"],
9+
"transformIgnorePatterns": [
10+
"/node_modules/(?!d3|d3-array|internmap|delaunator|robust-predicates)"
11+
],
912
"testRegex": "(/__tests__/.*|\\.(test|spec))\\.(ts|tsx|js)$",
1013
"moduleFileExtensions": [
1114
"ts",
@@ -46,6 +49,7 @@
4649
"Andy Tsou",
4750
"Andy Wong",
4851
"Becca Viner",
52+
"Ben Margolius",
4953
"Bryan Lee",
5054
"Caitlin Chan",
5155
"Caner Demir",
@@ -58,12 +62,14 @@
5862
"Dennis Lopez",
5963
"Edwin Menendez",
6064
"Ergi Shehu",
65+
"Eric Yun",
6166
"Freya Wu",
6267
"Gabriela Jardim Aquino",
6368
"Gregory Panciera",
6469
"Haejin Jo",
6570
"Hien Nguyen",
6671
"Jack Crish",
72+
"James Nghiem",
6773
"Joseph Park",
6874
"Josh Kim",
6975
"Joshua Howard",
@@ -83,6 +89,7 @@
8389
"Sierra Swaby",
8490
"Tania Lind",
8591
"Viet Nguyen",
92+
"Wilton Lee",
8693
"Yujin Kang"
8794
],
8895
"license": "ISC",
@@ -94,6 +101,7 @@
94101
"@babel/preset-react": "^7.12.7",
95102
"@emotion/babel-plugin": "^11.7.2",
96103
"@testing-library/jest-dom": "^4.2.4",
104+
"@testing-library/react": "^13.4.0",
97105
"@types/chai": "^4.2.14",
98106
"@types/chrome": "^0.0.119",
99107
"@types/d3": "^7.4.0",

src/app/components/StateRoute/ComponentMap/ComponentMap.tsx

Lines changed: 21 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ export default function ComponentMap({
4747
}: LinkTypesProps): JSX.Element {
4848
// importing custom hooks for the selection tabs.
4949
const [layout, setLayout] = useState('cartesian');
50-
const [orientation, setOrientation] = useState('horizontal');
50+
const [orientation, setOrientation] = useState('vertical');
5151
const [linkType, setLinkType] = useState('diagonal');
5252
const [stepPercent, setStepPercent] = useState(10);
5353
const [Tooltip, setTooltip] = useState(false);
@@ -153,6 +153,19 @@ export default function ComponentMap({
153153
return propsFormat;
154154
};
155155

156+
const formatContext = data => {
157+
const propsFormat = [];
158+
const nestedObj = [];
159+
for (const key in data) {
160+
propsFormat.push(
161+
<p className="stateprops">
162+
{`${key}: ${data[key]}`}
163+
</p>,
164+
);
165+
}
166+
return propsFormat;
167+
};
168+
156169
const formatState = state => {
157170
if (state === 'stateless') return ['stateless'];
158171
return ['stateful'];
@@ -378,10 +391,15 @@ export default function ComponentMap({
378391
{formatState(tooltipData.state)}
379392
</div>
380393
<div style={React.scrollStyle}>
381-
<div className="props">
382-
Props:
394+
<div className="tooltipWrapper">
395+
<h2>Props:</h2>
383396
{formatProps(tooltipData.componentData.props)}
384397
</div>
398+
{tooltipData.componentData.context &&
399+
<div className="tooltipWrapper">
400+
<h2>Context:</h2>
401+
{formatContext(tooltipData.componentData.context)}
402+
</div>}
385403
</div>
386404
</div>
387405
</TooltipInPortal>

src/app/components/StateRoute/ComponentMap/LinkControls.tsx

Lines changed: 5 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -89,8 +89,8 @@ export default function LinkControls({
8989
disabled={layout === 'polar'}
9090
style={dropDownStyle}
9191
>
92-
<option value="horizontal">Horizontal</option>
9392
<option value="vertical">Vertical</option>
93+
<option value="horizontal">Horizontal</option>
9494
</select>
9595
&nbsp;&nbsp;
9696

@@ -110,19 +110,16 @@ export default function LinkControls({
110110
{/* Controls for the select selections. */}
111111
<label> Select:</label>
112112
&nbsp;
113-
<input
113+
<select
114114
id="selectInput"
115-
list="nodeOptions"
116-
type="text"
117115
name="nodeOptions"
118116
onChange={e => setSelectedNode(e.target.value)}
119117
style={dropDownStyle}
120-
/>
121-
<datalist id="nodeOptions">
118+
>
122119
{nodeList.map(node => (
123-
<option key={node.name} value={node.name}>{node.name}</option>
120+
node.children.length > 0 && <option key={node.name} value={node.name}>{node.name}</option>
124121
))}
125-
</datalist>
122+
</select>
126123

127124
{/* This is the slider control for the step option */}
128125
{linkType === 'step' && layout !== 'polar' && (

src/app/containers/ErrorContainer.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -84,11 +84,11 @@ function ErrorContainer(): any {
8484
</div>
8585
<br />
8686
<a
87-
href="https://reactime.io/"
87+
href="https://reactime.dev/"
8888
target="_blank"
8989
rel="noopener noreferrer"
9090
>
91-
Please visit reactime.io to more info.
91+
Please visit reactime.dev to more info.
9292
</a>
9393
</div>
9494
);

src/app/styles/main.scss

Lines changed: 29 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,33 @@
11
@charset 'UTF-8';
22
@import url('https://fonts.googleapis.com/css2?family=Roboto:ital,wght@0,100;0,300;0,400;0,500;0,700;0,900;1,100;1,300;1,400;1,500;1,700;1,900&display=swap');
3+
34
* {
45
font-family: 'Roboto', sans-serif;
56
}
67

8+
.tooltipWrapper {
9+
background-color: #505050;
10+
color: rgb(216, 216, 216);
11+
margin-top: 3px;
12+
margin-bottom: 3px;
13+
padding: 2px;
14+
}
15+
16+
.tooltipWrapper h2 {
17+
margin-top: 1px;
18+
margin-bottom: 1px;
19+
margin-left: 1px;
20+
font-size: small;
21+
font-weight: bolder;
22+
}
23+
24+
.tooltipWrapper p {
25+
margin-top: 1px;
26+
margin-bottom: 1px;
27+
margin-left: 10px;
28+
margin-right: 3px;
29+
}
30+
731
/* width */
832
::-webkit-scrollbar {
933
width: 5px;
@@ -36,13 +60,13 @@
3660

3761
// 4. Layout-related sections
3862
@import 'layout/mainContainer', 'layout/bodyContainer', 'layout/actionContainer',
39-
'layout/errorContainer', 'layout/stateContainer', 'layout/travelContainer',
40-
'layout/buttonsContainer', 'layout/headContainer.scss';
63+
'layout/errorContainer', 'layout/stateContainer', 'layout/travelContainer',
64+
'layout/buttonsContainer', 'layout/headContainer.scss';
4165

4266
// 5. Components
4367
@import 'components/buttons', 'components/actionComponent',
44-
'components/jsonTree', 'components/renderingFrequency',
45-
'components/performanceVisx';
68+
'components/jsonTree', 'components/renderingFrequency',
69+
'components/performanceVisx';
4670

4771
// slider component
4872
@import './components/rc-slider', './components/sliderHandle';
@@ -51,4 +75,4 @@
5175
@import './components/d3graph.css';
5276

5377
// diff component
54-
@import './components/diff';
78+
@import './components/diff';

0 commit comments

Comments
 (0)