├── .all-contributorsrc ├── .babelrc ├── .babelrc.js ├── .editorconfig ├── .eslintignore ├── .eslintrc ├── .flowconfig ├── .gitattributes ├── .github ├── ISSUE_TEMPLATE.md └── PULL_REQUEST_TEMPLATE.md ├── .gitignore ├── .npmrc ├── .stylelintrc.json ├── .travis.yml ├── CHANGELOG.md ├── CODE_OF_CONDUCT.MD ├── CONTRIBUTING.md ├── LICENSE ├── README.md ├── __tests__ ├── advanced.js ├── api.js ├── basics.js ├── examples.js ├── index.js └── integrations.js ├── components ├── __tests__ │ ├── __snapshots__ │ │ ├── code-sandbox-embed.js.snap │ │ └── interactive-markdown.js.snap │ ├── code-sandbox-embed.js │ ├── interactive-markdown.js │ └── locale-chooser.js ├── algolia-config.js ├── callout.js ├── click-to-render.js ├── code-preview.js ├── code-sandbox-embed.js ├── console-greet.js ├── content │ ├── contributors.md │ ├── de │ │ ├── contributors.md │ │ ├── footer.md │ │ ├── locale-chooser.md │ │ └── nav.md │ ├── es │ │ ├── contributors.md │ │ ├── footer.md │ │ ├── locale-chooser.md │ │ └── nav.md │ ├── footer.md │ ├── fr │ │ ├── contributors.md │ │ ├── footer.md │ │ ├── locale-chooser.md │ │ └── nav.md │ ├── locale-chooser.md │ ├── nav.md │ ├── ru │ │ ├── contributors.md │ │ ├── footer.md │ │ ├── locale-chooser.md │ │ └── nav.md │ └── zh │ │ ├── contributors.md │ │ ├── footer.md │ │ ├── locale-chooser.md │ │ └── nav.md ├── contributors.js ├── docs-page │ ├── content │ │ ├── de │ │ │ └── index.md │ │ ├── es │ │ │ └── index.md │ │ ├── fr │ │ │ └── index.md │ │ ├── index.md │ │ ├── ru │ │ │ └── index.md │ │ ├── what-changed.md │ │ └── zh │ │ │ └── index.md │ ├── index.js │ ├── svgs │ │ ├── github.svg │ │ └── link.svg │ └── what-changed.js ├── footer.js ├── glamorous-logo.js ├── google-analytics.js ├── hero.js ├── inline-script.js ├── interactive-markdown.js ├── layout.js ├── lipstick-icon.js ├── locale-chooser.js ├── nav.js ├── separator.js ├── static-code-block.js ├── styled-links.js ├── svgs │ ├── cn.svg │ ├── de.svg │ ├── en.svg │ ├── es.svg │ ├── fr.svg │ ├── menu.svg │ ├── ru.svg │ └── search.svg ├── twitter-card.js └── utils │ ├── locale.js │ ├── md-to-html.js │ └── strip-indent.js ├── config.json ├── crowdin.yml ├── next.config.js ├── other ├── CONTRIBUTING_DOCUMENTATION.md ├── __tests__ │ ├── __snapshots__ │ │ ├── babel-plugin-l10-loader.es.js.snap │ │ ├── babel-plugin-l10-loader.fr.js.snap │ │ └── babel-plugin-l10-loader.js.snap │ ├── babel-plugin-l10-loader.es.js │ ├── babel-plugin-l10-loader.fr.js │ ├── babel-plugin-l10-loader.js │ └── fixtures │ │ ├── content │ │ ├── file.raw.js │ │ ├── fr │ │ │ ├── file.raw.js │ │ │ ├── index.js │ │ │ └── index.md │ │ ├── index.js │ │ └── index.md │ │ └── some-component.js ├── babel-plugin-l10n-loader.js ├── get-build-info.js ├── git.js ├── list-l10n.js ├── now-travis ├── test-setup.js ├── translation-status.js └── what-changed.js ├── package-scripts.js ├── package.json ├── pages ├── _document.js ├── _document │ ├── content │ │ ├── README.md │ │ ├── es │ │ │ └── index.md │ │ ├── fr │ │ │ └── index.md │ │ ├── index.md │ │ └── ru │ │ │ └── index.md │ └── index.js ├── advanced │ ├── content │ │ ├── context.md │ │ ├── es │ │ │ ├── existing-css.md │ │ │ ├── index.md │ │ │ ├── refs.md │ │ │ ├── size.md │ │ │ ├── ssr.md │ │ │ └── theming.md │ │ ├── existing-css.md │ │ ├── fr │ │ │ ├── existing-css.md │ │ │ ├── index.md │ │ │ ├── refs.md │ │ │ ├── size.md │ │ │ ├── ssr.md │ │ │ └── theming.md │ │ ├── index.md │ │ ├── refs.md │ │ ├── ru │ │ │ ├── context.md │ │ │ ├── existing-css.md │ │ │ ├── index.md │ │ │ ├── refs.md │ │ │ ├── size.md │ │ │ ├── ssr.md │ │ │ └── theming.md │ │ ├── size.md │ │ ├── ssr.md │ │ └── theming.md │ └── index.js ├── api │ ├── content │ │ ├── fr │ │ │ ├── glamorous-component-factory.md │ │ │ ├── glamorous.md │ │ │ ├── index.md │ │ │ └── typescript.md │ │ ├── glamorous-component-factory.md │ │ ├── glamorous.md │ │ ├── index.md │ │ └── typescript.md │ └── index.js ├── basics │ ├── content │ │ ├── animation.md │ │ ├── core-concepts.md │ │ ├── de │ │ │ └── getting-started.md │ │ ├── dynamic-styles.md │ │ ├── es │ │ │ ├── animation.md │ │ │ ├── core-concepts.md │ │ │ ├── dynamic-styles.md │ │ │ ├── index.md │ │ │ ├── install.md │ │ │ └── react-native.md │ │ ├── fr │ │ │ ├── animation.md │ │ │ ├── core-concepts.md │ │ │ ├── dynamic-styles.md │ │ │ ├── index.md │ │ │ ├── install.md │ │ │ └── react-native.md │ │ ├── getting-started.md │ │ ├── index.md │ │ ├── install.md │ │ ├── motivation.md │ │ ├── react-native.md │ │ ├── ru │ │ │ ├── animation.md │ │ │ ├── core-concepts.md │ │ │ ├── dynamic-styles.md │ │ │ ├── index.md │ │ │ ├── install.md │ │ │ ├── motivation.md │ │ │ └── react-native.md │ │ └── zh │ │ │ ├── animation.md │ │ │ ├── core-concepts.md │ │ │ ├── dynamic-styles.md │ │ │ ├── getting-started.md │ │ │ ├── index.md │ │ │ ├── install.md │ │ │ ├── motivation.md │ │ │ └── react-native.md │ └── index.js ├── examples │ ├── content │ │ ├── breadcrumbs.md │ │ ├── button.md │ │ ├── component-as-selector.md │ │ ├── css-grid.md │ │ ├── es │ │ │ ├── css-grid.md │ │ │ ├── index.md │ │ │ └── style-overrides.md │ │ ├── fr │ │ │ ├── button.md │ │ │ ├── css-grid.md │ │ │ ├── index.md │ │ │ └── style-overrides.md │ │ ├── index.md │ │ ├── nav-link.md │ │ ├── prop-styles.md │ │ ├── specificity.md │ │ ├── style-overrides.md │ │ └── transition-group.md │ └── index.js ├── getting-started │ ├── content │ │ ├── de │ │ │ ├── getting-started-code.raw.js │ │ │ ├── guide.md │ │ │ └── index.md │ │ ├── getting-started-code.raw.js │ │ ├── guide.md │ │ ├── index.md │ │ └── ru │ │ │ ├── getting-started-code.raw.js │ │ │ ├── guide.md │ │ │ └── index.md │ └── index.js ├── index.js ├── index │ ├── content │ │ ├── es │ │ │ ├── home-page-example.raw.js │ │ │ └── index.md │ │ ├── fr │ │ │ ├── home-page-example.raw.js │ │ │ └── index.md │ │ ├── home-page-example.raw.js │ │ ├── index.md │ │ ├── ru │ │ │ └── index.md │ │ └── zh │ │ │ └── index.md │ └── index.js └── integrations │ ├── content │ ├── create-react-app.md │ ├── fr │ │ ├── create-react-app.md │ │ ├── glam-props.md │ │ ├── glamor.md │ │ ├── index.md │ │ ├── jest.md │ │ ├── next.md │ │ ├── polished.md │ │ ├── pseudo.md │ │ ├── recompose.md │ │ └── styled-system.md │ ├── glam-props.md │ ├── glamor.md │ ├── index.md │ ├── jest.md │ ├── next.md │ ├── polished.md │ ├── preact.md │ ├── pseudo.md │ ├── recompose.md │ └── styled-system.md │ └── index.js ├── static └── images │ ├── banner.png │ ├── g-background.svg │ └── icon.png └── styles ├── base.js └── global-styles.js /.babelrc: -------------------------------------------------------------------------------- 1 | { 2 | "presets": ["./.babelrc.js"], 3 | } 4 | -------------------------------------------------------------------------------- /.babelrc.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | presets: [ 3 | [ 4 | 'env', 5 | { 6 | targets: { 7 | node: '8', 8 | browsers: ['last 2 versions'], 9 | }, 10 | }, 11 | ], 12 | 'stage-2', 13 | 'next/babel', 14 | 'react', 15 | ], 16 | plugins: [ 17 | 'glamorous-displayname', 18 | 'transform-class-properties', 19 | 'inline-react-svg', 20 | './other/babel-plugin-l10n-loader', 21 | 'babel-macros', 22 | // the env variables in the tests aren't neededd to be transpiled 23 | process.env.NODE_ENV !== 'test' 24 | ? 'transform-inline-environment-variables' 25 | : null, 26 | ].filter(Boolean), 27 | } 28 | -------------------------------------------------------------------------------- /.editorconfig: -------------------------------------------------------------------------------- 1 | root = true 2 | 3 | [*] 4 | indent_style = space 5 | indent_size = 2 6 | end_of_line = lf 7 | charset = utf-8 8 | trim_trailing_whitespace = true 9 | insert_final_newline = true 10 | -------------------------------------------------------------------------------- /.eslintignore: -------------------------------------------------------------------------------- 1 | node_modules 2 | coverage 3 | dist 4 | out 5 | flow-typed 6 | *.raw.js 7 | -------------------------------------------------------------------------------- /.eslintrc: -------------------------------------------------------------------------------- 1 | { 2 | "extends": [ 3 | "kentcdodds", 4 | "kentcdodds/react", 5 | "kentcdodds/jsx-a11y", 6 | "kentcdodds/jest", 7 | "kentcdodds/prettier" 8 | ], 9 | "rules": { 10 | "react/prop-types": "off", 11 | "func-style": "off", 12 | "max-len": "off", 13 | "import/no-dynamic-require": "off", 14 | "import/no-unresolved": "off", 15 | "import/no-unassigned-import": "off", 16 | "eol-last": "off", // the crowdin stuff doesn't include a line ending 🙄 17 | }, 18 | "globals": { 19 | "Prism": false, 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /.flowconfig: -------------------------------------------------------------------------------- 1 | [ignore] 2 | /.*/__tests__/.* 3 | .*/node_modules/.* 4 | out/** 5 | 6 | [include] 7 | 8 | [options] 9 | 10 | -------------------------------------------------------------------------------- /.gitattributes: -------------------------------------------------------------------------------- 1 | * text=auto 2 | *.js text eol=lf 3 | -------------------------------------------------------------------------------- /.github/ISSUE_TEMPLATE.md: -------------------------------------------------------------------------------- 1 | 10 | 11 | **Problem Description:** 12 | 13 | 14 | 15 | **Suggested Solution:** 16 | 17 | 18 | -------------------------------------------------------------------------------- /.github/PULL_REQUEST_TEMPLATE.md: -------------------------------------------------------------------------------- 1 | 20 | 21 | 22 | **What**: 23 | 24 | 25 | **Why**: 26 | 27 | 28 | **How**: 29 | 30 | 31 | 32 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | .next 2 | .vscode/ 3 | node_modules 4 | npm-debug.log 5 | coverage 6 | dist 7 | .opt-in 8 | .opt-out 9 | yarn-error.log 10 | out 11 | .DS_Store 12 | -------------------------------------------------------------------------------- /.npmrc: -------------------------------------------------------------------------------- 1 | registry=http://registry.npmjs.org/ 2 | save-exact=true 3 | -------------------------------------------------------------------------------- /.stylelintrc.json: -------------------------------------------------------------------------------- 1 | { 2 | "processors": ["stylelint-processor-glamorous"], 3 | "extends": "stylelint-config-standard", 4 | "rules": { 5 | "length-zero-no-unit": null, 6 | "number-leading-zero": null, 7 | "font-family-no-missing-generic-family-keyword": null, 8 | "selector-pseudo-element-colon-notation": null, 9 | "function-comma-space-after": null, 10 | "color-hex-case": null 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /.travis.yml: -------------------------------------------------------------------------------- 1 | sudo: false 2 | language: node_js 3 | cache: 4 | directories: 5 | - node_modules 6 | notifications: 7 | email: false 8 | node_js: 9 | - '8' 10 | before_install: 11 | - npm install -g await-url@^0.2 12 | script: 13 | - npm start validateAndBuild 14 | after_success: 15 | # report code coverage 16 | - npm install codecov 17 | - codecov 18 | branches: 19 | only: 20 | - master 21 | env: 22 | global: 23 | - secure: >- 24 | HvjQEp26lCqjTIqHq0N5iswOLllXliPr14JgJZ/KFsDajCenO35eKKAfTGbYRi0izNZlfJTlwR91PI92KkkgLprPsnhWA9B5qzdomyq2eRXVIBXN1Wn9FzmpOjlktvhd72fQZPnRkTZD0X1G5P7gfhwAYeWoAbaSsc13wea5dk8ut1k9SxsoXb9/+Pz6J5HSJxDjdwo4o6xJ4v8YLZF8A67yjVsHobrBpdufBfVCk85pQ1MQAbXH0Za5Xl2khUmUBHFBLQt/3YEriSICLN3Ka34eKg3dXo0Tgsr6G3zAfpM9bl1Uv+VxgU1tD/wyRpYwbhZjkMiCXCxm56u/Jh1n4xAdgubnViUstN+6ENeupy+9ZdCVz/FfOjjwscAT5ZWvHSDZkzdCurwFKUN2yBkNvoCYdOslhD1PR2PGzlSk43zMbmCLfMNgvtcDvgHKa93oJ/FYMPkJg7tuSC7BKbqFvEteQN5ITBnWd9PAUB5pOgow8Ta0NBxCqQPdbzn97mYzPzqMsRqS32So6CCtg4cOHJuB76V0RvBmJ9CZ/ri2Whlsb3rzLDeroxD2W9IgpW5JiCzpVMrBi5v/myq8u9kU5VIghHVYFaIpwC43pQStL6rY0H5rlJX6ExV9oaxx8VOOpBnyISY5HOC8cZkIMMV5FiK39hGn/PVuAz5NSLgEtiI= 25 | - secure: >- 26 | sbbsUOat2CK1h5mgC2F/P9b7SUZQaDG4+c7igSRUDffVHkVXiOk+8J5cIXA2+Qlx5+IxS9u1X+quyG4LfeLlNqvX9b4XjmaVOlY4S4QhAMCeKHUWr3egCbeI8T87p2HPns3oTy0q+GjZzRkP9wkhfwlG+NQHelVIHhPIoaAezVbvcpDrBQaJRzuN19yWH0KHDOcW6EyBxP8SWNDoxx2xCLr2Fd/sfQEGnxYdNH9BOVR1Tx9w6FlT1r2Yo6wsOCt/vGc183KVI7JC0TkVJbfshWxd/LnFGG74kL433n+lg9UIZS6vR/zaLUTdbBlH/aXUcoOsU90jM7dbAnBPAQ5ZFxtm/noQ/flxORP7tpkj3wDmXQ/hFJxY8NaCMRClIq7iC1pl4+xfI8lXUeZn7rlaEr54osIHRAEZ8s0/K1xuf+BasASMMA7sOAOvPcx2rPhDfV2gXEG8izkW1t33pdtLp6wU3eZd6fGYCAsbZoFBGGjzd5S4/IilAIflil2KpJJmMnoQEeTSrdKLe0Uuvlelnm/T1ZU/3ooWRvd1FebJxWbdadKc08YI6sbvSqkoncjofaJpDwM0IDPjN8oDY5iVBZmI50u9MCO8OOtmKik/aBjoPncfa3WLvJvcubTiPPYyNocs9TJnfG3PKUr5WpvF+mvbajn6tP+bF1H8zdhMKmw= 27 | -------------------------------------------------------------------------------- /CHANGELOG.md: -------------------------------------------------------------------------------- 1 | # CHANGELOG 2 | 3 | The changelog is automatically updated using [semantic-release](https://github.com/semantic-release/semantic-release). 4 | You can see it on the [releases page](../../releases). 5 | -------------------------------------------------------------------------------- /CODE_OF_CONDUCT.MD: -------------------------------------------------------------------------------- 1 | # Contributor Covenant Code of Conduct 2 | 3 | ## Our Pledge 4 | 5 | In the interest of fostering an open and welcoming environment, we as 6 | contributors and maintainers pledge to making participation in our project and 7 | our community a harassment-free experience for everyone, regardless of age, body 8 | size, disability, ethnicity, gender identity and expression, level of experience, 9 | nationality, personal appearance, race, religion, or sexual identity and 10 | orientation. 11 | 12 | ## Our Standards 13 | 14 | Examples of behavior that contributes to creating a positive environment 15 | include: 16 | 17 | * Using welcoming and inclusive language 18 | * Being respectful of differing viewpoints and experiences 19 | * Gracefully accepting constructive criticism 20 | * Focusing on what is best for the community 21 | * Showing empathy towards other community members 22 | 23 | Examples of unacceptable behavior by participants include: 24 | 25 | * The use of sexualized language or imagery and unwelcome sexual attention or 26 | advances 27 | * Trolling, insulting/derogatory comments, and personal or political attacks 28 | * Public or private harassment 29 | * Publishing others' private information, such as a physical or electronic 30 | address, without explicit permission 31 | * Other conduct which could reasonably be considered inappropriate in a 32 | professional setting 33 | 34 | ## Our Responsibilities 35 | 36 | Project maintainers are responsible for clarifying the standards of acceptable 37 | behavior and are expected to take appropriate and fair corrective action in 38 | response to any instances of unacceptable behavior. 39 | 40 | Project maintainers have the right and responsibility to remove, edit, or 41 | reject comments, commits, code, wiki edits, issues, and other contributions 42 | that are not aligned to this Code of Conduct, or to ban temporarily or 43 | permanently any contributor for other behaviors that they deem inappropriate, 44 | threatening, offensive, or harmful. 45 | 46 | ## Scope 47 | 48 | This Code of Conduct applies both within project spaces and in public spaces 49 | when an individual is representing the project or its community. Examples of 50 | representing a project or community include using an official project e-mail 51 | address, posting via an official social media account, or acting as an appointed 52 | representative at an online or offline event. Representation of a project may be 53 | further defined and clarified by project maintainers. 54 | 55 | ## Enforcement 56 | 57 | Instances of abusive, harassing, or otherwise unacceptable behavior may be 58 | reported by contacting the project team at kent+coc@doddsfamily.us. All 59 | complaints will be reviewed and investigated and will result in a response that 60 | is deemed necessary and appropriate to the circumstances. The project team is 61 | obligated to maintain confidentiality with regard to the reporter of an incident. 62 | Further details of specific enforcement policies may be posted separately. 63 | 64 | Project maintainers who do not follow or enforce the Code of Conduct in good 65 | faith may face temporary or permanent repercussions as determined by other 66 | members of the project's leadership. 67 | 68 | ## Attribution 69 | 70 | This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 1.4, 71 | available at [http://contributor-covenant.org/version/1/4][version] 72 | 73 | [homepage]: http://contributor-covenant.org 74 | [version]: http://contributor-covenant.org/version/1/4/ 75 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | The MIT License (MIT) 2 | Copyright (c) 2016 Kent C. Dodds 3 | 4 | Permission is hereby granted, free of charge, to any person obtaining a copy 5 | of this software and associated documentation files (the "Software"), to deal 6 | in the Software without restriction, including without limitation the rights 7 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | copies of the Software, and to permit persons to whom the Software is 9 | furnished to do so, subject to the following conditions: 10 | 11 | The above copyright notice and this permission notice shall be included in all 12 | copies or substantial portions of the Software. 13 | 14 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 20 | SOFTWARE. 21 | -------------------------------------------------------------------------------- /__tests__/advanced.js: -------------------------------------------------------------------------------- 1 | import React from 'react' 2 | import {mount} from 'enzyme' 3 | import Advanced from '../pages/advanced' 4 | 5 | test('renders', () => { 6 | expect(() => mount()).not.toThrow() 7 | }) 8 | -------------------------------------------------------------------------------- /__tests__/api.js: -------------------------------------------------------------------------------- 1 | import React from 'react' 2 | import {mount} from 'enzyme' 3 | import Api from '../pages/api' 4 | 5 | test('renders', () => { 6 | expect(() => mount()).not.toThrow() 7 | }) 8 | -------------------------------------------------------------------------------- /__tests__/basics.js: -------------------------------------------------------------------------------- 1 | import React from 'react' 2 | import {mount} from 'enzyme' 3 | import Basics from '../pages/basics' 4 | 5 | test('renders', () => { 6 | expect(() => mount()).not.toThrow() 7 | }) 8 | -------------------------------------------------------------------------------- /__tests__/examples.js: -------------------------------------------------------------------------------- 1 | import React from 'react' 2 | import {mount} from 'enzyme' 3 | import Examples from '../pages/examples' 4 | 5 | test('renders', () => { 6 | expect(() => mount()).not.toThrow() 7 | }) 8 | -------------------------------------------------------------------------------- /__tests__/index.js: -------------------------------------------------------------------------------- 1 | import React from 'react' 2 | import {mount} from 'enzyme' 3 | import Index from '../pages/index' 4 | 5 | test('renders', () => { 6 | expect(() => mount()).not.toThrow() 7 | }) 8 | -------------------------------------------------------------------------------- /__tests__/integrations.js: -------------------------------------------------------------------------------- 1 | import React from 'react' 2 | import {mount} from 'enzyme' 3 | import Integrations from '../pages/integrations' 4 | 5 | test('renders', () => { 6 | expect(() => mount()).not.toThrow() 7 | }) 8 | -------------------------------------------------------------------------------- /components/__tests__/__snapshots__/code-sandbox-embed.js.snap: -------------------------------------------------------------------------------- 1 | // Jest Snapshot v1, https://goo.gl/fbAQLP 2 | 3 | exports[`renders 1`] = ` 4 | 5 |