question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Add option to only apply a margin when Gitako is open to the header

See original GitHub issue

Instead of applying the left margin to the entire page when Gitako is open, I’d rather it was applied only to the header. Moving the with-gitako-spacing class down to the .js-header-wrapper class solves this rather simply.

This should be a toggle-able option that is disabled by default. This feature would mainly be intended for larger monitors that have enough screen real estate that opening a panel on the side doesn’t impact anything.

The following styles can also achieve the same effect:

.with-gitako-spacing {
    margin-left: 0;
}

.with-gitako-spcaing .js-header-wrapper {
    margin-left: var(--gitako-width);
}

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:5 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
SpedNSFWcommented, Dec 13, 2020

I think the issue comes down to screen sizes. For larger sizes, moving the entire page content over is very annoying. It’s unnecessary and moves the content so it’s no longer center.

I have included an image below of what it looks like for me. Note I am using a dark stylesheet that does not change the page layout in anyway.

image

At 1080p with a width of 300px, the gitako panel fits in perfectly. For even larger displays like my 1440p monitor, it just makes sense.

So perhaps changing the stylesheet to something like this would work:

@media (min-width: 1920px) {
    .with-gitako-spacing {
        margin-left: 0;
    }
    .with-gitako-spacing .js-header-wrapper {
        margin-left: var(--gitako-width);
    }
}
0reactions
EnixCodacommented, Feb 28, 2022

@mukkachaitanya In the very early versions of Gitako, this feature was supported. But removed due to maintenance cost.

Read more comments on GitHub >

github_iconTop Results From Across the Web

additional top/bottom margin when using headers, footers #2514
I have tried many option. I used the following option at last. $wkhtmltopdf --page-size A4 \ --header-left "DocName" \ --header- ...
Read more >
cm-header-* margin/padding/height - CodeMirror
For # My Title as Header 1 I would lie to apply a margin-bottom property ... You could add padding, though the cursor...
Read more >
Google Docs - How to add Margins in Header and Footer
This video shows the option to set margin for header and footer. It also shows on how to insert header and footer in...
Read more >
sindresorhus/refined-github (Raised $2,687.94) - Issuehunt
Add option to only render boundary whitespace. Unfunded#2266created byleggsimon ... File header takes less width than available in diff section.
Read more >
pdfmake - remove header margin from pages > 1
I'm using this code for header in my generated pdf, but even though the header is removed for pages after the first page,...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found