diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..89b62d2 --- /dev/null +++ b/Makefile @@ -0,0 +1,18 @@ +all: site/elm.min.js site/styles.css + +site/elm.js: src/ + elm make --optimize --output site/elm.js src/Main.elm + +site/elm.min.js: site/elm.js + uglifyjs site/elm.js --compress 'pure_funcs=[F2,F3,F4,F5,F6,F7,F8,F9,A2,A3,A4,A5,A6,A7,A8,A9],pure_getters,keep_fargs=false,unsafe_comps,unsafe' | uglifyjs --mangle --output site/elm.min.js + +site/styles.css: site/styles.scss + sass --update -t compressed site/styles.scss + +clean: + rm -rf site/elm.js \ + elm-stuff/ \ + site/elm.min.js \ + .sass-cache \ + site/styles.css \ + site/styles.css.map diff --git a/site/assets/fonts/lack/Lack-Regular.woff b/site/assets/fonts/lack/Lack-Regular.woff new file mode 100644 index 0000000..034a5e7 --- /dev/null +++ b/site/assets/fonts/lack/Lack-Regular.woff @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2e58f3c041bfb6828aa2a0267c14e1ee6332ae764d35536b29aaef537867f93f +size 59884 diff --git a/site/assets/fonts/lack/lack.woff2 b/site/assets/fonts/lack/lack.woff2 new file mode 100644 index 0000000..dad407e --- /dev/null +++ b/site/assets/fonts/lack/lack.woff2 @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2f1563423d4ab590dddc088ae9a32e676e7431dc0b8dab24c2e448c5abcbc135 +size 53920 diff --git a/site/assets/fonts/resistance/COPYRIGHT.md b/site/assets/fonts/resistance/COPYRIGHT.md new file mode 100755 index 0000000..7a1c72c --- /dev/null +++ b/site/assets/fonts/resistance/COPYRIGHT.md @@ -0,0 +1,5 @@ +Copyright (c) 2005-2013, Jane Doe +Copyright (c) 2007, Pat Johnson +Copyright (c) 2006, Fred Foobar +Copyright (c) 2005, Tom Parker +Copyright (c) 2005, Joe Smith \ No newline at end of file diff --git a/site/assets/fonts/resistance/LICENSE.txt b/site/assets/fonts/resistance/LICENSE.txt new file mode 100755 index 0000000..fd9b59c --- /dev/null +++ b/site/assets/fonts/resistance/LICENSE.txt @@ -0,0 +1,103 @@ +This Font Software is licensed under the SIL Open Font License, Version 1.1. +This license is copied below, and is also available with a FAQ at: +http://scripts.sil.org/OFL + +SIL Open Font License v1.1 +==================================================== + + +Preamble +---------- + +The goals of the Open Font License (OFL) are to stimulate worldwide +development of collaborative font projects, to support the font creation +efforts of academic and linguistic communities, and to provide a free and +open framework in which fonts may be shared and improved in partnership +with others. + +The OFL allows the licensed fonts to be used, studied, modified and +redistributed freely as long as they are not sold by themselves. The +fonts, including any derivative works, can be bundled, embedded, +redistributed and/or sold with any software provided that any reserved +names are not used by derivative works. The fonts and derivatives, +however, cannot be released under any other type of license. The +requirement for fonts to remain under this license does not apply +to any document created using the fonts or their derivatives. + + +Definitions +------------- + +`"Font Software"` refers to the set of files released by the Copyright +Holder(s) under this license and clearly marked as such. This may +include source files, build scripts and documentation. + +`"Reserved Font Name"` refers to any names specified as such after the +copyright statement(s). + +`"Original Version"` refers to the collection of Font Software components as +distributed by the Copyright Holder(s). + +`"Modified Version"` refers to any derivative made by adding to, deleting, +or substituting -- in part or in whole -- any of the components of the +Original Version, by changing formats or by porting the Font Software to a +new environment. + +`"Author"` refers to any designer, engineer, programmer, technical +writer or other person who contributed to the Font Software. + + +Permission & Conditions +------------------------ + +Permission is hereby granted, free of charge, to any person obtaining +a copy of the Font Software, to use, study, copy, merge, embed, modify, +redistribute, and sell modified and unmodified copies of the Font +Software, subject to the following conditions: + +1. Neither the Font Software nor any of its individual components, + in Original or Modified Versions, may be sold by itself. + +2. Original or Modified Versions of the Font Software may be bundled, + redistributed and/or sold with any software, provided that each copy + contains the above copyright notice and this license. These can be + included either as stand-alone text files, human-readable headers or + in the appropriate machine-readable metadata fields within text or + binary files as long as those fields can be easily viewed by the user. + +3. No Modified Version of the Font Software may use the Reserved Font + Name(s) unless explicit written permission is granted by the corresponding + Copyright Holder. This restriction only applies to the primary font name as + presented to the users. + +4. The name(s) of the Copyright Holder(s) or the Author(s) of the Font + Software shall not be used to promote, endorse or advertise any + Modified Version, except to acknowledge the contribution(s) of the + Copyright Holder(s) and the Author(s) or with their explicit written + permission. + +5. The Font Software, modified or unmodified, in part or in whole, + must be distributed entirely under this license, and must not be + distributed under any other license. The requirement for fonts to + remain under this license does not apply to any document created + using the Font Software. + + +Termination +----------- + +This license becomes null and void if any of the above conditions are +not met. + + + DISCLAIMER + + THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, + EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF + MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT + OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE + COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, + INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL + DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING + FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM + OTHER DEALINGS IN THE FONT SOFTWARE. diff --git a/site/assets/fonts/resistance/resistance.eot b/site/assets/fonts/resistance/resistance.eot new file mode 100755 index 0000000..cfa1e18 --- /dev/null +++ b/site/assets/fonts/resistance/resistance.eot @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e78d5564d5dce4a9f53641f1fc80da08fb5fc247f607e8c6b4ad4b0bd683c40f +size 11803 diff --git a/site/assets/fonts/resistance/resistance.ttf b/site/assets/fonts/resistance/resistance.ttf new file mode 100755 index 0000000..545f500 --- /dev/null +++ b/site/assets/fonts/resistance/resistance.ttf @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4a87c98a3649bb11458d5a4be34e43a10b230171591b4fa2a0e39456d03572f3 +size 25760 diff --git a/site/assets/fonts/resistance/resistance.woff2 b/site/assets/fonts/resistance/resistance.woff2 new file mode 100755 index 0000000..8c9b4dc --- /dev/null +++ b/site/assets/fonts/resistance/resistance.woff2 @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a303a2531edafdf3794b2fc30b168142ba623e3a03d99013d441f34520af73bb +size 10360 diff --git a/site/index.html b/site/index.html new file mode 100644 index 0000000..e182411 --- /dev/null +++ b/site/index.html @@ -0,0 +1,72 @@ + + + + + Main + + + + + +
+

