Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update API screenshot on homepage. #834

Merged
merged 1 commit into from
Dec 27, 2023

Conversation

abhcs
Copy link
Collaborator

@abhcs abhcs commented Nov 3, 2023

Fix #215 by updating the API screenshot image file rendered on the homepage.

🤖 Generated by Copilot at 206ca95

Summary

Walkthrough

@anth-volk anth-volk requested review from anth-volk and removed request for nikhilwoodruff December 14, 2023 01:34
Copy link
Collaborator

@anth-volk anth-volk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for your contribution! Unfortunately, I fear this does the opposite of what #215 is looking for - what we're hoping to do is change the font of the code output screen on that page so that it uses a monospace font like Courier instead of the Arial or Helvetica it's currently using. The image on the homepage is actually correct; the item with the font issue has moved from the pre-redesign homepage to a new API page, which may be part of the confusion.

Would you be willing to look into why the API renders this code with the Arial and change it to monospace?

@abhcs
Copy link
Collaborator Author

abhcs commented Dec 14, 2023

Initial investigation suggests that the code responsible for the font is in the policyengine-api-demo repository:

https://github.com/PolicyEngine/policyengine-api-demo/blob/353be7075283c58e2a61e0d6d2d1b6e70a4b8e28/app.py#L30

If streamlit is reading that repository, then changing the font there should fix the problem.

@abhcs
Copy link
Collaborator Author

abhcs commented Dec 15, 2023

The issue is fixed here. In this PR, I have reverted previous commits and added a comment to help others find the policyengine-api-demo repository.

@abhcs abhcs requested a review from anth-volk December 15, 2023 00:24
@anth-volk
Copy link
Collaborator

Thanks so much. I don't have write access over there, so I linked Nikhil, hopefully he can address at a later point, or if I can be added, I'll check it out a bit later.

@anth-volk
Copy link
Collaborator

I actually do have write access now. As I mentioned over there in the PR, would you mind uploading an image of the sample API code block with the formatting changes?

@anth-volk
Copy link
Collaborator

Thanks for this, @abhcs. I approved the fix over at policyengine-api-demo, and I'll approve this, as it's nice to have the added comment.

@anth-volk anth-volk merged commit c0f017b into PolicyEngine:master Dec 27, 2023
2 checks passed
@abhcs abhcs deleted the fix-issue-215 branch December 27, 2023 20:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

Use fixed width font for code demo on homepage
2 participants