Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 0 additions & 2 deletions spec/openapi.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,6 @@ info:
termsOfService: 'https://www.smartling.com/legal'
title: Smartling REST API Reference
version: 2.0.0
x-logo:
url: smartling_logo.png
servers:
- url: 'https://api.smartling.com'

Expand Down
19 changes: 19 additions & 0 deletions web/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,25 @@
</style>
</head>
<body>
<script>window.__siteChrome = { property: 'rest' };</script>
<link rel="stylesheet" href="https://graphql-reference.smartling.com/shared/site-chrome.css">
<script src="https://graphql-reference.smartling.com/shared/site-chrome.js" defer></script>
<script>
// ReDoc's own sidebar (.menu-content, incl. its search box) is `position: sticky; top: 0`,
// which collides with the site-chrome header injected above at the same offset once the
// page is scrolled, hiding the sidebar's top edge behind the header. Site-chrome's height
// is owned by the graphql-docs-hub repo, so measure it instead of hardcoding it here.
document.addEventListener('DOMContentLoaded', function () {
var chrome = document.querySelector('.site-chrome');
if (!chrome) return;
var height = chrome.getBoundingClientRect().height + 'px';
var style = document.createElement('style');
style.textContent = '.menu-content { top: ' + height + ' !important; ' +
'height: calc(100vh - ' + height + ') !important; }';
document.head.appendChild(style);
});
</script>

<redoc spec-url="./swagger.json"></redoc>

<script src="https://cdn.jsdelivr.net/npm/redoc@latest/bundles/redoc.standalone.js"> </script>
Expand Down
Binary file removed web/smartling_logo.png
Binary file not shown.