├── .nvmrc ├── src ├── assets │ ├── fonts │ │ └── .keep │ ├── icons │ │ └── .keep │ ├── img │ │ └── .keep │ ├── js │ │ ├── utils │ │ │ └── .kepp │ │ ├── components │ │ │ └── .keep │ │ └── app.js │ └── scss │ │ ├── pages │ │ └── .keep │ │ ├── base │ │ ├── _b_font_face.scss │ │ ├── _b_reset.scss │ │ └── _b_normalize.scss │ │ ├── utils │ │ ├── _u_width.scss │ │ ├── _u_show_hide.scss │ │ ├── _u_layout.scss │ │ ├── _u_spacing.scss │ │ ├── _u_text.scss │ │ └── _u_text_color.scss │ │ ├── molecules │ │ ├── _m_form_inline.scss │ │ ├── _m_form.scss │ │ └── _m_content.scss │ │ ├── atoms │ │ ├── _a_input_textarea.scss │ │ ├── _a_input_text.scss │ │ ├── _a_label.scss │ │ ├── _a_input_radio.scss │ │ ├── _a_input_select.scss │ │ ├── _a_input_checkbox.scss │ │ └── _a_button.scss │ │ ├── layout │ │ ├── _l_app.scss │ │ ├── _l_wrapper.scss │ │ └── _l_grid.scss │ │ ├── tools │ │ ├── _function.scss │ │ └── _mixin.scss │ │ ├── app.scss │ │ ├── _settings.scss │ │ └── styleguide.scss ├── template │ ├── partials │ │ ├── footer.pug │ │ ├── header.pug │ │ └── head.pug │ ├── config.pug │ ├── mixins │ │ └── mixins.pug │ ├── pages │ │ ├── index.pug │ │ ├── home.pug │ │ └── styleguide │ │ │ ├── atoms │ │ │ ├── a-label.pug │ │ │ ├── a-input-textarea.pug │ │ │ ├── a-input-select.pug │ │ │ ├── a-input-text.pug │ │ │ ├── a-input-radio.pug │ │ │ ├── a-input-checkbox.pug │ │ │ └── a-button.pug │ │ │ ├── utils │ │ │ ├── u-show-hide.pug │ │ │ ├── u-width.pug │ │ │ ├── u-layout.pug │ │ │ ├── u-text.pug │ │ │ ├── u-text-color.pug │ │ │ └── u-spacing.pug │ │ │ ├── index.pug │ │ │ ├── molecules │ │ │ ├── m-form-inline.pug │ │ │ ├── m-form.pug │ │ │ └── m-content.pug │ │ │ └── layout │ │ │ ├── l-wrapper.pug │ │ │ └── l-grid.pug │ └── layout │ │ ├── summary.pug │ │ ├── base.pug │ │ └── styleguide.pug └── rootfiles │ ├── favicon.ico │ ├── favicon-16x16.png │ ├── favicon-32x32.png │ ├── robots.txt │ └── .htaccess ├── .babelrc ├── .browserslistrc ├── gulpfile.js ├── .prettierrc ├── gulp ├── tasks │ ├── clean.js │ ├── fonts.js │ ├── rootfiles.js │ ├── build.js │ ├── default.js │ ├── browserSync.js │ ├── utils.js │ ├── watch.js │ ├── svg.js │ ├── rev.js │ ├── images.js │ ├── styles.js │ ├── icons.js │ ├── templates.js │ └── scripts.js └── config.js ├── webpack ├── webpack.config.dev.js ├── webpack.config.prod.js └── webpack.config.base.js ├── .gitignore ├── package.json └── README.md /.nvmrc: -------------------------------------------------------------------------------- 1 | v8.12.0 2 | -------------------------------------------------------------------------------- /src/assets/fonts/.keep: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /src/assets/icons/.keep: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /src/assets/img/.keep: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /src/assets/js/utils/.kepp: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /src/assets/scss/pages/.keep: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /src/assets/js/components/.keep: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /src/assets/scss/base/_b_font_face.scss: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /.babelrc: -------------------------------------------------------------------------------- 1 | { 2 | "presets": ["env"] 3 | } 4 | -------------------------------------------------------------------------------- /src/assets/js/app.js: -------------------------------------------------------------------------------- 1 | import "what-input"; 2 | -------------------------------------------------------------------------------- /.browserslistrc: -------------------------------------------------------------------------------- 1 | last 2 version 2 | > 1% 3 | IE 10 4 | -------------------------------------------------------------------------------- /src/template/partials/footer.pug: -------------------------------------------------------------------------------- 1 | footer.footer 2 | .l-wrapper 3 | div Footer here 4 | -------------------------------------------------------------------------------- /src/rootfiles/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sutter/helloFront/HEAD/src/rootfiles/favicon.ico -------------------------------------------------------------------------------- /gulpfile.js: -------------------------------------------------------------------------------- 1 | var requireDir = require("require-dir"); 2 | 3 | requireDir("./gulp/tasks", { recurse: true }); 4 | -------------------------------------------------------------------------------- /src/rootfiles/favicon-16x16.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sutter/helloFront/HEAD/src/rootfiles/favicon-16x16.png -------------------------------------------------------------------------------- /src/rootfiles/favicon-32x32.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sutter/helloFront/HEAD/src/rootfiles/favicon-32x32.png -------------------------------------------------------------------------------- /src/rootfiles/robots.txt: -------------------------------------------------------------------------------- 1 | # www.robotstxt.org/ 2 | 3 | # Allow crawling of all content 4 | User-agent: * 5 | Disallow: 6 | -------------------------------------------------------------------------------- /.prettierrc: -------------------------------------------------------------------------------- 1 | { 2 | "trailingComma": "es5", 3 | "useTabs": false, 4 | "printWidth": 80, 5 | "tabWidth": 2, 6 | "singleQuote": false 7 | } 8 | -------------------------------------------------------------------------------- /gulp/tasks/clean.js: -------------------------------------------------------------------------------- 1 | const gulp = require("gulp"); 2 | const del = require("del"); 3 | const config = require("../config"); 4 | 5 | gulp.task("clean", del.bind(null, [config.dist])); 6 | -------------------------------------------------------------------------------- /gulp/tasks/fonts.js: -------------------------------------------------------------------------------- 1 | const gulp = require("gulp"); 2 | const config = require("../config").fonts; 3 | 4 | gulp.task("fonts", () => { 5 | return gulp.src(config.src).pipe(gulp.dest(config.dist)); 6 | }); 7 | -------------------------------------------------------------------------------- /webpack/webpack.config.dev.js: -------------------------------------------------------------------------------- 1 | const webpackMerge = require("webpack-merge"); 2 | const webpackConfigBase = require("./webpack.config.base.js"); 3 | 4 | module.exports = webpackMerge(webpackConfigBase, { 5 | devtool: "cheap-module-eval-source-map", 6 | }); 7 | -------------------------------------------------------------------------------- /gulp/tasks/rootfiles.js: -------------------------------------------------------------------------------- 1 | const gulp = require("gulp"); 2 | const config = require("../config").rootfiles; 3 | 4 | gulp.task("rootfiles", () => { 5 | return gulp 6 | .src(config.src, { 7 | dot: true, 8 | }) 9 | .pipe(gulp.dest(config.dist)); 10 | }); 11 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | # Mac OSX 2 | .DS_Store 3 | 4 | # IDE 5 | .idea 6 | *.iml 7 | *.sublime-project 8 | *.sublime-workspace 9 | 10 | # Npm & yarn 11 | /npm-debug.log 12 | node_modules 13 | yarn-error.log 14 | 15 | # Generated folder 16 | dist 17 | 18 | # Generated SVG sprite 19 | src/assets/icons/symbol 20 | -------------------------------------------------------------------------------- /gulp/tasks/build.js: -------------------------------------------------------------------------------- 1 | const gulp = require("gulp"); 2 | const runSequence = require("run-sequence"); 3 | 4 | gulp.task("build", callback => { 5 | runSequence( 6 | "clean", 7 | "svg", 8 | "icons", 9 | ["styles", "templates", "images", "rootfiles", "fonts", "scripts"], 10 | callback 11 | ); 12 | }); 13 | -------------------------------------------------------------------------------- /src/assets/scss/utils/_u_width.scss: -------------------------------------------------------------------------------- 1 | /** ====================================== 2 | * Utils / Width 3 | * ======================================= */ 4 | 5 | @each $width in $width-list { 6 | $prefix: nth($width, 1); 7 | $size: nth($width, 2); 8 | 9 | .u-w#{$prefix} { 10 | width: #{$size} !important; 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /gulp/tasks/default.js: -------------------------------------------------------------------------------- 1 | const gulp = require("gulp"); 2 | const config = require("../config"); 3 | const browserSync = require("browser-sync"); 4 | const runSequence = require("run-sequence"); 5 | 6 | gulp.task("default", callback => { 7 | process.WATCH_SCRIPTS = true; 8 | runSequence("build", "browserSync", "watch", callback); 9 | }); 10 | -------------------------------------------------------------------------------- /webpack/webpack.config.prod.js: -------------------------------------------------------------------------------- 1 | const webpackMerge = require("webpack-merge"); 2 | const webpackConfigBase = require("./webpack.config.base.js"); 3 | const uglifyJSPlugin = require("uglifyjs-webpack-plugin"); 4 | 5 | module.exports = webpackMerge(webpackConfigBase, { 6 | devtool: "source-map", 7 | plugins: [new uglifyJSPlugin({ sourceMap: true })], 8 | }); 9 | -------------------------------------------------------------------------------- /src/template/partials/header.pug: -------------------------------------------------------------------------------- 1 | header.header 2 | 3 | .l-wrapper 4 | 5 | h1.header-logo 6 | a.header-logo-link(href="./") App name 7 | 8 | nav.menu 9 | +menu([ 10 | { 'title':'Author', 'link': 'https://sutterlity.fr/' }, 11 | { 'title':'Repo Github', 'link': 'https://github.com/sutter/helloFront' } 12 | ]) 13 | -------------------------------------------------------------------------------- /gulp/tasks/browserSync.js: -------------------------------------------------------------------------------- 1 | const gulp = require("gulp"); 2 | const config = require("../config").browserSync; 3 | const browserSync = require("browser-sync"); 4 | const reload = browserSync.reload; 5 | 6 | gulp.task("browserSync", () => { 7 | browserSync(config); 8 | }); 9 | 10 | gulp.task("browserSync-reload", () => { 11 | browserSync.reload(); 12 | }); 13 | -------------------------------------------------------------------------------- /src/assets/scss/molecules/_m_form_inline.scss: -------------------------------------------------------------------------------- 1 | /** ====================================== 2 | * Molecule : Form Inline 3 | * ======================================= */ 4 | 5 | .m-form-inline { 6 | display: flex; 7 | align-items: flex-start; 8 | .a-label { 9 | @include visually-hidden; 10 | } 11 | 12 | > *:not(:first-child) { 13 | margin-left: 1rem; 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /src/template/config.pug: -------------------------------------------------------------------------------- 1 | //- Site informations 2 | - var lang = 'fr' 3 | - var path = './' 4 | 5 | - var pathStyleguide = "/styleguide/" 6 | 7 | //- Page informations 8 | - var title = title || 'Hello Front - framework SCSS' 9 | - var metaDesc = metaDesc || 'Hello Front est un framework SCSS simple compatible à partir de IE10.' 10 | 11 | //- Templates classes 12 | - var template = template || "t-base" 13 | -------------------------------------------------------------------------------- /src/template/mixins/mixins.pug: -------------------------------------------------------------------------------- 1 | mixin icon(iconHref, iconClass ) 2 | svg(class= iconClass) 3 | use(xlink:href="#spriteIcon-"+iconHref) 4 | 5 | mixin menu(menu_items) 6 | ul.menu-inner 7 | each top_item in menu_items 8 | li.menu-item(class= navLinkActive) 9 | a(href= top_item.link, class= navLinkActive == top_item.title ? 'm-menu-link is-active' : 'm-menu-link')= top_item.title 10 | -------------------------------------------------------------------------------- /src/template/pages/index.pug: -------------------------------------------------------------------------------- 1 | extends ../layout/summary 2 | 3 | append config 4 | - var title = "Sommaire" 5 | - var metaDesc = "My page description" 6 | 7 | block content 8 | .hf-wrapper 9 | .hf-content 10 | h2 Pages 11 | ul 12 | li 13 | a(href="./home.html") Accueil 14 | h2 Documentation 15 | ul 16 | li 17 | a(href="./styleguide") Styleguide 18 | 19 | -------------------------------------------------------------------------------- /src/assets/scss/atoms/_a_input_textarea.scss: -------------------------------------------------------------------------------- 1 | /** ====================================== 2 | * Atom : Input Textarea 3 | * ======================================= */ 4 | 5 | .a-input-textarea { 6 | @include inputBase; 7 | min-height: $form-group-input-height * 2; 8 | padding: 0.9rem 2rem; 9 | line-height: 1.25; 10 | @include inputBaseState; 11 | } 12 | 13 | .a-input-textarea--error { 14 | border-color: $clr-error; 15 | } 16 | -------------------------------------------------------------------------------- /src/assets/scss/atoms/_a_input_text.scss: -------------------------------------------------------------------------------- 1 | /** ====================================== 2 | * Atom : Input Text 3 | * ======================================= */ 4 | 5 | .a-input-text { 6 | @include inputBase; 7 | height: $form-group-input-height; 8 | line-height: 1; 9 | padding: 0 2rem; 10 | border: 1px solid $clr-divider; 11 | @include inputBaseState; 12 | } 13 | 14 | .a-input-text--error { 15 | border-color: $clr-error; 16 | } 17 | -------------------------------------------------------------------------------- /src/assets/scss/utils/_u_show_hide.scss: -------------------------------------------------------------------------------- 1 | /** ====================================== 2 | * Utils : Show / Hide 3 | * ======================================= */ 4 | 5 | .u-hide-mobile { 6 | display: none !important; 7 | 8 | @media #{$mobileUp} { 9 | display: block !important; 10 | } 11 | } 12 | 13 | .u-show-mobile { 14 | @media #{$mobileUp} { 15 | display: none !important; 16 | } 17 | } 18 | 19 | .u-visually-hidden { 20 | @include visually-hidden; 21 | } 22 | -------------------------------------------------------------------------------- /src/assets/scss/layout/_l_app.scss: -------------------------------------------------------------------------------- 1 | /** ====================================== 2 | * Layout : app 3 | * ======================================= */ 4 | 5 | .l-app { 6 | display: flex; 7 | flex-direction: column; 8 | width: 100%; 9 | min-height: 100vh; 10 | overflow-y: scroll; 11 | overflow-x: hidden; 12 | -webkit-overflow-scrolling: touch; 13 | } 14 | 15 | .l-app__head, 16 | .l-app__footer { 17 | flex-shrink: 0; 18 | } 19 | 20 | .l-app__body { 21 | flex: 1 1 auto; 22 | } 23 | -------------------------------------------------------------------------------- /src/template/partials/head.pug: -------------------------------------------------------------------------------- 1 | meta(charset='UTF-8') 2 | title= title 3 | meta(name='description', content= metaDesc ) 4 | meta(name='viewport', content='width=device-width, initial-scale=1.0, shrink-to-fit=no') 5 | link(rel="icon", type="image/png", href= path + "favicon-32x32.png",sizes="32x32") 6 | link(rel="icon", type="image/png", href= path + "favicon-16x16.png",sizes="16x16") 7 | link(href='favicon.ico', rel='shortcut icon', type='image/x-icon') 8 | link(rel='stylesheet', href= path + 'assets/app.css') 9 | -------------------------------------------------------------------------------- /src/template/layout/summary.pug: -------------------------------------------------------------------------------- 1 | include ../config 2 | block config 3 | include ../mixins/mixins 4 | 5 | doctype 6 | html(lang= lang) 7 | head 8 | include ../partials/head 9 | link(rel='stylesheet', href= path + 'assets/styleguide.css') 10 | 11 | body(class= template) 12 | 13 | header.hf-head(role="banner") 14 | .hf-wrapper 15 | h1.hf-summaryHeader-title Sommaire 16 | main(role="main") 17 | section 18 | block content 19 | 20 | script(src= path + "assets/app.js", async) 21 | 22 | -------------------------------------------------------------------------------- /src/assets/scss/atoms/_a_label.scss: -------------------------------------------------------------------------------- 1 | /** ====================================== 2 | * Atom : Label 3 | * ======================================= */ 4 | 5 | .a-label { 6 | display: block; 7 | font-weight: $font-weight-bold; 8 | color: $clr-0; 9 | 10 | &:not(:last-child) { 11 | margin-bottom: 1rem; 12 | } 13 | 14 | &.label { 15 | cursor: pointer; 16 | } 17 | 18 | &[required] { 19 | &::after { 20 | content: " *"; 21 | } 22 | } 23 | } 24 | 25 | .a-label--error { 26 | color: $clr-error; 27 | } 28 | -------------------------------------------------------------------------------- /webpack/webpack.config.base.js: -------------------------------------------------------------------------------- 1 | const path = require("path"); 2 | 3 | module.exports = { 4 | watch: false, 5 | entry: { 6 | app: "./src/assets/js/app.js", 7 | }, 8 | output: { 9 | path: path.resolve(__dirname, "../dist/assets/js"), 10 | filename: "[name].js", 11 | }, 12 | externals: { 13 | jquery: "jQuery", 14 | }, 15 | module: { 16 | rules: [ 17 | { 18 | test: /\.js?$/, 19 | exclude: /(node_modules|bower_components)/, 20 | use: { 21 | loader: "babel-loader", 22 | }, 23 | }, 24 | ], 25 | }, 26 | }; 27 | -------------------------------------------------------------------------------- /src/assets/scss/utils/_u_layout.scss: -------------------------------------------------------------------------------- 1 | /** ====================================== 2 | * Utils : Layout 3 | * ======================================= */ 4 | 5 | .u-no-bfc { 6 | overflow: hidden !important; 7 | } 8 | 9 | .u-float-left { 10 | float: left !important; 11 | } 12 | 13 | .u-float-right { 14 | float: right !important; 15 | } 16 | 17 | .u-flex-push-left { 18 | margin-left: auto !important; 19 | } 20 | 21 | .u-flex-inline-grid.u-flex-inline-grid { 22 | display: flex; 23 | align-items: center; 24 | flex-wrap: wrap; 25 | margin: -0.5rem; 26 | > * { 27 | margin: 0.5rem; 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /src/template/layout/base.pug: -------------------------------------------------------------------------------- 1 | include ../config 2 | block config 3 | include ../mixins/mixins 4 | 5 | doctype 6 | html(lang= lang) 7 | head 8 | include ../partials/head 9 | 10 | body(class= template) 11 | //- Uncomment for active SVG Sprite 12 | .u-visuallyHidden 13 | include ../../assets/icons/symbol/icons.svg 14 | .l-app 15 | .l-app__head 16 | include ../partials/header 17 | main.l-app__body 18 | section 19 | block content 20 | .l-app__footer 21 | include ../partials/footer 22 | 23 | script(src= path + "assets/app.js", async) 24 | -------------------------------------------------------------------------------- /src/assets/scss/atoms/_a_input_radio.scss: -------------------------------------------------------------------------------- 1 | /** ====================================== 2 | * Atom : inputRadio 3 | * ======================================= */ 4 | 5 | .a-input-radio { 6 | @include inputRadioCheckboxBase; 7 | 8 | [type="radio"] + label::before { 9 | border-radius: 50%; 10 | } 11 | 12 | [type="radio"]:checked + label::before { 13 | box-shadow: inset 0 0 0 $radioCheckboxSize/2 - 0.35rem $clr-1; 14 | } 15 | 16 | &:not(:first-child) { 17 | margin-top: 1rem; 18 | } 19 | } 20 | 21 | .a-input-radio--error { 22 | label::before { 23 | box-shadow: inset 0 0 0 1px $clr-error; 24 | } 25 | } 26 | -------------------------------------------------------------------------------- /src/assets/scss/molecules/_m_form.scss: -------------------------------------------------------------------------------- 1 | /** ====================================== 2 | * Molecule : Form 3 | * ======================================= */ 4 | 5 | .m-form { 6 | &:not(:first-child) { 7 | margin-top: $spacer-M; 8 | } 9 | } 10 | 11 | .m-form__group { 12 | &:not(:first-child) { 13 | margin-top: $spacer-M; 14 | } 15 | } 16 | 17 | .m-form__group__legend { 18 | font-size: 80%; 19 | color: tint($clr-0, 40%); 20 | line-height: 1.25; 21 | &:not(:first-child) { 22 | margin-top: 1rem; 23 | } 24 | } 25 | 26 | .m-form__footer { 27 | &:not(:first-child) { 28 | margin-top: $spacer-M; 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /gulp/tasks/utils.js: -------------------------------------------------------------------------------- 1 | const fs = require("fs"); 2 | 3 | module.exports.createEmptyFile = path => { 4 | fs.writeFile(path, "", error => { 5 | if (error) { 6 | return console.error(error); 7 | } 8 | }); 9 | }; 10 | 11 | /** 12 | * Check if a directory contains a specified file extension 13 | * @param {string} path A string of the path 14 | * @param {string} ext A string of the extension, ex. '.svg' 15 | * @return {boolean} 16 | */ 17 | module.exports.checkDirectoryForExt = (path, ext) => { 18 | files = fs.readdirSync(path); 19 | return files.some(file => { 20 | return file.substr(-ext.length) === ext; 21 | }); 22 | }; 23 | -------------------------------------------------------------------------------- /src/assets/scss/layout/_l_wrapper.scss: -------------------------------------------------------------------------------- 1 | /** ====================================== 2 | * Layout : Wrapper 3 | * ======================================= */ 4 | 5 | .l-wrapper { 6 | padding-right: $gutter-width; 7 | padding-left: $gutter-width; 8 | } 9 | 10 | /** 11 | * Modifier : Size 12 | * --------------------------------------- */ 13 | 14 | .l-wrapper--medium { 15 | @media #{$mobileUp} { 16 | max-width: $wrap-M-max-width; 17 | margin-right: auto; 18 | margin-left: auto; 19 | } 20 | } 21 | 22 | .l-wrapper--small { 23 | @media #{$mobileUp} { 24 | max-width: $wrap-S-max-width; 25 | margin-right: auto; 26 | margin-left: auto; 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /gulp/tasks/watch.js: -------------------------------------------------------------------------------- 1 | const gulp = require("gulp"); 2 | const config = require("../config"); 3 | const browserSync = require("browser-sync"); 4 | const watch = require("gulp-watch"); 5 | const runSequence = require("run-sequence"); 6 | 7 | gulp.task("watch", () => { 8 | watch(config.styles.files_src, "./src/assets", function() { 9 | runSequence("styles"); 10 | }); 11 | 12 | watch(config.images.files_src, () => { 13 | runSequence("images", browserSync.reload); 14 | }); 15 | 16 | watch(config.icons.src_files, () => { 17 | runSequence("icons", "templates", browserSync.reload); 18 | }); 19 | 20 | watch(config.templates.files_src, () => { 21 | runSequence("templates", browserSync.reload); 22 | }); 23 | 24 | watch(config.fonts.src, () => { 25 | runSequence("fonts", browserSync.reload); 26 | }); 27 | }); 28 | -------------------------------------------------------------------------------- /src/template/pages/home.pug: -------------------------------------------------------------------------------- 1 | extends ../layout/base 2 | 3 | block content 4 | .l-wrapper 5 | p Lorem ipsum dolor sit amet consectetur, adipisicing elit. Qui nesciunt nisi est fugit voluptatum aspernatur magni. Voluptatibus non nemo quibusdam recusandae culpa voluptates hic, laudantium velit, labore, rerum commodi! Aliquam. 6 | p Lorem ipsum dolor sit amet consectetur, adipisicing elit. Qui nesciunt nisi est fugit voluptatum aspernatur magni. Voluptatibus non nemo quibusdam recusandae culpa voluptates hic, laudantium velit, labore, rerum commodi! Aliquam. 7 | p 8 | a(href='#') Lorem ipsum dolor sit amet consectetur, 9 | | 10 | | adipisicing elit. Qui nesciunt nisi est fugit voluptatum aspernatur magni. Voluptatibus non nemo quibusdam recusandae culpa voluptates hic, laudantium velit, labore, rerum commodi! Aliquam. 11 | 12 | -------------------------------------------------------------------------------- /gulp/tasks/svg.js: -------------------------------------------------------------------------------- 1 | const gulp = require("gulp"); 2 | const config = require("../config").svg; 3 | const imagemin = require("gulp-imagemin"); 4 | const size = require("gulp-size"); 5 | const plumber = require("gulp-plumber"); 6 | const notify = require("gulp-notify"); 7 | 8 | gulp.task("svg", () => { 9 | return gulp 10 | .src(config.files_src) 11 | .pipe( 12 | plumber({ 13 | errorHandler: notify.onError("SVG Error: <%= error.message %>"), 14 | }) 15 | ) 16 | .pipe( 17 | imagemin( 18 | [ 19 | imagemin.svgo({ 20 | plugins: [{ removeViewBox: false }, { removeDimensions: false }], 21 | }), 22 | ], 23 | { 24 | verbose: true, 25 | } 26 | ) 27 | ) 28 | .pipe( 29 | size({ 30 | title: "svg", 31 | }) 32 | ) 33 | .pipe(gulp.dest(config.dist)); 34 | }); 35 | -------------------------------------------------------------------------------- /src/template/pages/styleguide/atoms/a-label.pug: -------------------------------------------------------------------------------- 1 | extends ../../../layout/styleguide 2 | 3 | append config 4 | - var template = 't-styleguide' 5 | - var title = "Labels" 6 | - var metaDesc = "Labels - CSS / HTML" 7 | - var path = './../../' 8 | 9 | block content 10 | .hf-head 11 | .hf-wrapper 12 | h1 Labels 13 | .hf-wrapper 14 | .hf-content 15 | h2#styles Styles 16 | h3 Label de base 17 | :code 18 | 19 | 20 | .hf-content 21 | h3 Faux label 22 | :code 23 |
${html}
21 | .l-wrapper permet de center des éléments sur la grille.
18 | :code
19 | Lorem ipsum dolor sit amet consectetur adipisicing elit. Reiciendis vero debitis est facilis, neque eveniet corporis sunt qui necessitatibus dolores quisquam aperiam omnis itaque laboriosam non, quaerat iure. Voluptates, exercitationem.
21 |Lorem ipsum dolor sit amet consectetur adipisicing elit. Reiciendis vero debitis est facilis, neque eveniet corporis sunt qui necessitatibus dolores quisquam aperiam omnis itaque laboriosam non, quaerat iure. Voluptates, exercitationem.
29 |Lorem ipsum dolor sit amet consectetur adipisicing elit. Reiciendis vero debitis est facilis, neque eveniet corporis sunt qui necessitatibus dolores quisquam aperiam omnis itaque laboriosam non, quaerat iure. Voluptates, exercitationem.
36 |.l-grid__item--X-XX à l'élément ayant la classe .l-grid__item afin de modifier son nombre de colonnes.
25 | p Le dernier nombre de la chaine de caractères (ex : -50) correspond à la largeur en pourcentage (50%).
26 | p Modifiers disponibles :
27 | .u-mtM
28 | table
29 | thead
30 | tr
31 | th Taille
32 | th Valeurs
33 | tbody
34 | tr
35 | td
36 | b Taille s - de 480px à 768px
37 | td
38 | s-20
39 | s-25
40 | s-33
41 | s-40
42 | s-50
43 | s-60
44 | s-66
45 | s-75
46 | tr
47 | td
48 | b Taille s-up - sup à 480px
49 | td
50 | s-up-20
51 | s-up-25
52 | s-up-33
53 | s-up-40
54 | s-up-50
55 | s-up-60
56 | s-up-66
57 | s-up-75
58 | s-up-80
59 | tr
60 | td
61 | b Taille m - de 768px à 1049px
62 | td
63 | m-20
64 | m-25
65 | m-33
66 | m-40
67 | m-50
68 | m-60
69 | m-66
70 | m-75
71 | m-80
72 | tr
73 | td
74 | b Taille m-up - sup à 768px
75 | td
76 | m-up-20
77 | m-up-25
78 | m-up-33
79 | m-up-40
80 | m-up-50
81 | m-up-60
82 | m-up-66
83 | m-up-75
84 | m-up-80
85 | tr
86 | td
87 | b Taille l-up - sup à 1049px
88 | td
89 | l-up-20
90 | l-up-25
91 | l-up-33
92 | l-up-40
93 | l-up-50
94 | l-up-60
95 | l-up-66
96 | l-up-75
97 | l-up-80
98 | :code
99 | margin / padding sur un élément. A utiliser pour assembler différents composants sans avoir à définir une nouvelle classe de wrapper.
16 | .hf-content.hf-wrapper
17 | h3 Définition
18 | ul
19 | li p, m = padding, margin
20 | li a, t, r, b, l = all, top, right, bottom, left
21 | li s, m, l, n = Small (10 px), Medium (20 px), Large (40 px) , None (0)
22 | .hf-content.hf-wrapper
23 | h3 Margin
24 | table
25 | thead
26 | tr
27 | th Class
28 | th Usage
29 | tbody
30 | tr
31 | td
32 | code .u-mas
33 | td margin: 10 px;
34 | tr
35 | td
36 | code .u-mam
37 | td margin: 20 px;
38 | tr
39 | td
40 | code .u-mal
41 | td margin: 40 px;
42 | tr
43 | td
44 | code .u-man
45 | td margin: 0;
46 | tr
47 | td
48 | code .u-mts
49 | td margin-top: 10 px;
50 | tr
51 | td
52 | code .u-mtm
53 | td margin-top: 20 px;
54 | tr
55 | td
56 | code .u-mtl
57 | td margin-top: 40 px;
58 | tr
59 | td
60 | code .u-mtn
61 | td margin-top: 0;
62 | tr
63 | td
64 | code .u-mrs
65 | td margin-right: 10 px;
66 | tr
67 | td
68 | code .u-mrm
69 | td margin-right: 20 px;
70 | tr
71 | td
72 | code .u-mrl
73 | td margin-right: 40 px;
74 | tr
75 | td
76 | code .u-mrn
77 | td margin-right: 0;
78 | tr
79 | td
80 | code .u-mbs
81 | td margin-bottom: 10 px;
82 | tr
83 | td
84 | code .u-mbm
85 | td margin-bottom: 20 px;
86 | tr
87 | td
88 | code .u-mbl
89 | td margin-bottom: 40 px;
90 | tr
91 | td
92 | code .u-mbn
93 | td margin-bottom: 0;
94 | tr
95 | td
96 | code .u-mls
97 | td margin-left: 10 px;
98 | tr
99 | td
100 | code .u-mlm
101 | td margin-left: 20 px;
102 | tr
103 | td
104 | code .u-mll
105 | td margin-left: 40 px;
106 | tr
107 | td
108 | code .u-mln
109 | td margin-left: 0;
110 | .hf-content.hf-wrapper
111 | h3 Padding
112 | table
113 | thead
114 | tr
115 | th Class
116 | th Usage
117 | tbody
118 | tr
119 | td
120 | code .u-pas
121 | td padding: 10 px;
122 | tr
123 | td
124 | code .u-pam
125 | td padding: 20 px;
126 | tr
127 | td
128 | code .u-pal
129 | td padding: 40 px;
130 | tr
131 | td
132 | code .u-pan
133 | td padding: 0;
134 | tr
135 | td
136 | code .u-pts
137 | td padding-top: 10 px;
138 | tr
139 | td
140 | code .u-ptm
141 | td padding-top: 20 px;
142 | tr
143 | td
144 | code .u-ptl
145 | td padding-top: 40 px;
146 | tr
147 | td
148 | code .u-ptn
149 | td padding-top: 0;
150 | tr
151 | td
152 | code .u-prs
153 | td padding-right: 10 px;
154 | tr
155 | td
156 | code .u-prm
157 | td padding-right: 20 px;
158 | tr
159 | td
160 | code .u-prl
161 | td padding-right: 40 px;
162 | tr
163 | td
164 | code .u-prn
165 | td padding-right: 0;
166 | tr
167 | td
168 | code .u-pbs
169 | td padding-bottom: 10 px;
170 | tr
171 | td
172 | code .u-pbm
173 | td padding-bottom: 20 px;
174 | tr
175 | td
176 | code .u-pbl
177 | td padding-bottom: 40 px;
178 | tr
179 | td
180 | code .u-pbn
181 | td padding-bottom: 0;
182 | tr
183 | td
184 | code .u-pls
185 | td padding-left: 10 px;
186 | tr
187 | td
188 | code .u-plm
189 | td padding-left: 20 px;
190 | tr
191 | td
192 | code .u-pll
193 | td padding-left: 40 px;
194 | tr
195 | td
196 | code .u-pln
197 | td padding-left: 0;
198 |
--------------------------------------------------------------------------------
/src/assets/scss/base/_b_normalize.scss:
--------------------------------------------------------------------------------
1 | /*! normalize.css v8.0.1 | MIT License | github.com/necolas/normalize.css */
2 |
3 | /* Document
4 | ========================================================================== */
5 |
6 | /**
7 | * 1. Correct the line height in all browsers.
8 | * 2. Prevent adjustments of font size after orientation changes in iOS.
9 | */
10 |
11 | html {
12 | line-height: 1.15; /* 1 */
13 | -webkit-text-size-adjust: 100%; /* 2 */
14 | }
15 |
16 | /* Sections
17 | ========================================================================== */
18 |
19 | /**
20 | * Remove the margin in all browsers.
21 | */
22 |
23 | body {
24 | margin: 0;
25 | }
26 |
27 | /**
28 | * Render the `main` element consistently in IE.
29 | */
30 |
31 | main {
32 | display: block;
33 | }
34 |
35 | /**
36 | * Correct the font size and margin on `h1` elements within `section` and
37 | * `article` contexts in Chrome, Firefox, and Safari.
38 | */
39 |
40 | h1 {
41 | font-size: 2em;
42 | margin: 0.67em 0;
43 | }
44 |
45 | /* Grouping content
46 | ========================================================================== */
47 |
48 | /**
49 | * 1. Add the correct box sizing in Firefox.
50 | * 2. Show the overflow in Edge and IE.
51 | */
52 |
53 | hr {
54 | box-sizing: content-box; /* 1 */
55 | height: 0; /* 1 */
56 | overflow: visible; /* 2 */
57 | }
58 |
59 | /**
60 | * 1. Correct the inheritance and scaling of font size in all browsers.
61 | * 2. Correct the odd `em` font sizing in all browsers.
62 | */
63 |
64 | pre {
65 | font-family: monospace, monospace; /* 1 */
66 | font-size: 1em; /* 2 */
67 | }
68 |
69 | /* Text-level semantics
70 | ========================================================================== */
71 |
72 | /**
73 | * Remove the gray background on active links in IE 10.
74 | */
75 |
76 | a {
77 | background-color: transparent;
78 | }
79 |
80 | /**
81 | * 1. Remove the bottom border in Chrome 57-
82 | * 2. Add the correct text decoration in Chrome, Edge, IE, Opera, and Safari.
83 | */
84 |
85 | abbr[title] {
86 | border-bottom: none; /* 1 */
87 | text-decoration: underline; /* 2 */
88 | text-decoration: underline dotted; /* 2 */
89 | }
90 |
91 | /**
92 | * Add the correct font weight in Chrome, Edge, and Safari.
93 | */
94 |
95 | b,
96 | strong {
97 | font-weight: bolder;
98 | }
99 |
100 | /**
101 | * 1. Correct the inheritance and scaling of font size in all browsers.
102 | * 2. Correct the odd `em` font sizing in all browsers.
103 | */
104 |
105 | code,
106 | kbd,
107 | samp {
108 | font-family: monospace, monospace; /* 1 */
109 | font-size: 1em; /* 2 */
110 | }
111 |
112 | /**
113 | * Add the correct font size in all browsers.
114 | */
115 |
116 | small {
117 | font-size: 80%;
118 | }
119 |
120 | /**
121 | * Prevent `sub` and `sup` elements from affecting the line height in
122 | * all browsers.
123 | */
124 |
125 | sub,
126 | sup {
127 | font-size: 75%;
128 | line-height: 0;
129 | position: relative;
130 | vertical-align: baseline;
131 | }
132 |
133 | sub {
134 | bottom: -0.25em;
135 | }
136 |
137 | sup {
138 | top: -0.5em;
139 | }
140 |
141 | /* Embedded content
142 | ========================================================================== */
143 |
144 | /**
145 | * Remove the border on images inside links in IE 10.
146 | */
147 |
148 | img {
149 | border-style: none;
150 | }
151 |
152 | /* Forms
153 | ========================================================================== */
154 |
155 | /**
156 | * 1. Change the font styles in all browsers.
157 | * 2. Remove the margin in Firefox and Safari.
158 | */
159 |
160 | button,
161 | input,
162 | optgroup,
163 | select,
164 | textarea {
165 | font-family: inherit; /* 1 */
166 | font-size: 100%; /* 1 */
167 | line-height: 1.15; /* 1 */
168 | margin: 0; /* 2 */
169 | }
170 |
171 | /**
172 | * Show the overflow in IE.
173 | * 1. Show the overflow in Edge.
174 | */
175 |
176 | button,
177 | input {
178 | /* 1 */
179 | overflow: visible;
180 | }
181 |
182 | /**
183 | * Remove the inheritance of text transform in Edge, Firefox, and IE.
184 | * 1. Remove the inheritance of text transform in Firefox.
185 | */
186 |
187 | button,
188 | select {
189 | /* 1 */
190 | text-transform: none;
191 | }
192 |
193 | /**
194 | * Correct the inability to style clickable types in iOS and Safari.
195 | */
196 |
197 | button,
198 | [type="button"],
199 | [type="reset"],
200 | [type="submit"] {
201 | -webkit-appearance: button;
202 | }
203 |
204 | /**
205 | * Remove the inner border and padding in Firefox.
206 | */
207 |
208 | button::-moz-focus-inner,
209 | [type="button"]::-moz-focus-inner,
210 | [type="reset"]::-moz-focus-inner,
211 | [type="submit"]::-moz-focus-inner {
212 | border-style: none;
213 | padding: 0;
214 | }
215 |
216 | /**
217 | * Restore the focus styles unset by the previous rule.
218 | */
219 |
220 | button:-moz-focusring,
221 | [type="button"]:-moz-focusring,
222 | [type="reset"]:-moz-focusring,
223 | [type="submit"]:-moz-focusring {
224 | outline: 1px dotted ButtonText;
225 | }
226 |
227 | /**
228 | * Correct the padding in Firefox.
229 | */
230 |
231 | fieldset {
232 | padding: 0.35em 0.75em 0.625em;
233 | }
234 |
235 | /**
236 | * 1. Correct the text wrapping in Edge and IE.
237 | * 2. Correct the color inheritance from `fieldset` elements in IE.
238 | * 3. Remove the padding so developers are not caught out when they zero out
239 | * `fieldset` elements in all browsers.
240 | */
241 |
242 | legend {
243 | box-sizing: border-box; /* 1 */
244 | color: inherit; /* 2 */
245 | display: table; /* 1 */
246 | max-width: 100%; /* 1 */
247 | padding: 0; /* 3 */
248 | white-space: normal; /* 1 */
249 | }
250 |
251 | /**
252 | * Add the correct vertical alignment in Chrome, Firefox, and Opera.
253 | */
254 |
255 | progress {
256 | vertical-align: baseline;
257 | }
258 |
259 | /**
260 | * Remove the default vertical scrollbar in IE 10+.
261 | */
262 |
263 | textarea {
264 | overflow: auto;
265 | }
266 |
267 | /**
268 | * 1. Add the correct box sizing in IE 10.
269 | * 2. Remove the padding in IE 10.
270 | */
271 |
272 | [type="checkbox"],
273 | [type="radio"] {
274 | box-sizing: border-box; /* 1 */
275 | padding: 0; /* 2 */
276 | }
277 |
278 | /**
279 | * Correct the cursor style of increment and decrement buttons in Chrome.
280 | */
281 |
282 | [type="number"]::-webkit-inner-spin-button,
283 | [type="number"]::-webkit-outer-spin-button {
284 | height: auto;
285 | }
286 |
287 | /**
288 | * 1. Correct the odd appearance in Chrome and Safari.
289 | * 2. Correct the outline style in Safari.
290 | */
291 |
292 | [type="search"] {
293 | -webkit-appearance: textfield; /* 1 */
294 | outline-offset: -2px; /* 2 */
295 | }
296 |
297 | /**
298 | * Remove the inner padding in Chrome and Safari on macOS.
299 | */
300 |
301 | [type="search"]::-webkit-search-decoration {
302 | -webkit-appearance: none;
303 | }
304 |
305 | /**
306 | * 1. Correct the inability to style clickable types in iOS and Safari.
307 | * 2. Change font properties to `inherit` in Safari.
308 | */
309 |
310 | ::-webkit-file-upload-button {
311 | -webkit-appearance: button; /* 1 */
312 | font: inherit; /* 2 */
313 | }
314 |
315 | /* Interactive
316 | ========================================================================== */
317 |
318 | /*
319 | * Add the correct display in Edge, IE 10+, and Firefox.
320 | */
321 |
322 | details {
323 | display: block;
324 | }
325 |
326 | /*
327 | * Add the correct display in all browsers.
328 | */
329 |
330 | summary {
331 | display: list-item;
332 | }
333 |
334 | /* Misc
335 | ========================================================================== */
336 |
337 | /**
338 | * Add the correct display in IE 10+.
339 | */
340 |
341 | template {
342 | display: none;
343 | }
344 |
345 | /**
346 | * Add the correct display in IE 10.
347 | */
348 |
349 | [hidden] {
350 | display: none;
351 | }
352 |
--------------------------------------------------------------------------------
/src/assets/scss/styleguide.scss:
--------------------------------------------------------------------------------
1 | @charset 'UTF-8';
2 |
3 | @import "tools/function";
4 | @import "settings";
5 | @import "tools/mixin";
6 |
7 | // =======================================
8 | // Styleguide
9 | // =======================================
10 |
11 | $styleguideSidebar: 20rem;
12 |
13 | .hf-styleguide {
14 | min-height: 100vh;
15 | position: relative;
16 | overflow-y: scroll;
17 | > header {
18 | position: fixed;
19 | overflow-y: auto;
20 | top: 0;
21 | left: 0;
22 | bottom: 0;
23 | width: $styleguideSidebar;
24 | padding: 4rem 2rem;
25 | background: $clr-0-darker;
26 |
27 | nav {
28 | display: flex;
29 | flex-direction: column;
30 | margin-top: 3rem;
31 | font-size: 14px;
32 | p {
33 | color: #fff;
34 | font-size: 1.8rem;
35 | margin-bottom: 1rem;
36 | &:not(:first-child) {
37 | margin-top: 3rem;
38 | }
39 | }
40 | a {
41 | color: rgba(255, 255, 255, 0.5);
42 | &:not(:first-child) {
43 | margin-top: 1rem;
44 | }
45 | }
46 | }
47 | }
48 |
49 | > main {
50 | padding: 0 2rem 2rem $styleguideSidebar + 2rem;
51 | background: #fff;
52 | counter-reset: section;
53 | }
54 | }
55 |
56 | .hf-styleguide-title {
57 | color: #fff;
58 | text-transform: uppercase;
59 | font-size: 2.2rem;
60 | }
61 |
62 | .hf-styleguide-linkBack {
63 | color: $clr-1;
64 | display: inline-flex;
65 | margin: 2rem 0;
66 | align-items: center;
67 | font-size: 1.4rem;
68 | transition: color 0.3s ease-in-out;
69 | &:before {
70 | content: "";
71 | display: block;
72 | width: 0.8rem;
73 | height: 0.8rem;
74 | margin-right: 0.2rem;
75 | background: $clr-0-darker;
76 | box-shadow: -2px 2px 0 $clr-1;
77 | transform: rotate(45deg);
78 | transition: box-shadow 0.3s ease-in-out;
79 | }
80 |
81 | &:hover {
82 | color: $clr-1-light;
83 | &:before {
84 | box-shadow: -2px 2px 0 $clr-1-light;
85 | }
86 | }
87 | }
88 |
89 | // =======================================
90 | // hf
91 | // =======================================
92 |
93 | .hf-content {
94 | margin-top: 4rem;
95 | * {
96 | line-height: 1.5;
97 | }
98 | h2 {
99 | font-size: 2.6rem;
100 | font-weight: $font-weight-bold;
101 | border-bottom: 1px solid #ededed;
102 | padding: 0 0 15px;
103 | + * {
104 | margin-top: 3rem;
105 | }
106 | }
107 |
108 | h3 {
109 | font-size: 2rem;
110 | font-weight: $font-weight-bold;
111 | margin-bottom: 20px;
112 |
113 | &:before {
114 | display: inline-block;
115 | margin-right: 6px;
116 | font-weight: 400;
117 | color: complement($clr-1);
118 | content: counter(section) " -";
119 | counter-increment: section;
120 | }
121 | }
122 |
123 | ul {
124 | margin: 2rem 0;
125 | }
126 |
127 | li {
128 | list-style-type: none;
129 | &:before {
130 | content: "- ";
131 | }
132 | }
133 |
134 | a {
135 | color: $clr-1;
136 | transition: color 0.3s ease-in-out;
137 |
138 | &:hover {
139 | color: $clr-1-light;
140 | }
141 | }
142 |
143 | code {
144 | color: darken(complement($clr-1), 30%);
145 | background-color: lighten(complement($clr-1), 25%);
146 | padding: 2px 6px;
147 | font-size: 90%;
148 | vertical-align: middle;
149 | border-radius: 3px;
150 | border: 1px solid lighten(complement($clr-1), 15%);
151 | }
152 |
153 | pre code {
154 | background: $clr-0-darker;
155 | display: block;
156 | color: #fff;
157 | padding: 20px;
158 | border-radius: 3px;
159 | }
160 |
161 | table {
162 | margin: 30px 0;
163 | width: 100%;
164 | border: 1px solid #f2f2f2;
165 | background: #fff;
166 | tr:nth-child(even) {
167 | background: #fafafa;
168 | }
169 | th {
170 | padding: 10px 20px;
171 | border-bottom: 2px solid #f2f2f2;
172 | font-weight: $font-weight-bold;
173 | }
174 | td {
175 | padding: 10px 20px;
176 | font-size: 14px;
177 | border-bottom: 1px solid #f2f2f2;
178 | &:not(:first-child) {
179 | border-left: 1px solid #f2f2f2;
180 | }
181 | &:first-child {
182 | width: 300px;
183 | }
184 | code {
185 | white-space: nowrap;
186 | }
187 | }
188 | }
189 | }
190 |
191 | .hf-bullet {
192 | display: inline-block;
193 | width: 60px;
194 | height: 20px;
195 | margin-right: 10px;
196 | vertical-align: middle;
197 | border: 1px solid #ededed;
198 | border-radius: 20px;
199 | }
200 |
201 | .hf-gridItem {
202 | height: 20px;
203 | background: #ccc;
204 | }
205 |
206 | .hf-wrapper {
207 | max-width: 900px;
208 | margin-right: auto;
209 | margin-left: auto;
210 | padding-left: 20px;
211 | padding-right: 20px;
212 | }
213 |
214 | .hf-head {
215 | margin: 0 -2rem;
216 | padding: 3.5rem 0;
217 | background: $clr-1;
218 | color: #fff;
219 |
220 | .hf-wrapper {
221 | display: flex;
222 | justify-content: space-between;
223 | }
224 |
225 | h1 {
226 | font-size: 2.4rem;
227 | margin: 0.5rem 0;
228 | text-transform: uppercase;
229 | letter-spacing: 1px;
230 | font-weight: $font-weight-bold;
231 | }
232 |
233 | nav {
234 | a {
235 | font-size: 14px;
236 | letter-spacing: 1px;
237 | display: inline-block;
238 | padding: 8px 20px;
239 | color: #fff;
240 | background: rgba(#fff, 0.1);
241 | border-radius: 666px;
242 | transition: background 0.3s ease-in-out, color 0.3s ease-in-out;
243 | &:hover {
244 | background: #fff;
245 | color: $clr-1;
246 | }
247 | + a {
248 | margin-left: 10px;
249 | }
250 | }
251 | }
252 | }
253 |
254 | .hf-box {
255 | background: $clr-1;
256 | padding: 2rem;
257 | }
258 |
259 | .hf-exemple {
260 | &:not(:first-child) {
261 | margin-top: 2rem;
262 | }
263 | }
264 |
265 | .hf-preview {
266 | margin-top: 20px;
267 | padding: 20px;
268 | border-left: 2px solid #282a36;
269 | border-right: 2px solid #282a36;
270 | border-top: 2px solid #282a36;
271 | background: #fff;
272 | border-radius: 0.3rem 0.3rem 0 0;
273 |
274 | &:last-child {
275 | margin-bottom: 0.2rem;
276 | border-radius: 0.3rem;
277 | border-bottom: 2px solid #f7f7f9;
278 | border-radius: 0.3rem;
279 | }
280 |
281 | .l-grid__item {
282 | background: $clr-0-lighter;
283 | padding: 10px;
284 | text-align: center;
285 | font-weight: bold;
286 | box-shadow: inset 0 0 0 1px $clr-0-light;
287 | }
288 |
289 | & + .hf-code {
290 | border-radius: 0 0 0.3rem 0.3rem;
291 | }
292 | }
293 |
294 | .hf-code {
295 | font-size: 80%;
296 | background: #282a36;
297 | margin: 0;
298 | padding: 2rem;
299 | overflow: auto;
300 | line-height: 1.5;
301 | border-radius: 0.3rem;
302 | white-space: pre-wrap;
303 | .hljs {
304 | color: #f2f6f2;
305 | }
306 |
307 | .hljs-comment,
308 | .hljs-quote {
309 | color: #5c6370;
310 | font-style: italic;
311 | }
312 |
313 | .hljs-doctag,
314 | .hljs-keyword,
315 | .hljs-formula {
316 | color: #c678dd;
317 | }
318 |
319 | .hljs-section,
320 | .hljs-name,
321 | .hljs-selector-tag,
322 | .hljs-deletion,
323 | .hljs-subst {
324 | color: #ff6ec6;
325 | }
326 |
327 | .hljs-literal {
328 | color: #56b6c2;
329 | }
330 |
331 | .hljs-string,
332 | .hljs-regexp,
333 | .hljs-addition,
334 | .hljs-attribute,
335 | .hljs-meta-string {
336 | color: #eeee69;
337 | }
338 |
339 | .hljs-built_in,
340 | .hljs-class .hljs-title {
341 | color: #00fa58;
342 | }
343 |
344 | .hljs-attr,
345 | .hljs-variable,
346 | .hljs-template-variable,
347 | .hljs-type,
348 | .hljs-selector-class,
349 | .hljs-selector-attr,
350 | .hljs-selector-pseudo,
351 | .hljs-number {
352 | color: #00fa58;
353 | }
354 |
355 | .hljs-symbol,
356 | .hljs-bullet,
357 | .hljs-link,
358 | .hljs-meta,
359 | .hljs-selector-id,
360 | .hljs-title {
361 | color: #61aeee;
362 | }
363 |
364 | .hljs-emphasis {
365 | font-style: italic;
366 | }
367 |
368 | .hljs-strong {
369 | font-weight: bold;
370 | }
371 |
372 | .hljs-link {
373 | text-decoration: underline;
374 | }
375 | }
376 |
--------------------------------------------------------------------------------
/src/template/pages/styleguide/molecules/m-content.pug:
--------------------------------------------------------------------------------
1 | extends ../../../layout/styleguide
2 |
3 | append config
4 | - var template = 't-styleguide'
5 | - var title = "Contenu"
6 | - var metaDesc = "Contenu - CSS / HTML"
7 | - var path = './../../'
8 |
9 | block content
10 | .hf-head
11 | .hf-wrapper
12 | h1 Content
13 | .hf-wrapper
14 | .hf-content
15 | h2 Styles de base
16 | p La molecule .m-content permet de styliser tout les éléments HTML de base pour un contenu éditorial.
17 | :code
18 | One night when I had tasted bitterness I went out on to the hill. Dark heather checked my feet. Below marched the suburban lamps.
21 |Windows, their curtains drawn, were shut eyes, inwardly watching the lives of dreams. Beyond the sea’s level darkness a lighthouse pulsed. Overhead, obscurity. I distinguished our own house, our islet in the tumultuous and bitter currents of the world. 22 | There, for a decade and a half, we two, so different in quality, had grown in and in to one another, for mutual support and nourishment, in intricate symbiosis. There daily we planned our several undertakings, and recounted the day’s oddities 23 | and vexations. There letters piled up to be answered, socks to be darned. There the children were born, those sudden new lives. There, under that roof, our own two lives, recalcitrant sometimes to one another, were all the while thankfully one, 24 | one larger, more conscious life than either alone.
25 |Yet there was bitterness. And bitterness not only invaded us from the world; it welled up also within our own magic circle. For horror at our futility, at our own unreality, and not only at the world’s delirium, had driven me out on to the hill.
27 |We were always hurrying from one little urgent task to another, but the upshot was insubstantial. Had we, perhaps, misconceived our whole existence? Were we, as it were, living from false premises? And in particular, this partnership of ours, this 28 | seemingly so well-based fulcrum for activity in the world, was it after all nothing but a little eddy of complacent and ingrown domesticity, ineffectively whirling on the surface of the great flux, having in itself no depth of being, and no significance? 29 | Had we perhaps after all deceived ourselves? Behind those rapt windows did we, like so many others, indeed live only a dream? In a sick world even the hale are sick. And we two, spinning our little life mostly by rote, seldom with clear cognizance, 30 | seldom with firm intent, were products of a sick world.
31 |Yet this life of ours was not all sheer and barren fantasy. Was it not spun from the actual fibres of reality, which we gathered in with all the comings and goings through our door, all our traffic with the suburb and the city and with remoter cities, 32 | and with the ends of the earth? And were we not spinning together an authentic expression of our own nature? Did not our life issue daily as more or less firm threads of active living, and mesh itself into the growing web, the intricate, ever-proliferating 33 | pattern of mankind?
34 |And a kind of amused awe. How could I describe our relationship even to myself without either disparaging it or insulting it with the tawdry decoration of sentimentality? For this our delicate balance of dependence and independence, this coolly critical, 36 | shrewdly ridiculing, but loving mutual contact, was surely a microcosm of true community, was after all in its simple style an actual and living example of that high goal which the world seeks.
37 |38 |42 |I reflected that not one of the visible features of this celestial and living gem revealed the presence of man. Displayed before me, though invisible, were some of the most congested centers of human population. There below me lay huge industrial 39 | regions, blackening the air with smoke. Yet all this thronging life and humanly momentous enterprise had made no mark whatever on the features of the planet. From this high look-out the Earth would have appeared no different before the dawn 40 | of man. No visiting angel, or explorer from another planet, could have guessed that this bland orb teemed with vermin, with world-mastering, self-torturing, incipiently angelic beasts. — Olaf Stapledon, Star Maker
41 |
The whole world? The whole universe? Overhead, obscurity unveiled a star. One tremulous arrow of light, projected how many thousands of years ago, now stung my nerves with vision, and my heart with fear. For in such a universe as this what significance 43 | could there be in our fortuitous, our frail, our evanescent community?
44 |With a strange worship, not, surely of the star, that mere furnace which mere distance falsely sanctified, but of something other, which the dire contrast of the star and us signified to the heart. Yet what, what could thus be signified? Intellect, 46 | peering beyond the star, discovered no Star Maker, but only darkness; no Love, no Power even, but only Nothing.
47 |Impatiently I shook off this folly, and reverted from the inscrutable to the familiar and the concrete. Thrusting aside worship, and fear also and bitterness, I determined to examine more coldly this remarkable “us,” this surprisingly impressive datum, 49 | which to ourselves remained basic to the universe, though in relation to the stars it appeared so slight a thing.
50 |We were after all insignificant, perhaps ridiculous. We were such a commonplace occurrence, so trite, so respectable. We were just a married couple, making shift to live together without undue strain. Marriage in our time was suspect. And ours, with 52 | its trivial romantic origin, was doubly suspect.
53 |Yes! How predestinate had seemed our union! Yet now, in retrospect, how accidental. True, of course, that as a long-married couple we fitted rather neatly, like two close trees whose trunks have grown upwards together as a single shaft, mutually distorting, but mutually supporting. ABC
Here's some code: e = mc2
\n80 |
| # | 91 |First Name | 92 |Last Name | 93 |Username | 94 |
|---|---|---|---|
| 1 | 99 |Mark | 100 |Otto | 101 |@mdo | 102 |
| 2 | 105 |Jacob | 106 |Thornton | 107 |@fat | 108 |
| 3 | 111 |Larry | 112 |the Bird | 113 |