Compare commits

...

197 commits

Author SHA1 Message Date
Rhyne Vlaservich 7d51891e0c Update README status and about 2023-05-29 15:01:06 -04:00
Rhyne Vlaservich 155c66602a v1.9.2 2023-05-29 14:44:09 -04:00
Rhyne Vlaservich fb40ce705c Merge branch 'donmccurdy-hotfix/popover-visibility' 2023-05-29 14:41:36 -04:00
Rhyne Vlaservich 92da12bd3a v1.9.1 2023-05-29 14:41:25 -04:00
Don McCurdy d2bba9c930 Match transition lengths 2023-03-15 10:28:57 -04:00
Don McCurdy 6961c740e0 Remove transition macro. 2023-03-15 10:27:47 -04:00
Don McCurdy 11955f5c93
Apply suggestions from code review
Use 235ms transition duration, ease-in-out, and omit default value.

Co-authored-by: Olivier <olivierc8@hotmail.com>
2023-03-15 09:48:37 -04:00
Don McCurdy 6cd04adbc7 fix: Set visibility of popovers, so they do not appear when hovering over the hidden pseudoelement 2023-03-14 09:38:39 -07:00
Rhyne Vlaservich 6a682d685e v1.9.1 2022-12-26 15:02:44 -05:00
Rhyne Vlaservich 05094e2fd9 Fix dark mode alerts, buttons, and popovers 2022-12-26 15:00:49 -05:00
Rhyne Vlaservich 98566735bb v1.9.0 2022-11-24 12:22:40 -05:00
Rhyne Vlaservich 9b617f6283 Fix _navbar regression 2022-11-24 12:19:37 -05:00
Rhyne Vlaservich b9a3f08f65 Tweak colors 2022-11-24 12:13:03 -05:00
Mehdi El Fadil df96751517 ensure that collapsible style does not affect inputs and labels inside collapsible-body 2022-11-24 12:13:03 -05:00
Mehdi El Fadil 7e02a85c28 Show modal over navbar. Fix #268 2022-11-24 12:13:03 -05:00
Miguel Ibars 574566bcbe fix: Sass color unit deprecation warning 2022-11-24 12:13:03 -05:00
Famaxis ed69a1ceac Colors change for dark theme 2022-11-24 12:13:03 -05:00
Famaxis 57470dab5a Colors change for light theme, v2 2022-11-24 12:13:03 -05:00
Rhyne c4796bb2b3
Merge pull request #244 from Guergeiro/hotfix/navbar-icon
fix: Re-added height to navbar icon bars
2022-11-24 12:12:47 -05:00
Breno Salles bef7a17128 fix: Re-added height to navbar icon bars 2022-03-13 11:22:10 +00:00
Rhyne e9d058b1b4
Merge pull request #266 from marvelefe/master
Enable "font-display: swap " to avoid showing invisible text
2022-01-22 08:38:29 -05:00
Efe Omoregie 4535fa6922 Enable "font-display: swap" 2022-01-22 09:46:53 +01:00
Rhyne Vlaservich abe378d3ba v1.8.3 2021-12-25 14:43:41 -05:00
Rhyne Vlaservich b00e953314 v1.8.3 2021-12-25 14:36:47 -05:00
Rhyne Vlaservich a221d153f4 Add docs for distributing 2021-12-25 14:36:16 -05:00
Rhyne Vlaservich 7b45106cf6 Merge branch 'develop' 2021-12-25 12:41:56 -05:00
Rhyne Vlaservich 06c8d14d9e Merge branch 'mef-fix-li-font' 2021-12-25 12:39:29 -05:00
Mehdi El Fadil 79ee7efc93 fix: define font for list-item tags 2021-12-18 14:37:40 +00:00
Rhyne f9dc978667
Merge pull request #238 from toshihidetagami/feature-issue-234
add class for disabling shadows
2021-01-17 15:23:06 -05:00
Toshihide Tagami 7b55549c6c add class for disabling shadows 2021-01-16 13:26:51 +08:00
Rhyne Vlaservich aab255504a v1.8.2 2020-11-26 13:22:57 -05:00
Rhyne Vlaservich 9b3e0bd42a Fix Page.Hugo deprecation warning 2020-11-26 13:19:56 -05:00
Rhyne Vlaservich 3f6dcf5bd0 Upgrade the stylelint-config-sass-guidelines package
Done to fix two stylelint deprecation warnings:
- 'at-rule-blacklist'
- 'declaration-property-value-blacklist'
2020-11-26 13:15:42 -05:00
Rhyne Vlaservich 285a97a737 Fix alert color variables 2020-11-26 13:09:37 -05:00
Rhyne ba94bb0932
Merge pull request #232 from ChocolateLoverRaj/feature-custom-font-src
Change or disable font src
2020-11-26 12:57:54 -05:00
Rhyne c9d700831f
Merge pull request #231 from ChocolateLoverRaj/npm-audit-fix
Update vulnerable npm packages
2020-11-26 12:56:32 -05:00
Rhyne 122dc749b5
Merge pull request #230 from ChocolateLoverRaj/hotfix-update-docs
Updated docs
2020-11-26 12:36:54 -05:00
ChocolateLoverRaj 465387694f Change or disable font src 2020-11-17 09:52:52 -06:00
ChocolateLoverRaj 07ded259b9 Updated stylelint dependencies 2020-11-16 18:28:49 -06:00
ChocolateLoverRaj 8027b03f70 Updated docs 2020-11-16 17:16:29 -06:00
Rhyne Vlaservich af918f0313 v1.8.1 2020-10-07 08:58:30 -04:00
Rhyne Vlaservich 60c7dc93df Include src in NPM package 2020-10-07 08:55:55 -04:00
Rhyne 3b406c55b6
Merge pull request #226 from papercss/build/hot-reload
Add SCSS hot-reloading compilation for Hugo docs
2020-09-27 20:31:10 -04:00
Thomas Cazade 53ac2a6b6f Add constants for build-scripts 2020-09-14 08:12:09 +02:00
Thomas Cazade 270c302e51 Add hot-reload script, refactor log function into module 2020-09-14 08:02:44 +02:00
Thomas Cazade aaf5c494a5 Add chokidar and concurrently dev-deps 2020-09-14 08:02:00 +02:00
Rhyne Vlaservich ef6eb705bd Remove hugo environment in favor of node bin 2020-09-13 14:15:59 -04:00
Rhyne Vlaservich 359632d497 Fix hugo build 2020-09-13 14:13:51 -04:00
Rhyne Vlaservich 759e5a1584 Merge branch 'develop' for version 1.8.0 2020-09-13 14:03:24 -04:00
Rhyne Vlaservich 5064fa0224 v1.8.0 2020-09-13 13:53:26 -04:00
Rhyne Vlaservich 18d9cd7522 Add dark mode docs and prepare for release 2020-09-13 13:48:31 -04:00
Rhyne Vlaservich 705a1a2664 Fix markdown rendering with new Hugo version 2020-09-13 12:00:27 -04:00
Rhyne 5c470e9fd2
Merge pull request #219 from papercss/build/remove-gulp
Migrate build-tools from gulp to native NodeJS (SASS-compiler, PostCSS)
2020-09-13 11:53:50 -04:00
Rhyne 11ea531271
Merge pull request #199 from seifsay3d/feature-dark-mode
Add dark mode support 🌗
2020-09-13 11:39:37 -04:00
Thomas Cazade 310797c92a Write paper.css to docs assets, use logger function 2020-09-07 09:32:59 +02:00
Thomas Cazade 40b4508032 Re-add hugo-bin as a dev-dependency 2020-09-07 09:32:18 +02:00
Seifeldin Mahjoub 6f166e544c feat: change links color to secondary 2020-09-07 02:27:55 +02:00
Seifeldin Mahjoub 493d673f5d fix: code for dark-theme 2020-09-07 02:26:43 +02:00
Seifeldin Mahjoub ac67209535 fix: border styles 2020-09-07 02:11:51 +02:00
Seifeldin Mahjoub a810ac7551 fix: form focus styles 2020-09-07 00:19:52 +02:00
Seifeldin Mahjoub 496409f2b8 fix: code styling 2020-09-07 00:19:31 +02:00
Seifeldin Mahjoub 2c2edbadfa fix: cards border color 2020-09-06 20:28:16 +02:00
Seifeldin Mahjoub e60492710e fix: update alerts and badges text 2020-09-06 20:22:55 +02:00
Seifeldin Mahjoub 1198a321b0 chore: remove comments 2020-09-04 14:24:40 +02:00
Seifeldin Mahjoub 22ce468ea4 feat: add more color vars 2020-08-26 00:47:09 +02:00
Seifeldin Mahjoub 36afea4c08 chore: use color mixin in cards 2020-08-26 00:46:44 +02:00
Seifeldin Mahjoub a7c72c9992 fix: linting issues 2020-08-26 00:46:29 +02:00
Seifeldin Mahjoub 24981e9553 chore: use color mixin in forms 2020-08-26 00:46:01 +02:00
Seifeldin Mahjoub 63c7e1d795 chore: use color mixin in modals 2020-08-26 00:45:40 +02:00
Seifeldin Mahjoub 71194873cc chore: use color mixin in progress 2020-08-26 00:45:10 +02:00
Seifeldin Mahjoub a2fad6ecf9 chore: use color mixin in navbar 2020-08-26 00:44:43 +02:00
Seifeldin Mahjoub 63bba4d3ff chore: use color mixin in buttons 2020-08-26 00:40:03 +02:00
Seifeldin Mahjoub 4a27b7c0fa chore : use color mixin in popover 2020-08-26 00:39:08 +02:00
Seifeldin Mahjoub b9af460828 fix: (docs) borders to use same markup 2020-08-26 00:37:26 +02:00
Seifeldin Mahjoub 5fb606250b chore: use color mixin in borders 2020-08-26 00:36:52 +02:00
Seifeldin Mahjoub de8cbd3ca7 chore: fix typo 2020-08-26 00:36:06 +02:00
Seifeldin Mahjoub 97cc2f3c31 chore: use color mixin in badges 2020-08-26 00:35:42 +02:00
Seifeldin Mahjoub 415dca3d75 chore: use color mixin in alerts 2020-08-26 00:35:20 +02:00
Thomas Cazade b5fb97a77d Remove dependencies used for quixote testing 2020-08-25 07:45:09 +02:00
Thomas Cazade 2e045dad4a Update .npmignore to ignore all build-tools and source-code files 2020-08-25 07:42:09 +02:00
Thomas Cazade c505950f57 Remove quixote and minimal tests as they are not relevant anymore
Travis is also disconnected from the repo and we have Netlify previews
2020-08-25 07:41:47 +02:00
Thomas Cazade fe62b6fd41 Build for v1.7.0 2020-08-25 07:32:24 +02:00
Thomas Cazade 8d27b3838a Remove /dist from .gitignore 2020-08-25 07:32:13 +02:00
Thomas Cazade 55b8ab41e1 Migrate build-tools from gulp to native compilation 2020-08-25 07:32:00 +02:00
Rhyne Vlaservich 7f3bbfe5b1 Update contributing and readme for node-gyp requirements 2020-08-23 15:50:32 -04:00
Rhyne 6541844c71
Merge pull request #213 from Benbb96/feature-style-input-range
Feature: Paper style for range sliders
2020-08-23 15:38:46 -04:00
Rhyne 73837465e1
Merge pull request #217 from ChocolateLoverRaj/feature-update-clean-css
Hotfix: update clean css
2020-08-23 15:18:23 -04:00
ChocolateLoverRaj 1a0f29791f Merge remote-tracking branch 'origin/master' into hotfix-update-clean-css 2020-08-17 08:29:28 -05:00
ChocolateLoverRaj 454c36a405 At least 3.9.3 2020-08-17 08:27:42 -05:00
bbe 71835734fd Remove range input border 2020-08-17 12:28:11 +02:00
Rhyne 81c159527a
Merge pull request #212 from Benbb96/hotfix-minor-html-errors-in-forms
Correct minor errors in forms.md
2020-08-16 10:49:55 -04:00
bbe 46a3ff1103 Correct minor errors in forms.md 2020-08-11 11:37:37 +02:00
bbe b4be7ae2d2 Add examples in documentation forms.md 2020-08-11 11:32:11 +02:00
bbe f5c102ea11 Add paper style for input[type=range]
(cherry picked from commit 28d49a3d0e)
2020-08-11 11:13:43 +02:00
Seifeldin Mahjoub 688f27d959 chore: use color mixin in tabs 2020-08-10 01:21:36 +02:00
Seifeldin Mahjoub ebd2598c9a chore: remove commented code 2020-08-10 01:17:10 +02:00
Seifeldin Mahjoub 5c8a72b734 fix: auto generate css varaibales from theme-map 2020-08-10 01:16:26 +02:00
Seifeldin Mahjoub 9247411659 chore: use color mixin in images 2020-08-10 01:12:48 +02:00
Seifeldin Mahjoub c07130703e chore: use color mixin in accordion 2020-08-10 01:12:00 +02:00
Seifeldin Mahjoub a5a030fe42 chore: dry css vars declartion 2020-08-09 00:44:02 +02:00
Seifeldin Mahjoub 36056e4737 Merge branch 'develop' into feature-dark-mode 2020-08-09 00:23:47 +02:00
Seifeldin Mahjoub f78930dfe0 Merge remote-tracking branch 'upstream/develop' into develop 2020-08-09 00:22:32 +02:00
Rhyne Vlaservich 58ca84a82b Add version 1.7.0 2020-08-01 16:14:30 -04:00
Rhyne Vlaservich 4f7f6e8402 Fix linting in tabs 2020-08-01 16:13:50 -04:00
Rhyne Vlaservich 97599bbee0 Add container docs 2020-08-01 15:59:19 -04:00
Marcus Pereira 08b297da60 update containers size 2020-08-01 15:59:19 -04:00
Marcus Pereira 7d3b1e04fd feat: create size to .container class 2020-08-01 15:59:19 -04:00
Phreshhh 231d2ab6d9 Feature Breadcrumb 2020-08-01 15:59:19 -04:00
Phreshhh e1cee11c38 Feature Breadcrumb 2020-08-01 15:59:19 -04:00
Phreshhh 2f4f9c2465 button fix for backward compatibility 2020-08-01 15:59:19 -04:00
Phreshhh ae79596cd0 burger borderfix 2020-08-01 15:59:19 -04:00
Phreshhh bda6b79f1f margin-top removed 2020-08-01 15:59:19 -04:00
Phreshhh c219346051 margin-top stylelint fix 2020-08-01 15:59:19 -04:00
Phreshhh 4c4c97af44 Navbar fix for FireFox 2020-08-01 15:59:19 -04:00
Phreshhh 74f38c54ee bg and shadow color changed to variable colors 2020-08-01 15:59:19 -04:00
Phreshhh 4f8f7a9297 Switch components - stylelint fix 8 :) - realy last XD 2020-08-01 15:59:19 -04:00
Phreshhh bfdc62055e Switch components - stylelint fix 7 :) - last 2020-08-01 15:59:19 -04:00
Phreshhh 866e8b3abd Switch components - stylelint fix 6 :) 2020-08-01 15:59:19 -04:00
Phreshhh 84d81adae5 Switch components - stylelint fix 5 :) I installed stylelint to my editor.. next time will less commits. 2020-08-01 15:59:19 -04:00
Phreshhh 0e198c9fcc Switch components - stylelint fix 4 :) OMG alphabetical.. - Why?! lol 2020-08-01 15:59:19 -04:00
Phreshhh 262db03fe0 Switch components - stylelint fix 3 :) 2020-08-01 15:59:19 -04:00
Phreshhh 06ce202265 Switch components - stylelint fix 2 :) 2020-08-01 15:59:19 -04:00
Phreshhh ea2635161d Switch components - stylelint fix 1 :) 2020-08-01 15:59:19 -04:00
Phreshhh cf2deae2ea Switch components 2020-08-01 15:59:19 -04:00
Phreshhh 53ffaa02f7 outline colormap removed 2020-08-01 15:59:19 -04:00
Phreshhh 6f9f0ccda0 'paper-btn' class added to linkbutton example. Sorry I left it 1st time. 2020-08-01 15:59:19 -04:00
Phreshhh 800a5cd80f Outline buttons - stylelint fix 2020-08-01 15:59:19 -04:00
Phreshhh 1570e3ba33 Outline buttons 2020-08-01 15:59:19 -04:00
Rhyne 837c4321b9
Merge pull request #207 from Bajena/patch-1
Support multiple tab components
2020-08-01 15:32:53 -04:00
Rhyne 67435c6e81
Merge pull request #205 from papercss/tab-content-alignment-fix
Tabs Content Alignment Bugfix
2020-08-01 15:29:42 -04:00
Rhyne Vlaservich 33ca19d77a Fix gulp default command to start dev server 2020-08-01 15:14:46 -04:00
Rhyne 9af3610ce6
Merge pull request #190 from byrro/fix-license-link
Fix link to License in About page
2020-08-01 14:46:35 -04:00
Jan Bajena 5ee5960e84
Support multiple tab components
Hi, first of all thank you for your cool framework. I really have fun working with it :)

I'm building an app for building flashcard sets in which I decided to use tabs component for switching between different languages. However I've noticed that current version assumes that there'll only be a single tab component on the page.

I overcame it in my project by changing `=` (attribute equals) selector to `$=` (attribute ends with) selector. 
This allows me to generate different tab IDs for different flashcards, like this:
```ruby
<% tab_name = "tabs_#{word.id}" %>
<% tab1_id = "#{tab_name}_tab1" %>
<% tab2_id = "#{tab_name}_tab2" %>

<div class="xs-12 sm-6 md-4 lg-3 col align-top flashcard-column">
  <div class="card">
    <div class="card-body">
      <div class="row tabs">
        <input id="<%= tab1_id %>" type="radio" name="<%= tab_name %>" checked>
        <label for="<%= tab1_id %>">Question</label>

        <input id="<%= tab2_id %>" type="radio" name="<%= tab_name %>">
        <label for="<%= tab2_id %>">Answer</label>

        <div id="<%= tab_name %>_content1" class="content">
          <h4 class="card-title flashcard-title"><%= word.question %></h4>
          <% if word.question_example %>
            <p class="card-text flashcard-example"><%= word.question_example %></p>
          <% end %>
        </div>
        <div id="<%= tab_name %>_content2" class="content">
          <h4 class="card-title flashcard-title"><%= word.answer %></h4>
          <% if word.answer_example %>
            <p class="card-text flashcard-example"><%= word.answer_example %></p>
          <% end %>
        </div>
      </div>
    </div>
  </div>
</div>
```

