diff --git a/catalog/app/components/JsonDisplay/JsonDisplay.js b/catalog/app/components/JsonDisplay/JsonDisplay.js index 9e4e1cac938..dc84f1da224 100644 --- a/catalog/app/components/JsonDisplay/JsonDisplay.js +++ b/catalog/app/components/JsonDisplay/JsonDisplay.js @@ -16,9 +16,15 @@ const useStyles = M.makeStyles((t) => ({ fontFamily: t.typography.monospace.fontFamily, fontSize: t.typography.body2.fontSize, overflow: 'auto', + padding: '1px', // makes `outline` visible when `overflow: hidden` whiteSpace: 'pre', width: '100%', }, + container: { + alignItems: 'start', + display: 'flex', + flexDirection: 'column', + }, more: { color: t.palette.text.secondary, }, @@ -26,6 +32,9 @@ const useStyles = M.makeStyles((t) => ({ display: 'flex', }, compoundInner: { + alignItems: 'start', + display: 'flex', + flexDirection: 'column', paddingLeft: t.spacing(2), }, hidden: { @@ -43,6 +52,18 @@ const useStyles = M.makeStyles((t) => ({ brace: { color: t.palette.text.secondary, }, + clickable: { + cursor: 'pointer', + '&:hover': { + outline: `1px dotted ${t.palette.text.primary}`, + }, + }, + topLevelIcon: { + margin: '1px 0 0 1px', + }, + tailingBrace: { + padding: t.spacing(0, 0.5), + }, })) const IconBlank = ({ classes }) =>
@@ -199,6 +220,7 @@ function CollapsedEntry({ availableSpace, value, showValuesWhenCollapsed }) { } function CompoundEntry({ + className, name, value, topLevel = true, @@ -225,9 +247,8 @@ function CompoundEntry({ ]) return ( -