webpack/components/ReportJsonViewer.js in foreman_ansible-9.0.0 vs webpack/components/ReportJsonViewer.js in foreman_ansible-9.0.1
- old
+ new
@@ -8,10 +8,20 @@
base00: 'rgba(0, 0, 0, 0)',
};
const ReportJsonViewer = ({ data }) => (
<div className="report-json-viewer">
- <JSONTree data={data} hideRoot theme={theme} />
+ <JSONTree
+ data={data}
+ hideRoot
+ theme={theme}
+ shouldExpandNode={(keyPath, _myData, level) =>
+ keyPath[0] === '_meta' ||
+ keyPath[0] === 'hostvars' ||
+ level === 3 ||
+ keyPath[0] === 'foreman_ansible_roles'
+ }
+ />
</div>
);
ReportJsonViewer.propTypes = {
data: PropTypes.object.isRequired,