knuckleswtf / scribe

Generate API documentation for humans from your Laravel codebase.✍
https://scribe.knuckles.wtf/laravel/
MIT License
1.58k stars 280 forks source link

Large Request breaks Elements theme #833

Open rmundel opened 3 months ago

rmundel commented 3 months ago

Scribe version

4.34.0

PHP version

8.1

Framework

Laravel

Framework version

9.52.16

Scribe config

title => "WebService"
base_url => "https://localhost:3000"
theme => "elements"
static.output_path => "docs/"
laravel.add_routes => false
try_it_out.enabled => false
auth.enabled => true
auth.default => true
auth.name => "token"
auth.placeholder => "{YOU_API_TOKEN}"
logo => "https://localhost:8000/statics/app-logo-128x128.png"
last_updated => "Last update: {date:d/m/Y H:i:s}"
strategies.urlParameters => added Knuckles\Scribe\Extracting\Strategies\UrlParameters\GetFromLumenAPI
strategies.headers => added Knuckles\Scribe\Extracting\Strategies\Headers\GetFromRouteRules: removed [
    'override',
    [
        'Content-Type' => 'application/json',
        'Accept' => 'application/json',
    ],
]
strategies.responses => added Knuckles\Scribe\Extracting\Strategies\Responses\ResponseCalls: removed [
    'Knuckles\\Scribe\\Extracting\\Strategies\\Responses\\ResponseCalls',
    [
        'only' => [
            'GET *',
        ],
    ],
]

What happened?

The Request sample block in the Elements theme breaks when using large Request sample: image

The Response sample works fine, applying the scroll bar correctly: image

Docs

shalvah commented 3 months ago

Thanks for the report. I can't promise any timeline for this fix, so I recommend switching type in your config to the external_static or external_laravel, as that will use the stylesheets directly from the Stoplight Elements website.