Here's a video to present how it works after the change:
https://www.loom.com/share/6de1e443314f44f49c7b91e9b5875c93

Hope someone finds it useful
2020-07-30 21:43:39 +02:00
Kevin Koester fc4ede380a
Fixes #202
Fixes Bug where the content would be aligned right next to the tabs on larger screens.

See: https://github.com/papercss/papercss/issues/202
2020-07-10 11:44:26 +02:00
= 1ee089b924 chore: add comments for theme colors 2020-06-01 23:17:18 +02:00
= a7e099055c feat: add dark mode 2020-06-01 23:03:46 +02:00
= 36fcab8371 chore: (editorconfig) add quote_type 2020-06-01 22:55:06 +02:00
Renato Byrro fc54f0cf7f Fix link to License in About page 2019-08-23 15:21:43 -03:00
rhyneav cbbdce4d9e Update broken url 2019-08-18 13:09:58 -04:00
Rhyne 2d94af7997
Merge pull request #189 from fulldecent/patch-1
Fix styling of word GitHub
2019-08-18 13:03:23 -04:00
Rhyne 53d8c34a2c
Merge pull request #188 from impressivewebs/patch-1
Fixed markup for nested lists
2019-08-18 13:03:00 -04:00
William Entriken c6da9aee81
Fix styling of word GitHub 2019-07-30 13:05:53 -04:00
Louis Lazaris 012d8825aa
Fixed markup for nested lists
It's a common mistake, but HTML lists should be nested so that a list is in between the opening and closing tags for a given list item. I've corrected it in these examples. Most browsers handle it fine but it's best to use correct HTML, just in case there's a browser or platform that doesn't parse it correctly.
2019-05-23 00:27:57 -04:00
Rhyne e0b7a74c0e
Merge pull request #184 from Phreshhh/feature-breadcrumb
Feature Breadcrumb
2019-05-05 16:25:09 -04:00
Rhyne 84dde0dbad
Merge pull request #179 from Phreshhh/feature-navbar-fix-in-firefox
Navbar fix for FireFox
2019-05-05 16:23:18 -04:00
Phreshhh 95c7de0f27 Feature Breadcrumb 2019-02-14 12:53:16 +01:00
Phreshhh e9351b60af Feature Breadcrumb 2019-02-14 12:40:25 +01:00
Phreshhh 12af59b98a button fix for backward compatibility 2019-02-11 09:36:27 +01:00
Rhyne 2bf563c3f2
Merge pull request #181 from Phreshhh/feture-switch-component
Switch components
2019-02-08 18:21:18 -05:00
Rhyne de9fd41c6a
Merge pull request #180 from Phreshhh/feature-outline-buttons
Outline buttons
2019-02-08 18:15:40 -05:00
Phreshhh f9001e741b bg and shadow color changed to variable colors 2019-02-01 18:12:38 +01:00
Phreshhh 9f6be35b1b outline colormap removed 2019-02-01 17:36:54 +01:00
Phreshhh 923133c489 Switch components - stylelint fix 8 :) - realy last XD 2019-01-31 21:09:18 +01:00
Phreshhh aab82aa3c4 Switch components - stylelint fix 7 :) - last 2019-01-31 21:05:37 +01:00
Phreshhh 2e22ed491e Switch components - stylelint fix 6 :) 2019-01-31 21:00:20 +01:00
Phreshhh c0d9eb11a7 Switch components - stylelint fix 5 :) I installed stylelint to my editor.. next time will less commits. 2019-01-31 20:53:47 +01:00
Phreshhh 78a677b1b9 Switch components - stylelint fix 4 :) OMG alphabetical.. - Why?! lol 2019-01-31 20:44:57 +01:00
Phreshhh 608b93f7a9 Switch components - stylelint fix 3 :) 2019-01-31 20:32:01 +01:00
Phreshhh 8be95f87ba Switch components - stylelint fix 2 :) 2019-01-31 20:17:45 +01:00
Phreshhh df8e6b64d3 Switch components - stylelint fix 1 :) 2019-01-31 19:44:16 +01:00
Phreshhh 44f413b696 Switch components 2019-01-31 19:07:06 +01:00
Phreshhh a03b8dbc6d 'paper-btn' class added to linkbutton example. Sorry I left it 1st time. 2019-01-30 15:49:57 +01:00
Phreshhh 01f267fb8c Outline buttons - stylelint fix 2019-01-30 12:49:36 +01:00
Phreshhh 70b2a1422f Outline buttons 2019-01-30 12:36:11 +01:00
Phreshhh fad66597ce burger borderfix 2019-01-29 16:21:23 +01:00
Phreshhh 72ac948f70 margin-top removed 2019-01-29 15:39:08 +01:00
Phreshhh 6bc209efd8 margin-top stylelint fix 2019-01-29 15:10:44 +01:00
Phreshhh c9ea3a86c2 Navbar fix for FireFox 2019-01-29 14:58:36 +01:00
rhyneav 780c304f98 Merge branch 'release-1.6.1' 2019-01-25 07:20:02 -05:00
rhyneav 564c01b153 1.6.1 2019-01-25 07:18:37 -05:00
rhyneav 02b5d372bc Merge branch 'develop' into release-1.6.1 2019-01-25 07:11:48 -05:00
Rhyne 6695244c30
Merge pull request #177 from sarramegnag/fix-anchor-transition
Fix hover transition on .paper-btn anchors
2019-01-25 07:08:02 -05:00
Rhyne b5f837ca50
Merge pull request #176 from sarramegnag/fix-progress-bar
Fix percentage calculation in progress bar for loop
2019-01-25 07:07:51 -05:00
Rhyne 3a77420aaf
Merge pull request #175 from sarramegnag/fix-documentation
Fix yarn install command documentation
2019-01-25 07:07:39 -05:00
Guillaume Sarramegna a0c77badbd Fix hover transition on .paper-btn anchors 2018-12-28 01:08:19 +01:00
Guillaume Sarramegna 8af69f367c Fix percentage calculation in progress bar for loop 2018-12-27 23:35:42 +01:00
Guillaume Sarramegna 4c1eb37c68 Fix yarn install command documentation 2018-12-27 23:34:14 +01:00
Rhyne 03df3ea607
Merge pull request #171 from nelsonmestevao/patch-1
Fix typo
2018-12-07 19:42:59 -05:00
Nelson Estevão 9c3a9ddb7e
Fix typo 2018-12-04 23:31:39 +00:00
Rhyne dc474ed8c3
Merge pull request #170 from vanillaSlice/keyboard-control-on-radio-buttons-bug-fix
Keyboard control on radio buttons bug fix
2018-11-18 17:06:19 -05:00
vanillaSlice 0d51e714b6 Keyboard control on radio buttons bug fix 2018-11-17 17:46:37 +00:00
Thomas Cazade 6c20a60053
Merge pull request #165 from papercss/deps-audit
Update deps to reduce the vulnerabilities, migrate to Gulp 4
2018-11-05 15:18:26 +01:00
Thomas Cazade c9460edc28 Merge branch 'develop' of github.com:papercss/papercss into deps-audit 2018-11-05 15:12:09 +01:00
Rhyne 9625bf1e5c
Merge pull request #163 from anupamasok/master
Grammer Errors in Readme
2018-11-05 08:22:03 -05:00
Thomas Cazade a5123877ce
Merge pull request #166 from mertsafak/input-select-same-height
set selects' height to 2.35rem to prevent inconsistent behaviour
2018-11-01 18:33:20 +01:00
mert.safak 67d1208570 set select elements' height to 2.35rem to prevent inconsistent behaviour on Firefox 2018-10-31 22:44:21 +03:00
Thomas Cazade 9b23bbcf38 chore: removed yarn.lock (don't mix package managers) 2018-10-29 13:32:47 +01:00
Thomas Cazade c03f4a254d chore: update minimatch@3.0.4 --depth=5 2018-10-29 13:30:07 +01:00
Thomas Cazade 24969b15e4 chore: update gulp-less@^4.0.1 2018-10-29 13:26:04 +01:00
Thomas Cazade 487ad36fa2 chore: update webpack-dev-server@^3.1.10 2018-10-29 13:21:58 +01:00
Thomas Cazade 7e640b9732 gulpfile: migrate from v3 to v4 2018-10-29 13:21:22 +01:00
Thomas Cazade d5fe24720e chore: update karma@3.1.1 2018-10-29 12:18:51 +01:00
Thomas Cazade 9cfc25e9ee chore: update gulp@4.0.0 2018-10-29 12:15:39 +01:00
Thomas Cazade 248c71ae2d chore: add npm^6.4.1, fixes some vulnerabilities 2018-10-29 12:13:07 +01:00
Thomas Cazade 57711c19d5 chore: update some deps and reduce vulnerabilities 2018-10-29 11:55:33 +01:00
Anupam Asok 39c7c32152
Grammar Errors in Readme
Rectified a few grammar errors
2018-10-27 16:45:25 +05:30
anupam 0504724ca2 Grammer Errors in Readme 2018-10-26 01:10:43 +05:30
77 changed files with 9268 additions and 40592 deletions

View file

@ -7,3 +7,4 @@ trim_trailing_whitespace = true
insert_final_newline = true
indent_style = space
indent_size = 2
quote_type = single

1
.gitignore vendored
View file

@ -8,4 +8,3 @@ npm-debug.log
# Ignore compiled CSS
/docs/static/assets/paper.css
/docs/static/assets/paper.min.css
/dist

View file

@ -1,9 +1,13 @@
/node_modules
npm-debug.log
index.html
demo.css
yarn.lock
/img
/.github
/build
/docs
/img
/node_modules
/public
/tests
.browserslistrc
.editorconfig
.stylelintrc.json
CODE_OF_CONDUCT.md
CONTRIBUTING.md
netlify.toml
npm-debug.log

View file

@ -1,33 +0,0 @@
language: node_js
node_js: "8.8.1"
notifications:
slack:
rooms:
- papercss:1MrmPTVH6FLA95Oa5IfXl7xQ#travis
addons:
firefox: latest
apt:
sources:
- google-chrome
packages:
- google-chrome-stable fluxbox
before_install:
- npm install -g npm@5.10.0
install:
- npm ci
before_script:
- npm run stylelint
- "sh -e /etc/init.d/xvfb start"
- sleep 3
- fluxbox >/dev/null 2>&1 &
- chmod +x ./jake.sh
- chmod +x ./tests/build/scripts/run_jake.sh
- export DISPLAY=:99.0
- gulp build
script: "./jake.sh loose=true capture=Firefox"

View file

@ -1,19 +1,23 @@
## Contributing
Check out what's been added but not yet released at [develop.getpapercss.com](https://develop.getpapercss.com)
This project is open source and contributions are very welcomed. It is also as beginner friendly as possible, so don't be afraid to jump in if you've never contributed to any Git project before! Feel free to reach out if you are new and need help with the process.
Similar to customizing, make sure you have Git, Node, and NPM on your system.
- fork the repo via the fork button in the upper left
- run `git clone https://github.com/[your_username]/papercss.git`
- change directories to papercss `cd papercss`
- run `npm install`
- switch to the develop branch `git checkout develop`. This is the branch where features are added. Checking it out will set up the remote tracking to the develop branch on Github.
- create a new branch for your feature off of the develop branch `git checkout -b feature-thing develop`. Please be sure to prepend your new feature branch with "feature-"
- Start the local server to view changes with `npm start`
- _code and stuff_
- Once done, commit and push your changes to your fork
- Finally, open a pull request on this repo. Be sure to include any pictures and details on what you changed!
- Once approved, your changes will be merged to the develop branch where it will eventually be added to a release that ends up in the master branch. Check out [Vincent Driessen's blog post](http://nvie.com/posts/a-successful-git-branching-model/), [GitFlow](https://datasift.github.io/gitflow/IntroducingGitFlow.html), or [#27](https://github.com/rhyneav/papercss/issues/27) for more details on how this works.
Please before sending a PR, make sure you are properly using the `.editorconfig` file with your IDE. If your IDE doesn't natively support `editorconfig` files, you can use an extension/package/module. For example in Atom there is the [editorconfig package](https://atom.io/packages/editorconfig), as well for [Sublime Text](https://github.com/sindresorhus/editorconfig-sublime), [VS Code](https://github.com/editorconfig/editorconfig-vscode), [Vim](https://github.com/editorconfig/editorconfig-vim), ...
Note: If you have a hotfix, create your hotfix branch off of the master branch instead of develop: `git checkout -b hotfix-1.X.X master`
Once you are ready to contribute, here the workflow you should follow:
- Fork the repo then clone it: `git clone git@github.com:[your_username]/papercss.git`
- `cd papercss` then install dependencies: `npm install`
- Change your current branch to `develop`: `git checkout develop`
- Create your new branch where you will write your code: `git checkout -b feature-thing develop`. Please be sure to prepend your new feature branch with "feature-"
- Write some code!
- To build the scss (in `src/`) to css (in `dist/`), run `npm run css:build`. Note: you will need to re-run this command to include the latest changes in `src/`.
- To preview your changes, you can run `npm start`. This will start a `localhost` server.
- Check to make sure your code is following style rules with `npm run stylelint`
- Once done commit and push your changes to your fork. The linter is also run as a pre-commit hook.
- Open a pull request on the origin papercss repo. Be sure to include any pictures and/or details on what you have done; it will help reviewers **a lot**!
- When your changes are approved, they will be merged into the `develop` branch, which will finally be merged into the `master` branch when we reach a milestone regarding features and bug fixes. Check out [Vincent Driessen's blog post](http://nvie.com/posts/a-successful-git-branching-model/), [GitFlow](https://datasift.github.io/gitflow/IntroducingGitFlow.html), or [#27](https://github.com/rhyneav/papercss/issues/27) for more details on how this works.
Note: If you have a hotfix (usually typos and minor documentation tweaks), create your hotfix branch off of the master branch instead of develop: `git checkout -b hotfix-thing master`. The changes will be merged into both the master and develop to keep the branches consistent.

14
DISTRIBUTING.md Normal file
View file

@ -0,0 +1,14 @@
For distributing a new version to Github, NPM, and the CDN
1. Ensure the build is up to date with `npm run build`
2. Update all version numbers in the app using [Semantic Versioning](https://semver.org/). Ex renaming `1.8.0` to `1.8.1` for a patch.
1. package.json
2. package-lock.json
3. docs/content/_index.md
3. Create commit of the new version with the changed version files: `v1.8.3`
4. Push to master
5. Create new release in the Github UI
1. Create a new tag with the same name as the commit: `v1.8.3`
2. Add details about the additions and fixes
3. Upload the files in `dist` to the "Attach Binaries" section (`paper.css` and `paper.min.css`)
6. Publish to NPM with `npm publish`. The CDN will automatically pick up the new files

View file

@ -1,117 +0,0 @@
// Copyright (c) 2012-2014 Titanium I.T. LLC. All rights reserved. See LICENSE.txt for details.
// Main build file. Contains all tasks needed for normal development.
// There's no Quixote-specific configuration in this file.
(function() {
"use strict";
var startTime = Date.now();
var shell = require("shelljs");
var karma = require("simplebuild-karma");
var browserify = require("./tests/build/util/browserify_runner.js");
var browsers = require("./tests/build/config/tested_browsers.js");
var paths = require("./tests/build/config/paths.js");
var KARMA_CONFIG = "./tests/build/config/karma.conf.js";
var strict = !process.env.loose;
//*** GENERAL
desc("Lint and test");
task("default", [ "lint", "test" ], function() {
var elapsedSeconds = (Date.now() - startTime) / 1000;
console.log("\n\nBUILD OK (" + elapsedSeconds.toFixed(2) + "s)");
});
desc("Start server (for manual testing)");
task("run", [ "build" ], function() {
jake.exec("node ../node_modules/http-server/bin/http-server " + paths.clientDistDir, { interactive: true }, complete);
}, { async: true });
desc("Delete generated files");
task("clean", function() {
shell.rm("-rf", paths.generatedDir);
});
//*** LINT
/** */
desc("Lint everything");
task("lint", ["lintNode", "lintClient"]);
task("lintNode", function() {
process.stdout.write("Linting Node.js code: ");
}, { async: false });
task("lintClient", function() {
process.stdout.write("Linting browser code: ");
}, { async: false });
//*** TEST
desc("Start Karma server -- run this first");
task("karma", function() {
karma.start({
configFile: KARMA_CONFIG
}, complete, fail);
}, { async: true });
desc("Run tests");
task("test", function() {
console.log("Testing browser code: ");
var browsersToCapture = process.env.capture ? process.env.capture.split(",") : [];
karma.run({
configFile: KARMA_CONFIG,
expectedBrowsers: browsers,
strict: strict,
capture: browsersToCapture
}, complete, fail);
}, { async: true });
//*** BUILD
desc("Build distribution package");
task("build", [ "prepDistDir", "buildClient" ]);
task("prepDistDir", function() {
shell.rm("-rf", paths.distDir);
});
task("buildClient", [ paths.clientDistDir, "bundleClientJs" ], function() {
console.log("Copying client code: .");
shell.cp(
paths.clientDir + "/*.html",
paths.clientDir + "/*.css",
paths.clientDir + "/*.svg",
paths.clientDistDir
);
});
task("bundleClientJs", [ paths.clientDistDir ], function() {
console.log("Bundling browser code with Browserify: .");
browserify.bundle({
entry: paths.clientEntryPoint,
outfile: paths.clientDistBundle,
options: {
standalone: "toggle",
debug: true
}
}, complete, fail);
}, { async: true });
//*** CREATE DIRECTORIES
directory(paths.testDir);
directory(paths.clientDistDir);
}());

View file

@ -10,8 +10,8 @@
## Table of contents
- [Table of contents](#table-of-contents)
- [Quick-start](#quick-start)
- [Status](#status)
- [Content of the framework](#content-of-the-framework)
- [Documentation](#documentation)
- [Customizing](#customizing)
@ -26,31 +26,24 @@ There are several options available:
- You can [download the latest release](https://github.com/papercss/papercss/releases).
- Clone the repo: `git clone https://github.com/papercss/papercss.git`
- Install with npm: `npm install papercss`
- Install with yarn: `yarn install papercss`
- Install with yarn: `yarn add papercss`
- Import it using a CDN (it will automatically download the latest version):
- `https://unpkg.com/papercss/dist/paper.min.css`
- `https://unpkg.com/papercss/dist/paper.css`
## Status
[![Build status](https://travis-ci.org/papercss/papercss.svg?branch=master)](https://travis-ci.org/papercss/papercss)
[![Dependencies](https://img.shields.io/david/papercss/papercss.svg)](https://david-dm.org/papercss/papercss)
[![Peer dependencies](https://img.shields.io/david/peer/papercss/papercss.svg)](https://david-dm.org/papercss/papercss?type=peer)
[![Dev dependencies](https://img.shields.io/david/dev/papercss/papercss.svg)](https://david-dm.org/papercss/papercss?type=dev)
- `https://unpkg.com/papercss/dist/paper.min.css`
- `https://unpkg.com/papercss/dist/paper.css`
## Content of the framework
We provide compiled CSS (`paper.css`) as well as minified CSS (`paper.min.css`).
You can choose which components you may want to use. Only the components that get imported in `src/styles.scss` will be compiled into `dist/paper.css`.
You can choose which components you may want to use. Only the components that get imported into `src/styles.scss` will be compiled into `dist/paper.css`.
You can also play with original, source files, written in SCSS, in `src/`.
## Documentation
You can view the docs at [getpapercss.com](https://www.getpapercss.com). Those are directly from the `master` branch, this means those features are stable and ready to be used in your project.
You can view the docs at [getpapercss.com](https://www.getpapercss.com). Those are directly from the `master` branch; this means those features are stable and ready to be used in your project.
You can also view the develop branch at [develop.getpapercss.com](https://develop.getpapercss.com), this include new features that are coming soon in master branch. Be warned, a feature in develop can be removed without any prevention.
You can also view the develop branch at [develop.getpapercss.com](https://develop.getpapercss.com), this includes new features that are coming soon in the master branch. Be warned, a feature in develop can be removed without any prevention.
## Customizing
@ -58,7 +51,7 @@ You can customize PaperCSS easily, clone the repo, run `npm install` and make an
The main place you might want to make changes would be `core/_config.scss`, where you can specify new colors or fonts for your CSS build.
After you make changes, be sure to build the new CSS files. Do so by running `gulp build` and get them from the `dist/` folder.
After you make changes, be sure to build the new CSS files. Do so by running `npm run css:build` and get them from the `dist/` folder.
## Contributing
@ -72,22 +65,23 @@ Once you are ready to contribute, here the workflow you should follow:
- `cd papercss` then install dependencies: `npm install`
- Change your current branch to `develop`: `git checkout develop`
- Create your new branch where you will write your code: `git checkout -b feature-thing develop`. Please be sure to prepend your new feature branch with "feature-"
- Start the local web-server: `gulp` or `npm start`
- Write some code!
- To build the scss (in `src/`) to css (in `dist/`), run `npm run css:build`. Note: you will need to re-run this command to include the latest changes in `src/`.
- To preview your changes, you can run `npm start`. This will start a `localhost` server.
- Check to make sure your code is following style rules with `npm run stylelint`
- Once done commit and push your changes to your fork. The linter is also run as a precommit hook.
- Open a pull request on the origin papercss repo. Be sure to include any pictures and/or details on what you have done, it will help reviewers **a lot**!
- When your changes are approved, they will be merged into the `develop` branch, which will finally be merged into the `master` branch when we reach a milestone in terms of features and bug fixes. Check out [Vincent Driessen's blog post](http://nvie.com/posts/a-successful-git-branching-model/), [GitFlow](https://datasift.github.io/gitflow/IntroducingGitFlow.html), or [#27](https://github.com/rhyneav/papercss/issues/27) for more details on how this works.
- Once done commit and push your changes to your fork. The linter is also run as a pre-commit hook.
- Open a pull request on the origin papercss repo. Be sure to include any pictures and/or details on what you have done; it will help reviewers **a lot**!
- When your changes are approved, they will be merged into the `develop` branch, which will finally be merged into the `master` branch when we reach a milestone regarding features and bug fixes. Check out [Vincent Driessen's blog post](http://nvie.com/posts/a-successful-git-branching-model/), [GitFlow](https://datasift.github.io/gitflow/IntroducingGitFlow.html), or [#27](https://github.com/rhyneav/papercss/issues/27) for more details on how this works.
Note: If you have a hotfix (usually typos and minor documentation tweaks), create your hotfix branch off of the master branch instead of develop: `git checkout -b hotfix-thing master`. The changes will be merged into both master and develop to keep the branches consistent.
Note: If you have a hotfix (usually typos and minor documentation tweaks), create your hotfix branch off of the master branch instead of develop: `git checkout -b hotfix-thing master`. The changes will be merged into both the master and develop to keep the branches consistent.
## About
PaperCSS was originally made by [@rhyneav](https://github.com/rhyneav) to be something different than the typical mODerN STylEs and clean pages found in every other CSS framework. It was built with LESS and deployed on a single index.html page before being open sourced. It has since evolved; The CSS source has been rewritten in SCSS and the documentation is now built with Hugo (all thanks to some [wonderful contributors](https://github.com/papercss/papercss/graphs/contributors)). In addition to the original creator, it is maintained by [@Fraham](https://github.com/Fraham) and [@TotomInc](https://github.com/TotomInc).
PaperCSS was originally made by [@rhyneav](https://github.com/rhyneav) to be something different than the typical mODerN STylEs and clean pages found in every other CSS framework. It was built with LESS and deployed on a single index.html page before being open sourced. It has since evolved; The CSS source has been rewritten in SCSS and the documentation is now built with Hugo (all thanks to some [wonderful contributors](https://github.com/papercss/papercss/graphs/contributors)). It is currently maintained by the [PaperCSS team](https://github.com/orgs/papercss/people).
The goal of PaperCSS is to be as minimal as possible when adding classes. For example, a button should just look like a paper button. There shouldn't be a need to add a class such as `paper-button`. Because of this, adding PaperCSS to a markdown generated page should instantly paper-ize it.
Feel free to use it for wireframes, webapps, blogs, or whatever else you can think of!
Feel free to use it for wireframes, web apps, blogs, or whatever else you can think of!
If you are new to Git or SCSS, this would be a great project to get your feet wet with. I'd be happy to help walk you through the pull request process.

43
build/build.js Normal file
View file

@ -0,0 +1,43 @@
const fs = require('fs');
const sass = require('sass');
const write = require('write');
const rimraf = require('rimraf');
const postcss = require('postcss');
const cssnano = require('cssnano');
const autoprefixer = require('autoprefixer');
const constants = require('./constants');
const log = require('./log');
async function build() {
log('Starting PaperCSS build...');
log('Cleaning "dist/, docs/static/assets/paper.css" folder...');
rimraf.sync('dist', { disableGlob: true });
if (fs.existsSync(constants.PAPER_DOCS_PATH)) {
fs.unlinkSync(constants.PAPER_DOCS_PATH);
}
log('Compiling SCSS to CSS, entrypoint:', constants.ENTRYPOINT_PATH);
const compiledCSS = sass.renderSync({ file: constants.ENTRYPOINT_PATH });
log('Processing CSS: autoprefixer...');
const autoprefixedCSS = await postcss([autoprefixer]).process(compiledCSS.css, { from: undefined });
log('Processing CSS: cssnano...');
const minifiedCSS = await postcss([cssnano]).process(autoprefixedCSS.css, { from: undefined });
log('Writing paper.css and paper.min.css files to dist/ and docs/ folders...');
write(constants.PAPER_DIST_PATH, autoprefixedCSS.css);
write(constants.PAPER_DIST_MIN_PATH, minifiedCSS.css);
write(constants.PAPER_DOCS_PATH, autoprefixedCSS.css);
log('Build done!');
}
build();

8
build/constants.js Normal file
View file

@ -0,0 +1,8 @@
const path = require('path');
module.exports = {
ENTRYPOINT_PATH: path.resolve(__dirname, '../src/styles.scss'),
PAPER_DIST_PATH: path.resolve(__dirname, '../dist/paper.css'),
PAPER_DIST_MIN_PATH: path.resolve(__dirname, '../dist/paper.min.css'),
PAPER_DOCS_PATH: path.resolve(__dirname, '../docs/static/assets/paper.css'),
};

26
build/hot-reload.js Normal file
View file

@ -0,0 +1,26 @@
const util = require('util');
const sass = require('sass');
const write = require('write');
const postcss = require('postcss');
const chokidar = require('chokidar');
const autoprefixer = require('autoprefixer');
const constants = require('./constants');
const log = require('./log');
const sassRenderPromisified = util.promisify(sass.render);
function compile() {
sassRenderPromisified({ file: constants.ENTRYPOINT_PATH })
.then((compiledCSS) => postcss([autoprefixer]).process(compiledCSS.css.toString(), { from: undefined }))
.then((autoprefixedCSS) => write(constants.PAPER_DOCS_PATH, autoprefixedCSS.css))
.then(() => log('Compiled CSS in docs/ folder.'));
}
chokidar.watch('./src/**/*.scss').on('change', (event) => {
log(`Detected file change (${event}), compiling SCSS to CSS...`);
compile();
});
// Do initial compilation.
compile();

7
build/log.js Normal file
View file

@ -0,0 +1,7 @@
const chalk = require('chalk');
function log(...args) {
return console.log('📦 ', chalk.cyan(...args));
}
module.exports = log;

3328
dist/paper.css vendored Normal file

File diff suppressed because it is too large Load diff

2
dist/paper.min.css vendored Normal file

File diff suppressed because one or more lines are too long

View file

@ -7,6 +7,7 @@ publishDir = "../public"
# Syntax Highlighting ( https://gohugo.io/content-management/syntax-highlighting/ )
pygmentsCodefences = true
pygmentsStyle = "emacs"
pygmentsUseClasses=true
[params.info]
description = "the less formal CSS framework"
@ -16,5 +17,7 @@ title404 = "Nothing's here!"
# Title Separator: - — · • * ⋆ | ~ « » < >
titleSeparator = "•"
[blackfriday]
hrefTargetBlank = true
[markup]
defaultMarkdownHandler = "blackfriday"
[markup.blackFriday]
hrefTargetBlank = true

View file

@ -6,48 +6,51 @@ weight: -270
#### Download
Download the latest version (1.6.0) using either of the links below. Or
download an older release via Github.
Download the latest version (1.9.2) using either of the links below. Or
download an older release via GitHub.
<div class="row flex-spaces text-center">
<a class="paper-btn margin" href="https://github.com/rhyneav/papercss/releases/download/v1.6.0/paper.css">CSS File</a>
<a class="paper-btn margin" href="https://github.com/rhyneav/papercss/releases/download/v1.6.0/paper.min.css">Minified CSS File</a>
<a class="paper-btn margin" href="https://github.com/rhyneav/papercss/releases">Github Releases</a>
<a class="paper-btn margin" href="https://github.com/rhyneav/papercss/releases/download/v1.9.2/paper.css">CSS File</a>
<a class="paper-btn margin" href="https://github.com/rhyneav/papercss/releases/download/v1.9.2/paper.min.css">Minified CSS File</a>
<a class="paper-btn margin" href="https://github.com/rhyneav/papercss/releases">GitHub Releases</a>
</div>
#### NPM
PaperCSS is available on NPM, current version 1.6.0. Install with <code>npm install papercss --save</code> and find the CSS in:
PaperCSS is available on NPM, current version 1.9.2. Install with <code>npm install papercss --save</code> and find the CSS in:
* node_modules/papercss/dist/paper.css
* node_modules/papercss/dist/paper.min.css
- node_modules/papercss/dist/paper.css
- node_modules/papercss/dist/paper.min.css
#### CDN
Don't want to download it? That's cool. You can just link to PaperCSS via
[unpkg's CDN](https://unpkg.com/#/). You can use either:
* [https://unpkg.com/papercss@1.6.0/dist/paper.css](https://unpkg.com/papercss@1.6.0/dist/paper.css)
* [https://unpkg.com/papercss@1.6.0/dist/paper.min.css](https://unpkg.com/papercss@1.6.0/dist/paper.min.css)
- [https://unpkg.com/papercss@1.9.2/dist/paper.css](https://unpkg.com/papercss@1.9.2/dist/paper.css)
- [https://unpkg.com/papercss@1.9.2/dist/paper.min.css](https://unpkg.com/papercss@1.9.2/dist/paper.min.css)
Here's a quck snippet to get started with PaperCSS:
Here's a quick snippet to get started with PaperCSS:
```html
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<link rel="stylesheet" href="https://unpkg.com/papercss@1.6.0/dist/paper.min.css">
<title>Document</title>
</head>
<body>
<div class="paper container">
<h1>Some Fresh Title</h1>
<p>This is where some content would go.</p>
</div>
</body>
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<meta http-equiv="X-UA-Compatible" content="ie=edge" />
<link
rel="stylesheet"
href="https://unpkg.com/papercss@1.9.2/dist/paper.min.css"
/>
<title>Document</title>
</head>
<body>
<div class="paper container">
<h1>Some Fresh Title</h1>
<p>This is where some content would go.</p>
</div>
</body>
</html>
```
@ -64,4 +67,4 @@ npm run build
Grab the CSS out of the /dist folder created
You can also go into src/core/_config.scss before building to change around the global styles of your new CSS.
You can also go into src/core/\_config.scss before building to change around the global styles of your new CSS.

View file

@ -9,6 +9,6 @@ PaperCSS was originally made by [@rhyneav](https://github.com/rhyneav) to be som
The goal of PaperCSS is to be as minimal as possible when adding classes. For example, a button should just look like a paper button. There shouldn't be a need to add a class such as `paper-button`. Because of this, adding PaperCSS to a markdown generated page should instantly paper-ize it.
Feel free to use it for wireframes, webapps, blogs, or whatever else you can think of! It is licensed under the [ISC License](https://github.com/papercss/papercss/blob/master/license), so use it wherever you want to.
Feel free to use it for wireframes, webapps, blogs, or whatever else you can think of! It is licensed under the [ISC License](https://github.com/papercss/papercss/blob/master/LICENSE.md), so use it wherever you want to.
If you are new to Git or SCSS, this would be a great project to get your feet wet with. I'd be happy to help walk you through the pull request process. Check out the [Git repo](https://github.com/papercss/papercss) for more info!

View file

@ -0,0 +1,20 @@
---
title: Breadcrumb
description: PaperCSS Breadcrumb
---
<ul class="breadcrumb border">
<li><a href="#">Documentation</a></li>
<li><a href="#">Components</a></li>
<li>Breadcrumb</li>
</ul>
#### Code:
```html
<ul class="breadcrumb border">
<li><a href="#">Documentation</a></li>
<li><a href="#">Components</a></li>
<li>Breadcrumb</li>
</ul>
```

View file

@ -53,3 +53,21 @@ Inspired by [Imperfect Buttons](https://codepen.io/tmrDevelops/pen/VeRvKX)
<button class="btn-warning">Warning</button>
<button class="btn-danger">Danger</button>
```
### Outline colors
<input type="button" class="paper-btn btn-primary-outline" value="Primary"/>
<input type="button" class="btn-secondary-outline" value="Secondary"/>
<button class="btn-success-outline">Success</button>
<button class="btn-warning-outline">Warning</button>
<a href="#" class="paper-btn btn-danger-outline">Danger</a>
#### Code:
```html
<input type="button" class="paper-btn btn-primary-outline" value="Primary"/>
<input type="button" class="btn-secondary-outline" value="Secondary"/>
<button class="btn-success-outline">Success</button>
<button class="btn-warning-outline">Warning</button>
<a href="#" class="paper-btn btn-danger-outline">Danger</a>
```

View file

@ -25,12 +25,12 @@ description: PaperCSS Forms
<input type="text" placeholder="Disabled" id="paperInputs4" disabled>
</div>
<div class="form-group">
<label>Large Input</label>
<textarea placeholder="Large input"></textarea>
<label for="large-input">Large Input</label>
<textarea id="large-input" placeholder="Large input"></textarea>
</div>
<div class="form-group">
<label>No Resize</label>
<textarea class="no-resize" placeholder="No resize"></textarea>
<label for="no-resize">No Resize</label>
<textarea class="no-resize" id="no-resize" placeholder="No resize"></textarea>
</div>
<div class="form-group">
<label for="paperSelects1">Select</label>
@ -38,19 +38,17 @@ description: PaperCSS Forms
<option value="1">Option 1</option>
<option value="2">Option 2</option>
<option value="3">Option 3</option>
<select>
</select>
</div>
<fieldset class="form-group">
<legend>Some Radio Buttons</legend>
<label for="paperRadios1" class="paper-radio">
<input type="radio" name="paperRadios" id="paperRadios1" value="option 1">
<span>This is the first option
<span>
<span>This is the first option</span>
</label>
<label for="paperRadios2" class="paper-radio">
<input type="radio" name="paperRadios" id="paperRadios2" value="option 2">
<span>This is the second option
<span>
<span>This is the second option</span>
</label>
</fieldset>
<fieldset class="form-group">
@ -64,6 +62,117 @@ description: PaperCSS Forms
<span>This is the second check</span>
</label>
</fieldset>
<fieldset class="form-group">
<legend>Some Switch</legend>
<p>Default - standard outline style (square & circle)</p>
<label class="paper-switch">
<input id="paperSwitch4" name="paperSwitch4" type="checkbox" />
<span class="paper-switch-slider"></span>
</label>
<label for="paperSwitch4" class="paper-switch-label">
Square switch
</label>
</fieldset>
<fieldset class="form-group">
<label for="paperSwitch5" class="paper-switch-label">
Square switch
</label>
<label class="paper-switch">
<input id="paperSwitch5" name="paperSwitch5" type="checkbox" checked />
<span class="paper-switch-slider"></span>
</label>
</fieldset>
<fieldset class="form-group">
<label class="paper-switch">
<input id="paperSwitch6" name="paperSwitch6" type="checkbox" checked />
<span class="paper-switch-slider round"></span>
</label>
<label for="paperSwitch6" class="paper-switch-label">
Circle switch
</label>
</fieldset>
<fieldset class="form-group">
<label for="paperSwitch7" class="paper-switch-label">
Circle switch
</label>
<label class="paper-switch">
<input id="paperSwitch7" name="paperSwitch7" type="checkbox" />
<span class="paper-switch-slider round"></span>
</label>
</fieldset>
<fieldset class="form-group">
<p>Type2 - inline style (square & circle)</p>
<label class="paper-switch-2">
<input id="paperSwitch8" name="paperSwitch8" type="checkbox" checked />
<span class="paper-switch-slider"></span>
</label>
<label for="paperSwitch8" class="paper-switch-2-label">
Square switch
</label>
</fieldset>
<fieldset class="form-group">
<label for="paperSwitch9" class="paper-switch-2-label">
Square switch
</label>
<label class="paper-switch-2">
<input id="paperSwitch9" name="paperSwitch9" type="checkbox" />
<span class="paper-switch-slider"></span>
</label>
</fieldset>
<fieldset class="form-group">
<label class="paper-switch-2">
<input id="paperSwitch10" name="paperSwitch10" type="checkbox" />
<span class="paper-switch-slider round"></span>
</label>
<label for="paperSwitch10" class="paper-switch-2-label">
Circle switch
</label>
</fieldset>
<fieldset class="form-group">
<label for="paperSwitch11" class="paper-switch-2-label">
Circle switch
</label>
<label class="paper-switch-2">
<input id="paperSwitch11" name="paperSwitch11" type="checkbox" checked />
<span class="paper-switch-slider round"></span>
</label>
</fieldset>
<fieldset class="form-group">
<p>Type3 - Tile style</p>
<label for="paperSwitch1" class="paper-switch-tile">
<input id="paperSwitch1" name="paperSwitch1" type="checkbox" />
<div class="paper-switch-tile-card border">
<div class="paper-switch-tile-card-front border">Front</div>
<div class="paper-switch-tile-card-back border background-primary">Back</div>
</div>
</label>
<label for="paperSwitch2" class="paper-switch-tile">
<input id="paperSwitch2" name="paperSwitch2" type="checkbox" />
<div class="paper-switch-tile-card border">
<div class="paper-switch-tile-card-front border background-warning">Off</div>
<div class="paper-switch-tile-card-back border background-secondary">On</div>
</div>
</label>
<label for="paperSwitch3" class="paper-switch-tile">
<input id="paperSwitch3" name="paperSwitch3" type="checkbox" />
<div class="paper-switch-tile-card border">
<div class="paper-switch-tile-card-front border background-danger">Declined</div>
<div class="paper-switch-tile-card-back border background-success">Accepted</div>
</div>
</label>
</fieldset>
<fieldset class="form-group">
<legend>Sliders</legend>
<div class="form-group">
<label for="input-range">Note /10 :</label>
<input type="range" name="note" id="input-range" min="0" max="10">
</div>
<div class="form-group">
<label for="percentage">Percentage (<code>.input-block</code>) :</label>
<input class="input-block" type="range" name="percentage" id="percentage" min="0" max="100" oninput="output.value = this.value + '%';">
<output id="output" for="percentage">50%</output>
</div>
</fieldset>
#### Code:
@ -91,12 +200,12 @@ description: PaperCSS Forms
<input type="text" placeholder="Disabled" id="paperInputs4" disabled>
</div>
<div class="form-group">
<label>Large Input</label>
<textarea placeholder="Large input"></textarea>
<label for="large-input">Large Input</label>
<textarea id="large-input" placeholder="Large input"></textarea>
</div>
<div class="form-group">
<label>No Resize</label>
<textarea class="no-resize" placeholder="No resize"></textarea>
<label for="no-resize">No Resize</label>
<textarea class="no-resize" id="no-resize" placeholder="No resize"></textarea>
</div>
<div class="form-group">
<label for="paperSelects1">Select</label>
@ -104,15 +213,15 @@ description: PaperCSS Forms
<option value="1">Option 1</option>
<option value="2">Option 2</option>
<option value="3">Option 3</option>
<select>
</select>
</div>
<fieldset class="form-group">
<legend>Some Radio Buttons</legend>
<label for="paperRadios1" class="paper-radio">
<input type="radio" name="paperRadios" id="paperRadios1" value="option 1"> <span>This is the first option<span>
<input type="radio" name="paperRadios" id="paperRadios1" value="option 1"> <span>This is the first option</span>
</label>
<label for="paperRadios2" class="paper-radio">
<input type="radio" name="paperRadios" id="paperRadios2" value="option 2"> <span>This is the second option<span>
<input type="radio" name="paperRadios" id="paperRadios2" value="option 2"> <span>This is the second option</span>
</label>
</fieldset>
<fieldset class="form-group">
@ -124,4 +233,115 @@ description: PaperCSS Forms
<input type="checkbox" name="paperChecks" id="paperChecks2" value="option 2"> <span>This is the second check</span>
</label>
</fieldset>
<fieldset class="form-group">
<legend>Some Switch</legend>
<p>Default - standard outline style (square & circle)</p>
<label class="paper-switch">
<input id="paperSwitch4" name="paperSwitch4" type="checkbox" />
<span class="paper-switch-slider"></span>
</label>
<label for="paperSwitch4" class="paper-switch-label">
Square switch
</label>
</fieldset>
<fieldset class="form-group">
<label for="paperSwitch5" class="paper-switch-label">
Square switch
</label>
<label class="paper-switch">
<input id="paperSwitch5" name="paperSwitch5" type="checkbox" checked />
<span class="paper-switch-slider"></span>
</label>
</fieldset>
<fieldset class="form-group">
<label class="paper-switch">
<input id="paperSwitch6" name="paperSwitch6" type="checkbox" checked />
<span class="paper-switch-slider round"></span>
</label>
<label for="paperSwitch6" class="paper-switch-label">
Circle switch
</label>
</fieldset>
<fieldset class="form-group">
<label for="paperSwitch7" class="paper-switch-label">
Circle switch
</label>
<label class="paper-switch">
<input id="paperSwitch7" name="paperSwitch7" type="checkbox" />
<span class="paper-switch-slider round"></span>
</label>
</fieldset>
<fieldset class="form-group">
<p>Type2 - inline style (square & circle)</p>
<label class="paper-switch-2">
<input id="paperSwitch8" name="paperSwitch8" type="checkbox" checked />
<span class="paper-switch-slider"></span>
</label>
<label for="paperSwitch8" class="paper-switch-2-label">
Square switch
</label>
</fieldset>
<fieldset class="form-group">
<label for="paperSwitch9" class="paper-switch-2-label">
Square switch
</label>
<label class="paper-switch-2">
<input id="paperSwitch9" name="paperSwitch9" type="checkbox" />
<span class="paper-switch-slider"></span>
</label>
</fieldset>
<fieldset class="form-group">
<label class="paper-switch-2">
<input id="paperSwitch10" name="paperSwitch10" type="checkbox" />
<span class="paper-switch-slider round"></span>
</label>
<label for="paperSwitch10" class="paper-switch-2-label">
Circle switch
</label>
</fieldset>
<fieldset class="form-group">
<label for="paperSwitch11" class="paper-switch-2-label">
Circle switch
</label>
<label class="paper-switch-2">
<input id="paperSwitch11" name="paperSwitch11" type="checkbox" checked />
<span class="paper-switch-slider round"></span>
</label>
</fieldset>
<fieldset class="form-group">
<p>Type3 - Tile style</p>
<label for="paperSwitch1" class="paper-switch-tile">
<input id="paperSwitch1" name="paperSwitch1" type="checkbox" />
<div class="paper-switch-tile-card border">
<div class="paper-switch-tile-card-front border">Front</div>
<div class="paper-switch-tile-card-back border background-primary">Back</div>
</div>
</label>
<label for="paperSwitch2" class="paper-switch-tile">
<input id="paperSwitch2" name="paperSwitch2" type="checkbox" />
<div class="paper-switch-tile-card border">
<div class="paper-switch-tile-card-front border background-warning">Off</div>
<div class="paper-switch-tile-card-back border background-secondary">On</div>
</div>
</label>
<label for="paperSwitch3" class="paper-switch-tile">
<input id="paperSwitch3" name="paperSwitch3" type="checkbox" />
<div class="paper-switch-tile-card border">
<div class="paper-switch-tile-card-front border background-danger">Declined</div>
<div class="paper-switch-tile-card-back border background-success">Accepted</div>
</div>
</label>
</fieldset>
<fieldset class="form-group">
<legend>Sliders</legend>
<div class="form-group">
<label for="input-range">Note /10 :</label>
<input type="range" name="note" id="input-range" min="0" max="10">
</div>
<div class="form-group">
<label for="percentage">Percentage (<code>.input-block</code>) :</label>
<input class="input-block" type="range" name="percentage" id="percentage" min="0" max="100" oninput="output.value = this.value + '%';">
<output id="output" for="percentage">50%</output>
</div>
</fieldset>
```

View file

@ -9,13 +9,11 @@ description: PaperCSS Navbar
</div>
<div class="collapsible">
<input id="collapsible0" type="checkbox" name="collapsible0">
<button>
<label for="collapsible0">
<div class="bar1"></div>
<div class="bar2"></div>
<div class="bar3"></div>
</label>
</button>
<label for="collapsible0">
<div class="bar1"></div>
<div class="bar2"></div>
<div class="bar3"></div>
</label>
<div class="collapsible-body">
<ul class="inline">
<li><a href="/docs/">Documentation</a></li>
@ -32,13 +30,11 @@ description: PaperCSS Navbar
</div>
<div class="collapsible">
<input id="collapsible1" type="checkbox" name="collapsible1">
<button>
<label for="collapsible1">
<div class="bar1"></div>
<div class="bar2"></div>
<div class="bar3"></div>
</label>
</button>
<label for="collapsible1">
<div class="bar1"></div>
<div class="bar2"></div>
<div class="bar3"></div>
</label>
<div class="collapsible-body">
<ul class="inline">
<li><a href="#">Documentation</a></li>
@ -60,13 +56,11 @@ Add ```.fixed``` to ```<nav>``` to fix the nav to the top to have it scroll the
</div>
<div class="collapsible">
<input id="collapsible1" type="checkbox" name="collapsible1">
<button>
<label for="collapsible1">
<div class="bar1"></div>
<div class="bar2"></div>
<div class="bar3"></div>
</label>
</button>
<div class="bar1"></div>
<div class="bar2"></div>
<div class="bar3"></div>
</label>
<div class="collapsible-body">
<ul class="inline">
<li><a href="#">Documentation</a></li>
@ -86,13 +80,11 @@ Add ```.fixed``` to ```<nav>``` to fix the nav to the top to have it scroll the
</div>
<div class="collapsible">
<input id="collapsible2" type="checkbox" name="collapsible2">
<button>
<label for="collapsible2">
<div class="bar1"></div>
<div class="bar2"></div>
<div class="bar3"></div>
</label>
</button>
<label for="collapsible2">
<div class="bar1"></div>
<div class="bar2"></div>
<div class="bar3"></div>
</label>
<div class="collapsible-body">
<ul class="inline">
<li><a href="#">Documentation</a></li>
@ -112,13 +104,11 @@ Add ```.fixed``` to ```<nav>``` to fix the nav to the top to have it scroll the
</div>
<div class="collapsible">
<input id="collapsible2" type="checkbox" name="collapsible2">
<button>
<label for="collapsible2">
<div class="bar1"></div>
<div class="bar2"></div>
<div class="bar3"></div>
</label>
</button>
<label for="collapsible2">
<div class="bar1"></div>
<div class="bar2"></div>
<div class="bar3"></div>
</label>
<div class="collapsible-body">
<ul class="inline">
<li><a href="#">Documentation</a></li>

View file

@ -9,23 +9,27 @@ description: PaperCSS Lists
<li>Do this</li>
<li>Then this</li>
<li>Finally this</li>
<li>Then we'll go one deeper</li>
<ol>
<li>Dillon</li>
<li>Francis</li>
<li>Then we'll go one deeper
<ol>
<li>What if we went...</li>
<li>One more deeper?</li>
<ol>
<li>DJ</li>
<li>Hanzel</li>
<li>Dillon</li>
<li>Francis
<ol>
<li>Five levels should be enough</li>
<li>Right?</li>
<li>What if we went...</li>
<li>One more deeper?
<ol>
<li>DJ</li>
<li>Hanzel
<ol>
<li>Five levels should be enough</li>
<li>Right?</li>
</ol>
</li>
</ol>
</li>
</ol>
</ol>
</li>
</ol>
</ol>
</li>
<li>But don't forget this</li>
</ol>
@ -33,22 +37,26 @@ description: PaperCSS Lists
<ul>
<li>Let's try this</li>
<li>Let's try this again</li>
<ul>
<li>And now we are nested</li>
<li>Pretty cool?</li>
<li>Let's try this again
<ul>
<li>The list items are just text</li>
<li>From this font</li>
<ul>
<li>We'll keep going</li>
<li>Until we hit</li>
<li>And now we are nested</li>
<li>Pretty cool?
<ul>
<li>LEVEL 5</li>
<li>The list items are just text</li>
<li>From this font
<ul>
<li>We'll keep going</li>
<li>Until we hit
<ul>
<li>LEVEL 5</li>
</ul>
</li>
</ul>
</li>
</ul>
</ul>
</li>
</ul>
</ul>
</li>
<li>And now we're are the top!</li>
</ul>
@ -68,23 +76,27 @@ description: PaperCSS Lists
<li>Do this</li>
<li>Then this</li>
<li>Finally this</li>
<li>Then we'll go one deeper</li>
<ol>
<li>Then we'll go one deeper
<ol>
<li>Dillon</li>
<li>Francis</li>
<ol>
<li>What if we went...</li>
<li>One more deeper?</li>
<li>Francis
<ol>
<li>DJ</li>
<li>Hanzel</li>
<ol>
<li>Five levels should be enough</li>
<li>Right?</li>
</ol>
<li>What if we went...</li>
<li>One more deeper?
<ol>
<li>DJ</li>
<li>Hanzel
<ol>
<li>Five levels should be enough</li>
<li>Right?</li>
</ol>
</li>
</ol>
</li>
</ol>
</ol>
</ol>
</li>
</ol>
</li>
<li>But don't forget this</li>
</ol>

View file

@ -0,0 +1,53 @@
---
title: Container
description: PaperCSS Container
---
The container is usually at the root of the HTML and holds all of the content in a fixed size. PaperCSS supports a few
different sizes to make setting your content within a certain max-width easy. Don't forget to add the `.paper` class to
give you site some extra paper flair!
<div class='paper container margin-bottom-large'>
<h4>Responsive Container!</h4>
<p>The default</p>
<p>
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Cras lorem lectus, lobortis a nibh non, luctus luctus
erat posuere. Curabitur ac turpis aliquam, malesuada elit suscipit, blandit dolor.
</p>
</div>
<div class='paper container container-lg margin-bottom-large'>
<h4>Large Container!</h4>
<p>Using <code>container-lg</code><p>
<p>
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Cras lorem lectus, lobortis a nibh non, luctus luctus
erat posuere. Curabitur ac turpis aliquam, malesuada elit suscipit, blandit dolor.
</p>
</div>
<div class='paper container container-md margin-bottom-large'>
<h4>Medium Container!</h4>
<p>Using <code>container-md</code><p>
<p>
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Cras lorem lectus, lobortis a nibh non, luctus luctus
erat posuere. Curabitur ac turpis aliquam, malesuada elit suscipit, blandit dolor.
</p>
</div>
<div class='paper container container-sm margin-bottom-large'>
<h4>Small Container!</h4>
<p>Using <code>container-sm</code><p>
<p>
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Cras lorem lectus, lobortis a nibh non, luctus luctus
erat posuere. Curabitur ac turpis aliquam, malesuada elit suscipit, blandit dolor.
</p>
</div>
<div class='paper container container-xs margin-bottom-large'>
<h4>Extra Small Container!</h4>
<p>Using <code>container-xs</code><p>
<p>
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Cras lorem lectus, lobortis a nibh non, luctus luctus
erat posuere. Curabitur ac turpis aliquam, malesuada elit suscipit, blandit dolor.
</p>
</div>

View file

@ -39,7 +39,7 @@ description: PaperCSS Borders & Shadows
<div class="sm-2 col border border-success">Border success</div>
<div class="sm-2 col border border-warning">Border warning</div>
<div class="sm-2 col border border-danger">Border danger</div>
<div class="sm-2 col border background-primary border-white">Border white</div>
<div class="sm-2 col border border-white">Border white</div>
</div>
#### Code:
@ -51,7 +51,7 @@ description: PaperCSS Borders & Shadows
<div class="sm-2 col border border-success">Border success</div>
<div class="sm-2 col border border-warning">Border warning</div>
<div class="sm-2 col border border-danger">Border danger</div>
<div class="sm-2 col border background-primary border-white">Border white</div>
<div class="sm-2 col border border-white">Border white</div>
</div>
<div class="row child-borders">
<div class="sm-2 col border border-primary">Border primary</div>
@ -59,7 +59,7 @@ description: PaperCSS Borders & Shadows
<div class="sm-2 col border border-success">Border success</div>
<div class="sm-2 col border border-warning">Border warning</div>
<div class="sm-2 col border border-danger">Border danger</div>
<div class="sm-2 col border background-primary border-white">Border white</div>
<div class="sm-2 col border border-white">Border white</div>
</div>
```
@ -136,7 +136,7 @@ Use this if you want all children to have a shadow.
<div class="row flex-spaces child-borders child-shadows">
<div class="sm-3 col">Shadow</div>
<div class="sm-3 col">Shadow</div>
<div class="sm-3 col">Shadow</div>
<div class="sm-3 col shadow-none">No Shadow</div>
</div>
#### Code:
@ -145,7 +145,7 @@ Use this if you want all children to have a shadow.
<div class="row flex-spaces child-borders child-shadows">
<div class="sm-3 col">Shadow</div>
<div class="sm-3 col">Shadow</div>
<div class="sm-3 col">Shadow</div>
<div class="sm-3 col shadow-none">No Shadow</div>
</div>
```

View file

@ -0,0 +1,67 @@
---
title: Dark Mode
description: PaperCSS Dark Mode
---
As of version `1.8.0`, PaperCSS supports a dark mode of the framework. Just add the `.dark` class to your `html` tag!
#### Examples
Here's what some of the components look like:
<div class="form-group">
<label for="paperInputs1">Input</label>
<input type="text" placeholder="Nice input" id="paperInputs1">
</div>
<button>
Button
</button>
<div class="progress margin-bottom">
<div class="bar w-25"></div>
</div>
<table>
<thead>
<tr>
<th>#</th>
<th>Name</th>
<th>Position</th>
<th>Location</th>
</tr>
</thead>
<tbody>
<tr>
<td>1</td>
<td>Bob Dylan</td>
<td>Musician</td>
<td>California, USA</td>
</tr>
<tr>
<td>2</td>
<td>Eric Clapton</td>
<td>Musician</td>
<td>Ohio, USA</td>
</tr>
<tr>
<td>3</td>
<td>Daniel Kahneman</td>
<td>Psychologist</td>
<td>California, USA</td>
</tr>
</tbody>
</table>
<script>
var html = document.documentElement;
html.className += 'dark';
</script>
#### Code
```html
<html class='dark'>
Dark mode styles are automatically applied with the dark class!
</html>
```

View file

@ -1,3 +1,4 @@
<!-- Styles -->
<link rel='stylesheet' href='/assets/paper.css'>
<link rel='stylesheet' href='/assets/demo.css'>
<link rel='stylesheet' href='/assets/syntax.css'>

View file

@ -8,4 +8,4 @@
{{ partial "head/opengraph" . }}
{{ .Hugo.Generator }}
{{ hugo.Generator }}

View file

@ -25,7 +25,7 @@
{{ end }}
<div class='paper'>
<div class="row flex-center">
<p>Made with 💛 by <a href="https://vlaservi.ch" target="_blank">Rhyne</a> and some <a href="https://github.com/rhyneav/papercss/graphs/contributors">fantastic contributors</a>!</p>
<p>Made with 💛 by <a href="https://vlaservich.com" target="_blank">Rhyne</a> and some <a href="https://github.com/rhyneav/papercss/graphs/contributors">fantastic contributors</a>!</p>
</div>
</div>
</div>

View file

@ -1,5 +1,8 @@
body {
background-image: url("/img/geometry2.png")
background-image: url("/img/geometry2.png")
}
html.dark body {
background: #41403e;
}
#top {
max-width: 1440px;
@ -31,7 +34,6 @@ img.no-responsive {
}
.to-top .paper-btn {
padding: .6em 1em;
background: #fff;
border-top-left-radius: 185px 160px;
border-top-right-radius: 200px 195px;
border-bottom-right-radius: 160px 195px;

365
docs/static/assets/syntax.css vendored Normal file
View file

@ -0,0 +1,365 @@
/* LineTableTD */
.chroma .lntd {
border: 0;
margin: 0;
padding: 0;
vertical-align: top;
}
/* LineTable */
.chroma .lntable {
border: 0;
border-spacing: 0;
display: block;
margin: 0;
overflow: auto;
padding: 0;
width: auto;
}
/* LineHighlight */
.chroma .hl {
background-color: #ffc;
display: block;
width: 100%;
}
/* LineNumbersTable */
.chroma .lnt {color: #7f7f7f;
margin-right: 0.4em;
padding: 0 0.4em;
}
/* LineNumbers */
.chroma .ln {color: #7f7f7f;
margin-right: 0.4em;
padding: 0 0.4em;
}
/* Keyword */
.chroma .k {
color: #a2f;
font-weight: bold;
}
/* KeywordConstant */
.chroma .kc {
color: #a2f;
font-weight: bold;
}
/* KeywordDeclaration */
.chroma .kd {
color: #a2f;
font-weight: bold;
}
/* KeywordNamespace */
.chroma .kn {
color: #a2f;
font-weight: bold;
}
/* KeywordPseudo */
.chroma .kp {
color: #a2f;
}
/* KeywordReserved */
.chroma .kr {
color: #a2f;
font-weight: bold;
}
/* KeywordType */
.chroma .kt {
color: #0b0;
font-weight: bold;
}
/* NameAttribute */
.chroma .na {
color: #b44;
}
/* NameBuiltin */
.chroma .nb {
color: #a2f;
}
/* NameClass */
.chroma .nc {
color: #00f;
}
/* NameConstant */
.chroma .no {
color: #800;
}
/* NameDecorator */
.chroma .nd {
color: #a2f;
}
/* NameEntity */
.chroma .ni {
color: #999;
font-weight: bold;
}
/* NameException */
.chroma .ne {
color: #d2413a;
font-weight: bold;
}
/* NameFunction */
.chroma .nf {
color: #00a000;
}
/* NameLabel */
.chroma .nl {
color: #a0a000;
}
/* NameNamespace */
.chroma .nn {
color: #00f;
font-weight: bold;
}
/* NameTag */
.chroma .nt {
color: #008000;
font-weight: bold;
}
/* NameVariable */
.chroma .nv {
color: #b8860b;
}
/* LiteralString */
.chroma .s {
color: #b44;
}
/* LiteralStringAffix */
.chroma .sa {
color: #b44;
}
/* LiteralStringBacktick */
.chroma .sb {
color: #b44;
}
/* LiteralStringChar */
.chroma .sc {
color: #b44;
}
/* LiteralStringDelimiter */
.chroma .dl {
color: #b44;
}
/* LiteralStringDoc */
.chroma .sd {
color: #b44;
font-style: italic;
}
/* LiteralStringDouble */
.chroma .s2 {
color: #b44;
}
/* LiteralStringEscape */
.chroma .se {
color: #b62;
font-weight: bold;
}
/* LiteralStringHeredoc */
.chroma .sh {
color: #b44;
}
/* LiteralStringInterpol */
.chroma .si {
color: #b68;
font-weight: bold;
}
/* LiteralStringOther */
.chroma .sx {
color: #008000;
}
/* LiteralStringRegex */
.chroma .sr {
color: #b68;
}
/* LiteralStringSingle */
.chroma .s1 {
color: #b44;
}
/* LiteralStringSymbol */
.chroma .ss {
color: #b8860b;
}
/* LiteralNumber */
.chroma .m {
color: #666;
}
/* LiteralNumberBin */
.chroma .mb {
color: #666;
}
/* LiteralNumberFloat */
.chroma .mf {
color: #666;
}
/* LiteralNumberHex */
.chroma .mh {
color: #666;
}
/* LiteralNumberInteger */
.chroma .mi {
color: #666;
}
/* LiteralNumberIntegerLong */
.chroma .il {
color: #666;
}
/* LiteralNumberOct */
.chroma .mo {
color: #666;
}
/* Operator */
.chroma .o {
color: #666;
}
/* OperatorWord */
.chroma .ow {
color: #a2f;
font-weight: bold;
}
/* Comment */
.chroma .c {
color: #080;
font-style: italic;
}
/* CommentHashbang */
.chroma .ch {
color: #080;
font-style: italic;
}
/* CommentMultiline */
.chroma .cm {
color: #080;
font-style: italic;
}
/* CommentSingle */
.chroma .c1 {
color: #080;
font-style: italic;
}
/* CommentSpecial */
.chroma .cs {
color: #080;
font-weight: bold;
}
/* CommentPreproc */
.chroma .cp {
color: #080;
}
/* CommentPreprocFile */
.chroma .cpf {
color: #080;
}
/* GenericDeleted */
.chroma .gd {
color: #a00000;
}
/* GenericEmph */
.chroma .ge {
font-style: italic;
}
/* GenericError */
.chroma .gr {
color: #f00;
}
/* GenericHeading */
.chroma .gh {
color: #000080;
font-weight: bold;
}
/* GenericInserted */
.chroma .gi {
color: #00a000;
}
/* GenericOutput */
.chroma .go {
color: #888;
}
/* GenericPrompt */
.chroma .gp {
color: #000080;
font-weight: bold;
}
/* GenericStrong */
.chroma .gs {
font-weight: bold;
}
/* GenericSubheading */
.chroma .gu {
color: #800080;
font-weight: bold;
}
/* GenericTraceback */
.chroma .gt {
color: #04d;
}
/* GenericUnderline */
.chroma .gl {
text-decoration: underline;
}
/* TextWhitespace */
.chroma .w {
color: #bbb;
}

View file

@ -1,71 +0,0 @@
'use strict';
const gulp = require('gulp'),
sass = require('gulp-sass'),
cleanCSS = require('gulp-clean-css'),
rename = require('gulp-rename'),
exec = require('child_process').execFile,
optional = require('optional'),
hugo = optional('hugo-bin'),
gulpStylelint = optional('gulp-stylelint'),
autoprefixer = require('gulp-autoprefixer');
gulp.task('sass', function() {
gulp.src('src/**/*.scss')
.pipe(sass.sync().on('error', sass.logError))
.pipe(autoprefixer())
.pipe(cleanCSS({format: 'beautify'}))
.pipe(rename('paper.css'))
.pipe(gulp.dest('dist'))
.pipe(gulp.dest('docs/static/assets'));
});
gulp.task('watch', function () {
gulp.watch('src/**/*.scss', ['sass']);
});
gulp.task('hugo-server', function (cb) {
let hugo_process = exec(
hugo, ['server', '--source=docs', '--disableFastRender'],
function (err, stdout, stderr) {
console.log(stderr);
return err ? cb(err) : cb();
}
);
hugo_process.stdout.pipe(process.stdout);
return hugo_process;
})
gulp.task('hugo-build', function (cb) {
let hugo_process = exec(
hugo, ['--source=docs'],
function (err, stdout, stderr) {
console.log(stderr);
return err ? cb(err) : cb();
}
);
hugo_process.stdout.pipe(process.stdout);
return hugo_process;
})
gulp.task('minify-css', () => {
return gulp.src('src/**/*.scss')
.pipe(sass({outputStyle: 'compressed'}).on('error', sass.logError))
.pipe(autoprefixer())
.pipe(rename('paper.min.css'))
.pipe(gulp.dest('dist'))
.pipe(gulp.dest('docs/static/assets'));
});
gulp.task('lint-css', function() {
return gulp.src('src/**/*.scss')
.pipe(gulpStylelint({
reporters: [
{formatter: 'string', console: true}
]
}));
})
gulp.task('default', ['sass','watch','hugo-server']);
gulp.task('build', ['sass','minify-css','hugo-build']);
gulp.task('postinstall', ['sass','minify-css']);

View file

@ -1 +0,0 @@
@call tests\build\scripts\run_jake -f tests\build\scripts\build.Jakefile.js %*

View file

@ -1,2 +0,0 @@
#!/bin/sh
. tests/build/scripts/run_jake.sh -f tests/build/scripts/build.Jakefile.js $*

View file

@ -1,6 +1,2 @@
[build]
publish = "public"
command = "hugo --source=docs"
[build.environment]
HUGO_VERSION = "0.30"

21038
package-lock.json generated

File diff suppressed because it is too large Load diff

View file

@ -1,14 +1,18 @@
{
"name": "papercss",
"version": "1.6.0",
"version": "1.9.2",
"description": "The less formal CSS framework.",
"main": "index.js",
"main": "dist/paper.css",
"scripts": {
"start": "node node_modules/gulp/bin/gulp.js",
"build": "node node_modules/gulp/bin/gulp.js build",
"test": "echo \"Error: no test specified\" && exit 1",
"postinstall": "gulp postinstall",
"stylelint": "node_modules/stylelint/bin/stylelint.js 'src/**/*.scss'"
"build": "npm run css:build && npm run hugo:build",
"css:build": "node ./build/build.js",
"dev": "concurrently --kill-others \"npm run dev:hot-reload\" \"npm run hugo:serve\"",
"dev:hot-reload": "node ./build/hot-reload.js",
"hugo:build": "hugo -D --source=docs",
"hugo:serve": "hugo server --source=docs --disableFastRender",
"lint": "npm run stylelint",
"start": "npm run hugo:serve",
"stylelint": "stylelint src/**/*.scss"
},
"repository": {
"type": "git",
@ -20,58 +24,25 @@
"url": "https://github.com/papercss/papercss/issues"
},
"homepage": "https://www.getpapercss.com",
"dependencies": {
"gulp": "3.9.1",
"gulp-autoprefixer": "^6.0.0",
"gulp-clean-css": "3.9.0",
"gulp-connect": "5.0.0",
"gulp-plumber": "1.1.0",
"gulp-rename": "1.2.2",
"gulp-sass": "^3.1.0",
"optional": "^0.1.4"
},
"dependencies": {},
"devDependencies": {
"browserify": "^14.1.0",
"autoprefixer": "^9.8.6",
"chai": "^4.1.2",
"gulp-less": "3.3.2",
"gulp-plumber": "1.1.0",
"gulp-rename": "1.2.2",
"gulp-sass": "^3.1.0",
"gulp-stylelint": "6.0.0",
"gulp-watch-less": "1.0.1",
"http-server": "^0.9.0",
"hugo-bin": "^0.17.0",
"install": "0.10.1",
"jake": "^8.0.15",
"jshint": "^2.9.4",
"karma": "^1.7.1",
"karma-chai": "^0.1.0",
"karma-commonjs": "1.0.0",
"karma-firefox-launcher": "^1.0.0",
"karma-mocha": "^1.3.0",
"karma-node-modules-middleware": "^1.0.1",
"karma-quixote": "^1.0.0",
"karma-requirejs": "^1.1.0",
"mocha": "^4.0.1",
"nodemon": "^1.11.0",
"npm": "^5.3.0",
"object-merge": "^2.5.1",
"os": "^0.1.1",
"chalk": "^4.1.0",
"chokidar": "^3.4.2",
"concurrently": "^5.3.0",
"cssnano": "^4.1.10",
"hugo-bin": "^0.62.3",
"postcss": "^7.0.32",
"pre-commit": "^1.2.2",
"procfile": "^0.1.1",
"quixote": "^0.14.0",
"request": "^2.83.0",
"requirejs": "^2.3.5",
"semver": "^5.3.0",
"shelljs": "^0.7.6",
"simplebuild-jshint": "^1.3.0",
"simplebuild-karma": "^1.0.0",
"stylelint": "8.4.0",
"stylelint-config-sass-guidelines": "4.0.1",
"stylelint-config-standard": "18.0.0",
"stylelint-order": "0.8.0",
"stylelint-scss": "2.2.0",
"webpack-dev-server": "2.7.1"
"rimraf": "^3.0.2",
"sass": "^1.26.10",
"stylelint": "^13.7.2",
"stylelint-config-sass-guidelines": "^7.1.0",
"stylelint-config-standard": "^20.0.0",
"stylelint-order": "^4.1.0",
"stylelint-scss": "^3.18.0",
"write": "^2.0.0"
},
"pre-commit": [
"stylelint"

View file

@ -3,13 +3,17 @@
flex-direction: column;
&:nth-of-type(1) {
border-top: 1px solid $muted-light;
@include color('border-top-color', 'muted-light');
border-top-style: solid;
border-top-width: 1px;
}
.collapsible-body {
@include color('border-bottom-color', 'muted-light');
@include color('background-color', 'white-dark-light-80');
@include transition;
background-color: lighten($white-dark, 80%);
border-bottom: 1px solid $muted-light;
border-bottom-style: solid;
border-bottom-width: 1px;
margin: 0;
max-height: 0;
opacity: 0;
@ -17,11 +21,11 @@
padding: 0 0.75rem;
}
input {
> input {
display: none;
&:checked + label {
color: $primary;
@include color('color', 'primary');
}
&[id^='collapsible']:checked~div.collapsible-body {
@ -32,9 +36,11 @@
}
}
label {
border-bottom: 1px solid $muted-light;
color: $primary;
> label {
@include color('color', 'primary');
@include color('border-bottom-color', 'muted-light');
border-bottom-style: solid;
border-bottom-width: 1px;
display: inline-block;
font-weight: 600;
margin: 0 0 -1px;
@ -42,7 +48,7 @@
text-align: center;
&:hover {
color: $muted;
@include color('color', 'muted');
cursor: pointer;
}
}

View file

@ -1,16 +1,18 @@
@mixin btn-close-color($base-color) {
color: lighten($base-color, 10%);
@mixin btn-close-color($base-color-name) {
@include color('color', #{$base-color-name}-text);
&:hover,
&:active,
&:focus {
color: darken($base-color, 10%);
@include color('color', #{$base-color-name}-dark);
}
}
.alert {
@include color('border-color', 'primary');
@include border-style();
border: 2px solid $primary;
border-style: solid;
border-width: 2px;
margin-bottom: 20px;
padding: 15px;
width: 100%;
@ -25,20 +27,20 @@
.btn-close {
@include transition;
@include btn-close-color($primary);
@include btn-close-color(primary);
cursor: pointer;
margin-left: 0.75rem;
}
}
@each $colorName, $color, $color-light in $colors {
.alert-#{$colorName} {
background-color: $color-light;
border-color: $color;
color: $color;
@each $color-name, $color, $color-light, $color-text in $colors {
.alert-#{$color-name} {
@include color('color', #{$color-name}-text);
@include color('background-color', #{$color-name}-light);
@include color('border-color', $color-name);
.btn-close {
@include btn-close-color($color);
@include btn-close-color($color-name);
}
}
}

View file

@ -4,15 +4,15 @@ article {
}
.article-meta {
color: $muted;
@include color(color, 'muted-text');
font-size: 15px;
a {
@include color(color, 'muted-text');
background-image: none;
color: $muted-text;
&:hover {
color: $light-dark;
@include color(color, 'light-dark');
}
}
}

View file

@ -1,9 +1,10 @@
.badge {
@include border-style();
background-color: $muted;
border: 2px solid $primary;
@include color('color', 'white');
@include color('background-color', 'muted');
@include color('border-color', 'primary');
border: 2px solid;
border-color: transparent;
color: $white;
display: inline-block;
font-size: 75%;
font-weight: 700;
@ -16,6 +17,6 @@
@each $colorName, $color in $colors {
.badge.#{$colorName} {
background-color: $color;
@include color('background-color', #{$colorName});
}
}

View file

@ -0,0 +1,28 @@
ul.breadcrumb {
list-style: none;
padding: 10px 16px;
li {
display: inline;
font-size: 20px;
&::before {
content: '';
}
a {
@include color('color', 'secondary');
background-image: none;
text-decoration: none;
&:hover {
text-decoration: underline;
}
}
}
li + li::before {
content: '/\00a0';
padding: 8px;
}
}

View file

@ -4,12 +4,15 @@ button,
@include border-style();
@include shadow();
@include transition();
@include color('color', 'primary');
@include color('border-color', 'primary');
@include color('background-color', 'main-background');
align-self: center;
background: transparent;
border: 2px solid $primary;
color: $primary;
background-image: none;
border-style: solid;
border-width: 2px;
cursor: pointer;
display: inline;
display: inline-block;
font-size: 1rem;
outline: none;
padding: 0.75rem;
@ -43,7 +46,9 @@ button,
}
&:focus {
border: 2px solid $secondary;
@include color('border-color', 'secondary');
border-style: solid;
border-width: 2px;
box-shadow: 2px 8px 4px -6px hsla(0, 0%, 0%, 0.3);
}
@ -60,6 +65,7 @@ button,
}
a {
@include color('color', 'secondary');
background-image: linear-gradient(5deg, transparent 65%, $secondary 80%, transparent 90%), linear-gradient(165deg, transparent 5%, $secondary 15%, transparent 25%), linear-gradient(165deg, transparent 45%, $secondary 55%, transparent 65%), linear-gradient(15deg, transparent 25%, $secondary 35%, transparent 50%);
background-position: 0 90%;
background-repeat: repeat-x;
@ -67,25 +73,38 @@ a {
text-decoration: none;
&:visited {
color: $primary;
@include color('color', 'primary');
text-decoration: none;
}
}
@each $colorName, $color, $color-light, $color-text in $colors {
.alert-#{$colorName} {
background-color: $color-light;
border-color: $color;
color: $color;
}
button.btn-#{$colorName},
.paper-btn.btn-#{$colorName},
[type='button'].btn-#{$colorName} {
background-color: $color-light;
border-color: $color;
color: $color-text;
@include color('color', #{$colorName}-text);
@include color('background-color', #{$colorName}-light);
@include color('border-color', #{$colorName});
&:hover {
&:active {
background-color: darken($color-light, 10%);
}
}
}
}
@each $colorName, $color, $color-light, $color-text in $colors {
button.btn-#{$colorName}-outline,
.paper-btn.btn-#{$colorName}-outline,
[type='button'].btn-#{$colorName}-outline {
@include color('background-color', main-background);
@include color('color', #{$colorName});
@include color('border-color', #{$colorName});
&:hover {
background-color: $color-light;
}
&:hover {
&:active {

View file

@ -1,7 +1,9 @@
.card {
@include shadow;
@include color('border-color', 'muted-light');
backface-visibility: hidden;
border: 2px solid $muted-light;
border-style: solid;
border-width: 2px;
display: flex;
flex-direction: column;
position: relative;
@ -14,16 +16,19 @@
.card-header,
.card-footer {
background-color: $white-dark;
@include color('background-color', 'white-dark');
@include color('border-color', 'muted-light');
padding: 0.75rem 1.25rem;
}
.card-header {
border-bottom: 2px solid $muted-light;
border-bottom-style: solid;
border-bottom-width: 2px;
}
.card-footer {
border-top: 2px solid $muted-light;
border-top-style: solid;
border-top-width: 2px;
}
.card-body {

View file

@ -1,20 +1,24 @@
input,
select,
textarea {
@include color('color', 'primary');
@include color('border-color', 'primary');
background: transparent;
border: 2px solid $primary;
border-bottom-left-radius: 15px 255px;
border-bottom-right-radius: 225px 15px;
border-style: solid;
border-top-left-radius: 255px 15px;
border-top-right-radius: 15px 225px;
color: $primary;
border-width: 2px;
display: block;
font-size: 1rem;
outline: none;
padding: 0.5rem;
&:focus {
border: 2px solid $secondary;
@include color('border-color', 'secondary');
border-style: solid;
border-width: 2px;
}
&.disabled,
@ -23,6 +27,10 @@ textarea {
}
}
select {
height: 2.35rem;
}
.disabled {
cursor: not-allowed;
opacity: 0.5;
@ -60,9 +68,9 @@ textarea {
/* the basic, unchecked style */
input {
border: 0;
display: none;
height: 1px;
margin: -1px;
opacity: 0;
overflow: hidden;
padding: 0;
position: absolute;
@ -72,7 +80,9 @@ textarea {
display: block;
&::before {
border: 2px solid $primary;
@include color('border-color', 'primary');
border-style: solid;
border-width: 2px;
content: '';
display: inline-block;
height: 1rem;
@ -115,6 +125,316 @@ textarea {
}
}
}
.paper-switch-label,
.paper-switch-2-label {
cursor: pointer;
float: left;
}
.paper-switch-label {
margin: -6px 10px 0 0;
}
.paper-switch-2-label {
margin: 0 10px 0 0;
}
.paper-switch,
.paper-switch-2 {
display: block;
float: left;
margin: 0 10px 0 0;
position: relative;
input {
height: 0;
opacity: 0;
width: 0;
&:checked + .paper-switch-slider {
@include color('background-color', 'success-light');
}
&:checked + .paper-switch-slider::before {
transform: translateX(26px);
}
&:focus + .paper-switch-slider {
box-shadow: 0 0 3px $secondary;
}
}
.paper-switch-slider {
@include color('border-color', 'primary');
border-bottom-left-radius: 15px 255px;
border-bottom-right-radius: 225px 15px;
border-style: solid;
border-top-left-radius: 255px 15px;
border-top-right-radius: 15px 225px;
border-width: 2px;
bottom: 0;
cursor: pointer;
left: 0;
position: absolute;
right: 0;
top: 0;
transition: 0.4s;
&::before {
@include color('background', 'secondary');
border-bottom-left-radius: 15px 255px;
border-bottom-right-radius: 225px 15px;
border-top-left-radius: 255px 15px;
border-top-right-radius: 15px 225px;
content: '';
left: 4px;
position: absolute;
transition: 0.4s;
}
}
.paper-switch-slider.round {
@include color('border-color', 'primary');
border-bottom-left-radius: 0.7rem 1rem;
border-bottom-right-radius: 1rem 0.9rem;
border-style: solid;
border-top-left-radius: 1rem 1rem;
border-top-right-radius: 1rem 0.6rem;
border-width: 2px;
&::before {
background: url("data:image/svg+xml,%3Csvg%20xmlns%3D'http%3A//www.w3.org/2000/svg'%20viewBox%3D'0%200%20100%20100'%3E%3Cpath%20fill%3D'%230071de'%20d%3D'M49.346,46.341c-3.79-2.005,3.698-10.294,7.984-8.89%20c8.713,2.852,4.352,20.922-4.901,20.269c-4.684-0.33-12.616-7.405-14.38-11.818c-2.375-5.938,7.208-11.688,11.624-13.837%20c9.078-4.42,18.403-3.503,22.784,6.651c4.049,9.378,6.206,28.09-1.462,36.276c-7.091,7.567-24.673,2.277-32.357-1.079%20c-11.474-5.01-24.54-19.124-21.738-32.758c3.958-19.263,28.856-28.248,46.044-23.244c20.693,6.025,22.012,36.268,16.246,52.826%20c-5.267,15.118-17.03,26.26-33.603,21.938c-11.054-2.883-20.984-10.949-28.809-18.908C9.236,66.096,2.704,57.597,6.01,46.371%20c3.059-10.385,12.719-20.155,20.892-26.604C40.809,8.788,58.615,1.851,75.058,12.031c9.289,5.749,16.787,16.361,18.284,27.262%20c0.643,4.698,0.646,10.775-3.811,13.746'%3E%3C/path%3E%3C/svg%3E") left center no-repeat;
border-bottom-left-radius: 0.7rem 1rem;
border-bottom-right-radius: 1rem 0.9rem;
border-top-left-radius: 1rem 1rem;
border-top-right-radius: 1rem 0.6rem;
left: 4px;
}
}
}
.paper-switch {
height: 12px;
width: 60px;
.paper-switch-slider {
&::before {
bottom: -6px;
height: 20px;
width: 20px;
}
}
.paper-switch-slider.round {
&::before {
bottom: -7px;
height: 23px;
width: 23px;
}
}
}
.paper-switch-2 {
height: 22px;
width: 50px;
.paper-switch-slider {
&::before {
bottom: 2px;
height: 14px;
width: 14px;
}
}
.paper-switch-slider.round {
&::before {
bottom: 2px;
height: 14px;
width: 14px;
}
}
}
.paper-switch-tile {
cursor: pointer;
display: block;
float: left;
height: 80px;
margin: 40px 0 0 40px;
perspective: 1000px;
position: relative;
transform: translate(-50%, -50%);
transform-style: preserve-3d;
width: 80px;
&:hover {
.paper-switch-tile-card {
box-shadow: 2px 8px 4px -5px rgba(0, 0, 0, 0.2);
transform: rotateX(30deg);
}
&:checked + .paper-switch-tile-card {
background-color: transparent;
box-shadow: 0 10px 15px -15px rgba(0, 0, 0, 0.9);
transform: rotateX(150deg);
}
}
input {
display: none;
&:checked + .paper-switch-tile-card {
transform: rotateX(180deg);
}
}
}
.paper-switch-tile-card {
background-color: transparent;
border-color: transparent;
height: 100%;
position: relative;
transform-style: preserve-3d;
transition: all 600ms;
width: 100%;
div {
backface-visibility: hidden;
box-shadow: 2px 8px 8px -5px rgba(0, 0, 0, 0.3);
height: 100%;
line-height: 70px;
position: absolute;
text-align: center;
width: 100%;
}
.paper-switch-tile-card-back {
transform: rotateX(180deg);
}
}
input[type='range'] {
appearance: none;
border-width: 0;
padding: 0;
/* For Chromium */
&::-webkit-slider-runnable-track {
@include color('background', 'secondary');
@include color('border-color', 'primary');
border-radius: 18px;
border-style: solid;
border-width: 1px;
box-shadow: 1px 1px 1px #000, 0 0 1px #0d0d0d;
cursor: pointer;
height: 8px;
margin: 10px 0;
width: 100%;
}
&::-webkit-slider-thumb {
@include color('background', 'white');
@include color('border-color', 'primary');
appearance: none;
border-bottom-left-radius: 0.7rem 1rem;
border-bottom-right-radius: 1rem 0.9rem;
border-style: solid;
border-top-left-radius: 1rem 1rem;
border-top-right-radius: 1rem 0.6rem;
border-width: 1px;
box-shadow: 1px 1px 1px #000, 0 0 1px #0d0d0d;
cursor: pointer;
height: 36px;
margin-top: -14px;
width: 16px;
}
/* For Mozilla Firefox */
&::-moz-range-track {
@include color('background', 'secondary');
@include color('border-color', 'primary');
border-radius: 18px;
box-shadow: 1px 1px 1px #000, 0 0 1px #0d0d0d;
cursor: pointer;
height: 8px;
width: 100%;
}
&::-moz-range-thumb {
@include color('background', 'white');
@include color('border-color', 'primary');
border-bottom-left-radius: 0.7rem 1rem;
border-bottom-right-radius: 1rem 0.9rem;
border-style: solid;
border-top-left-radius: 1rem 1rem;
border-top-right-radius: 1rem 0.6rem;
border-width: 1px;
box-shadow: 1px 1px 1px #000, 0 0 1px #0d0d0d;
cursor: pointer;
height: 36px;
width: 16px;
}
/* For IE */
&::-ms-track {
background: transparent;
border-color: transparent;
border-width: 16px 0;
color: transparent;
cursor: pointer;
height: 8px;
width: 100%;
}
&::-ms-fill-lower,
&::-ms-fill-upper {
@include color('background', 'secondary');
@include color('border-color', 'primary');
border-radius: 18px;
border-style: solid;
border-width: 1px;
box-shadow: 1px 1px 1px #000, 0 0 1px #0d0d0d;
}
&::-ms-thumb {
@include color('background', 'white');
@include color('border-color', 'primary');
border: 1px solid $primary;
border-bottom-left-radius: 0.7rem 1rem;
border-bottom-right-radius: 1rem 0.9rem;
border-style: solid;
border-top-left-radius: 1rem 1rem;
border-top-right-radius: 1rem 0.6rem;
border-width: 1px;
box-shadow: 1px 1px 1px #000, 0 0 1px #0d0d0d;
cursor: pointer;
height: 36px;
width: 16px;
}
}
}
fieldset.form-group {

View file

@ -11,7 +11,7 @@
top: 0;
visibility: hidden;
word-wrap: break-word;
z-index: 12;
z-index: 200;
// modal background
&-bg {
@ -24,10 +24,13 @@
}
.modal-body {
@include color('color', 'primary');
@include color('background', 'main-background');
@include color('border-color', 'muted-light');
@include transition;
backface-visibility: hidden;
background: $white;
border: 2px solid $muted-light;
border: 2px solid;
left: 50%;
padding: 1.25rem;
position: absolute;
@ -41,8 +44,8 @@
}
.btn-close {
@include color('color', 'primary-light');
@include transition;
color: $primary-light;
cursor: pointer;
font-size: 30px;
height: 1.1rem;
@ -55,7 +58,7 @@
&:hover,
&:active,
&:focus {
color: $primary;
@include color('color', 'primary');
}
}
@ -67,7 +70,7 @@
h5,
.modal-subtitle {
color: $secondary;
@include color('color', 'secondary');
margin-bottom: 0.5rem;
margin-top: 0;
}
@ -84,7 +87,7 @@
}
.paper-btn {
background: $white;
@include color('background', 'main-background');
display: inline-block;
text-decoration: none;
}
@ -101,7 +104,7 @@
&:hover,
&:focus,
&:visited {
color: $primary;
@include color('color', 'primary');
text-decoration: none;
}
}

View file

@ -1,5 +1,5 @@
nav {
background-color: $main-background;
@include color('background-color', 'main-background');
display: flex;
padding: 0.3rem;
position: relative;
@ -13,17 +13,20 @@ nav {
.bar1,
.bar2,
.bar3 {
background-color: $primary;
border-bottom: 5px solid $primary;
@include color('background-color', 'primary');
@include color('border-color', 'primary');
@include color('color', 'primary');
border-bottom-left-radius: 15px 5px;
border-bottom-right-radius: 15px 3px;
color: $primary;
border-bottom-style: solid;
border-bottom-width: 5px;
margin: 6px 0;
transition: 0.4s;
width: 2rem;
}
.collapsible input[id^=collapsible]:checked + button {
.collapsible input[id^=collapsible]:checked + button, // Leaving for backwards compatibility. See docs for proper usage
.collapsible input[id^=collapsible]:checked + label {
.bar1 {
transform: rotate(-45deg) translate(-9px, 7px);
}
@ -69,16 +72,20 @@ nav {
}
a {
@include color('color', 'primary');
@include color('border-bottom-color', 'primary');
background-image: none;
border-bottom: 5px solid $primary;
border-bottom-left-radius: 15px 3px;
border-bottom-right-radius: 15px 5px;
color: $primary;
border-bottom-style: solid;
border-bottom-width: 5px;
padding-bottom: 0.1rem;
}
a:hover {
border-bottom: 5px solid $primary-light;
@include color('border-color', 'primary-light');
border-bottom-style: solid;
border-bottom-width: 5px;
}
ul.inline li a {
@ -101,12 +108,18 @@ nav {
h3,
h4,
h5,
h6, {
h6 {
margin: 0;
margin-bottom: 0.2rem;
}
}
.collapsible {
@include resp(small) {
width: 100%;
}
}
.collapsible input[id^=collapsible]:checked ~ div.collapsible-body {
margin: 0;
max-height: 960px;
@ -128,12 +141,24 @@ nav {
}
.collapsible label {
border-bottom: 0;
padding: 0;
@include color('border-color', 'primary');
border-bottom-left-radius: 15px 255px;
border-bottom-right-radius: 225px 15px;
border-style: solid;
border-top-left-radius: 255px 15px;
border-top-right-radius: 15px 225px;
border-width: 2px;
}
.collapsible > button {
background-color: $main-background;
// Leaving for backwards compatibility. See docs for proper usage
border: 0;
}
.collapsible > button, // Leaving for backwards compatibility. See docs for proper usage
.collapsible > label {
@include color('background-color', 'main-background');
display: none;
font-size: 0.5rem;
margin-right: 1rem;

View file

@ -10,17 +10,19 @@
&:hover {
&::after {
opacity: 1;
transition: opacity 0.2s ease-out;
transition: opacity 235ms ease-in-out, visibility 0s linear;
visibility: visible;
}
}
// Creating popover::after element
&::after {
@include border-style();
@include transition(opacity);
background: $light-dark;
border: 2px solid $primary;
color: $white;
@include color('background-color', 'light-dark');
@include color('border-color', 'light-dark');
@include color('color', 'primary-inverse');
border-style: solid;
border-width: 2px;
font-size: 0.7em;
left: 50%;
min-width: 80px;
@ -30,6 +32,8 @@
text-align: center;
top: -6px;
transform: translateX(-50%) translateY(-100%);
transition: opacity 235ms ease-in-out, visibility 0s linear 235ms;
visibility: hidden;
}
}

View file

@ -1,6 +1,7 @@
.progress {
@include border-style(5);
border: 2px solid $primary;
@include color('border-color', 'primary');
border: 2px solid;
box-shadow: $shadow-hover;
height: 1.2rem;
overflow: hidden;
@ -9,8 +10,9 @@
.bar {
@include border-style(5);
@include transition;
background-color: $primary-light;
border-right: 2px solid $primary;
@include color('background-color', 'primary-light');
@include color('border-color', 'primary');
border-right: 2px solid;
display: flex;
flex-direction: column;
font-size: 0.6rem;
@ -25,7 +27,7 @@
@each $colorName, $color, $color-light in $colors {
&.#{$colorName} {
background-color: $color-light;
@include color('background-color', #{$colorName}-light);
&.striped {
@include striped-background($color-light);
@ -35,7 +37,7 @@
@for $i from 0 through 100 {
&.w-#{$i} {
width: $i + %;
width: $i * 1%;
}
}

View file

@ -1,26 +1,29 @@
.tabs {
.content {
display: none;
flex-basis: 100%;
padding: 0.75rem 0 0;
}
input {
display: none;
&:checked+label {
border-bottom: solid 3px $secondary;
color: $primary;
&:checked + label {
@include color(color, 'primary');
@include color('border-bottom-color', 'secondary');
border-bottom-style: solid;
border-bottom-width: 3px;
}
@for $num from 1 through 5 {
&[id='tab#{$num}']:checked~div[id='content#{$num}'] {
&[id$='tab#{$num}']:checked~div[id$='content#{$num}'] {
display: block;
}
}
}
label {
color: $primary-light;
@include color('color', primary-light);
display: inline-block;
font-weight: 600;
margin: 0 0 -1px;
@ -28,7 +31,7 @@
text-align: center;
&:hover {
color: $muted;
@include color('color', muted);
cursor: pointer;
}
}

View file

@ -1,24 +1,27 @@
code {
background-color: lighten($primary, 70%);
@include color('color', 'secondary');
@include color('background-color', 'primary-shaded-70');
border-radius: 3px;
color: $secondary;
font-size: 80%;
padding: 2px 4px;
}
kbd {
background-color: $primary;
@include color('color', 'primary-inverse');
@include color('background-color', 'primary');
border-radius: 3px;
color: $white;
font-size: 80%;
padding: 2px 4px;
}
pre {
background-color: lighten($primary, 73%);
border: 1px solid lighten($primary, 50%);
@include color('color', 'inverse-primary');
@include color('background-color', 'primary-shaded-70');
@include color('border-color', 'primary-shaded-50');
border-radius: 3px;
color: $primary;
border-style: solid;
border-width: 1px;
display: block;
font-size: 80%;
line-height: 1.5;
@ -29,8 +32,8 @@ pre {
word-wrap: break-word;
code {
@include color('color', 'inverse-primary');
background: transparent;
color: inherit;
display: block;
font-size: inherit;
padding: initial;

View file

@ -1,5 +1,5 @@
html {
color: $font-color;
@include color('color', 'primary');
font-family: $body-font, sans-serif;
font-size: $global-font-size;
}
@ -7,6 +7,7 @@ html {
p,
a,
button,
li,
table,
thead,
tbody,

View file

@ -1,6 +1,8 @@
img {
@include border-style();
border: 2px solid $primary;
@include color('border-color', 'primary');
border-style: solid;
border-width: 2px;
display: block;
height: auto;
max-width: 100%;

View file

@ -29,7 +29,7 @@ table {
}
&.table-hover tbody tr:hover {
color: $secondary;
@include color('color', 'secondary');
}
&.table-alternating tbody tr:nth-of-type(even) {

View file

@ -2,40 +2,260 @@
Global PaperCSS Config
*/
// The src for fonts (false to disable)
$font-src: 'https://fonts.googleapis.com/css?family=Neucha|Patrick+Hand+SC&display=swap' !default;
// Imports
@import url('https://fonts.googleapis.com/css?family=Neucha|Patrick+Hand+SC');
@if $font-src {
@import url($font-src);
}
// Set theme colors
$primary: #41403e !default;
$secondary: #0071de !default;
$secondary: #0b74d5 !default;
$success: #86a361 !default;
$warning: #ddcd45 !default;
$danger: #a7342d !default;
$muted: #868e96 !default;
$primary-light: lighten($primary, 50%) !default;
$secondary-light: lighten($secondary, 50%) !default;
$success-light: lighten($success, 30%) !default;
$primary-light: lighten($primary, 55%) !default;
$secondary-light: lighten($secondary, 48%) !default;
$success-light: lighten($success, 32%) !default;
$warning-light: lighten($warning, 30%) !default;
$danger-light: lighten($danger, 45%) !default;
$muted-light: lighten($muted, 35%) !default;
$primary-dark: darken($primary, 50%) !default;
$secondary-dark: darken($secondary, 50%) !default;
$success-dark: darken($success, 30%) !default;
$warning-dark: darken($warning, 30%) !default;
$danger-dark: darken($danger, 45%) !default;
$muted-dark: darken($muted, 35%) !default;
$primary-light-10: lighten($primary, 10%) !default;
$secondary-light-10: lighten($secondary, 10%) !default;
$success-light-10: lighten($success, 10%) !default;
$warning-light-10: lighten($warning, 10%) !default;
$danger-light-10: lighten($danger, 10%) !default;
$muted-light-10: lighten($muted, 10%) !default;
$primary-dark-10: darken($primary, 10%) !default;
$secondary-dark-10: darken($secondary, 10%) !default;
$success-dark-10: darken($success, 23%) !default;
$warning-dark-10: darken($warning, 30%) !default;
$danger-dark-10: darken($danger, 10%) !default;
$muted-dark-10: darken($muted, 10%) !default;
$primary-shaded-70: lighten($primary, 70%) !default;
$primary-shaded-50: lighten($primary, 50%) !default;
$white-dark: rgba(#000, 0.03) !default;
$white-dark-light-80: lighten($white-dark, 80%) !default;
$light-dark: rgba(#000, 0.7) !default;
$white: rgba(#fff, 1) !default;
$main-background: rgba(#fff, 1) !default;
$black: rgba(#000, 1) !default;
$main-background-light: lighten($main-background, 50%) !default;
$primary-text: #fff !default;
$secondary-text: $primary !default;
$success-text: $primary !default;
$warning-text: $primary !default;
$danger-text: $primary !default;
$muted-text: $primary !default;
$primary-text: $primary-dark-10 !default;
$secondary-text: $secondary-dark-10 !default;
$success-text: $success-dark-10 !default;
$warning-text: $warning-dark-10 !default;
$danger-text: $danger-dark-10 !default;
$muted-text: $muted-dark-10 !default;
$shadow-color-regular: hsla(0, 0, 0%, 0.2) !default;
$shadow-color-hover: hsla(0, 0, 0%, 0.3) !default;
$shadow-color-regular: hsla(0, 0%, 0%, 0.2) !default;
$shadow-color-hover: hsla(0, 0%, 0%, 0.3) !default;
$primary-inverse: #fff !default;
// Set dark theme colors
$dark-primary: #fff !default;
$dark-secondary: #5595ce !default;
$dark-success: #70c272 !default;
$dark-warning: #d4c252 !default;
$dark-danger: #df4c57 !default;
$dark-muted: #868e96 !default;
$dark-primary-light: lighten($dark-primary, 5%) !default;
$dark-secondary-light: lighten($dark-secondary, 5%) !default;
$dark-success-light: lighten($dark-success, 5%) !default;
$dark-warning-light: lighten($dark-warning, 5%) !default;
$dark-danger-light: lighten($dark-danger, 5%) !default;
$dark-muted-light: lighten($dark-muted, 5%) !default;
$dark-primary-dark: darken($dark-primary, 50%) !default;
$dark-secondary-dark: darken($dark-secondary, 30%) !default;
$dark-success-dark: darken($dark-success, 35%) !default;
$dark-warning-dark: darken($dark-warning, 30%) !default;
$dark-danger-dark: darken($dark-danger, 30%) !default;
$dark-muted-dark: darken($dark-muted, 35%) !default;
$dark-primary-light-10: lighten($dark-primary, 10%) !default;
$dark-secondary-light-10: lighten($dark-secondary, 10%) !default;
$dark-success-light-10: lighten($dark-success, 10%) !default;
$dark-warning-light-10: lighten($dark-warning, 10%) !default;
$dark-danger-light-10: lighten($dark-danger, 10%) !default;
$dark-muted-light-10: lighten($dark-muted, 10%) !default;
$dark-primary-dark-10: darken($dark-primary, 10%) !default;
$dark-secondary-dark-10: darken($dark-secondary, 10%) !default;
$dark-success-dark-10: darken($dark-success, 10%) !default;
$dark-warning-dark-10: darken($dark-warning, 10%) !default;
$dark-danger-dark-10: darken($dark-danger, 10%) !default;
$dark-muted-dark-10: darken($dark-muted, 10%) !default;
$dark-primary-shaded-70: darken($primary, 7%) !default;
$dark-primary-shaded-50: darken($primary, 5%) !default;
$dark-white-dark: rgba(#fff, 0.03) !default;
$dark-white-dark-light-80: lighten($dark-white-dark, 80%) !default;
$dark-light-dark: rgba(#fff, 0.7) !default;
$dark-white: rgba(#fff, 1) !default;
$dark-main-background: rgba($primary, 1) !default;
$dark-main-background-light: lighten($dark-main-background, 50%) !default;
$dark-black: rgba(#000, 1) !default;
$dark-primary-text: $primary !default;
$dark-secondary-text: $dark-secondary-dark !default;
$dark-success-text: $dark-success-dark !default;
$dark-warning-text: $dark-warning-dark !default;
$dark-danger-text: $dark-danger-dark !default;
$dark-muted-text: $dark-muted-light !default;
$dark-shadow-color-regular: hsla(0, 0%, 0%, 0.2) !default;
$dark-shadow-color-hover: hsla(0, 0%, 0%, 0.3) !default;
$dark-primary-inverse: $primary !default;
$theme-map: (
light: (
primary: $primary,
secondary: $secondary,
success: $success,
warning: $warning,
danger: $danger,
muted: $muted,
primary-light: $primary-light,
secondary-light:$secondary-light,
success-light:$success-light,
warning-light:$warning-light,
danger-light:$danger-light,
muted-light:$muted-light,
primary-dark: $primary-dark,
secondary-dark:$secondary-dark,
success-dark:$success-dark,
warning-dark:$warning-dark,
danger-dark:$danger-dark,
muted-dark:$muted-dark,
primary-light-10:$primary-light-10,
secondary-light-10:$secondary-light-10,
success-light-10:$success-light-10,
warning-light-10:$warning-light-10,
danger-light-10:$danger-light-10,
muted-light-10:$muted-light-10,
primary-dark-10:$primary-dark-10,
secondary-dark-10:$secondary-dark-10,
success-dark-10:$success-dark-10,
warning-dark-10:$warning-dark-10,
danger-dark-10:$danger-dark-10,
muted-dark-10:$muted-dark-10,
primary-shaded-50: $primary-shaded-50,
primary-shaded-70: $primary-shaded-70,
white-dark:$white-dark,
white-dark-light-80:$white-dark-light-80,
light-dark:$light-dark,
'white':$white,
main-background: $main-background,
main-background-light: $main-background-light,
'black': $black,
primary-text:$primary-text,
secondary-text:$secondary-text,
success-text:$success-text,
warning-text:$warning-text,
danger-text:$danger-text,
muted-text:$muted-text,
shadow-color-regular: $shadow-color-regular,
shadow-color-hover: $shadow-color-hover,
primary-inverse: $primary-inverse,
),
dark: (
primary: $dark-primary,
secondary: $dark-secondary,
success: $dark-success,
warning: $dark-warning,
danger: $dark-danger,
muted: $dark-muted,
primary-light: $dark-primary-light,
secondary-light:$dark-secondary-light,
success-light:$dark-success-light,
warning-light:$dark-warning-light,
danger-light:$dark-danger-light,
muted-light:$dark-muted-light,
primary-dark: $dark-primary-dark,
secondary-dark:$dark-secondary-dark,
success-dark:$dark-success-dark,
warning-dark:$dark-warning-dark,
danger-dark:$dark-danger-dark,
muted-dark:$dark-muted-dark,
primary-light-10:$dark-primary-light-10,
secondary-light-10:$dark-secondary-light-10,
success-light-10:$dark-success-light-10,
warning-light-10:$dark-warning-light-10,
danger-light-10:$dark-danger-light-10,
muted-light-10:$dark-muted-light-10,
primary-dark-10:$dark-primary-dark-10,
secondary-dark-10:$dark-secondary-dark-10,
success-dark-10:$dark-success-dark-10,
warning-dark-10:$dark-warning-dark-10,
danger-dark-10:$dark-danger-dark-10,
muted-dark-10:$dark-muted-dark-10,
primary-shaded-50: $dark-primary-shaded-50,
primary-shaded-70: $dark-primary-shaded-70,
white-dark:$dark-white-dark,
white-dark-light-80:$dark-white-dark-light-80,
light-dark:$dark-light-dark,
'white':$dark-white,
main-background: $dark-main-background,
main-background-light: $dark-main-background-light,
'black': $dark-black,
primary-text:$dark-primary-text,
secondary-text:$dark-secondary-text,
success-text:$dark-success-text,
warning-text:$dark-warning-text,
danger-text:$dark-danger-text,
muted-text:$dark-muted-text,
shadow-color-regular: $dark-shadow-color-regular,
shadow-color-hover: $dark-shadow-color-hover,
primary-inverse: $dark-primary-inverse,
)
);
html {
@each $var in map-keys(map-get($theme-map, 'light')) {
--#{$var}: #{map-get(map-get($theme-map, 'light'), $var)};
}
}
html.dark {
@each $var in map-keys(map-get($theme-map, 'dark')) {
--#{$var}: #{map-get(map-get($theme-map, 'dark'), $var)};
}
}
@mixin color($property, $varName) {
// IE falls back to light theme always
#{$property}: #{map-get(map-get($theme-map, 'light'), 'primary')};
#{$property}: var(--#{$varName});
}
// Map to set your color names
/* stylelint-disable */
@ -53,11 +273,11 @@ $colors: (primary, $primary, $primary-light, $primary-text),
*/
@each $colorName, $color, $color-light in $colors {
.text-#{$colorName} {
color: $color;
@include color('color',#{$colorName});
}
.background-#{$colorName} {
background-color: $color-light;
@include color('background-color',#{$colorName}-light);
}
}

View file

@ -11,6 +11,30 @@
}
}
.container {
&.container-xs {
max-width: $xsmall-screen;
}
}
.container {
&.container-sm {
max-width: $small-screen;
}
}
.container {
&.container-md {
max-width: $medium-screen;
}
}
.container {
&.container-lg {
max-width: $large-screen;
}
}
.section {
margin-bottom: 2rem;
margin-top: 1rem;
@ -31,7 +55,7 @@ hr {
}
.paper {
background-color: $main-background;
@include color('background-color', 'main-background');
border: 1px solid $primary-light;
box-shadow: -1px 5px 35px -9px hsla(0, 0%, 0%, 0.2);
margin-bottom: 1rem;

View file

@ -25,6 +25,7 @@
@import 'components/alerts';
@import 'components/article';
@import 'components/badges';
@import 'components/breadcrumb';
@import 'components/buttons';
@import 'components/cards';
@import 'components/forms';

View file

@ -1,6 +1,7 @@
.border {
border: 2px solid $primary;
@include color('border-color','primary' );
border-style: solid;
border-width: 2px;
}
.border,
@ -35,11 +36,13 @@
}
.child-borders>* {
border: 2px solid $primary;
@include color('border-color', 'primary');
border-style: solid;
border-width: 2px;
}
.border-white {
border-color: $white;
@include color('border-color', 'white');
}
.border-dotted {
@ -56,6 +59,6 @@
@each $colorName, $color in $colors {
.border-#{$colorName} {
border-color: $color;
@include color('border-color', #{$colorName});
}
}

View file

@ -20,6 +20,12 @@
@include shadow();
}
.child-shadows {
.shadow-none {
box-shadow: none;
}
}
.child-shadows-hover > * {
@include shadow();

View file

@ -1,17 +0,0 @@
// Copyright (c) 2012 Titanium I.T. LLC. All rights reserved. See LICENSE.txt for details.
// A cross-platform mechanism for determining how to run the build.
(function() {
"use strict";
var UNIX_BUILD_COMMAND = "./jake.sh";
var WINDOWS_BUILD_COMMAND = "jake.bat";
var os = require("os");
exports.get = function() {
return os.platform() === "win32" ? WINDOWS_BUILD_COMMAND : UNIX_BUILD_COMMAND;
//return WINDOWS_BUILD_COMMAND;
};
}());

View file

@ -1,79 +0,0 @@
// Karma configuration
// Quixote-specific configuration starts with "QUIXOTE:"
(function() {
"use strict";
var paths = require("./paths.js");
module.exports = function(config) {
config.set({
// base path, that will be used to resolve files and exclude
basePath: '../../..',
// frameworks to use
frameworks: ['mocha', 'commonjs'],
middleware: ['node-modules'],
// list of files / patterns to load in the browser
files: [
'tests/*.js',
'tests/vendor/*.js',
"node_modules/chai/chai.js",
//'tests/**/*.js',
//'node_modules/**/*.js',
//'node_modules/**/*.js',
// QUIXOTE: Serve the CSS file so we can load it in our tests
// Mark it `included: false` so Karma doesn't load it automatically
{ pattern: 'dist/paper.css', included: false }
],
// list of files to exclude
exclude: [],
// preprocess matching files before serving them to the browser
// available preprocessors: https://npmjs.org/browse/keyword/karma-preprocessor
preprocessors: {
'tests/*.js': ['commonjs'],
'tests/vendor/*.js': ['commonjs'],
},
// test results reporter to use
// possible values: 'dots', 'progress', 'junit', 'growl', 'coverage'
reporters: ['dots'],
// web server port
port: 9876,
// enable / disable colors in the output (reporters and logs)
colors: true,
// level of logging
// possible values: config.LOG_DISABLE || config.LOG_ERROR || config.LOG_WARN || config.LOG_INFO || config.LOG_DEBUG
logLevel: config.LOG_INFO,
// enable / disable watching file and executing tests whenever any file changes
autoWatch: false,
// Start these browsers, currently available:
// - Chrome
// - ChromeCanary
// - Firefox
// - Opera
// - Safari (only Mac)
// - PhantomJS
// - IE (only Windows)
browsers: [],
// If browser does not capture in given timeout [ms], kill it
captureTimeout: 60000,
// Continuous Integration mode
// if true, it capture browsers, run tests and exit
singleRun: false
});
};
}());

View file

@ -1,20 +0,0 @@
// Copyright (c) 2015 Titanium I.T. LLC. All rights reserved. For license, see "README" or "LICENSE" file.
// Lists commonly-used directories. They're all relative to the project root.
(function() {
"use strict";
module.exports = {
generatedDir: "generated",
testDir: "generated/test",
distDir: "generated/dist",
clientDistDir: "generated/dist/client",
buildDir: "build",
clientDir: "src",
clientEntryPoint: "src/toggle.js",
clientDistBundle: "generated/dist/client/bundle.js"
};
}());

View file

@ -1,17 +0,0 @@
// Copyright (c) 2014 Titanium I.T. LLC. All rights reserved. For license, see "README" or "LICENSE" file.
(function() {
"use strict";
// Uncomment and modify the following list to cause the build to fail unless these browsers are tested.
// There's no Quixote-specific configuration in this file.
module.exports = [
//"IE 10.0.0 (Windows 7 0.0.0)",
//"Firefox 41.0.0 (Mac OS X 10.10.0)",
//"Chrome 46.0.2490 (Mac OS X 10.10.5)",
//"Safari 9.0.1 (Mac OS X 10.10.5)",
//"Mobile Safari 8.0.0 (iOS 8.4.0)",
//"Chrome Mobile 44.0.2403 (Android 6.0.0)"
];
}());

View file

@ -1,117 +0,0 @@
// Copyright (c) 2012-2014 Titanium I.T. LLC. All rights reserved. See LICENSE.txt for details.
// Main build file. Contains all tasks needed for normal development.
// There's no Quixote-specific configuration in this file.
(function() {
"use strict";
var startTime = Date.now();
var shell = require("../../../node_modules/shelljs/shell.js");
var karma = require("simplebuild-karma");
var browserify = require("../util/browserify_runner.js");
var browsers = require("../config/tested_browsers.js");
var paths = require("../config/paths.js");
var KARMA_CONFIG = "./tests/build/config/karma.conf.js";
var strict = !process.env.loose;
//*** GENERAL
desc("Lint and test");
task("default", [ "lint", "test" ], function() {
var elapsedSeconds = (Date.now() - startTime) / 1000;
console.log("\n\nBUILD OK (" + elapsedSeconds.toFixed(2) + "s)");
});
desc("Start server (for manual testing)");
task("run", [ "build" ], function() {
jake.exec("node ../node_modules/http-server/bin/http-server " + paths.clientDistDir, { interactive: true }, complete);
}, { async: true });
desc("Delete generated files");
task("clean", function() {
shell.rm("-rf", paths.generatedDir);
});
//*** LINT
/** */
desc("Lint everything");
task("lint", ["lintNode", "lintClient"]);
task("lintNode", function() {
process.stdout.write("Linting Node.js code: ");
}, { async: false });
task("lintClient", function() {
process.stdout.write("Linting browser code: ");
}, { async: false });
//*** TEST
desc("Start Karma server -- run this first");
task("karma", function() {
karma.start({
configFile: KARMA_CONFIG
}, complete, fail);
}, { async: true });
desc("Run tests");
task("test", function() {
console.log("Testing browser code: ");
var browsersToCapture = process.env.capture ? process.env.capture.split(",") : [];
karma.run({
configFile: KARMA_CONFIG,
expectedBrowsers: browsers,
strict: strict,
capture: browsersToCapture
}, complete, fail);
}, { async: true });
//*** BUILD
desc("Build distribution package");
task("build", [ "prepDistDir", "buildClient" ]);
task("prepDistDir", function() {
shell.rm("-rf", paths.distDir);
});
task("buildClient", [ paths.clientDistDir, "bundleClientJs" ], function() {
console.log("Copying client code: .");
shell.cp(
paths.clientDir + "/*.html",
paths.clientDir + "/*.css",
paths.clientDir + "/*.svg",
paths.clientDistDir
);
});
task("bundleClientJs", [ paths.clientDistDir ], function() {
console.log("Bundling browser code with Browserify: .");
browserify.bundle({
entry: paths.clientEntryPoint,
outfile: paths.clientDistBundle,
options: {
standalone: "toggle",
debug: true
}
}, complete, fail);
}, { async: true });
//*** CREATE DIRECTORIES
directory(paths.testDir);
directory(paths.clientDistDir);
}());

View file

@ -1,117 +0,0 @@
// Copyright (c) 2012-2014 Titanium I.T. LLC. All rights reserved. See LICENSE.txt for details.
// Main build file. Contains all tasks needed for normal development.
// There's no Quixote-specific configuration in this file.
(function() {
"use strict";
var startTime = Date.now();
var shell = require("../../../node_modules/shelljs/shell.js");
var karma = require("simplebuild-karma");
var browserify = require("../util/browserify_runner.js");
var browsers = require("../config/tested_browsers.js");
var paths = require("../config/paths.js");
var KARMA_CONFIG = "./tests/build/config/karma.conf.js";
var strict = !process.env.loose;
//*** GENERAL
desc("Lint and test");
task("default", [ "lint", "test" ], function() {
var elapsedSeconds = (Date.now() - startTime) / 1000;
console.log("\n\nBUILD OK (" + elapsedSeconds.toFixed(2) + "s)");
});
desc("Start server (for manual testing)");
task("run", [ "build" ], function() {
jake.exec("node ../node_modules/http-server/bin/http-server " + paths.clientDistDir, { interactive: true }, complete);
}, { async: true });
desc("Delete generated files");
task("clean", function() {
shell.rm("-rf", paths.generatedDir);
});
//*** LINT
/** */
desc("Lint everything");
task("lint", ["lintNode", "lintClient"]);
task("lintNode", function() {
process.stdout.write("Linting Node.js code: ");
}, { async: false });
task("lintClient", function() {
process.stdout.write("Linting browser code: ");
}, { async: false });
//*** TEST
desc("Start Karma server -- run this first");
task("karma", function() {
karma.start({
configFile: KARMA_CONFIG
}, complete, fail);
}, { async: true });
desc("Run tests");
task("test", function() {
console.log("Testing browser code: ");
var browsersToCapture = process.env.capture ? process.env.capture.split(",") : [];
karma.run({
configFile: KARMA_CONFIG,
expectedBrowsers: browsers,
strict: strict,
capture: browsersToCapture
}, complete, fail);
}, { async: true });
//*** BUILD
desc("Build distribution package");
task("build", [ "prepDistDir", "buildClient" ]);
task("prepDistDir", function() {
shell.rm("-rf", paths.distDir);
});
task("buildClient", [ paths.clientDistDir, "bundleClientJs" ], function() {
console.log("Copying client code: .");
shell.cp(
paths.clientDir + "/*.html",
paths.clientDir + "/*.css",
paths.clientDir + "/*.svg",
paths.clientDistDir
);
});
task("bundleClientJs", [ paths.clientDistDir ], function() {
console.log("Bundling browser code with Browserify: .");
browserify.bundle({
entry: paths.clientEntryPoint,
outfile: paths.clientDistBundle,
options: {
standalone: "toggle",
debug: true
}
}, complete, fail);
}, { async: true });
//*** CREATE DIRECTORIES
directory(paths.testDir);
directory(paths.clientDistDir);
}());

View file

@ -1,7 +0,0 @@
@echo off
REM Runs Jake from node_modules directory, preventing it from needing to be installed globally
REM Also ensures node modules have been installed
REM There's no Quixote-specific configuration in this file.
if not exist node_modules\.bin\jake.cmd call npm install
node_modules\.bin\jake %*

View file

@ -1,6 +0,0 @@
# Runs Jake from node_modules directory, preventing it from needing to be installed globally
# Also ensures node modules have been installed
# There's no Quixote-specific configuration in this file.
[ ! -f node_modules/.bin/jake ] && echo "Installing npm modules:" && npm install
node_modules/.bin/jake $*

View file

@ -1,28 +0,0 @@
// Copyright (c) 2015 Titanium I.T. LLC. All rights reserved. For license, see "README" or "LICENSE" file.
// Automatically runs build when files change.
// There's no Quixote-specific configuration in this file.
(function() {
"use strict";
var nodemon = require("nodemon");
var buildCommand = require("../config/build_command.js");
var paths = require("../config/paths.js");
console.log("*** Using nodemon to run " + buildCommand.get() + ". Type 'rs<enter>' to force restart.");
nodemon({
ext: "sh bat json js html css",
ignore: paths.generatedDir,
exec: buildCommand.get() + " " + process.argv.slice(2).join(" "),
execMap: {
sh: "/bin/sh",
bat: "cmd.exe /c",
cmd: "cmd.exe /c"
}
}).on("restart", function(files) {
if (files) console.log("*** Restarting due to", files);
else console.log("*** Restarting");
});
}());

View file

@ -1,21 +0,0 @@
/* Copyright (c) 2014 Titanium I.T. LLC - See LICENSE.txt for license */
// Helper function for running Browserify
// There's no Quixote-specific configuration in this file.
"use strict";
var fs = require("fs");
var path = require("path");
var browserify = require("browserify");
exports.bundle = function(config, success, failure) {
var b = browserify(config.options);
b.add(path.resolve(config.entry));
b.bundle(function(err, bundle) {
if (err) return failure(err);
fs.writeFileSync(config.outfile, bundle);
return success();
});
};

View file

@ -1,76 +0,0 @@
// Copyright (c) 2012-2015 Titanium I.T. LLC. All rights reserved. See LICENSE.txt for details.
// Helper functions for running Karma
// There's no Quixote-specific configuration in this file.
(function() {
"use strict";
var path = require("path");
var sh = require("./sh.js");
var runner = require("karma/lib/runner");
var server = require("karma/lib/server");
var KARMA = "node node_modules/karma/bin/karma";
exports.serve = function(configFile, success, fail) {
var command = KARMA + " start " + configFile;
sh.run(command, success, function () {
fail("Could not start Karma server");
});
};
exports.runTests = function(options, success, fail) {
options.capture = options.capture || [];
var config = {
configFile: path.resolve(options.configFile),
browsers: options.capture,
singleRun: options.capture.length > 0
};
var runKarma = runner.run.bind(runner);
if (config.singleRun) runKarma = server.start.bind(server);
var stdout = new CapturedStdout();
runKarma(config, function(exitCode) {
stdout.restore();
if (exitCode) return fail("Client tests failed (did you start the Karma server?)");
var browserMissing = checkRequiredBrowsers(options.browsers, stdout);
if (browserMissing && options.strict) return fail("Did not test all browsers");
if (stdout.capturedOutput.indexOf("TOTAL: 0 SUCCESS") !== -1) return fail("No tests were run!");
return success();
});
};
function checkRequiredBrowsers(requiredBrowsers, stdout) {
var browserMissing = false;
requiredBrowsers.forEach(function(browser) {
browserMissing = lookForBrowser(browser, stdout.capturedOutput) || browserMissing;
});
return browserMissing;
}
function lookForBrowser(browser, output) {
var missing = output.indexOf(browser + ": Executed") === -1;
if (missing) console.log("Warning: " + browser + " was not tested!");
return missing;
}
function CapturedStdout() {
var self = this;
self.oldStdout = process.stdout.write;
self.capturedOutput = "";
process.stdout.write = function(data) {
self.capturedOutput += data;
self.oldStdout.apply(this, arguments);
};
}
CapturedStdout.prototype.restore = function() {
process.stdout.write = this.oldStdout;
};
}());

View file

@ -1,54 +0,0 @@
// Copyright (c) 2014-2015 Titanium I.T. LLC. All rights reserved. See LICENSE.txt for details.
// Helper function for running Mocha
// There's no Quixote-specific configuration in this file.
(function() {
"use strict";
var Mocha = require("mocha");
var jake = require("jake");
exports.runTests = function runTests(options, success, failure) {
var mocha = new Mocha(options.options);
var files = deglob(options.files);
files.forEach(mocha.addFile.bind(mocha));
// This is a bit of a hack. The issue is this: during test execution, if an exception is thrown inside
// of a callback (and keep in mind that assertions throw exceptions), there's no way for Mocha to catch
// that exception.
// So Mocha registers an 'uncaughtException' handler on Node's process object. That way any unhandled
// exception is passed to Mocha.
// The problem is that Jake ALSO listens for 'uncaughtException'. Its handler and Mocha's handler don't
// get along. Somehow the Jake handler seems to terminate Mocha's test run... not sure why. We need to
// disable Jake's handler while Mocha is running.
// This code disables ALL uncaughtException handlers and then restores them after Mocha is done. It's
// very hacky and likely to cause problems in certain edge cases (for example, '.once' listeners aren't
// restored properly), but it seems to be working for now.
// It might be possible to create a better solution by using Node's 'domain' module. Something to look
// into if you're reading this. Another solution is to just spawn Mocha in a separate process, but I
// didn't want the time penalty involved. Besides, this seems to be working okay.
var savedListeners = disableExceptionListeners();
var runner = mocha.run(function(failures) {
restoreExceptionListeners(savedListeners);
if (failures) return failure("Tests failed");
else return success();
});
};
function deglob(globs) {
return new jake.FileList(globs).toArray();
}
function disableExceptionListeners() {
var listeners = process.listeners("uncaughtException");
process.removeAllListeners("uncaughtException");
return listeners;
}
function restoreExceptionListeners(listeners) {
listeners.forEach(process.addListener.bind(process, "uncaughtException"));
}
}());

View file

@ -1,48 +0,0 @@
// Copyright (c) 2012-2015 Titanium I.T. LLC. All rights reserved. See LICENSE.txt for details.
// Helper functions for running processes.
// There's no Quixote-specific configuration in this file.
(function() {
"use strict";
var jake = require("jake");
exports.runMany = function(commands, successCallback, failureCallback) {
var stdout = [];
function serializedSh(command) {
if (command) {
run(command, function(oneStdout) {
stdout.push(oneStdout);
serializedSh(commands.shift());
}, failureCallback);
}
else {
successCallback(stdout);
}
}
serializedSh(commands.shift());
};
var run = exports.run = function(oneCommand, successCallback, failureCallback) {
var stdout = "";
var child = jake.createExec(oneCommand);
child.on("stdout", function(data) {
process.stdout.write(data);
stdout += data;
});
child.on("stderr", function(data) {
process.stderr.write(data);
});
child.on("cmdEnd", function() {
successCallback(stdout);
});
child.on("error", function() {
failureCallback(stdout);
});
console.log("> " + oneCommand);
child.run();
};
}());

View file

@ -1,29 +0,0 @@
// Copyright (c) 2013 Titanium I.T. LLC. All rights reserved. See LICENSE.TXT for details.
// Helper function for checking version numbers.
// There's no Quixote-specific configuration in this file.
(function() {
"use strict";
var semver = require("semver");
exports.check = function(options, success, fail) {
if (options.strict) {
if (semver.neq(options.actual, options.expected)) return failWithQualifier("exactly");
}
else {
if (semver.lt(options.actual, options.expected)) return failWithQualifier("at least");
if (semver.neq(options.actual, options.expected)) console.log("Warning: Newer " + options.name +
" version than expected. Expected " + options.expected + ", but was " + options.actual + ".");
}
return success();
function failWithQualifier(qualifier) {
return fail("Incorrect " + options.name + " version. Expected " + qualifier +
" " + options.expected + ", but was " + options.actual + ".");
}
};
}());

View file

@ -1,151 +0,0 @@
(function() {
"use strict";
var quixote = require("./vendor/quixote.js");
var assert = require("./vendor/chai.js").assert;
describe("Colors", function() {
var frame;
var media;
var textPrimary;
var textSecondary;
var textSuccess;
var textWarning;
var textDanger;
var textMuted;
var backgroundPrimary;
var backgroundSecondary;
var backgroundSuccess;
var backgroundWarning;
var backgroundDanger;
var backgroundMuted;
var textOverride;
var textNotOverride;
before(function(done) {
frame = quixote.createFrame({
stylesheet: "/base/dist/paper.css"
}, done);
});
after(function() {
frame.remove();
});
beforeEach(function() {
frame.reset();
media = frame.add(
"<div class='media'>" +
"<div id='text'>" +
"<p class='text-primary' id='textPrimary'>text-primary</p>" +
"<p class='text-secondary' id='textSecondary'>text-secondary</p>" +
"<p class='text-success' id='textSuccess'>text-success</p>" +
"<p class='text-warning' id='textWarning'>text-warning</p>" +
"<p class='text-danger' id='textDanger'>text-danger</p>" +
"<p class='text-muted' id='textMuted'>text-muted</p>" +
"</div>" +
"<div id='background'>" +
"<div class='background-primary' id='backgroundPrimary'>background-primary</div>" +
"<div class='background-secondary' id='backgroundSecondary'>background-secondary</div>" +
"<div class='background-success' id='backgroundSuccess'>background-success</div>" +
"<div class='background-warning' id='backgroundWarning'>background-warning</div>" +
"<div class='background-danger' id='backgroundDanger'>background-danger</div>" +
"<div class='background-muted' id='backgroundMuted'>background-muted</div>" +
"</div>" +
"<div id='inheritance'>" +
"<div class='text-primary'>" +
"<p class='text-success' id='text-override'>text-override</p>" +
"<p id='text-not-override'>text-not-override</p>" +
"</div>" +
"</div>" +
"</div>",
"colors"
);
textPrimary = frame.get("#textPrimary");
textSecondary = frame.get("#textSecondary");
textSuccess = frame.get("#textSuccess");
textWarning = frame.get("#textWarning");
textDanger = frame.get("#textDanger");
textMuted = frame.get("#textMuted");
backgroundPrimary = frame.get("#backgroundPrimary");
backgroundSecondary = frame.get("#backgroundSecondary");
backgroundSuccess = frame.get("#backgroundSuccess");
backgroundWarning = frame.get("#backgroundWarning");
backgroundDanger = frame.get("#backgroundDanger");
backgroundMuted = frame.get("#backgroundMuted");
textOverride = frame.get("#text-override");
textNotOverride = frame.get("#text-not-override");
});
it("Text color is set to primary", function() {
assert.equal(textPrimary.getRawStyle("color"), "rgb(65, 64, 62)", "Primary color should be #41403E");
});
it("Text color is set to secondary", function() {
assert.equal(textSecondary.getRawStyle("color"), "rgb(0, 113, 222)", "Secondary color should be #0071DE");
});
it("Text color is set to success", function() {
assert.equal(textSuccess.getRawStyle("color"), "rgb(134, 163, 97)", "Success color should be #86a361");
});
it("Text color is set to warning", function() {
assert.equal(textWarning.getRawStyle("color"), "rgb(221, 205, 69)", "Warning color should be #ddcd45");
});
it("Text color is set to danger", function() {
assert.equal(textDanger.getRawStyle("color"), "rgb(167, 52, 45)", "Danger color should be #a7342d");
});
it("Text color is set to muted", function() {
assert.equal(textMuted.getRawStyle("color"), "rgb(134, 142, 150)", "Muted color should be #868e96");
});
it("Background color is set to primary", function() {
assert.equal(backgroundPrimary.getRawStyle("background-color"), "rgb(193, 192, 189)", "Primary color should be #C1C0BD");
});
it("Background color is set to secondary", function() {
assert.equal(backgroundSecondary.getRawStyle("background-color"), "rgb(222, 239, 255)", "Secondary color should be #DEEFFF");
});
it("Background color is set to success", function() {
assert.equal(backgroundSuccess.getRawStyle("background-color"), "rgb(208, 219, 194)", "Success color should be #D0BDC2");
});
it("Background color is set to warning", function() {
assert.equal(backgroundWarning.getRawStyle("background-color"), "rgb(245, 240, 198)", "Warning color should be #F5F0C6");
});
it("Background color is set to danger", function() {
assert.equal(backgroundDanger.getRawStyle("background-color"), "rgb(240, 203, 201)", "Danger color should be #F0CBC9");
});
it("Background color is set to muted", function() {
assert.equal(backgroundMuted.getRawStyle("background-color"), "rgb(230, 231, 233)", "Muted color should be #E6E7E9");
});
it("Text overrides parent style", function(){
assert.equal(textOverride.getRawStyle("color"), "rgb(134, 163, 97)", "Success color should be #86a361");
});
it("Text overrides parent style", function(){
assert.equal(textOverride.getRawStyle("color"), "rgb(134, 163, 97)", "Success color should be #86a361");
});
it("Text has parent style", function(){
assert.equal(textNotOverride.getRawStyle("color"), "rgb(65, 64, 62)", "Primary color should be #41403E");
});
});
}());

View file

@ -1,28 +0,0 @@
<!DOCTYPE html>
<html>
<!-- smoke test marker: automatopia home page -->
<head>
<title>Agile Engineering for the Web</title>
<link rel="stylesheet" type="text/css" href="./screen.css">
<script src="bundle.js" type="text/javascript"></script>
</head>
<body>
<!-- Note: This page is for manual demonstration of the example code. It's not tested like real production code should be. -->
<div class="media">
<img id="image" class="media__figure" src="icon.svg" width="25" />
<p id="content" class="media__body invisible">Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Aenean commodo ligula eget dolor. Aenean massa. Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus. Donec quam felis, ultricies nec, pellentesque eu, pretium quis, sem.</p>
</div>
<script type="text/javascript">
document.addEventListener("DOMContentLoaded", function(event) {
var image = document.getElementById("image");
var content = document.getElementById("content");
toggle.init(image, content, "invisible");
});
</script>
</body>
</html>

10707
tests/vendor/chai.js vendored

File diff suppressed because it is too large Load diff

4195
tests/vendor/quixote.js vendored

File diff suppressed because one or more lines are too long

7354
yarn.lock

File diff suppressed because it is too large Load diff