Skip to content
This repository has been archived by the owner on Sep 6, 2021. It is now read-only.

Adding feature for adding own CSS to brackets GUI (#10548) #10642

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

FabianCernota
Copy link

You can now adding own CSS declaration without using a extension.

Put an custom.css on the same level like config.json or index.html and activate it over View -> Themes

Reload the UI with F5

@peterflynn
Copy link
Member

I'm not sure we need a checkbox in the UI -- why not just load the file any time it exists? The keymap.json file works that way and it seems fine.

To match how preferences and keybinding overrides work though, I wonder if we should listen for user changes to this file and update the Brackets UI immediately, without requiring a reload. It's not hard -- e.g. here's how KeyBindingManager does it -- and re-replacing the original style tag should be easy too. The only question is whether messing with CSS is so error-prone that it shouldn't go into effect without an explicit reload gesture...

@FabianCernota
Copy link
Author

Okey i will change it so that the CSS File will load if exists.

@redmunds
Copy link
Contributor

@FabianCernota Not sure if you saw my comment in IRC, but I think ExtensionUtils methods addLinkedStyleSheet() and addEmbeddedStyleSheet() will need to be fixed to detect "custom.css" and insert any new stylesheets before that stylesheet. Otherwise, "custom.css" will not override all extensions and themes.

@sprintr
Copy link
Contributor

sprintr commented Feb 21, 2015

I think it will be nice to put custom.css in extensions directory, (where we already have disabled and user directories) so it can be accessible from Brackets UI.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants