Skip to content

Commit

Permalink
Initial commit
Browse files Browse the repository at this point in the history
  • Loading branch information
liorgrossman committed Aug 10, 2016
1 parent bcef528 commit 1864300
Show file tree
Hide file tree
Showing 81 changed files with 8,515 additions and 56 deletions.
174 changes: 174 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,174 @@
# =======
# Ignores specific to Darkness
/chrome-production
*.zip

# =======
# Created by https://www.gitignore.io/api/node,sass,linux,macos,windows,jetbrains,git

### Node ###
# Logs
logs
*.log
npm-debug.log*

# Runtime data
pids
*.pid
*.seed
*.pid.lock

# Directory for instrumented libs generated by jscoverage/JSCover
lib-cov

# Coverage directory used by tools like istanbul
coverage

# nyc test coverage
.nyc_output

# Grunt intermediate storage (http://gruntjs.com/creating-plugins#storing-task-files)
.grunt

# node-waf configuration
.lock-wscript

# Compiled binary addons (http://nodejs.org/api/addons.html)
build/Release

# Dependency directories
node_modules
jspm_packages

# Optional npm cache directory
.npm

# Optional REPL history
.node_repl_history


### Sass ###
.sass-cache/
*.css.map


### Linux ###
*~

# temporary files which can be created if a process still has a handle open of a deleted file
.fuse_hidden*

# KDE directory preferences
.directory

# Linux trash folder which might appear on any partition or disk
.Trash-*


### macOS ###
*.DS_Store
.AppleDouble
.LSOverride

# Icon must end with two \r
Icon


# Thumbnails
._*

# Files that might appear in the root of a volume
.DocumentRevisions-V100
.fseventsd
.Spotlight-V100
.TemporaryItems
.Trashes
.VolumeIcon.icns
.com.apple.timemachine.donotpresent

# Directories potentially created on remote AFP share
.AppleDB
.AppleDesktop
Network Trash Folder
Temporary Items
.apdisk


### Windows ###
# Windows image file caches
Thumbs.db
ehthumbs.db

# Folder config file
Desktop.ini

# Recycle Bin used on file shares
$RECYCLE.BIN/

# Windows Installer files
*.cab
*.msi
*.msm
*.msp

# Windows shortcuts
*.lnk


### JetBrains ###
# Covers JetBrains IDEs: IntelliJ, RubyMine, PhpStorm, AppCode, PyCharm, CLion, Android Studio and Webstorm
# Reference: https://intellij-support.jetbrains.com/hc/en-us/articles/206544839

# User-specific stuff:
.idea/workspace.xml
.idea/tasks.xml
.idea/dictionaries
.idea/vcs.xml
.idea/jsLibraryMappings.xml

# Sensitive or high-churn files:
.idea/dataSources.ids
.idea/dataSources.xml
.idea/dataSources.local.xml
.idea/sqlDataSources.xml
.idea/dynamic.xml
.idea/uiDesigner.xml

# Gradle:
.idea/gradle.xml
.idea/libraries

# Mongo Explorer plugin:
.idea/mongoSettings.xml

## File-based project format:
*.iws

## Plugin-specific files:

# IntelliJ
/out/

# mpeltonen/sbt-idea plugin
.idea_modules/

# JIRA plugin
atlassian-ide-plugin.xml

# Crashlytics plugin (for Android Studio and IntelliJ)
com_crashlytics_export_strings.xml
crashlytics.properties
crashlytics-build.properties
fabric.properties

### JetBrains Patch ###
# Comment Reason: https://github.com/joeblau/gitignore.io/issues/186#issuecomment-215987721

# *.iml
# modules.xml
# .idea/misc.xml
# *.ipr


### Git ###
*.orig
2 changes: 2 additions & 0 deletions AUTHORS.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
Authors ordered by first contribution:
Lior <[email protected]>
36 changes: 36 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
# Contriburing to Darkness
Please help us **improve existing skins and create new ones**. Pull requests are welcome!



## How to start developing?
1. First, [install Darkness locally](./README.MD) if you haven't
1. Run `npm start` to **watch SCSS files** and compile them in real time.
1. Write your awesome code - see below


## How do I...
##### Fix or improve an existing skin
Edit `/themes/websites/[WEBSITE].scss` (e.g. `/themes/websites/youtube.scss`)

##### Add skin for an new website (e.g. GitHub, Twitter)
Open `/themes/websites/WEBSITE-TEMPLATE.scss` in your code editor and follow the instructions.

##### Fix or improve a color theme
Edit `/themes/themes/[THEME].scss` (e.g. `/themes/themes/material.scss`)

##### Create a new color theme (in addition to Monokai, Tomorrow, etc.)
Open `/themes/themes/THEME-TEMPLATE.scss` in your code editor and follow the instructions.


## How to push code back to Darkness?
1. Please test your changes locally in Chrome
1. Commit and push:
```bash
git add .
git commit -m 'Description of Changes'
git push origin master
```
1. Go to [GitHub](https://github.com) and navigate to **your fork of Darkness**.
1. Click the **Compare & pull request** button.
1. Write a description and click **Create pull request**.
55 changes: 0 additions & 55 deletions LICENSE
Original file line number Diff line number Diff line change
Expand Up @@ -617,58 +617,3 @@ reviewing courts shall apply local law that most closely approximates
an absolute waiver of all civil liability in connection with the
Program, unless a warranty or assumption of liability accompanies a
copy of the Program in return for a fee.

END OF TERMS AND CONDITIONS

How to Apply These Terms to Your New Programs

If you develop a new program, and you want it to be of the greatest
possible use to the public, the best way to achieve this is to make it
free software which everyone can redistribute and change under these terms.

To do so, attach the following notices to the program. It is safest
to attach them to the start of each source file to most effectively
state the exclusion of warranty; and each file should have at least
the "copyright" line and a pointer to where the full notice is found.

{one line to give the program's name and a brief idea of what it does.}
Copyright (C) {year} {name of author}

This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.

This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.

Also add information on how to contact you by electronic and paper mail.

If the program does terminal interaction, make it output a short
notice like this when it starts in an interactive mode:

{project} Copyright (C) {year} {fullname}
This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
This is free software, and you are welcome to redistribute it
under certain conditions; type `show c' for details.

The hypothetical commands `show w' and `show c' should show the appropriate
parts of the General Public License. Of course, your program's commands
might be different; for a GUI interface, you would use an "about box".

You should also get your employer (if you work as a programmer) or school,
if any, to sign a "copyright disclaimer" for the program, if necessary.
For more information on this, and how to apply and follow the GNU GPL, see
<http://www.gnu.org/licenses/>.

The GNU General Public License does not permit incorporating your program
into proprietary programs. If your program is a subroutine library, you
may consider it more useful to permit linking proprietary applications with
the library. If this is what you want to do, use the GNU Lesser General
Public License instead of this License. But first, please read
<http://www.gnu.org/philosophy/why-not-lgpl.html>.
55 changes: 54 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1 +1,54 @@
# darkness
# Darkness: Dark Themes for Popular Websites

<img src="" align="left" hspace="10" vspace="10">

**Darkness** is a Chrome extension that provides **dark themes** for popular websites such as Google, Facebook, Gmail and YouTube.

Using dark themes reduces the eye strain and fatigue caused by a bright screen, helps you sleep faster and better at night, and generally makes you awesome :)

<img src="" align="center" hspace="10" vspace="10">

## Features
* Supports 4 websites: Google, Facebook, Gmail, YouTube (help us add more)
* Boasts 3 color schemes: Iceberg, Tomorrow, Material (help us add more)
* Written in Javascript and SCSS (basically CSS with variables)
* Self-hosted. Easy to install on Windows, Mac, Linux
* Available commercially on [Chrome Web Store](https://chrome.google.com/webstore/detail/darkness-beautiful-dark-t/imilbobhamcfahccagbncamhpnbkaenm). Read about the difference.

## Installation
##### Installing Darkness Developer Edition:
1. Fork the Darkness repo: https://github.com/liorgrossman/darkness/fork
1. Clone your fork locally: `git clone [email protected]:YourGitHubUsername/darkness.git`
1. `cd darkness`
1. Set up a the original repo as a remote: `git remote add upstream [email protected]:liorgrossman/darkness.git`
1. Get the code: `git fetch upstream`
1. To compile all SCSS files to CSS (required): `npm install`

##### Loading it in Chrome:
1. On Chrome, browse to [chrome://extensions](chrome://extensions)
1. If you have already Darkness installed, disable it
1. Check **Developer mode** in the top of the Extensions page
1. Click **Load unpacked extension...**
1. Choose the directory **darkness-chrome** (same dir as manifest.json)

##### To keep Darkness up-to-date, please pull occasionally:
```bash
git checkout master
git pull upstream master
```

## Contributing Code
Pull requests are welcome!
Please see our [contribution guide](./CONTRIBUTING.MD) to us improve existing skins and create new ones.


## Got more questions?
* Join the [Darkness Developers Community on Facebook](https://www.facebook.com/groups/darkness-developers)
* Contact us at: [email protected]


## License

GPLv3


8 changes: 8 additions & 0 deletions chrome-extension/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
themes-css/
style-css/

themes/*.css
themes/*.css.map

style/*.css
style/*.css.map
Binary file added chrome-extension/fonts/OpenSans-Light.woff2
Binary file not shown.
Binary file added chrome-extension/fonts/OpenSans-Semibold.woff2
Binary file not shown.
Binary file added chrome-extension/fonts/OpenSans.woff2
Binary file not shown.
22 changes: 22 additions & 0 deletions chrome-extension/html/options.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
<!-- Options screen - shown: (1) when clicking the extension icon in Chrome's toolbar; (2) on chrome://extensions/ when clicking "Options" -->
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Darkness</title>
<link href='https://fonts.googleapis.com/css?family=Open+Sans:400,600,700,300' rel='stylesheet' type='text/css'>
</head>
<style>
body { width: 400px; background: #000; color: #ccc; font-size: 14px; padding: 7px 10px; line-height: 1.7em; font-family: 'Open Sans'; font-weight: 300; }

b { font-weight: 300; color: #fff; }

h3 { font-size: 17px; font-weight: 400; color: #fff; padding: 0 0 10px; margin: 0; }
</style>
<body>
<h3>To configure Darkness:</h3>
1. Visit a supported website like <b>Facebook</b> or <b>Google</b>.<BR>
2. Click the <b>moon icon</b> in the <b>top-right corner</b> of the website.<BR><BR>
<img src="../images/explain-icon-location.png"/>
</body>
</html>
7 changes: 7 additions & 0 deletions chrome-extension/html/page.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
<!-- This HTML is injected to supported websites only, upon page load -->

<!-- Moon icon on a website's toolbar -->
<div class="drk_settings_icon" id="drk_settings_icon"></div>

<!-- Global message to user (e.g. in case of a conflict with another extension) -->
<div class="drk_settings_global_msg"><div class="drk_settings_global_msg_close">Close</div><div class="drk_settings_global_msg_text"></div></div>
Loading

0 comments on commit 1864300

Please sign in to comment.