-
Notifications
You must be signed in to change notification settings - Fork 117
Fix mobile overflow and soft-wrapping issues on documentation pages #424
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
Open
vaidikchitwar
wants to merge
4
commits into
neovim:master
Choose a base branch
from
vaidikchitwar:master
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
4 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -7,7 +7,8 @@ | |
| /* Hue is between neovim green and blue for text/background */ | ||
| /* Saturation is low */ | ||
| --fg-color: #29332f; | ||
| --inverse-fg-color: #a9d5c4; /* Dark-mode fg color. */ | ||
| --inverse-fg-color: #a9d5c4; | ||
| /* Dark-mode fg color. */ | ||
| --bg-color: #e7eee8; | ||
| --accent-bg-color: #d3e4db; | ||
| --link-color: #195174; | ||
|
|
@@ -18,7 +19,8 @@ | |
| @media (prefers-color-scheme: dark) { | ||
| :root { | ||
| --fg-color: #a9d5c4; | ||
| --inverse-fg-color: #29332f; /* Light-mode fg color. */ | ||
| --inverse-fg-color: #29332f; | ||
| /* Light-mode fg color. */ | ||
| --bg-color: #0f191f; | ||
| --accent-bg-color: #0b151b; | ||
| --link-color: #5fb950; | ||
|
|
@@ -65,7 +67,7 @@ a { | |
| transition: all ease-in-out 140ms; | ||
| } | ||
|
|
||
| /* Ensure that the hover border is sized correctly for <a><img…></a>. #295 */ | ||
| /* Ensure that the hover border is sized correctly for <a><img…></a>. #295 */ | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. ? |
||
| a:has(> img) { | ||
| display: block; | ||
| } | ||
|
|
@@ -139,20 +141,24 @@ pre { | |
|
|
||
| /* Keyboard input should be distinctive from <pre> and <code>. */ | ||
| kbd { | ||
| box-shadow: 0 2px 4px rgba(0,0,0,0.2), inset 0px 0px 0px 2px #ffffff; | ||
| box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2), inset 0px 0px 0px 2px #ffffff; | ||
| color: var(--accent-color); | ||
| background-color: #ebebeb; /* var(--accent-bg-color); */ | ||
| border: 1pt solid var(--border-color); /* #555 */ | ||
| border-radius: 3px; /* rounded corners */ | ||
| background-color: #ebebeb; | ||
| /* var(--accent-bg-color); */ | ||
| border: 1pt solid var(--border-color); | ||
| /* #555 */ | ||
| border-radius: 3px; | ||
| /* rounded corners */ | ||
| padding: 2px 5px; | ||
| } | ||
|
|
||
| @media (prefers-color-scheme: dark) { | ||
| kbd { | ||
| box-shadow: 2px 2px 4px var(--border-color), inset 0px 0px 0px 2px rgba(255,255,255,0.2); | ||
| box-shadow: 2px 2px 4px var(--border-color), inset 0px 0px 0px 2px rgba(255, 255, 255, 0.2); | ||
| color: var(--fg-color); | ||
| background-color: var(--accent-bg-color); | ||
| border: 1pt solid var(--fg-color); /* #555 */ | ||
| border: 1pt solid var(--fg-color); | ||
| /* #555 */ | ||
| } | ||
| } | ||
|
|
||
|
|
@@ -175,6 +181,11 @@ samp { | |
| .container { | ||
| width: 100%; | ||
| max-width: 1200px; | ||
| padding-left: 1rem; | ||
| padding-right: 1rem; | ||
| padding-left: max(1rem, env(safe-area-inset-left)); | ||
| padding-right: max(1rem, env(safe-area-inset-right)); | ||
| overflow-wrap: break-word; | ||
| } | ||
|
|
||
| .container:before { | ||
|
|
@@ -188,6 +199,7 @@ samp { | |
| grid-template-columns: initial; | ||
| } | ||
| } | ||
|
|
||
| .flex { | ||
| display: flex; | ||
| gap: 1em; | ||
|
|
@@ -212,11 +224,23 @@ samp { | |
| grid-gap: 1em; | ||
| } | ||
|
|
||
| .golden-grid > * { | ||
| min-width: 0; | ||
| max-width: 100%; | ||
| } | ||
|
|
||
| img, | ||
| iframe, | ||
| video { | ||
| max-width: 100%; | ||
| } | ||
|
|
||
| @media (max-width: 525px) { | ||
| .golden-grid { | ||
| grid-template-columns: 1fr; | ||
| } | ||
| } | ||
|
|
||
| /* | ||
| * Navbar | ||
| * | ||
|
|
@@ -226,6 +250,7 @@ samp { | |
| .nav-link { | ||
| color: var(--link-color); | ||
| } | ||
|
|
||
| .nav-link:hover, | ||
| .nav-link:focus, | ||
| .nav-link:active { | ||
|
|
@@ -243,6 +268,7 @@ samp { | |
| .navbar-brand { | ||
| color: var(--link-color); | ||
| } | ||
|
|
||
| .navbar-brand:hover, | ||
| .navbar-brand:focus, | ||
| .navbar-brand:active { | ||
|
|
@@ -264,6 +290,7 @@ samp { | |
| .dropdown-item { | ||
| color: var(--link-color); | ||
| } | ||
|
|
||
| .dropdown-item:focus, | ||
| .dropdown-item:hover, | ||
| .dropdown-item:active { | ||
|
|
@@ -321,7 +348,8 @@ samp { | |
| position: relative; | ||
| overflow: hidden; | ||
| width: 100%; | ||
| padding-top: 56.25%; /* 16:9 Aspect Ratio (divide 9 by 16 = 0.5625) */ | ||
| padding-top: 56.25%; | ||
| /* 16:9 Aspect Ratio (divide 9 by 16 = 0.5625) */ | ||
|
Comment on lines
+351
to
+352
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. what is the point of this change |
||
|
|
||
| /* width: 560px; */ | ||
| /* height: 315px; */ | ||
|
|
@@ -496,9 +524,9 @@ iframe.poll { | |
| * News section | ||
| */ | ||
|
|
||
| .news-section table { | ||
| margin-top: 1rem; | ||
| } | ||
| .news-section table { | ||
| margin-top: 1rem; | ||
| } | ||
|
|
||
| /* | ||
| * DocSearch overrides | ||
|
|
@@ -587,12 +615,12 @@ iframe.poll { | |
| } | ||
|
|
||
| .DocSearch-Button { | ||
| border: 1px solid var(--docsearch-primary-color) | ||
| border: 1px solid var(--docsearch-primary-color) | ||
| } | ||
|
|
||
| @media (prefers-color-scheme: dark) { | ||
| .DocSearch footer { | ||
| border-top: 1px solid var(--link-color) | ||
| border-top: 1px solid var(--link-color) | ||
| } | ||
|
|
||
| .DocSearch-Button-Keys { | ||
|
|
@@ -603,27 +631,31 @@ iframe.poll { | |
| } | ||
|
|
||
| .DocSearch-Button { | ||
| border: 1px solid var(--docsearch-primary-color) | ||
| border: 1px solid var(--docsearch-primary-color) | ||
| } | ||
| } | ||
|
|
||
| /* Force footer to bottom of viewport. */ | ||
| html { | ||
| height: 100%; | ||
| } | ||
|
|
||
| body { | ||
| min-height: 100vh; | ||
| display: flex; | ||
| flex-direction: column; | ||
| margin: 0; | ||
| } | ||
|
|
||
| body > nav { | ||
| flex-shrink: 0; | ||
| } | ||
|
|
||
| body > main { | ||
| flex: 1 0 auto; | ||
| } | ||
|
|
||
| body > footer { | ||
| flex-shrink: 0; | ||
| margin-top: auto; | ||
| } | ||
| } | ||
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
revert. same for other cases