A few mini-fixes for the accessibility layout inspector

Summary:
- fix mutual selection of elements in ax and non-ax tree (simplifies linkedNode logic as well)
- remove unneeded extraInfo attributes (focused, nonAXwithAXchild, & hasAXNode were not/no longer being used)
- use 50/50 fixed width view for trees when both are visible

Reviewed By: jknoxville

Differential Revision: D16390355

fbshipit-source-id: bbf9ea887f8f1035df8b4b0562ddcc4de291f004
This commit is contained in:
Sara Valderrama
2019-08-01 21:58:40 -07:00
committed by Facebook Github Bot
parent 3ed71680a1
commit f591475f85
11 changed files with 81 additions and 82 deletions

View File

@@ -36,9 +36,8 @@ export type ElementAttribute = {|
|};
export type ElementExtraInfo = {|
nonAXWithAXChild?: boolean,
linkedAXNode?: string,
focused?: boolean,
linkedNode?: string, // id of linked node in opposite tree
expandWithParent?: boolean,
|};
export type Element = {|
@@ -86,21 +85,19 @@ export default class ElementsInspector extends Component<{
} = this.props;
return (
<FlexRow grow={true}>
<Elements
onElementExpanded={onElementExpanded}
onElementSelected={onElementSelected}
onElementHovered={onElementHovered}
selected={selected}
focused={focused}
searchResults={searchResults}
root={root}
elements={elements}
alternateRowColor={alternateRowColor}
contextMenuExtensions={contextMenuExtensions}
decorateRow={decorateRow}
/>
</FlexRow>
<Elements
onElementExpanded={onElementExpanded}
onElementSelected={onElementSelected}
onElementHovered={onElementHovered}
selected={selected}
focused={focused}
searchResults={searchResults}
root={root}
elements={elements}
alternateRowColor={alternateRowColor}
contextMenuExtensions={contextMenuExtensions}
decorateRow={decorateRow}
/>
);
}
}