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

fine-tune apidocs markup for dark mode #338

Merged
merged 1 commit into from
Sep 21, 2023

Conversation

xrstf
Copy link
Contributor

@xrstf xrstf commented Sep 20, 2023

This is the result of working a bit more on the dark mode for the apidocs. I had to extend the markup a bit, now at least the result is now pretty:

2023-09-21T00-57-07
2023-09-21T00-57-26

I adopted the font that is used on kubernetes.io, plus the colors in light mode were adjusted a bit to better match the Kubernetes website.

The markup is now also setup for an CSS-only automatic dark mode, which avoids the previous flash-of-white before the JS kicked in and applied the theme-dark class.

I also renamed the scroll-apiref.js, since the file is not just responsible for the scrolling behaviour, but also the dark mode toggler. I hope this won't cause issues when the website repo PR is eventually merged.

@k8s-ci-robot k8s-ci-robot added the cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. label Sep 20, 2023
@k8s-ci-robot k8s-ci-robot added the size/M Denotes a PR that changes 30-99 lines, ignoring generated files. label Sep 20, 2023
@tengqm
Copy link
Contributor

tengqm commented Sep 21, 2023

Thanks.
/lgtm
/approve

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Sep 21, 2023
@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: tengqm, xrstf

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@k8s-ci-robot k8s-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Sep 21, 2023
@k8s-ci-robot k8s-ci-robot merged commit f7ae6a1 into kubernetes-sigs:master Sep 21, 2023
2 checks passed
@xrstf xrstf deleted the finetuning branch September 21, 2023 09:23
@xrstf
Copy link
Contributor Author

xrstf commented Sep 21, 2023

@tengqm Thanks a lot for your super quick reviews on all these PRs, it's really appreciated :-) Is there anything else I need to do to complete this? The markup on https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.27/ is still the old one, but the new CSS/JS is already live.

@tengqm
Copy link
Contributor

tengqm commented Sep 21, 2023

@xrstf I've sent a PR refreshing the HTML (kubernetes/website#43139) and it has been merged.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. lgtm "Looks good to me", indicates that a PR is ready to be merged. size/M Denotes a PR that changes 30-99 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants