Comments (9)
Indeed, seems like it's an undocumented feature of the parser in Stylus, implemented here from what I can tell: https://github.com/openstyles/stylus/blob/v1.5.22/js/usercss-compiler.js#L66-L95
Tracing it back, it looks like it's been part of the UserCSS implementation from the beginning, added in openstyles/stylus#134 (js/usercss.js
, lines 62-89). Just one of those somewhat quirky features that never got documented and has been flying under the radar ever since :)
from github-dark.
I actually did some digging and found it to be an old USo feature! Will definitely add support for this in the next Cascadea update.
Oh, the fun of implementing your own UserCSS parser/compiler from scratch. :)
from github-dark.
I've actually had this implemented for a week now and was going to wait until I had a few more fixes or changes in place to bother shipping it, but given that might be a while, I've gone ahead and pushed Cascadea 2.1.3 to the App Store which should support this:
It's still waiting for Apple approval (edit: approved!), but once it's out, you should just need to have Cascadea recompile GitHub Dark (which will happen automatically when updating, or if you open the Style Properties window and click "Save") for it to properly apply these variables.
from github-dark.
Have you tested chrome/firefox + stylus? Are you using the latest version of this style?
from github-dark.
@the-j0k3r Yep, it works fine in Chrome and Firefox using Stylus. Everything is fully updated; browsers, Stylus, Cascadea, and the GitHub Dark userstyle CSS.
Hence I suspect maybe it's Cascadea that lacks support for the -rgb
thing on color options?
from github-dark.
The dev is around and pingable. @mikefreuden
This one is all yours, thx ;)
@jimeh no worries thanks for actually testing. ;)
from github-dark.
Oh hello!
I'd be happy to fix this on Cascadea's end, but I'm not quite sure I understand what GitHub Dark is doing here. There's indeed no base-color-rgb
variable defined in the UserCSS header. I'm assuming Stylus added support for some way to specify the format of a color variable by appending the format to it or something along those lines that I missed out on and isn't documented in the Writing UserCSS article? 😅
from github-dark.
For now I have made a quick hack userstyle to work around the issue. It simply overrides the specific CCS variables affected. I use the default Base Color in GitHub Dark (#4f8cc9
), which is 79, 140, 201
in RGB values.
@-moz-document domain("githubusercontent.com"), domain("githubstatus.com"), domain("github.com")
{
:root:root:root {
--color-accent-muted: rgba(79, 140, 201, .3);
--color-auto-blue-2: rgba(79, 140, 201, .25);
--color-auto-blue-3: rgba(79, 140, 201, .5);
--color-calendar-graph-day-L1-bg: rgba(79, 140, 201, .25);
--color-calendar-graph-day-L2-bg: rgba(79, 140, 201, .5);
--color-calendar-graph-day-L3-bg: rgba(79, 140, 201, .75);
--color-primer-shadow-focus: 0 0 0 2.25px rgba(79, 140, 201, .3);
--color-state-focus-shadow: 0 0 0 2.25px rgba(79, 140, 201, .3);
}
}
from github-dark.
@mikefreuden thanks, I just updated to Cascadea 2.1.3 and things all work as expected now :D
from github-dark.
Related Issues (20)
- Revert link accent styling in file table
- Codepages page a little TOO dark
- Gitako support doesn't work
- Network Graph not showing properly HOT 4
- YML text diffs are unreadable
- Colored border on the "Following" or "For you" button HOT 1
- All focused anchor elements all have a solid outline
- Please include this dark github theme for the new Projects Beta HOT 5
- %-encoded character in URLs do not match regexp HOT 1
- Unable to download
- Nord Theme
- GitHub Custom Fonts do not working in New Code Search and Code View (Beta)
- Contribution graph not using base color
- So many buttons in GitHub Discussions are wrongly darkened
- [Custom Fonts (5.2.37)] New Editor - background/read-only content used for cursor/text selection not using custom font settings HOT 1
- Markdown images get inverted if filename contains the string "404"
- Transparent Background on Navbar Redesign is Opaque
- GH Custom Fonts: PRs and issues with `code` in titles have small font size relative to rest of the title HOT 4
- Updating is broken - stuck at version 5.3.143 HOT 3
- Custom Fonts (5.4.7) - Family & Size settings do not affect hidden view used for text cursor/selection HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from github-dark.