diff --git a/docs/usage/configuration.md b/docs/usage/configuration.md
index 41b5b3d1d858..dee7be64c67c 100644
--- a/docs/usage/configuration.md
+++ b/docs/usage/configuration.md
@@ -208,7 +208,7 @@ Parameter name | Docker variable | Description
- renderSizeThreshold
+ payload.render.sizeThreshold
|
Unavailable |
The maximum size (in bytes) of a payload to render.
diff --git a/src/core/components/highlight-code.jsx b/src/core/components/highlight-code.jsx
index 9549fe48a53b..3702c748608e 100644
--- a/src/core/components/highlight-code.jsx
+++ b/src/core/components/highlight-code.jsx
@@ -9,7 +9,7 @@ import { CopyToClipboard } from "react-copy-to-clipboard"
const HighlightCode = ({value, fileName = "response.txt", className, downloadable, getConfigs, canCopy, language}) => {
const config = isFunction(getConfigs) ? getConfigs() : null
- const renderSizeThreshold = get(config, "renderSizeThreshold")
+ const renderSizeThreshold = get(config, "payload.render.sizeThreshold")
const canSyntaxHighlight = get(config, "syntaxHighlight") !== false && get(config, "syntaxHighlight.activated", true)
const syntaxHighlightSizeThreshold = canSyntaxHighlight ? get(config, "syntaxHighlight.sizeThreshold", undefined) : undefined
const rootRef = useRef(null)
diff --git a/test/unit/components/highlight-code.jsx b/test/unit/components/highlight-code.jsx
index 84794bc3a04d..f0cbaf35a329 100644
--- a/test/unit/components/highlight-code.jsx
+++ b/test/unit/components/highlight-code.jsx
@@ -9,10 +9,14 @@ const defaultSyntaxHighlightConfig = {
}
const fakeGetConfigs = (
- renderSizeThreshold = undefined,
- syntaxHighlight = defaultSyntaxHighlightConfig) => (
+ renderSizeThreshold = undefined,
+ syntaxHighlight = defaultSyntaxHighlightConfig) => (
{
- renderSizeThreshold: renderSizeThreshold,
+ payload: {
+ render: {
+ sizeThreshold: renderSizeThreshold,
+ }
+ },
syntaxHighlight: syntaxHighlight
})
|