Skip to content

Commit

Permalink
fix: stoplight ui height (#2444)
Browse files Browse the repository at this point in the history
## Description

Fixes stoplight ui on massive documentation
https://docs.stoplight.io/docs/elements/d536b917a4e1d-layout

## What type of PR is this? (check all applicable)
- [x] Bug Fix
- [ ] Feature
- [ ] Refactor
- [ ] Deprecation
- [ ] Breaking Change
- [ ] Documentation Update
- [ ] CI

## Checklist
- [ ] I have made corresponding changes to the documentation (`docs/`)
- [ ] I have made corresponding changes to the changelog
(`CHANGELOG.md`)
  • Loading branch information
DjordyKoert authored Feb 14, 2025
1 parent c55c47c commit 1497977
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
2 changes: 1 addition & 1 deletion templates/Stoplight/index.html.twig
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
{{ nelmioAsset(assets_mode, 'stoplight/styles.min.css') }}
{% endblock stylesheets %}
</head>
<body>
<body style="height: 100vh;">
{% block swagger_ui %}
<elements-api id="docs"/>
{% endblock swagger_ui %}
Expand Down
4 changes: 3 additions & 1 deletion tests/Command/DumpCommandTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,9 @@ public function testHtml($htmlConfig, string $expectedHtml): void
'--format' => 'html',
'--html-config' => json_encode($htmlConfig),
]);
self::assertStringContainsString('<body>', $output);
self::assertStringContainsString('<html>', $output);
self::assertStringContainsString('<body', $output);
self::assertStringContainsString('</body>', $output);
self::assertStringContainsString($expectedHtml, $output);
}

Expand Down

0 comments on commit 1497977

Please sign in to comment.