Merge pull request #15 from papercss/master

Merge master
This commit is contained in:
Afzal Sayed 2018-10-08 23:04:30 +05:30 committed by GitHub
commit d001a9d6e6
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
102 changed files with 13588 additions and 4166 deletions

11
.gitignore vendored
View file

@ -1,4 +1,11 @@
/node_modules
npm-debug.log
/dist
/tests/node_modules
/tests/node_modules
.DS_Store
/public
.vscode
# Ignore compiled CSS
/docs/static/assets/paper.css
/docs/static/assets/paper.min.css
/dist

View file

@ -2,5 +2,8 @@
npm-debug.log
index.html
demo.css
yarn.lock
/img
yarn.lock
/docs
/public
/tests

15
.stylelintrc.json Normal file
View file

@ -0,0 +1,15 @@
{
"extends": "stylelint-config-sass-guidelines",
"plugins": [
"stylelint-scss"
],
"rules": {
"max-nesting-depth": 5,
"property-no-vendor-prefix": null,
"value-no-vendor-prefix": null,
"selector-no-qualifying-type": null,
"selector-max-compound-selectors": null,
"scss/selector-no-redundant-nesting-selector": null,
"scss/at-extend-no-missing-placeholder": null
}
}

View file

@ -14,7 +14,14 @@ addons:
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 &

View file

@ -1,4 +1,6 @@
Copyright 2017 Rhyne Vlaservich <rhyneav@gmail.com>
## ISC Licence
Copyright (c) 20172018, Rhyne Vlaservich <rhyneav@gmail.com>
Permission to use, copy, modify, and/or distribute this software for any purpose with or without fee is hereby granted, provided that the above copyright notice and this permission notice appear in all copies.

View file

