improved performance of jsonViewer by only expanding the first element up to the specified maxDepth, removed needless function calls , fixed clipMode of jsonViewer