Skip to content

Commit 5e34d93

Browse files
committed
changed ax toggle note to have 'Chrome Debugger API' instead of 'Chrome Debugging API'
1 parent beb2f54 commit 5e34d93

File tree

1 file changed

+35
-27
lines changed
  • src/app/components/StateRoute

1 file changed

+35
-27
lines changed

src/app/components/StateRoute/Ax.tsx

Lines changed: 35 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -35,52 +35,60 @@ const AxTree = (props) => {
3535

3636
const dispatch = useDispatch();
3737
const [showTree, setShowTree] = useState(false);
38-
const [selectedValue, setSelectedValue] = useState('disable')
39-
const [showParagraph, setShowParagraph] = useState(true)
38+
const [selectedValue, setSelectedValue] = useState('disable');
39+
const [showParagraph, setShowParagraph] = useState(true);
4040

4141
const enableAxTreeButton = () => {
4242
dispatch(toggleAxTree('toggleAxRecord'));
4343
dispatch(setCurrentTabInApp('AxTree'));
4444
setSelectedValue('enable');
4545
setShowParagraph(false);
4646
setShowTree(true);
47-
}
47+
};
4848

4949
const disableAxTree = () => {
5050
dispatch(toggleAxTree('toggleAxRecord'));
5151
setSelectedValue('disable');
5252
setShowParagraph(true);
5353
setShowTree(false);
54-
}
54+
};
5555

5656
return (
5757
<div>
58-
{showParagraph && <p>A Note to Developers: Reactime is using the Chrome Debugging API in order to grab the Accessibility Tree. Enabling this option will allow you to record Accessibility Tree snapshots, but will result in the Chrome browser notifying you that the Chrome Debugger has started.</p>}
58+
{showParagraph && (
59+
<p>
60+
A Note to Developers: Reactime is using the Chrome Debugger API in order to grab the
61+
Accessibility Tree. Enabling this option will allow you to record Accessibility Tree
62+
snapshots, but will result in the Chrome browser notifying you that the Chrome Debugger
63+
has started.
64+
</p>
65+
)}
5966
<div>
60-
{<input
61-
type='radio'
62-
value='enable'
63-
checked={selectedValue === 'enable'}
64-
onChange={() => {
65-
enableAxTreeButton();
66-
}}
67-
/>}
67+
{
68+
<input
69+
type='radio'
70+
value='enable'
71+
checked={selectedValue === 'enable'}
72+
onChange={() => {
73+
enableAxTreeButton();
74+
}}
75+
/>
76+
}
6877
<label htmlFor='enable'>Enable</label>
69-
{<input
70-
type='radio'
71-
value='disable'
72-
checked={selectedValue === 'disable'}
73-
onChange={() => {
74-
disableAxTree();
75-
}}
76-
/>}
78+
{
79+
<input
80+
type='radio'
81+
value='disable'
82+
checked={selectedValue === 'disable'}
83+
onChange={() => {
84+
disableAxTree();
85+
}}
86+
/>
87+
}
7788
<label htmlFor='disable'>Disable</label>
7889
</div>
79-
{showTree && <JSONTree
80-
data={axSnapshots[currLocation.index]}
81-
theme={theme}
82-
/>}
83-
</div>
84-
)
90+
{showTree && <JSONTree data={axSnapshots[currLocation.index]} theme={theme} />}
91+
</div>
92+
);
8593
};
8694
export default AxTree;

0 commit comments

Comments
 (0)