@ -1,6 +1,6 @@
<p align="center">
<a href="https://getpapercss.com">
<img src="https://github.com/papercss/papercss/blob/master/img/favicon.ico?raw=true" alt="PaperCSS logo">
<img src="https://raw.githubusercontent.com/papercss/papercss/master/docs/static/favicon.ico?raw=true" alt="PaperCSS logo">
</a>
<h3 align="center">PaperCSS</h3>
@ -40,9 +40,11 @@ There are several options available:
## Content of the framework
We provide compiled CSS (`paper.css`) as well as minified CSS (`paper.min.css`). You can also use single components that are build into `papercss/dist/components`.
We provide compiled CSS (`paper.css`) as well as minified CSS (`paper.min.css`).
You can also play with original, source files, written in LESS, in `src/`.
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 also play with original, source files, written in SCSS, in `src/`.
## Documentation
@ -52,11 +54,11 @@ You can also view the develop branch at [develop.getpapercss.com](https://develo
## Customizing
You can customize PaperCSS easily, clone the repo, run `npm install` and make any changes to `.less` files in `src/`.
You can customize PaperCSS easily, clone the repo, run `npm install` and make any changes to `.scss` files in `src/`.
The main places you might want to make changes would be `colors.less` or `fonts.less`, where you can specify new colors or fonts for your CSS build.
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 `npm run build` and get them from the `dist/` folder.
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.
## Contributing
@ -71,24 +73,26 @@ Once you are ready to contribute, here the workflow you should follow:
- 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`
- Once done commit and push your changes to your fork.
- Open a pull request on the origin papercss repo. Be sure to include any picture and/or details on what you have done, it will helps reviewers **a lot**!
- Write some code!
- 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.
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.
## About
I got tired of mODerN STylEs and clean pages on the internet. I also wanted to learn more about Flexbox and Less. So I made PaperCSS to solve these two challenges of mine :)
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).
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.
While I'm proud of how it's turned out so far, I think there's a lot that can still be done to make it better. Such things as refactoring, adding more utility classes and more border types (like dashed/dotted) could really polish off this framework. That's why it's open sourced and available for pull requests!
Feel free to use it for wireframes, webapps, blogs, or whatever else you can think of!
If you are new to Git or Less, 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.
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.
## Credits and license
Code and documentation under [ISC license](https://github.com/papercss/papercss/blob/master/license).
Code and documentation under [ISC license](https://github.com/papercss/papercss/blob/master/license).
Shout out to Tiffany Rayside for creating Imperfect Buttons, which was an inspiration for this project. https://codepen.io/tmrDevelops/pen/VeRvKX

View file

@ -0,0 +1,5 @@
---
title: "{{ replace .TranslationBaseName "-" " " | title }}"
date: {{ .Date }}
draft: true
---

20
docs/config.toml Normal file
View file

@ -0,0 +1,20 @@
baseURL = "https://getpapercss.com"
title = "PaperCSS"
# Directories
publishDir = "../public"
# Syntax Highlighting ( https://gohugo.io/content-management/syntax-highlighting/ )
pygmentsCodefences = true
pygmentsStyle = "emacs"
[params.info]
description = "the less formal CSS framework"
title404 = "Nothing's here!"
[params.seo]
# Title Separator: - — · • * ⋆ | ~ « » < >
titleSeparator = "•"
[blackfriday]
hrefTargetBlank = true

67
docs/content/_index.md Normal file
View file

@ -0,0 +1,67 @@
---
title: Get PaperCSS
menu: main
weight: -270
---
#### Download
Download the latest version (1.5.4) 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.5.4/paper.css">CSS File</a>
<a class="paper-btn margin" href="https://github.com/rhyneav/papercss/releases/download/v1.5.4/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.5.4. 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
#### 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.5.4/dist/paper.css](https://unpkg.com/papercss@1.5.4/dist/paper.css)
* [https://unpkg.com/papercss@1.5.4/dist/paper.min.css](https://unpkg.com/papercss@1.5.4/dist/paper.min.css)
Here's a quck 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.5.4/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>
```
#### Build it Yourself
If you'd rather customize things, you can build the CSS yourself via the git repo
```sh
git clone https://github.com/papercss/papercss.git
cd papercss
npm install
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.

14
docs/content/about.md Normal file
View file

@ -0,0 +1,14 @@
---
title: About
slug: about
menu: main
weight: -90
---
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).
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.
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,5 @@
---
title: Documentation
menu: main
weight: -240
---

View file

@ -0,0 +1,4 @@
---
title: Components
description: PaperCSS Components
---

View file

@ -0,0 +1,33 @@
---
title: Alerts
description: PaperCSS Alerts
---
<div class="row flex-spaces">
<div class="alert alert-primary">
Alert-primary
</div>
<div class="alert alert-secondary">
Alert-secondary
</div>
<div class="alert alert-success">
Alert-success
</div>
<div class="alert alert-warning">
Alert-warning
</div>
<div class="alert alert-danger">
Alert-danger
</div>
</div>
#### Code:
```html
<div class="row flex-spaces">
<div class="alert alert-primary">Alert-primary</div>
<div class="alert alert-secondary">Alert-secondary</div>
<div class="alert alert-success">Alert-success</div>
<div class="alert alert-warning">Alert-warning</div>
<div class="alert alert-danger">Alert-danger</div>
</div>
```

View file

@ -0,0 +1,42 @@
---
title: Articles
description: PaperCSS Articles
---
<article class="article">
<h1 class="article-title">
<a href="#">Article Title</a>
</h1>
<p class="article-meta">
Written by <a href="#">Super User</a> on 24 November 2017. Posted in <a href="#">Blog</a>
</p>
<p class="text-lead">
Lorem ipsum dolor sit amet, consectetur adipisicing elit. Pariatur repellendus excepturi, consequatur illo rerum, non sint asperiores dolore sapiente, vitae blanditiis. Officiis at quaerat modi earum, fugiat magni impedit, aperiam.
</p>
<p>
Lorem ipsum dolor sit amet, consectetur adipisicing elit. Corrupti iure totam nam debitis aliquid impedit, et quas omnis aspernatur optio molestias ex laborum quia. Ducimus culpa tempore, veritatis officia delectus dolore dignissimos reprehenderit vero, sunt odit placeat est non molestiae ipsa nam velit in iusto hic quasi similique facere. Maxime?
</p>
<p>
Lorem ipsum dolor sit amet, consectetur adipisicing elit. Corrupti iure totam nam debitis aliquid impedit, et quas omnis aspernatur optio molestias ex laborum quia. Ducimus culpa tempore, veritatis officia delectus dolore dignissimos reprehenderit vero, sunt odit placeat est non molestiae ipsa nam velit in iusto hic quasi similique facere. Maxime?
</p>
<div class="row">
<button>Read More</button>
<button>5 Comments</button>
</div>
</article>
#### Code:
```html
<article class="article">
<h1 class="article-title"><a href="">Article Title</a></h1>
<p class="article-meta">Written by <a href="#">Super User</a></p>
<p class="text-lead"> Lorem... </p>
<p>Lorem...</p>
<div class="row">
<button>Read More</button>
<button>5 Comments</button>
</div>
</article>
```

View file

@ -0,0 +1,30 @@
---
title: Badges
description: PaperCSS Badges
---
### Default
You can customize badges colors with secondary, success, warning, danger classes.
# Example h1 heading <span class="badge">123</span>
## Example h2 heading <span class="badge secondary">123</span>
### Example h3 heading <span class="badge success">123</span>
#### Example h4 heading <span class="badge warning">123</span>
##### Example h5 heading <span class="badge danger">123</span>
###### Example h6 heading <span class="badge">123</span>
#### Code:
```html
<h1>Example h1 heading <span class="badge">123</span></h1>
<h2>Example h2 heading <span class="badge secondary">123</span></h2>
<h3>Example h3 heading <span class="badge success">123</span></h3>
<h4>Example h4 heading <span class="badge warning">123</span></h4>
<h5>Example h5 heading <span class="badge danger">123</span></h5>
<h6>Example h6 heading <span class="badge">123</span></h6>
```

View file

@ -0,0 +1,55 @@
---
title: Buttons
description: PaperCSS Buttons
---
Insprired by [Imprefect Buttons](https://codepen.io/tmrDevelops/pen/VeRvKX)
<button class="btn-large">Large</button>
<button>Default</button>
<button class="btn-small">Small</button>
<a href="#" class="paper-btn">Link</a>
<div class="row">
<div class="col-6 col">
<button class="btn-block">Block level</button>
</div>
</div>
<button class="disabled">Disabled</button>
<button disabled>Disabled</button>
#### Code:
```html
<p>Insprired by <a href="https://codepen.io/tmrDevelops/pen/VeRvKX" target="_blank">Imprefect Buttons</a></p>
<button class="btn-large">Large</button>
<button>Default</button>
<button class="btn-small">Small</button>
<a href="#" class="paper-btn">Link</a>
<div class="row">
<div class="col-6 col">
<button class="btn-block">Block level</button>
</div>
</div>
<button class="disabled">Disabled</button>
<button disabled>Disabled</button>
```
### Colors
<input type="button" class="paper-btn btn-primary" value="Primary"/>
<input type="button" class="btn-secondary" value="Secondary"/>
<button class="btn-success">Success</button>
<button class="btn-warning">Warning</button>
<button class="btn-danger">Danger</button>
#### Code:
```html
<input type="button" class="paper-btn btn-primary" value="Primary"/>
<input type="button" class="btn-secondary" value="Secondary"/>
<button class="btn-success">Success</button>
<button class="btn-warning">Warning</button>
<button class="btn-danger">Danger</button>
```

View file

@ -0,0 +1,120 @@
---
title: Cards
description: PaperCSS Cards
---
### Full card example
It is possible to not put all the sub-classes like card-title, card-subtitle, card-text, ... But instead the framework will recognize the element properly if it's a h4, h5, p, ... And you need to put all this content on a div with card class.
<div class="row flex-center">
<div class="card" style="width: 20rem;">
<img class="image-top" src="https://picsum.photos/768" alt="Card example image">
<div class="card-body">
<h4 class="card-title">My awesome Paper card!</h4>
<h5 class="card-subtitle">Nice looking subtitle.</h5>
<p class="card-text">Notice that the card width in this example have been set to 20rem, otherwise it will try to fill the current container/row where the card is.</p>
<button>Let me go here!</button>
</div>
</div>
</div>
#### Code:
```html
<div class="card" style="width: 20rem;">
<img src="https://picsum.photos/768" alt="Card example image">
<div class="card-body">
<h4 class="card-title">My awesome Paper card!</h4>
<h5 class="card-subtitle">Nice looking subtitle.</h5>
<p class="card-text">Notice that the card width in this example have been set to 20rem, otherwise it will try to fill the current container/row where the card is.</p>
<button>Let me go here!</button>
</div>
</div>
```
### Card title, text, links
<div class="row flex-center">
<div class="card" style="width: 20rem;">
<div class="card-body">
<h4 class="card-title">My awesome Paper card!</h4>
<h5 class="card-subtitle">Nice looking subtitle.</h5>
<p class="card-text">This is another example of a card without image. Cards are also meant to be used without images, but with text/links/buttons.</p>
<a class="card-link" href="#">First link</a>
<a class="card-link" href="#">Second link</a>
</div>
</div>
</div>
#### Code:
```html
<div class="card" style="width: 20rem;">
<div class="card-body">
<h4 class="card-title">My awesome Paper card!</h4>
<h5 class="card-subtitle">Nice looking subtitle.</h5>
<p class="card-text">This is another example of a card without image. Cards are also meant to be used without images, but with text/links/buttons.</p>
<a class="card-link" href="#">First link</a>
<a class="card-link" href="#">Second link</a>
</div>
</div>
```
### Image on top or bottom
<div class="row flex-center">
<div class="card" style="width: 20rem;">
<div class="card-body">
<h4 class="card-title">My awesome Paper card!</h4>
<h5 class="card-subtitle">Nice looking subtitle.</h5>
<p class="card-text">You can also place image on the bottom of the card.</p>
<button>Let me go here!</button>
</div>
<img class="image-bottom" src="https://unsplash.it/550/250" alt="Card example image">
</div>
</div>
#### Code:
```html
<div class="card" style="width: 20rem;">
<div class="card-body">
<h4 class="card-title">My awesome Paper card!</h4>
<h5 class="card-subtitle">Nice looking subtitle.</h5>
<p class="card-text">You can also place image on the bottom of the card.</p>
<button>Let me go here!</button>
</div>
<img class="image-bottom" src="https://unsplash.it/550/250" alt="Card example image">
</div>
```
### Header and footer
<div class="row flex-center">
<div class="card" style="width: 20rem;">
<div class="card-header">Header</div>
<div class="card-body">
<h4 class="card-title">My awesome Paper card!</h4>
<h5 class="card-subtitle">Nice looking subtitle.</h5>
<p class="card-text">You can also place image on the bottom of the card.</p>
<button>Let me go here!</button>
</div>
<div class="card-footer">Footer</div>
</div>
</div>
#### Code:
```html
<div class="card" style="width: 20rem;">
<div class="card-header">Header</div>
<div class="card-body">
<h4 class="card-title">My awesome Paper card!</h4>
<h5 class="card-subtitle">Nice looking subtitle.</h5>
<p class="card-text">You can also place image on the bottom of the card.</p>
<button>Let me go here!</button>
</div>
<div class="card-footer">Footer</div>
</div>
```

View file

@ -0,0 +1,160 @@
---
title: Collapsibles
description: PaperCSS Collapsibles
---
Collapsibles are elements that expand when you click on them. You can hide/reveal content back on clicking.
<div class="row">
<div class="collapsible">
<input id="collapsible1" type="checkbox" name="collapsible">
<label for="collapsible1">First</label>
<div class="collapsible-body">
<span>
Bacon ipsum dolor sit amet beef venison beef ribs kielbasa. Sausage pig leberkas, t-bone sirloin shoulder bresaola. Frankfurter rump porchetta ham. Pork belly prosciutto brisket meatloaf short ribs.
</span>
</div>
</div>
<div class="collapsible">
<input id="collapsible2" type="checkbox" name="collapsible">
<label for="collapsible2">Second</label>
<div class="collapsible-body">
<span>
Bacon ipsum dolor sit amet landjaeger sausage brisket, jerky drumstick fatback boudin ball tip turducken. Pork belly meatball t-bone bresaola tail filet mignon kevin turkey ribeye shank flank doner cow kielbasa shankle.
</span>
</div>
</div>
<div class="collapsible">
<input id="collapsible3" type="checkbox" name="collapsible">
<label for="collapsible3">Third</label>
<div class="collapsible-body">
<span>
Bacon ipsum dolor sit amet beef venison beef ribs kielbasa. Sausage pig leberkas, t-bone sirloin shoulder bresaola. Frankfurter rump porchetta ham. Pork belly prosciutto brisket meatloaf short ribs.
</span>
</div>
</div>
<div class="collapsible">
<input id="collapsible4" type="checkbox" name="collapsible">
<label for="collapsible4">Fourth</label>
<div class="collapsible-body">
<span>
Bacon ipsum dolor sit amet landjaeger sausage brisket, jerky drumstick fatback boudin ball tip turducken. Pork belly meatball t-bone bresaola tail filet mignon kevin turkey ribeye shank flank doner cow kielbasa shankle.
</span>
</div>
</div>
</div>
#### Code:
```html
<div class="row">
<div class="collapsible">
<input id="collapsible1" type="checkbox" name="collapsible">
<label for="collapsible1">First</label>
<div class="collapsible-body">
<span>Bacon ipsum dolor sit amet landjaeger sausage brisket, jerky drumstick fatback boudin ball tip turducken...</span>
</div>
</div>
<div class="collapsible">
<input id="collapsible2" type="checkbox" name="collapsible">
<label for="collapsible2">Second</label>
<div class="collapsible-body">
<span>Bacon ipsum dolor sit amet beef venison beef ribs kielbasa. Sausage pig leberkas, t-bone sirloin shoulder bresaola...</span>
</div>
</div>
<div class="collapsible">
<input id="collapsible3" type="checkbox" name="collapsible">
<label for="collapsible3">Third</label>
<div class="collapsible-body">
<span>Bacon ipsum dolor sit amet landjaeger sausage brisket, jerky drumstick fatback boudin ball tip turducken...</span>
</div>
</div>
<div class="collapsible">
<input id="collapsible4" type="checkbox" name="collapsible">
<label for="collapsible4">Fourth</label>
<div class="collapsible-body">
<span>Bacon ipsum dolor sit amet beef venison beef ribs kielbasa. Sausage pig leberkas, t-bone sirloin shoulder bresaola...</span>
</div>
</div>
</div>
```
### Accordions
Use `input type="radio"` when you want to keep only one element collapsed at a time.
<div class="row">
<div class="collapsible">
<input id="collapsible5" type="radio" name="collapsible">
<label for="collapsible5">First</label>
<div class="collapsible-body">
<span>
Bacon ipsum dolor sit amet beef venison beef ribs kielbasa. Sausage pig leberkas, t-bone sirloin shoulder bresaola. Frankfurter rump porchetta ham. Pork belly prosciutto brisket meatloaf short ribs.
</span>
</div>
</div>
<div class="collapsible">
<input id="collapsible6" type="radio" name="collapsible">
<label for="collapsible6">Second</label>
<div class="collapsible-body">
<span>
Bacon ipsum dolor sit amet landjaeger sausage brisket, jerky drumstick fatback boudin ball tip turducken. Pork belly meatball t-bone bresaola tail filet mignon kevin turkey ribeye shank flank doner cow kielbasa shankle.
</span>
</div>
</div>
<div class="collapsible">
<input id="collapsible7" type="radio" name="collapsible">
<label for="collapsible7">Third</label>
<div class="collapsible-body">
<span>
Bacon ipsum dolor sit amet beef venison beef ribs kielbasa. Sausage pig leberkas, t-bone sirloin shoulder bresaola. Frankfurter rump porchetta ham. Pork belly prosciutto brisket meatloaf short ribs.
</span>
</div>
</div>
<div class="collapsible">
<input id="collapsible8" type="radio" name="collapsible">
<label for="collapsible8">Fourth</label>
<div class="collapsible-body">
<span>
Bacon ipsum dolor sit amet landjaeger sausage brisket, jerky drumstick fatback boudin ball tip turducken. Pork belly meatball t-bone bresaola tail filet mignon kevin turkey ribeye shank flank doner cow kielbasa shankle.
</span>
</div>
</div>
</div>
#### Code:
```html
<div class="row">
<div class="collapsible">
<input id="collapsible5" type="radio" name="collapsible">
<label for="collapsible5">First</label>
<div class="collapsible-body">
<span>Bacon ipsum dolor sit amet landjaeger sausage brisket, jerky drumstick fatback boudin ball tip turducken...</span>
</div>
</div>
<div class="collapsible">
<input id="collapsible6" type="radio" name="collapsible">
<label for="collapsible6">Second</label>
<div class="collapsible-body">
<span>Bacon ipsum dolor sit amet beef venison beef ribs kielbasa. Sausage pig leberkas, t-bone sirloin shoulder bresaola...</span>
</div>
</div>
<div class="collapsible">
<input id="collapsible7" type="radio" name="collapsible">
<label for="collapsible7">Third</label>
<div class="collapsible-body">
<span>Bacon ipsum dolor sit amet landjaeger sausage brisket, jerky drumstick fatback boudin ball tip turducken...</span>
</div>
</div>
<div class="collapsible">
<input id="collapsible8" type="radio" name="collapsible">
<label for="collapsible8">Fourth</label>
<div class="collapsible-body">
<span>Bacon ipsum dolor sit amet beef venison beef ribs kielbasa. Sausage pig leberkas, t-bone sirloin shoulder bresaola...</span>
</div>
</div>
</div>
```

View file

@ -0,0 +1,127 @@
---
title: Forms
description: PaperCSS Forms
---
<div class="form-group">
<label for="paperInputs1">Input</label>
<input type="text" placeholder="Nice input" id="paperInputs1">
</div>
<div class="row">
<div class="col sm-4">
<div class="form-group">
<label for="paperInputs2">Block Level</label>
<input class="input-block" type="text" id="paperInputs2">
</div>
</div>
<div class="col sm-8">
<div class="form-group">
<label for="paperInputs3">Block Level</label>
<input class="input-block" type="text" id="paperInputs3">
</div>
</div>
</div>
<div class="form-group">
<label for="paperInputs4">Disabled</label>
<input type="text" placeholder="Disabled" id="paperInputs4" disabled>
</div>
<div class="form-group">
<label>Large Input</label>
<textarea placeholder="Large input"></textarea>
</div>
<div class="form-group">
<label>No Resize</label>
<textarea class="no-resize" placeholder="No resize"></textarea>
</div>
<div class="form-group">
<label for="paperSelects1">Select</label>
<select id="paperSelects1">
<option value="1">Option 1</option>
<option value="2">Option 2</option>
<option value="3">Option 3</option>
<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>
</label>
<label for="paperRadios2" class="paper-radio">
<input type="radio" name="paperRadios" id="paperRadios2" value="option 2">
<span>This is the second option
<span>
</label>
</fieldset>
<fieldset class="form-group">
<legend>Some Check Boxes</legend>
<label for="paperChecks1" class="paper-check">
<input type="checkbox" name="paperChecks" id="paperChecks1" value="option 1">
<span>This is the first check</span>
</label>
<label for="paperChecks2" class="paper-check">
<input type="checkbox" name="paperChecks" id="paperChecks2" value="option 2">
<span>This is the second check</span>
</label>
</fieldset>
#### Code:
```html
<div class="form-group">
<label for="paperInputs1">Input</label>
<input type="text" placeholder="Nice input" id="paperInputs1">
</div>
<div class="row">
<div class="col sm-4">
<div class="form-group">
<label for="paperInputs2">Block Level</label>
<input class="input-block" type="text" id="paperInputs2">
</div>
</div>
<div class="col sm-8">
<div class="form-group">
<label for="paperInputs3">Block Level</label>
<input class="input-block" type="text" id="paperInputs3">
</div>
</div>
</div>
<div class="form-group">
<label for="paperInputs4">Disabled</label>
<input type="text" placeholder="Disabled" id="paperInputs4" disabled>
</div>
<div class="form-group">
<label>Large Input</label>
<textarea placeholder="Large input"></textarea>
</div>
<div class="form-group">
<label>No Resize</label>
<textarea class="no-resize" placeholder="No resize"></textarea>
</div>
<div class="form-group">
<label for="paperSelects1">Select</label>
<select id="paperSelects1">
<option value="1">Option 1</option>
<option value="2">Option 2</option>
<option value="3">Option 3</option>
<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>
</label>
<label for="paperRadios2" class="paper-radio">
<input type="radio" name="paperRadios" id="paperRadios2" value="option 2"> <span>This is the second option<span>
</label>
</fieldset>
<fieldset class="form-group">
<legend>Some Check Boxes</legend>
<label for="paperChecks1" class="paper-check">
<input type="checkbox" name="paperChecks" id="paperChecks1" value="option 1"> <span>This is the first check</span>
</label>
<label for="paperChecks2" class="paper-check">
<input type="checkbox" name="paperChecks" id="paperChecks2" value="option 2"> <span>This is the second check</span>
</label>
</fieldset>
```

View file

@ -0,0 +1,79 @@
---
title: Modals
description: PaperCSS Modals
---
### Simple modal example
This can be used to implement modals along with features like title, subtitle, text, button and links. Just use whichever component you need for your modal with proper classes and leave the rest on the framework.
<div class="row flex-spaces child-borders">
<label class="paper-btn margin" for="modal-1">Open Modal!</label>
</div>
<input class="modal-state" id="modal-1" type="checkbox">
<div class="modal">
<label class="modal-bg" for="modal-1"></label>
<div class="modal-body">
<label class="btn-close" for="modal-1">X</label>
<h4 class="modal-title">Modal Title</h4>
<h5 class="modal-subtitle">Modal Subtitle</h5>
<p class="modal-text">This is an example of modal which is implemented with pure CSS! :D</p>
<label for="modal-1" class="paper-btn">Nice!</label>
</div>
</div>
#### Code:
```html
<div class="row flex-spaces child-borders">
<label class="paper-btn margin" for="modal-1">Open Modal!</label>
</div>
<input class="modal-state" id="modal-1" type="checkbox">
<div class="modal">
<label class="modal-bg" for="modal-1"></label>
<div class="modal-body">
<label class="btn-close" for="modal-1">X</label>
<h4 class="modal-title">Modal Title</h4>
<h5 class="modal-subtitle">Modal Subtitle</h5>
<p class="modal-text">This is an example of modal which is implemented with pure CSS! :D</p>
<label for="modal-1">Nice!</label>
</div>
</div>
```
### Modal with title, text and links
<div class="row flex-spaces child-borders">
<label class="paper-btn margin" for="modal-2">Another Modal!</label>
</div>
<input class="modal-state" id="modal-2" type="checkbox">
<div class="modal">
<label class="modal-bg" for="modal-2"></label>
<div class="modal-body">
<label class="btn-close" for="modal-2">X</label>
<h4 class="modal-title">Modal Title</h4>
<h5 class="modal-subtitle">Modal Subtitle</h5>
<p class="modal-text">This is another example of modal which is implemented with pure CSS! :D</p>
<a href="/#download">Get PaperCSS</a>
<label for="modal-2" class="modal-link">Close</label>
</div>
</div>
#### Code:
```html
<div class="row flex-spaces child-borders">
<label class="paper-btn margin" for="modal-2">Another Modal!</label>
</div>
<input class="modal-state" id="modal-2" type="checkbox">
<div class="modal">
<label class="modal-bg" for="modal-2"></label>
<div class="modal-body">
<label class="btn-close" for="modal-2">X</label>
<h4 class="modal-title">Modal Title</h4>
<h5 class="modal-subtitle">Modal Subtitle</h5>
<p class="modal-text">This is another example of modal which is implemented with pure CSS! :D</p>
<a href="/#download">Get PaperCSS</a>
<label for="modal-2" class="modal-link">Close</label>
</div>
</div>
```

View file

@ -0,0 +1,131 @@
---
title: Navbar
description: PaperCSS Navbar
---
<nav class="border fixed split-nav">
<div class="nav-brand">
<h3><a href="/">Get PaperCSS</a></h3>
</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>
<div class="collapsible-body">
<ul class="inline">
<li><a href="/docs/">Documentation</a></li>
<li><a href="/about/">About</a></li>
<li><a href="https://github.com/rhyneav/papercss" target="_blank">Github</a></li>
</ul>
</div>
</div>
</nav>
<nav class="border split-nav">
<div class="nav-brand">
<h3><a href="#">Get PaperCSS</a></h3>
</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="collapsible-body">
<ul class="inline">
<li><a href="#">Documentation</a></li>
<li><a href="#">About</a></li>
<li><a href="#">Github</a></li>
</ul>
</div>
</div>
</nav>
#### Code:
Add ```.fixed``` to ```<nav>``` to fix the nav to the top to have it scroll the whole page. It's also mobile responsive and will show a hamburger menu on small screens. No JavaScript required!
```html
<nav class="border fixed split-nav">
<div class="nav-brand">
<h3><a href="#">Get PaperCSS</a></h3>
</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="collapsible-body">
<ul class="inline">
<li><a href="#">Documentation</a></li>
<li><a href="#">About</a></li>
<li><a href="#">Github</a></li>
</ul>
</div>
</div>
</nav>
```
### Not Split Navbar
<nav class="border">
<div class="nav-brand">
<h3><a href="#">Get PaperCSS</a></h3>
</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>
<div class="collapsible-body">
<ul class="inline">
<li><a href="#">Documentation</a></li>
<li><a href="#">About</a></li>
<li><a href="#">Github</a></li>
</ul>
</div>
</div>
</nav>
#### Code:
```html
<nav class="border fixed">
<div class="nav-brand">
<h4><a href="#">Get PaperCSS</a></h4>
</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>
<div class="collapsible-body">
<ul class="inline">
<li><a href="#">Documentation</a></li>
<li><a href="#">About</a></li>
<li><a href="#">Github</a></li>
</ul>
</div>
</div>
</nav>
```

View file

@ -0,0 +1,47 @@
---
title: Popovers
description: PaperCSS Popovers
---
### Basic usage
You can add popovers, also called tooltips, on your elements. popover attribute is the popover text content, popover-position attribute can be: top, left, right, bottom.
<div class="row flex-spaces">
<div class="sm-3 col">
<p popover-left="Popover on left">Popover left position</p>
</div>
<div class="sm-3 col">
<p popover-top="Popover on top">Popover top position</p>
</div>
<div class="sm-3 col">
<p popover-bottom="Popover on bottom">Popover bottom position</p>
</div>
<div class="sm-3 col">
<p popover-right="Popover on right">Popover right position</p>
</div>
</div>
#### Code:
```html
<p popover-left="Popover on left">Popover left position</p>
<p popover-top="Popover on top">Popover top position</p>
<p popover-bottom="Popover on bottom">Popover bottom position</p>
<p popover-right="Popover on right">Popover right position</p>
```
But you can also popover on pretty much any element you want, it can be on a button, on a table cell, ...
<div class="row flex-center">
<div class="sm-6 col">
<button popover-top="Popover on top">Popover on top and on a button!</button>
</div>
</div>
#### Code:
```html
<button popover-top="Popover on top">Popover on top and on a button!</button>
```

View file

@ -0,0 +1,101 @@
---
title: Tabs
description: PaperCSS Tabs
---
<div class="row flex-spaces tabs">
<input id="tab1" type="radio" name="tabs" checked>
<label for="tab1">Tab 1</label>
<input id="tab2" type="radio" name="tabs">
<label for="tab2">Tab 2</label>
<input id="tab3" type="radio" name="tabs">
<label for="tab3">Tab 3</label>
<input id="tab4" type="radio" name="tabs">
<label for="tab4">Tab 4</label>
<div class="content" id="content1">
<p>
Bacon ipsum dolor sit amet beef venison beef ribs kielbasa. Sausage pig leberkas, t-bone sirloin shoulder bresaola. Frankfurter
rump porchetta ham. Pork belly prosciutto brisket meatloaf short ribs.
</p>
<p>
Brisket meatball turkey short loin boudin leberkas meatloaf chuck andouille pork loin pastrami spare ribs pancetta rump.
Frankfurter corned beef beef tenderloin short loin meatloaf swine ground round venison.
</p>
</div>
<div class="content" id="content2">
<p>
Bacon ipsum dolor sit amet landjaeger sausage brisket, jerky drumstick fatback boudin ball tip turducken. Pork belly meatball
t-bone bresaola tail filet mignon kevin turkey ribeye shank flank doner cow kielbasa shankle. Pig swine
chicken hamburger, tenderloin turkey rump ball tip sirloin frankfurter meatloaf boudin brisket ham hock.
Hamburger venison brisket tri-tip andouille pork belly ball tip short ribs biltong meatball chuck. Pork
chop ribeye tail short ribs, beef hamburger meatball kielbasa rump corned beef porchetta landjaeger flank.
Doner rump frankfurter meatball meatloaf, cow kevin pork pork loin venison fatback spare ribs salami
beef ribs.
</p>
</div>
<div class="content" id="content3">
<p>
Brisket meatball turkey short loin boudin leberkas meatloaf chuck andouille pork loin pastrami spare ribs pancetta rump.
Frankfurter corned beef beef tenderloin short loin meatloaf swine ground round venison.
</p>
<p>
Bacon ipsum dolor sit amet beef venison beef ribs kielbasa. Sausage pig leberkas, t-bone sirloin shoulder bresaola. Frankfurter
rump porchetta ham. Pork belly prosciutto brisket meatloaf short ribs.
</p>
</div>
<div class="content" id="content4">
<p>
Hamburger venison brisket tri-tip andouille pork belly ball tip short ribs biltong meatball chuck. Pork
chop ribeye tail short ribs, beef hamburger meatball kielbasa rump corned beef porchetta landjaeger flank.
Doner rump frankfurter meatball meatloaf, cow kevin pork pork loin venison fatback spare ribs salami
beef ribs.
Bacon ipsum dolor sit amet landjaeger sausage brisket, jerky drumstick fatback boudin ball tip turducken. Pork belly meatball
t-bone bresaola tail filet mignon kevin turkey ribeye shank flank doner cow kielbasa shankle. Pig swine
chicken hamburger, tenderloin turkey rump ball tip sirloin frankfurter meatloaf boudin brisket ham hock.
</p>
</div>
</div>
#### Code:
```html
<div class="row flex-spaces tabs">
<input id="tab1" type="radio" name="tabs" checked>
<label for="tab1">Tab 1</label>
<input id="tab2" type="radio" name="tabs">
<label for="tab2">Tab 2</label>
<input id="tab3" type="radio" name="tabs">
<label for="tab3">Tab 3</label>
<input id="tab4" type="radio" name="tabs">
<label for="tab4">Tab 4</label>
<div class="content" id="content1">
<p>
Bacon ipsum dolor sit amet beef venison beef ribs kielbasa...
</p>
<p>
Brisket meatball turkey short loin boudin leberkas meatloaf...
</p>
</div>
<div class="content" id="content2">
<p>
Bacon ipsum dolor sit amet landjaeger sausage brisket...
</p>
</div>
<div class="content" id="content3">
<p>
Bacon ipsum dolor sit amet beef venison beef ribs kielbasa...
</p>
<p>
Brisket meatball turkey short loin boudin leberkas meatloaf...
</p>
</div>
<div class="content" id="content4">
<p>
Bacon ipsum dolor sit amet landjaeger sausage brisket...
</p>
</div>
</div>
```

View file

@ -0,0 +1,4 @@
---
title: Content
description: PaperCSS Content
---

View file

@ -0,0 +1,27 @@
---
title: Code
description: PaperCSS Code
---
Let's make some pretty `<code>`
Print files backwards using <kbd>tac</kbd>
To stop a process, hit <kbd>ctrl + c</kbd>
<pre><code>function add(x, y) {
return x + y;
}
</code></pre>
#### Code:
```html
<p>Let's make some pretty <code><code></code></p>
<p>Print files backwards using <kbd>tac</kbd></p>
<p>To stop a process, hit <kbd>ctrl + c</kbd></p>
<pre><code>function add(x, y) {
return x + y;
}
</code></pre>
```

View file

@ -0,0 +1,45 @@
---
title: Images
description: PaperCSS Images
---
### Responsive
Images by default are responsive
<img src="https://unsplash.it/900" alt="Random Unsplash">
#### Code:
```html
<img src="https://unsplash.it/900" alt="Random Unsplash">
```
### Float
You can also float responsive images to fit neatly with your text
<img src="https://unsplash.it/200" alt="Smaller Unsplash" class="float-left"> Lorem ipsum dolor sit amet, consectetur adipiscing elit. Curabitur non elit sed lorem vulputate consectetur sed vel orci. Nunc orci metus, hendrerit viverra diam a, viverra efficitur nisi. Suspendisse ante sapien, porta vitae augue et, pulvinar posuere nibh. Suspendisse id commodo sem, vestibulum malesuada erat. Duis luctus est sit amet nisl maximus porta. Curabitur tempor nisi tincidunt ultricies rutrum. Nam finibus turpis ut nibh dignissim, in tincidunt mauris suscipit. Curabitur sollicitudin mi quis orci semper, nec egestas nibh mollis. Aenean pellentesque lectus rutrum, ultrices felis malesuada, finibus purus. Morbi eleifend pellentesque justo, quis vestibulum mi. Donec porta ipsum tellus, ac scelerisque lectus pellentesque eget. Etiam quis rutrum dui. Nulla facilisi. Donec imperdiet mattis mi nec fringilla. Donec mollis augue sed viverra placerat. Donec varius, sem sed porttitor euismod, est nunc varius tellus, eget molestie urna arcu ac turpis. Phasellus id sem elit. Vivamus pellentesque mauris vel ex laoreet varius. Vivamus non tempor libero. Nam consectetur nisi erat, ac varius elit porttitor quis. Morbi ullamcorper, tortor in sagittis tempus, justo ipsum pretium urna, ut bibendum nisl orci et eros. Quisque ut ipsum neque. Integer sapien dolor, vestibulum id maximus ac, pharetra eu augue.
<img src="https://unsplash.it/100" alt="Smallerer Unsplash" class="float-right"> Aenean mauris tellus, facilisis sed quam non, tincidunt rutrum risus. Fusce quam urna, commodo vitae nunc condimentum, efficitur commodo libero. Sed dignissim odio enim, ac pharetra dui laoreet id. Suspendisse nec accumsan erat. Integer sit amet leo arcu. Proin sagittis blandit tempor. Vivamus at egestas lectus. Mauris eros tellus, egestas ac neque eget, lacinia sagittis ante. Phasellus faucibus suscipit erat, eget malesuada neque congue non.
#### Code:
```html
<p>
<img src="https://unsplash.it/200" class="float-left">
Lorem ipsum dolor.......
<img src="https://unsplash.it/100" class="float-right">
Aenean mauris tellus......
</p>
```
### No Responsive & No Borders
If you don't like the default, you can just add the class `no-responsive` to prevent the image from being responsive. You can also remove the default border with `no-border`.
<img src="https://unsplash.it/300" alt="Not responsive Unsplash" class="no-responsive no-border">
#### Code:
```html
<img src="https://unsplash.it/300" class="no-responsive no-border">
```

View file

@ -0,0 +1,95 @@
---
title: Lists
description: PaperCSS Lists
---
### Ordered Lists
<ol>
<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>
<ol>
<li>What if we went...</li>
<li>One more deeper?</li>
<ol>
<li>DJ</li>
<li>Hanzel</li>
<ol>
<li>Five levels should be enough</li>
<li>Right?</li>
</ol>
</ol>
</ol>
</ol>
<li>But don't forget this</li>
</ol>
### Unordered 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>
<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>
<ul>
<li>LEVEL 5</li>
</ul>
</ul>
</ul>
</ul>
<li>And now we're are the top!</li>
</ul>
### Inline List
<ul class="inline">
<li>Item 1</li>
<li>Item 2</li>
<li>Item 3</li>
<li>Item 4</li>
</ul>
#### Codes:
```html
<ol>
<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>
<ol>
<li>What if we went...</li>
<li>One more deeper?</li>
<ol>
<li>DJ</li>
<li>Hanzel</li>
<ol>
<li>Five levels should be enough</li>
<li>Right?</li>
</ol>
</ol>
</ol>
</ol>
<li>But don't forget this</li>
</ol>
<!-- Replace ol with ul for unordered lists. Go up to 5 levels deep! -->
<!-- For inline lists -->
<ul class="inline">...</ul>
```

View file

@ -0,0 +1,140 @@
---
title: Tables
description: PaperCSS Tables
---
### Regular
<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>
### Hover
<table class="table-hover">
<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>
### Alternating
<table class="table-alternating">
<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>
#### Code:
```html
<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>
<!-- Add table-hover or table-alternating to change the style of the table -->
<table class="table-hover">
<table class="table-alternating">
```

View file

@ -0,0 +1,36 @@
---
title: Typography
description: PaperCSS Typography
---
How pretty is the text?
# Heading 1
## Heading 2
### Heading 3
#### Heading 4
##### Heading 5
###### Heading 6
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Aenean ultrices, eros
non elementum accumsan, massa nulla aliquam libero, ut posuere justo nibh ac
ipsum. Aliquam blandit commodo justo at laoreet. Suspendisse potenti. Duis magna
neque, venenatis non libero a, tincidunt convallis diam. Donec vel fermentum
ante. Quisque diam nisl, vestibulum imperdiet sapien nec, interdum fringilla
lorem. Morbi sed arcu facilisis, maximus justo vel, porttitor nisl. Nam suscipit
metus facilisis iaculis vestibulum.
```html
<h1>Heading 1</h1>
<h2>Heading 2</h2>
<h3>Heading 3</h3>
<h4>Heading 4</h4>
<h5>Heading 5</h5>
<h6>Heading 6</h6>
<p>Lorem ipsum dolor....</p>
```

View file

@ -0,0 +1,4 @@
---
title: Layout
description: PaperCSS Layout
---

View file

@ -0,0 +1,149 @@
---
title: Flexbox
description: PaperCSS Flexbox
---
### Flexgrid
The flexgrid is a grid system that supports up to 12 columns per row. Because it
uses flexbox (rather than just %widths), we also get the benefit of the fun
parts of flexbox like alignment in more complex ways than normal.
<div class="demo">
<div class="row">
<div class="col-4 col">col-4 col</div>
<div class="col-4 col">col-4 col</div>
<div class="col-4 col">col-4 col</div>
</div>
<div class="row">
<div class="col-3 col">col-3 col</div>
<div class="col-9 col">col-9 col</div>
</div>
<div class="row">
<div class="sm-6 md-8 lg-10 col">sm-6 md-8 lg-10 col</div>
<div class="sm-6 md-4 lg-2 col">sm-6 md-4 lg-2 col</div>
</div>
<div class="row">
<div class="sm-5 col">sm-5 col</div>
<div class="col-fill col">col-fill col</div>
<div class="col-fill col">col-fill col</div>
</div>
<div class="row">
<div class="sm-4 col">Aligned</div>
<div class="sm-4 col">Left (default)</div>
</div>
<div class="row flex-right">
<div class="sm-4 col">Aligned</div>
<div class="sm-4 col">Right (flex-right)</div>
</div>
<div class="row flex-center">
<div class="sm-4 col">Aligned</div>
<div class="sm-4 col">Center (flex-center)</div>
</div>
<div class="row flex-edges">
<div class="sm-4 col">Aligned</div>
<div class="sm-4 col">to edges (flex-edges)</div>
</div>
<div class="row flex-spaces">
<div class="sm-4 col">Aligned</div>
<div class="sm-4 col">to be evenly spaced (flex-spaces)</div>
</div>
<div class="row flex-top">
<div class="sm-4 col">Aligned top</div>
<div class="sm-4 col">Aligned top</div>
<div class="sm-4 col">
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.
</div>
</div>
<div class="row flex-middle">
<div class="sm-4 col">Aligned middle</div>
<div class="sm-4 col">Aligned middle</div>
<div class="sm-4 col">
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.
</div>
</div>
<div class="row flex-bottom">
<div class="sm-4 col">Aligned bottom</div>
<div class="sm-4 col">Aligned bottom</div>
<div class="sm-4 col">
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.
</div>
</div>
<div class="row">
<div class="sm-3 col align-bottom">Align bottom</div>
<div class="sm-3 col align-middle">Align middle</div>
<div class="sm-3 col align-top">Align top</div>
<div class="sm-3 col">
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.
</div>
</div>
</div>
#### Code:
```html
<div class="row">
<div class="col-4 col">col-4 col</div>
<div class="col-4 col">col-4 col</div>
<div class="col-4 col">col-4 col</div>
</div>
<div class="row">
<div class="col-3 col">col-3 col</div>
<div class="col-9 col">col-9 col</div>
</div>
<div class="row">
<div class="sm-6 md-8 lg-10 col">sm-6 md-8 lg-10 col</div>
<div class="sm-6 md-4 lg-2 col">sm-6 md-4 lg-2 col</div>
</div>
<div class="row">
<div class="sm-5 col">sm-5 col</div>
<div class="col-fill col">col-fill col</div>
<div class="col-fill col">col-fill col</div>
</div>
<div class="row">
<div class="sm-4 col">Aligned</div>
<div class="sm-4 col">Left (default)</div>
</div>
<div class="row flex-right">
<div class="sm-4 col">Aligned</div>
<div class="sm-4 col">Right (flex-right)</div>
</div>
<div class="row flex-center">
<div class="sm-4 col">Aligned</div>
<div class="sm-4 col">Center (flex-center)</div>
</div>
<div class="row flex-edges">
<div class="sm-4 col">Aligned</div>
<div class="sm-4 col">to edges (flex-edges)</div>
</div>
<div class="row flex-spaces">
<div class="sm-4 col">Aligned</div>
<div class="sm-4 col">to be evenly spaced (flex-spaces)</div>
</div>
<div class="row flex-top">
<div class="sm-6 col">Aligned top</div>
<div class="sm-6 col">
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.
</div>
</div>
<div class="row flex-middle">
<div class="sm-6 col">Aligned middle</div>
<div class="sm-6 col">
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.
</div>
</div>
<div class="row flex-bottom">
<div class="sm-6 col">Aligned bottom</div>
<div class="sm-6 col">
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.
</div>
</div>
<div class="row">
<div class="sm-3 col align-bottom">Align bottom</div>
<div class="sm-3 col align-middle">Align middle</div>
<div class="sm-3 col align-top">Align top</div>
<div class="sm-3 col">
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.
</div>
</div>
```

View file

@ -0,0 +1,4 @@
---
title: Utilities
description: PaperCSS Utilities
---

View file

@ -0,0 +1,170 @@
---
title: Borders & Shadows
slug: borders
description: PaperCSS Borders & Shadows
---
### Borders
<div class="row flex-spaces">
<div class="sm-3 col border border-primary">Default Border</div>
<div class="sm-3 col border border-2 border-primary">Border-2</div>
<div class="sm-3 col border border-3 border-primary">Border-3</div>
</div>
<div class="row flex-spaces">
<div class="sm-3 col border border-4 border-primary">Border-4</div>
<div class="sm-3 col border border-5 border-primary">Border-5</div>
<div class="sm-3 col border border-6 border-primary">Border-6</div>
</div>
#### Code:
```html
<div class="row flex-spaces">
<div class="sm-3 col border border-primary">Default Border</div>
<div class="sm-3 col border border-2 border-primary">Border-2</div>
<div class="sm-3 col border border-3 border-primary">Border-3</div>
</div>
<div class="row flex-spaces">
<div class="sm-3 col border border-4 border-primary">Border-4</div>
<div class="sm-3 col border border-5 border-primary">Border-5</div>
<div class="sm-3 col border border-6 border-primary">Border-6</div>
</div>
```
### Border Colors
<div class="row child-borders">
<div class="sm-2 col border border-primary">Border primary</div>
<div class="sm-2 col border border-secondary">Border secondary</div>
<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>
#### Code:
```html
<div class="row child-borders">
<div class="sm-2 col border border-primary">Border primary</div>
<div class="sm-2 col border border-secondary">Border secondary</div>
<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>
<div class="row child-borders">
<div class="sm-2 col border border-primary">Border primary</div>
<div class="sm-2 col border border-secondary">Border secondary</div>
<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>
```
### Child Borders
Use this if you want all children to have a border. This will alternate through the different border styles defined above instead of having to add the border class for each element.
<div class="row flex-center child-borders">
<div class="sm-2 col">1</div>
<div class="sm-2 col">2</div>
<div class="sm-2 col">3</div>
<div class="sm-2 col">4</div>
<div class="sm-2 col">5</div>
<div class="sm-2 col">6</div>
</div>
#### Code:
```html
<div class="row flex-center child-borders">
<div class="sm-2 col">1</div>
<div class="sm-2 col">2</div>
<div class="sm-2 col">3</div>
<div class="sm-2 col">4</div>
<div class="sm-2 col">5</div>
<div class="sm-2 col">6</div>
</div>
```
### Border Styles
<div class="row flex-spaces child-borders">
<div class="sm-3 col border-dashed">Dashed</div>
<div class="sm-3 col border-dotted">Dotted</div>
<div class="sm-3 col border-dashed border-thick">Dashed Thick</div>
<div class="sm-3 col border-dotted border-thick">Dotted Thick</div>
</div>
#### Code:
```html
<div class="row flex-spaces child-borders">
<div class="sm-3 col border-dashed">Dashed</div>
<div class="sm-3 col border-dotted">Dotted</div>
<div class="sm-3 col border-dashed border-thick">Dashed Thick</div>
<div class="sm-3 col border-dotted border-thick">Dotted Thick</div>
</div>
```
### Shadows
<div class="row flex-spaces child-borders">
<div class="sm-3 col shadow shadow-large">Large</div>
<div class="sm-3 col shadow">Default</div>
<div class="sm-3 col shadow shadow-small">Small</div>
<div class="sm-3 col shadow shadow-hover">Hover</div>
</div>
#### Code:
```html
<div class="row flex-spaces child-borders">
<div class="sm-3 col shadow shadow-large">Large</div>
<div class="sm-3 col shadow">Default</div>
<div class="sm-3 col shadow shadow-small">Small</div>
<div class="sm-3 col shadow shadow-hover">Hover</div>
</div>
```
### Child Shadows
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>
#### Code:
```html
<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>
```
### Child Shadows Hover
Use this if you want all children to have a shadow... that changes on hover
<div class="row flex-spaces child-borders child-shadows-hover">
<div class="sm-3 col">Shadow</div>
<div class="sm-3 col">Shadow</div>
<div class="sm-3 col">Shadow</div>
</div>
#### Code:
```html
<div class="row flex-spaces child-borders child-shadows-hover">
<div class="sm-3 col">Shadow</div>
<div class="sm-3 col">Shadow</div>
<div class="sm-3 col">Shadow</div>
</div>
```

View file

@ -0,0 +1,45 @@
---
title: Colors
description: PaperCSS Colors
---
### Text
<p class="text-primary">Text primary</p>
<p class="text-secondary">Text secondary</p>
<p class="text-success">Text success</p>
<p class="text-warning">Text warning</p>
<p class="text-danger">Text danger</p>
<p class="text-muted">Text muted</p>
#### Code:
```html
<p class="text-primary">Text primary</p>
<p class="text-secondary">Text secondary</p>
<p class="text-success">Text success</p>
<p class="text-warning">Text warning</p>
<p class="text-danger">Text danger</p>
<p class="text-muted">Text muted</p>
```
### Backgrounds
<div class="row flex-center">
<div class="sm-2 col background-primary">Background primary</div>
<div class="sm-2 col background-secondary">Background secondary</div>
<div class="sm-2 col background-success">Background success</div>
<div class="sm-2 col background-warning">Background warning</div>
<div class="sm-2 col background-danger">Background danger</div>
</div>
#### Code:
```html
<div class="row flex-center">
<div class="sm-2 col background-primary">Background primary</div>
<div class="sm-2 col background-secondary">Background secondary</div>
<div class="sm-2 col background-success">Background success</div>
<div class="sm-2 col background-warning">Background warning</div>
<div class="sm-2 col background-danger">Background danger</div>
</div>
```

View file

@ -0,0 +1,38 @@
---
title: Spacing
description: PaperCSS Spacing
---
### Margin
<div class="row flex-spaces child-borders">
<div class="sm-3 col margin">Margin</div>
<div class="sm-3 col margin-large">Margin-large</div>
<div class="sm-3 col margin-top-small">Margin-top-small</div>
</div>
#### Code:
```html
<div class="row flex-spaces child-borders">
<div class="sm-3 col margin">Margin</div>
<div class="sm-3 col margin-large">Margin-large</div>
<div class="sm-3 col margin-top-small">Margin-top-small</div>
</div>
```
### Padding
<div class="row flex-spaces child-borders">
<div class="sm-3 col padding-small">Padding-small</div>
<div class="sm-3 col padding-none">Padding-none</div>
<div class="sm-3 col padding-left-large">Padding-left-large</div>
</div>
#### Code:
```html
<div class="row flex-spaces child-borders">
<div class="sm-3 col padding-small">Padding-small</div>
<div class="sm-3 col padding-none">Padding-none</div>
<div class="sm-3 col padding-left-large">Padding-left-large</div>
</div>
```

View file

@ -0,0 +1,13 @@
<div class='col sm-6 md-4'>
<div class='card'>
<div class="card-body">
<h4 class="card-title">{{- .Title -}}</h4>
<div class="card-text">
{{- .Params.description -}}
</div>
<a class='paper-btn btn-block' href='{{ .Permalink | relURL }}'>
Let's see!
</a>
</div>
</div>
</div>

View file

@ -0,0 +1,31 @@
{{ partial "header" . }}
<div class='section'>
<h2>{{ .Title }}</h2>
{{ .Content }}
<div class='row flex-spaces'>
{{ range .Sections }}
<div class='collapsible full-width'>
<input id='collapsible-section-{{ .Title | urlize }}' type='checkbox' name='collapsible-section' checked>
<label for="collapsible-section-{{ .Title | urlize }}">{{ .Title }}</label>
<div class='collapsible-body'>
<div class="row child-borders">
{{ range .Pages }}
<a class="paper-btn margin" href='{{ .Permalink | relURL }}'>{{- .Title -}}</a>
{{ end }}
</div>
</div>
</div>
{{ end }}
{{ range .Pages }}
{{ .Render "li" }}
{{ end }}
</div>
</div>
{{ partial "footer" . }}

View file

@ -0,0 +1,8 @@
{{ partial "header" . }}
<div class='section'>
<h2>{{ .Title }}</h2>
{{ .Content }}
</div>
{{ partial "footer" . }}

8
docs/layouts/index.html Normal file
View file

@ -0,0 +1,8 @@
{{ partial "header" . }}
<div class='section'>
<h2>{{ .Title }}</h2>
{{ .Content }}
</div>
{{ partial "footer" . }}

View file

@ -0,0 +1,12 @@
{{- $title := ( .Title ) -}}
{{- $siteTitle := ( .Site.Title ) -}}
{{- $title404 := ( .Site.Params.info.title404 | default $title ) -}}
{{- $sep := ( .Site.Params.seo.titleSeparator | default "•" ) -}}
{{- if .IsHome -}}
{{ print $siteTitle " " $sep " " $.Site.Params.info.description }}
{{- else if eq .Kind "404" -}}
{{ $title404 }} {{ $sep }} {{ $siteTitle }}
{{- else -}}
{{ $title }} {{ $sep }} {{ $siteTitle }}
{{- end -}}

View file

@ -0,0 +1,7 @@
</div>
</div>
{{ partial "nav/sidebar" . }}
</div>
</body>
</html>

View file

@ -0,0 +1,8 @@
<head>
{{ partial "head/meta" . }}
<title>{{ partial "data/title" . }}</title>
<link rel='canonical' href='{{ .Permalink }}'>
{{ partial "head/includes" . }}
</head>

View file

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

View file

@ -0,0 +1,11 @@
<meta charset='utf-8'>
<meta name='viewport' content='width=device-width, initial-scale=1'>
<meta name='description' content='The less formal CSS framework.'>
<meta name='author' content='Rhyneav and PaperCSS contributors.'>
<!-- Favicon -->
<link rel='shortcut icon' href='/favicon.ico' type='image/x-icon'>
{{ partial "head/opengraph" . }}
{{ .Hugo.Generator }}

View file

@ -0,0 +1,8 @@
<!-- Twitter -->
<meta name="twitter:description" content="The less formal CSS framework">
<meta name="twitter:title" content="PaperCSS">
<!-- OpenGraph -->
<meta property="og:url" content="https://www.getpapercss.com/">
<meta property="og:title" content="PaperCSS">
<meta property="og:description" content="The less formal CSS framework">

View file

@ -0,0 +1,24 @@
<!DOCTYPE html>
<html>
{{ partial "head/head" . }}
<body>
<div id='top' class='row site'>
<div class='sm-12 md-8 col'>
<div class='paper'>
<div class='demo-title'>
<div class='row flex-center'>
<div class='text-center'>
<h1>{{ .Site.Title }}</h1>
<h3>{{ .Site.Params.info.description }}</h3>
</div>
</div>
{{ partial "nav/main" . }}
</div>
<div class="to-top">
<a href="#top" class="paper-btn margin">^</a>
</div>

View file

@ -0,0 +1,9 @@
<div class="row flex-center child-borders">
{{ range .Site.Menus.main }}
{{- $isCurrent := ( or ( $.IsMenuCurrent "main" . ) ( $.HasMenuCurrent "main" . ) ) -}}
<a class='paper-btn margin{{- if $isCurrent }} current{{- end -}}' href='{{ .URL }}'>
{{- .Name -}}
</a>
{{ end }}
<a href="https://github.com/rhyneav/papercss" target="_blank" class="paper-btn margin">Github</a>
</div>

View file

@ -0,0 +1,31 @@
<div class='sm-12 md-4 col sidebar'>
{{ range .Site.Sections }}
<div class='paper'>
<h3 class='sidebar-title' style='text-align:center'>
<a href='/docs'>Documentation</a>
</h3>
<div class='row'>
{{ range .Sections }}
<div class='collapsible full-width'>
<input id='collapsible-{{ .Title | urlize }}' type='radio' name='collapsible'>
<label for="collapsible-{{ .Title | urlize }}">{{ .Title }}</label>
<div class="collapsible-body">
<ul>
{{ range .Pages }}
<li>
<a href='{{ .Permalink | relURL }}'>{{ .Title }}</a>
</li>
{{ end }}
</ul>
</div>
</div>
{{ end }}
</div>
</div>
{{ 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>
</div>
</div>
</div>

View file

@ -0,0 +1,3 @@
<button {{- with .Get 0 }} class='btn-{{- . -}}' {{- end -}}>
{{ .Inner }}
</button>

View file

@ -1,8 +1,11 @@
body {
background-image: url("/img/geometry2.png")
}
#top {
max-width: 1440px;
}
.demo .row .col {
background-color: #eee;
background-color: #eee;
}
.demo .row .col:nth-child(even) {
background-color: #ddd;
@ -12,7 +15,7 @@ body {
margin-bottom: 2rem;
}
.summary a {
color: #41403e;
color: #41403e;
}
img.no-responsive {
max-width: -webkit-fill-available;
@ -36,4 +39,11 @@ img.no-responsive {
}
.demo-title:hover + .to-top {
opacity: 0
}
}
.sidebar-title a {
color: inherit;
background: none;
}
.collapsible.full-width {
width: 100%;
}

View file

Before

Width:  |  Height:  |  Size: 17 KiB

After

Width:  |  Height:  |  Size: 17 KiB

View file

Before

Width:  |  Height:  |  Size: 2.1 KiB

After

Width:  |  Height:  |  Size: 2.1 KiB

View file

@ -1,41 +1,68 @@
'use strict';
const gulp = require('gulp'),
connect = require('gulp-connect'),
less = require('gulp-less'),
cleanCSS = require('gulp-clean-css'),
rename = require('gulp-rename');
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');
gulp.task('webserver', function() {
connect.server({
livereload: true
});
});
gulp.task('less', function() {
gulp.src('src/styles.less')
.pipe(less())
gulp.task('sass', function() {
gulp.src('src/**/*.scss')
.pipe(sass.sync().on('error', sass.logError))
.pipe(cleanCSS({format: 'beautify'}))
.pipe(rename('paper.css'))
.pipe(gulp.dest('dist'))
.pipe(connect.reload());
.pipe(gulp.dest('docs/static/assets'));
});
gulp.task('watch', function() {
gulp.watch('src/*.less', ['less']);
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', () => {
gulp.src('dist/paper.css')
.pipe(cleanCSS())
.pipe(rename('paper.min.css'))
.pipe(gulp.dest('dist'));
return gulp.src('src/**/*.scss')
.pipe(sass({outputStyle: 'compressed'}).on('error', sass.logError))
.pipe(rename('paper.min.css'))
.pipe(gulp.dest('dist'))
.pipe(gulp.dest('docs/static/assets'));
});
gulp.task('components', () => {
gulp.src('src/*.less')
.pipe(less())
.pipe(cleanCSS({format: 'beautify'}))
.pipe(gulp.dest('dist/components'));
});
gulp.task('lint-css', function() {
return gulp.src('src/**/*.scss')
.pipe(gulpStylelint({
reporters: [
{formatter: 'string', console: true}
]
}));
})
gulp.task('default', ['less', 'webserver', 'watch']);
gulp.task('build', ['components', 'less', 'minify-css']);
gulp.task('default', ['sass','watch','hugo-server']);
gulp.task('build', ['sass','minify-css','hugo-build']);
gulp.task('postinstall', ['sass','minify-css']);

1330
index.html

File diff suppressed because it is too large Load diff

6
netlify.toml Normal file
View file

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

8854
package-lock.json generated

File diff suppressed because it is too large Load diff

View file

@ -1,38 +1,45 @@
{
"name": "papercss",
"version": "1.3.1",
"version": "1.5.4",
"description": "The less formal CSS framework.",
"main": "index.js",
"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 build"
"postinstall": "gulp postinstall",
"stylelint": "node_modules/stylelint/bin/stylelint.js 'src/**/*.scss'"
},
"repository": {
"type": "git",
"url": "git+https://github.com/rhyneav/papercss.git"
"url": "git+https://github.com/papercss/papercss.git"
},
"author": "Rhyne Vlaservich <rhyneav@gmail.com>",
"license": "ISC",
"bugs": {
"url": "https://github.com/rhyneav/papercss/issues"
"url": "https://github.com/papercss/papercss/issues"
},
"homepage": "https://github.com/rhyneav/papercss#readme",
"homepage": "https://www.getpapercss.com",
"dependencies": {
"gulp": "3.9.1",
"gulp-clean-css": "3.9.0",
"gulp-connect": "5.0.0",
"gulp-less": "3.3.2",
"gulp-plumber": "1.1.0",
"gulp-rename": "1.2.2",
"gulp-watch-less": "1.0.1",
"less": "2.7.2"
"gulp-sass": "^3.1.0",
"optional": "^0.1.4"
},
"devDependencies": {
"browserify": "^14.1.0",
"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",
@ -46,9 +53,10 @@
"karma-requirejs": "^1.1.0",
"mocha": "^4.0.1",
"nodemon": "^1.11.0",
"npm": "5.3.0",
"npm": "^5.3.0",
"object-merge": "^2.5.1",
"os": "^0.1.1",
"pre-commit": "^1.2.2",
"procfile": "^0.1.1",
"quixote": "^0.14.0",
"request": "^2.83.0",
@ -57,6 +65,14 @@
"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"
}
},
"pre-commit": [
"stylelint"
]
}

View file

@ -1,21 +0,0 @@
@import './colors.less';
@import './borders.less';
.alert{
.border;
padding: 15px;
margin-bottom: 20px;
width: 100%;
}
.make-alert-color-classes(@a: length(@colors)) when (@a > 0) {
.make-alert-color-classes(@a - 1);
@color: extract(@colors, @a);
.alert-@{color} {
border-color: @@color;
color: @@color;
background-color: ~"@{@{color}-light}";
}
}
.make-alert-color-classes();

View file

@ -1,27 +0,0 @@
@import './colors.less';
article {
.article-title {
font-size: 3rem;
}
.article-meta {
font-size: 15px;
color: @muted;
a {
color: @muted-text;
background-image: none;
&:hover {
color: @light-dark;
}
}
}
.text-lead {
font-size: 30px;
line-height: 1.3;
margin: 35px 0px;
}
}

View file

@ -1,28 +0,0 @@
@import './colors.less';
@import './borders.less';
.badge {
.border;
display: inline-block;
padding: .25em .4em;
font-size: 75%;
font-weight: 700;
line-height: 1;
text-align: center;
white-space: nowrap;
vertical-align: baseline;
background-color: @muted;
color: white;
border-color: transparent;
}
.make-badge-color-classes(@i: length(@colors)) when (@i > 0) {
.make-badge-color-classes(@i - 1);
@color: extract(@colors, @i);
.badge.@{color} {
background-color: @@color;
}
}
.make-badge-color-classes();

View file

@ -1,66 +0,0 @@
@import './colors.less';
.border {
border: 2px solid @primary;
}
.border, .border-1, .child-borders > *:nth-child(6n+1) {
border-top-left-radius: 255px 15px;
border-top-right-radius: 15px 225px;
border-bottom-right-radius: 225px 15px;
border-bottom-left-radius: 15px 255px;
}
.border-2, .child-borders > *:nth-child(6n+2) {
border-top-left-radius: 125px 25px;
border-top-right-radius: 10px 205px;
border-bottom-right-radius: 20px 205px;
border-bottom-left-radius: 185px 25px;
}
.border-3, .child-borders > *:nth-child(6n+3) {
border-top-left-radius: 15px 225px;
border-top-right-radius: 255px 15px;
border-bottom-left-radius: 225px 15px;
border-bottom-right-radius: 15px 255px;
}
.border-4, .child-borders > *:nth-child(6n+4) {
border-top-left-radius: 15px 225px;
border-top-right-radius: 25px 150px;
border-bottom-left-radius: 25px 115px;
border-bottom-right-radius: 155px 25px;
}
.border-5, .child-borders > *:nth-child(6n+5) {
border-top-left-radius: 250px 15px;
border-top-right-radius: 25px 80px;
border-bottom-left-radius: 20px 115px;
border-bottom-right-radius: 15px 105px;
}
.border-6, .child-borders > *:nth-child(6n+6) {
border-top-left-radius: 28px 125px;
border-top-right-radius: 100px 30px;
border-bottom-right-radius: 20px 205px;
border-bottom-left-radius: 15px 225px;
}
.child-borders > * {
border: 2px solid @primary;
}
.border-white {
border-color: @white;
}
.border-dotted {
border-style: dotted;
}
.border-dashed {
border-style: dashed;
}
.border-thick {
border-width: 5px;
}
.make-border-color-classes(@i: length(@colors)) when (@i > 0) {
.make-border-color-classes(@i - 1);
@color: extract(@colors, @i);
.border-@{color} {
border-color: @@color;
}
}
.make-border-color-classes();

View file

@ -1,8 +0,0 @@
// Why is box sizing not the default?
// https://www.paulirish.com/2012/box-sizing-border-box-ftw/
html {
box-sizing: border-box;
}
*, *:before, *:after {
box-sizing: inherit;
}

View file

@ -1,83 +0,0 @@
@import './colors.less';
@import './shadows.less';
@import './borders.less';
@import './forms.less'; // .disabled
button, .paper-btn, [type="button"] {
.shadow;
align-self:center;
background:transparent;
transition:all .5s ease, background-color .1s ease;
color: @primary;
display: inline;
outline:none;
border:solid 2px @primary;
.border;
font-size: 1rem;
padding: .75rem .75rem;
cursor: pointer;
.shadow;
.shadow-hover;
&.btn-large {
.shadow-large;
font-size:2rem;
padding:1rem 1rem;
}
&.btn-small {
.shadow-small;
font-size: .75rem;
padding: .5rem;
}
&.btn-block {
display: block;
width: 100%;
}
&:hover {
.shadow-hover;
}
&:focus{
border: 2px solid @secondary;
-webkit-box-shadow:2px 8px 4px -6px hsla(0,0%,0%,.3);
-moz-box-shadow:2px 8px 4px -6px hsla(0,0%,0%,.3);
box-shadow:2px 8px 4px -6px hsla(0,0%,0%,.3);
}
&:active {
border-color: hsla(0,0%,0%,.2);
transition: none;
}
&.disabled, &[disabled] {
.disabled;
}
}
a {
text-decoration: none;
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-repeat:repeat-x;
background-size: 4px 3px;
background-position:0 90%;
&:visited {
text-decoration: none;
color: @primary;
}
}
.make-button-color-classes(@i: length(@colors)) when (@i > 0) {
.make-button-color-classes(@i - 1);
@color: extract(@colors, @i);
button.btn-@{color}, .paper-btn.btn-@{color}, [type="button"].btn-@{color} {
border-color: @@color;
background-color: ~"@{@{color}-light}";
color: ~"@{@{color}-text}";
&:hover:active{
@darkcolour: ~"@{color}-light";
background-color: darken(@@darkcolour, 10%);
}
}
}
.make-button-color-classes();

View file

@ -1,38 +0,0 @@
@import './colors.less';
code {
padding: 2px 4px;
font-size: 80%;
color: @secondary;
background-color: lighten(@primary, 70%);
border-radius: 3px;
}
kbd {
padding: 2px 4px;
font-size: 80%;
color: @white;
background-color: @primary;
border-radius: 3px;
}
pre {
display: block;
padding: 1em;
font-size: 80%;
line-height: 1.5;
color: @primary;
word-break: break-all;
word-wrap: break-word;
background-color: lighten(@primary, 73%);
border: 1px solid lighten(@primary, 50%);
border-radius: 3px;
overflow-x: auto;
white-space: pre;
}
pre code{
color: inherit;
background: transparent;
display: block;
font-size: inherit;
padding: initial;
white-space:pre;
}

View file

@ -1,41 +0,0 @@
@primary: #41403E;
@secondary: #0071DE;
@success: #86a361;
@warning: #ddcd45;
@danger: #a7342d;
@muted: #868e96;
@primary-light: lighten(@primary, 50%);
@secondary-light: lighten(@secondary, 50%);
@success-light: lighten(@success, 30%);
@warning-light: lighten(@warning, 30%);
@danger-light: lighten(@danger, 45%);
@muted-light: lighten(@muted, 35%);
@white-dark: rgba(0, 0, 0, 0.03);
@light-dark: rgba(0, 0, 0, 0.7);
@white: rgba(255, 255, 255, 1);
@main-background: rgba(255, 255, 255, 1);
@primary-text: #FFF;
@secondary-text: @primary;
@success-text: @primary;
@warning-text: @primary;
@danger-text: @primary;
@muted-text: @primary;
@colors: primary, secondary, success, warning, danger, muted;
.make-text-color-classes(@i: length(@colors)) when (@i > 0) {
.make-text-color-classes(@i - 1);
@color: extract(@colors, @i);
.text-@{color} {
color: @@color;
}
.background-@{color}{
background-color: ~"@{@{color}-light}";
}
}
.make-text-color-classes();

View file

@ -0,0 +1,49 @@
.collapsible {
display: flex;
flex-direction: column;
&:nth-of-type(1) {
border-top: 1px solid $muted-light;
}
.collapsible-body {
@include transition;
background-color: lighten($white-dark, 80%);
border-bottom: 1px solid $muted-light;
margin: 0;
max-height: 0;
opacity: 0;
overflow: hidden;
padding: 0 0.75rem;
}
input {
display: none;
&:checked + label {
color: $primary;
}
&[id^='collapsible']:checked~div.collapsible-body {
margin: 0;
max-height: 960px;
opacity: 1;
padding: 0.75rem;
}
}
label {
border-bottom: 1px solid $muted-light;
color: $primary;
display: inline-block;
font-weight: 600;
margin: 0 0 -1px;
padding: 0.75rem;
text-align: center;
&:hover {
color: $muted;
cursor: pointer;
}
}
}

View file

@ -0,0 +1,15 @@
.alert {
@include border-style();
border: 2px solid $primary;
margin-bottom: 20px;
padding: 15px;
width: 100%;
}
@each $colorName, $color, $color-light in $colors {
.alert-#{$colorName} {
background-color: $color-light;
border-color: $color;
color: $color;
}
}

View file

@ -0,0 +1,38 @@
article {
.article-title {
font-size: 3rem;
}
.article-meta {
color: $muted;
font-size: 15px;
a {
background-image: none;
color: $muted-text;
&:hover {
color: $light-dark;
}
}
}
.text-lead {
font-size: 30px;
line-height: 1.3;
margin: 35px;
}
button {
&:not(:first-of-type) {
margin-left: 2rem;
@include resp(xs) {
margin-left: 0;
}
}
}
p {
line-height: 1.6;
}
}

View file

@ -0,0 +1,21 @@
.badge {
@include border-style();
background-color: $muted;
border: 2px solid $primary;
border-color: transparent;
color: $white;
display: inline-block;
font-size: 75%;
font-weight: 700;
line-height: 1;
padding: 0.25em 0.4em;
text-align: center;
vertical-align: baseline;
white-space: nowrap;
}
@each $colorName, $color in $colors {
.badge.#{$colorName} {
background-color: $color;
}
}

View file

@ -0,0 +1,98 @@
button,
.paper-btn,
[type='button'] {
@include border-style();
@include shadow();
@include transition();
align-self: center;
background: transparent;
border: 2px solid $primary;
color: $primary;
cursor: pointer;
display: inline;
font-size: 1rem;
outline: none;
padding: 0.75rem;
@include resp(520px) {
display: inline-block;
margin: 0 auto;
margin-bottom: 1rem;
text-align: center;
}
&.btn-large {
@include shadow(large);
font-size: 2rem;
padding: 1rem;
}
&.btn-small {
@include shadow(small);
font-size: 0.75rem;
padding: 0.5rem;
}
&.btn-block {
display: block;
width: 100%;
}
&:hover {
@include shadow(hover);
}
&:focus {
border: 2px solid $secondary;
-webkit-box-shadow: 2px 8px 4px -6px hsla(0, 0%, 0%, 0.3);
-moz-box-shadow: 2px 8px 4px -6px hsla(0, 0%, 0%, 0.3);
box-shadow: 2px 8px 4px -6px hsla(0, 0%, 0%, 0.3);
}
&:active {
border-color: hsla(0, 0%, 0%, 0.2);
transition: none;
}
&.disabled,
&[disabled] {
cursor: not-allowed;
opacity: 0.5;
}
}
a {
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;
background-size: 4px 3px;
text-decoration: none;
&:visited {
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;
&:hover {
&:active {
background-color: darken($color-light, 10%);
}
}
}
}

View file

@ -1,49 +1,52 @@
@import './colors.less';
@import './shadows.less';
.card {
.shadow;
.shadow-hover;
position: relative;
@include shadow;
backface-visibility: hidden;
border: 2px solid $muted-light;
display: flex;
flex-direction: column;
position: relative;
will-change: transform;
word-wrap: break-word;
border: 2px solid @muted-light;
&:hover {
@include shadow(hover);
}
.card-header,
.card-footer {
padding: .75rem 1.25rem;
background-color: @white-dark;
background-color: $white-dark;
padding: 0.75rem 1.25rem;
}
.card-header {
border-bottom: 2px solid @muted-light;
border-bottom: 2px solid $muted-light;
}
.card-footer {
border-top: 2px solid @muted-light;
border-top: 2px solid $muted-light;
}
.card-body {
flex: 1 1 auto;
padding: 1.25rem;
.card-title, h4 {
margin-top: 0;
.card-title,
h4 {
margin-bottom: 0.5rem;
margin-top: 0;
}
.card-subtitle, h5 {
.text-secondary;
margin-top: 0;
.card-subtitle,
h5 {
color: $secondary;
margin-bottom: 0.5rem;
margin-top: 0;
}
.card-text, p {
margin-top: 0;
.card-text,
p {
margin-bottom: 1rem;
margin-top: 0;
}
.card-link + .card-link,

123
src/components/_forms.scss Normal file
View file

@ -0,0 +1,123 @@
input,
select,
textarea {
background: transparent;
border: 2px solid $primary;
border-bottom-left-radius: 15px 255px;
border-bottom-right-radius: 225px 15px;
border-top-left-radius: 255px 15px;
border-top-right-radius: 15px 225px;
color: $primary;
display: block;
font-size: 1rem;
outline: none;
padding: 0.5rem;
&:focus {
border: 2px solid $secondary;
}
&.disabled,
&[disabled] {
@extend .disabled;
}
}
.disabled {
cursor: not-allowed;
opacity: 0.5;
}
.form-group {
margin-bottom: 1rem;
> label,
legend {
display: inline-block;
margin-bottom: 0.5rem;
}
.input-block {
width: 100%;
}
textarea {
max-height: 90vh;
max-width: 100%;
}
textarea.no-resize {
resize: none;
}
// TODO: make these classes implicit. We can find out what class to apply based on its type
.paper-radio,
.paper-check {
cursor: pointer;
display: block;
margin-bottom: 0.5rem;
/* the basic, unchecked style */
input {
border: 0;
display: none;
height: 1px;
margin: -1px;
overflow: hidden;
padding: 0;
position: absolute;
width: 1px;
& + span {
display: block;
&::before {
border: 2px solid $primary;
content: '';
display: inline-block;
height: 1rem;
margin-right: 0.75em;
position: relative;
vertical-align: -0.25em;
width: 1rem;
}
}
/* radio styles */
&[type='radio'] {
& + span::before {
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;
}
&:checked + span::before {
$radio-fill: "data:image/svg+xml,%3Csvg%20xmlns%3D'http%3A//www.w3.org/2000/svg'%20viewBox%3D'0%200%20100%20100'%3E%3Cpath%20fill%3D'#{$secondary}'%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";
background: url('#{str-replace($radio-fill, "#", "%23")}') left center no-repeat;
}
}
/* checkbox styles */
&[type='checkbox'] {
& + span::before {
border-bottom-left-radius: 15px 255px;
border-bottom-right-radius: 225px 15px;
border-top-left-radius: 255px 15px;
border-top-right-radius: 15px 225px;
}
/* checked */
&:checked + span::before {
$check-fill: "data:image/svg+xml,%3Csvg%20xmlns%3D'http%3A//www.w3.org/2000/svg'%20viewBox%3D'0%200%20100%20100'%3E%3Cpath%20stroke%3D'#{$secondary}'%20fill-opacity%3D'0'%20stroke-width%3D'16'%20d%3D'm13,62c0.61067,1.6%201.3045,2.3045%201.75717,2.75716c0.72683,0.72684%201.24283,1.24284%202.07617,2.07617c0.54133,0.54133%201.04116,1.06035%201.82833,1.82383c0.5781,0.5607%201.00502,0.96983%202.02633,1.74417c0.55877,0.42365%201.191,0.84034%201.884,1.284c1.16491,0.74577%201.59777,1.00147%202.5,1.55067c0.4692,0.28561%201.43689,0.86868%201.93067,1.16534c0.99711,0.59904%201.99667,1.19755%202.49283,1.49866c0.98501,0.59779%201.47073,0.89648%201.94733,1.2c1.3971,0.88972%201.83738,1.19736%202.7,1.7955c0.42201,0.29262%201.24022,0.87785%202.05583,1.41917c0.79531,0.52785%201.59376,1.0075%202.38,1.43867c0.74477,0.40842%201.45167,0.75802%202.37817,1.22517c0.76133,0.38387%201.54947,0.82848%202.40717,1.41084c0.7312,0.49647%201.49563,1.08231%202.27884,1.258c0.35564,0.07978%200.14721,-0.95518%200.35733,-1.86867c0.18092,-0.78651%200.98183,-1.2141%200.99983,-2.07867c0.02073,-0.99529%200.07916,-1.79945%200.42533,-2.56133c0.43607,-0.95973%200.53956,-1.66774%200.79617,-2.68183c0.18888,-0.74645%200.39764,-1.31168%200.7785,-2.6235c0.20865,-0.71867%200.41483,-1.48614%200.708,-2.28c0.15452,-0.41843%200.77356,-1.73138%201.348,-2.64133c0.30581,-0.48443%200.65045,-0.97043%201.0065,-1.4745c0.74776,-1.05863%201.1531,-1.60163%201.9375,-2.77084c0.40621,-0.60548%200.80272,-1.23513%201.2045,-1.8765c0.40757,-0.65062%200.81464,-1.31206%201.2315,-1.9755c0.41946,-0.66757%200.83374,-1.34258%201.73067,-2.648c0.44696,-0.65053%200.91436,-1.28356%201.386,-1.9095c0.46972,-0.6234%200.94725,-1.2364%201.422,-1.8465c0.94116,-1.20947%201.86168,-2.40844%202.30367,-3.0105c0.438,-0.59664%200.86246,-1.19396%201.27501,-1.7895c0.40743,-0.58816%200.80352,-1.17234%201.185,-1.7535c1.10526,-1.68381%201.44079,-2.23511%201.77633,-2.7705c0.32878,-0.52461%200.96306,-1.5459%201.27467,-2.04c0.60654,-0.96177%201.20782,-1.88193%201.51051,-2.325c0.59013,-0.86381%201.17888,-1.68032%201.46416,-2.075c0.5498,-0.76063%201.31747,-1.8231%201.77883,-2.4895c0.43918,-0.63437%200.85266,-1.25267%201.45717,-2.15717c0.59549,-0.891%200.96531,-1.46814%201.51466,-2.22933c0.58413,-0.80936%201.12566,-1.40253%201.83801,-2.12333c0.61304,-0.62031%200.45171,-1.48306%200.7045,-2.34733c0.25668,-0.87762%200.75447,-1.62502%201,-2.40983c0.25128,-0.8032%200.7633,-1.39453%201.33217,-2.25417c0.54528,-0.82398%200.73415,-1.6714%201.31516,-2.336c0.55639,-0.63644%201.38658,-1.22588%201.8595,-1.9c0.5082,-0.72441%200.78867,-1.4%201.60266,-1.56667l0.71184,-0.4905'%3E%3C/path%3E%3C/svg%3E";
background: url('#{str-replace($check-fill, "#", "%23")}') left center no-repeat;
}
}
}
}
}
fieldset.form-group {
border: 0;
padding: 0;
}

121
src/components/_modals.scss Normal file
View file

@ -0,0 +1,121 @@
.modal {
@include transition(opacity);
background: rgba(#000, 0.6);
bottom: 0;
flex: 1 1 auto;
left: 0;
opacity: 0;
position: fixed;
right: 0;
text-align: left;
top: 0;
visibility: hidden;
word-wrap: break-word;
z-index: 12;
// modal background
&-bg {
bottom: 0;
cursor: pointer;
left: 0;
position: absolute;
right: 0;
top: 0;
}
.modal-body {
@include transition;
@include translate(-50%, -50%);
backface-visibility: hidden;
background: $white;
border: 2px solid $muted-light;
left: 50%;
padding: 1.25rem;
position: absolute;
top: 0;
@include resp(sm) {
box-sizing: border-box;
width: 90%;
}
}
.btn-close {
@include transition;
color: $primary-light;
cursor: pointer;
font-size: 30px;
height: 1.1rem;
position: absolute;
right: 1rem;
text-decoration: none;
top: 1rem;
width: 1.1rem;
&:hover,
&:active,
&:focus {
color: $primary;
}
}
h4,
.modal-title {
margin-bottom: 0.5rem;
margin-top: 0;
}
h5,
.modal-subtitle {
color: $secondary;
margin-bottom: 0.5rem;
margin-top: 0;
}
p,
.modal-text {
margin-bottom: 1rem;
margin-top: 0;
}
.modal-link+.modal-link,
a+a {
margin-left: 1.25rem;
}
.paper-btn {
background: $white;
display: inline-block;
text-decoration: none;
}
.modal-link,
a {
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;
background-size: 4px 3px;
cursor: pointer;
text-decoration: none;
&:hover,
&:focus,
&:visited {
color: $primary;
text-decoration: none;
}
}
}
.modal-state {
display: none;
&:checked+.modal {
opacity: 1;
visibility: visible;
.modal-body {
top: 50%;
}
}
}

151
src/components/_navbar.scss Normal file
View file

@ -0,0 +1,151 @@
nav {
background-color: $main-background;
display: flex;
padding: 0.3rem;
position: relative;
width: 100%;
z-index: 100;
@include resp(small) {
display: block;
}
.bar1,
.bar2,
.bar3 {
background-color: $primary;
border-bottom: 5px solid $primary;
border-bottom-left-radius: 15px 5px;
border-bottom-right-radius: 15px 3px;
color: $primary;
margin: 6px 0;
transition: 0.4s;
width: 2rem;
}
.collapsible input[id^=collapsible]:checked + button {
.bar1 {
-webkit-transform: rotate(-45deg) translate(-9px, 7px);
transform: rotate(-45deg) translate(-9px, 7px);
}
.bar2 {
opacity: 0;
}
.bar3 {
-webkit-transform: rotate(45deg) translate(-8px, -9px);
transform: rotate(45deg) translate(-8px, -9px);
}
}
&.split-nav {
justify-content: space-between;
}
&.fixed {
left: 0;
position: fixed;
right: 0;
top: 0;
}
div {
margin: 0 1rem;
}
ul.inline {
margin-bottom: 0;
margin-top: 10px;
padding: 0;
}
ul.inline li {
display: inline-block;
margin: 0 0.5rem;
@include resp(small) {
display: block;
margin: 1rem 0;
}
}
a {
background-image: none;
border-bottom: 5px solid $primary;
border-bottom-left-radius: 15px 3px;
border-bottom-right-radius: 15px 5px;
color: $primary;
padding-bottom: 0.1rem;
}
a:hover {
border-bottom: 5px solid $primary-light;
}
ul.inline li a {
font-size: 1.3rem;
}
ul.inline li::before {
content: '';
}
ul {
@include resp(medium) {
text-align: center;
}
}
.nav-brand {
h1,
h2,
h3,
h4,
h5,
h6, {
margin: 0;
margin-bottom: 0.2rem;
}
}
.collapsible input[id^=collapsible]:checked ~ div.collapsible-body {
margin: 0;
max-height: 960px;
opacity: 1;
padding: 0;
}
.collapsible:nth-of-type(1),
.collapsible .collapsible-body {
border: 0;
@include resp(null, $small-screen + 1px) {
display: contents;
}
}
div.collapsible-body {
padding: none;
}
.collapsible label {
border-bottom: 0;
padding: 0;
}
.collapsible > button {
background-color: $main-background;
display: none;
font-size: 0.5rem;
margin-right: 1rem;
padding: 0.25rem;
position: absolute;
right: 0;
top: 0.2rem;
@include resp(small) {
display: block;
}
}
}

View file

@ -1,37 +1,35 @@
@import './colors.less';
@import './borders.less';
// Core popovers
[popover-top],
[popover-right],
[popover-bottom],
[popover-left]{
position: relative;
[popover-left] {
margin: 24px;
position: relative;
// Popover hover trigger
&:hover {
&::after {
transition: opacity .2s ease-out;
opacity: 1;
transition: opacity 0.2s ease-out;
}
}
// Creating popover::after element
&::after {
position: absolute;
top: -6px;
@include border-style();
@include transition(opacity);
background: $light-dark;
border: 2px solid $primary;
color: $white;
font-size: 0.7em;
left: 50%;
min-width: 80px;
opacity: 0;
padding: 4px 2px;
min-width: 80px;
font-size: 0.7em;
position: absolute;
text-align: center;
color: @white;
background: @light-dark;
transition: opacity .25s ease-out;
top: -6px;
transform: translateX(-50%) translateY(-100%);
.border;
}
}
@ -39,16 +37,16 @@
[popover-left] {
&::before {
left: 0;
top: 50%;
margin-left: -12px;
transform: translatey(-50%) rotate(-90deg);
top: 50%;
transform: translateY(-50%) rotate(-90deg);
}
&::after {
content: attr(popover-left);
left: 0;
top: 50%;
margin-left: -8px;
top: 50%;
transform: translateX(-100%) translateY(-50%);
}
}
@ -56,16 +54,16 @@
[popover-right] {
&::before {
left: 100%;
top: 50%;
margin-left: 1px;
top: 50%;
transform: translatey(-50%) rotate(90deg);
}
&::after {
content: attr(popover-right);
left: 100%;
top: 50%;
margin-left: 8px;
top: 50%;
transform: translateX(0%) translateY(-50%);
}
}
@ -83,15 +81,15 @@
[popover-bottom] {
&::before {
top:100%;
margin-top: 8px;
top: 100%;
transform: translateX(-50%) translatey(-100%) rotate(-180deg);
}
&::after {
content: attr(popover-bottom);
top: 100%;
margin-top: 8px;
top: 100%;
transform: translateX(-50%) translateY(0%);
}
}

35
src/components/_tabs.scss Normal file
View file

@ -0,0 +1,35 @@
.tabs {
.content {
display: none;
padding: 0.75rem 0 0;
}
input {
display: none;
&:checked+label {
border-bottom: solid 3px $secondary;
color: $primary;
}
@for $num from 1 through 5 {
&[id='tab#{$num}']:checked~div[id='content#{$num}'] {
display: block;
}
}
}
label {
color: $primary-light;
display: inline-block;
font-weight: 600;
margin: 0 0 -1px;
padding: 0.75rem;
text-align: center;
&:hover {
color: $muted;
cursor: pointer;
}
}
}

View file

@ -0,0 +1,163 @@
$base: 1rem;
$large: 2rem;
$small: 0.5rem;
.margin {
margin: $base;
&-top {
margin-top: $base;
&-large {
margin-top: $large;
}
&-small {
margin-top: $small;
}
&-none {
margin-top: 0;
}
}
&-right {
margin-right: $base;
&-large {
margin-right: $large;
}
&-small {
margin-right: $small;
}
&-none {
margin-right: 0;
}
}
&-bottom {
margin-bottom: $base;
&-large {
margin-bottom: $large;
}
&-small {
margin-bottom: $small;
}
&-none {
margin-bottom: 0;
}
}
&-left {
margin-left: $base;
&-large {
margin-left: $large;
}
&-small {
margin-left: $small;
}
&-none {
margin-left: 0;
}
}
&-large {
margin: $large;
}
&-small {
margin: $small;
}
&-none {
margin: 0;
}
}
.padding {
padding: $base;
&-top {
padding-top: $base;
&-large {
padding-top: $large;
}
&-small {
padding-top: $small;
}
&-none {
padding-top: 0;
}
}
&-right {
padding-right: $base;
&-large {
padding-right: $large;
}
&-small {
padding-right: $small;
}
&-none {
padding-right: 0;
}
}
&-bottom {
padding-bottom: $base;
&-large {
padding-bottom: $large;
}
&-small {
padding-bottom: $small;
}
&-none {
padding-bottom: 0;
}
}
&-left {
padding-left: $base;
&-large {
padding-left: $large;
}
&-small {
padding-left: $small;
}
&-none {
padding-left: 0;
}
}
&-large {
padding: $large;
}
&-small {
padding: $small;
}
&-none {
padding: 0;
}
}

View file

@ -1,58 +0,0 @@
@import './colors.less';
@large-screen: ~"screen and (max-width: 1200px)";
@medium-screen: ~"screen and (max-width: 992px)";
@small-screen: ~"screen and (max-width: 768px)";
@xsmall-screen: ~"screen and (max-width: 480px)";
.container {
width: 100%;
max-width: 960px;
position: relative;
margin: 0 auto;
@media @medium-screen {
width: 85%;
}
@media @xsmall-screen {
width: 90%;
}
}
.hr-after() {
text-align: center;
color: lighten(@primary, 30%);
display: block;
content: "~~~";
position: relative;
font-size: 1.5rem;
}
.section {
margin-top: 1rem;
margin-bottom: 2rem;
word-wrap: break-word;
}
.section:after {
.hr-after;
}
hr {
border: 0;
}
hr:after {
.hr-after;
top: -.75rem;
}
.paper {
border: 1px solid @primary-light;
background-color: @main-background;
padding: 2rem;
margin-top: 1rem;
margin-bottom: 1rem;
-webkit-box-shadow: -1px 5px 35px -9px hsla(0,0%,0%,.2);
-moz-box-shadow: -1px 5px 35px -9px hsla(0,0%,0%,.2);
box-shadow: -1px 5px 35px -9px hsla(0,0%,0%,.2);
@media @xsmall-screen {
padding: 1rem;
width: 100%;
margin-top: 0;
margin-bottom: 0;
}
}

39
src/content/_code.scss Normal file
View file

@ -0,0 +1,39 @@
code {
background-color: lighten($primary, 70%);
border-radius: 3px;
color: $secondary;
font-size: 80%;
padding: 2px 4px;
}
kbd {
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%);
border-radius: 3px;
color: $primary;
display: block;
font-size: 80%;
line-height: 1.5;
overflow-x: auto;
padding: 1em;
white-space: pre;
word-break: break-all;
word-wrap: break-word;
code {
background: transparent;
color: inherit;
display: block;
font-size: inherit;
padding: initial;
white-space: pre;
}
}

67
src/content/_fonts.scss Normal file
View file

@ -0,0 +1,67 @@
html {
color: $font-color;
font-family: $body-font, sans-serif;
font-size: $global-font-size;
}
p,
a,
button,
table,
thead,
tbody,
th,
tr,
td,
input,
textarea,
select,
option {
font-family: $body-font, sans-serif;
}
h1,
h2,
h3,
h4,
h5,
h6 {
font-family: $header-font, sans-serif;
font-weight: normal;
}
h1 {
font-size: 4rem;
}
h2 {
font-size: 3rem;
}
h3 {
font-size: 2rem;
}
h4 {
font-size: 1.5rem;
}
h5 {
font-size: 1rem;
}
h6 {
font-size: 0.8rem;
}
.text-left {
text-align: left;
}
.text-center {
text-align: center;
}
.text-right {
text-align: right;
}

28
src/content/_images.scss Normal file
View file

@ -0,0 +1,28 @@
img {
@include border-style();
border: 2px solid $primary;
display: block;
height: auto;
max-width: 100%;
&.float-left {
float: left;
margin: 1rem 1rem 1rem 0;
}
&.float-right {
float: right;
margin: 1rem 0 1rem 1rem;
}
&.no-responsive {
display: initial;
height: initial;
max-width: initial;
}
&.no-border {
border: 0;
border-radius: 0;
}
}

63
src/content/_lists.scss Normal file
View file

@ -0,0 +1,63 @@
ol {
list-style-type: decimal;
ol {
list-style-type: upper-alpha;
ol {
list-style-type: upper-roman;
ol {
list-style-type: lower-alpha;
ol {
list-style-type: lower-roman;
}
}
}
}
}
ul {
@include li-bullet('-');
list-style: none;
margin-left: 0;
li {
text-indent: -7px;
.badge,
[popover-bottom]::after,
[popover-left]::after,
[popover-right]::after,
[popover-top]::after {
text-indent: 0;
}
&::before {
left: -7px;
position: relative;
}
}
ul {
@include li-bullet('+');
ul {
@include li-bullet('~');
ul {
@include li-bullet('');
ul {
@include li-bullet('');
}
}
}
}
&.inline li {
display: inline;
margin-left: 5px;
}
}

38
src/content/_tables.scss Normal file
View file

@ -0,0 +1,38 @@
table {
box-sizing: border-box;
max-width: 100%;
overflow-x: auto;
width: 100%;
@include resp(xsmall) {
thead tr th {
padding: 2%;
}
tbody tr td {
padding: 2%;
}
}
thead tr th {
line-height: 1.5;
padding: 8px;
text-align: left;
vertical-align: bottom;
}
tbody tr td {
border-top: 1px dashed lighten($primary, 60%);
line-height: 1.5;
padding: 8px;
vertical-align: top;
}
&.table-hover tbody tr:hover {
color: $secondary;
}
&.table-alternating tbody tr:nth-of-type(even) {
color: lighten($primary, 25%);
}
}

241
src/core/_config.scss Normal file
View file

@ -0,0 +1,241 @@
/**
Global PaperCSS Config
*/
// Imports
@import url('https://fonts.googleapis.com/css?family=Neucha|Patrick+Hand+SC');
// Set theme colors
$primary: #41403e !default;
$secondary: #0071de !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;
$warning-light: lighten($warning, 30%) !default;
$danger-light: lighten($danger, 45%) !default;
$muted-light: lighten($muted, 35%) !default;
$white-dark: rgba(#000, 0.03) !default;
$light-dark: rgba(#000, 0.7) !default;
$white: rgba(#fff, 1) !default;
$main-background: rgba(#fff, 1) !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;
$shadow-color-regular: hsla(0, 0, 0%, 0.2) !default;
$shadow-color-hover: hsla(0, 0, 0%, 0.3) !default;
// Map to set your color names
/* stylelint-disable */
$colors: (primary, $primary, $primary-light, $primary-text),
(secondary, $secondary, $secondary-light, $secondary-text),
(success, $success, $success-light, $success-text),
(warning, $warning, $warning-light, $warning-text),
(danger, $danger, $danger-light, $danger-text),
(muted, $muted, $muted-light, $muted-text);
/* stylelint-enable */
/**
This Loop will generate the various .text- and .background- classes
based on the $colors map above.
*/
@each $colorName, $color, $color-light in $colors {
.text-#{$colorName} {
color: $color;
}
.background-#{$colorName} {
background-color: $color-light;
}
}
// Font settings
$global-font-size: 20px !default;
$header-font: 'Patrick Hand SC' !default;
$body-font: 'Neucha' !default;
$font-color: $primary !default;
// Responsive breakpoints
$large-screen: 1200px !default;
$medium-screen: 992px !default;
$small-screen: 768px !default;
$xsmall-screen: 480px !default;
// Sizes for shadows
$shadow-small: 10px 19px 17px -13px $shadow-color-regular !default;
$shadow-regular: 15px 28px 25px -18px $shadow-color-regular !default;
$shadow-large: 20px 38px 34px -26px $shadow-color-regular !default;
$shadow-hover: 2px 8px 8px -5px $shadow-color-hover !default;
// Mixins
/**
Assign a border style to a component selector.
@param integer
@default 1
*/
@mixin border-style($style: 1) {
@if $style==1 {
border-bottom-left-radius: 15px 255px;
border-bottom-right-radius: 225px 15px;
border-top-left-radius: 255px 15px;
border-top-right-radius: 15px 225px;
}
@if $style==2 {
border-bottom-left-radius: 185px 25px;
border-bottom-right-radius: 20px 205px;
border-top-left-radius: 125px 25px;
border-top-right-radius: 10px 205px;
}
@if $style==3 {
border-bottom-left-radius: 225px 15px;
border-bottom-right-radius: 15px 255px;
border-top-left-radius: 15px 225px;
border-top-right-radius: 255px 15px;
}
@if $style==4 {
border-bottom-left-radius: 25px 115px;
border-bottom-right-radius: 155px 25px;
border-top-left-radius: 15px 225px;
border-top-right-radius: 25px 150px;
}
@if $style==5 {
border-bottom-left-radius: 20px 115px;
border-bottom-right-radius: 15px 105px;
border-top-left-radius: 250px 15px;
border-top-right-radius: 25px 80px;
}
@if $style==6 {
border-bottom-left-radius: 15px 225px;
border-bottom-right-radius: 20px 205px;
border-top-left-radius: 28px 125px;
border-top-right-radius: 100px 30px;
}
}
/**
Mixin for setting responsive breakpoints
@param string | integer
@default null
*/
@mixin resp($max:null, $min:null) {
@if $max == large or $max == lg { $max: $large-screen; }
@if $max == medium or $max == md { $max: $medium-screen; }
@if $max == small or $max == sm { $max: $small-screen; }
@if $max == xsmall or $max == xs { $max: $xsmall-screen; }
@if ($min != null and $max != null) { @media only screen and (max-width: $max) and (min-width: $min) { @content; } }
@else if($max != null and $min == null) { @media only screen and (max-width: $max) { @content; } }
@else if($min != null and $max == null) { @media only screen and (min-width: $min) { @content; } }
@else { @error 'no matching size found';}
}
/**
Useful helper mixins
*/
@mixin hr-after() {
color: lighten($primary, 30%);
content: '~~~';
display: block;
font-size: 1.5rem;
position: relative;
text-align: center;
}
@mixin center-all() {
-webkit-align-items: center;
align-items: center;
-webkit-justify-content: center;
justify-content: center;
}
@mixin col-size($percent) {
-webkit-box-flex: 0;
-webkit-flex: 0 0 $percent;
-ms-flex: 0 0 $percent;
flex: 0 0 $percent;
max-width: $percent;
}
@mixin li-bullet($char) {
li::before {
content: $char;
}
}
/*
Add transform: translate() with browser prefixes.
Same syntax for translate() and translate3d()
To get 3D add a $z value and set 'true'
@param string | boolean
@default 0 | false
*/
@mixin translate($x, $y, $z: 0, $transform3d: false) {
@if $transform3d {
-webkit-transform: translate3d($x, $y, $z);
-ms-transform: translate3d($x, $y, $z);
transform: translate3d($x, $y, $z);
} @else {
-webkit-transform: translate($x, $y);
-ms-transform: translate($x, $y);
transform: translate($x, $y);
}
}
/*
Add global transition styles to selector
@param string
@default all | 235ms | ease-in-out | 0
*/
@mixin transition($name:all, $duration:235ms, $animation:ease-in-out, $delay: 0s) {
-webkit-transition: $name $duration $animation $delay;
-moz-transition: $name $duration $animation $delay;
-o-transition: $name $duration $animation $delay;
transition: $name $duration $animation $delay;
}
/**
Set the shadow type for a component
@param string
@default regular
*/
@mixin shadow($type: regular) {
@if $type == hover {
@include translate(0, 2px, 0, true);
box-shadow: $shadow-hover;
} @else if $type == small {
@include transition($animation: ease);
box-shadow: $shadow-small;
} @else if $type == regular {
@include transition($animation: ease);
box-shadow: $shadow-regular;
} @else if $type == large {
@include transition($animation: ease);
box-shadow: $shadow-large;
} @else {
@error 'wrong $type. available types: small | regular | large | hover';
}
}
//function for string replacement
@function str-replace($string, $search, $replace: '') {
$index: str-index($string, $search);
@if $index {
@return str-slice($string, 1, $index - 1) + $replace + str-replace(str-slice($string, $index + str-length($search)), $search, $replace);
}
@return $string;
}

View file

@ -1,4 +1,6 @@
/*! normalize.css v7.0.0 | MIT License | github.com/necolas/normalize.css */
/* stylelint-disable */
html {
line-height: 1.15;
-ms-text-size-adjust: 100%;
@ -188,3 +190,13 @@ template {
[hidden] {
display: none
}
// Why is box sizing not the default?
// https://www.paulirish.com/2012/box-sizing-border-box-ftw/
html {
box-sizing: border-box;
}
*, *:before, *:after {
box-sizing: inherit;
}
/* stylelint-enable */

View file

@ -1,120 +0,0 @@
@columnNames: col, sm, md, lg;
@columnSizes: 0px, 768px, 992px, 1200px;
@numberOfColumns: 12;
.make-column-class(@name, @size, @n, @p: 1) when (@p =< @n) {
@percent: (@p * 100% / @n);
.@{name}-@{p} {
.col-size(@percent);
}
.make-column-class(@name, @size, @n, (@p + 1));
}
.make-column-classes(@n, @j: 1) when (@j =< length(@columnNames)) {
@columnName: extract(@columnNames, @j);
@columnSize: extract(@columnSizes, @j);
@media (min-width: @columnSize) {
.make-column-class(@columnName, @columnSize, @n);
}
.make-column-classes(@n, @j + 1);
}
.center-all() {
-webkit-align-items: center;
align-items: center;
-webkit-justify-content: center;
justify-content: center;
}
.col-size(@percent) {
-webkit-box-flex: 0;
-webkit-flex: 0 0 @percent;
-ms-flex: 0 0 @percent;
flex: 0 0 @percent;
max-width: @percent;
}
.row {
margin-right: auto;
margin-left: auto;
display: -webkit-box;
display: -webkit-flex;
display: -ms-flexbox;
display: flex;
-webkit-box-orient: horizontal;
-webkit-box-direction: normal;
-webkit-flex-flow: row wrap;
-ms-flex-flow: row wrap;
flex-flow: row wrap;
margin-bottom: 1rem;
&.flex-right {
-webkit-box-pack: end;
-webkit-justify-content: flex-end;
-ms-flex-pack: end;
justify-content: flex-end;
}
&.flex-center {
-webkit-box-pack: center;
-webkit-justify-content: center;
-ms-flex-pack: center;
justify-content: center;
}
&.flex-edges {
-webkit-box-pack: justify;
-webkit-justify-content: space-between;
-ms-flex-pack: justify;
justify-content: space-between;
}
&.flex-spaces {
-webkit-justify-content: space-around;
-ms-flex-pack: distribute;
justify-content: space-around;
}
&.flex-top {
-webkit-box-align: start;
-webkit-align-items: flex-start;
-ms-flex-align: start;
align-items: flex-start;
}
&.flex-middle {
-webkit-box-align: center;
-webkit-align-items: center;
-ms-flex-align: center;
align-items: center;
}
&.flex-bottom {
-webkit-box-align: end;
-webkit-align-items: flex-end;
-ms-flex-align: end;
align-items: flex-end;
}
}
.col {
padding: 1rem;
@media (max-width: 767px) {
// Stack for mobile
.col-size(100%);
}
}
.col-fill {
width: auto;
flex: 1 1 0px;
}
.make-column-classes(@numberOfColumns);
.align-top {
-webkit-align-self: flex-start;
-ms-flex-item-align: start;
align-self: flex-start;
}
.align-middle {
-webkit-align-self: center;
-ms-flex-item-align: center;
-ms-grid-row-align: center;
align-self: center;
}
.align-bottom {
-webkit-align-self: flex-end;
-ms-flex-item-align: end;
align-self: flex-end;
}

View file

@ -1,48 +0,0 @@
@import './colors.less';
@import url('https://fonts.googleapis.com/css?family=Neucha|Patrick+Hand+SC');
@global-font-size: 20px;
@header-font: 'Patrick Hand SC';
@body-font: 'Neucha';
@font-color: @primary;
html {
font-size: @global-font-size;
font-family: @body-font, sans-serif;
color: @font-color;
}
p, a, button, table, thead, tbody, th, tr, td, input, textarea, select, option {
font-family: @body-font, sans-serif;
}
h1, h2, h3, h4, h5, h6 {
font-family: @header-font, sans-serif;
font-weight: normal;
}
h1 {
font-size: 4rem;
}
h2 {
font-size: 3rem;
}
h3 {
font-size: 2rem;
}
h4 {
font-size: 1.5rem;
}
h5 {
font-size: 1rem;
}
h6 {
font-size: .8rem;
}
.text-left {
text-align: left;
}
.text-center {
text-align: center;
}
.text-right {
text-align: right;
}

View file

@ -1,105 +0,0 @@
@import './colors.less';
input, select, textarea {
display: block;
background:transparent;
color:@primary;
outline:none;
border-top-left-radius: 255px 15px;
border-top-right-radius: 15px 225px;
border-bottom-right-radius: 225px 15px;
border-bottom-left-radius:15px 255px;
font-size: 1rem;
padding: .5rem .5rem;
border: 2px solid @primary;
&:focus {
border: 2px solid @secondary;
}
&.disabled, &[disabled]{
.disabled;
}
}
.disabled{
cursor: not-allowed;
opacity: 0.5;
}
.form-group {
margin-bottom: 1rem;
> label, legend {
display: inline-block;
margin-bottom: .5rem;
}
.input-block {
width: 100%;
}
textarea{
max-width: 100%;
max-height: 90vh;
}
textarea.no-resize{
resize: none;
}
// TODO: make these classes implicit. We can find out what class to apply based on its type
.paper-radio, .paper-check {
display: block;
margin-bottom: .5rem;
cursor: pointer;
input {
border: 0;
height: 1px; margin: -1px;
overflow: hidden;
padding: 0;
position: absolute;
width: 1px;
display: none;
}
input + span {
display: block;
}
/* the basic, unchecked style */
input + span:before {
content: '';
display: inline-block;
position: relative;
width: 1rem;
height: 1rem;
border: 2px solid @primary;
margin-right: 0.75em;
vertical-align: -0.25em;
}
input[type="radio"] + span:before {
border-top-left-radius: 1rem 1rem;
border-top-right-radius: 1rem .6rem;
border-bottom-right-radius: 1rem .9rem;
border-bottom-left-radius: .7rem 1rem;
}
input[type="checkbox"] + span:before {
border-top-left-radius: 255px 15px;
border-top-right-radius: 15px 225px;
border-bottom-right-radius: 225px 15px;
border-bottom-left-radius:15px 255px;
}
/* the checked style using the :checked pseudo class */
input[type="radio"]:checked + span:before {
@escaped-svg: escape("<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 100'><path fill='@{secondary}' d='M49.346,46.341c-3.79-2.005,3.698-10.294,7.984-8.89 c8.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 c9.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 c-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 c-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 c3.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 c0.643,4.698,0.646,10.775-3.811,13.746'></path></svg>");
@radio-fill: "data:image/svg+xml,@{escaped-svg}";
background: url(@radio-fill) left center no-repeat;
}
input[type="checkbox"]:checked + span:before {
@escaped-svg: escape("<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 100'><path stroke='@{secondary}' fill-opacity='0' stroke-width='16' d='m13,62c0.61067,1.6 1.3045,2.3045 1.75717,2.75716c0.72683,0.72684 1.24283,1.24284 2.07617,2.07617c0.54133,0.54133 1.04116,1.06035 1.82833,1.82383c0.5781,0.5607 1.00502,0.96983 2.02633,1.74417c0.55877,0.42365 1.191,0.84034 1.884,1.284c1.16491,0.74577 1.59777,1.00147 2.5,1.55067c0.4692,0.28561 1.43689,0.86868 1.93067,1.16534c0.99711,0.59904 1.99667,1.19755 2.49283,1.49866c0.98501,0.59779 1.47073,0.89648 1.94733,1.2c1.3971,0.88972 1.83738,1.19736 2.7,1.7955c0.42201,0.29262 1.24022,0.87785 2.05583,1.41917c0.79531,0.52785 1.59376,1.0075 2.38,1.43867c0.74477,0.40842 1.45167,0.75802 2.37817,1.22517c0.76133,0.38387 1.54947,0.82848 2.40717,1.41084c0.7312,0.49647 1.49563,1.08231 2.27884,1.258c0.35564,0.07978 0.14721,-0.95518 0.35733,-1.86867c0.18092,-0.78651 0.98183,-1.2141 0.99983,-2.07867c0.02073,-0.99529 0.07916,-1.79945 0.42533,-2.56133c0.43607,-0.95973 0.53956,-1.66774 0.79617,-2.68183c0.18888,-0.74645 0.39764,-1.31168 0.7785,-2.6235c0.20865,-0.71867 0.41483,-1.48614 0.708,-2.28c0.15452,-0.41843 0.77356,-1.73138 1.348,-2.64133c0.30581,-0.48443 0.65045,-0.97043 1.0065,-1.4745c0.74776,-1.05863 1.1531,-1.60163 1.9375,-2.77084c0.40621,-0.60548 0.80272,-1.23513 1.2045,-1.8765c0.40757,-0.65062 0.81464,-1.31206 1.2315,-1.9755c0.41946,-0.66757 0.83374,-1.34258 1.73067,-2.648c0.44696,-0.65053 0.91436,-1.28356 1.386,-1.9095c0.46972,-0.6234 0.94725,-1.2364 1.422,-1.8465c0.94116,-1.20947 1.86168,-2.40844 2.30367,-3.0105c0.438,-0.59664 0.86246,-1.19396 1.27501,-1.7895c0.40743,-0.58816 0.80352,-1.17234 1.185,-1.7535c1.10526,-1.68381 1.44079,-2.23511 1.77633,-2.7705c0.32878,-0.52461 0.96306,-1.5459 1.27467,-2.04c0.60654,-0.96177 1.20782,-1.88193 1.51051,-2.325c0.59013,-0.86381 1.17888,-1.68032 1.46416,-2.075c0.5498,-0.76063 1.31747,-1.8231 1.77883,-2.4895c0.43918,-0.63437 0.85266,-1.25267 1.45717,-2.15717c0.59549,-0.891 0.96531,-1.46814 1.51466,-2.22933c0.58413,-0.80936 1.12566,-1.40253 1.83801,-2.12333c0.61304,-0.62031 0.45171,-1.48306 0.7045,-2.34733c0.25668,-0.87762 0.75447,-1.62502 1,-2.40983c0.25128,-0.8032 0.7633,-1.39453 1.33217,-2.25417c0.54528,-0.82398 0.73415,-1.6714 1.31516,-2.336c0.55639,-0.63644 1.38658,-1.22588 1.8595,-1.9c0.5082,-0.72441 0.78867,-1.4 1.60266,-1.56667l0.71184,-0.4905'></path></svg>");
@check-fill: "data:image/svg+xml,@{escaped-svg}";
background: url(@check-fill) left center no-repeat;
}
}
}
fieldset.form-group {
border: none;
padding: 0;
}

View file

@ -1,26 +0,0 @@
@import './colors.less';
@import './borders.less';
img {
max-width: 100%;
height: auto;
display: block;
.border;
&.float-left {
float: left;
margin: 1rem 1rem 1rem 0rem;
}
&.float-right {
float: right;
margin: 1rem 0rem 1rem 1rem;
}
&.no-responsive {
max-width: initial;
height: initial;
display: initial;
}
&.no-border {
border: 0;
border-radius: 0;
}
}

View file

@ -0,0 +1,48 @@
.container {
margin: 0 auto;
max-width: 960px;
position: relative;
width: 100%;
@include resp(medium) {
width: 85%;
}
@include resp(xsmall) {
width: 90%;
}
}
.section {
margin-bottom: 2rem;
margin-top: 1rem;
word-wrap: break-word;
&::after {
@include hr-after;
}
}
hr {
border: 0;
&::after {
@include hr-after;
top: -0.75rem;
}
}
.paper {
background-color: $main-background;
border: 1px solid $primary-light;
-moz-box-shadow: -1px 5px 35px -9px hsla(0, 0%, 0%, 0.2);
-webkit-box-shadow: -1px 5px 35px -9px hsla(0, 0%, 0%, 0.2);
box-shadow: -1px 5px 35px -9px hsla(0, 0%, 0%, 0.2);
margin-bottom: 1rem;
margin-top: 1rem;
padding: 2rem;
@include resp(xs) {
margin-bottom: 0;
margin-top: 0;
padding: 1rem;
width: 100%;
}
}

130
src/layout/_flexbox.scss Normal file
View file

@ -0,0 +1,130 @@
$number-columns: 12;
@mixin create-flex-classes($colName, $breakpoint: 0) {
@include resp($min: $breakpoint) {
@for $i from 1 through $number-columns {
.#{$colName}-#{$i} {
-webkit-box-flex: 0;
-webkit-flex: 0 0 $i * 100% / $number-columns;
-ms-flex: 0 0 $i * 100% / $number-columns;
flex: 0 0 $i * 100% / $number-columns;
max-width: $i * 100% / $number-columns;
}
}
}
}
.row {
-webkit-box-direction: normal;
-webkit-box-orient: horizontal;
display: -webkit-box;
display: -webkit-flex;
display: -ms-flexbox;
display: flex;
-webkit-flex-flow: row wrap;
-ms-flex-flow: row wrap;
flex-flow: row wrap;
margin-bottom: 1rem;
margin-left: auto;
margin-right: auto;
&.flex-right {
-webkit-box-pack: end;
-ms-flex-pack: end;
-webkit-justify-content: flex-end;
justify-content: flex-end;
}
&.flex-center {
-webkit-box-pack: center;
-ms-flex-pack: center;
-webkit-justify-content: center;
justify-content: center;
}
&.flex-edges {
-webkit-box-pack: justify;
-ms-flex-pack: justify;
-webkit-justify-content: space-between;
justify-content: space-between;
}
&.flex-spaces {
-ms-flex-pack: distribute;
-webkit-justify-content: space-around;
justify-content: space-around;
}
&.flex-top {
-webkit-align-items: flex-start;
align-items: flex-start;
-webkit-box-align: start;
-ms-flex-align: start;
}
&.flex-middle {
-webkit-align-items: center;
align-items: center;
-webkit-box-align: center;
-ms-flex-align: center;
}
&.flex-bottom {
-webkit-align-items: flex-end;
align-items: flex-end;
-webkit-box-align: end;
-ms-flex-align: end;
}
}
.col {
padding: 1rem;
@include resp(sm) {
@include col-size(100%);
}
}
.col-fill {
flex: 1 1 0;
width: auto;
}
@include create-flex-classes(col);
@include create-flex-classes(xs, $xsmall-screen);
@include create-flex-classes(sm, $small-screen);
@include create-flex-classes(md, $medium-screen);
@include create-flex-classes(lg, $large-screen);
.align-top {
-webkit-align-self: flex-start;
align-self: flex-start;
-ms-flex-item-align: start;
}
.align-middle {
-webkit-align-self: center;
align-self: center;
-ms-flex-item-align: center;
-ms-grid-row-align: center;
}
.align-bottom {
-webkit-align-self: flex-end;
align-self: flex-end;
-ms-flex-item-align: end;
}
.container {
margin: 0 auto;
max-width: 960px;
position: relative;
width: 100%;
@include resp(md) {
width: 85%;
}
@include resp(xs) {
width: 90%;
}
}

View file

@ -1,48 +0,0 @@
ol {
list-style-type: decimal;
ol {
list-style-type: upper-alpha;
ol {
list-style-type: upper-roman;
ol {
list-style-type: lower-alpha;
ol {
list-style-type: lower-roman;
}
}
}
}
}
.li-bullet(@char) {
li:before {
content: @char;
}
}
ul {
list-style: none;
margin-left: 0;
li {
text-indent: -7px;
}
li:before {
position: relative;
left: -7px;
}
.li-bullet("-");
ul {
.li-bullet("+");
ul {
.li-bullet("~");
ul {
.li-bullet("⤍");
ul {
.li-bullet("")
}
}
}
}
&.inline li{
display: inline;
margin-left: 5px;
}
}

View file

@ -1,97 +0,0 @@
@import './colors.less';
@import './container.less';
@import './utilities.less';
.translate(@x; @y) {
-webkit-transform: translate(@x, @y);
-ms-transform: translate(@x, @y);
transform: translate(@x, @y);
}
.transition-transform(@transition) {
-webkit-transition: -webkit-transform @transition;
-moz-transition: -moz-transform @transition;
-o-transition: -o-transform @transition;
transition: transform @transition;
}
.modal{
&:before{
content: "";
display: none;
background: rgba(0,0,0,.6);
position: fixed;
top: 0; left: 0; right: 0; bottom: 0;
z-index: 10;
}
&:target{
&:before{
display: flex;
}
.modal-body{
.translate(0, 0);
top: 20%;
}
}
.modal-body{
flex: 1 1 auto;
padding: 1.25rem;
background: @white;
border: 2px solid @muted-light;
word-wrap: break-word;
position: fixed;
z-index: 11;
max-width: 960px;
@media @medium-screen {
max-width: 85%;
}
@media @xsmall-screen {
max-width: 90%;
}
.translate(0, -500%);
.transition-transform(~"0.3s ease-out");
}
.btn-close{
color: @primary-light;
font-size: 30px;
text-decoration: none;
position: absolute; right: 0; top: 0;
.margin;
background: inherit;
&:hover{
color: @muted;
}
}
.modal-title, h4 {
margin-top: 0;
margin-bottom: 0.5rem;
}
.modal-subtitle, h5 {
.text-secondary;
margin-top: 0;
margin-bottom: 0.5rem;
}
.modal-text, p {
margin-top: 0;
margin-bottom: 1rem;
}
.modal-link + .modal-link,
a + a {
margin-left: 1.25rem;
}
a button {
text-decoration: none;
background: @white;
}
}

View file

@ -1,39 +0,0 @@
@shadow-color-regular: hsla(0,0%,0%,.2);
@shadow-color-hover: hsla(0,0%,0%,.3);
@shadow-small: 10px 19px 17px -13px @shadow-color-regular;
@shadow-regular: 15px 28px 25px -18px @shadow-color-regular;
@shadow-large: 20px 38px 34px -26px @shadow-color-regular;
@shadow-hover: 2px 8px 8px -5px @shadow-color-hover;
.shadow {
-webkit-box-shadow: @shadow-regular;
-moz-box-shadow: @shadow-regular;
box-shadow: @shadow-regular;
transition: all .5s ease;
&.shadow-large {
-webkit-box-shadow: @shadow-large;
-moz-box-shadow: @shadow-large;
box-shadow: @shadow-large;
}
&.shadow-small {
-webkit-box-shadow: @shadow-small;
-moz-box-shadow: @shadow-small;
box-shadow: @shadow-small;
}
&.shadow-hover {
&:hover{
-webkit-box-shadow: @shadow-hover;
-moz-box-shadow: @shadow-hover;
box-shadow: @shadow-hover;
transform: translate(0, 2px);
}
}
}
.child-shadows > * {
.shadow;
}
.child-shadows-hover > * {
.shadow;
.shadow-hover;
}

View file

@ -1,22 +0,0 @@
@import (less) "./reset.less";
@import (less) "./boxreset.less";
@import (less) "./colors.less";
@import (less) "./fonts.less";
@import (less) "./borders.less";
@import (less) "./shadows.less";
@import (less) "./flexbox.less";
@import (less) "./container.less";
@import (less) "./buttons.less";
@import (less) "./forms.less";
@import (less) "./lists.less";
@import (less) "./code.less";
@import (less) "./tables.less";
@import (less) "./images.less";
@import (less) "./utilities.less";
@import (less) "./popovers.less";
@import (less) "./cards.less";
@import (less) "./badges.less";
@import (less) "./alerts.less";
@import (less) "./tabs.less";
@import (less) "./article.less";
@import (less) "./modals.less";

38
src/styles.scss Normal file
View file

@ -0,0 +1,38 @@
@charset 'UTF-8';
/* PaperCSS core */
@import 'core/config';
@import 'core/reset';
/* Layout styling */
@import 'layout/container';
@import 'layout/flexbox';
/* Content styling */
@import 'content/code';
@import 'content/fonts';
@import 'content/images';
@import 'content/lists';
@import 'content/tables';
/* Utilities */
@import 'utilities/borders';
@import 'utilities/shadows';
/* Components */
@import 'components/accordion';
@import 'components/alerts';
@import 'components/article';
@import 'components/badges';
@import 'components/buttons';
@import 'components/cards';
@import 'components/forms';
@import 'components/modals';
@import 'components/popovers';
@import 'components/tabs';
@import 'components/utilities';
@import 'components/navbar';
// @media print {
// @import 'layout/print';
// }

View file

@ -1,33 +0,0 @@
@import './colors.less';
table {
box-sizing: border-box;
width: 100%;
max-width: 100%;
thead tr th {
vertical-align: bottom;
text-align: left;
padding: 8px;
line-height: 1.5;
}
tbody tr td {
padding: 8px;
line-height: 1.5;
vertical-align: top;
border-top: 1px dashed lighten(@primary, 60%);
}
@media screen and (max-width:480px) {
thead tr th {
padding: 2%;
}
tbody tr td {
padding: 2%;
}
}
&.table-hover tbody tr:hover {
color: @secondary;
}
&.table-alternating tbody tr:nth-of-type(even) {
color: lighten(@primary, 25%);
}
}

View file

@ -1,40 +0,0 @@
@import './colors.less';
.tabs {
.content {
display: none;
padding: 0.75rem 0 0;
}
input {
display: none;
}
label {
display: inline-block;
margin: 0 0 -1px;
padding: 0.75rem 0.75rem;
font-weight: 600;
text-align: center;
color: @primary-light;
}
label:hover {
color: @muted;
cursor: pointer;
}
input:checked+label {
color: @primary;
border-bottom: solid 3px @secondary;
}
.loop(@num) when (@num > 0) {
.loop((@num - 1));
input[id = ~"tab@{num}"]:checked~div[id = ~"content@{num}"]{
display:block;
}
}
.loop(5);
}

View file

@ -1,124 +0,0 @@
@base: 1rem;
@large: 2rem;
@small: .5rem;
.margin {
margin: @base;
&-top {
margin-top: @base;
&-large {
margin-top: @large;
}
&-small {
margin-top: @small;
}
&-none {
margin-top: 0;
}
}
&-right {
margin-right: @base;
&-large {
margin-right: @large;
}
&-small {
margin-right: @small;
}
&-none {
margin-right: 0;
}
}
&-bottom {
margin-bottom: @base;
&-large {
margin-bottom: @large;
}
&-small {
margin-bottom: @small;
}
&-none {
margin-bottom: 0;
}
}
&-left {
margin-left: @base;
&-large {
margin-left: @large;
}
&-small {
margin-left: @small;
}
&-none {
margin-left: 0;
}
}
&-large {
margin: @large;
}
&-small {
margin: @small;
}
&-none {
margin: 0;
}
}
.padding {
padding: @base;
&-top {
padding-top: @base;
&-large {
padding-top: @large;
}
&-small {
padding-top: @small;
}
&-none {
padding-top: 0;
}
}
&-right {
padding-right: @base;
&-large {
padding-right: @large;
}
&-small {
padding-right: @small;
}
&-none {
padding-right: 0;
}
}
&-bottom {
padding-bottom: @base;
&-large {
padding-bottom: @large;
}
&-small {
padding-bottom: @small;
}
&-none {
padding-bottom: 0;
}
}
&-left {
padding-left: @base;
&-large {
padding-left: @large;
}
&-small {
padding-left: @small;
}
&-none {
padding-left: 0;
}
}
&-large {
padding: @large;
}
&-small {
padding: @small;
}
&-none {
padding: 0;
}
}

View file

@ -0,0 +1,61 @@
.border {
border: 2px solid $primary;
}
.border,
.border-1,
.child-borders>*:nth-child(6n+1) {
@include border-style(1);
}
.border-2,
.child-borders>*:nth-child(6n+2) {
@include border-style(2);
}
.border-3,
.child-borders>*:nth-child(6n+3) {
@include border-style(3);
}
.border-4,
.child-borders>*:nth-child(6n+4) {
@include border-style(4);
}
.border-5,
.child-borders>*:nth-child(6n+5) {
@include border-style(5);
}
.border-6,
.child-borders>*:nth-child(6n+6) {
@include border-style(6);
}
.child-borders>* {
border: 2px solid $primary;
}
.border-white {
border-color: $white;
}
.border-dotted {
border-style: dotted;
}
.border-dashed {
border-style: dashed;
}
.border-thick {
border-width: 5px;
}
@each $colorName, $color in $colors {
.border-#{$colorName} {
border-color: $color;
}
}

Some files were not shown because too many files have changed in this diff Show more