+

For Good,

+

Not Evil

+

+
+ +
+ +

+ The world of today is not the world our free software licenses were written for. + The licenses we created to protect freedom are being taken advantage of by + institutions like ICE and surveilence states to take away the freedom of others. +

+

+ It's time to reclaim our software in the name of freedom. +

+

+ This site helps you find and build licenses that uphold the principles of open + source software, while making sure your code is used for good, not evil. +

+
+ +
+
+ + + diff --git a/site/styles.scss b/site/styles.scss new file mode 100644 index 0000000..f889bb0 --- /dev/null +++ b/site/styles.scss @@ -0,0 +1,97 @@ +body { + --color-bg: #170423; + --color-hi: #ce027c; + background-color: var(--color-bg); + color: white; + + font-family: Lack, sansserif; + font-size: 1.5em; + line-height: 1.4em; + + max-width: 700px; + margin: 0 auto; + margin-bottom: 60px; +} + +header { + font-family: Resistance, sansserif; + font-variant-alternates: styleset(normal-is); + font-size: 3.2rem; + + padding: 0px 49px; + + p { + display: flex; + white-space: nowrap; + line-height: 1em; + margin: 20px 0; + + .hr { + width: 100%; + height: 0.5em; + border-bottom: 1px solid white; + margin: 0 50px; + + &:first-child { + margin-left: 0; + } + &:last-child { + margin-right: 0; + margin-left: 40px; + } + } + } +} + +.emphasis-paragraph { + font-family: Resistance; + font-size: 3.5rem; + line-height: initial; + text-align: center; + + margin-left: -50px; + margin-right: -50px; +} + +#should-hide-intro:checked + #intro { + display: none; +} + +#should-hide-intro:not(:checked) ~ #elm-area { + display: none; +} + +.cool-button { + --bevel: var(--color-hi); + --bevel-size: 20px; + color: var(--color-bg); + width: fit-content; + font-family: Resistance; + font-size: 2.5rem; + margin-left: auto; + margin-right: auto; + cursor: pointer; + + & > div:nth-child(2) { + padding: 5px 30px; + } +} + +.bevel { + border: var(--bevel-size) solid var(--bevel); + &.tl, &.tr { + border-top: 0; + & ~ :not(.bevel) { + background-color: var(--bevel); + } + } + &.bl, &.br { + border-bottom: 0; + } + &.tr, &.br { + border-right-color: transparent; + } + &.tl, &.bl { + border-left-color: transparent; + } +} diff --git a/src/Main.elm b/src/Main.elm index 0cf7645..7f393b6 100644 --- a/src/Main.elm +++ b/src/Main.elm @@ -4,7 +4,7 @@ import Browser import Sort.Set exposing (Set) import Html exposing (Html, div, input, label, p, text, h3) import Html.Events exposing (onCheck) -import Html.Attributes exposing (class, type_) +import Html.Attributes exposing (class, type_, id) import Modules exposing ( Module , all_modules @@ -63,7 +63,7 @@ view_module_button enabled mod = view : Model -> Html Msg view model = - div [] ( + div [id "elm-area"] ( all_modules |> List.map (view_module_button model.enabled_modules) )