Skip to content

Conversation

@MarcL
Copy link
Contributor

@MarcL MarcL commented Mar 3, 2023

This adds the legal compliance footer as discussed in https://github.com/netlify/pod-ecosystem-frameworks/issues/418.

It's not pretty but it injects the footer into the generated redoc page in the same way as the meta tags in the <head>.

Screenshot

CleanShot 2023-03-06 at 14 33 56

@MarcL MarcL requested a review from a team as a code owner March 3, 2023 14:30
@netlify
Copy link

netlify bot commented Mar 3, 2023

Deploy Preview for open-api ready!

Name Link
🔨 Latest commit f5726bb
🔍 Latest deploy log https://app.netlify.com/sites/open-api/deploys/6405f9cfce147b0008a7271a
😎 Deploy Preview https://deploy-preview-432--open-api.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site settings.

@github-actions github-actions bot added the type: bug code to address defects in shipped code label Mar 3, 2023
@MarcL MarcL self-assigned this Mar 3, 2023
@jasonbarry
Copy link
Contributor

Thanks for jumping on this @MarcL to make sure that we are compliant!!

I wanted to point out this resource for modifying footer content for redoc-powered sites: https://redocly.com/docs/developer-portal/guides/navbars-footers/#modify-footer-contents

Maybe this approach can be used instead of the injection approach?

Not a blocker by any means, esp with the Mar 7 turnaround time, but wanted to throw that out there!

@MarcL
Copy link
Contributor Author

MarcL commented Mar 3, 2023

Hey @jasonbarry.

I did look at this as I really don't like the way this is done. Injecting the code in this way didn't sit right with me!

It felt beyond the scope of the work here as the link you shared would need us to also create the developer portal I think. Currently, it uses the Swagger schema to generate and it looked like we'd need more config. I had a read through the redoc-cli docs and I couldn't immediately see how we use the siteConfig.yaml approach that they suggest.

Are we ok with this as is for now and we can look to improve the docs in a future PR?
Or if you can see how to use the developer portal approach then happy to update to use it if you can point me in the right direction.

Thanks!

@jasonbarry
Copy link
Contributor

jasonbarry commented Mar 3, 2023

@MarcL yeah you're right, it does seem out of scope for this PR. I think we'd need to start by not shelling out to redoc-cli, and instead just call it from an npm script to read a yml config file. But we can save that for another day!

akahn
akahn previously approved these changes Mar 6, 2023
@MarcL
Copy link
Contributor Author

MarcL commented Mar 6, 2023

Pushed some minimal tweaks to CSS to match the open API docs font.

@MarcL MarcL merged commit d211832 into master Mar 6, 2023
@MarcL MarcL deleted the marcl/add-legal-footer branch March 6, 2023 14:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

type: bug code to address defects in shipped code

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants