From 542d2f639d154924a35a7eea0fc8df651ced37ea Mon Sep 17 00:00:00 2001 From: Jon Rohan Date: Wed, 21 Feb 2018 11:28:19 -0800 Subject: [PATCH 01/97] First commit on a react-octicons component --- lib/react/LICENSE | 21 +++++++++++++++ lib/react/README.md | 60 ++++++++++++++++++++++++++++++++++++++++++ lib/react/index.js | 53 +++++++++++++++++++++++++++++++++++++ lib/react/package.json | 37 ++++++++++++++++++++++++++ 4 files changed, 171 insertions(+) create mode 100644 lib/react/LICENSE create mode 100644 lib/react/README.md create mode 100644 lib/react/index.js create mode 100644 lib/react/package.json diff --git a/lib/react/LICENSE b/lib/react/LICENSE new file mode 100644 index 000000000..9317777c6 --- /dev/null +++ b/lib/react/LICENSE @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2018 GitHub Inc. + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/lib/react/README.md b/lib/react/README.md new file mode 100644 index 000000000..1dca6098a --- /dev/null +++ b/lib/react/README.md @@ -0,0 +1,60 @@ +# GitHub Octicons React Component + +[![npm version](https://img.shields.io/npm/v/%40primer%2Freact-octicons.svg)](https://www.npmjs.org/package/%40primer%2Freact-octicons) +[![Build Status](https://travis-ci.org/primer/octicons.svg?branch=master)](https://travis-ci.org/primer/octicons) + +> A react component for installing octicons + +## Install + +``` +$ npm install @primer/react-octicons --save +``` + +## Usage + +The entire library will be available when importing `@primer/react-octicons`. Specifying the [icon you want to use][octicons], by supplying the `name=""` to the component. + +```js +// Example usage +import Octicon from "@primer/react-octicons" + +const AlertIcon = +``` + +##### ariaLabel + +You have the option to add accessibility information to the icon using `aria-label`. + +```js +// Example usage +import Octicon from "@primer/react-octicons" + +const PlusIcon = +``` + + +##### width & height + +You can change the dimensions of the icon by setting `width` and/or `height`. We recommended you supply **only the `height`**, because this will then calculate the appropriate width based on the viewBox size. + +```js +// Example usage +import Octicon from "@primer/react-octicons" + +const BiggestLogo = +``` + +## License + +(c) GitHub, Inc. + +When using the GitHub logos, be sure to follow the [GitHub logo guidelines](https://github.com/logos). + +[MIT](./LICENSE) + +[octicons]: https://octicons.github.com/ +[primer]: https://github.com/primer/primer +[docs]: http://primercss.io/ +[npm]: https://www.npmjs.com/ +[install-npm]: https://docs.npmjs.com/getting-started/installing-node diff --git a/lib/react/index.js b/lib/react/index.js new file mode 100644 index 000000000..afd6859cf --- /dev/null +++ b/lib/react/index.js @@ -0,0 +1,53 @@ +import React from 'react' +import octicons from 'octicons' + +export default class Octicon extends React.Component { + + prepareAttributes(octicon) { + const {height, width, ariaLabel} = this.props + + const attr = octicon.options + + // If any of the width or height is passed in + if(width || height) { + attr["width"] = width ? width : (parseInt(height) * octicon.options["width"] / octicon.options["height"]) + attr["height"] = height ? height : (parseInt(width) * octicon.options["height"] / octicon.options["width"]) + } + + // If the user passed in aria-label + if (ariaLabel) { + attr["aria-label"] = ariaLabel + attr["role"] = "img" + + // Un-hide the icon + delete attr["aria-hidden"] + } + + return attr + } + + render() { + const {name} = this.props + const octicon = octicons[name] + + if (octicon) { + const svgStyle = { + display: "inline-block", + fill: "currentColor", + verticalAlign: "text-bottom", + position: "relative", + userSelect: "none" + } + + return ( + + + ) + } else { + throw new Error(`No such octicon: "${name}"!`) + } + } +} diff --git a/lib/react/package.json b/lib/react/package.json new file mode 100644 index 000000000..8922bb9c1 --- /dev/null +++ b/lib/react/package.json @@ -0,0 +1,37 @@ +{ + "name": "@primer/react-octicons", + "version": "1.0.0", + "description": "A scalable set of icons handcrafted with <3 by GitHub.", + "homepage": "https://octicons.github.com", + "author": "GitHub Inc.", + "license": "MIT", + "main": "index.js", + "repository": "https://github.com/primer/octicons.git", + "bugs": { + "url": "https://github.com/primer/octicons/issues" + }, + "keywords": [ + "GitHub", + "icons", + "svg", + "octicons", + "react" + ], + "babel": { + "presets": [ + "env", + "react" + ] + }, + "peerDependencies": { + "react": ">=16.2.0" + }, + "dependencies": { + "octicons": "7.1.0", + "react": "^16.2.0" + }, + "devDependencies": { + "babel-preset-env": "^1.6.1", + "babel-preset-react": "^6.24.1" + } +} From 2cb57f78ae3e796c7f955fd91493299829936e03 Mon Sep 17 00:00:00 2001 From: Jon Rohan Date: Wed, 21 Feb 2018 11:46:47 -0800 Subject: [PATCH 02/97] Renaming for npmjs --- lib/react/README.md | 12 ++++++------ lib/react/package.json | 7 ++++--- 2 files changed, 10 insertions(+), 9 deletions(-) diff --git a/lib/react/README.md b/lib/react/README.md index 1dca6098a..12e9a25e0 100644 --- a/lib/react/README.md +++ b/lib/react/README.md @@ -8,16 +8,16 @@ ## Install ``` -$ npm install @primer/react-octicons --save +$ npm install @github/octicons-react --save ``` ## Usage -The entire library will be available when importing `@primer/react-octicons`. Specifying the [icon you want to use][octicons], by supplying the `name=""` to the component. +The entire library will be available when importing `@github/octicons-react`. Specifying the [icon you want to use][octicons], by supplying the `name=""` to the component. ```js // Example usage -import Octicon from "@primer/react-octicons" +import Octicon from "@github/octicons-react" const AlertIcon = ``` @@ -28,7 +28,7 @@ You have the option to add accessibility information to the icon using `aria-lab ```js // Example usage -import Octicon from "@primer/react-octicons" +import Octicon from "@github/octicons-react" const PlusIcon = ``` @@ -36,11 +36,11 @@ const PlusIcon = ##### width & height -You can change the dimensions of the icon by setting `width` and/or `height`. We recommended you supply **only the `height`**, because this will then calculate the appropriate width based on the viewBox size. +You can change the dimensions of the icon by setting `width` and/or `height`. We recommended you supply **only the height**, because this will then calculate the appropriate width based on the viewBox size. ```js // Example usage -import Octicon from "@primer/react-octicons" +import Octicon from "@github/octicons-react" const BiggestLogo = ``` diff --git a/lib/react/package.json b/lib/react/package.json index 8922bb9c1..f94fcac5e 100644 --- a/lib/react/package.json +++ b/lib/react/package.json @@ -1,6 +1,6 @@ { - "name": "@primer/react-octicons", - "version": "1.0.0", + "name": "@github/octicons-react", + "version": "1.1.0-alpha.542d2f63", "description": "A scalable set of icons handcrafted with <3 by GitHub.", "homepage": "https://octicons.github.com", "author": "GitHub Inc.", @@ -15,7 +15,8 @@ "icons", "svg", "octicons", - "react" + "react", + "primer" ], "babel": { "presets": [ From b5a9afd96c81fce171968f962f339c3e3fb93bab Mon Sep 17 00:00:00 2001 From: Jon Rohan Date: Wed, 21 Feb 2018 11:54:14 -0800 Subject: [PATCH 03/97] Updating sheild location --- lib/react/README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/react/README.md b/lib/react/README.md index 12e9a25e0..9c6f99435 100644 --- a/lib/react/README.md +++ b/lib/react/README.md @@ -1,6 +1,6 @@ # GitHub Octicons React Component -[![npm version](https://img.shields.io/npm/v/%40primer%2Freact-octicons.svg)](https://www.npmjs.org/package/%40primer%2Freact-octicons) +[![npm version](https://img.shields.io/npm/v/%40github%2Focticons-react.svg)](https://www.npmjs.org/package/%40github%2Focticons-react) [![Build Status](https://travis-ci.org/primer/octicons.svg?branch=master)](https://travis-ci.org/primer/octicons) > A react component for installing octicons From 0cccc4f7516de894aa3ec0fd36265162e05f69b6 Mon Sep 17 00:00:00 2001 From: Jon Rohan Date: Wed, 21 Feb 2018 14:52:18 -0800 Subject: [PATCH 04/97] remove clasee --- lib/react/index.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lib/react/index.js b/lib/react/index.js index afd6859cf..77aca87a2 100644 --- a/lib/react/index.js +++ b/lib/react/index.js @@ -8,6 +8,8 @@ export default class Octicon extends React.Component { const attr = octicon.options + delete attr["class"] + // If any of the width or height is passed in if(width || height) { attr["width"] = width ? width : (parseInt(height) * octicon.options["width"] / octicon.options["height"]) From a0d68d5d528d86fa5b5e27e4924a6a6f13ccd905 Mon Sep 17 00:00:00 2001 From: Jon Rohan Date: Wed, 21 Feb 2018 20:08:55 -0800 Subject: [PATCH 05/97] building babel dist --- .gitignore | 1 + lib/react/package.json | 9 +++++++-- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/.gitignore b/.gitignore index d1925b995..e6a8e0d79 100644 --- a/.gitignore +++ b/.gitignore @@ -8,3 +8,4 @@ lib/octicons_gem/lib/data.json *.lock .bundle vendor +lib/react/dist diff --git a/lib/react/package.json b/lib/react/package.json index f94fcac5e..4a0acedbd 100644 --- a/lib/react/package.json +++ b/lib/react/package.json @@ -1,12 +1,16 @@ { "name": "@github/octicons-react", - "version": "1.1.0-alpha.542d2f63", + "version": "0.1.0", "description": "A scalable set of icons handcrafted with <3 by GitHub.", "homepage": "https://octicons.github.com", "author": "GitHub Inc.", "license": "MIT", - "main": "index.js", + "main": "dist/index.js", "repository": "https://github.com/primer/octicons.git", + "scripts": { + "build": "$(npm bin)/babel index.js -d dist", + "prepare": "npm run build" + }, "bugs": { "url": "https://github.com/primer/octicons/issues" }, @@ -32,6 +36,7 @@ "react": "^16.2.0" }, "devDependencies": { + "babel-cli": "^6.26.0", "babel-preset-env": "^1.6.1", "babel-preset-react": "^6.24.1" } From d7728f2d5073b1f811b74b3c39745145a82d4f9c Mon Sep 17 00:00:00 2001 From: Jon Rohan Date: Wed, 21 Feb 2018 20:11:57 -0800 Subject: [PATCH 06/97] Outputting to build instead --- .gitignore | 1 - lib/react/package.json | 8 ++++++-- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/.gitignore b/.gitignore index e6a8e0d79..d1925b995 100644 --- a/.gitignore +++ b/.gitignore @@ -8,4 +8,3 @@ lib/octicons_gem/lib/data.json *.lock .bundle vendor -lib/react/dist diff --git a/lib/react/package.json b/lib/react/package.json index 4a0acedbd..0abfc8199 100644 --- a/lib/react/package.json +++ b/lib/react/package.json @@ -5,10 +5,14 @@ "homepage": "https://octicons.github.com", "author": "GitHub Inc.", "license": "MIT", - "main": "dist/index.js", + "main": "build/index.js", "repository": "https://github.com/primer/octicons.git", + "files": [ + "index.js", + "build" + ], "scripts": { - "build": "$(npm bin)/babel index.js -d dist", + "build": "$(npm bin)/babel index.js -d build", "prepare": "npm run build" }, "bugs": { From 36e3e4bc6868f7fc41ab0ee7bcb02c810ce4ba37 Mon Sep 17 00:00:00 2001 From: Jon Rohan Date: Wed, 21 Feb 2018 21:07:14 -0800 Subject: [PATCH 07/97] Setting up linting --- lib/react/.eslintrc.json | 3 +++ lib/react/index.js | 58 ++++++++++++++++++++++++++-------------- lib/react/package.json | 5 +++- package.json | 3 ++- 4 files changed, 47 insertions(+), 22 deletions(-) create mode 100644 lib/react/.eslintrc.json diff --git a/lib/react/.eslintrc.json b/lib/react/.eslintrc.json new file mode 100644 index 000000000..4dec427fb --- /dev/null +++ b/lib/react/.eslintrc.json @@ -0,0 +1,3 @@ +{ + "extends": ["plugin:github/es6", "plugin:github/react"] +} diff --git a/lib/react/index.js b/lib/react/index.js index 77aca87a2..586254cac 100644 --- a/lib/react/index.js +++ b/lib/react/index.js @@ -1,36 +1,53 @@ -import React from 'react' -import octicons from 'octicons' +import React from "react"; +import octicons from "octicons"; export default class Octicon extends React.Component { - prepareAttributes(octicon) { - const {height, width, ariaLabel} = this.props + const { width, ariaLabel } = this.props; + const attr = octicon.options; + let height = this.props.height; - const attr = octicon.options + // Delete class set by octicons library + delete attr["class"]; - delete attr["class"] + // Read in small, medium, large props + if (this.props.small) { + height = 16; + } else if (this.props.medium) { + height = 32; + } else if (this.props.large) { + height = 64; + } // If any of the width or height is passed in - if(width || height) { - attr["width"] = width ? width : (parseInt(height) * octicon.options["width"] / octicon.options["height"]) - attr["height"] = height ? height : (parseInt(width) * octicon.options["height"] / octicon.options["width"]) + if (width || height) { + attr["width"] = width + ? width + : parseInt(height) * + octicon.options["width"] / + octicon.options["height"]; + attr["height"] = height + ? height + : parseInt(width) * + octicon.options["height"] / + octicon.options["width"]; } // If the user passed in aria-label if (ariaLabel) { - attr["aria-label"] = ariaLabel - attr["role"] = "img" + attr["aria-label"] = ariaLabel; + attr["role"] = "img"; // Un-hide the icon - delete attr["aria-hidden"] + delete attr["aria-hidden"]; } - return attr + return attr; } render() { - const {name} = this.props - const octicon = octicons[name] + const { name } = this.props; + const octicon = octicons[name]; if (octicon) { const svgStyle = { @@ -39,17 +56,18 @@ export default class Octicon extends React.Component { verticalAlign: "text-bottom", position: "relative", userSelect: "none" - } + }; return ( - - ) + /* eslint-disable-next-line react/no-danger */ + dangerouslySetInnerHTML={{ __html: octicon.path }} + /> + ); } else { - throw new Error(`No such octicon: "${name}"!`) + throw new Error(`No such octicon: "${name}"!`); } } } diff --git a/lib/react/package.json b/lib/react/package.json index 0abfc8199..1e6c63dd8 100644 --- a/lib/react/package.json +++ b/lib/react/package.json @@ -12,6 +12,7 @@ "build" ], "scripts": { + "lint": "$(npm bin)/eslint index.js", "build": "$(npm bin)/babel index.js -d build", "prepare": "npm run build" }, @@ -42,6 +43,8 @@ "devDependencies": { "babel-cli": "^6.26.0", "babel-preset-env": "^1.6.1", - "babel-preset-react": "^6.24.1" + "babel-preset-react": "^6.24.1", + "eslint": "^4.18.1", + "eslint-plugin-github": "^0.23.0" } } diff --git a/package.json b/package.json index 5a68a161c..79d734fa9 100644 --- a/package.json +++ b/package.json @@ -2,7 +2,8 @@ "private": true, "scripts": { "bootstrap": "lerna bootstrap", - "test": "ava tests/*.js && lerna run test", + "lint": "$(npm bin)/lerna exec npm run lint", + "test": "npm run lint && ava tests/*.js && lerna run test", "precommit": "lint-staged", "alpha-release": "script/clean && $(npm bin)/lerna publish --npm-tag=alpha --canary --exact --skip-git", "release": "script/clean && $(npm bin)/lerna publish --exact --since \"v$(npm info octicons version)\"" From 581a4f218b1d16db7e331d8f0fe38db1df836a85 Mon Sep 17 00:00:00 2001 From: Jon Rohan Date: Wed, 21 Feb 2018 21:24:38 -0800 Subject: [PATCH 08/97] github-lint? --- lib/react/.eslintignore | 2 ++ lib/react/package.json | 4 ++-- 2 files changed, 4 insertions(+), 2 deletions(-) create mode 100644 lib/react/.eslintignore diff --git a/lib/react/.eslintignore b/lib/react/.eslintignore new file mode 100644 index 000000000..90e4079f1 --- /dev/null +++ b/lib/react/.eslintignore @@ -0,0 +1,2 @@ +build/ +*.json diff --git a/lib/react/package.json b/lib/react/package.json index 1e6c63dd8..826248da9 100644 --- a/lib/react/package.json +++ b/lib/react/package.json @@ -1,6 +1,6 @@ { "name": "@github/octicons-react", - "version": "0.1.0", + "version": "1.2.0", "description": "A scalable set of icons handcrafted with <3 by GitHub.", "homepage": "https://octicons.github.com", "author": "GitHub Inc.", @@ -12,7 +12,7 @@ "build" ], "scripts": { - "lint": "$(npm bin)/eslint index.js", + "lint": "$(npm bin)/github-lint", "build": "$(npm bin)/babel index.js -d build", "prepare": "npm run build" }, From 60d21a75c59abaf390667066f6191d4715e9806b Mon Sep 17 00:00:00 2001 From: Jon Rohan Date: Wed, 21 Feb 2018 21:26:02 -0800 Subject: [PATCH 09/97] 1.1.0 --- lib/react/package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/react/package.json b/lib/react/package.json index 826248da9..17a6074a8 100644 --- a/lib/react/package.json +++ b/lib/react/package.json @@ -1,6 +1,6 @@ { "name": "@github/octicons-react", - "version": "1.2.0", + "version": "1.0.0", "description": "A scalable set of icons handcrafted with <3 by GitHub.", "homepage": "https://octicons.github.com", "author": "GitHub Inc.", From 9d94633ba469ccc2e44e122554795692c97b4127 Mon Sep 17 00:00:00 2001 From: Jon Rohan Date: Wed, 21 Feb 2018 21:29:23 -0800 Subject: [PATCH 10/97] 1.1.0 --- lib/react/package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/react/package.json b/lib/react/package.json index 17a6074a8..e001bf80e 100644 --- a/lib/react/package.json +++ b/lib/react/package.json @@ -1,6 +1,6 @@ { "name": "@github/octicons-react", - "version": "1.0.0", + "version": "1.1.0", "description": "A scalable set of icons handcrafted with <3 by GitHub.", "homepage": "https://octicons.github.com", "author": "GitHub Inc.", From 8f120ac77836c609adda976551e05edee0bb4d9a Mon Sep 17 00:00:00 2001 From: Jon Rohan Date: Wed, 21 Feb 2018 21:55:09 -0800 Subject: [PATCH 11/97] Be explicit so that it's not mixed up with index.scss --- lib/react/index.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/react/index.js b/lib/react/index.js index 586254cac..6a09b0498 100644 --- a/lib/react/index.js +++ b/lib/react/index.js @@ -1,5 +1,5 @@ import React from "react"; -import octicons from "octicons"; +import octicons from "octicons/index.js"; export default class Octicon extends React.Component { prepareAttributes(octicon) { From 20170b645e0002aebac8a96da1514cab84047699 Mon Sep 17 00:00:00 2001 From: Jon Rohan Date: Fri, 23 Feb 2018 12:52:44 -0800 Subject: [PATCH 12/97] Making the sizing stricter --- lib/react/README.md | 12 +++++++++--- lib/react/index.js | 35 ++++++++++++----------------------- 2 files changed, 21 insertions(+), 26 deletions(-) diff --git a/lib/react/README.md b/lib/react/README.md index 9c6f99435..5aa3c3b48 100644 --- a/lib/react/README.md +++ b/lib/react/README.md @@ -34,15 +34,21 @@ const PlusIcon = ``` -##### width & height +##### Sizes -You can change the dimensions of the icon by setting `width` and/or `height`. We recommended you supply **only the height**, because this will then calculate the appropriate width based on the viewBox size. +The properties `large`, `medium`, `small` are available for setting the size of the icon. + +| Prop | Rendered Size | +| :- | :- | +| Small | 16px height by `computed` width | +| Medium | 32px height by `computed` width | +| Small | 64px height by `computed` width | ```js // Example usage import Octicon from "@github/octicons-react" -const BiggestLogo = +const BiggestLogo = ``` ## License diff --git a/lib/react/index.js b/lib/react/index.js index 6a09b0498..47a8d8447 100644 --- a/lib/react/index.js +++ b/lib/react/index.js @@ -1,37 +1,26 @@ import React from "react"; -import octicons from "octicons/index.js"; +import octicons from "octicons"; export default class Octicon extends React.Component { prepareAttributes(octicon) { - const { width, ariaLabel } = this.props; - const attr = octicon.options; - let height = this.props.height; + const { ariaLabel, medium, large } = this.props; + const attr = Object.assign({}, octicon.options); + // Default octicon sizes to small + attr["height"] = 16; // Delete class set by octicons library delete attr["class"]; // Read in small, medium, large props - if (this.props.small) { - height = 16; - } else if (this.props.medium) { - height = 32; - } else if (this.props.large) { - height = 64; + if (medium) { + attr["height"] = 32; + } else if (large) { + attr["height"] = 64; } - // If any of the width or height is passed in - if (width || height) { - attr["width"] = width - ? width - : parseInt(height) * - octicon.options["width"] / - octicon.options["height"]; - attr["height"] = height - ? height - : parseInt(width) * - octicon.options["height"] / - octicon.options["width"]; - } + // Calculate the width based on height + attr["width"] = + attr["height"] * octicon.options["width"] / octicon.options["height"]; // If the user passed in aria-label if (ariaLabel) { From 11933d88f49af5676bc164f1d6f4c3fa97817a1d Mon Sep 17 00:00:00 2001 From: Jon Rohan Date: Fri, 23 Feb 2018 13:06:23 -0800 Subject: [PATCH 13/97] Large --- lib/react/README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/react/README.md b/lib/react/README.md index 5aa3c3b48..9d95562c6 100644 --- a/lib/react/README.md +++ b/lib/react/README.md @@ -42,7 +42,7 @@ The properties `large`, `medium`, `small` are available for setting the size of | :- | :- | | Small | 16px height by `computed` width | | Medium | 32px height by `computed` width | -| Small | 64px height by `computed` width | +| Large | 64px height by `computed` width | ```js // Example usage From b41121ca64716250b12174e7fb50910d3ffca1c8 Mon Sep 17 00:00:00 2001 From: Jon Rohan Date: Fri, 23 Feb 2018 15:39:42 -0800 Subject: [PATCH 14/97] Adding alignment options --- lib/react/README.md | 38 +++++++++++++++++++++++++++++++++----- lib/react/index.js | 14 ++++++++++++-- 2 files changed, 45 insertions(+), 7 deletions(-) diff --git a/lib/react/README.md b/lib/react/README.md index 9d95562c6..739367ca5 100644 --- a/lib/react/README.md +++ b/lib/react/README.md @@ -19,10 +19,28 @@ The entire library will be available when importing `@github/octicons-react`. Sp // Example usage import Octicon from "@github/octicons-react" -const AlertIcon = +return ( + +) ``` -##### ariaLabel +### Alignment + +By default the octicons have `vertical-align: text-bottom;` applied to them. But there are cases where you'll want to change the alignment. The props available are `top`, `middle`. + +```js +// Example usage +import Octicon from "@github/octicons-react" + +return ( +

+ github/github +

+) +``` + + +### ariaLabel You have the option to add accessibility information to the icon using `aria-label`. @@ -30,11 +48,15 @@ You have the option to add accessibility information to the icon using `aria-lab // Example usage import Octicon from "@github/octicons-react" -const PlusIcon = +return ( + +) ``` -##### Sizes +### Sizes The properties `large`, `medium`, `small` are available for setting the size of the icon. @@ -48,7 +70,13 @@ The properties `large`, `medium`, `small` are available for setting the size of // Example usage import Octicon from "@github/octicons-react" -const BiggestLogo = +return ( +

+ + + +

+) ``` ## License diff --git a/lib/react/index.js b/lib/react/index.js index 47a8d8447..774f435a9 100644 --- a/lib/react/index.js +++ b/lib/react/index.js @@ -38,12 +38,22 @@ export default class Octicon extends React.Component { const { name } = this.props; const octicon = octicons[name]; + const alignment = props => { + const { top, middle } = props; + + if (top) { + return "text-top"; + } else if (middle) { + return "middle"; + } + return "text-bottom"; + }; + if (octicon) { const svgStyle = { display: "inline-block", fill: "currentColor", - verticalAlign: "text-bottom", - position: "relative", + verticalAlign: alignment(this.props), userSelect: "none" }; From ba46dc4e3d05983163f854a627840e7243f9b2eb Mon Sep 17 00:00:00 2001 From: Jon Rohan Date: Fri, 23 Mar 2018 22:06:55 -0700 Subject: [PATCH 15/97] Removing lint from test --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index 464c2a167..e01419742 100644 --- a/package.json +++ b/package.json @@ -2,7 +2,7 @@ "private": true, "scripts": { "lint": "$(npm bin)/lerna exec npm run lint", - "test": "npm run lint && ava tests/*.js && lerna run test", + "test": "ava tests/*.js && lerna run test", "bootstrap": "script/export && lerna bootstrap", "bump": "lerna publish --exact --skip-npm --since \"v$(npm info octicons version)\"" }, From c72f20be3545fad0298b92d60cb1fa73ae5fdbb4 Mon Sep 17 00:00:00 2001 From: Jon Rohan Date: Mon, 26 Mar 2018 14:12:42 -0700 Subject: [PATCH 16/97] Renaming --- README.md | 3 ++- lerna.json | 3 ++- lib/{jekyll-octicons => octicons_jekyll}/.npmignore | 0 lib/{jekyll-octicons => octicons_jekyll}/Gemfile | 0 lib/{jekyll-octicons => octicons_jekyll}/LICENSE | 0 lib/{jekyll-octicons => octicons_jekyll}/README.md | 0 lib/{jekyll-octicons => octicons_jekyll}/Rakefile | 0 .../jekyll-octicons.gemspec | 0 .../lib/jekyll-octicons.rb | 0 .../lib/jekyll-octicons/version.rb | 0 lib/{jekyll-octicons => octicons_jekyll}/package.json | 0 lib/{jekyll-octicons => octicons_jekyll}/test/helper.rb | 0 .../test/octicon_tag_test.rb | 0 lib/{react => octicons_react}/.eslintignore | 0 lib/{react => octicons_react}/.eslintrc.json | 0 lib/{react => octicons_react}/LICENSE | 0 lib/{react => octicons_react}/README.md | 0 lib/{react => octicons_react}/index.js | 0 lib/{react => octicons_react}/package.json | 0 19 files changed, 4 insertions(+), 2 deletions(-) rename lib/{jekyll-octicons => octicons_jekyll}/.npmignore (100%) rename lib/{jekyll-octicons => octicons_jekyll}/Gemfile (100%) rename lib/{jekyll-octicons => octicons_jekyll}/LICENSE (100%) rename lib/{jekyll-octicons => octicons_jekyll}/README.md (100%) rename lib/{jekyll-octicons => octicons_jekyll}/Rakefile (100%) rename lib/{jekyll-octicons => octicons_jekyll}/jekyll-octicons.gemspec (100%) rename lib/{jekyll-octicons => octicons_jekyll}/lib/jekyll-octicons.rb (100%) rename lib/{jekyll-octicons => octicons_jekyll}/lib/jekyll-octicons/version.rb (100%) rename lib/{jekyll-octicons => octicons_jekyll}/package.json (100%) rename lib/{jekyll-octicons => octicons_jekyll}/test/helper.rb (100%) rename lib/{jekyll-octicons => octicons_jekyll}/test/octicon_tag_test.rb (100%) rename lib/{react => octicons_react}/.eslintignore (100%) rename lib/{react => octicons_react}/.eslintrc.json (100%) rename lib/{react => octicons_react}/LICENSE (100%) rename lib/{react => octicons_react}/README.md (100%) rename lib/{react => octicons_react}/index.js (100%) rename lib/{react => octicons_react}/package.json (100%) diff --git a/README.md b/README.md index ff5853f06..6202c8719 100644 --- a/README.md +++ b/README.md @@ -21,6 +21,7 @@ The octicons node.js library is the main JavaScript library. With [a JavaScript | Package | Version | |---|---| | **[octicons](/lib/octicons_node)**
Node.js package with Javascript API | [![npm version](https://img.shields.io/npm/v/octicons.svg)](https://www.npmjs.org/package/octicons) | +| **[@github/octicons-react](/lib/octicons_react)**
React.js octicons components | [![npm version](https://img.shields.io/npm/v/%40github%2Focticons-react.svg)](https://www.npmjs.org/package/%40github%2Focticons-react) | ### Ruby @@ -28,7 +29,7 @@ The octicons node.js library is the main JavaScript library. With [a JavaScript |---|---| | **[octicons](/lib/octicons_gem)**
Ruby gem with Ruby API | [![Gem version](https://img.shields.io/gem/v/octicons.svg)](https://rubygems.org/gems/octicons) | | [octicons_helper](/lib/octicons_helper)
Rails helper for using octicons| [![Gem version](https://img.shields.io/gem/v/octicons_helper.svg)](https://rubygems.org/gems/octicons_helper) | -| [jekyll-octicons](/lib/jekyll-octicons)
Jekyll plugin for using octicons | [![Gem version](https://img.shields.io/gem/v/jekyll-octicons.svg)](https://rubygems.org/gems/jekyll-octicons) | +| [jekyll-octicons](/lib/octicons_jekyll)
Jekyll plugin for using octicons | [![Gem version](https://img.shields.io/gem/v/jekyll-octicons.svg)](https://rubygems.org/gems/jekyll-octicons) | ## License diff --git a/lerna.json b/lerna.json index 96f7cd1d8..88071d0c1 100644 --- a/lerna.json +++ b/lerna.json @@ -4,7 +4,8 @@ "lib/octicons_node", "lib/octicons_gem", "lib/octicons_helper", - "lib/jekyll-octicons" + "lib/octicons_jekyll", + "lib/octicons_react" ], "version": "independent" } diff --git a/lib/jekyll-octicons/.npmignore b/lib/octicons_jekyll/.npmignore similarity index 100% rename from lib/jekyll-octicons/.npmignore rename to lib/octicons_jekyll/.npmignore diff --git a/lib/jekyll-octicons/Gemfile b/lib/octicons_jekyll/Gemfile similarity index 100% rename from lib/jekyll-octicons/Gemfile rename to lib/octicons_jekyll/Gemfile diff --git a/lib/jekyll-octicons/LICENSE b/lib/octicons_jekyll/LICENSE similarity index 100% rename from lib/jekyll-octicons/LICENSE rename to lib/octicons_jekyll/LICENSE diff --git a/lib/jekyll-octicons/README.md b/lib/octicons_jekyll/README.md similarity index 100% rename from lib/jekyll-octicons/README.md rename to lib/octicons_jekyll/README.md diff --git a/lib/jekyll-octicons/Rakefile b/lib/octicons_jekyll/Rakefile similarity index 100% rename from lib/jekyll-octicons/Rakefile rename to lib/octicons_jekyll/Rakefile diff --git a/lib/jekyll-octicons/jekyll-octicons.gemspec b/lib/octicons_jekyll/jekyll-octicons.gemspec similarity index 100% rename from lib/jekyll-octicons/jekyll-octicons.gemspec rename to lib/octicons_jekyll/jekyll-octicons.gemspec diff --git a/lib/jekyll-octicons/lib/jekyll-octicons.rb b/lib/octicons_jekyll/lib/jekyll-octicons.rb similarity index 100% rename from lib/jekyll-octicons/lib/jekyll-octicons.rb rename to lib/octicons_jekyll/lib/jekyll-octicons.rb diff --git a/lib/jekyll-octicons/lib/jekyll-octicons/version.rb b/lib/octicons_jekyll/lib/jekyll-octicons/version.rb similarity index 100% rename from lib/jekyll-octicons/lib/jekyll-octicons/version.rb rename to lib/octicons_jekyll/lib/jekyll-octicons/version.rb diff --git a/lib/jekyll-octicons/package.json b/lib/octicons_jekyll/package.json similarity index 100% rename from lib/jekyll-octicons/package.json rename to lib/octicons_jekyll/package.json diff --git a/lib/jekyll-octicons/test/helper.rb b/lib/octicons_jekyll/test/helper.rb similarity index 100% rename from lib/jekyll-octicons/test/helper.rb rename to lib/octicons_jekyll/test/helper.rb diff --git a/lib/jekyll-octicons/test/octicon_tag_test.rb b/lib/octicons_jekyll/test/octicon_tag_test.rb similarity index 100% rename from lib/jekyll-octicons/test/octicon_tag_test.rb rename to lib/octicons_jekyll/test/octicon_tag_test.rb diff --git a/lib/react/.eslintignore b/lib/octicons_react/.eslintignore similarity index 100% rename from lib/react/.eslintignore rename to lib/octicons_react/.eslintignore diff --git a/lib/react/.eslintrc.json b/lib/octicons_react/.eslintrc.json similarity index 100% rename from lib/react/.eslintrc.json rename to lib/octicons_react/.eslintrc.json diff --git a/lib/react/LICENSE b/lib/octicons_react/LICENSE similarity index 100% rename from lib/react/LICENSE rename to lib/octicons_react/LICENSE diff --git a/lib/react/README.md b/lib/octicons_react/README.md similarity index 100% rename from lib/react/README.md rename to lib/octicons_react/README.md diff --git a/lib/react/index.js b/lib/octicons_react/index.js similarity index 100% rename from lib/react/index.js rename to lib/octicons_react/index.js diff --git a/lib/react/package.json b/lib/octicons_react/package.json similarity index 100% rename from lib/react/package.json rename to lib/octicons_react/package.json From a8a7a071682dd7b957f00df804a568bd8b68de29 Mon Sep 17 00:00:00 2001 From: Jon Rohan Date: Mon, 26 Mar 2018 19:57:32 -0700 Subject: [PATCH 17/97] Updating react package to build components --- lib/octicons_react/.eslintrc.json | 3 - lib/octicons_react/README.md | 23 +++-- lib/octicons_react/index.js | 72 ------------- lib/octicons_react/package.json | 13 +-- lib/octicons_react/script/build.js | 158 +++++++++++++++++++++++++++++ 5 files changed, 180 insertions(+), 89 deletions(-) delete mode 100644 lib/octicons_react/.eslintrc.json delete mode 100644 lib/octicons_react/index.js create mode 100644 lib/octicons_react/script/build.js diff --git a/lib/octicons_react/.eslintrc.json b/lib/octicons_react/.eslintrc.json deleted file mode 100644 index 4dec427fb..000000000 --- a/lib/octicons_react/.eslintrc.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "extends": ["plugin:github/es6", "plugin:github/react"] -} diff --git a/lib/octicons_react/README.md b/lib/octicons_react/README.md index 739367ca5..df48a9e45 100644 --- a/lib/octicons_react/README.md +++ b/lib/octicons_react/README.md @@ -24,17 +24,28 @@ return ( ) ``` +You can also import only the icons you need by importing the specific icon names. This is useful if you’re trying to keep bundle size down. + +```js +// Example usage +import { AlertOcticon, RepoOcticon, XOcticon } from "@github/octicons-react" + +return ( + +) +``` + ### Alignment By default the octicons have `vertical-align: text-bottom;` applied to them. But there are cases where you'll want to change the alignment. The props available are `top`, `middle`. ```js // Example usage -import Octicon from "@github/octicons-react" +import { RepoOcticon } from "@github/octicons-react" return (

- github/github + github/github

) ``` @@ -46,11 +57,11 @@ You have the option to add accessibility information to the icon using `aria-lab ```js // Example usage -import Octicon from "@github/octicons-react" +import { PlusOcticon } from "@github/octicons-react" return ( ) ``` @@ -68,12 +79,12 @@ The properties `large`, `medium`, `small` are available for setting the size of ```js // Example usage -import Octicon from "@github/octicons-react" +import { LogoGithubOcticon } from "@github/octicons-react" return (

- +

) diff --git a/lib/octicons_react/index.js b/lib/octicons_react/index.js deleted file mode 100644 index 774f435a9..000000000 --- a/lib/octicons_react/index.js +++ /dev/null @@ -1,72 +0,0 @@ -import React from "react"; -import octicons from "octicons"; - -export default class Octicon extends React.Component { - prepareAttributes(octicon) { - const { ariaLabel, medium, large } = this.props; - const attr = Object.assign({}, octicon.options); - // Default octicon sizes to small - attr["height"] = 16; - - // Delete class set by octicons library - delete attr["class"]; - - // Read in small, medium, large props - if (medium) { - attr["height"] = 32; - } else if (large) { - attr["height"] = 64; - } - - // Calculate the width based on height - attr["width"] = - attr["height"] * octicon.options["width"] / octicon.options["height"]; - - // If the user passed in aria-label - if (ariaLabel) { - attr["aria-label"] = ariaLabel; - attr["role"] = "img"; - - // Un-hide the icon - delete attr["aria-hidden"]; - } - - return attr; - } - - render() { - const { name } = this.props; - const octicon = octicons[name]; - - const alignment = props => { - const { top, middle } = props; - - if (top) { - return "text-top"; - } else if (middle) { - return "middle"; - } - return "text-bottom"; - }; - - if (octicon) { - const svgStyle = { - display: "inline-block", - fill: "currentColor", - verticalAlign: alignment(this.props), - userSelect: "none" - }; - - return ( - - ); - } else { - throw new Error(`No such octicon: "${name}"!`); - } - } -} diff --git a/lib/octicons_react/package.json b/lib/octicons_react/package.json index e001bf80e..46ac8791a 100644 --- a/lib/octicons_react/package.json +++ b/lib/octicons_react/package.json @@ -13,8 +13,9 @@ ], "scripts": { "lint": "$(npm bin)/github-lint", - "build": "$(npm bin)/babel index.js -d build", - "prepare": "npm run build" + "publish": "../../script/notify success", + "prepublishOnly": "../../script/notify pending", + "prepare": "node script/build.js" }, "bugs": { "url": "https://github.com/primer/octicons/issues" @@ -36,15 +37,11 @@ "peerDependencies": { "react": ">=16.2.0" }, - "dependencies": { - "octicons": "7.1.0", - "react": "^16.2.0" - }, "devDependencies": { "babel-cli": "^6.26.0", "babel-preset-env": "^1.6.1", "babel-preset-react": "^6.24.1", - "eslint": "^4.18.1", - "eslint-plugin-github": "^0.23.0" + "lodash": "^4.17.5", + "octicons": "7.2.0" } } diff --git a/lib/octicons_react/script/build.js b/lib/octicons_react/script/build.js new file mode 100644 index 000000000..a65c19281 --- /dev/null +++ b/lib/octicons_react/script/build.js @@ -0,0 +1,158 @@ +'use strict'; + +const transform = require('babel-core').transform; +const octicons = require('octicons'); +const fs = require('fs-extra'); +const path = require('path'); +const lodash = require('lodash') + +const BUILD_PATH = path.join(__dirname, '..', 'build'); + +fs.emptyDirSync(BUILD_PATH) + +// Transform code to ES5 +const getTransformedSourceCode = (originalSource) => transform(originalSource, { + presets: [ 'env', 'react' ] +}).code; + +/** + * Template: React components + */ +const getReactSource = ({ componentName, options, svgPaths }) => { + let m = [] + while ((m = /\s([a-z]*\-[a-z]*)=/gi.exec(svgPaths)) != null) { + let mat = m.pop() + svgPaths = svgPaths.replace(mat, lodash.camelCase(mat)) + } + return getTransformedSourceCode(` +import createIconComponent from '../utils/createIconComponent'; +import React from 'react'; +const ${componentName} = createIconComponent({ content: ${svgPaths}, options: ${options} }); +${componentName}.displayName = '${componentName}'; +export default ${componentName}; +`); +} + +/** + * Template: createIconComponent + */ +const getCreateIconSource = () => getTransformedSourceCode(` +import React from "react"; + +const createIconComponent = ({ content, options }) => { + + const prepare = props => { + const { ariaLabel, medium, large } = props; + const attributes = Object.assign({}, options) + + // Default octicon sizes to small + attributes["height"] = 16; + + // Read in small, medium, large props + if (medium) { + attributes["height"] = 32; + } else if (large) { + attributes["height"] = 64; + } + + // Calculate the width based on height + attributes["width"] = + attributes["height"] * options["width"] / options["height"]; + + // If the user passed in aria-label + if (ariaLabel) { + attributes["aria-label"] = ariaLabel; + attributes["role"] = "img"; + + // Un-hide the icon + delete attributes["aria-hidden"]; + } + + return attributes; + }; + + const alignment = props => { + const { top, middle } = props; + + if (top) { + return "text-top"; + } else if (middle) { + return "middle"; + } + return "text-bottom"; + }; + + return (props) => { + const svgStyle = { + display: "inline-block", + fill: "currentColor", + verticalAlign: alignment(props), + userSelect: "none" + }; + + return ( + + {content} + + ) + } +} + +export default createIconComponent; +`); + +/** + * Template: createIconComponent + */ +const getIconIndexSource = () => { + const icons = Object.values(octicons).map((octicon) => { + const { name } = octicon; + const componentName = `${lodash.upperFirst(lodash.camelCase(name))}Octicon`; + return `export const ${componentName} = require('./icons/${name}.js').default; + octicons['${name}'] = ${componentName};` + }) + return getTransformedSourceCode(` + import React from 'react'; + let octicons = {} + ${icons.join('\n')} + export default class Octicon extends React.Component { + render() { + const { name } = this.props; + const Octicon = octicons[name]; + if (Octicon) { + return ( + + ) + } else { + throw new Error('No such octicon: "' + name + '!'); + } + } + } + `) +} + +const files = Object.values(octicons).map((octicon) => { + const { name, options, path } = octicon; + const componentName = `${lodash.upperFirst(lodash.camelCase(name))}Octicon`; + delete options["class"]; + return { + filepath: `icons/${name}.js`, + source: getReactSource({componentName: componentName, options: JSON.stringify(options), svgPaths: path}) + } +}) + +files.push({ + filepath: 'utils/createIconComponent.js', + source: getCreateIconSource() +}) + +files.push({ + filepath: 'index.js', + source: getIconIndexSource() +}) + +files.forEach((file) => { + fs.outputFile(path.join(BUILD_PATH, file.filepath), file.source); +}) From 571e21904af1dfafae1c3be1799fb4e401e5e794 Mon Sep 17 00:00:00 2001 From: Jon Rohan Date: Mon, 26 Mar 2018 20:39:43 -0700 Subject: [PATCH 18/97] Revert package.json --- package.json | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/package.json b/package.json index e01419742..484963739 100644 --- a/package.json +++ b/package.json @@ -1,9 +1,8 @@ { "private": true, "scripts": { - "lint": "$(npm bin)/lerna exec npm run lint", - "test": "ava tests/*.js && lerna run test", "bootstrap": "script/export && lerna bootstrap", + "test": "ava tests/*.js && lerna run test", "bump": "lerna publish --exact --skip-npm --since \"v$(npm info octicons version)\"" }, "figma": { From 1b305381bfbd4897089a3b3569b7ef7b0ace0b95 Mon Sep 17 00:00:00 2001 From: Jon Rohan Date: Mon, 26 Mar 2018 20:41:34 -0700 Subject: [PATCH 19/97] Cleaning lint --- lib/octicons_react/.eslintignore | 2 -- lib/octicons_react/package.json | 1 - 2 files changed, 3 deletions(-) delete mode 100644 lib/octicons_react/.eslintignore diff --git a/lib/octicons_react/.eslintignore b/lib/octicons_react/.eslintignore deleted file mode 100644 index 90e4079f1..000000000 --- a/lib/octicons_react/.eslintignore +++ /dev/null @@ -1,2 +0,0 @@ -build/ -*.json diff --git a/lib/octicons_react/package.json b/lib/octicons_react/package.json index 46ac8791a..6790f612b 100644 --- a/lib/octicons_react/package.json +++ b/lib/octicons_react/package.json @@ -12,7 +12,6 @@ "build" ], "scripts": { - "lint": "$(npm bin)/github-lint", "publish": "../../script/notify success", "prepublishOnly": "../../script/notify pending", "prepare": "node script/build.js" From d2e5c241131117f6445c13c3f9f2ef683ef4c3f9 Mon Sep 17 00:00:00 2001 From: Jon Rohan Date: Mon, 26 Mar 2018 20:45:58 -0700 Subject: [PATCH 20/97] Don't need this in files --- lib/octicons_react/package.json | 1 - 1 file changed, 1 deletion(-) diff --git a/lib/octicons_react/package.json b/lib/octicons_react/package.json index 6790f612b..f626dbbc5 100644 --- a/lib/octicons_react/package.json +++ b/lib/octicons_react/package.json @@ -8,7 +8,6 @@ "main": "build/index.js", "repository": "https://github.com/primer/octicons.git", "files": [ - "index.js", "build" ], "scripts": { From f962884f3b4c7cf32b54ee96352a3bf54a314205 Mon Sep 17 00:00:00 2001 From: Jon Rohan Date: Tue, 27 Mar 2018 14:17:58 -0700 Subject: [PATCH 21/97] Importing separately for all vs specific octicons --- .gitignore | 1 + lib/octicons_react/README.md | 14 +++++++------- lib/octicons_react/script/build.js | 30 +++++++++++++++++++++++------- 3 files changed, 31 insertions(+), 14 deletions(-) diff --git a/.gitignore b/.gitignore index 645bdafc2..de8166bc7 100644 --- a/.gitignore +++ b/.gitignore @@ -11,3 +11,4 @@ vendor # Ignore build/export artifacts build/ lib/octicons_gem/lib/data.json +lib/octicons_react/named.js diff --git a/lib/octicons_react/README.md b/lib/octicons_react/README.md index df48a9e45..c93b34ba0 100644 --- a/lib/octicons_react/README.md +++ b/lib/octicons_react/README.md @@ -28,7 +28,7 @@ You can also import only the icons you need by importing the specific icon names ```js // Example usage -import { AlertOcticon, RepoOcticon, XOcticon } from "@github/octicons-react" +import { AlertOcticon, RepoOcticon, XOcticon } from "@github/octicons-react/named" return ( @@ -41,11 +41,11 @@ By default the octicons have `vertical-align: text-bottom;` applied to them. But ```js // Example usage -import { RepoOcticon } from "@github/octicons-react" +import Octicon from "@github/octicons-react" return (

- github/github + github/github

) ``` @@ -57,11 +57,11 @@ You have the option to add accessibility information to the icon using `aria-lab ```js // Example usage -import { PlusOcticon } from "@github/octicons-react" +import Octicon from "@github/octicons-react" return ( ) ``` @@ -79,12 +79,12 @@ The properties `large`, `medium`, `small` are available for setting the size of ```js // Example usage -import { LogoGithubOcticon } from "@github/octicons-react" +import Octicon from "@github/octicons-react" return (

- +

) diff --git a/lib/octicons_react/script/build.js b/lib/octicons_react/script/build.js index a65c19281..f71e59bca 100644 --- a/lib/octicons_react/script/build.js +++ b/lib/octicons_react/script/build.js @@ -10,7 +10,7 @@ const BUILD_PATH = path.join(__dirname, '..', 'build'); fs.emptyDirSync(BUILD_PATH) -// Transform code to ES5 +// Transform code with babel const getTransformedSourceCode = (originalSource) => transform(originalSource, { presets: [ 'env', 'react' ] }).code; @@ -104,18 +104,29 @@ export default createIconComponent; `); /** - * Template: createIconComponent + * Template: getIconNamedSource + */ +const getIconNamedSource = () => { + return getTransformedSourceCode(Object.values(octicons).map((octicon) => { + const { name } = octicon; + const componentName = `${lodash.upperFirst(lodash.camelCase(name))}Octicon`; + return `export const ${componentName} = require('./build/icons/${name}.js').default;` + }).join('\n') + + `export default "Error: To import all octicons, try require('@github/octicons-react')"`) +} + +/** + * Template: getPackageIndexSource */ -const getIconIndexSource = () => { +const getPackageIndexSource = () => { const icons = Object.values(octicons).map((octicon) => { const { name } = octicon; const componentName = `${lodash.upperFirst(lodash.camelCase(name))}Octicon`; - return `export const ${componentName} = require('./icons/${name}.js').default; - octicons['${name}'] = ${componentName};` + return `octicons['${name}'] = require('./icons/${name}.js').default;` }) return getTransformedSourceCode(` import React from 'react'; - let octicons = {} + let octicons = {}; ${icons.join('\n')} export default class Octicon extends React.Component { render() { @@ -150,7 +161,12 @@ files.push({ files.push({ filepath: 'index.js', - source: getIconIndexSource() + source: getPackageIndexSource() +}) + +files.push({ + filepath: '../named.js', + source: getIconNamedSource() }) files.forEach((file) => { From f0b872f7eb2206d63a93e5bda3c233de0d839642 Mon Sep 17 00:00:00 2001 From: Jon Rohan Date: Tue, 27 Mar 2018 14:32:43 -0700 Subject: [PATCH 22/97] Adding named.js to the package files --- lib/octicons_react/package.json | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/octicons_react/package.json b/lib/octicons_react/package.json index f626dbbc5..c5c8f5250 100644 --- a/lib/octicons_react/package.json +++ b/lib/octicons_react/package.json @@ -8,7 +8,8 @@ "main": "build/index.js", "repository": "https://github.com/primer/octicons.git", "files": [ - "build" + "build", + "named.js" ], "scripts": { "publish": "../../script/notify success", From cfdb19fb274ea2d61efb0ad8e2ddf5c7baf6877b Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Fri, 8 Jun 2018 11:39:55 -0700 Subject: [PATCH 23/97] slimmer icons, bulkier --- lib/octicons_react/icons/alert.js | 5 + lib/octicons_react/icons/arrow-down.js | 5 + lib/octicons_react/icons/arrow-left.js | 5 + lib/octicons_react/icons/arrow-right.js | 5 + lib/octicons_react/icons/arrow-small-down.js | 5 + lib/octicons_react/icons/arrow-small-left.js | 5 + lib/octicons_react/icons/arrow-small-right.js | 5 + lib/octicons_react/icons/arrow-small-up.js | 5 + lib/octicons_react/icons/arrow-up.js | 5 + lib/octicons_react/icons/beaker.js | 5 + lib/octicons_react/icons/bell.js | 5 + lib/octicons_react/icons/bold.js | 5 + lib/octicons_react/icons/book.js | 5 + lib/octicons_react/icons/bookmark.js | 5 + lib/octicons_react/icons/briefcase.js | 5 + lib/octicons_react/icons/broadcast.js | 5 + lib/octicons_react/icons/browser.js | 5 + lib/octicons_react/icons/bug.js | 5 + lib/octicons_react/icons/calendar.js | 5 + lib/octicons_react/icons/check.js | 5 + lib/octicons_react/icons/checklist.js | 5 + lib/octicons_react/icons/chevron-down.js | 5 + lib/octicons_react/icons/chevron-left.js | 5 + lib/octicons_react/icons/chevron-right.js | 5 + lib/octicons_react/icons/chevron-up.js | 5 + lib/octicons_react/icons/circle-slash.js | 5 + lib/octicons_react/icons/circuit-board.js | 5 + lib/octicons_react/icons/clippy.js | 5 + lib/octicons_react/icons/clock.js | 5 + lib/octicons_react/icons/cloud-download.js | 5 + lib/octicons_react/icons/cloud-upload.js | 5 + lib/octicons_react/icons/code.js | 5 + .../icons/comment-discussion.js | 5 + lib/octicons_react/icons/comment.js | 5 + lib/octicons_react/icons/credit-card.js | 5 + lib/octicons_react/icons/dash.js | 5 + lib/octicons_react/icons/dashboard.js | 5 + lib/octicons_react/icons/database.js | 5 + lib/octicons_react/icons/desktop-download.js | 5 + .../icons/device-camera-video.js | 5 + lib/octicons_react/icons/device-camera.js | 5 + lib/octicons_react/icons/device-desktop.js | 5 + lib/octicons_react/icons/device-mobile.js | 5 + lib/octicons_react/icons/diff-added.js | 5 + lib/octicons_react/icons/diff-ignored.js | 5 + lib/octicons_react/icons/diff-modified.js | 5 + lib/octicons_react/icons/diff-removed.js | 5 + lib/octicons_react/icons/diff-renamed.js | 5 + lib/octicons_react/icons/diff.js | 5 + lib/octicons_react/icons/ellipsis.js | 5 + lib/octicons_react/icons/eye.js | 5 + lib/octicons_react/icons/file-binary.js | 5 + lib/octicons_react/icons/file-code.js | 5 + lib/octicons_react/icons/file-directory.js | 5 + lib/octicons_react/icons/file-media.js | 5 + lib/octicons_react/icons/file-pdf.js | 5 + lib/octicons_react/icons/file-submodule.js | 5 + .../icons/file-symlink-directory.js | 5 + lib/octicons_react/icons/file-symlink-file.js | 5 + lib/octicons_react/icons/file-zip.js | 5 + lib/octicons_react/icons/file.js | 5 + lib/octicons_react/icons/flame.js | 5 + lib/octicons_react/icons/fold.js | 5 + lib/octicons_react/icons/gear.js | 5 + lib/octicons_react/icons/gift.js | 5 + lib/octicons_react/icons/gist-secret.js | 5 + lib/octicons_react/icons/gist.js | 5 + lib/octicons_react/icons/git-branch.js | 5 + lib/octicons_react/icons/git-commit.js | 5 + lib/octicons_react/icons/git-compare.js | 5 + lib/octicons_react/icons/git-merge.js | 5 + lib/octicons_react/icons/git-pull-request.js | 5 + lib/octicons_react/icons/globe.js | 5 + lib/octicons_react/icons/grabber.js | 5 + lib/octicons_react/icons/graph.js | 5 + lib/octicons_react/icons/heart.js | 5 + lib/octicons_react/icons/history.js | 5 + lib/octicons_react/icons/home.js | 5 + lib/octicons_react/icons/horizontal-rule.js | 5 + lib/octicons_react/icons/hubot.js | 5 + lib/octicons_react/icons/inbox.js | 5 + lib/octicons_react/icons/info.js | 5 + lib/octicons_react/icons/issue-closed.js | 5 + lib/octicons_react/icons/issue-opened.js | 5 + lib/octicons_react/icons/issue-reopened.js | 5 + lib/octicons_react/icons/italic.js | 5 + lib/octicons_react/icons/jersey.js | 5 + lib/octicons_react/icons/kebab-horizontal.js | 5 + lib/octicons_react/icons/kebab-vertical.js | 5 + lib/octicons_react/icons/key.js | 5 + lib/octicons_react/icons/keyboard.js | 5 + lib/octicons_react/icons/law.js | 5 + lib/octicons_react/icons/light-bulb.js | 5 + lib/octicons_react/icons/link-external.js | 5 + lib/octicons_react/icons/link.js | 5 + lib/octicons_react/icons/list-ordered.js | 5 + lib/octicons_react/icons/list-unordered.js | 5 + lib/octicons_react/icons/location.js | 5 + lib/octicons_react/icons/lock.js | 5 + lib/octicons_react/icons/logo-gist.js | 5 + lib/octicons_react/icons/logo-github.js | 5 + lib/octicons_react/icons/mail-read.js | 5 + lib/octicons_react/icons/mail.js | 5 + lib/octicons_react/icons/mark-github.js | 5 + lib/octicons_react/icons/markdown.js | 5 + lib/octicons_react/icons/megaphone.js | 5 + lib/octicons_react/icons/mention.js | 5 + lib/octicons_react/icons/milestone.js | 5 + lib/octicons_react/icons/mirror.js | 5 + lib/octicons_react/icons/mortar-board.js | 5 + lib/octicons_react/icons/mute.js | 5 + lib/octicons_react/icons/no-newline.js | 5 + lib/octicons_react/icons/note.js | 5 + lib/octicons_react/icons/octoface.js | 5 + lib/octicons_react/icons/organization.js | 5 + lib/octicons_react/icons/package.js | 5 + lib/octicons_react/icons/paintcan.js | 5 + lib/octicons_react/icons/pencil.js | 5 + lib/octicons_react/icons/person.js | 5 + lib/octicons_react/icons/pin.js | 5 + lib/octicons_react/icons/plug.js | 5 + lib/octicons_react/icons/plus-small.js | 5 + lib/octicons_react/icons/plus.js | 5 + lib/octicons_react/icons/primitive-dot.js | 5 + lib/octicons_react/icons/primitive-square.js | 5 + lib/octicons_react/icons/project.js | 5 + lib/octicons_react/icons/pulse.js | 5 + lib/octicons_react/icons/question.js | 5 + lib/octicons_react/icons/quote.js | 5 + lib/octicons_react/icons/radio-tower.js | 5 + lib/octicons_react/icons/reply.js | 5 + lib/octicons_react/icons/repo-clone.js | 5 + lib/octicons_react/icons/repo-force-push.js | 5 + lib/octicons_react/icons/repo-forked.js | 5 + lib/octicons_react/icons/repo-pull.js | 5 + lib/octicons_react/icons/repo-push.js | 5 + lib/octicons_react/icons/repo.js | 5 + lib/octicons_react/icons/report.js | 5 + lib/octicons_react/icons/rocket.js | 5 + lib/octicons_react/icons/rss.js | 5 + lib/octicons_react/icons/ruby.js | 5 + lib/octicons_react/icons/screen-full.js | 5 + lib/octicons_react/icons/screen-normal.js | 5 + lib/octicons_react/icons/search.js | 5 + lib/octicons_react/icons/server.js | 5 + lib/octicons_react/icons/settings.js | 5 + lib/octicons_react/icons/shield.js | 5 + lib/octicons_react/icons/sign-in.js | 5 + lib/octicons_react/icons/sign-out.js | 5 + lib/octicons_react/icons/smiley.js | 5 + lib/octicons_react/icons/squirrel.js | 5 + lib/octicons_react/icons/star.js | 5 + lib/octicons_react/icons/stop.js | 5 + lib/octicons_react/icons/sync.js | 5 + lib/octicons_react/icons/tag.js | 5 + lib/octicons_react/icons/tasklist.js | 5 + lib/octicons_react/icons/telescope.js | 5 + lib/octicons_react/icons/terminal.js | 5 + lib/octicons_react/icons/text-size.js | 5 + lib/octicons_react/icons/three-bars.js | 5 + lib/octicons_react/icons/thumbsdown.js | 5 + lib/octicons_react/icons/thumbsup.js | 5 + lib/octicons_react/icons/tools.js | 5 + lib/octicons_react/icons/trashcan.js | 5 + lib/octicons_react/icons/triangle-down.js | 5 + lib/octicons_react/icons/triangle-left.js | 5 + lib/octicons_react/icons/triangle-right.js | 5 + lib/octicons_react/icons/triangle-up.js | 5 + lib/octicons_react/icons/unfold.js | 5 + lib/octicons_react/icons/unmute.js | 5 + lib/octicons_react/icons/unverified.js | 5 + lib/octicons_react/icons/verified.js | 5 + lib/octicons_react/icons/versions.js | 5 + lib/octicons_react/icons/watch.js | 5 + lib/octicons_react/icons/x.js | 5 + lib/octicons_react/icons/zap.js | 5 + lib/octicons_react/index.js | 60 ++++++ lib/octicons_react/package.json | 10 +- lib/octicons_react/script/build.js | 188 +++--------------- 179 files changed, 970 insertions(+), 168 deletions(-) create mode 100644 lib/octicons_react/icons/alert.js create mode 100644 lib/octicons_react/icons/arrow-down.js create mode 100644 lib/octicons_react/icons/arrow-left.js create mode 100644 lib/octicons_react/icons/arrow-right.js create mode 100644 lib/octicons_react/icons/arrow-small-down.js create mode 100644 lib/octicons_react/icons/arrow-small-left.js create mode 100644 lib/octicons_react/icons/arrow-small-right.js create mode 100644 lib/octicons_react/icons/arrow-small-up.js create mode 100644 lib/octicons_react/icons/arrow-up.js create mode 100644 lib/octicons_react/icons/beaker.js create mode 100644 lib/octicons_react/icons/bell.js create mode 100644 lib/octicons_react/icons/bold.js create mode 100644 lib/octicons_react/icons/book.js create mode 100644 lib/octicons_react/icons/bookmark.js create mode 100644 lib/octicons_react/icons/briefcase.js create mode 100644 lib/octicons_react/icons/broadcast.js create mode 100644 lib/octicons_react/icons/browser.js create mode 100644 lib/octicons_react/icons/bug.js create mode 100644 lib/octicons_react/icons/calendar.js create mode 100644 lib/octicons_react/icons/check.js create mode 100644 lib/octicons_react/icons/checklist.js create mode 100644 lib/octicons_react/icons/chevron-down.js create mode 100644 lib/octicons_react/icons/chevron-left.js create mode 100644 lib/octicons_react/icons/chevron-right.js create mode 100644 lib/octicons_react/icons/chevron-up.js create mode 100644 lib/octicons_react/icons/circle-slash.js create mode 100644 lib/octicons_react/icons/circuit-board.js create mode 100644 lib/octicons_react/icons/clippy.js create mode 100644 lib/octicons_react/icons/clock.js create mode 100644 lib/octicons_react/icons/cloud-download.js create mode 100644 lib/octicons_react/icons/cloud-upload.js create mode 100644 lib/octicons_react/icons/code.js create mode 100644 lib/octicons_react/icons/comment-discussion.js create mode 100644 lib/octicons_react/icons/comment.js create mode 100644 lib/octicons_react/icons/credit-card.js create mode 100644 lib/octicons_react/icons/dash.js create mode 100644 lib/octicons_react/icons/dashboard.js create mode 100644 lib/octicons_react/icons/database.js create mode 100644 lib/octicons_react/icons/desktop-download.js create mode 100644 lib/octicons_react/icons/device-camera-video.js create mode 100644 lib/octicons_react/icons/device-camera.js create mode 100644 lib/octicons_react/icons/device-desktop.js create mode 100644 lib/octicons_react/icons/device-mobile.js create mode 100644 lib/octicons_react/icons/diff-added.js create mode 100644 lib/octicons_react/icons/diff-ignored.js create mode 100644 lib/octicons_react/icons/diff-modified.js create mode 100644 lib/octicons_react/icons/diff-removed.js create mode 100644 lib/octicons_react/icons/diff-renamed.js create mode 100644 lib/octicons_react/icons/diff.js create mode 100644 lib/octicons_react/icons/ellipsis.js create mode 100644 lib/octicons_react/icons/eye.js create mode 100644 lib/octicons_react/icons/file-binary.js create mode 100644 lib/octicons_react/icons/file-code.js create mode 100644 lib/octicons_react/icons/file-directory.js create mode 100644 lib/octicons_react/icons/file-media.js create mode 100644 lib/octicons_react/icons/file-pdf.js create mode 100644 lib/octicons_react/icons/file-submodule.js create mode 100644 lib/octicons_react/icons/file-symlink-directory.js create mode 100644 lib/octicons_react/icons/file-symlink-file.js create mode 100644 lib/octicons_react/icons/file-zip.js create mode 100644 lib/octicons_react/icons/file.js create mode 100644 lib/octicons_react/icons/flame.js create mode 100644 lib/octicons_react/icons/fold.js create mode 100644 lib/octicons_react/icons/gear.js create mode 100644 lib/octicons_react/icons/gift.js create mode 100644 lib/octicons_react/icons/gist-secret.js create mode 100644 lib/octicons_react/icons/gist.js create mode 100644 lib/octicons_react/icons/git-branch.js create mode 100644 lib/octicons_react/icons/git-commit.js create mode 100644 lib/octicons_react/icons/git-compare.js create mode 100644 lib/octicons_react/icons/git-merge.js create mode 100644 lib/octicons_react/icons/git-pull-request.js create mode 100644 lib/octicons_react/icons/globe.js create mode 100644 lib/octicons_react/icons/grabber.js create mode 100644 lib/octicons_react/icons/graph.js create mode 100644 lib/octicons_react/icons/heart.js create mode 100644 lib/octicons_react/icons/history.js create mode 100644 lib/octicons_react/icons/home.js create mode 100644 lib/octicons_react/icons/horizontal-rule.js create mode 100644 lib/octicons_react/icons/hubot.js create mode 100644 lib/octicons_react/icons/inbox.js create mode 100644 lib/octicons_react/icons/info.js create mode 100644 lib/octicons_react/icons/issue-closed.js create mode 100644 lib/octicons_react/icons/issue-opened.js create mode 100644 lib/octicons_react/icons/issue-reopened.js create mode 100644 lib/octicons_react/icons/italic.js create mode 100644 lib/octicons_react/icons/jersey.js create mode 100644 lib/octicons_react/icons/kebab-horizontal.js create mode 100644 lib/octicons_react/icons/kebab-vertical.js create mode 100644 lib/octicons_react/icons/key.js create mode 100644 lib/octicons_react/icons/keyboard.js create mode 100644 lib/octicons_react/icons/law.js create mode 100644 lib/octicons_react/icons/light-bulb.js create mode 100644 lib/octicons_react/icons/link-external.js create mode 100644 lib/octicons_react/icons/link.js create mode 100644 lib/octicons_react/icons/list-ordered.js create mode 100644 lib/octicons_react/icons/list-unordered.js create mode 100644 lib/octicons_react/icons/location.js create mode 100644 lib/octicons_react/icons/lock.js create mode 100644 lib/octicons_react/icons/logo-gist.js create mode 100644 lib/octicons_react/icons/logo-github.js create mode 100644 lib/octicons_react/icons/mail-read.js create mode 100644 lib/octicons_react/icons/mail.js create mode 100644 lib/octicons_react/icons/mark-github.js create mode 100644 lib/octicons_react/icons/markdown.js create mode 100644 lib/octicons_react/icons/megaphone.js create mode 100644 lib/octicons_react/icons/mention.js create mode 100644 lib/octicons_react/icons/milestone.js create mode 100644 lib/octicons_react/icons/mirror.js create mode 100644 lib/octicons_react/icons/mortar-board.js create mode 100644 lib/octicons_react/icons/mute.js create mode 100644 lib/octicons_react/icons/no-newline.js create mode 100644 lib/octicons_react/icons/note.js create mode 100644 lib/octicons_react/icons/octoface.js create mode 100644 lib/octicons_react/icons/organization.js create mode 100644 lib/octicons_react/icons/package.js create mode 100644 lib/octicons_react/icons/paintcan.js create mode 100644 lib/octicons_react/icons/pencil.js create mode 100644 lib/octicons_react/icons/person.js create mode 100644 lib/octicons_react/icons/pin.js create mode 100644 lib/octicons_react/icons/plug.js create mode 100644 lib/octicons_react/icons/plus-small.js create mode 100644 lib/octicons_react/icons/plus.js create mode 100644 lib/octicons_react/icons/primitive-dot.js create mode 100644 lib/octicons_react/icons/primitive-square.js create mode 100644 lib/octicons_react/icons/project.js create mode 100644 lib/octicons_react/icons/pulse.js create mode 100644 lib/octicons_react/icons/question.js create mode 100644 lib/octicons_react/icons/quote.js create mode 100644 lib/octicons_react/icons/radio-tower.js create mode 100644 lib/octicons_react/icons/reply.js create mode 100644 lib/octicons_react/icons/repo-clone.js create mode 100644 lib/octicons_react/icons/repo-force-push.js create mode 100644 lib/octicons_react/icons/repo-forked.js create mode 100644 lib/octicons_react/icons/repo-pull.js create mode 100644 lib/octicons_react/icons/repo-push.js create mode 100644 lib/octicons_react/icons/repo.js create mode 100644 lib/octicons_react/icons/report.js create mode 100644 lib/octicons_react/icons/rocket.js create mode 100644 lib/octicons_react/icons/rss.js create mode 100644 lib/octicons_react/icons/ruby.js create mode 100644 lib/octicons_react/icons/screen-full.js create mode 100644 lib/octicons_react/icons/screen-normal.js create mode 100644 lib/octicons_react/icons/search.js create mode 100644 lib/octicons_react/icons/server.js create mode 100644 lib/octicons_react/icons/settings.js create mode 100644 lib/octicons_react/icons/shield.js create mode 100644 lib/octicons_react/icons/sign-in.js create mode 100644 lib/octicons_react/icons/sign-out.js create mode 100644 lib/octicons_react/icons/smiley.js create mode 100644 lib/octicons_react/icons/squirrel.js create mode 100644 lib/octicons_react/icons/star.js create mode 100644 lib/octicons_react/icons/stop.js create mode 100644 lib/octicons_react/icons/sync.js create mode 100644 lib/octicons_react/icons/tag.js create mode 100644 lib/octicons_react/icons/tasklist.js create mode 100644 lib/octicons_react/icons/telescope.js create mode 100644 lib/octicons_react/icons/terminal.js create mode 100644 lib/octicons_react/icons/text-size.js create mode 100644 lib/octicons_react/icons/three-bars.js create mode 100644 lib/octicons_react/icons/thumbsdown.js create mode 100644 lib/octicons_react/icons/thumbsup.js create mode 100644 lib/octicons_react/icons/tools.js create mode 100644 lib/octicons_react/icons/trashcan.js create mode 100644 lib/octicons_react/icons/triangle-down.js create mode 100644 lib/octicons_react/icons/triangle-left.js create mode 100644 lib/octicons_react/icons/triangle-right.js create mode 100644 lib/octicons_react/icons/triangle-up.js create mode 100644 lib/octicons_react/icons/unfold.js create mode 100644 lib/octicons_react/icons/unmute.js create mode 100644 lib/octicons_react/icons/unverified.js create mode 100644 lib/octicons_react/icons/verified.js create mode 100644 lib/octicons_react/icons/versions.js create mode 100644 lib/octicons_react/icons/watch.js create mode 100644 lib/octicons_react/icons/x.js create mode 100644 lib/octicons_react/icons/zap.js create mode 100644 lib/octicons_react/index.js mode change 100644 => 100755 lib/octicons_react/script/build.js diff --git a/lib/octicons_react/icons/alert.js b/lib/octicons_react/icons/alert.js new file mode 100644 index 000000000..d9d246e56 --- /dev/null +++ b/lib/octicons_react/icons/alert.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function alert() { + return +} +alert.size = [16, 16] diff --git a/lib/octicons_react/icons/arrow-down.js b/lib/octicons_react/icons/arrow-down.js new file mode 100644 index 000000000..77d5c5905 --- /dev/null +++ b/lib/octicons_react/icons/arrow-down.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function arrowDown() { + return +} +arrowDown.size = [10, 16] diff --git a/lib/octicons_react/icons/arrow-left.js b/lib/octicons_react/icons/arrow-left.js new file mode 100644 index 000000000..3e891e23d --- /dev/null +++ b/lib/octicons_react/icons/arrow-left.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function arrowLeft() { + return +} +arrowLeft.size = [10, 16] diff --git a/lib/octicons_react/icons/arrow-right.js b/lib/octicons_react/icons/arrow-right.js new file mode 100644 index 000000000..9f13d6144 --- /dev/null +++ b/lib/octicons_react/icons/arrow-right.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function arrowRight() { + return +} +arrowRight.size = [10, 16] diff --git a/lib/octicons_react/icons/arrow-small-down.js b/lib/octicons_react/icons/arrow-small-down.js new file mode 100644 index 000000000..5a1193a2a --- /dev/null +++ b/lib/octicons_react/icons/arrow-small-down.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function arrowSmallDown() { + return +} +arrowSmallDown.size = [6, 16] diff --git a/lib/octicons_react/icons/arrow-small-left.js b/lib/octicons_react/icons/arrow-small-left.js new file mode 100644 index 000000000..537e6729b --- /dev/null +++ b/lib/octicons_react/icons/arrow-small-left.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function arrowSmallLeft() { + return +} +arrowSmallLeft.size = [6, 16] diff --git a/lib/octicons_react/icons/arrow-small-right.js b/lib/octicons_react/icons/arrow-small-right.js new file mode 100644 index 000000000..306f11779 --- /dev/null +++ b/lib/octicons_react/icons/arrow-small-right.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function arrowSmallRight() { + return +} +arrowSmallRight.size = [6, 16] diff --git a/lib/octicons_react/icons/arrow-small-up.js b/lib/octicons_react/icons/arrow-small-up.js new file mode 100644 index 000000000..87a5cc334 --- /dev/null +++ b/lib/octicons_react/icons/arrow-small-up.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function arrowSmallUp() { + return +} +arrowSmallUp.size = [6, 16] diff --git a/lib/octicons_react/icons/arrow-up.js b/lib/octicons_react/icons/arrow-up.js new file mode 100644 index 000000000..63b96fcb9 --- /dev/null +++ b/lib/octicons_react/icons/arrow-up.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function arrowUp() { + return +} +arrowUp.size = [10, 16] diff --git a/lib/octicons_react/icons/beaker.js b/lib/octicons_react/icons/beaker.js new file mode 100644 index 000000000..695380294 --- /dev/null +++ b/lib/octicons_react/icons/beaker.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function beaker() { + return +} +beaker.size = [16, 16] diff --git a/lib/octicons_react/icons/bell.js b/lib/octicons_react/icons/bell.js new file mode 100644 index 000000000..e3e0ac254 --- /dev/null +++ b/lib/octicons_react/icons/bell.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function bell() { + return +} +bell.size = [14, 16] diff --git a/lib/octicons_react/icons/bold.js b/lib/octicons_react/icons/bold.js new file mode 100644 index 000000000..aa839c9be --- /dev/null +++ b/lib/octicons_react/icons/bold.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function bold() { + return +} +bold.size = [10, 16] diff --git a/lib/octicons_react/icons/book.js b/lib/octicons_react/icons/book.js new file mode 100644 index 000000000..0503debb7 --- /dev/null +++ b/lib/octicons_react/icons/book.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function book() { + return +} +book.size = [16, 16] diff --git a/lib/octicons_react/icons/bookmark.js b/lib/octicons_react/icons/bookmark.js new file mode 100644 index 000000000..6aa5db36b --- /dev/null +++ b/lib/octicons_react/icons/bookmark.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function bookmark() { + return +} +bookmark.size = [10, 16] diff --git a/lib/octicons_react/icons/briefcase.js b/lib/octicons_react/icons/briefcase.js new file mode 100644 index 000000000..7719a1d64 --- /dev/null +++ b/lib/octicons_react/icons/briefcase.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function briefcase() { + return +} +briefcase.size = [14, 16] diff --git a/lib/octicons_react/icons/broadcast.js b/lib/octicons_react/icons/broadcast.js new file mode 100644 index 000000000..535224b17 --- /dev/null +++ b/lib/octicons_react/icons/broadcast.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function broadcast() { + return +} +broadcast.size = [16, 16] diff --git a/lib/octicons_react/icons/browser.js b/lib/octicons_react/icons/browser.js new file mode 100644 index 000000000..b161256e7 --- /dev/null +++ b/lib/octicons_react/icons/browser.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function browser() { + return +} +browser.size = [14, 16] diff --git a/lib/octicons_react/icons/bug.js b/lib/octicons_react/icons/bug.js new file mode 100644 index 000000000..335af5a46 --- /dev/null +++ b/lib/octicons_react/icons/bug.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function bug() { + return +} +bug.size = [16, 16] diff --git a/lib/octicons_react/icons/calendar.js b/lib/octicons_react/icons/calendar.js new file mode 100644 index 000000000..498099be9 --- /dev/null +++ b/lib/octicons_react/icons/calendar.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function calendar() { + return +} +calendar.size = [14, 16] diff --git a/lib/octicons_react/icons/check.js b/lib/octicons_react/icons/check.js new file mode 100644 index 000000000..805c4b723 --- /dev/null +++ b/lib/octicons_react/icons/check.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function check() { + return +} +check.size = [12, 16] diff --git a/lib/octicons_react/icons/checklist.js b/lib/octicons_react/icons/checklist.js new file mode 100644 index 000000000..64d7eef0d --- /dev/null +++ b/lib/octicons_react/icons/checklist.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function checklist() { + return +} +checklist.size = [16, 16] diff --git a/lib/octicons_react/icons/chevron-down.js b/lib/octicons_react/icons/chevron-down.js new file mode 100644 index 000000000..f5821b93c --- /dev/null +++ b/lib/octicons_react/icons/chevron-down.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function chevronDown() { + return +} +chevronDown.size = [10, 16] diff --git a/lib/octicons_react/icons/chevron-left.js b/lib/octicons_react/icons/chevron-left.js new file mode 100644 index 000000000..b2587dfce --- /dev/null +++ b/lib/octicons_react/icons/chevron-left.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function chevronLeft() { + return +} +chevronLeft.size = [8, 16] diff --git a/lib/octicons_react/icons/chevron-right.js b/lib/octicons_react/icons/chevron-right.js new file mode 100644 index 000000000..6edaabe02 --- /dev/null +++ b/lib/octicons_react/icons/chevron-right.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function chevronRight() { + return +} +chevronRight.size = [8, 16] diff --git a/lib/octicons_react/icons/chevron-up.js b/lib/octicons_react/icons/chevron-up.js new file mode 100644 index 000000000..1809ed0c4 --- /dev/null +++ b/lib/octicons_react/icons/chevron-up.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function chevronUp() { + return +} +chevronUp.size = [10, 16] diff --git a/lib/octicons_react/icons/circle-slash.js b/lib/octicons_react/icons/circle-slash.js new file mode 100644 index 000000000..2df0fc130 --- /dev/null +++ b/lib/octicons_react/icons/circle-slash.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function circleSlash() { + return +} +circleSlash.size = [14, 16] diff --git a/lib/octicons_react/icons/circuit-board.js b/lib/octicons_react/icons/circuit-board.js new file mode 100644 index 000000000..b362a450b --- /dev/null +++ b/lib/octicons_react/icons/circuit-board.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function circuitBoard() { + return +} +circuitBoard.size = [14, 16] diff --git a/lib/octicons_react/icons/clippy.js b/lib/octicons_react/icons/clippy.js new file mode 100644 index 000000000..4c672cf22 --- /dev/null +++ b/lib/octicons_react/icons/clippy.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function clippy() { + return +} +clippy.size = [14, 16] diff --git a/lib/octicons_react/icons/clock.js b/lib/octicons_react/icons/clock.js new file mode 100644 index 000000000..177f284f7 --- /dev/null +++ b/lib/octicons_react/icons/clock.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function clock() { + return +} +clock.size = [14, 16] diff --git a/lib/octicons_react/icons/cloud-download.js b/lib/octicons_react/icons/cloud-download.js new file mode 100644 index 000000000..e4a9e4570 --- /dev/null +++ b/lib/octicons_react/icons/cloud-download.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function cloudDownload() { + return +} +cloudDownload.size = [16, 16] diff --git a/lib/octicons_react/icons/cloud-upload.js b/lib/octicons_react/icons/cloud-upload.js new file mode 100644 index 000000000..08bd4202d --- /dev/null +++ b/lib/octicons_react/icons/cloud-upload.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function cloudUpload() { + return +} +cloudUpload.size = [16, 16] diff --git a/lib/octicons_react/icons/code.js b/lib/octicons_react/icons/code.js new file mode 100644 index 000000000..8073f7ade --- /dev/null +++ b/lib/octicons_react/icons/code.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function code() { + return +} +code.size = [14, 16] diff --git a/lib/octicons_react/icons/comment-discussion.js b/lib/octicons_react/icons/comment-discussion.js new file mode 100644 index 000000000..5717347bb --- /dev/null +++ b/lib/octicons_react/icons/comment-discussion.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function commentDiscussion() { + return +} +commentDiscussion.size = [16, 16] diff --git a/lib/octicons_react/icons/comment.js b/lib/octicons_react/icons/comment.js new file mode 100644 index 000000000..a77b2522f --- /dev/null +++ b/lib/octicons_react/icons/comment.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function comment() { + return +} +comment.size = [16, 16] diff --git a/lib/octicons_react/icons/credit-card.js b/lib/octicons_react/icons/credit-card.js new file mode 100644 index 000000000..d1e761481 --- /dev/null +++ b/lib/octicons_react/icons/credit-card.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function creditCard() { + return +} +creditCard.size = [16, 16] diff --git a/lib/octicons_react/icons/dash.js b/lib/octicons_react/icons/dash.js new file mode 100644 index 000000000..2653aede0 --- /dev/null +++ b/lib/octicons_react/icons/dash.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function dash() { + return +} +dash.size = [8, 16] diff --git a/lib/octicons_react/icons/dashboard.js b/lib/octicons_react/icons/dashboard.js new file mode 100644 index 000000000..2308ecbc9 --- /dev/null +++ b/lib/octicons_react/icons/dashboard.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function dashboard() { + return +} +dashboard.size = [16, 16] diff --git a/lib/octicons_react/icons/database.js b/lib/octicons_react/icons/database.js new file mode 100644 index 000000000..3a2e91396 --- /dev/null +++ b/lib/octicons_react/icons/database.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function database() { + return +} +database.size = [12, 16] diff --git a/lib/octicons_react/icons/desktop-download.js b/lib/octicons_react/icons/desktop-download.js new file mode 100644 index 000000000..678d828f4 --- /dev/null +++ b/lib/octicons_react/icons/desktop-download.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function desktopDownload() { + return +} +desktopDownload.size = [16, 16] diff --git a/lib/octicons_react/icons/device-camera-video.js b/lib/octicons_react/icons/device-camera-video.js new file mode 100644 index 000000000..934790e3e --- /dev/null +++ b/lib/octicons_react/icons/device-camera-video.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function deviceCameraVideo() { + return +} +deviceCameraVideo.size = [16, 16] diff --git a/lib/octicons_react/icons/device-camera.js b/lib/octicons_react/icons/device-camera.js new file mode 100644 index 000000000..3cc7a4903 --- /dev/null +++ b/lib/octicons_react/icons/device-camera.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function deviceCamera() { + return +} +deviceCamera.size = [16, 16] diff --git a/lib/octicons_react/icons/device-desktop.js b/lib/octicons_react/icons/device-desktop.js new file mode 100644 index 000000000..900e20087 --- /dev/null +++ b/lib/octicons_react/icons/device-desktop.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function deviceDesktop() { + return +} +deviceDesktop.size = [16, 16] diff --git a/lib/octicons_react/icons/device-mobile.js b/lib/octicons_react/icons/device-mobile.js new file mode 100644 index 000000000..8d0e51d12 --- /dev/null +++ b/lib/octicons_react/icons/device-mobile.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function deviceMobile() { + return +} +deviceMobile.size = [10, 16] diff --git a/lib/octicons_react/icons/diff-added.js b/lib/octicons_react/icons/diff-added.js new file mode 100644 index 000000000..15b302a5c --- /dev/null +++ b/lib/octicons_react/icons/diff-added.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function diffAdded() { + return +} +diffAdded.size = [14, 16] diff --git a/lib/octicons_react/icons/diff-ignored.js b/lib/octicons_react/icons/diff-ignored.js new file mode 100644 index 000000000..5cbe971b2 --- /dev/null +++ b/lib/octicons_react/icons/diff-ignored.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function diffIgnored() { + return +} +diffIgnored.size = [14, 16] diff --git a/lib/octicons_react/icons/diff-modified.js b/lib/octicons_react/icons/diff-modified.js new file mode 100644 index 000000000..0b5aaf765 --- /dev/null +++ b/lib/octicons_react/icons/diff-modified.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function diffModified() { + return +} +diffModified.size = [14, 16] diff --git a/lib/octicons_react/icons/diff-removed.js b/lib/octicons_react/icons/diff-removed.js new file mode 100644 index 000000000..c1568caae --- /dev/null +++ b/lib/octicons_react/icons/diff-removed.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function diffRemoved() { + return +} +diffRemoved.size = [14, 16] diff --git a/lib/octicons_react/icons/diff-renamed.js b/lib/octicons_react/icons/diff-renamed.js new file mode 100644 index 000000000..f905e8f84 --- /dev/null +++ b/lib/octicons_react/icons/diff-renamed.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function diffRenamed() { + return +} +diffRenamed.size = [14, 16] diff --git a/lib/octicons_react/icons/diff.js b/lib/octicons_react/icons/diff.js new file mode 100644 index 000000000..9a7f514cd --- /dev/null +++ b/lib/octicons_react/icons/diff.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function diff() { + return +} +diff.size = [13, 16] diff --git a/lib/octicons_react/icons/ellipsis.js b/lib/octicons_react/icons/ellipsis.js new file mode 100644 index 000000000..6f5766557 --- /dev/null +++ b/lib/octicons_react/icons/ellipsis.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function ellipsis() { + return +} +ellipsis.size = [12, 16] diff --git a/lib/octicons_react/icons/eye.js b/lib/octicons_react/icons/eye.js new file mode 100644 index 000000000..3f0be72bf --- /dev/null +++ b/lib/octicons_react/icons/eye.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function eye() { + return +} +eye.size = [16, 16] diff --git a/lib/octicons_react/icons/file-binary.js b/lib/octicons_react/icons/file-binary.js new file mode 100644 index 000000000..33e4b0132 --- /dev/null +++ b/lib/octicons_react/icons/file-binary.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function fileBinary() { + return +} +fileBinary.size = [12, 16] diff --git a/lib/octicons_react/icons/file-code.js b/lib/octicons_react/icons/file-code.js new file mode 100644 index 000000000..3b23e5779 --- /dev/null +++ b/lib/octicons_react/icons/file-code.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function fileCode() { + return +} +fileCode.size = [12, 16] diff --git a/lib/octicons_react/icons/file-directory.js b/lib/octicons_react/icons/file-directory.js new file mode 100644 index 000000000..841099bb9 --- /dev/null +++ b/lib/octicons_react/icons/file-directory.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function fileDirectory() { + return +} +fileDirectory.size = [14, 16] diff --git a/lib/octicons_react/icons/file-media.js b/lib/octicons_react/icons/file-media.js new file mode 100644 index 000000000..17ea910c8 --- /dev/null +++ b/lib/octicons_react/icons/file-media.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function fileMedia() { + return +} +fileMedia.size = [12, 16] diff --git a/lib/octicons_react/icons/file-pdf.js b/lib/octicons_react/icons/file-pdf.js new file mode 100644 index 000000000..d0ce79f75 --- /dev/null +++ b/lib/octicons_react/icons/file-pdf.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function filePdf() { + return +} +filePdf.size = [12, 16] diff --git a/lib/octicons_react/icons/file-submodule.js b/lib/octicons_react/icons/file-submodule.js new file mode 100644 index 000000000..bacf8ff25 --- /dev/null +++ b/lib/octicons_react/icons/file-submodule.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function fileSubmodule() { + return +} +fileSubmodule.size = [14, 16] diff --git a/lib/octicons_react/icons/file-symlink-directory.js b/lib/octicons_react/icons/file-symlink-directory.js new file mode 100644 index 000000000..77d2fa6ae --- /dev/null +++ b/lib/octicons_react/icons/file-symlink-directory.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function fileSymlinkDirectory() { + return +} +fileSymlinkDirectory.size = [14, 16] diff --git a/lib/octicons_react/icons/file-symlink-file.js b/lib/octicons_react/icons/file-symlink-file.js new file mode 100644 index 000000000..0093a8511 --- /dev/null +++ b/lib/octicons_react/icons/file-symlink-file.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function fileSymlinkFile() { + return +} +fileSymlinkFile.size = [12, 16] diff --git a/lib/octicons_react/icons/file-zip.js b/lib/octicons_react/icons/file-zip.js new file mode 100644 index 000000000..bbdbd6e8a --- /dev/null +++ b/lib/octicons_react/icons/file-zip.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function fileZip() { + return +} +fileZip.size = [12, 16] diff --git a/lib/octicons_react/icons/file.js b/lib/octicons_react/icons/file.js new file mode 100644 index 000000000..eaa831a77 --- /dev/null +++ b/lib/octicons_react/icons/file.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function file() { + return +} +file.size = [12, 16] diff --git a/lib/octicons_react/icons/flame.js b/lib/octicons_react/icons/flame.js new file mode 100644 index 000000000..d7b3dc2de --- /dev/null +++ b/lib/octicons_react/icons/flame.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function flame() { + return +} +flame.size = [12, 16] diff --git a/lib/octicons_react/icons/fold.js b/lib/octicons_react/icons/fold.js new file mode 100644 index 000000000..69fe836f0 --- /dev/null +++ b/lib/octicons_react/icons/fold.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function fold() { + return +} +fold.size = [14, 16] diff --git a/lib/octicons_react/icons/gear.js b/lib/octicons_react/icons/gear.js new file mode 100644 index 000000000..664d6593f --- /dev/null +++ b/lib/octicons_react/icons/gear.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function gear() { + return +} +gear.size = [14, 16] diff --git a/lib/octicons_react/icons/gift.js b/lib/octicons_react/icons/gift.js new file mode 100644 index 000000000..7cd2b09d2 --- /dev/null +++ b/lib/octicons_react/icons/gift.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function gift() { + return +} +gift.size = [14, 16] diff --git a/lib/octicons_react/icons/gist-secret.js b/lib/octicons_react/icons/gist-secret.js new file mode 100644 index 000000000..b5582aac0 --- /dev/null +++ b/lib/octicons_react/icons/gist-secret.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function gistSecret() { + return +} +gistSecret.size = [14, 16] diff --git a/lib/octicons_react/icons/gist.js b/lib/octicons_react/icons/gist.js new file mode 100644 index 000000000..9f7d8deae --- /dev/null +++ b/lib/octicons_react/icons/gist.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function gist() { + return +} +gist.size = [12, 16] diff --git a/lib/octicons_react/icons/git-branch.js b/lib/octicons_react/icons/git-branch.js new file mode 100644 index 000000000..00a58b20f --- /dev/null +++ b/lib/octicons_react/icons/git-branch.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function gitBranch() { + return +} +gitBranch.size = [10, 16] diff --git a/lib/octicons_react/icons/git-commit.js b/lib/octicons_react/icons/git-commit.js new file mode 100644 index 000000000..8ecc1df88 --- /dev/null +++ b/lib/octicons_react/icons/git-commit.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function gitCommit() { + return +} +gitCommit.size = [14, 16] diff --git a/lib/octicons_react/icons/git-compare.js b/lib/octicons_react/icons/git-compare.js new file mode 100644 index 000000000..e67e5866c --- /dev/null +++ b/lib/octicons_react/icons/git-compare.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function gitCompare() { + return +} +gitCompare.size = [14, 16] diff --git a/lib/octicons_react/icons/git-merge.js b/lib/octicons_react/icons/git-merge.js new file mode 100644 index 000000000..a6df2e1b1 --- /dev/null +++ b/lib/octicons_react/icons/git-merge.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function gitMerge() { + return +} +gitMerge.size = [12, 16] diff --git a/lib/octicons_react/icons/git-pull-request.js b/lib/octicons_react/icons/git-pull-request.js new file mode 100644 index 000000000..476ff313e --- /dev/null +++ b/lib/octicons_react/icons/git-pull-request.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function gitPullRequest() { + return +} +gitPullRequest.size = [12, 16] diff --git a/lib/octicons_react/icons/globe.js b/lib/octicons_react/icons/globe.js new file mode 100644 index 000000000..f1222c9dd --- /dev/null +++ b/lib/octicons_react/icons/globe.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function globe() { + return +} +globe.size = [14, 16] diff --git a/lib/octicons_react/icons/grabber.js b/lib/octicons_react/icons/grabber.js new file mode 100644 index 000000000..340259926 --- /dev/null +++ b/lib/octicons_react/icons/grabber.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function grabber() { + return +} +grabber.size = [8, 16] diff --git a/lib/octicons_react/icons/graph.js b/lib/octicons_react/icons/graph.js new file mode 100644 index 000000000..610cb5503 --- /dev/null +++ b/lib/octicons_react/icons/graph.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function graph() { + return +} +graph.size = [16, 16] diff --git a/lib/octicons_react/icons/heart.js b/lib/octicons_react/icons/heart.js new file mode 100644 index 000000000..7f0143511 --- /dev/null +++ b/lib/octicons_react/icons/heart.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function heart() { + return +} +heart.size = [12, 16] diff --git a/lib/octicons_react/icons/history.js b/lib/octicons_react/icons/history.js new file mode 100644 index 000000000..6b65450c6 --- /dev/null +++ b/lib/octicons_react/icons/history.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function history() { + return +} +history.size = [14, 16] diff --git a/lib/octicons_react/icons/home.js b/lib/octicons_react/icons/home.js new file mode 100644 index 000000000..2730f288f --- /dev/null +++ b/lib/octicons_react/icons/home.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function home() { + return +} +home.size = [16, 16] diff --git a/lib/octicons_react/icons/horizontal-rule.js b/lib/octicons_react/icons/horizontal-rule.js new file mode 100644 index 000000000..e1809214e --- /dev/null +++ b/lib/octicons_react/icons/horizontal-rule.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function horizontalRule() { + return +} +horizontalRule.size = [10, 16] diff --git a/lib/octicons_react/icons/hubot.js b/lib/octicons_react/icons/hubot.js new file mode 100644 index 000000000..7e6ae56e8 --- /dev/null +++ b/lib/octicons_react/icons/hubot.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function hubot() { + return +} +hubot.size = [14, 16] diff --git a/lib/octicons_react/icons/inbox.js b/lib/octicons_react/icons/inbox.js new file mode 100644 index 000000000..c0c7d94f7 --- /dev/null +++ b/lib/octicons_react/icons/inbox.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function inbox() { + return +} +inbox.size = [14, 16] diff --git a/lib/octicons_react/icons/info.js b/lib/octicons_react/icons/info.js new file mode 100644 index 000000000..d93a5340d --- /dev/null +++ b/lib/octicons_react/icons/info.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function info() { + return +} +info.size = [14, 16] diff --git a/lib/octicons_react/icons/issue-closed.js b/lib/octicons_react/icons/issue-closed.js new file mode 100644 index 000000000..8044bc008 --- /dev/null +++ b/lib/octicons_react/icons/issue-closed.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function issueClosed() { + return +} +issueClosed.size = [16, 16] diff --git a/lib/octicons_react/icons/issue-opened.js b/lib/octicons_react/icons/issue-opened.js new file mode 100644 index 000000000..435064f3c --- /dev/null +++ b/lib/octicons_react/icons/issue-opened.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function issueOpened() { + return +} +issueOpened.size = [14, 16] diff --git a/lib/octicons_react/icons/issue-reopened.js b/lib/octicons_react/icons/issue-reopened.js new file mode 100644 index 000000000..72956e486 --- /dev/null +++ b/lib/octicons_react/icons/issue-reopened.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function issueReopened() { + return +} +issueReopened.size = [14, 16] diff --git a/lib/octicons_react/icons/italic.js b/lib/octicons_react/icons/italic.js new file mode 100644 index 000000000..522f2b7fe --- /dev/null +++ b/lib/octicons_react/icons/italic.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function italic() { + return +} +italic.size = [6, 16] diff --git a/lib/octicons_react/icons/jersey.js b/lib/octicons_react/icons/jersey.js new file mode 100644 index 000000000..74dc1cb96 --- /dev/null +++ b/lib/octicons_react/icons/jersey.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function jersey() { + return +} +jersey.size = [14, 16] diff --git a/lib/octicons_react/icons/kebab-horizontal.js b/lib/octicons_react/icons/kebab-horizontal.js new file mode 100644 index 000000000..b2d3e4c0e --- /dev/null +++ b/lib/octicons_react/icons/kebab-horizontal.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function kebabHorizontal() { + return +} +kebabHorizontal.size = [13, 16] diff --git a/lib/octicons_react/icons/kebab-vertical.js b/lib/octicons_react/icons/kebab-vertical.js new file mode 100644 index 000000000..e2e53573c --- /dev/null +++ b/lib/octicons_react/icons/kebab-vertical.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function kebabVertical() { + return +} +kebabVertical.size = [3, 16] diff --git a/lib/octicons_react/icons/key.js b/lib/octicons_react/icons/key.js new file mode 100644 index 000000000..74c679551 --- /dev/null +++ b/lib/octicons_react/icons/key.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function key() { + return +} +key.size = [14, 16] diff --git a/lib/octicons_react/icons/keyboard.js b/lib/octicons_react/icons/keyboard.js new file mode 100644 index 000000000..627bcc063 --- /dev/null +++ b/lib/octicons_react/icons/keyboard.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function keyboard() { + return +} +keyboard.size = [16, 16] diff --git a/lib/octicons_react/icons/law.js b/lib/octicons_react/icons/law.js new file mode 100644 index 000000000..c1ffe584a --- /dev/null +++ b/lib/octicons_react/icons/law.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function law() { + return +} +law.size = [14, 16] diff --git a/lib/octicons_react/icons/light-bulb.js b/lib/octicons_react/icons/light-bulb.js new file mode 100644 index 000000000..7af8803de --- /dev/null +++ b/lib/octicons_react/icons/light-bulb.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function lightBulb() { + return +} +lightBulb.size = [12, 16] diff --git a/lib/octicons_react/icons/link-external.js b/lib/octicons_react/icons/link-external.js new file mode 100644 index 000000000..e574d566c --- /dev/null +++ b/lib/octicons_react/icons/link-external.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function linkExternal() { + return +} +linkExternal.size = [12, 16] diff --git a/lib/octicons_react/icons/link.js b/lib/octicons_react/icons/link.js new file mode 100644 index 000000000..45b5a7718 --- /dev/null +++ b/lib/octicons_react/icons/link.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function link() { + return +} +link.size = [16, 16] diff --git a/lib/octicons_react/icons/list-ordered.js b/lib/octicons_react/icons/list-ordered.js new file mode 100644 index 000000000..0e63d9f8e --- /dev/null +++ b/lib/octicons_react/icons/list-ordered.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function listOrdered() { + return +} +listOrdered.size = [12, 16] diff --git a/lib/octicons_react/icons/list-unordered.js b/lib/octicons_react/icons/list-unordered.js new file mode 100644 index 000000000..156c4267b --- /dev/null +++ b/lib/octicons_react/icons/list-unordered.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function listUnordered() { + return +} +listUnordered.size = [12, 16] diff --git a/lib/octicons_react/icons/location.js b/lib/octicons_react/icons/location.js new file mode 100644 index 000000000..2686f0dd1 --- /dev/null +++ b/lib/octicons_react/icons/location.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function location() { + return +} +location.size = [12, 16] diff --git a/lib/octicons_react/icons/lock.js b/lib/octicons_react/icons/lock.js new file mode 100644 index 000000000..ab0cb2369 --- /dev/null +++ b/lib/octicons_react/icons/lock.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function lock() { + return +} +lock.size = [12, 16] diff --git a/lib/octicons_react/icons/logo-gist.js b/lib/octicons_react/icons/logo-gist.js new file mode 100644 index 000000000..b5560aa13 --- /dev/null +++ b/lib/octicons_react/icons/logo-gist.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function logoGist() { + return +} +logoGist.size = [25, 16] diff --git a/lib/octicons_react/icons/logo-github.js b/lib/octicons_react/icons/logo-github.js new file mode 100644 index 000000000..38ec669e4 --- /dev/null +++ b/lib/octicons_react/icons/logo-github.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function logoGithub() { + return +} +logoGithub.size = [45, 16] diff --git a/lib/octicons_react/icons/mail-read.js b/lib/octicons_react/icons/mail-read.js new file mode 100644 index 000000000..73b950b73 --- /dev/null +++ b/lib/octicons_react/icons/mail-read.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function mailRead() { + return +} +mailRead.size = [14, 16] diff --git a/lib/octicons_react/icons/mail.js b/lib/octicons_react/icons/mail.js new file mode 100644 index 000000000..6526eac37 --- /dev/null +++ b/lib/octicons_react/icons/mail.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function mail() { + return +} +mail.size = [14, 16] diff --git a/lib/octicons_react/icons/mark-github.js b/lib/octicons_react/icons/mark-github.js new file mode 100644 index 000000000..0bf5b19d1 --- /dev/null +++ b/lib/octicons_react/icons/mark-github.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function markGithub() { + return +} +markGithub.size = [16, 16] diff --git a/lib/octicons_react/icons/markdown.js b/lib/octicons_react/icons/markdown.js new file mode 100644 index 000000000..6edc0ada6 --- /dev/null +++ b/lib/octicons_react/icons/markdown.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function markdown() { + return +} +markdown.size = [16, 16] diff --git a/lib/octicons_react/icons/megaphone.js b/lib/octicons_react/icons/megaphone.js new file mode 100644 index 000000000..1f44a3807 --- /dev/null +++ b/lib/octicons_react/icons/megaphone.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function megaphone() { + return +} +megaphone.size = [16, 16] diff --git a/lib/octicons_react/icons/mention.js b/lib/octicons_react/icons/mention.js new file mode 100644 index 000000000..2b1c9134d --- /dev/null +++ b/lib/octicons_react/icons/mention.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function mention() { + return +} +mention.size = [14, 16] diff --git a/lib/octicons_react/icons/milestone.js b/lib/octicons_react/icons/milestone.js new file mode 100644 index 000000000..ae86e404f --- /dev/null +++ b/lib/octicons_react/icons/milestone.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function milestone() { + return +} +milestone.size = [14, 16] diff --git a/lib/octicons_react/icons/mirror.js b/lib/octicons_react/icons/mirror.js new file mode 100644 index 000000000..5b0395cc4 --- /dev/null +++ b/lib/octicons_react/icons/mirror.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function mirror() { + return +} +mirror.size = [16, 16] diff --git a/lib/octicons_react/icons/mortar-board.js b/lib/octicons_react/icons/mortar-board.js new file mode 100644 index 000000000..5573ae9ad --- /dev/null +++ b/lib/octicons_react/icons/mortar-board.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function mortarBoard() { + return +} +mortarBoard.size = [16, 16] diff --git a/lib/octicons_react/icons/mute.js b/lib/octicons_react/icons/mute.js new file mode 100644 index 000000000..bae659581 --- /dev/null +++ b/lib/octicons_react/icons/mute.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function mute() { + return +} +mute.size = [16, 16] diff --git a/lib/octicons_react/icons/no-newline.js b/lib/octicons_react/icons/no-newline.js new file mode 100644 index 000000000..287df16d8 --- /dev/null +++ b/lib/octicons_react/icons/no-newline.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function noNewline() { + return +} +noNewline.size = [16, 16] diff --git a/lib/octicons_react/icons/note.js b/lib/octicons_react/icons/note.js new file mode 100644 index 000000000..7ea7d4164 --- /dev/null +++ b/lib/octicons_react/icons/note.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function note() { + return +} +note.size = [14, 16] diff --git a/lib/octicons_react/icons/octoface.js b/lib/octicons_react/icons/octoface.js new file mode 100644 index 000000000..e5cf15fdd --- /dev/null +++ b/lib/octicons_react/icons/octoface.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function octoface() { + return +} +octoface.size = [16, 16] diff --git a/lib/octicons_react/icons/organization.js b/lib/octicons_react/icons/organization.js new file mode 100644 index 000000000..d76d90f8a --- /dev/null +++ b/lib/octicons_react/icons/organization.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function organization() { + return +} +organization.size = [16, 16] diff --git a/lib/octicons_react/icons/package.js b/lib/octicons_react/icons/package.js new file mode 100644 index 000000000..00e9259f5 --- /dev/null +++ b/lib/octicons_react/icons/package.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function package() { + return +} +package.size = [16, 16] diff --git a/lib/octicons_react/icons/paintcan.js b/lib/octicons_react/icons/paintcan.js new file mode 100644 index 000000000..84ef079b1 --- /dev/null +++ b/lib/octicons_react/icons/paintcan.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function paintcan() { + return +} +paintcan.size = [12, 16] diff --git a/lib/octicons_react/icons/pencil.js b/lib/octicons_react/icons/pencil.js new file mode 100644 index 000000000..b5acec037 --- /dev/null +++ b/lib/octicons_react/icons/pencil.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function pencil() { + return +} +pencil.size = [14, 16] diff --git a/lib/octicons_react/icons/person.js b/lib/octicons_react/icons/person.js new file mode 100644 index 000000000..54a111329 --- /dev/null +++ b/lib/octicons_react/icons/person.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function person() { + return +} +person.size = [12, 16] diff --git a/lib/octicons_react/icons/pin.js b/lib/octicons_react/icons/pin.js new file mode 100644 index 000000000..65fdd282a --- /dev/null +++ b/lib/octicons_react/icons/pin.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function pin() { + return +} +pin.size = [16, 16] diff --git a/lib/octicons_react/icons/plug.js b/lib/octicons_react/icons/plug.js new file mode 100644 index 000000000..ac8595907 --- /dev/null +++ b/lib/octicons_react/icons/plug.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function plug() { + return +} +plug.size = [14, 16] diff --git a/lib/octicons_react/icons/plus-small.js b/lib/octicons_react/icons/plus-small.js new file mode 100644 index 000000000..f7e2b899d --- /dev/null +++ b/lib/octicons_react/icons/plus-small.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function plusSmall() { + return +} +plusSmall.size = [7, 16] diff --git a/lib/octicons_react/icons/plus.js b/lib/octicons_react/icons/plus.js new file mode 100644 index 000000000..ba304ed32 --- /dev/null +++ b/lib/octicons_react/icons/plus.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function plus() { + return +} +plus.size = [12, 16] diff --git a/lib/octicons_react/icons/primitive-dot.js b/lib/octicons_react/icons/primitive-dot.js new file mode 100644 index 000000000..5ade5749e --- /dev/null +++ b/lib/octicons_react/icons/primitive-dot.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function primitiveDot() { + return +} +primitiveDot.size = [8, 16] diff --git a/lib/octicons_react/icons/primitive-square.js b/lib/octicons_react/icons/primitive-square.js new file mode 100644 index 000000000..a9fb4c97a --- /dev/null +++ b/lib/octicons_react/icons/primitive-square.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function primitiveSquare() { + return +} +primitiveSquare.size = [8, 16] diff --git a/lib/octicons_react/icons/project.js b/lib/octicons_react/icons/project.js new file mode 100644 index 000000000..46445cbda --- /dev/null +++ b/lib/octicons_react/icons/project.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function project() { + return +} +project.size = [15, 16] diff --git a/lib/octicons_react/icons/pulse.js b/lib/octicons_react/icons/pulse.js new file mode 100644 index 000000000..c3f0cf460 --- /dev/null +++ b/lib/octicons_react/icons/pulse.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function pulse() { + return +} +pulse.size = [14, 16] diff --git a/lib/octicons_react/icons/question.js b/lib/octicons_react/icons/question.js new file mode 100644 index 000000000..a81ea9179 --- /dev/null +++ b/lib/octicons_react/icons/question.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function question() { + return +} +question.size = [14, 16] diff --git a/lib/octicons_react/icons/quote.js b/lib/octicons_react/icons/quote.js new file mode 100644 index 000000000..3b7738609 --- /dev/null +++ b/lib/octicons_react/icons/quote.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function quote() { + return +} +quote.size = [14, 16] diff --git a/lib/octicons_react/icons/radio-tower.js b/lib/octicons_react/icons/radio-tower.js new file mode 100644 index 000000000..410272983 --- /dev/null +++ b/lib/octicons_react/icons/radio-tower.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function radioTower() { + return +} +radioTower.size = [16, 16] diff --git a/lib/octicons_react/icons/reply.js b/lib/octicons_react/icons/reply.js new file mode 100644 index 000000000..5d7c4f879 --- /dev/null +++ b/lib/octicons_react/icons/reply.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function reply() { + return +} +reply.size = [14, 16] diff --git a/lib/octicons_react/icons/repo-clone.js b/lib/octicons_react/icons/repo-clone.js new file mode 100644 index 000000000..fd611e6be --- /dev/null +++ b/lib/octicons_react/icons/repo-clone.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function repoClone() { + return +} +repoClone.size = [16, 16] diff --git a/lib/octicons_react/icons/repo-force-push.js b/lib/octicons_react/icons/repo-force-push.js new file mode 100644 index 000000000..ade9a7153 --- /dev/null +++ b/lib/octicons_react/icons/repo-force-push.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function repoForcePush() { + return +} +repoForcePush.size = [12, 16] diff --git a/lib/octicons_react/icons/repo-forked.js b/lib/octicons_react/icons/repo-forked.js new file mode 100644 index 000000000..3bce9034a --- /dev/null +++ b/lib/octicons_react/icons/repo-forked.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function repoForked() { + return +} +repoForked.size = [10, 16] diff --git a/lib/octicons_react/icons/repo-pull.js b/lib/octicons_react/icons/repo-pull.js new file mode 100644 index 000000000..02609bc70 --- /dev/null +++ b/lib/octicons_react/icons/repo-pull.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function repoPull() { + return +} +repoPull.size = [16, 16] diff --git a/lib/octicons_react/icons/repo-push.js b/lib/octicons_react/icons/repo-push.js new file mode 100644 index 000000000..86970ee03 --- /dev/null +++ b/lib/octicons_react/icons/repo-push.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function repoPush() { + return +} +repoPush.size = [12, 16] diff --git a/lib/octicons_react/icons/repo.js b/lib/octicons_react/icons/repo.js new file mode 100644 index 000000000..8db6e4251 --- /dev/null +++ b/lib/octicons_react/icons/repo.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function repo() { + return +} +repo.size = [12, 16] diff --git a/lib/octicons_react/icons/report.js b/lib/octicons_react/icons/report.js new file mode 100644 index 000000000..bf6e09a90 --- /dev/null +++ b/lib/octicons_react/icons/report.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function report() { + return +} +report.size = [16, 16] diff --git a/lib/octicons_react/icons/rocket.js b/lib/octicons_react/icons/rocket.js new file mode 100644 index 000000000..68afd60eb --- /dev/null +++ b/lib/octicons_react/icons/rocket.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function rocket() { + return +} +rocket.size = [16, 16] diff --git a/lib/octicons_react/icons/rss.js b/lib/octicons_react/icons/rss.js new file mode 100644 index 000000000..9586587f3 --- /dev/null +++ b/lib/octicons_react/icons/rss.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function rss() { + return +} +rss.size = [10, 16] diff --git a/lib/octicons_react/icons/ruby.js b/lib/octicons_react/icons/ruby.js new file mode 100644 index 000000000..6c2bcb0d2 --- /dev/null +++ b/lib/octicons_react/icons/ruby.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function ruby() { + return +} +ruby.size = [16, 16] diff --git a/lib/octicons_react/icons/screen-full.js b/lib/octicons_react/icons/screen-full.js new file mode 100644 index 000000000..ac4b1ddf1 --- /dev/null +++ b/lib/octicons_react/icons/screen-full.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function screenFull() { + return +} +screenFull.size = [14, 16] diff --git a/lib/octicons_react/icons/screen-normal.js b/lib/octicons_react/icons/screen-normal.js new file mode 100644 index 000000000..f233ebbc1 --- /dev/null +++ b/lib/octicons_react/icons/screen-normal.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function screenNormal() { + return +} +screenNormal.size = [14, 16] diff --git a/lib/octicons_react/icons/search.js b/lib/octicons_react/icons/search.js new file mode 100644 index 000000000..6f4d8f9e7 --- /dev/null +++ b/lib/octicons_react/icons/search.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function search() { + return +} +search.size = [16, 16] diff --git a/lib/octicons_react/icons/server.js b/lib/octicons_react/icons/server.js new file mode 100644 index 000000000..121a8792a --- /dev/null +++ b/lib/octicons_react/icons/server.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function server() { + return +} +server.size = [12, 16] diff --git a/lib/octicons_react/icons/settings.js b/lib/octicons_react/icons/settings.js new file mode 100644 index 000000000..19dd72925 --- /dev/null +++ b/lib/octicons_react/icons/settings.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function settings() { + return +} +settings.size = [16, 16] diff --git a/lib/octicons_react/icons/shield.js b/lib/octicons_react/icons/shield.js new file mode 100644 index 000000000..e21f348ff --- /dev/null +++ b/lib/octicons_react/icons/shield.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function shield() { + return +} +shield.size = [14, 16] diff --git a/lib/octicons_react/icons/sign-in.js b/lib/octicons_react/icons/sign-in.js new file mode 100644 index 000000000..10c0773b3 --- /dev/null +++ b/lib/octicons_react/icons/sign-in.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function signIn() { + return +} +signIn.size = [14, 16] diff --git a/lib/octicons_react/icons/sign-out.js b/lib/octicons_react/icons/sign-out.js new file mode 100644 index 000000000..e3b3535bb --- /dev/null +++ b/lib/octicons_react/icons/sign-out.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function signOut() { + return +} +signOut.size = [16, 16] diff --git a/lib/octicons_react/icons/smiley.js b/lib/octicons_react/icons/smiley.js new file mode 100644 index 000000000..4a678d65a --- /dev/null +++ b/lib/octicons_react/icons/smiley.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function smiley() { + return +} +smiley.size = [16, 16] diff --git a/lib/octicons_react/icons/squirrel.js b/lib/octicons_react/icons/squirrel.js new file mode 100644 index 000000000..3afcdbbb1 --- /dev/null +++ b/lib/octicons_react/icons/squirrel.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function squirrel() { + return +} +squirrel.size = [16, 16] diff --git a/lib/octicons_react/icons/star.js b/lib/octicons_react/icons/star.js new file mode 100644 index 000000000..2f3130110 --- /dev/null +++ b/lib/octicons_react/icons/star.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function star() { + return +} +star.size = [14, 16] diff --git a/lib/octicons_react/icons/stop.js b/lib/octicons_react/icons/stop.js new file mode 100644 index 000000000..ef1b4c3dc --- /dev/null +++ b/lib/octicons_react/icons/stop.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function stop() { + return +} +stop.size = [14, 16] diff --git a/lib/octicons_react/icons/sync.js b/lib/octicons_react/icons/sync.js new file mode 100644 index 000000000..99962b1bf --- /dev/null +++ b/lib/octicons_react/icons/sync.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function sync() { + return +} +sync.size = [12, 16] diff --git a/lib/octicons_react/icons/tag.js b/lib/octicons_react/icons/tag.js new file mode 100644 index 000000000..0d54ef6e8 --- /dev/null +++ b/lib/octicons_react/icons/tag.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function tag() { + return +} +tag.size = [14, 16] diff --git a/lib/octicons_react/icons/tasklist.js b/lib/octicons_react/icons/tasklist.js new file mode 100644 index 000000000..19eb53783 --- /dev/null +++ b/lib/octicons_react/icons/tasklist.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function tasklist() { + return +} +tasklist.size = [16, 16] diff --git a/lib/octicons_react/icons/telescope.js b/lib/octicons_react/icons/telescope.js new file mode 100644 index 000000000..56576bc38 --- /dev/null +++ b/lib/octicons_react/icons/telescope.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function telescope() { + return +} +telescope.size = [14, 16] diff --git a/lib/octicons_react/icons/terminal.js b/lib/octicons_react/icons/terminal.js new file mode 100644 index 000000000..847033d89 --- /dev/null +++ b/lib/octicons_react/icons/terminal.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function terminal() { + return +} +terminal.size = [14, 16] diff --git a/lib/octicons_react/icons/text-size.js b/lib/octicons_react/icons/text-size.js new file mode 100644 index 000000000..be466a949 --- /dev/null +++ b/lib/octicons_react/icons/text-size.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function textSize() { + return +} +textSize.size = [18, 16] diff --git a/lib/octicons_react/icons/three-bars.js b/lib/octicons_react/icons/three-bars.js new file mode 100644 index 000000000..5d8731a34 --- /dev/null +++ b/lib/octicons_react/icons/three-bars.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function threeBars() { + return +} +threeBars.size = [12, 16] diff --git a/lib/octicons_react/icons/thumbsdown.js b/lib/octicons_react/icons/thumbsdown.js new file mode 100644 index 000000000..7d9bfa780 --- /dev/null +++ b/lib/octicons_react/icons/thumbsdown.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function thumbsdown() { + return +} +thumbsdown.size = [16, 16] diff --git a/lib/octicons_react/icons/thumbsup.js b/lib/octicons_react/icons/thumbsup.js new file mode 100644 index 000000000..ee71dc6a2 --- /dev/null +++ b/lib/octicons_react/icons/thumbsup.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function thumbsup() { + return +} +thumbsup.size = [16, 16] diff --git a/lib/octicons_react/icons/tools.js b/lib/octicons_react/icons/tools.js new file mode 100644 index 000000000..c3a020662 --- /dev/null +++ b/lib/octicons_react/icons/tools.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function tools() { + return +} +tools.size = [16, 16] diff --git a/lib/octicons_react/icons/trashcan.js b/lib/octicons_react/icons/trashcan.js new file mode 100644 index 000000000..79dd009a4 --- /dev/null +++ b/lib/octicons_react/icons/trashcan.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function trashcan() { + return +} +trashcan.size = [12, 16] diff --git a/lib/octicons_react/icons/triangle-down.js b/lib/octicons_react/icons/triangle-down.js new file mode 100644 index 000000000..2d2dbec7c --- /dev/null +++ b/lib/octicons_react/icons/triangle-down.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function triangleDown() { + return +} +triangleDown.size = [12, 16] diff --git a/lib/octicons_react/icons/triangle-left.js b/lib/octicons_react/icons/triangle-left.js new file mode 100644 index 000000000..e1e47ef48 --- /dev/null +++ b/lib/octicons_react/icons/triangle-left.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function triangleLeft() { + return +} +triangleLeft.size = [6, 16] diff --git a/lib/octicons_react/icons/triangle-right.js b/lib/octicons_react/icons/triangle-right.js new file mode 100644 index 000000000..bd00aa6c4 --- /dev/null +++ b/lib/octicons_react/icons/triangle-right.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function triangleRight() { + return +} +triangleRight.size = [6, 16] diff --git a/lib/octicons_react/icons/triangle-up.js b/lib/octicons_react/icons/triangle-up.js new file mode 100644 index 000000000..6661cb815 --- /dev/null +++ b/lib/octicons_react/icons/triangle-up.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function triangleUp() { + return +} +triangleUp.size = [12, 16] diff --git a/lib/octicons_react/icons/unfold.js b/lib/octicons_react/icons/unfold.js new file mode 100644 index 000000000..e241716b5 --- /dev/null +++ b/lib/octicons_react/icons/unfold.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function unfold() { + return +} +unfold.size = [14, 16] diff --git a/lib/octicons_react/icons/unmute.js b/lib/octicons_react/icons/unmute.js new file mode 100644 index 000000000..0f3ca9f88 --- /dev/null +++ b/lib/octicons_react/icons/unmute.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function unmute() { + return +} +unmute.size = [16, 16] diff --git a/lib/octicons_react/icons/unverified.js b/lib/octicons_react/icons/unverified.js new file mode 100644 index 000000000..d989ffdda --- /dev/null +++ b/lib/octicons_react/icons/unverified.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function unverified() { + return +} +unverified.size = [16, 16] diff --git a/lib/octicons_react/icons/verified.js b/lib/octicons_react/icons/verified.js new file mode 100644 index 000000000..91d957710 --- /dev/null +++ b/lib/octicons_react/icons/verified.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function verified() { + return +} +verified.size = [16, 16] diff --git a/lib/octicons_react/icons/versions.js b/lib/octicons_react/icons/versions.js new file mode 100644 index 000000000..aa8eaab34 --- /dev/null +++ b/lib/octicons_react/icons/versions.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function versions() { + return +} +versions.size = [14, 16] diff --git a/lib/octicons_react/icons/watch.js b/lib/octicons_react/icons/watch.js new file mode 100644 index 000000000..062a88c74 --- /dev/null +++ b/lib/octicons_react/icons/watch.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function watch() { + return +} +watch.size = [12, 16] diff --git a/lib/octicons_react/icons/x.js b/lib/octicons_react/icons/x.js new file mode 100644 index 000000000..d01bc7865 --- /dev/null +++ b/lib/octicons_react/icons/x.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function x() { + return +} +x.size = [12, 16] diff --git a/lib/octicons_react/icons/zap.js b/lib/octicons_react/icons/zap.js new file mode 100644 index 000000000..15b614018 --- /dev/null +++ b/lib/octicons_react/icons/zap.js @@ -0,0 +1,5 @@ +import React from 'react' +export default function zap() { + return +} +zap.size = [10, 16] diff --git a/lib/octicons_react/index.js b/lib/octicons_react/index.js new file mode 100644 index 000000000..488986bb5 --- /dev/null +++ b/lib/octicons_react/index.js @@ -0,0 +1,60 @@ +import React from 'react' +import PropTypes from 'prop-types' + +const sizeMap = { + medium: 32, + large: 64 +} + +const alignMap = { + top: 'text-top', + middle: 'middle' +} + +export default function Octicon(props) { + const { + ariaLabel, + children, + icon, + size, + verticalAlign, + ...rest + } = props + + const child = (typeof icon === 'function') + ? + : React.Children.only(children) + + const [width, height] = child.type.size || [16, 16] + const attrs = { + ariaLabel, + role: 'img', + height: height + } + + if (size in sizeMap) { + attrs.height = sizeMap[size] + } + + attrs.width = attrs.height * width / height + + const alignment = alignMap[verticalAlign] || 'text-bottom' + + attrs.style = { + display: 'inline-block', + fill: 'currentColor', + verticalAlign: alignment + } + + return {child} +} + +Octicon.propTypes = { + ariaLabel: PropTypes.string, + children: PropTypes.element, + icon: PropTypes.func, + size: PropTypes.oneOf(['medium', 'large']), + verticalAlign: PropTypes.oneOf([ + 'middle', 'text-bottom', 'text-top', 'top' + ]) +} diff --git a/lib/octicons_react/package.json b/lib/octicons_react/package.json index c5c8f5250..9e2596ca8 100644 --- a/lib/octicons_react/package.json +++ b/lib/octicons_react/package.json @@ -5,16 +5,16 @@ "homepage": "https://octicons.github.com", "author": "GitHub Inc.", "license": "MIT", - "main": "build/index.js", + "main": "index.js", "repository": "https://github.com/primer/octicons.git", "files": [ - "build", - "named.js" + "index.js", + "icons" ], "scripts": { "publish": "../../script/notify success", "prepublishOnly": "../../script/notify pending", - "prepare": "node script/build.js" + "prepare": "script/build.js" }, "bugs": { "url": "https://github.com/primer/octicons/issues" @@ -40,7 +40,7 @@ "babel-cli": "^6.26.0", "babel-preset-env": "^1.6.1", "babel-preset-react": "^6.24.1", - "lodash": "^4.17.5", + "fs-extra": "^6.0.1", "octicons": "7.2.0" } } diff --git a/lib/octicons_react/script/build.js b/lib/octicons_react/script/build.js old mode 100644 new mode 100755 index f71e59bca..9eeb31545 --- a/lib/octicons_react/script/build.js +++ b/lib/octicons_react/script/build.js @@ -1,174 +1,36 @@ -'use strict'; +#!/usr/bin/env node +const octicons = require('octicons') +const fse = require('fs-extra') +const {join} = require('path') -const transform = require('babel-core').transform; -const octicons = require('octicons'); -const fs = require('fs-extra'); -const path = require('path'); -const lodash = require('lodash') +const DIR = 'icons' -const BUILD_PATH = path.join(__dirname, '..', 'build'); - -fs.emptyDirSync(BUILD_PATH) - -// Transform code with babel -const getTransformedSourceCode = (originalSource) => transform(originalSource, { - presets: [ 'env', 'react' ] -}).code; - -/** - * Template: React components - */ -const getReactSource = ({ componentName, options, svgPaths }) => { - let m = [] - while ((m = /\s([a-z]*\-[a-z]*)=/gi.exec(svgPaths)) != null) { - let mat = m.pop() - svgPaths = svgPaths.replace(mat, lodash.camelCase(mat)) - } - return getTransformedSourceCode(` -import createIconComponent from '../utils/createIconComponent'; -import React from 'react'; -const ${componentName} = createIconComponent({ content: ${svgPaths}, options: ${options} }); -${componentName}.displayName = '${componentName}'; -export default ${componentName}; -`); -} - -/** - * Template: createIconComponent - */ -const getCreateIconSource = () => getTransformedSourceCode(` -import React from "react"; - -const createIconComponent = ({ content, options }) => { - - const prepare = props => { - const { ariaLabel, medium, large } = props; - const attributes = Object.assign({}, options) - - // Default octicon sizes to small - attributes["height"] = 16; - - // Read in small, medium, large props - if (medium) { - attributes["height"] = 32; - } else if (large) { - attributes["height"] = 64; - } - - // Calculate the width based on height - attributes["width"] = - attributes["height"] * options["width"] / options["height"]; - - // If the user passed in aria-label - if (ariaLabel) { - attributes["aria-label"] = ariaLabel; - attributes["role"] = "img"; - - // Un-hide the icon - delete attributes["aria-hidden"]; - } - - return attributes; - }; - - const alignment = props => { - const { top, middle } = props; - - if (top) { - return "text-top"; - } else if (middle) { - return "middle"; - } - return "text-bottom"; - }; - - return (props) => { - const svgStyle = { - display: "inline-block", - fill: "currentColor", - verticalAlign: alignment(props), - userSelect: "none" - }; - - return ( - - {content} - - ) - } +function camelCase(str) { + return str.replace(/-([a-z])/g, (_, c) => c.toUpperCase()) } -export default createIconComponent; -`); - -/** - * Template: getIconNamedSource - */ -const getIconNamedSource = () => { - return getTransformedSourceCode(Object.values(octicons).map((octicon) => { - const { name } = octicon; - const componentName = `${lodash.upperFirst(lodash.camelCase(name))}Octicon`; - return `export const ${componentName} = require('./build/icons/${name}.js').default;` - }).join('\n') + - `export default "Error: To import all octicons, try require('@github/octicons-react')"`) +const icons = [...Object.entries(octicons)] + .map(([key, octicon]) => { + const name = camelCase(key) + const {width, height, path} = octicon + const code = `import React from 'react' +export default function ${name}() { + return ${path} } +${name}.size = [${width}, ${height}] +` -/** - * Template: getPackageIndexSource - */ -const getPackageIndexSource = () => { - const icons = Object.values(octicons).map((octicon) => { - const { name } = octicon; - const componentName = `${lodash.upperFirst(lodash.camelCase(name))}Octicon`; - return `octicons['${name}'] = require('./icons/${name}.js').default;` - }) - return getTransformedSourceCode(` - import React from 'react'; - let octicons = {}; - ${icons.join('\n')} - export default class Octicon extends React.Component { - render() { - const { name } = this.props; - const Octicon = octicons[name]; - if (Octicon) { - return ( - - ) - } else { - throw new Error('No such octicon: "' + name + '!'); - } - } + return { + key, + octicon, + code } - `) -} - -const files = Object.values(octicons).map((octicon) => { - const { name, options, path } = octicon; - const componentName = `${lodash.upperFirst(lodash.camelCase(name))}Octicon`; - delete options["class"]; - return { - filepath: `icons/${name}.js`, - source: getReactSource({componentName: componentName, options: JSON.stringify(options), svgPaths: path}) - } -}) - -files.push({ - filepath: 'utils/createIconComponent.js', - source: getCreateIconSource() -}) - -files.push({ - filepath: 'index.js', - source: getPackageIndexSource() -}) + }) -files.push({ - filepath: '../named.js', - source: getIconNamedSource() +const tasks = icons.map(({key, code}) => { + return fse.writeFile(join(DIR, key + '.js'), code, 'utf8') }) -files.forEach((file) => { - fs.outputFile(path.join(BUILD_PATH, file.filepath), file.source); +Promise.all(tasks).then(() => { + console.warn('wrote %d files to %s.', tasks.length, DIR) }) From 88e952f96e5f35f43f9366b4f441b1f2f4abea57 Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Fri, 8 Jun 2018 11:49:31 -0700 Subject: [PATCH 24/97] UpperCase all the things --- lib/octicons_react/icons/alert.js | 4 +- lib/octicons_react/icons/arrow-down.js | 4 +- lib/octicons_react/icons/arrow-left.js | 4 +- lib/octicons_react/icons/arrow-right.js | 4 +- lib/octicons_react/icons/arrow-small-down.js | 4 +- lib/octicons_react/icons/arrow-small-left.js | 4 +- lib/octicons_react/icons/arrow-small-right.js | 4 +- lib/octicons_react/icons/arrow-small-up.js | 4 +- lib/octicons_react/icons/arrow-up.js | 4 +- lib/octicons_react/icons/beaker.js | 4 +- lib/octicons_react/icons/bell.js | 4 +- lib/octicons_react/icons/bold.js | 4 +- lib/octicons_react/icons/book.js | 4 +- lib/octicons_react/icons/bookmark.js | 4 +- lib/octicons_react/icons/briefcase.js | 4 +- lib/octicons_react/icons/broadcast.js | 4 +- lib/octicons_react/icons/browser.js | 4 +- lib/octicons_react/icons/bug.js | 4 +- lib/octicons_react/icons/calendar.js | 4 +- lib/octicons_react/icons/check.js | 4 +- lib/octicons_react/icons/checklist.js | 4 +- lib/octicons_react/icons/chevron-down.js | 4 +- lib/octicons_react/icons/chevron-left.js | 4 +- lib/octicons_react/icons/chevron-right.js | 4 +- lib/octicons_react/icons/chevron-up.js | 4 +- lib/octicons_react/icons/circle-slash.js | 4 +- lib/octicons_react/icons/circuit-board.js | 4 +- lib/octicons_react/icons/clippy.js | 4 +- lib/octicons_react/icons/clock.js | 4 +- lib/octicons_react/icons/cloud-download.js | 4 +- lib/octicons_react/icons/cloud-upload.js | 4 +- lib/octicons_react/icons/code.js | 4 +- .../icons/comment-discussion.js | 4 +- lib/octicons_react/icons/comment.js | 4 +- lib/octicons_react/icons/credit-card.js | 4 +- lib/octicons_react/icons/dash.js | 4 +- lib/octicons_react/icons/dashboard.js | 4 +- lib/octicons_react/icons/database.js | 4 +- lib/octicons_react/icons/desktop-download.js | 4 +- .../icons/device-camera-video.js | 4 +- lib/octicons_react/icons/device-camera.js | 4 +- lib/octicons_react/icons/device-desktop.js | 4 +- lib/octicons_react/icons/device-mobile.js | 4 +- lib/octicons_react/icons/diff-added.js | 4 +- lib/octicons_react/icons/diff-ignored.js | 4 +- lib/octicons_react/icons/diff-modified.js | 4 +- lib/octicons_react/icons/diff-removed.js | 4 +- lib/octicons_react/icons/diff-renamed.js | 4 +- lib/octicons_react/icons/diff.js | 4 +- lib/octicons_react/icons/ellipsis.js | 4 +- lib/octicons_react/icons/eye.js | 4 +- lib/octicons_react/icons/file-binary.js | 4 +- lib/octicons_react/icons/file-code.js | 4 +- lib/octicons_react/icons/file-directory.js | 4 +- lib/octicons_react/icons/file-media.js | 4 +- lib/octicons_react/icons/file-pdf.js | 4 +- lib/octicons_react/icons/file-submodule.js | 4 +- .../icons/file-symlink-directory.js | 4 +- lib/octicons_react/icons/file-symlink-file.js | 4 +- lib/octicons_react/icons/file-zip.js | 4 +- lib/octicons_react/icons/file.js | 4 +- lib/octicons_react/icons/flame.js | 4 +- lib/octicons_react/icons/fold.js | 4 +- lib/octicons_react/icons/gear.js | 4 +- lib/octicons_react/icons/gift.js | 4 +- lib/octicons_react/icons/gist-secret.js | 4 +- lib/octicons_react/icons/gist.js | 4 +- lib/octicons_react/icons/git-branch.js | 4 +- lib/octicons_react/icons/git-commit.js | 4 +- lib/octicons_react/icons/git-compare.js | 4 +- lib/octicons_react/icons/git-merge.js | 4 +- lib/octicons_react/icons/git-pull-request.js | 4 +- lib/octicons_react/icons/globe.js | 4 +- lib/octicons_react/icons/grabber.js | 4 +- lib/octicons_react/icons/graph.js | 4 +- lib/octicons_react/icons/heart.js | 4 +- lib/octicons_react/icons/history.js | 4 +- lib/octicons_react/icons/home.js | 4 +- lib/octicons_react/icons/horizontal-rule.js | 4 +- lib/octicons_react/icons/hubot.js | 4 +- lib/octicons_react/icons/inbox.js | 4 +- lib/octicons_react/icons/index.js | 176 ++++++++++++++++++ lib/octicons_react/icons/info.js | 4 +- lib/octicons_react/icons/issue-closed.js | 4 +- lib/octicons_react/icons/issue-opened.js | 4 +- lib/octicons_react/icons/issue-reopened.js | 4 +- lib/octicons_react/icons/italic.js | 4 +- lib/octicons_react/icons/jersey.js | 4 +- lib/octicons_react/icons/kebab-horizontal.js | 4 +- lib/octicons_react/icons/kebab-vertical.js | 4 +- lib/octicons_react/icons/key.js | 4 +- lib/octicons_react/icons/keyboard.js | 4 +- lib/octicons_react/icons/law.js | 4 +- lib/octicons_react/icons/light-bulb.js | 4 +- lib/octicons_react/icons/link-external.js | 4 +- lib/octicons_react/icons/link.js | 4 +- lib/octicons_react/icons/list-ordered.js | 4 +- lib/octicons_react/icons/list-unordered.js | 4 +- lib/octicons_react/icons/location.js | 4 +- lib/octicons_react/icons/lock.js | 4 +- lib/octicons_react/icons/logo-gist.js | 4 +- lib/octicons_react/icons/logo-github.js | 4 +- lib/octicons_react/icons/mail-read.js | 4 +- lib/octicons_react/icons/mail.js | 4 +- lib/octicons_react/icons/mark-github.js | 4 +- lib/octicons_react/icons/markdown.js | 4 +- lib/octicons_react/icons/megaphone.js | 4 +- lib/octicons_react/icons/mention.js | 4 +- lib/octicons_react/icons/milestone.js | 4 +- lib/octicons_react/icons/mirror.js | 4 +- lib/octicons_react/icons/mortar-board.js | 4 +- lib/octicons_react/icons/mute.js | 4 +- lib/octicons_react/icons/no-newline.js | 4 +- lib/octicons_react/icons/note.js | 4 +- lib/octicons_react/icons/octoface.js | 4 +- lib/octicons_react/icons/organization.js | 4 +- lib/octicons_react/icons/package.js | 4 +- lib/octicons_react/icons/paintcan.js | 4 +- lib/octicons_react/icons/pencil.js | 4 +- lib/octicons_react/icons/person.js | 4 +- lib/octicons_react/icons/pin.js | 4 +- lib/octicons_react/icons/plug.js | 4 +- lib/octicons_react/icons/plus-small.js | 4 +- lib/octicons_react/icons/plus.js | 4 +- lib/octicons_react/icons/primitive-dot.js | 4 +- lib/octicons_react/icons/primitive-square.js | 4 +- lib/octicons_react/icons/project.js | 4 +- lib/octicons_react/icons/pulse.js | 4 +- lib/octicons_react/icons/question.js | 4 +- lib/octicons_react/icons/quote.js | 4 +- lib/octicons_react/icons/radio-tower.js | 4 +- lib/octicons_react/icons/reply.js | 4 +- lib/octicons_react/icons/repo-clone.js | 4 +- lib/octicons_react/icons/repo-force-push.js | 4 +- lib/octicons_react/icons/repo-forked.js | 4 +- lib/octicons_react/icons/repo-pull.js | 4 +- lib/octicons_react/icons/repo-push.js | 4 +- lib/octicons_react/icons/repo.js | 4 +- lib/octicons_react/icons/report.js | 4 +- lib/octicons_react/icons/rocket.js | 4 +- lib/octicons_react/icons/rss.js | 4 +- lib/octicons_react/icons/ruby.js | 4 +- lib/octicons_react/icons/screen-full.js | 4 +- lib/octicons_react/icons/screen-normal.js | 4 +- lib/octicons_react/icons/search.js | 4 +- lib/octicons_react/icons/server.js | 4 +- lib/octicons_react/icons/settings.js | 4 +- lib/octicons_react/icons/shield.js | 4 +- lib/octicons_react/icons/sign-in.js | 4 +- lib/octicons_react/icons/sign-out.js | 4 +- lib/octicons_react/icons/smiley.js | 4 +- lib/octicons_react/icons/squirrel.js | 4 +- lib/octicons_react/icons/star.js | 4 +- lib/octicons_react/icons/stop.js | 4 +- lib/octicons_react/icons/sync.js | 4 +- lib/octicons_react/icons/tag.js | 4 +- lib/octicons_react/icons/tasklist.js | 4 +- lib/octicons_react/icons/telescope.js | 4 +- lib/octicons_react/icons/terminal.js | 4 +- lib/octicons_react/icons/text-size.js | 4 +- lib/octicons_react/icons/three-bars.js | 4 +- lib/octicons_react/icons/thumbsdown.js | 4 +- lib/octicons_react/icons/thumbsup.js | 4 +- lib/octicons_react/icons/tools.js | 4 +- lib/octicons_react/icons/trashcan.js | 4 +- lib/octicons_react/icons/triangle-down.js | 4 +- lib/octicons_react/icons/triangle-left.js | 4 +- lib/octicons_react/icons/triangle-right.js | 4 +- lib/octicons_react/icons/triangle-up.js | 4 +- lib/octicons_react/icons/unfold.js | 4 +- lib/octicons_react/icons/unmute.js | 4 +- lib/octicons_react/icons/unverified.js | 4 +- lib/octicons_react/icons/verified.js | 4 +- lib/octicons_react/icons/versions.js | 4 +- lib/octicons_react/icons/watch.js | 4 +- lib/octicons_react/icons/x.js | 4 +- lib/octicons_react/icons/zap.js | 4 +- lib/octicons_react/script/build.js | 26 ++- 178 files changed, 547 insertions(+), 359 deletions(-) create mode 100644 lib/octicons_react/icons/index.js diff --git a/lib/octicons_react/icons/alert.js b/lib/octicons_react/icons/alert.js index d9d246e56..0316b1ce9 100644 --- a/lib/octicons_react/icons/alert.js +++ b/lib/octicons_react/icons/alert.js @@ -1,5 +1,5 @@ import React from 'react' -export default function alert() { +export default function Alert() { return } -alert.size = [16, 16] +Alert.size = [16, 16] diff --git a/lib/octicons_react/icons/arrow-down.js b/lib/octicons_react/icons/arrow-down.js index 77d5c5905..94a4db708 100644 --- a/lib/octicons_react/icons/arrow-down.js +++ b/lib/octicons_react/icons/arrow-down.js @@ -1,5 +1,5 @@ import React from 'react' -export default function arrowDown() { +export default function ArrowDown() { return } -arrowDown.size = [10, 16] +ArrowDown.size = [10, 16] diff --git a/lib/octicons_react/icons/arrow-left.js b/lib/octicons_react/icons/arrow-left.js index 3e891e23d..d5898d391 100644 --- a/lib/octicons_react/icons/arrow-left.js +++ b/lib/octicons_react/icons/arrow-left.js @@ -1,5 +1,5 @@ import React from 'react' -export default function arrowLeft() { +export default function ArrowLeft() { return } -arrowLeft.size = [10, 16] +ArrowLeft.size = [10, 16] diff --git a/lib/octicons_react/icons/arrow-right.js b/lib/octicons_react/icons/arrow-right.js index 9f13d6144..cf91d224d 100644 --- a/lib/octicons_react/icons/arrow-right.js +++ b/lib/octicons_react/icons/arrow-right.js @@ -1,5 +1,5 @@ import React from 'react' -export default function arrowRight() { +export default function ArrowRight() { return } -arrowRight.size = [10, 16] +ArrowRight.size = [10, 16] diff --git a/lib/octicons_react/icons/arrow-small-down.js b/lib/octicons_react/icons/arrow-small-down.js index 5a1193a2a..5d67639a2 100644 --- a/lib/octicons_react/icons/arrow-small-down.js +++ b/lib/octicons_react/icons/arrow-small-down.js @@ -1,5 +1,5 @@ import React from 'react' -export default function arrowSmallDown() { +export default function ArrowSmallDown() { return } -arrowSmallDown.size = [6, 16] +ArrowSmallDown.size = [6, 16] diff --git a/lib/octicons_react/icons/arrow-small-left.js b/lib/octicons_react/icons/arrow-small-left.js index 537e6729b..399be002b 100644 --- a/lib/octicons_react/icons/arrow-small-left.js +++ b/lib/octicons_react/icons/arrow-small-left.js @@ -1,5 +1,5 @@ import React from 'react' -export default function arrowSmallLeft() { +export default function ArrowSmallLeft() { return } -arrowSmallLeft.size = [6, 16] +ArrowSmallLeft.size = [6, 16] diff --git a/lib/octicons_react/icons/arrow-small-right.js b/lib/octicons_react/icons/arrow-small-right.js index 306f11779..2cc53478a 100644 --- a/lib/octicons_react/icons/arrow-small-right.js +++ b/lib/octicons_react/icons/arrow-small-right.js @@ -1,5 +1,5 @@ import React from 'react' -export default function arrowSmallRight() { +export default function ArrowSmallRight() { return } -arrowSmallRight.size = [6, 16] +ArrowSmallRight.size = [6, 16] diff --git a/lib/octicons_react/icons/arrow-small-up.js b/lib/octicons_react/icons/arrow-small-up.js index 87a5cc334..efbf0b2c4 100644 --- a/lib/octicons_react/icons/arrow-small-up.js +++ b/lib/octicons_react/icons/arrow-small-up.js @@ -1,5 +1,5 @@ import React from 'react' -export default function arrowSmallUp() { +export default function ArrowSmallUp() { return } -arrowSmallUp.size = [6, 16] +ArrowSmallUp.size = [6, 16] diff --git a/lib/octicons_react/icons/arrow-up.js b/lib/octicons_react/icons/arrow-up.js index 63b96fcb9..b017291c5 100644 --- a/lib/octicons_react/icons/arrow-up.js +++ b/lib/octicons_react/icons/arrow-up.js @@ -1,5 +1,5 @@ import React from 'react' -export default function arrowUp() { +export default function ArrowUp() { return } -arrowUp.size = [10, 16] +ArrowUp.size = [10, 16] diff --git a/lib/octicons_react/icons/beaker.js b/lib/octicons_react/icons/beaker.js index 695380294..9f1f430ac 100644 --- a/lib/octicons_react/icons/beaker.js +++ b/lib/octicons_react/icons/beaker.js @@ -1,5 +1,5 @@ import React from 'react' -export default function beaker() { +export default function Beaker() { return } -beaker.size = [16, 16] +Beaker.size = [16, 16] diff --git a/lib/octicons_react/icons/bell.js b/lib/octicons_react/icons/bell.js index e3e0ac254..c4a6282bd 100644 --- a/lib/octicons_react/icons/bell.js +++ b/lib/octicons_react/icons/bell.js @@ -1,5 +1,5 @@ import React from 'react' -export default function bell() { +export default function Bell() { return } -bell.size = [14, 16] +Bell.size = [14, 16] diff --git a/lib/octicons_react/icons/bold.js b/lib/octicons_react/icons/bold.js index aa839c9be..ad3f6893a 100644 --- a/lib/octicons_react/icons/bold.js +++ b/lib/octicons_react/icons/bold.js @@ -1,5 +1,5 @@ import React from 'react' -export default function bold() { +export default function Bold() { return } -bold.size = [10, 16] +Bold.size = [10, 16] diff --git a/lib/octicons_react/icons/book.js b/lib/octicons_react/icons/book.js index 0503debb7..0897e677a 100644 --- a/lib/octicons_react/icons/book.js +++ b/lib/octicons_react/icons/book.js @@ -1,5 +1,5 @@ import React from 'react' -export default function book() { +export default function Book() { return } -book.size = [16, 16] +Book.size = [16, 16] diff --git a/lib/octicons_react/icons/bookmark.js b/lib/octicons_react/icons/bookmark.js index 6aa5db36b..0f9fe0665 100644 --- a/lib/octicons_react/icons/bookmark.js +++ b/lib/octicons_react/icons/bookmark.js @@ -1,5 +1,5 @@ import React from 'react' -export default function bookmark() { +export default function Bookmark() { return } -bookmark.size = [10, 16] +Bookmark.size = [10, 16] diff --git a/lib/octicons_react/icons/briefcase.js b/lib/octicons_react/icons/briefcase.js index 7719a1d64..760947053 100644 --- a/lib/octicons_react/icons/briefcase.js +++ b/lib/octicons_react/icons/briefcase.js @@ -1,5 +1,5 @@ import React from 'react' -export default function briefcase() { +export default function Briefcase() { return } -briefcase.size = [14, 16] +Briefcase.size = [14, 16] diff --git a/lib/octicons_react/icons/broadcast.js b/lib/octicons_react/icons/broadcast.js index 535224b17..a8cf1d4b6 100644 --- a/lib/octicons_react/icons/broadcast.js +++ b/lib/octicons_react/icons/broadcast.js @@ -1,5 +1,5 @@ import React from 'react' -export default function broadcast() { +export default function Broadcast() { return } -broadcast.size = [16, 16] +Broadcast.size = [16, 16] diff --git a/lib/octicons_react/icons/browser.js b/lib/octicons_react/icons/browser.js index b161256e7..325682778 100644 --- a/lib/octicons_react/icons/browser.js +++ b/lib/octicons_react/icons/browser.js @@ -1,5 +1,5 @@ import React from 'react' -export default function browser() { +export default function Browser() { return } -browser.size = [14, 16] +Browser.size = [14, 16] diff --git a/lib/octicons_react/icons/bug.js b/lib/octicons_react/icons/bug.js index 335af5a46..80f9e16b8 100644 --- a/lib/octicons_react/icons/bug.js +++ b/lib/octicons_react/icons/bug.js @@ -1,5 +1,5 @@ import React from 'react' -export default function bug() { +export default function Bug() { return } -bug.size = [16, 16] +Bug.size = [16, 16] diff --git a/lib/octicons_react/icons/calendar.js b/lib/octicons_react/icons/calendar.js index 498099be9..17de83d2a 100644 --- a/lib/octicons_react/icons/calendar.js +++ b/lib/octicons_react/icons/calendar.js @@ -1,5 +1,5 @@ import React from 'react' -export default function calendar() { +export default function Calendar() { return } -calendar.size = [14, 16] +Calendar.size = [14, 16] diff --git a/lib/octicons_react/icons/check.js b/lib/octicons_react/icons/check.js index 805c4b723..476f14ffe 100644 --- a/lib/octicons_react/icons/check.js +++ b/lib/octicons_react/icons/check.js @@ -1,5 +1,5 @@ import React from 'react' -export default function check() { +export default function Check() { return } -check.size = [12, 16] +Check.size = [12, 16] diff --git a/lib/octicons_react/icons/checklist.js b/lib/octicons_react/icons/checklist.js index 64d7eef0d..995119db3 100644 --- a/lib/octicons_react/icons/checklist.js +++ b/lib/octicons_react/icons/checklist.js @@ -1,5 +1,5 @@ import React from 'react' -export default function checklist() { +export default function Checklist() { return } -checklist.size = [16, 16] +Checklist.size = [16, 16] diff --git a/lib/octicons_react/icons/chevron-down.js b/lib/octicons_react/icons/chevron-down.js index f5821b93c..f9f57a2ba 100644 --- a/lib/octicons_react/icons/chevron-down.js +++ b/lib/octicons_react/icons/chevron-down.js @@ -1,5 +1,5 @@ import React from 'react' -export default function chevronDown() { +export default function ChevronDown() { return } -chevronDown.size = [10, 16] +ChevronDown.size = [10, 16] diff --git a/lib/octicons_react/icons/chevron-left.js b/lib/octicons_react/icons/chevron-left.js index b2587dfce..451634d7b 100644 --- a/lib/octicons_react/icons/chevron-left.js +++ b/lib/octicons_react/icons/chevron-left.js @@ -1,5 +1,5 @@ import React from 'react' -export default function chevronLeft() { +export default function ChevronLeft() { return } -chevronLeft.size = [8, 16] +ChevronLeft.size = [8, 16] diff --git a/lib/octicons_react/icons/chevron-right.js b/lib/octicons_react/icons/chevron-right.js index 6edaabe02..7d0aee4c6 100644 --- a/lib/octicons_react/icons/chevron-right.js +++ b/lib/octicons_react/icons/chevron-right.js @@ -1,5 +1,5 @@ import React from 'react' -export default function chevronRight() { +export default function ChevronRight() { return } -chevronRight.size = [8, 16] +ChevronRight.size = [8, 16] diff --git a/lib/octicons_react/icons/chevron-up.js b/lib/octicons_react/icons/chevron-up.js index 1809ed0c4..3eab3daf9 100644 --- a/lib/octicons_react/icons/chevron-up.js +++ b/lib/octicons_react/icons/chevron-up.js @@ -1,5 +1,5 @@ import React from 'react' -export default function chevronUp() { +export default function ChevronUp() { return } -chevronUp.size = [10, 16] +ChevronUp.size = [10, 16] diff --git a/lib/octicons_react/icons/circle-slash.js b/lib/octicons_react/icons/circle-slash.js index 2df0fc130..ae418669e 100644 --- a/lib/octicons_react/icons/circle-slash.js +++ b/lib/octicons_react/icons/circle-slash.js @@ -1,5 +1,5 @@ import React from 'react' -export default function circleSlash() { +export default function CircleSlash() { return } -circleSlash.size = [14, 16] +CircleSlash.size = [14, 16] diff --git a/lib/octicons_react/icons/circuit-board.js b/lib/octicons_react/icons/circuit-board.js index b362a450b..125dc4f6c 100644 --- a/lib/octicons_react/icons/circuit-board.js +++ b/lib/octicons_react/icons/circuit-board.js @@ -1,5 +1,5 @@ import React from 'react' -export default function circuitBoard() { +export default function CircuitBoard() { return } -circuitBoard.size = [14, 16] +CircuitBoard.size = [14, 16] diff --git a/lib/octicons_react/icons/clippy.js b/lib/octicons_react/icons/clippy.js index 4c672cf22..bd94bbc51 100644 --- a/lib/octicons_react/icons/clippy.js +++ b/lib/octicons_react/icons/clippy.js @@ -1,5 +1,5 @@ import React from 'react' -export default function clippy() { +export default function Clippy() { return } -clippy.size = [14, 16] +Clippy.size = [14, 16] diff --git a/lib/octicons_react/icons/clock.js b/lib/octicons_react/icons/clock.js index 177f284f7..8554c248f 100644 --- a/lib/octicons_react/icons/clock.js +++ b/lib/octicons_react/icons/clock.js @@ -1,5 +1,5 @@ import React from 'react' -export default function clock() { +export default function Clock() { return } -clock.size = [14, 16] +Clock.size = [14, 16] diff --git a/lib/octicons_react/icons/cloud-download.js b/lib/octicons_react/icons/cloud-download.js index e4a9e4570..01dfa4844 100644 --- a/lib/octicons_react/icons/cloud-download.js +++ b/lib/octicons_react/icons/cloud-download.js @@ -1,5 +1,5 @@ import React from 'react' -export default function cloudDownload() { +export default function CloudDownload() { return } -cloudDownload.size = [16, 16] +CloudDownload.size = [16, 16] diff --git a/lib/octicons_react/icons/cloud-upload.js b/lib/octicons_react/icons/cloud-upload.js index 08bd4202d..ff5cb3cee 100644 --- a/lib/octicons_react/icons/cloud-upload.js +++ b/lib/octicons_react/icons/cloud-upload.js @@ -1,5 +1,5 @@ import React from 'react' -export default function cloudUpload() { +export default function CloudUpload() { return } -cloudUpload.size = [16, 16] +CloudUpload.size = [16, 16] diff --git a/lib/octicons_react/icons/code.js b/lib/octicons_react/icons/code.js index 8073f7ade..01b88d8fb 100644 --- a/lib/octicons_react/icons/code.js +++ b/lib/octicons_react/icons/code.js @@ -1,5 +1,5 @@ import React from 'react' -export default function code() { +export default function Code() { return } -code.size = [14, 16] +Code.size = [14, 16] diff --git a/lib/octicons_react/icons/comment-discussion.js b/lib/octicons_react/icons/comment-discussion.js index 5717347bb..cfcfbfcc1 100644 --- a/lib/octicons_react/icons/comment-discussion.js +++ b/lib/octicons_react/icons/comment-discussion.js @@ -1,5 +1,5 @@ import React from 'react' -export default function commentDiscussion() { +export default function CommentDiscussion() { return } -commentDiscussion.size = [16, 16] +CommentDiscussion.size = [16, 16] diff --git a/lib/octicons_react/icons/comment.js b/lib/octicons_react/icons/comment.js index a77b2522f..677eed952 100644 --- a/lib/octicons_react/icons/comment.js +++ b/lib/octicons_react/icons/comment.js @@ -1,5 +1,5 @@ import React from 'react' -export default function comment() { +export default function Comment() { return } -comment.size = [16, 16] +Comment.size = [16, 16] diff --git a/lib/octicons_react/icons/credit-card.js b/lib/octicons_react/icons/credit-card.js index d1e761481..e12adb916 100644 --- a/lib/octicons_react/icons/credit-card.js +++ b/lib/octicons_react/icons/credit-card.js @@ -1,5 +1,5 @@ import React from 'react' -export default function creditCard() { +export default function CreditCard() { return } -creditCard.size = [16, 16] +CreditCard.size = [16, 16] diff --git a/lib/octicons_react/icons/dash.js b/lib/octicons_react/icons/dash.js index 2653aede0..9130f660b 100644 --- a/lib/octicons_react/icons/dash.js +++ b/lib/octicons_react/icons/dash.js @@ -1,5 +1,5 @@ import React from 'react' -export default function dash() { +export default function Dash() { return } -dash.size = [8, 16] +Dash.size = [8, 16] diff --git a/lib/octicons_react/icons/dashboard.js b/lib/octicons_react/icons/dashboard.js index 2308ecbc9..a7da612e8 100644 --- a/lib/octicons_react/icons/dashboard.js +++ b/lib/octicons_react/icons/dashboard.js @@ -1,5 +1,5 @@ import React from 'react' -export default function dashboard() { +export default function Dashboard() { return } -dashboard.size = [16, 16] +Dashboard.size = [16, 16] diff --git a/lib/octicons_react/icons/database.js b/lib/octicons_react/icons/database.js index 3a2e91396..a28eb44a1 100644 --- a/lib/octicons_react/icons/database.js +++ b/lib/octicons_react/icons/database.js @@ -1,5 +1,5 @@ import React from 'react' -export default function database() { +export default function Database() { return } -database.size = [12, 16] +Database.size = [12, 16] diff --git a/lib/octicons_react/icons/desktop-download.js b/lib/octicons_react/icons/desktop-download.js index 678d828f4..bde481abb 100644 --- a/lib/octicons_react/icons/desktop-download.js +++ b/lib/octicons_react/icons/desktop-download.js @@ -1,5 +1,5 @@ import React from 'react' -export default function desktopDownload() { +export default function DesktopDownload() { return } -desktopDownload.size = [16, 16] +DesktopDownload.size = [16, 16] diff --git a/lib/octicons_react/icons/device-camera-video.js b/lib/octicons_react/icons/device-camera-video.js index 934790e3e..ea2624ea7 100644 --- a/lib/octicons_react/icons/device-camera-video.js +++ b/lib/octicons_react/icons/device-camera-video.js @@ -1,5 +1,5 @@ import React from 'react' -export default function deviceCameraVideo() { +export default function DeviceCameraVideo() { return } -deviceCameraVideo.size = [16, 16] +DeviceCameraVideo.size = [16, 16] diff --git a/lib/octicons_react/icons/device-camera.js b/lib/octicons_react/icons/device-camera.js index 3cc7a4903..0d7a2cfef 100644 --- a/lib/octicons_react/icons/device-camera.js +++ b/lib/octicons_react/icons/device-camera.js @@ -1,5 +1,5 @@ import React from 'react' -export default function deviceCamera() { +export default function DeviceCamera() { return } -deviceCamera.size = [16, 16] +DeviceCamera.size = [16, 16] diff --git a/lib/octicons_react/icons/device-desktop.js b/lib/octicons_react/icons/device-desktop.js index 900e20087..435e83915 100644 --- a/lib/octicons_react/icons/device-desktop.js +++ b/lib/octicons_react/icons/device-desktop.js @@ -1,5 +1,5 @@ import React from 'react' -export default function deviceDesktop() { +export default function DeviceDesktop() { return } -deviceDesktop.size = [16, 16] +DeviceDesktop.size = [16, 16] diff --git a/lib/octicons_react/icons/device-mobile.js b/lib/octicons_react/icons/device-mobile.js index 8d0e51d12..6a3a1b721 100644 --- a/lib/octicons_react/icons/device-mobile.js +++ b/lib/octicons_react/icons/device-mobile.js @@ -1,5 +1,5 @@ import React from 'react' -export default function deviceMobile() { +export default function DeviceMobile() { return } -deviceMobile.size = [10, 16] +DeviceMobile.size = [10, 16] diff --git a/lib/octicons_react/icons/diff-added.js b/lib/octicons_react/icons/diff-added.js index 15b302a5c..dce7c8ea5 100644 --- a/lib/octicons_react/icons/diff-added.js +++ b/lib/octicons_react/icons/diff-added.js @@ -1,5 +1,5 @@ import React from 'react' -export default function diffAdded() { +export default function DiffAdded() { return } -diffAdded.size = [14, 16] +DiffAdded.size = [14, 16] diff --git a/lib/octicons_react/icons/diff-ignored.js b/lib/octicons_react/icons/diff-ignored.js index 5cbe971b2..aa38d390c 100644 --- a/lib/octicons_react/icons/diff-ignored.js +++ b/lib/octicons_react/icons/diff-ignored.js @@ -1,5 +1,5 @@ import React from 'react' -export default function diffIgnored() { +export default function DiffIgnored() { return } -diffIgnored.size = [14, 16] +DiffIgnored.size = [14, 16] diff --git a/lib/octicons_react/icons/diff-modified.js b/lib/octicons_react/icons/diff-modified.js index 0b5aaf765..0bae6241c 100644 --- a/lib/octicons_react/icons/diff-modified.js +++ b/lib/octicons_react/icons/diff-modified.js @@ -1,5 +1,5 @@ import React from 'react' -export default function diffModified() { +export default function DiffModified() { return } -diffModified.size = [14, 16] +DiffModified.size = [14, 16] diff --git a/lib/octicons_react/icons/diff-removed.js b/lib/octicons_react/icons/diff-removed.js index c1568caae..0489b56cc 100644 --- a/lib/octicons_react/icons/diff-removed.js +++ b/lib/octicons_react/icons/diff-removed.js @@ -1,5 +1,5 @@ import React from 'react' -export default function diffRemoved() { +export default function DiffRemoved() { return } -diffRemoved.size = [14, 16] +DiffRemoved.size = [14, 16] diff --git a/lib/octicons_react/icons/diff-renamed.js b/lib/octicons_react/icons/diff-renamed.js index f905e8f84..34ac7bb8e 100644 --- a/lib/octicons_react/icons/diff-renamed.js +++ b/lib/octicons_react/icons/diff-renamed.js @@ -1,5 +1,5 @@ import React from 'react' -export default function diffRenamed() { +export default function DiffRenamed() { return } -diffRenamed.size = [14, 16] +DiffRenamed.size = [14, 16] diff --git a/lib/octicons_react/icons/diff.js b/lib/octicons_react/icons/diff.js index 9a7f514cd..0ef722230 100644 --- a/lib/octicons_react/icons/diff.js +++ b/lib/octicons_react/icons/diff.js @@ -1,5 +1,5 @@ import React from 'react' -export default function diff() { +export default function Diff() { return } -diff.size = [13, 16] +Diff.size = [13, 16] diff --git a/lib/octicons_react/icons/ellipsis.js b/lib/octicons_react/icons/ellipsis.js index 6f5766557..2c360166f 100644 --- a/lib/octicons_react/icons/ellipsis.js +++ b/lib/octicons_react/icons/ellipsis.js @@ -1,5 +1,5 @@ import React from 'react' -export default function ellipsis() { +export default function Ellipsis() { return } -ellipsis.size = [12, 16] +Ellipsis.size = [12, 16] diff --git a/lib/octicons_react/icons/eye.js b/lib/octicons_react/icons/eye.js index 3f0be72bf..04554f2ba 100644 --- a/lib/octicons_react/icons/eye.js +++ b/lib/octicons_react/icons/eye.js @@ -1,5 +1,5 @@ import React from 'react' -export default function eye() { +export default function Eye() { return } -eye.size = [16, 16] +Eye.size = [16, 16] diff --git a/lib/octicons_react/icons/file-binary.js b/lib/octicons_react/icons/file-binary.js index 33e4b0132..1d509f9d4 100644 --- a/lib/octicons_react/icons/file-binary.js +++ b/lib/octicons_react/icons/file-binary.js @@ -1,5 +1,5 @@ import React from 'react' -export default function fileBinary() { +export default function FileBinary() { return } -fileBinary.size = [12, 16] +FileBinary.size = [12, 16] diff --git a/lib/octicons_react/icons/file-code.js b/lib/octicons_react/icons/file-code.js index 3b23e5779..edead1234 100644 --- a/lib/octicons_react/icons/file-code.js +++ b/lib/octicons_react/icons/file-code.js @@ -1,5 +1,5 @@ import React from 'react' -export default function fileCode() { +export default function FileCode() { return } -fileCode.size = [12, 16] +FileCode.size = [12, 16] diff --git a/lib/octicons_react/icons/file-directory.js b/lib/octicons_react/icons/file-directory.js index 841099bb9..173133d76 100644 --- a/lib/octicons_react/icons/file-directory.js +++ b/lib/octicons_react/icons/file-directory.js @@ -1,5 +1,5 @@ import React from 'react' -export default function fileDirectory() { +export default function FileDirectory() { return } -fileDirectory.size = [14, 16] +FileDirectory.size = [14, 16] diff --git a/lib/octicons_react/icons/file-media.js b/lib/octicons_react/icons/file-media.js index 17ea910c8..5183cae21 100644 --- a/lib/octicons_react/icons/file-media.js +++ b/lib/octicons_react/icons/file-media.js @@ -1,5 +1,5 @@ import React from 'react' -export default function fileMedia() { +export default function FileMedia() { return } -fileMedia.size = [12, 16] +FileMedia.size = [12, 16] diff --git a/lib/octicons_react/icons/file-pdf.js b/lib/octicons_react/icons/file-pdf.js index d0ce79f75..d866ee8dd 100644 --- a/lib/octicons_react/icons/file-pdf.js +++ b/lib/octicons_react/icons/file-pdf.js @@ -1,5 +1,5 @@ import React from 'react' -export default function filePdf() { +export default function FilePdf() { return } -filePdf.size = [12, 16] +FilePdf.size = [12, 16] diff --git a/lib/octicons_react/icons/file-submodule.js b/lib/octicons_react/icons/file-submodule.js index bacf8ff25..1c000131c 100644 --- a/lib/octicons_react/icons/file-submodule.js +++ b/lib/octicons_react/icons/file-submodule.js @@ -1,5 +1,5 @@ import React from 'react' -export default function fileSubmodule() { +export default function FileSubmodule() { return } -fileSubmodule.size = [14, 16] +FileSubmodule.size = [14, 16] diff --git a/lib/octicons_react/icons/file-symlink-directory.js b/lib/octicons_react/icons/file-symlink-directory.js index 77d2fa6ae..11f0fec27 100644 --- a/lib/octicons_react/icons/file-symlink-directory.js +++ b/lib/octicons_react/icons/file-symlink-directory.js @@ -1,5 +1,5 @@ import React from 'react' -export default function fileSymlinkDirectory() { +export default function FileSymlinkDirectory() { return } -fileSymlinkDirectory.size = [14, 16] +FileSymlinkDirectory.size = [14, 16] diff --git a/lib/octicons_react/icons/file-symlink-file.js b/lib/octicons_react/icons/file-symlink-file.js index 0093a8511..b044a26f1 100644 --- a/lib/octicons_react/icons/file-symlink-file.js +++ b/lib/octicons_react/icons/file-symlink-file.js @@ -1,5 +1,5 @@ import React from 'react' -export default function fileSymlinkFile() { +export default function FileSymlinkFile() { return } -fileSymlinkFile.size = [12, 16] +FileSymlinkFile.size = [12, 16] diff --git a/lib/octicons_react/icons/file-zip.js b/lib/octicons_react/icons/file-zip.js index bbdbd6e8a..8c61731c9 100644 --- a/lib/octicons_react/icons/file-zip.js +++ b/lib/octicons_react/icons/file-zip.js @@ -1,5 +1,5 @@ import React from 'react' -export default function fileZip() { +export default function FileZip() { return } -fileZip.size = [12, 16] +FileZip.size = [12, 16] diff --git a/lib/octicons_react/icons/file.js b/lib/octicons_react/icons/file.js index eaa831a77..29b51761d 100644 --- a/lib/octicons_react/icons/file.js +++ b/lib/octicons_react/icons/file.js @@ -1,5 +1,5 @@ import React from 'react' -export default function file() { +export default function File() { return } -file.size = [12, 16] +File.size = [12, 16] diff --git a/lib/octicons_react/icons/flame.js b/lib/octicons_react/icons/flame.js index d7b3dc2de..1e2e059d3 100644 --- a/lib/octicons_react/icons/flame.js +++ b/lib/octicons_react/icons/flame.js @@ -1,5 +1,5 @@ import React from 'react' -export default function flame() { +export default function Flame() { return } -flame.size = [12, 16] +Flame.size = [12, 16] diff --git a/lib/octicons_react/icons/fold.js b/lib/octicons_react/icons/fold.js index 69fe836f0..55136d783 100644 --- a/lib/octicons_react/icons/fold.js +++ b/lib/octicons_react/icons/fold.js @@ -1,5 +1,5 @@ import React from 'react' -export default function fold() { +export default function Fold() { return } -fold.size = [14, 16] +Fold.size = [14, 16] diff --git a/lib/octicons_react/icons/gear.js b/lib/octicons_react/icons/gear.js index 664d6593f..49ae5d43f 100644 --- a/lib/octicons_react/icons/gear.js +++ b/lib/octicons_react/icons/gear.js @@ -1,5 +1,5 @@ import React from 'react' -export default function gear() { +export default function Gear() { return } -gear.size = [14, 16] +Gear.size = [14, 16] diff --git a/lib/octicons_react/icons/gift.js b/lib/octicons_react/icons/gift.js index 7cd2b09d2..8ac766f7a 100644 --- a/lib/octicons_react/icons/gift.js +++ b/lib/octicons_react/icons/gift.js @@ -1,5 +1,5 @@ import React from 'react' -export default function gift() { +export default function Gift() { return } -gift.size = [14, 16] +Gift.size = [14, 16] diff --git a/lib/octicons_react/icons/gist-secret.js b/lib/octicons_react/icons/gist-secret.js index b5582aac0..a15ad0424 100644 --- a/lib/octicons_react/icons/gist-secret.js +++ b/lib/octicons_react/icons/gist-secret.js @@ -1,5 +1,5 @@ import React from 'react' -export default function gistSecret() { +export default function GistSecret() { return } -gistSecret.size = [14, 16] +GistSecret.size = [14, 16] diff --git a/lib/octicons_react/icons/gist.js b/lib/octicons_react/icons/gist.js index 9f7d8deae..4aaeb864d 100644 --- a/lib/octicons_react/icons/gist.js +++ b/lib/octicons_react/icons/gist.js @@ -1,5 +1,5 @@ import React from 'react' -export default function gist() { +export default function Gist() { return } -gist.size = [12, 16] +Gist.size = [12, 16] diff --git a/lib/octicons_react/icons/git-branch.js b/lib/octicons_react/icons/git-branch.js index 00a58b20f..ccb788428 100644 --- a/lib/octicons_react/icons/git-branch.js +++ b/lib/octicons_react/icons/git-branch.js @@ -1,5 +1,5 @@ import React from 'react' -export default function gitBranch() { +export default function GitBranch() { return } -gitBranch.size = [10, 16] +GitBranch.size = [10, 16] diff --git a/lib/octicons_react/icons/git-commit.js b/lib/octicons_react/icons/git-commit.js index 8ecc1df88..1fb31cad6 100644 --- a/lib/octicons_react/icons/git-commit.js +++ b/lib/octicons_react/icons/git-commit.js @@ -1,5 +1,5 @@ import React from 'react' -export default function gitCommit() { +export default function GitCommit() { return } -gitCommit.size = [14, 16] +GitCommit.size = [14, 16] diff --git a/lib/octicons_react/icons/git-compare.js b/lib/octicons_react/icons/git-compare.js index e67e5866c..075eb41a3 100644 --- a/lib/octicons_react/icons/git-compare.js +++ b/lib/octicons_react/icons/git-compare.js @@ -1,5 +1,5 @@ import React from 'react' -export default function gitCompare() { +export default function GitCompare() { return } -gitCompare.size = [14, 16] +GitCompare.size = [14, 16] diff --git a/lib/octicons_react/icons/git-merge.js b/lib/octicons_react/icons/git-merge.js index a6df2e1b1..1465a72bb 100644 --- a/lib/octicons_react/icons/git-merge.js +++ b/lib/octicons_react/icons/git-merge.js @@ -1,5 +1,5 @@ import React from 'react' -export default function gitMerge() { +export default function GitMerge() { return } -gitMerge.size = [12, 16] +GitMerge.size = [12, 16] diff --git a/lib/octicons_react/icons/git-pull-request.js b/lib/octicons_react/icons/git-pull-request.js index 476ff313e..1cf8f67db 100644 --- a/lib/octicons_react/icons/git-pull-request.js +++ b/lib/octicons_react/icons/git-pull-request.js @@ -1,5 +1,5 @@ import React from 'react' -export default function gitPullRequest() { +export default function GitPullRequest() { return } -gitPullRequest.size = [12, 16] +GitPullRequest.size = [12, 16] diff --git a/lib/octicons_react/icons/globe.js b/lib/octicons_react/icons/globe.js index f1222c9dd..92015f566 100644 --- a/lib/octicons_react/icons/globe.js +++ b/lib/octicons_react/icons/globe.js @@ -1,5 +1,5 @@ import React from 'react' -export default function globe() { +export default function Globe() { return } -globe.size = [14, 16] +Globe.size = [14, 16] diff --git a/lib/octicons_react/icons/grabber.js b/lib/octicons_react/icons/grabber.js index 340259926..76a6d995b 100644 --- a/lib/octicons_react/icons/grabber.js +++ b/lib/octicons_react/icons/grabber.js @@ -1,5 +1,5 @@ import React from 'react' -export default function grabber() { +export default function Grabber() { return } -grabber.size = [8, 16] +Grabber.size = [8, 16] diff --git a/lib/octicons_react/icons/graph.js b/lib/octicons_react/icons/graph.js index 610cb5503..890f10175 100644 --- a/lib/octicons_react/icons/graph.js +++ b/lib/octicons_react/icons/graph.js @@ -1,5 +1,5 @@ import React from 'react' -export default function graph() { +export default function Graph() { return } -graph.size = [16, 16] +Graph.size = [16, 16] diff --git a/lib/octicons_react/icons/heart.js b/lib/octicons_react/icons/heart.js index 7f0143511..e966d27ff 100644 --- a/lib/octicons_react/icons/heart.js +++ b/lib/octicons_react/icons/heart.js @@ -1,5 +1,5 @@ import React from 'react' -export default function heart() { +export default function Heart() { return } -heart.size = [12, 16] +Heart.size = [12, 16] diff --git a/lib/octicons_react/icons/history.js b/lib/octicons_react/icons/history.js index 6b65450c6..f798fd3e6 100644 --- a/lib/octicons_react/icons/history.js +++ b/lib/octicons_react/icons/history.js @@ -1,5 +1,5 @@ import React from 'react' -export default function history() { +export default function History() { return } -history.size = [14, 16] +History.size = [14, 16] diff --git a/lib/octicons_react/icons/home.js b/lib/octicons_react/icons/home.js index 2730f288f..0fde82216 100644 --- a/lib/octicons_react/icons/home.js +++ b/lib/octicons_react/icons/home.js @@ -1,5 +1,5 @@ import React from 'react' -export default function home() { +export default function Home() { return } -home.size = [16, 16] +Home.size = [16, 16] diff --git a/lib/octicons_react/icons/horizontal-rule.js b/lib/octicons_react/icons/horizontal-rule.js index e1809214e..1052c55ea 100644 --- a/lib/octicons_react/icons/horizontal-rule.js +++ b/lib/octicons_react/icons/horizontal-rule.js @@ -1,5 +1,5 @@ import React from 'react' -export default function horizontalRule() { +export default function HorizontalRule() { return } -horizontalRule.size = [10, 16] +HorizontalRule.size = [10, 16] diff --git a/lib/octicons_react/icons/hubot.js b/lib/octicons_react/icons/hubot.js index 7e6ae56e8..5389522c9 100644 --- a/lib/octicons_react/icons/hubot.js +++ b/lib/octicons_react/icons/hubot.js @@ -1,5 +1,5 @@ import React from 'react' -export default function hubot() { +export default function Hubot() { return } -hubot.size = [14, 16] +Hubot.size = [14, 16] diff --git a/lib/octicons_react/icons/inbox.js b/lib/octicons_react/icons/inbox.js index c0c7d94f7..dec40fff6 100644 --- a/lib/octicons_react/icons/inbox.js +++ b/lib/octicons_react/icons/inbox.js @@ -1,5 +1,5 @@ import React from 'react' -export default function inbox() { +export default function Inbox() { return } -inbox.size = [14, 16] +Inbox.size = [14, 16] diff --git a/lib/octicons_react/icons/index.js b/lib/octicons_react/icons/index.js new file mode 100644 index 000000000..371393b01 --- /dev/null +++ b/lib/octicons_react/icons/index.js @@ -0,0 +1,176 @@ +export {default as Alert} from './alert' +export {default as ArrowDown} from './arrow-down' +export {default as ArrowLeft} from './arrow-left' +export {default as ArrowRight} from './arrow-right' +export {default as ArrowUp} from './arrow-up' +export {default as ArrowSmallDown} from './arrow-small-down' +export {default as ArrowSmallLeft} from './arrow-small-left' +export {default as ArrowSmallRight} from './arrow-small-right' +export {default as ArrowSmallUp} from './arrow-small-up' +export {default as Beaker} from './beaker' +export {default as Bell} from './bell' +export {default as Bold} from './bold' +export {default as Book} from './book' +export {default as Bookmark} from './bookmark' +export {default as Briefcase} from './briefcase' +export {default as Broadcast} from './broadcast' +export {default as Browser} from './browser' +export {default as Bug} from './bug' +export {default as Calendar} from './calendar' +export {default as Check} from './check' +export {default as Checklist} from './checklist' +export {default as ChevronDown} from './chevron-down' +export {default as ChevronLeft} from './chevron-left' +export {default as ChevronRight} from './chevron-right' +export {default as ChevronUp} from './chevron-up' +export {default as CircleSlash} from './circle-slash' +export {default as CircuitBoard} from './circuit-board' +export {default as Clippy} from './clippy' +export {default as Clock} from './clock' +export {default as CloudDownload} from './cloud-download' +export {default as CloudUpload} from './cloud-upload' +export {default as Code} from './code' +export {default as CommentDiscussion} from './comment-discussion' +export {default as Comment} from './comment' +export {default as CreditCard} from './credit-card' +export {default as Dash} from './dash' +export {default as Dashboard} from './dashboard' +export {default as Database} from './database' +export {default as DesktopDownload} from './desktop-download' +export {default as DeviceCameraVideo} from './device-camera-video' +export {default as DeviceCamera} from './device-camera' +export {default as DeviceDesktop} from './device-desktop' +export {default as DeviceMobile} from './device-mobile' +export {default as DiffAdded} from './diff-added' +export {default as DiffIgnored} from './diff-ignored' +export {default as DiffModified} from './diff-modified' +export {default as DiffRemoved} from './diff-removed' +export {default as DiffRenamed} from './diff-renamed' +export {default as Diff} from './diff' +export {default as Ellipsis} from './ellipsis' +export {default as Eye} from './eye' +export {default as FileBinary} from './file-binary' +export {default as FileCode} from './file-code' +export {default as FileDirectory} from './file-directory' +export {default as FileMedia} from './file-media' +export {default as FilePdf} from './file-pdf' +export {default as FileSubmodule} from './file-submodule' +export {default as FileSymlinkDirectory} from './file-symlink-directory' +export {default as FileSymlinkFile} from './file-symlink-file' +export {default as File} from './file' +export {default as FileZip} from './file-zip' +export {default as Flame} from './flame' +export {default as Fold} from './fold' +export {default as Gear} from './gear' +export {default as Gift} from './gift' +export {default as GistSecret} from './gist-secret' +export {default as Gist} from './gist' +export {default as GitBranch} from './git-branch' +export {default as GitCommit} from './git-commit' +export {default as GitCompare} from './git-compare' +export {default as GitMerge} from './git-merge' +export {default as GitPullRequest} from './git-pull-request' +export {default as Globe} from './globe' +export {default as Graph} from './graph' +export {default as Heart} from './heart' +export {default as History} from './history' +export {default as Home} from './home' +export {default as HorizontalRule} from './horizontal-rule' +export {default as Hubot} from './hubot' +export {default as Inbox} from './inbox' +export {default as Info} from './info' +export {default as IssueClosed} from './issue-closed' +export {default as IssueOpened} from './issue-opened' +export {default as IssueReopened} from './issue-reopened' +export {default as Italic} from './italic' +export {default as Jersey} from './jersey' +export {default as Keyboard} from './keyboard' +export {default as Law} from './law' +export {default as Link} from './link' +export {default as ListOrdered} from './list-ordered' +export {default as ListUnordered} from './list-unordered' +export {default as Location} from './location' +export {default as Lock} from './lock' +export {default as LogoGist} from './logo-gist' +export {default as LogoGithub} from './logo-github' +export {default as MailRead} from './mail-read' +export {default as Reply} from './reply' +export {default as Mail} from './mail' +export {default as MarkGithub} from './mark-github' +export {default as Markdown} from './markdown' +export {default as Megaphone} from './megaphone' +export {default as Mention} from './mention' +export {default as Milestone} from './milestone' +export {default as Mirror} from './mirror' +export {default as MortarBoard} from './mortar-board' +export {default as Mute} from './mute' +export {default as NoNewline} from './no-newline' +export {default as Octoface} from './octoface' +export {default as Organization} from './organization' +export {default as Package} from './package' +export {default as Paintcan} from './paintcan' +export {default as Pencil} from './pencil' +export {default as Person} from './person' +export {default as Pin} from './pin' +export {default as Plug} from './plug' +export {default as Plus} from './plus' +export {default as PrimitiveDot} from './primitive-dot' +export {default as PrimitiveSquare} from './primitive-square' +export {default as Pulse} from './pulse' +export {default as Question} from './question' +export {default as Quote} from './quote' +export {default as RadioTower} from './radio-tower' +export {default as RepoClone} from './repo-clone' +export {default as RepoForcePush} from './repo-force-push' +export {default as RepoForked} from './repo-forked' +export {default as RepoPull} from './repo-pull' +export {default as RepoPush} from './repo-push' +export {default as Repo} from './repo' +export {default as Rocket} from './rocket' +export {default as Rss} from './rss' +export {default as Ruby} from './ruby' +export {default as Search} from './search' +export {default as Server} from './server' +export {default as Settings} from './settings' +export {default as Shield} from './shield' +export {default as SignIn} from './sign-in' +export {default as SignOut} from './sign-out' +export {default as Smiley} from './smiley' +export {default as Squirrel} from './squirrel' +export {default as Star} from './star' +export {default as Stop} from './stop' +export {default as Sync} from './sync' +export {default as Tag} from './tag' +export {default as Tasklist} from './tasklist' +export {default as Telescope} from './telescope' +export {default as Terminal} from './terminal' +export {default as TextSize} from './text-size' +export {default as ThreeBars} from './three-bars' +export {default as Thumbsdown} from './thumbsdown' +export {default as Thumbsup} from './thumbsup' +export {default as Tools} from './tools' +export {default as Trashcan} from './trashcan' +export {default as TriangleDown} from './triangle-down' +export {default as TriangleLeft} from './triangle-left' +export {default as TriangleRight} from './triangle-right' +export {default as TriangleUp} from './triangle-up' +export {default as Unfold} from './unfold' +export {default as Unmute} from './unmute' +export {default as Project} from './project' +export {default as KebabHorizontal} from './kebab-horizontal' +export {default as KebabVertical} from './kebab-vertical' +export {default as Report} from './report' +export {default as Note} from './note' +export {default as ScreenFull} from './screen-full' +export {default as ScreenNormal} from './screen-normal' +export {default as Unverified} from './unverified' +export {default as Verified} from './verified' +export {default as Versions} from './versions' +export {default as Watch} from './watch' +export {default as X} from './x' +export {default as Zap} from './zap' +export {default as Key} from './key' +export {default as Grabber} from './grabber' +export {default as PlusSmall} from './plus-small' +export {default as LightBulb} from './light-bulb' +export {default as LinkExternal} from './link-external' \ No newline at end of file diff --git a/lib/octicons_react/icons/info.js b/lib/octicons_react/icons/info.js index d93a5340d..8e95fdc8d 100644 --- a/lib/octicons_react/icons/info.js +++ b/lib/octicons_react/icons/info.js @@ -1,5 +1,5 @@ import React from 'react' -export default function info() { +export default function Info() { return } -info.size = [14, 16] +Info.size = [14, 16] diff --git a/lib/octicons_react/icons/issue-closed.js b/lib/octicons_react/icons/issue-closed.js index 8044bc008..52694f7ed 100644 --- a/lib/octicons_react/icons/issue-closed.js +++ b/lib/octicons_react/icons/issue-closed.js @@ -1,5 +1,5 @@ import React from 'react' -export default function issueClosed() { +export default function IssueClosed() { return } -issueClosed.size = [16, 16] +IssueClosed.size = [16, 16] diff --git a/lib/octicons_react/icons/issue-opened.js b/lib/octicons_react/icons/issue-opened.js index 435064f3c..e2102adb8 100644 --- a/lib/octicons_react/icons/issue-opened.js +++ b/lib/octicons_react/icons/issue-opened.js @@ -1,5 +1,5 @@ import React from 'react' -export default function issueOpened() { +export default function IssueOpened() { return } -issueOpened.size = [14, 16] +IssueOpened.size = [14, 16] diff --git a/lib/octicons_react/icons/issue-reopened.js b/lib/octicons_react/icons/issue-reopened.js index 72956e486..c7250e6d3 100644 --- a/lib/octicons_react/icons/issue-reopened.js +++ b/lib/octicons_react/icons/issue-reopened.js @@ -1,5 +1,5 @@ import React from 'react' -export default function issueReopened() { +export default function IssueReopened() { return } -issueReopened.size = [14, 16] +IssueReopened.size = [14, 16] diff --git a/lib/octicons_react/icons/italic.js b/lib/octicons_react/icons/italic.js index 522f2b7fe..91f945d19 100644 --- a/lib/octicons_react/icons/italic.js +++ b/lib/octicons_react/icons/italic.js @@ -1,5 +1,5 @@ import React from 'react' -export default function italic() { +export default function Italic() { return } -italic.size = [6, 16] +Italic.size = [6, 16] diff --git a/lib/octicons_react/icons/jersey.js b/lib/octicons_react/icons/jersey.js index 74dc1cb96..22ae80585 100644 --- a/lib/octicons_react/icons/jersey.js +++ b/lib/octicons_react/icons/jersey.js @@ -1,5 +1,5 @@ import React from 'react' -export default function jersey() { +export default function Jersey() { return } -jersey.size = [14, 16] +Jersey.size = [14, 16] diff --git a/lib/octicons_react/icons/kebab-horizontal.js b/lib/octicons_react/icons/kebab-horizontal.js index b2d3e4c0e..649912f75 100644 --- a/lib/octicons_react/icons/kebab-horizontal.js +++ b/lib/octicons_react/icons/kebab-horizontal.js @@ -1,5 +1,5 @@ import React from 'react' -export default function kebabHorizontal() { +export default function KebabHorizontal() { return } -kebabHorizontal.size = [13, 16] +KebabHorizontal.size = [13, 16] diff --git a/lib/octicons_react/icons/kebab-vertical.js b/lib/octicons_react/icons/kebab-vertical.js index e2e53573c..793a5ec8a 100644 --- a/lib/octicons_react/icons/kebab-vertical.js +++ b/lib/octicons_react/icons/kebab-vertical.js @@ -1,5 +1,5 @@ import React from 'react' -export default function kebabVertical() { +export default function KebabVertical() { return } -kebabVertical.size = [3, 16] +KebabVertical.size = [3, 16] diff --git a/lib/octicons_react/icons/key.js b/lib/octicons_react/icons/key.js index 74c679551..0cdbb4e14 100644 --- a/lib/octicons_react/icons/key.js +++ b/lib/octicons_react/icons/key.js @@ -1,5 +1,5 @@ import React from 'react' -export default function key() { +export default function Key() { return } -key.size = [14, 16] +Key.size = [14, 16] diff --git a/lib/octicons_react/icons/keyboard.js b/lib/octicons_react/icons/keyboard.js index 627bcc063..f653ed01e 100644 --- a/lib/octicons_react/icons/keyboard.js +++ b/lib/octicons_react/icons/keyboard.js @@ -1,5 +1,5 @@ import React from 'react' -export default function keyboard() { +export default function Keyboard() { return } -keyboard.size = [16, 16] +Keyboard.size = [16, 16] diff --git a/lib/octicons_react/icons/law.js b/lib/octicons_react/icons/law.js index c1ffe584a..bcc651cd5 100644 --- a/lib/octicons_react/icons/law.js +++ b/lib/octicons_react/icons/law.js @@ -1,5 +1,5 @@ import React from 'react' -export default function law() { +export default function Law() { return } -law.size = [14, 16] +Law.size = [14, 16] diff --git a/lib/octicons_react/icons/light-bulb.js b/lib/octicons_react/icons/light-bulb.js index 7af8803de..b15ea431b 100644 --- a/lib/octicons_react/icons/light-bulb.js +++ b/lib/octicons_react/icons/light-bulb.js @@ -1,5 +1,5 @@ import React from 'react' -export default function lightBulb() { +export default function LightBulb() { return } -lightBulb.size = [12, 16] +LightBulb.size = [12, 16] diff --git a/lib/octicons_react/icons/link-external.js b/lib/octicons_react/icons/link-external.js index e574d566c..9ad902d22 100644 --- a/lib/octicons_react/icons/link-external.js +++ b/lib/octicons_react/icons/link-external.js @@ -1,5 +1,5 @@ import React from 'react' -export default function linkExternal() { +export default function LinkExternal() { return } -linkExternal.size = [12, 16] +LinkExternal.size = [12, 16] diff --git a/lib/octicons_react/icons/link.js b/lib/octicons_react/icons/link.js index 45b5a7718..cadc433a0 100644 --- a/lib/octicons_react/icons/link.js +++ b/lib/octicons_react/icons/link.js @@ -1,5 +1,5 @@ import React from 'react' -export default function link() { +export default function Link() { return } -link.size = [16, 16] +Link.size = [16, 16] diff --git a/lib/octicons_react/icons/list-ordered.js b/lib/octicons_react/icons/list-ordered.js index 0e63d9f8e..4ae3633e0 100644 --- a/lib/octicons_react/icons/list-ordered.js +++ b/lib/octicons_react/icons/list-ordered.js @@ -1,5 +1,5 @@ import React from 'react' -export default function listOrdered() { +export default function ListOrdered() { return } -listOrdered.size = [12, 16] +ListOrdered.size = [12, 16] diff --git a/lib/octicons_react/icons/list-unordered.js b/lib/octicons_react/icons/list-unordered.js index 156c4267b..d5df18c2a 100644 --- a/lib/octicons_react/icons/list-unordered.js +++ b/lib/octicons_react/icons/list-unordered.js @@ -1,5 +1,5 @@ import React from 'react' -export default function listUnordered() { +export default function ListUnordered() { return } -listUnordered.size = [12, 16] +ListUnordered.size = [12, 16] diff --git a/lib/octicons_react/icons/location.js b/lib/octicons_react/icons/location.js index 2686f0dd1..618d8b8ea 100644 --- a/lib/octicons_react/icons/location.js +++ b/lib/octicons_react/icons/location.js @@ -1,5 +1,5 @@ import React from 'react' -export default function location() { +export default function Location() { return } -location.size = [12, 16] +Location.size = [12, 16] diff --git a/lib/octicons_react/icons/lock.js b/lib/octicons_react/icons/lock.js index ab0cb2369..9729fca8e 100644 --- a/lib/octicons_react/icons/lock.js +++ b/lib/octicons_react/icons/lock.js @@ -1,5 +1,5 @@ import React from 'react' -export default function lock() { +export default function Lock() { return } -lock.size = [12, 16] +Lock.size = [12, 16] diff --git a/lib/octicons_react/icons/logo-gist.js b/lib/octicons_react/icons/logo-gist.js index b5560aa13..4773fa392 100644 --- a/lib/octicons_react/icons/logo-gist.js +++ b/lib/octicons_react/icons/logo-gist.js @@ -1,5 +1,5 @@ import React from 'react' -export default function logoGist() { +export default function LogoGist() { return } -logoGist.size = [25, 16] +LogoGist.size = [25, 16] diff --git a/lib/octicons_react/icons/logo-github.js b/lib/octicons_react/icons/logo-github.js index 38ec669e4..6501976c7 100644 --- a/lib/octicons_react/icons/logo-github.js +++ b/lib/octicons_react/icons/logo-github.js @@ -1,5 +1,5 @@ import React from 'react' -export default function logoGithub() { +export default function LogoGithub() { return } -logoGithub.size = [45, 16] +LogoGithub.size = [45, 16] diff --git a/lib/octicons_react/icons/mail-read.js b/lib/octicons_react/icons/mail-read.js index 73b950b73..d216b5792 100644 --- a/lib/octicons_react/icons/mail-read.js +++ b/lib/octicons_react/icons/mail-read.js @@ -1,5 +1,5 @@ import React from 'react' -export default function mailRead() { +export default function MailRead() { return } -mailRead.size = [14, 16] +MailRead.size = [14, 16] diff --git a/lib/octicons_react/icons/mail.js b/lib/octicons_react/icons/mail.js index 6526eac37..3449a3b05 100644 --- a/lib/octicons_react/icons/mail.js +++ b/lib/octicons_react/icons/mail.js @@ -1,5 +1,5 @@ import React from 'react' -export default function mail() { +export default function Mail() { return } -mail.size = [14, 16] +Mail.size = [14, 16] diff --git a/lib/octicons_react/icons/mark-github.js b/lib/octicons_react/icons/mark-github.js index 0bf5b19d1..0b2841fb9 100644 --- a/lib/octicons_react/icons/mark-github.js +++ b/lib/octicons_react/icons/mark-github.js @@ -1,5 +1,5 @@ import React from 'react' -export default function markGithub() { +export default function MarkGithub() { return } -markGithub.size = [16, 16] +MarkGithub.size = [16, 16] diff --git a/lib/octicons_react/icons/markdown.js b/lib/octicons_react/icons/markdown.js index 6edc0ada6..d3b0f080b 100644 --- a/lib/octicons_react/icons/markdown.js +++ b/lib/octicons_react/icons/markdown.js @@ -1,5 +1,5 @@ import React from 'react' -export default function markdown() { +export default function Markdown() { return } -markdown.size = [16, 16] +Markdown.size = [16, 16] diff --git a/lib/octicons_react/icons/megaphone.js b/lib/octicons_react/icons/megaphone.js index 1f44a3807..76f356235 100644 --- a/lib/octicons_react/icons/megaphone.js +++ b/lib/octicons_react/icons/megaphone.js @@ -1,5 +1,5 @@ import React from 'react' -export default function megaphone() { +export default function Megaphone() { return } -megaphone.size = [16, 16] +Megaphone.size = [16, 16] diff --git a/lib/octicons_react/icons/mention.js b/lib/octicons_react/icons/mention.js index 2b1c9134d..577b787ee 100644 --- a/lib/octicons_react/icons/mention.js +++ b/lib/octicons_react/icons/mention.js @@ -1,5 +1,5 @@ import React from 'react' -export default function mention() { +export default function Mention() { return } -mention.size = [14, 16] +Mention.size = [14, 16] diff --git a/lib/octicons_react/icons/milestone.js b/lib/octicons_react/icons/milestone.js index ae86e404f..0022c94b5 100644 --- a/lib/octicons_react/icons/milestone.js +++ b/lib/octicons_react/icons/milestone.js @@ -1,5 +1,5 @@ import React from 'react' -export default function milestone() { +export default function Milestone() { return } -milestone.size = [14, 16] +Milestone.size = [14, 16] diff --git a/lib/octicons_react/icons/mirror.js b/lib/octicons_react/icons/mirror.js index 5b0395cc4..4e299b752 100644 --- a/lib/octicons_react/icons/mirror.js +++ b/lib/octicons_react/icons/mirror.js @@ -1,5 +1,5 @@ import React from 'react' -export default function mirror() { +export default function Mirror() { return } -mirror.size = [16, 16] +Mirror.size = [16, 16] diff --git a/lib/octicons_react/icons/mortar-board.js b/lib/octicons_react/icons/mortar-board.js index 5573ae9ad..38662e187 100644 --- a/lib/octicons_react/icons/mortar-board.js +++ b/lib/octicons_react/icons/mortar-board.js @@ -1,5 +1,5 @@ import React from 'react' -export default function mortarBoard() { +export default function MortarBoard() { return } -mortarBoard.size = [16, 16] +MortarBoard.size = [16, 16] diff --git a/lib/octicons_react/icons/mute.js b/lib/octicons_react/icons/mute.js index bae659581..78ea728f6 100644 --- a/lib/octicons_react/icons/mute.js +++ b/lib/octicons_react/icons/mute.js @@ -1,5 +1,5 @@ import React from 'react' -export default function mute() { +export default function Mute() { return } -mute.size = [16, 16] +Mute.size = [16, 16] diff --git a/lib/octicons_react/icons/no-newline.js b/lib/octicons_react/icons/no-newline.js index 287df16d8..1701315fa 100644 --- a/lib/octicons_react/icons/no-newline.js +++ b/lib/octicons_react/icons/no-newline.js @@ -1,5 +1,5 @@ import React from 'react' -export default function noNewline() { +export default function NoNewline() { return } -noNewline.size = [16, 16] +NoNewline.size = [16, 16] diff --git a/lib/octicons_react/icons/note.js b/lib/octicons_react/icons/note.js index 7ea7d4164..642ec1f13 100644 --- a/lib/octicons_react/icons/note.js +++ b/lib/octicons_react/icons/note.js @@ -1,5 +1,5 @@ import React from 'react' -export default function note() { +export default function Note() { return } -note.size = [14, 16] +Note.size = [14, 16] diff --git a/lib/octicons_react/icons/octoface.js b/lib/octicons_react/icons/octoface.js index e5cf15fdd..34149f2f6 100644 --- a/lib/octicons_react/icons/octoface.js +++ b/lib/octicons_react/icons/octoface.js @@ -1,5 +1,5 @@ import React from 'react' -export default function octoface() { +export default function Octoface() { return } -octoface.size = [16, 16] +Octoface.size = [16, 16] diff --git a/lib/octicons_react/icons/organization.js b/lib/octicons_react/icons/organization.js index d76d90f8a..6a6522482 100644 --- a/lib/octicons_react/icons/organization.js +++ b/lib/octicons_react/icons/organization.js @@ -1,5 +1,5 @@ import React from 'react' -export default function organization() { +export default function Organization() { return } -organization.size = [16, 16] +Organization.size = [16, 16] diff --git a/lib/octicons_react/icons/package.js b/lib/octicons_react/icons/package.js index 00e9259f5..c063ae4e3 100644 --- a/lib/octicons_react/icons/package.js +++ b/lib/octicons_react/icons/package.js @@ -1,5 +1,5 @@ import React from 'react' -export default function package() { +export default function Package() { return } -package.size = [16, 16] +Package.size = [16, 16] diff --git a/lib/octicons_react/icons/paintcan.js b/lib/octicons_react/icons/paintcan.js index 84ef079b1..da1af3574 100644 --- a/lib/octicons_react/icons/paintcan.js +++ b/lib/octicons_react/icons/paintcan.js @@ -1,5 +1,5 @@ import React from 'react' -export default function paintcan() { +export default function Paintcan() { return } -paintcan.size = [12, 16] +Paintcan.size = [12, 16] diff --git a/lib/octicons_react/icons/pencil.js b/lib/octicons_react/icons/pencil.js index b5acec037..650ed192c 100644 --- a/lib/octicons_react/icons/pencil.js +++ b/lib/octicons_react/icons/pencil.js @@ -1,5 +1,5 @@ import React from 'react' -export default function pencil() { +export default function Pencil() { return } -pencil.size = [14, 16] +Pencil.size = [14, 16] diff --git a/lib/octicons_react/icons/person.js b/lib/octicons_react/icons/person.js index 54a111329..6336210cc 100644 --- a/lib/octicons_react/icons/person.js +++ b/lib/octicons_react/icons/person.js @@ -1,5 +1,5 @@ import React from 'react' -export default function person() { +export default function Person() { return } -person.size = [12, 16] +Person.size = [12, 16] diff --git a/lib/octicons_react/icons/pin.js b/lib/octicons_react/icons/pin.js index 65fdd282a..2e5e7bc79 100644 --- a/lib/octicons_react/icons/pin.js +++ b/lib/octicons_react/icons/pin.js @@ -1,5 +1,5 @@ import React from 'react' -export default function pin() { +export default function Pin() { return } -pin.size = [16, 16] +Pin.size = [16, 16] diff --git a/lib/octicons_react/icons/plug.js b/lib/octicons_react/icons/plug.js index ac8595907..ce742c38b 100644 --- a/lib/octicons_react/icons/plug.js +++ b/lib/octicons_react/icons/plug.js @@ -1,5 +1,5 @@ import React from 'react' -export default function plug() { +export default function Plug() { return } -plug.size = [14, 16] +Plug.size = [14, 16] diff --git a/lib/octicons_react/icons/plus-small.js b/lib/octicons_react/icons/plus-small.js index f7e2b899d..633b81a90 100644 --- a/lib/octicons_react/icons/plus-small.js +++ b/lib/octicons_react/icons/plus-small.js @@ -1,5 +1,5 @@ import React from 'react' -export default function plusSmall() { +export default function PlusSmall() { return } -plusSmall.size = [7, 16] +PlusSmall.size = [7, 16] diff --git a/lib/octicons_react/icons/plus.js b/lib/octicons_react/icons/plus.js index ba304ed32..384611bcb 100644 --- a/lib/octicons_react/icons/plus.js +++ b/lib/octicons_react/icons/plus.js @@ -1,5 +1,5 @@ import React from 'react' -export default function plus() { +export default function Plus() { return } -plus.size = [12, 16] +Plus.size = [12, 16] diff --git a/lib/octicons_react/icons/primitive-dot.js b/lib/octicons_react/icons/primitive-dot.js index 5ade5749e..2e8bcb623 100644 --- a/lib/octicons_react/icons/primitive-dot.js +++ b/lib/octicons_react/icons/primitive-dot.js @@ -1,5 +1,5 @@ import React from 'react' -export default function primitiveDot() { +export default function PrimitiveDot() { return } -primitiveDot.size = [8, 16] +PrimitiveDot.size = [8, 16] diff --git a/lib/octicons_react/icons/primitive-square.js b/lib/octicons_react/icons/primitive-square.js index a9fb4c97a..7b8852a95 100644 --- a/lib/octicons_react/icons/primitive-square.js +++ b/lib/octicons_react/icons/primitive-square.js @@ -1,5 +1,5 @@ import React from 'react' -export default function primitiveSquare() { +export default function PrimitiveSquare() { return } -primitiveSquare.size = [8, 16] +PrimitiveSquare.size = [8, 16] diff --git a/lib/octicons_react/icons/project.js b/lib/octicons_react/icons/project.js index 46445cbda..3bc8ca90a 100644 --- a/lib/octicons_react/icons/project.js +++ b/lib/octicons_react/icons/project.js @@ -1,5 +1,5 @@ import React from 'react' -export default function project() { +export default function Project() { return } -project.size = [15, 16] +Project.size = [15, 16] diff --git a/lib/octicons_react/icons/pulse.js b/lib/octicons_react/icons/pulse.js index c3f0cf460..d1ccfa44f 100644 --- a/lib/octicons_react/icons/pulse.js +++ b/lib/octicons_react/icons/pulse.js @@ -1,5 +1,5 @@ import React from 'react' -export default function pulse() { +export default function Pulse() { return } -pulse.size = [14, 16] +Pulse.size = [14, 16] diff --git a/lib/octicons_react/icons/question.js b/lib/octicons_react/icons/question.js index a81ea9179..f47c7dbd1 100644 --- a/lib/octicons_react/icons/question.js +++ b/lib/octicons_react/icons/question.js @@ -1,5 +1,5 @@ import React from 'react' -export default function question() { +export default function Question() { return } -question.size = [14, 16] +Question.size = [14, 16] diff --git a/lib/octicons_react/icons/quote.js b/lib/octicons_react/icons/quote.js index 3b7738609..53a3c7a3f 100644 --- a/lib/octicons_react/icons/quote.js +++ b/lib/octicons_react/icons/quote.js @@ -1,5 +1,5 @@ import React from 'react' -export default function quote() { +export default function Quote() { return } -quote.size = [14, 16] +Quote.size = [14, 16] diff --git a/lib/octicons_react/icons/radio-tower.js b/lib/octicons_react/icons/radio-tower.js index 410272983..fbd9bed7c 100644 --- a/lib/octicons_react/icons/radio-tower.js +++ b/lib/octicons_react/icons/radio-tower.js @@ -1,5 +1,5 @@ import React from 'react' -export default function radioTower() { +export default function RadioTower() { return } -radioTower.size = [16, 16] +RadioTower.size = [16, 16] diff --git a/lib/octicons_react/icons/reply.js b/lib/octicons_react/icons/reply.js index 5d7c4f879..f36b3880f 100644 --- a/lib/octicons_react/icons/reply.js +++ b/lib/octicons_react/icons/reply.js @@ -1,5 +1,5 @@ import React from 'react' -export default function reply() { +export default function Reply() { return } -reply.size = [14, 16] +Reply.size = [14, 16] diff --git a/lib/octicons_react/icons/repo-clone.js b/lib/octicons_react/icons/repo-clone.js index fd611e6be..7984bbea1 100644 --- a/lib/octicons_react/icons/repo-clone.js +++ b/lib/octicons_react/icons/repo-clone.js @@ -1,5 +1,5 @@ import React from 'react' -export default function repoClone() { +export default function RepoClone() { return } -repoClone.size = [16, 16] +RepoClone.size = [16, 16] diff --git a/lib/octicons_react/icons/repo-force-push.js b/lib/octicons_react/icons/repo-force-push.js index ade9a7153..d5f0a64b0 100644 --- a/lib/octicons_react/icons/repo-force-push.js +++ b/lib/octicons_react/icons/repo-force-push.js @@ -1,5 +1,5 @@ import React from 'react' -export default function repoForcePush() { +export default function RepoForcePush() { return } -repoForcePush.size = [12, 16] +RepoForcePush.size = [12, 16] diff --git a/lib/octicons_react/icons/repo-forked.js b/lib/octicons_react/icons/repo-forked.js index 3bce9034a..6a48c0209 100644 --- a/lib/octicons_react/icons/repo-forked.js +++ b/lib/octicons_react/icons/repo-forked.js @@ -1,5 +1,5 @@ import React from 'react' -export default function repoForked() { +export default function RepoForked() { return } -repoForked.size = [10, 16] +RepoForked.size = [10, 16] diff --git a/lib/octicons_react/icons/repo-pull.js b/lib/octicons_react/icons/repo-pull.js index 02609bc70..38038e29c 100644 --- a/lib/octicons_react/icons/repo-pull.js +++ b/lib/octicons_react/icons/repo-pull.js @@ -1,5 +1,5 @@ import React from 'react' -export default function repoPull() { +export default function RepoPull() { return } -repoPull.size = [16, 16] +RepoPull.size = [16, 16] diff --git a/lib/octicons_react/icons/repo-push.js b/lib/octicons_react/icons/repo-push.js index 86970ee03..8d921def6 100644 --- a/lib/octicons_react/icons/repo-push.js +++ b/lib/octicons_react/icons/repo-push.js @@ -1,5 +1,5 @@ import React from 'react' -export default function repoPush() { +export default function RepoPush() { return } -repoPush.size = [12, 16] +RepoPush.size = [12, 16] diff --git a/lib/octicons_react/icons/repo.js b/lib/octicons_react/icons/repo.js index 8db6e4251..1088ef5da 100644 --- a/lib/octicons_react/icons/repo.js +++ b/lib/octicons_react/icons/repo.js @@ -1,5 +1,5 @@ import React from 'react' -export default function repo() { +export default function Repo() { return } -repo.size = [12, 16] +Repo.size = [12, 16] diff --git a/lib/octicons_react/icons/report.js b/lib/octicons_react/icons/report.js index bf6e09a90..c7622c380 100644 --- a/lib/octicons_react/icons/report.js +++ b/lib/octicons_react/icons/report.js @@ -1,5 +1,5 @@ import React from 'react' -export default function report() { +export default function Report() { return } -report.size = [16, 16] +Report.size = [16, 16] diff --git a/lib/octicons_react/icons/rocket.js b/lib/octicons_react/icons/rocket.js index 68afd60eb..8c506da8c 100644 --- a/lib/octicons_react/icons/rocket.js +++ b/lib/octicons_react/icons/rocket.js @@ -1,5 +1,5 @@ import React from 'react' -export default function rocket() { +export default function Rocket() { return } -rocket.size = [16, 16] +Rocket.size = [16, 16] diff --git a/lib/octicons_react/icons/rss.js b/lib/octicons_react/icons/rss.js index 9586587f3..36a630b8a 100644 --- a/lib/octicons_react/icons/rss.js +++ b/lib/octicons_react/icons/rss.js @@ -1,5 +1,5 @@ import React from 'react' -export default function rss() { +export default function Rss() { return } -rss.size = [10, 16] +Rss.size = [10, 16] diff --git a/lib/octicons_react/icons/ruby.js b/lib/octicons_react/icons/ruby.js index 6c2bcb0d2..d36883a85 100644 --- a/lib/octicons_react/icons/ruby.js +++ b/lib/octicons_react/icons/ruby.js @@ -1,5 +1,5 @@ import React from 'react' -export default function ruby() { +export default function Ruby() { return } -ruby.size = [16, 16] +Ruby.size = [16, 16] diff --git a/lib/octicons_react/icons/screen-full.js b/lib/octicons_react/icons/screen-full.js index ac4b1ddf1..29ff6f06d 100644 --- a/lib/octicons_react/icons/screen-full.js +++ b/lib/octicons_react/icons/screen-full.js @@ -1,5 +1,5 @@ import React from 'react' -export default function screenFull() { +export default function ScreenFull() { return } -screenFull.size = [14, 16] +ScreenFull.size = [14, 16] diff --git a/lib/octicons_react/icons/screen-normal.js b/lib/octicons_react/icons/screen-normal.js index f233ebbc1..c6e6b357e 100644 --- a/lib/octicons_react/icons/screen-normal.js +++ b/lib/octicons_react/icons/screen-normal.js @@ -1,5 +1,5 @@ import React from 'react' -export default function screenNormal() { +export default function ScreenNormal() { return } -screenNormal.size = [14, 16] +ScreenNormal.size = [14, 16] diff --git a/lib/octicons_react/icons/search.js b/lib/octicons_react/icons/search.js index 6f4d8f9e7..6af268d09 100644 --- a/lib/octicons_react/icons/search.js +++ b/lib/octicons_react/icons/search.js @@ -1,5 +1,5 @@ import React from 'react' -export default function search() { +export default function Search() { return } -search.size = [16, 16] +Search.size = [16, 16] diff --git a/lib/octicons_react/icons/server.js b/lib/octicons_react/icons/server.js index 121a8792a..b1b20501c 100644 --- a/lib/octicons_react/icons/server.js +++ b/lib/octicons_react/icons/server.js @@ -1,5 +1,5 @@ import React from 'react' -export default function server() { +export default function Server() { return } -server.size = [12, 16] +Server.size = [12, 16] diff --git a/lib/octicons_react/icons/settings.js b/lib/octicons_react/icons/settings.js index 19dd72925..73bc9c219 100644 --- a/lib/octicons_react/icons/settings.js +++ b/lib/octicons_react/icons/settings.js @@ -1,5 +1,5 @@ import React from 'react' -export default function settings() { +export default function Settings() { return } -settings.size = [16, 16] +Settings.size = [16, 16] diff --git a/lib/octicons_react/icons/shield.js b/lib/octicons_react/icons/shield.js index e21f348ff..285d89af0 100644 --- a/lib/octicons_react/icons/shield.js +++ b/lib/octicons_react/icons/shield.js @@ -1,5 +1,5 @@ import React from 'react' -export default function shield() { +export default function Shield() { return } -shield.size = [14, 16] +Shield.size = [14, 16] diff --git a/lib/octicons_react/icons/sign-in.js b/lib/octicons_react/icons/sign-in.js index 10c0773b3..522b5d398 100644 --- a/lib/octicons_react/icons/sign-in.js +++ b/lib/octicons_react/icons/sign-in.js @@ -1,5 +1,5 @@ import React from 'react' -export default function signIn() { +export default function SignIn() { return } -signIn.size = [14, 16] +SignIn.size = [14, 16] diff --git a/lib/octicons_react/icons/sign-out.js b/lib/octicons_react/icons/sign-out.js index e3b3535bb..88f779454 100644 --- a/lib/octicons_react/icons/sign-out.js +++ b/lib/octicons_react/icons/sign-out.js @@ -1,5 +1,5 @@ import React from 'react' -export default function signOut() { +export default function SignOut() { return } -signOut.size = [16, 16] +SignOut.size = [16, 16] diff --git a/lib/octicons_react/icons/smiley.js b/lib/octicons_react/icons/smiley.js index 4a678d65a..8aa509c9e 100644 --- a/lib/octicons_react/icons/smiley.js +++ b/lib/octicons_react/icons/smiley.js @@ -1,5 +1,5 @@ import React from 'react' -export default function smiley() { +export default function Smiley() { return } -smiley.size = [16, 16] +Smiley.size = [16, 16] diff --git a/lib/octicons_react/icons/squirrel.js b/lib/octicons_react/icons/squirrel.js index 3afcdbbb1..aef5f326d 100644 --- a/lib/octicons_react/icons/squirrel.js +++ b/lib/octicons_react/icons/squirrel.js @@ -1,5 +1,5 @@ import React from 'react' -export default function squirrel() { +export default function Squirrel() { return } -squirrel.size = [16, 16] +Squirrel.size = [16, 16] diff --git a/lib/octicons_react/icons/star.js b/lib/octicons_react/icons/star.js index 2f3130110..e7e1456a3 100644 --- a/lib/octicons_react/icons/star.js +++ b/lib/octicons_react/icons/star.js @@ -1,5 +1,5 @@ import React from 'react' -export default function star() { +export default function Star() { return } -star.size = [14, 16] +Star.size = [14, 16] diff --git a/lib/octicons_react/icons/stop.js b/lib/octicons_react/icons/stop.js index ef1b4c3dc..e558cf2d9 100644 --- a/lib/octicons_react/icons/stop.js +++ b/lib/octicons_react/icons/stop.js @@ -1,5 +1,5 @@ import React from 'react' -export default function stop() { +export default function Stop() { return } -stop.size = [14, 16] +Stop.size = [14, 16] diff --git a/lib/octicons_react/icons/sync.js b/lib/octicons_react/icons/sync.js index 99962b1bf..1952c0d48 100644 --- a/lib/octicons_react/icons/sync.js +++ b/lib/octicons_react/icons/sync.js @@ -1,5 +1,5 @@ import React from 'react' -export default function sync() { +export default function Sync() { return } -sync.size = [12, 16] +Sync.size = [12, 16] diff --git a/lib/octicons_react/icons/tag.js b/lib/octicons_react/icons/tag.js index 0d54ef6e8..5da8cf47a 100644 --- a/lib/octicons_react/icons/tag.js +++ b/lib/octicons_react/icons/tag.js @@ -1,5 +1,5 @@ import React from 'react' -export default function tag() { +export default function Tag() { return } -tag.size = [14, 16] +Tag.size = [14, 16] diff --git a/lib/octicons_react/icons/tasklist.js b/lib/octicons_react/icons/tasklist.js index 19eb53783..98265fefb 100644 --- a/lib/octicons_react/icons/tasklist.js +++ b/lib/octicons_react/icons/tasklist.js @@ -1,5 +1,5 @@ import React from 'react' -export default function tasklist() { +export default function Tasklist() { return } -tasklist.size = [16, 16] +Tasklist.size = [16, 16] diff --git a/lib/octicons_react/icons/telescope.js b/lib/octicons_react/icons/telescope.js index 56576bc38..28888e65e 100644 --- a/lib/octicons_react/icons/telescope.js +++ b/lib/octicons_react/icons/telescope.js @@ -1,5 +1,5 @@ import React from 'react' -export default function telescope() { +export default function Telescope() { return } -telescope.size = [14, 16] +Telescope.size = [14, 16] diff --git a/lib/octicons_react/icons/terminal.js b/lib/octicons_react/icons/terminal.js index 847033d89..5003ab1bb 100644 --- a/lib/octicons_react/icons/terminal.js +++ b/lib/octicons_react/icons/terminal.js @@ -1,5 +1,5 @@ import React from 'react' -export default function terminal() { +export default function Terminal() { return } -terminal.size = [14, 16] +Terminal.size = [14, 16] diff --git a/lib/octicons_react/icons/text-size.js b/lib/octicons_react/icons/text-size.js index be466a949..e943a72a1 100644 --- a/lib/octicons_react/icons/text-size.js +++ b/lib/octicons_react/icons/text-size.js @@ -1,5 +1,5 @@ import React from 'react' -export default function textSize() { +export default function TextSize() { return } -textSize.size = [18, 16] +TextSize.size = [18, 16] diff --git a/lib/octicons_react/icons/three-bars.js b/lib/octicons_react/icons/three-bars.js index 5d8731a34..d786b4320 100644 --- a/lib/octicons_react/icons/three-bars.js +++ b/lib/octicons_react/icons/three-bars.js @@ -1,5 +1,5 @@ import React from 'react' -export default function threeBars() { +export default function ThreeBars() { return } -threeBars.size = [12, 16] +ThreeBars.size = [12, 16] diff --git a/lib/octicons_react/icons/thumbsdown.js b/lib/octicons_react/icons/thumbsdown.js index 7d9bfa780..c21192fc0 100644 --- a/lib/octicons_react/icons/thumbsdown.js +++ b/lib/octicons_react/icons/thumbsdown.js @@ -1,5 +1,5 @@ import React from 'react' -export default function thumbsdown() { +export default function Thumbsdown() { return } -thumbsdown.size = [16, 16] +Thumbsdown.size = [16, 16] diff --git a/lib/octicons_react/icons/thumbsup.js b/lib/octicons_react/icons/thumbsup.js index ee71dc6a2..225a2f4bf 100644 --- a/lib/octicons_react/icons/thumbsup.js +++ b/lib/octicons_react/icons/thumbsup.js @@ -1,5 +1,5 @@ import React from 'react' -export default function thumbsup() { +export default function Thumbsup() { return } -thumbsup.size = [16, 16] +Thumbsup.size = [16, 16] diff --git a/lib/octicons_react/icons/tools.js b/lib/octicons_react/icons/tools.js index c3a020662..07c49dd7d 100644 --- a/lib/octicons_react/icons/tools.js +++ b/lib/octicons_react/icons/tools.js @@ -1,5 +1,5 @@ import React from 'react' -export default function tools() { +export default function Tools() { return } -tools.size = [16, 16] +Tools.size = [16, 16] diff --git a/lib/octicons_react/icons/trashcan.js b/lib/octicons_react/icons/trashcan.js index 79dd009a4..7369ce7ca 100644 --- a/lib/octicons_react/icons/trashcan.js +++ b/lib/octicons_react/icons/trashcan.js @@ -1,5 +1,5 @@ import React from 'react' -export default function trashcan() { +export default function Trashcan() { return } -trashcan.size = [12, 16] +Trashcan.size = [12, 16] diff --git a/lib/octicons_react/icons/triangle-down.js b/lib/octicons_react/icons/triangle-down.js index 2d2dbec7c..a3ba3afff 100644 --- a/lib/octicons_react/icons/triangle-down.js +++ b/lib/octicons_react/icons/triangle-down.js @@ -1,5 +1,5 @@ import React from 'react' -export default function triangleDown() { +export default function TriangleDown() { return } -triangleDown.size = [12, 16] +TriangleDown.size = [12, 16] diff --git a/lib/octicons_react/icons/triangle-left.js b/lib/octicons_react/icons/triangle-left.js index e1e47ef48..188df9997 100644 --- a/lib/octicons_react/icons/triangle-left.js +++ b/lib/octicons_react/icons/triangle-left.js @@ -1,5 +1,5 @@ import React from 'react' -export default function triangleLeft() { +export default function TriangleLeft() { return } -triangleLeft.size = [6, 16] +TriangleLeft.size = [6, 16] diff --git a/lib/octicons_react/icons/triangle-right.js b/lib/octicons_react/icons/triangle-right.js index bd00aa6c4..0db185e15 100644 --- a/lib/octicons_react/icons/triangle-right.js +++ b/lib/octicons_react/icons/triangle-right.js @@ -1,5 +1,5 @@ import React from 'react' -export default function triangleRight() { +export default function TriangleRight() { return } -triangleRight.size = [6, 16] +TriangleRight.size = [6, 16] diff --git a/lib/octicons_react/icons/triangle-up.js b/lib/octicons_react/icons/triangle-up.js index 6661cb815..c62d1c631 100644 --- a/lib/octicons_react/icons/triangle-up.js +++ b/lib/octicons_react/icons/triangle-up.js @@ -1,5 +1,5 @@ import React from 'react' -export default function triangleUp() { +export default function TriangleUp() { return } -triangleUp.size = [12, 16] +TriangleUp.size = [12, 16] diff --git a/lib/octicons_react/icons/unfold.js b/lib/octicons_react/icons/unfold.js index e241716b5..b67c8cd98 100644 --- a/lib/octicons_react/icons/unfold.js +++ b/lib/octicons_react/icons/unfold.js @@ -1,5 +1,5 @@ import React from 'react' -export default function unfold() { +export default function Unfold() { return } -unfold.size = [14, 16] +Unfold.size = [14, 16] diff --git a/lib/octicons_react/icons/unmute.js b/lib/octicons_react/icons/unmute.js index 0f3ca9f88..a638b7cd9 100644 --- a/lib/octicons_react/icons/unmute.js +++ b/lib/octicons_react/icons/unmute.js @@ -1,5 +1,5 @@ import React from 'react' -export default function unmute() { +export default function Unmute() { return } -unmute.size = [16, 16] +Unmute.size = [16, 16] diff --git a/lib/octicons_react/icons/unverified.js b/lib/octicons_react/icons/unverified.js index d989ffdda..aea1d5342 100644 --- a/lib/octicons_react/icons/unverified.js +++ b/lib/octicons_react/icons/unverified.js @@ -1,5 +1,5 @@ import React from 'react' -export default function unverified() { +export default function Unverified() { return } -unverified.size = [16, 16] +Unverified.size = [16, 16] diff --git a/lib/octicons_react/icons/verified.js b/lib/octicons_react/icons/verified.js index 91d957710..134522b80 100644 --- a/lib/octicons_react/icons/verified.js +++ b/lib/octicons_react/icons/verified.js @@ -1,5 +1,5 @@ import React from 'react' -export default function verified() { +export default function Verified() { return } -verified.size = [16, 16] +Verified.size = [16, 16] diff --git a/lib/octicons_react/icons/versions.js b/lib/octicons_react/icons/versions.js index aa8eaab34..62f05c050 100644 --- a/lib/octicons_react/icons/versions.js +++ b/lib/octicons_react/icons/versions.js @@ -1,5 +1,5 @@ import React from 'react' -export default function versions() { +export default function Versions() { return } -versions.size = [14, 16] +Versions.size = [14, 16] diff --git a/lib/octicons_react/icons/watch.js b/lib/octicons_react/icons/watch.js index 062a88c74..09cbde259 100644 --- a/lib/octicons_react/icons/watch.js +++ b/lib/octicons_react/icons/watch.js @@ -1,5 +1,5 @@ import React from 'react' -export default function watch() { +export default function Watch() { return } -watch.size = [12, 16] +Watch.size = [12, 16] diff --git a/lib/octicons_react/icons/x.js b/lib/octicons_react/icons/x.js index d01bc7865..50291adf6 100644 --- a/lib/octicons_react/icons/x.js +++ b/lib/octicons_react/icons/x.js @@ -1,5 +1,5 @@ import React from 'react' -export default function x() { +export default function X() { return } -x.size = [12, 16] +X.size = [12, 16] diff --git a/lib/octicons_react/icons/zap.js b/lib/octicons_react/icons/zap.js index 15b614018..9d2f89288 100644 --- a/lib/octicons_react/icons/zap.js +++ b/lib/octicons_react/icons/zap.js @@ -1,5 +1,5 @@ import React from 'react' -export default function zap() { +export default function Zap() { return } -zap.size = [10, 16] +Zap.size = [10, 16] diff --git a/lib/octicons_react/script/build.js b/lib/octicons_react/script/build.js index 9eeb31545..e4f9f9295 100755 --- a/lib/octicons_react/script/build.js +++ b/lib/octicons_react/script/build.js @@ -5,13 +5,13 @@ const {join} = require('path') const DIR = 'icons' -function camelCase(str) { - return str.replace(/-([a-z])/g, (_, c) => c.toUpperCase()) +function CamelCase(str) { + return str.replace(/(^|-)([a-z])/g, (_, __, c) => c.toUpperCase()) } const icons = [...Object.entries(octicons)] .map(([key, octicon]) => { - const name = camelCase(key) + const name = CamelCase(key) const {width, height, path} = octicon const code = `import React from 'react' export default function ${name}() { @@ -22,15 +22,27 @@ ${name}.size = [${width}, ${height}] return { key, + name, octicon, code } }) -const tasks = icons.map(({key, code}) => { - return fse.writeFile(join(DIR, key + '.js'), code, 'utf8') +const tasks = icons.map(({key, name, code}) => { + const file = join(DIR, key + '.js') + return fse.writeFile(file, code, 'utf8') + .then(() => ({key, name, file})) }) -Promise.all(tasks).then(() => { - console.warn('wrote %d files to %s.', tasks.length, DIR) +Promise.all(tasks).then(written => { + const count = written.length + console.warn('wrote %d files to %s.', count, DIR) + const file = join(DIR, 'index.js') + const code = written.map(({key, name}) => ( + `export {default as ${name}} from './${key}'` + )).join('\n') + return fse.writeFile(file, code, 'utf8') + .then(() => { + console.warn('wrote %s with %d exports', file, count) + }) }) From 661d32098ba72b3cabfd201484fc8accaa327084 Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Fri, 8 Jun 2018 12:01:01 -0700 Subject: [PATCH 25/97] export all the icons??? --- lib/octicons_react/index.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lib/octicons_react/index.js b/lib/octicons_react/index.js index 488986bb5..a0d936a9e 100644 --- a/lib/octicons_react/index.js +++ b/lib/octicons_react/index.js @@ -58,3 +58,5 @@ Octicon.propTypes = { 'middle', 'text-bottom', 'text-top', 'top' ]) } + +export * from './icons' From 3a8157fc1e57a14916d4bcc01c10ca744ed72904 Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Fri, 8 Jun 2018 12:53:34 -0700 Subject: [PATCH 26/97] icon output fix, viewBox --- lib/octicons_react/index.js | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/lib/octicons_react/index.js b/lib/octicons_react/index.js index a0d936a9e..490a46108 100644 --- a/lib/octicons_react/index.js +++ b/lib/octicons_react/index.js @@ -15,21 +15,23 @@ export default function Octicon(props) { const { ariaLabel, children, - icon, + className = 'octicon', + icon: Icon, size, - verticalAlign, - ...rest + verticalAlign } = props - const child = (typeof icon === 'function') - ? + const child = (typeof Icon === 'function') + ? : React.Children.only(children) const [width, height] = child.type.size || [16, 16] const attrs = { - ariaLabel, + 'aria-label': ariaLabel, + className, role: 'img', - height: height + height: height, + viewBox: [0, 0, width, height].join(' ') } if (size in sizeMap) { From 6f811ae36eea54f220bd81843b1223b5d0a2399e Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Fri, 8 Jun 2018 12:54:20 -0700 Subject: [PATCH 27/97] add parcel for testing --- lib/octicons_react/.babelrc | 1 + lib/octicons_react/example.js | 23 +++++++++++++++++++++++ lib/octicons_react/index.html | 10 ++++++++++ lib/octicons_react/package.json | 11 +++++++++-- 4 files changed, 43 insertions(+), 2 deletions(-) create mode 100644 lib/octicons_react/.babelrc create mode 100644 lib/octicons_react/example.js create mode 100644 lib/octicons_react/index.html diff --git a/lib/octicons_react/.babelrc b/lib/octicons_react/.babelrc new file mode 100644 index 000000000..0ace98b8f --- /dev/null +++ b/lib/octicons_react/.babelrc @@ -0,0 +1 @@ +{"presets": ["env", "react"]} diff --git a/lib/octicons_react/example.js b/lib/octicons_react/example.js new file mode 100644 index 000000000..72fed030c --- /dev/null +++ b/lib/octicons_react/example.js @@ -0,0 +1,23 @@ +import React from 'react' +import ReactDOM from 'react-dom' + +import Octicon, {Alert, X, Zap} from './' + +function App() { + return ( +
+ {[Alert, X, Zap].map((Icon, i) => ( +
+

{Icon.name}

+

with {'icon={Icon}'}:

+

with {''} as child:

+

medium:

+

large:

+

without {''}:

+
+ ))} +
+ ) +} + +ReactDOM.render(, document.getElementById('app')) diff --git a/lib/octicons_react/index.html b/lib/octicons_react/index.html new file mode 100644 index 000000000..78c1b49d1 --- /dev/null +++ b/lib/octicons_react/index.html @@ -0,0 +1,10 @@ + + + + + + +
+ + + diff --git a/lib/octicons_react/package.json b/lib/octicons_react/package.json index 9e2596ca8..c31063acf 100644 --- a/lib/octicons_react/package.json +++ b/lib/octicons_react/package.json @@ -12,6 +12,7 @@ "icons" ], "scripts": { + "start": "parcel serve index.html", "publish": "../../script/notify success", "prepublishOnly": "../../script/notify pending", "prepare": "script/build.js" @@ -38,9 +39,15 @@ }, "devDependencies": { "babel-cli": "^6.26.0", - "babel-preset-env": "^1.6.1", + "babel-preset-env": "^1.7.0", "babel-preset-react": "^6.24.1", "fs-extra": "^6.0.1", - "octicons": "7.2.0" + "octicons": "7.2.0", + "parcel": "^1.8.1", + "react": "^16.4.0", + "react-dom": "^16.4.0" + }, + "dependencies": { + "prop-types": "^15.6.1" } } From 98826f549101d7c4a12440b5227eebd41729942f Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Fri, 8 Jun 2018 12:54:47 -0700 Subject: [PATCH 28/97] ignore stuff --- lib/octicons_react/.gitignore | 2 ++ 1 file changed, 2 insertions(+) create mode 100644 lib/octicons_react/.gitignore diff --git a/lib/octicons_react/.gitignore b/lib/octicons_react/.gitignore new file mode 100644 index 000000000..d757f56df --- /dev/null +++ b/lib/octicons_react/.gitignore @@ -0,0 +1,2 @@ +.cache +dist/ From 6a3c8ec4d6a99c8141d725cfed94eff8a1db75cb Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Fri, 8 Jun 2018 12:55:13 -0700 Subject: [PATCH 29/97] clarify --- lib/octicons_react/example.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/octicons_react/example.js b/lib/octicons_react/example.js index 72fed030c..f9588fd6d 100644 --- a/lib/octicons_react/example.js +++ b/lib/octicons_react/example.js @@ -10,7 +10,7 @@ function App() {

{Icon.name}

with {'icon={Icon}'}:

-

with {''} as child:

+

with {''} as child:

medium:

large:

without {''}:

From 4ecbf0e56c9439e9bb60140f27586b37f040137a Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Fri, 8 Jun 2018 14:44:54 -0700 Subject: [PATCH 30/97] use next.js --- lib/octicons_react/.babelrc | 1 - lib/octicons_react/.gitignore | 2 +- lib/octicons_react/index.html | 10 ---------- lib/octicons_react/package.json | 14 ++------------ lib/octicons_react/pages/_document.js | 17 +++++++++++++++++ .../{example.js => pages/index.js} | 7 ++----- 6 files changed, 22 insertions(+), 29 deletions(-) delete mode 100644 lib/octicons_react/.babelrc delete mode 100644 lib/octicons_react/index.html create mode 100644 lib/octicons_react/pages/_document.js rename lib/octicons_react/{example.js => pages/index.js} (80%) diff --git a/lib/octicons_react/.babelrc b/lib/octicons_react/.babelrc deleted file mode 100644 index 0ace98b8f..000000000 --- a/lib/octicons_react/.babelrc +++ /dev/null @@ -1 +0,0 @@ -{"presets": ["env", "react"]} diff --git a/lib/octicons_react/.gitignore b/lib/octicons_react/.gitignore index d757f56df..18acff14b 100644 --- a/lib/octicons_react/.gitignore +++ b/lib/octicons_react/.gitignore @@ -1,2 +1,2 @@ .cache -dist/ +.next diff --git a/lib/octicons_react/index.html b/lib/octicons_react/index.html deleted file mode 100644 index 78c1b49d1..000000000 --- a/lib/octicons_react/index.html +++ /dev/null @@ -1,10 +0,0 @@ - - - - - - -
- - - diff --git a/lib/octicons_react/package.json b/lib/octicons_react/package.json index c31063acf..097f65849 100644 --- a/lib/octicons_react/package.json +++ b/lib/octicons_react/package.json @@ -12,7 +12,7 @@ "icons" ], "scripts": { - "start": "parcel serve index.html", + "start": "next", "publish": "../../script/notify success", "prepublishOnly": "../../script/notify pending", "prepare": "script/build.js" @@ -28,22 +28,12 @@ "react", "primer" ], - "babel": { - "presets": [ - "env", - "react" - ] - }, - "peerDependencies": { - "react": ">=16.2.0" - }, "devDependencies": { - "babel-cli": "^6.26.0", "babel-preset-env": "^1.7.0", "babel-preset-react": "^6.24.1", "fs-extra": "^6.0.1", + "next": "^6.0.3", "octicons": "7.2.0", - "parcel": "^1.8.1", "react": "^16.4.0", "react-dom": "^16.4.0" }, diff --git a/lib/octicons_react/pages/_document.js b/lib/octicons_react/pages/_document.js new file mode 100644 index 000000000..dc0654405 --- /dev/null +++ b/lib/octicons_react/pages/_document.js @@ -0,0 +1,17 @@ +import Document, { Head, Main, NextScript } from 'next/document' + +export default class PrimerDocument extends Document { + render() { + return ( + + + + + +
+ + + + ) + } +} diff --git a/lib/octicons_react/example.js b/lib/octicons_react/pages/index.js similarity index 80% rename from lib/octicons_react/example.js rename to lib/octicons_react/pages/index.js index f9588fd6d..f1ed6b4e3 100644 --- a/lib/octicons_react/example.js +++ b/lib/octicons_react/pages/index.js @@ -1,9 +1,8 @@ import React from 'react' -import ReactDOM from 'react-dom' -import Octicon, {Alert, X, Zap} from './' +import Octicon, {Alert, X, Zap} from '../' -function App() { +export default function App() { return (
{[Alert, X, Zap].map((Icon, i) => ( @@ -19,5 +18,3 @@ function App() {
) } - -ReactDOM.render(, document.getElementById('app')) From 635b44466aee8ed9d054d90fc58f865392f7491b Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Fri, 8 Jun 2018 14:54:27 -0700 Subject: [PATCH 31/97] make a table --- lib/octicons_react/pages/index.js | 44 ++++++++++++++++++++++++------- 1 file changed, 34 insertions(+), 10 deletions(-) diff --git a/lib/octicons_react/pages/index.js b/lib/octicons_react/pages/index.js index f1ed6b4e3..4ebe7a779 100644 --- a/lib/octicons_react/pages/index.js +++ b/lib/octicons_react/pages/index.js @@ -5,16 +5,40 @@ import Octicon, {Alert, X, Zap} from '../' export default function App() { return (
- {[Alert, X, Zap].map((Icon, i) => ( -
-

{Icon.name}

-

with {'icon={Icon}'}:

-

with {''} as child:

-

medium:

-

large:

-

without {''}:

-
- ))} + + + + + + + + + + + + + {[Alert, X, Zap].map((Icon, i) => ( + + + + + + + + + ))} + +
Name{'icon={Icon}'}{''}mediumlargeno {''}
{Icon.name} + + + + + + + + + +
) } From 32a0078af431bf24fc8d499e038300e916f1f54c Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Fri, 8 Jun 2018 15:02:17 -0700 Subject: [PATCH 32/97] add pages to files list --- lib/octicons_react/package.json | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/octicons_react/package.json b/lib/octicons_react/package.json index 097f65849..1efdc205e 100644 --- a/lib/octicons_react/package.json +++ b/lib/octicons_react/package.json @@ -8,8 +8,9 @@ "main": "index.js", "repository": "https://github.com/primer/octicons.git", "files": [ + "icons", "index.js", - "icons" + "pages" ], "scripts": { "start": "next", From 5c07b328ec4513e0014fd2f717b02e6b35c90db2 Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Mon, 25 Jun 2018 14:34:15 -0700 Subject: [PATCH 33/97] reasonable FIGMA_DOMAIN default; bail on missing FIGMA_TOKEN --- script/export | 20 +++++++++++++++----- 1 file changed, 15 insertions(+), 5 deletions(-) diff --git a/script/export b/script/export index f431d0029..312a40169 100755 --- a/script/export +++ b/script/export @@ -18,6 +18,16 @@ try { return process.exit(1) } +const { + FIGMA_DOMAIN = 'api.figma.com', + FIGMA_TOKEN +} = process.env + +if (!FIGMA_TOKEN) { + console.error('You must set FIGMA_TOKEN to a Figma personal access token.') + process.exit(1) +} + spinner.info(`Exporting octicons from ${figma.url} file`) // Where we're putting the exported SVG and data.json @@ -30,9 +40,9 @@ let oCount = 0 const getFigmaComponents = () => { return new Promise((resolve, reject) => { spinner.info("Getting components from the figma file") - spinner.start(`Contacting ${process.env.FIGMA_DOMAIN}`) - got.get(`${process.env.FIGMA_DOMAIN}/v1/files/${figmaFileKey}`, { - headers: { "Content-Type": "application/json", "x-figma-token": process.env.FIGMA_TOKEN }, + spinner.start(`Contacting ${FIGMA_DOMAIN}`) + got.get(`${FIGMA_DOMAIN}/v1/files/${figmaFileKey}`, { + headers: { "Content-Type": "application/json", "x-figma-token": FIGMA_TOKEN }, json: true }) .then( response => { @@ -66,12 +76,12 @@ const getFigmaComponents = () => { const getFigmaImageUrls = (componentIds) => { spinner.info("Exporting figma components as SVG") return new Promise((resolve, reject) => { - got.get(`${process.env.FIGMA_DOMAIN}/v1/images/${figmaFileKey}`, { + got.get(`${FIGMA_DOMAIN}/v1/images/${figmaFileKey}`, { query: { ids: componentIds, format: "svg" }, - headers: { "Content-Type": "application/json", "x-figma-token": process.env.FIGMA_TOKEN }, + headers: { "Content-Type": "application/json", "x-figma-token": FIGMA_TOKEN }, json: true }) .then( response => { From e030c2c65b5642d7f9414e7a4b9e84a8282cfe0d Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Mon, 25 Jun 2018 14:34:29 -0700 Subject: [PATCH 34/97] remove unneeded rubocop:disable --- lib/octicons_jekyll/lib/jekyll-octicons.rb | 1 - 1 file changed, 1 deletion(-) diff --git a/lib/octicons_jekyll/lib/jekyll-octicons.rb b/lib/octicons_jekyll/lib/jekyll-octicons.rb index 9c91560c7..7a306dba2 100644 --- a/lib/octicons_jekyll/lib/jekyll-octicons.rb +++ b/lib/octicons_jekyll/lib/jekyll-octicons.rb @@ -1,4 +1,3 @@ -# rubocop:disable Naming/FileName require "octicons" require "jekyll-octicons/version" require "liquid" From 2cf602ceac48718e261372c8760342f2a1ec5204 Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Mon, 25 Jun 2018 15:37:20 -0700 Subject: [PATCH 35/97] tidy --- lib/octicons_react/index.js | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/lib/octicons_react/index.js b/lib/octicons_react/index.js index 490a46108..9bb7608d8 100644 --- a/lib/octicons_react/index.js +++ b/lib/octicons_react/index.js @@ -11,6 +11,8 @@ const alignMap = { middle: 'middle' } +const defaultSize = [16, 16] + export default function Octicon(props) { const { ariaLabel, @@ -25,12 +27,12 @@ export default function Octicon(props) { ? : React.Children.only(children) - const [width, height] = child.type.size || [16, 16] + const [width, height] = child.type.size || defaultSize const attrs = { - 'aria-label': ariaLabel, + ariaLabel, className, - role: 'img', height: height, + role: 'img', viewBox: [0, 0, width, height].join(' ') } @@ -61,4 +63,6 @@ Octicon.propTypes = { ]) } +// this exports all of the icon classes as named exports, which can be +// tree-shaken by tools such as webpack, rollup, etc. export * from './icons' From 85a6fe204c9a6bf7800e9bd3ddac779b09d5eed4 Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Mon, 25 Jun 2018 15:37:39 -0700 Subject: [PATCH 36/97] add icons/all endpoint for named icons --- lib/octicons_react/icons/all.js | 358 +++++++++++++++++++++++++++++ lib/octicons_react/script/build.js | 37 ++- 2 files changed, 391 insertions(+), 4 deletions(-) create mode 100644 lib/octicons_react/icons/all.js diff --git a/lib/octicons_react/icons/all.js b/lib/octicons_react/icons/all.js new file mode 100644 index 000000000..e73be2f2a --- /dev/null +++ b/lib/octicons_react/icons/all.js @@ -0,0 +1,358 @@ + +import {default as Alert} from './alert' +import {default as ArrowDown} from './arrow-down' +import {default as ArrowLeft} from './arrow-left' +import {default as ArrowRight} from './arrow-right' +import {default as ArrowUp} from './arrow-up' +import {default as ArrowSmallDown} from './arrow-small-down' +import {default as ArrowSmallLeft} from './arrow-small-left' +import {default as ArrowSmallRight} from './arrow-small-right' +import {default as ArrowSmallUp} from './arrow-small-up' +import {default as Beaker} from './beaker' +import {default as Bell} from './bell' +import {default as Bold} from './bold' +import {default as Book} from './book' +import {default as Bookmark} from './bookmark' +import {default as Briefcase} from './briefcase' +import {default as Broadcast} from './broadcast' +import {default as Browser} from './browser' +import {default as Bug} from './bug' +import {default as Calendar} from './calendar' +import {default as Check} from './check' +import {default as Checklist} from './checklist' +import {default as ChevronDown} from './chevron-down' +import {default as ChevronLeft} from './chevron-left' +import {default as ChevronRight} from './chevron-right' +import {default as ChevronUp} from './chevron-up' +import {default as CircleSlash} from './circle-slash' +import {default as CircuitBoard} from './circuit-board' +import {default as Clippy} from './clippy' +import {default as Clock} from './clock' +import {default as CloudDownload} from './cloud-download' +import {default as CloudUpload} from './cloud-upload' +import {default as Code} from './code' +import {default as CommentDiscussion} from './comment-discussion' +import {default as Comment} from './comment' +import {default as CreditCard} from './credit-card' +import {default as Dash} from './dash' +import {default as Dashboard} from './dashboard' +import {default as Database} from './database' +import {default as DesktopDownload} from './desktop-download' +import {default as DeviceCameraVideo} from './device-camera-video' +import {default as DeviceCamera} from './device-camera' +import {default as DeviceDesktop} from './device-desktop' +import {default as DeviceMobile} from './device-mobile' +import {default as DiffAdded} from './diff-added' +import {default as DiffIgnored} from './diff-ignored' +import {default as DiffModified} from './diff-modified' +import {default as DiffRemoved} from './diff-removed' +import {default as DiffRenamed} from './diff-renamed' +import {default as Diff} from './diff' +import {default as Ellipsis} from './ellipsis' +import {default as Eye} from './eye' +import {default as FileBinary} from './file-binary' +import {default as FileCode} from './file-code' +import {default as FileDirectory} from './file-directory' +import {default as FileMedia} from './file-media' +import {default as FilePdf} from './file-pdf' +import {default as FileSubmodule} from './file-submodule' +import {default as FileSymlinkDirectory} from './file-symlink-directory' +import {default as FileSymlinkFile} from './file-symlink-file' +import {default as File} from './file' +import {default as FileZip} from './file-zip' +import {default as Flame} from './flame' +import {default as Fold} from './fold' +import {default as Gear} from './gear' +import {default as Gift} from './gift' +import {default as GistSecret} from './gist-secret' +import {default as Gist} from './gist' +import {default as GitBranch} from './git-branch' +import {default as GitCommit} from './git-commit' +import {default as GitCompare} from './git-compare' +import {default as GitMerge} from './git-merge' +import {default as GitPullRequest} from './git-pull-request' +import {default as Globe} from './globe' +import {default as Graph} from './graph' +import {default as Heart} from './heart' +import {default as History} from './history' +import {default as Home} from './home' +import {default as HorizontalRule} from './horizontal-rule' +import {default as Hubot} from './hubot' +import {default as Inbox} from './inbox' +import {default as Info} from './info' +import {default as IssueClosed} from './issue-closed' +import {default as IssueOpened} from './issue-opened' +import {default as IssueReopened} from './issue-reopened' +import {default as Italic} from './italic' +import {default as Jersey} from './jersey' +import {default as Keyboard} from './keyboard' +import {default as Law} from './law' +import {default as Link} from './link' +import {default as ListOrdered} from './list-ordered' +import {default as ListUnordered} from './list-unordered' +import {default as Location} from './location' +import {default as Lock} from './lock' +import {default as LogoGist} from './logo-gist' +import {default as LogoGithub} from './logo-github' +import {default as MailRead} from './mail-read' +import {default as Reply} from './reply' +import {default as Mail} from './mail' +import {default as MarkGithub} from './mark-github' +import {default as Markdown} from './markdown' +import {default as Megaphone} from './megaphone' +import {default as Mention} from './mention' +import {default as Milestone} from './milestone' +import {default as Mirror} from './mirror' +import {default as MortarBoard} from './mortar-board' +import {default as Mute} from './mute' +import {default as NoNewline} from './no-newline' +import {default as Octoface} from './octoface' +import {default as Organization} from './organization' +import {default as Package} from './package' +import {default as Paintcan} from './paintcan' +import {default as Pencil} from './pencil' +import {default as Person} from './person' +import {default as Pin} from './pin' +import {default as Plug} from './plug' +import {default as Plus} from './plus' +import {default as PrimitiveDot} from './primitive-dot' +import {default as PrimitiveSquare} from './primitive-square' +import {default as Pulse} from './pulse' +import {default as Question} from './question' +import {default as Quote} from './quote' +import {default as RadioTower} from './radio-tower' +import {default as RepoClone} from './repo-clone' +import {default as RepoForcePush} from './repo-force-push' +import {default as RepoForked} from './repo-forked' +import {default as RepoPull} from './repo-pull' +import {default as RepoPush} from './repo-push' +import {default as Repo} from './repo' +import {default as Rocket} from './rocket' +import {default as Rss} from './rss' +import {default as Ruby} from './ruby' +import {default as Search} from './search' +import {default as Server} from './server' +import {default as Settings} from './settings' +import {default as Shield} from './shield' +import {default as SignIn} from './sign-in' +import {default as SignOut} from './sign-out' +import {default as Smiley} from './smiley' +import {default as Squirrel} from './squirrel' +import {default as Star} from './star' +import {default as Stop} from './stop' +import {default as Sync} from './sync' +import {default as Tag} from './tag' +import {default as Tasklist} from './tasklist' +import {default as Telescope} from './telescope' +import {default as Terminal} from './terminal' +import {default as TextSize} from './text-size' +import {default as ThreeBars} from './three-bars' +import {default as Thumbsdown} from './thumbsdown' +import {default as Thumbsup} from './thumbsup' +import {default as Tools} from './tools' +import {default as Trashcan} from './trashcan' +import {default as TriangleDown} from './triangle-down' +import {default as TriangleLeft} from './triangle-left' +import {default as TriangleRight} from './triangle-right' +import {default as TriangleUp} from './triangle-up' +import {default as Unfold} from './unfold' +import {default as Unmute} from './unmute' +import {default as Project} from './project' +import {default as KebabHorizontal} from './kebab-horizontal' +import {default as KebabVertical} from './kebab-vertical' +import {default as Report} from './report' +import {default as Note} from './note' +import {default as ScreenFull} from './screen-full' +import {default as ScreenNormal} from './screen-normal' +import {default as Unverified} from './unverified' +import {default as Verified} from './verified' +import {default as Versions} from './versions' +import {default as Watch} from './watch' +import {default as X} from './x' +import {default as Zap} from './zap' +import {default as Key} from './key' +import {default as Grabber} from './grabber' +import {default as PlusSmall} from './plus-small' +import {default as LightBulb} from './light-bulb' +import {default as LinkExternal} from './link-external' + +const iconsByKey = { + 'alert': Alert, + 'arrow-down': ArrowDown, + 'arrow-left': ArrowLeft, + 'arrow-right': ArrowRight, + 'arrow-up': ArrowUp, + 'arrow-small-down': ArrowSmallDown, + 'arrow-small-left': ArrowSmallLeft, + 'arrow-small-right': ArrowSmallRight, + 'arrow-small-up': ArrowSmallUp, + 'beaker': Beaker, + 'bell': Bell, + 'bold': Bold, + 'book': Book, + 'bookmark': Bookmark, + 'briefcase': Briefcase, + 'broadcast': Broadcast, + 'browser': Browser, + 'bug': Bug, + 'calendar': Calendar, + 'check': Check, + 'checklist': Checklist, + 'chevron-down': ChevronDown, + 'chevron-left': ChevronLeft, + 'chevron-right': ChevronRight, + 'chevron-up': ChevronUp, + 'circle-slash': CircleSlash, + 'circuit-board': CircuitBoard, + 'clippy': Clippy, + 'clock': Clock, + 'cloud-download': CloudDownload, + 'cloud-upload': CloudUpload, + 'code': Code, + 'comment-discussion': CommentDiscussion, + 'comment': Comment, + 'credit-card': CreditCard, + 'dash': Dash, + 'dashboard': Dashboard, + 'database': Database, + 'desktop-download': DesktopDownload, + 'device-camera-video': DeviceCameraVideo, + 'device-camera': DeviceCamera, + 'device-desktop': DeviceDesktop, + 'device-mobile': DeviceMobile, + 'diff-added': DiffAdded, + 'diff-ignored': DiffIgnored, + 'diff-modified': DiffModified, + 'diff-removed': DiffRemoved, + 'diff-renamed': DiffRenamed, + 'diff': Diff, + 'ellipsis': Ellipsis, + 'eye': Eye, + 'file-binary': FileBinary, + 'file-code': FileCode, + 'file-directory': FileDirectory, + 'file-media': FileMedia, + 'file-pdf': FilePdf, + 'file-submodule': FileSubmodule, + 'file-symlink-directory': FileSymlinkDirectory, + 'file-symlink-file': FileSymlinkFile, + 'file': File, + 'file-zip': FileZip, + 'flame': Flame, + 'fold': Fold, + 'gear': Gear, + 'gift': Gift, + 'gist-secret': GistSecret, + 'gist': Gist, + 'git-branch': GitBranch, + 'git-commit': GitCommit, + 'git-compare': GitCompare, + 'git-merge': GitMerge, + 'git-pull-request': GitPullRequest, + 'globe': Globe, + 'graph': Graph, + 'heart': Heart, + 'history': History, + 'home': Home, + 'horizontal-rule': HorizontalRule, + 'hubot': Hubot, + 'inbox': Inbox, + 'info': Info, + 'issue-closed': IssueClosed, + 'issue-opened': IssueOpened, + 'issue-reopened': IssueReopened, + 'italic': Italic, + 'jersey': Jersey, + 'keyboard': Keyboard, + 'law': Law, + 'link': Link, + 'list-ordered': ListOrdered, + 'list-unordered': ListUnordered, + 'location': Location, + 'lock': Lock, + 'logo-gist': LogoGist, + 'logo-github': LogoGithub, + 'mail-read': MailRead, + 'reply': Reply, + 'mail': Mail, + 'mark-github': MarkGithub, + 'markdown': Markdown, + 'megaphone': Megaphone, + 'mention': Mention, + 'milestone': Milestone, + 'mirror': Mirror, + 'mortar-board': MortarBoard, + 'mute': Mute, + 'no-newline': NoNewline, + 'octoface': Octoface, + 'organization': Organization, + 'package': Package, + 'paintcan': Paintcan, + 'pencil': Pencil, + 'person': Person, + 'pin': Pin, + 'plug': Plug, + 'plus': Plus, + 'primitive-dot': PrimitiveDot, + 'primitive-square': PrimitiveSquare, + 'pulse': Pulse, + 'question': Question, + 'quote': Quote, + 'radio-tower': RadioTower, + 'repo-clone': RepoClone, + 'repo-force-push': RepoForcePush, + 'repo-forked': RepoForked, + 'repo-pull': RepoPull, + 'repo-push': RepoPush, + 'repo': Repo, + 'rocket': Rocket, + 'rss': Rss, + 'ruby': Ruby, + 'search': Search, + 'server': Server, + 'settings': Settings, + 'shield': Shield, + 'sign-in': SignIn, + 'sign-out': SignOut, + 'smiley': Smiley, + 'squirrel': Squirrel, + 'star': Star, + 'stop': Stop, + 'sync': Sync, + 'tag': Tag, + 'tasklist': Tasklist, + 'telescope': Telescope, + 'terminal': Terminal, + 'text-size': TextSize, + 'three-bars': ThreeBars, + 'thumbsdown': Thumbsdown, + 'thumbsup': Thumbsup, + 'tools': Tools, + 'trashcan': Trashcan, + 'triangle-down': TriangleDown, + 'triangle-left': TriangleLeft, + 'triangle-right': TriangleRight, + 'triangle-up': TriangleUp, + 'unfold': Unfold, + 'unmute': Unmute, + 'project': Project, + 'kebab-horizontal': KebabHorizontal, + 'kebab-vertical': KebabVertical, + 'report': Report, + 'note': Note, + 'screen-full': ScreenFull, + 'screen-normal': ScreenNormal, + 'unverified': Unverified, + 'verified': Verified, + 'versions': Versions, + 'watch': Watch, + 'x': X, + 'zap': Zap, + 'key': Key, + 'grabber': Grabber, + 'plus-small': PlusSmall, + 'light-bulb': LightBulb, + 'link-external': LinkExternal, +} + +export default key => iconsByKey[key] \ No newline at end of file diff --git a/lib/octicons_react/script/build.js b/lib/octicons_react/script/build.js index e4f9f9295..e52f2b01a 100755 --- a/lib/octicons_react/script/build.js +++ b/lib/octicons_react/script/build.js @@ -34,15 +34,44 @@ const tasks = icons.map(({key, name, code}) => { .then(() => ({key, name, file})) }) -Promise.all(tasks).then(written => { - const count = written.length +function writeIndex(icons) { + const count = icons.length console.warn('wrote %d files to %s.', count, DIR) const file = join(DIR, 'index.js') - const code = written.map(({key, name}) => ( + const code = icons.map(({key, name}) => ( `export {default as ${name}} from './${key}'` )).join('\n') return fse.writeFile(file, code, 'utf8') .then(() => { console.warn('wrote %s with %d exports', file, count) + return icons }) -}) +} + +function writeAll(icons) { + const file = join(DIR, 'all.js') + const code = ` +${icons.map(({key, name}) => ( + `import {default as ${name}} from './${key}'` +)).join('\n')} + +const iconsByKey = { +${icons.map(({key, name}) => ` '${key}': ${name},`).join('\n')} +} + +export default key => iconsByKey[key]` + return fse.writeFile(file, code, 'utf8') + .then(() => { + console.warn('wrote %s with all exports', file) + }) +} + +Promise.all(tasks) + .then(icons => Promise.all([ + writeIndex(icons), + writeAll(icons) + ])) + .catch(error => { + console.error(error) + process.exit(1) + }) From f58779614372c623e3b075a54ccb8adc12bbcf8e Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Mon, 25 Jun 2018 15:38:08 -0700 Subject: [PATCH 37/97] clean up deps, add jest --- lib/octicons_react/package.json | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/lib/octicons_react/package.json b/lib/octicons_react/package.json index 1efdc205e..434d0b782 100644 --- a/lib/octicons_react/package.json +++ b/lib/octicons_react/package.json @@ -14,6 +14,7 @@ ], "scripts": { "start": "next", + "test": "jest", "publish": "../../script/notify success", "prepublishOnly": "../../script/notify pending", "prepare": "script/build.js" @@ -29,16 +30,18 @@ "react", "primer" ], + "dependencies": { + "react": "^16.4.0", + "prop-types": "^15.6.1" + }, "devDependencies": { "babel-preset-env": "^1.7.0", "babel-preset-react": "^6.24.1", "fs-extra": "^6.0.1", + "jest": "^23.2.0", "next": "^6.0.3", "octicons": "7.2.0", - "react": "^16.4.0", - "react-dom": "^16.4.0" - }, - "dependencies": { - "prop-types": "^15.6.1" + "react-dom": "^16.4.1", + "react-test-renderer": "^16.4.1" } } From 62487aa5187590406ba4e770844fab544316e1e3 Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Mon, 25 Jun 2018 15:38:17 -0700 Subject: [PATCH 38/97] add basic tests --- lib/octicons_react/__tests__/all.js | 13 +++++++ lib/octicons_react/__tests__/octicon.js | 50 +++++++++++++++++++++++++ 2 files changed, 63 insertions(+) create mode 100644 lib/octicons_react/__tests__/all.js create mode 100644 lib/octicons_react/__tests__/octicon.js diff --git a/lib/octicons_react/__tests__/all.js b/lib/octicons_react/__tests__/all.js new file mode 100644 index 000000000..a597f54a4 --- /dev/null +++ b/lib/octicons_react/__tests__/all.js @@ -0,0 +1,13 @@ +import React from 'react' +import getIcon from '../icons/all' +import renderer from 'react-test-renderer' +import {Zap} from '../' + +const render = el => renderer.create(el).toJSON() + +describe("import getIcon from '@github/octicons-react/icons/all'", () => { + it('gets named icons', () => { + const Icon = getIcon('zap') + expect(render()).toEqual(render()) + }) +}) diff --git a/lib/octicons_react/__tests__/octicon.js b/lib/octicons_react/__tests__/octicon.js new file mode 100644 index 000000000..40e86617f --- /dev/null +++ b/lib/octicons_react/__tests__/octicon.js @@ -0,0 +1,50 @@ +import React from 'react' +import Octicon from '../' +import renderer from 'react-test-renderer' + +const render = el => renderer.create(el).toJSON() + +describe('', () => { + + it('throws an error without a single child or icon prop', () => { + expect(() => render()).toThrow() + expect(() => render()).toThrow() + }) + + it('outputs ', () => { + const rendered = render() + expect(rendered.type).toEqual('svg') + }) + + describe('with as child', () => { + it('generates a default viewBox', () => { + const rendered = render() + expect(rendered.props.viewBox).toEqual('0 0 16 16') + }) + + it('generates default viewBox', () => { + const rendered = render() + expect(rendered.props.viewBox).toEqual('0 0 16 16') + }) + }) + + function Icon() { + return + } + Icon.size = [12, 20] + + describe('with an child', () => { + it('generates the right viewBox', () => { + const rendered = render() + expect(rendered.props.viewBox).toEqual('0 0 12 20') + }) + }) + + describe('with an icon={Icon} prop', () => { + it('generates the right viewBox', () => { + const rendered = render() + expect(rendered.props.viewBox).toEqual('0 0 12 20') + }) + }) + +}) From e7bdde99e040989d02a9be915c63cb6a0bc5b9a4 Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Mon, 25 Jun 2018 15:38:26 -0700 Subject: [PATCH 39/97] add .babelrc that works with jest and next --- lib/octicons_react/.babelrc | 8 ++++++++ 1 file changed, 8 insertions(+) create mode 100644 lib/octicons_react/.babelrc diff --git a/lib/octicons_react/.babelrc b/lib/octicons_react/.babelrc new file mode 100644 index 000000000..a0b632b1a --- /dev/null +++ b/lib/octicons_react/.babelrc @@ -0,0 +1,8 @@ +{ + "presets": ["env", "react"], + "env": { + "development": { + "presets": ["next/babel"] + } + } +} From 8404d60d38c69fd5b2e728bfa8535ebc003ae934 Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Mon, 25 Jun 2018 15:38:43 -0700 Subject: [PATCH 40/97] add getIcon(name) example to demo app --- lib/octicons_react/pages/index.js | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/lib/octicons_react/pages/index.js b/lib/octicons_react/pages/index.js index 4ebe7a779..688103f5c 100644 --- a/lib/octicons_react/pages/index.js +++ b/lib/octicons_react/pages/index.js @@ -1,6 +1,7 @@ import React from 'react' import Octicon, {Alert, X, Zap} from '../' +import getIcon from '../icons/all' export default function App() { return ( @@ -11,13 +12,14 @@ export default function App() { Name {'icon={Icon}'} {''} + {"getIcon('name')"} medium large no {''} - {[Alert, X, Zap].map((Icon, i) => ( + {[[Alert, 'alert'], [X, 'x'], [Zap, 'zap']].map(([Icon, key], i) => ( {Icon.name} @@ -26,6 +28,9 @@ export default function App() { + + + From 4d6dc4251c7da6da162e813edb972a0ff59b8d7c Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Mon, 25 Jun 2018 15:38:55 -0700 Subject: [PATCH 41/97] start fleshing out new docs --- lib/octicons_react/README.md | 36 ++++++++++++++++++++---------------- 1 file changed, 20 insertions(+), 16 deletions(-) diff --git a/lib/octicons_react/README.md b/lib/octicons_react/README.md index c93b34ba0..755d3ecc8 100644 --- a/lib/octicons_react/README.md +++ b/lib/octicons_react/README.md @@ -13,26 +13,30 @@ $ npm install @github/octicons-react --save ## Usage -The entire library will be available when importing `@github/octicons-react`. Specifying the [icon you want to use][octicons], by supplying the `name=""` to the component. - -```js -// Example usage -import Octicon from "@github/octicons-react" - -return ( - -) +### `` +The `` component is really just the "shell" of an octicon which +handles the `` element and all of its attributes. To render a specific +icon, you must pass it either via `icon` prop or as a child: + +```jsx +// icon prop (function) + +// icon prop (element) +} /> +// child + ``` -You can also import only the icons you need by importing the specific icon names. This is useful if you’re trying to keep bundle size down. +### Icons +In order to avoid bloating builds, the `@github/octicons-react` ES6 module +exports the `Octicon` component as `default`, and the individual icon symbols +as separate [named exports]. This means that you have to import only the icons +that you need: -```js -// Example usage -import { AlertOcticon, RepoOcticon, XOcticon } from "@github/octicons-react/named" +```jsx +import Octicon, {Beaker, Zap} from '@github/octicons-react' -return ( - -) +module.exports = ({boom}) => ``` ### Alignment From c86a79278ee979f19ba08172c41dabb4a14e9329 Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Mon, 25 Jun 2018 16:20:15 -0700 Subject: [PATCH 42/97] add "small" size --- lib/octicons_react/index.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/octicons_react/index.js b/lib/octicons_react/index.js index 9bb7608d8..fe4f64d70 100644 --- a/lib/octicons_react/index.js +++ b/lib/octicons_react/index.js @@ -2,6 +2,7 @@ import React from 'react' import PropTypes from 'prop-types' const sizeMap = { + small: 16, medium: 32, large: 64 } @@ -57,7 +58,7 @@ Octicon.propTypes = { ariaLabel: PropTypes.string, children: PropTypes.element, icon: PropTypes.func, - size: PropTypes.oneOf(['medium', 'large']), + size: PropTypes.oneOf(Object.keys(sizeMap)), verticalAlign: PropTypes.oneOf([ 'middle', 'text-bottom', 'text-top', 'top' ]) From 5adf596736d3f25ab3a2fdc32cba23cb07a5b673 Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Mon, 25 Jun 2018 16:21:27 -0700 Subject: [PATCH 43/97] add iconsByName object export to icons/all --- lib/octicons_react/__tests__/all.js | 12 ++++++++---- lib/octicons_react/icons/all.js | 11 ++++++++--- lib/octicons_react/script/build.js | 14 ++++++++++---- 3 files changed, 26 insertions(+), 11 deletions(-) diff --git a/lib/octicons_react/__tests__/all.js b/lib/octicons_react/__tests__/all.js index a597f54a4..dd99e69e1 100644 --- a/lib/octicons_react/__tests__/all.js +++ b/lib/octicons_react/__tests__/all.js @@ -1,13 +1,17 @@ import React from 'react' -import getIcon from '../icons/all' +import getIconByName, {iconsByName} from '../icons/all' import renderer from 'react-test-renderer' -import {Zap} from '../' +import {Alert, Zap} from '../' const render = el => renderer.create(el).toJSON() -describe("import getIcon from '@github/octicons-react/icons/all'", () => { +describe("import {getIconByName} from '@github/octicons-react/icons/all'", () => { it('gets named icons', () => { - const Icon = getIcon('zap') + const Icon = getIconByName('zap') expect(render()).toEqual(render()) }) + + it('gets all the icons', () => { + expect(iconsByName.alert).toEqual(Alert) + }) }) diff --git a/lib/octicons_react/icons/all.js b/lib/octicons_react/icons/all.js index e73be2f2a..e04708245 100644 --- a/lib/octicons_react/icons/all.js +++ b/lib/octicons_react/icons/all.js @@ -1,4 +1,3 @@ - import {default as Alert} from './alert' import {default as ArrowDown} from './arrow-down' import {default as ArrowLeft} from './arrow-left' @@ -176,7 +175,7 @@ import {default as PlusSmall} from './plus-small' import {default as LightBulb} from './light-bulb' import {default as LinkExternal} from './link-external' -const iconsByKey = { +const iconsByName = { 'alert': Alert, 'arrow-down': ArrowDown, 'arrow-left': ArrowLeft, @@ -355,4 +354,10 @@ const iconsByKey = { 'link-external': LinkExternal, } -export default key => iconsByKey[key] \ No newline at end of file +export default function getIconByName(name) { + return iconsByName[name] +} + +export { + iconsByName +} diff --git a/lib/octicons_react/script/build.js b/lib/octicons_react/script/build.js index e52f2b01a..0ff62e8f1 100755 --- a/lib/octicons_react/script/build.js +++ b/lib/octicons_react/script/build.js @@ -50,16 +50,22 @@ function writeIndex(icons) { function writeAll(icons) { const file = join(DIR, 'all.js') - const code = ` -${icons.map(({key, name}) => ( + const code = `${icons.map(({key, name}) => ( `import {default as ${name}} from './${key}'` )).join('\n')} -const iconsByKey = { +const iconsByName = { ${icons.map(({key, name}) => ` '${key}': ${name},`).join('\n')} } -export default key => iconsByKey[key]` +export default function getIconByName(name) { + return iconsByName[name] +} + +export { + iconsByName +} +` return fse.writeFile(file, code, 'utf8') .then(() => { console.warn('wrote %s with all exports', file) From 59e2c22d5bf04056b437920500493504f308c3ff Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Mon, 25 Jun 2018 16:21:37 -0700 Subject: [PATCH 44/97] moar docs --- lib/octicons_react/README.md | 69 +++++++++++++++++++++++++++++++----- 1 file changed, 60 insertions(+), 9 deletions(-) diff --git a/lib/octicons_react/README.md b/lib/octicons_react/README.md index 755d3ecc8..7ec37edb7 100644 --- a/lib/octicons_react/README.md +++ b/lib/octicons_react/README.md @@ -22,21 +22,72 @@ icon, you must pass it either via `icon` prop or as a child: // icon prop (function) // icon prop (element) -} /> +} /> // child ``` ### Icons -In order to avoid bloating builds, the `@github/octicons-react` ES6 module -exports the `Octicon` component as `default`, and the individual icon symbols -as separate [named exports]. This means that you have to import only the icons -that you need: +The `@github/octicons-react` ES6 module exports the `Octicon` component as +`default` and the individual icon symbols as separate [named +exports](https://ponyfoo.com/articles/es6-modules-in-depth#named-exports). This +allows you to import only the icons that you need without blowing up your +bundle: ```jsx +import React from 'react' import Octicon, {Beaker, Zap} from '@github/octicons-react' -module.exports = ({boom}) => +export default function Icon({boom}) { + return +} +``` + +If you were to compile this example with a tool that supports [tree-shaking], +the resulting bundle would only include the "zap" and "beaker" icons. + +### All icons +If you don't mind your bundle being huge or you need to be able to render +arbitrarily named icons at runtime, there's a special `all` export which +provides you with two ways to get any icon: + +#### Icons by name +The default export of `@github/octicons-react/icons/all` is a function that +takes a lowercase octicon name (such as `arrow-right`) and returns the +corresponding icon class. Using this helper, it's possible to create an Octicon +class that takes a `name` prop: + +```jsx +import React from 'react' +import Octicon from '@github/octicons-react' +import allOcticons from '@github/octicons-react/icons/all' + +export default function OcticonByName({name, ...props}) { + return +} +``` + +`@github/octicons-react/icons/all` also exports a `iconsByName` object that +maps keys (such as `arrow-right`) to component functions, which you can use to +generate listings of all the octicons: + +```jsx +import React from 'react' +import Octicon from '@github/octicons-react' +import getIcon, {iconsByName} from '@github/octicons-react/icons/all' + +export default function OcticonsList() { + return ( +
    + {Object.keys(iconsByName).map(key => ( +
  • + {key} + +
  • + ))} +
+ ) +} ``` ### Alignment @@ -47,7 +98,7 @@ By default the octicons have `vertical-align: text-bottom;` applied to them. But // Example usage import Octicon from "@github/octicons-react" -return ( +export default () => (

github/github

@@ -63,7 +114,7 @@ You have the option to add accessibility information to the icon using `aria-lab // Example usage import Octicon from "@github/octicons-react" -return ( +export default () => ( @@ -85,7 +136,7 @@ The properties `large`, `medium`, `small` are available for setting the size of // Example usage import Octicon from "@github/octicons-react" -return ( +export default () => (

From 7df502a5398f2947b556c7f2b84e0e34c6dc3a97 Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Mon, 25 Jun 2018 16:22:31 -0700 Subject: [PATCH 45/97] add tree-shaking link --- lib/octicons_react/README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/octicons_react/README.md b/lib/octicons_react/README.md index 7ec37edb7..b70866345 100644 --- a/lib/octicons_react/README.md +++ b/lib/octicons_react/README.md @@ -158,3 +158,4 @@ When using the GitHub logos, be sure to follow the [GitHub logo guidelines](http [docs]: http://primercss.io/ [npm]: https://www.npmjs.com/ [install-npm]: https://docs.npmjs.com/getting-started/installing-node +[tree-shaking]: https://developer.mozilla.org/en-US/docs/Glossary/Tree_shaking From 7ab2d070ed0ef098ad2c2864540a9f6d7d73e9b6 Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Mon, 25 Jun 2018 16:24:51 -0700 Subject: [PATCH 46/97] tidy up icon docs --- lib/octicons_react/README.md | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/lib/octicons_react/README.md b/lib/octicons_react/README.md index b70866345..fa4e68ec3 100644 --- a/lib/octicons_react/README.md +++ b/lib/octicons_react/README.md @@ -48,19 +48,19 @@ the resulting bundle would only include the "zap" and "beaker" icons. ### All icons If you don't mind your bundle being huge or you need to be able to render -arbitrarily named icons at runtime, there's a special `all` export which +arbitrarily named icons at runtime, there's a special `icons/all` entry which provides you with two ways to get any icon: -#### Icons by name +#### `getIconByName()` The default export of `@github/octicons-react/icons/all` is a function that takes a lowercase octicon name (such as `arrow-right`) and returns the corresponding icon class. Using this helper, it's possible to create an Octicon -class that takes a `name` prop: +class that takes a `name` prop and resolves it to the right component: ```jsx import React from 'react' import Octicon from '@github/octicons-react' -import allOcticons from '@github/octicons-react/icons/all' +import getIcon from '@github/octicons-react/icons/all' export default function OcticonByName({name, ...props}) { return @@ -74,7 +74,7 @@ generate listings of all the octicons: ```jsx import React from 'react' import Octicon from '@github/octicons-react' -import getIcon, {iconsByName} from '@github/octicons-react/icons/all' +import {iconsByName} from '@github/octicons-react/icons/all' export default function OcticonsList() { return ( @@ -82,7 +82,7 @@ export default function OcticonsList() { {Object.keys(iconsByName).map(key => (
  • {key} - +
  • ))} From 39df26ae10f9c8742f3292386ee11dbbe60e81ce Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Mon, 25 Jun 2018 16:31:13 -0700 Subject: [PATCH 47/97] updating props, examples --- lib/octicons_react/README.md | 36 ++++++++++++++++++++---------------- 1 file changed, 20 insertions(+), 16 deletions(-) diff --git a/lib/octicons_react/README.md b/lib/octicons_react/README.md index fa4e68ec3..0398bd5a7 100644 --- a/lib/octicons_react/README.md +++ b/lib/octicons_react/README.md @@ -67,6 +67,7 @@ export default function OcticonByName({name, ...props}) { } ``` +#### `iconsByName` object `@github/octicons-react/icons/all` also exports a `iconsByName` object that maps keys (such as `arrow-right`) to component functions, which you can use to generate listings of all the octicons: @@ -90,25 +91,26 @@ export default function OcticonsList() { } ``` -### Alignment - -By default the octicons have `vertical-align: text-bottom;` applied to them. But there are cases where you'll want to change the alignment. The props available are `top`, `middle`. +### Vertical alignment +By default the octicons have `vertical-align: text-bottom;` applied as inline +styles. You can change the alignment via the `verticalAlign` prop, which can be +either `middle`, `text-bottom`, `text-top`, or `top`. ```js -// Example usage -import Octicon from "@github/octicons-react" +import Octicon from '@github/octicons-react' export default () => (

    - github/github + github/github

    ) ``` -### ariaLabel - -You have the option to add accessibility information to the icon using `aria-label`. +### `ariaLabel` +You have the option of adding accessibility information to the icon with the +[`aria-label` attribute][aria-label] via the `ariaLabel` prop (note the +capitalization of `L`!). ```js // Example usage @@ -124,22 +126,23 @@ export default () => ( ### Sizes -The properties `large`, `medium`, `small` are available for setting the size of the icon. +The `size` prop takes `small`, `medium`, and `large` values that can be used to +render octicons at standard sizes: | Prop | Rendered Size | | :- | :- | -| Small | 16px height by `computed` width | -| Medium | 32px height by `computed` width | -| Large | 64px height by `computed` width | +| `size='small'` | 16px height by `computed` width | +| `size='medium'` | 32px height by `computed` width | +| `size='large'` | 64px height by `computed` width | ```js // Example usage -import Octicon from "@github/octicons-react" +import Octicon from '@github/octicons-react' export default () => (

    - - + +

    ) @@ -159,3 +162,4 @@ When using the GitHub logos, be sure to follow the [GitHub logo guidelines](http [npm]: https://www.npmjs.com/ [install-npm]: https://docs.npmjs.com/getting-started/installing-node [tree-shaking]: https://developer.mozilla.org/en-US/docs/Glossary/Tree_shaking +[aria-label]: https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/ARIA_Techniques/Using_the_aria-label_attribute From aa3e559cbb9bd67da9a8e7b49ad60c65c6321415 Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Tue, 26 Jun 2018 09:55:50 -0700 Subject: [PATCH 48/97] refactor all icons exports --- lib/octicons_react/__tests__/all.js | 7 +- lib/octicons_react/icons/all.js | 363 -------------- lib/octicons_react/icons/index.js | 717 +++++++++++++++++++++------- lib/octicons_react/script/build.js | 47 +- 4 files changed, 564 insertions(+), 570 deletions(-) delete mode 100644 lib/octicons_react/icons/all.js diff --git a/lib/octicons_react/__tests__/all.js b/lib/octicons_react/__tests__/all.js index dd99e69e1..79ae88818 100644 --- a/lib/octicons_react/__tests__/all.js +++ b/lib/octicons_react/__tests__/all.js @@ -1,16 +1,17 @@ import React from 'react' -import getIconByName, {iconsByName} from '../icons/all' +import {Alert, Zap, getIconByName, iconsByName} from '../' import renderer from 'react-test-renderer' -import {Alert, Zap} from '../' const render = el => renderer.create(el).toJSON() -describe("import {getIconByName} from '@github/octicons-react/icons/all'", () => { +describe("import {getIconByName}", () => { it('gets named icons', () => { const Icon = getIconByName('zap') expect(render()).toEqual(render()) }) +}) +describe("import {iconsByName} from '...'", () => { it('gets all the icons', () => { expect(iconsByName.alert).toEqual(Alert) }) diff --git a/lib/octicons_react/icons/all.js b/lib/octicons_react/icons/all.js deleted file mode 100644 index e04708245..000000000 --- a/lib/octicons_react/icons/all.js +++ /dev/null @@ -1,363 +0,0 @@ -import {default as Alert} from './alert' -import {default as ArrowDown} from './arrow-down' -import {default as ArrowLeft} from './arrow-left' -import {default as ArrowRight} from './arrow-right' -import {default as ArrowUp} from './arrow-up' -import {default as ArrowSmallDown} from './arrow-small-down' -import {default as ArrowSmallLeft} from './arrow-small-left' -import {default as ArrowSmallRight} from './arrow-small-right' -import {default as ArrowSmallUp} from './arrow-small-up' -import {default as Beaker} from './beaker' -import {default as Bell} from './bell' -import {default as Bold} from './bold' -import {default as Book} from './book' -import {default as Bookmark} from './bookmark' -import {default as Briefcase} from './briefcase' -import {default as Broadcast} from './broadcast' -import {default as Browser} from './browser' -import {default as Bug} from './bug' -import {default as Calendar} from './calendar' -import {default as Check} from './check' -import {default as Checklist} from './checklist' -import {default as ChevronDown} from './chevron-down' -import {default as ChevronLeft} from './chevron-left' -import {default as ChevronRight} from './chevron-right' -import {default as ChevronUp} from './chevron-up' -import {default as CircleSlash} from './circle-slash' -import {default as CircuitBoard} from './circuit-board' -import {default as Clippy} from './clippy' -import {default as Clock} from './clock' -import {default as CloudDownload} from './cloud-download' -import {default as CloudUpload} from './cloud-upload' -import {default as Code} from './code' -import {default as CommentDiscussion} from './comment-discussion' -import {default as Comment} from './comment' -import {default as CreditCard} from './credit-card' -import {default as Dash} from './dash' -import {default as Dashboard} from './dashboard' -import {default as Database} from './database' -import {default as DesktopDownload} from './desktop-download' -import {default as DeviceCameraVideo} from './device-camera-video' -import {default as DeviceCamera} from './device-camera' -import {default as DeviceDesktop} from './device-desktop' -import {default as DeviceMobile} from './device-mobile' -import {default as DiffAdded} from './diff-added' -import {default as DiffIgnored} from './diff-ignored' -import {default as DiffModified} from './diff-modified' -import {default as DiffRemoved} from './diff-removed' -import {default as DiffRenamed} from './diff-renamed' -import {default as Diff} from './diff' -import {default as Ellipsis} from './ellipsis' -import {default as Eye} from './eye' -import {default as FileBinary} from './file-binary' -import {default as FileCode} from './file-code' -import {default as FileDirectory} from './file-directory' -import {default as FileMedia} from './file-media' -import {default as FilePdf} from './file-pdf' -import {default as FileSubmodule} from './file-submodule' -import {default as FileSymlinkDirectory} from './file-symlink-directory' -import {default as FileSymlinkFile} from './file-symlink-file' -import {default as File} from './file' -import {default as FileZip} from './file-zip' -import {default as Flame} from './flame' -import {default as Fold} from './fold' -import {default as Gear} from './gear' -import {default as Gift} from './gift' -import {default as GistSecret} from './gist-secret' -import {default as Gist} from './gist' -import {default as GitBranch} from './git-branch' -import {default as GitCommit} from './git-commit' -import {default as GitCompare} from './git-compare' -import {default as GitMerge} from './git-merge' -import {default as GitPullRequest} from './git-pull-request' -import {default as Globe} from './globe' -import {default as Graph} from './graph' -import {default as Heart} from './heart' -import {default as History} from './history' -import {default as Home} from './home' -import {default as HorizontalRule} from './horizontal-rule' -import {default as Hubot} from './hubot' -import {default as Inbox} from './inbox' -import {default as Info} from './info' -import {default as IssueClosed} from './issue-closed' -import {default as IssueOpened} from './issue-opened' -import {default as IssueReopened} from './issue-reopened' -import {default as Italic} from './italic' -import {default as Jersey} from './jersey' -import {default as Keyboard} from './keyboard' -import {default as Law} from './law' -import {default as Link} from './link' -import {default as ListOrdered} from './list-ordered' -import {default as ListUnordered} from './list-unordered' -import {default as Location} from './location' -import {default as Lock} from './lock' -import {default as LogoGist} from './logo-gist' -import {default as LogoGithub} from './logo-github' -import {default as MailRead} from './mail-read' -import {default as Reply} from './reply' -import {default as Mail} from './mail' -import {default as MarkGithub} from './mark-github' -import {default as Markdown} from './markdown' -import {default as Megaphone} from './megaphone' -import {default as Mention} from './mention' -import {default as Milestone} from './milestone' -import {default as Mirror} from './mirror' -import {default as MortarBoard} from './mortar-board' -import {default as Mute} from './mute' -import {default as NoNewline} from './no-newline' -import {default as Octoface} from './octoface' -import {default as Organization} from './organization' -import {default as Package} from './package' -import {default as Paintcan} from './paintcan' -import {default as Pencil} from './pencil' -import {default as Person} from './person' -import {default as Pin} from './pin' -import {default as Plug} from './plug' -import {default as Plus} from './plus' -import {default as PrimitiveDot} from './primitive-dot' -import {default as PrimitiveSquare} from './primitive-square' -import {default as Pulse} from './pulse' -import {default as Question} from './question' -import {default as Quote} from './quote' -import {default as RadioTower} from './radio-tower' -import {default as RepoClone} from './repo-clone' -import {default as RepoForcePush} from './repo-force-push' -import {default as RepoForked} from './repo-forked' -import {default as RepoPull} from './repo-pull' -import {default as RepoPush} from './repo-push' -import {default as Repo} from './repo' -import {default as Rocket} from './rocket' -import {default as Rss} from './rss' -import {default as Ruby} from './ruby' -import {default as Search} from './search' -import {default as Server} from './server' -import {default as Settings} from './settings' -import {default as Shield} from './shield' -import {default as SignIn} from './sign-in' -import {default as SignOut} from './sign-out' -import {default as Smiley} from './smiley' -import {default as Squirrel} from './squirrel' -import {default as Star} from './star' -import {default as Stop} from './stop' -import {default as Sync} from './sync' -import {default as Tag} from './tag' -import {default as Tasklist} from './tasklist' -import {default as Telescope} from './telescope' -import {default as Terminal} from './terminal' -import {default as TextSize} from './text-size' -import {default as ThreeBars} from './three-bars' -import {default as Thumbsdown} from './thumbsdown' -import {default as Thumbsup} from './thumbsup' -import {default as Tools} from './tools' -import {default as Trashcan} from './trashcan' -import {default as TriangleDown} from './triangle-down' -import {default as TriangleLeft} from './triangle-left' -import {default as TriangleRight} from './triangle-right' -import {default as TriangleUp} from './triangle-up' -import {default as Unfold} from './unfold' -import {default as Unmute} from './unmute' -import {default as Project} from './project' -import {default as KebabHorizontal} from './kebab-horizontal' -import {default as KebabVertical} from './kebab-vertical' -import {default as Report} from './report' -import {default as Note} from './note' -import {default as ScreenFull} from './screen-full' -import {default as ScreenNormal} from './screen-normal' -import {default as Unverified} from './unverified' -import {default as Verified} from './verified' -import {default as Versions} from './versions' -import {default as Watch} from './watch' -import {default as X} from './x' -import {default as Zap} from './zap' -import {default as Key} from './key' -import {default as Grabber} from './grabber' -import {default as PlusSmall} from './plus-small' -import {default as LightBulb} from './light-bulb' -import {default as LinkExternal} from './link-external' - -const iconsByName = { - 'alert': Alert, - 'arrow-down': ArrowDown, - 'arrow-left': ArrowLeft, - 'arrow-right': ArrowRight, - 'arrow-up': ArrowUp, - 'arrow-small-down': ArrowSmallDown, - 'arrow-small-left': ArrowSmallLeft, - 'arrow-small-right': ArrowSmallRight, - 'arrow-small-up': ArrowSmallUp, - 'beaker': Beaker, - 'bell': Bell, - 'bold': Bold, - 'book': Book, - 'bookmark': Bookmark, - 'briefcase': Briefcase, - 'broadcast': Broadcast, - 'browser': Browser, - 'bug': Bug, - 'calendar': Calendar, - 'check': Check, - 'checklist': Checklist, - 'chevron-down': ChevronDown, - 'chevron-left': ChevronLeft, - 'chevron-right': ChevronRight, - 'chevron-up': ChevronUp, - 'circle-slash': CircleSlash, - 'circuit-board': CircuitBoard, - 'clippy': Clippy, - 'clock': Clock, - 'cloud-download': CloudDownload, - 'cloud-upload': CloudUpload, - 'code': Code, - 'comment-discussion': CommentDiscussion, - 'comment': Comment, - 'credit-card': CreditCard, - 'dash': Dash, - 'dashboard': Dashboard, - 'database': Database, - 'desktop-download': DesktopDownload, - 'device-camera-video': DeviceCameraVideo, - 'device-camera': DeviceCamera, - 'device-desktop': DeviceDesktop, - 'device-mobile': DeviceMobile, - 'diff-added': DiffAdded, - 'diff-ignored': DiffIgnored, - 'diff-modified': DiffModified, - 'diff-removed': DiffRemoved, - 'diff-renamed': DiffRenamed, - 'diff': Diff, - 'ellipsis': Ellipsis, - 'eye': Eye, - 'file-binary': FileBinary, - 'file-code': FileCode, - 'file-directory': FileDirectory, - 'file-media': FileMedia, - 'file-pdf': FilePdf, - 'file-submodule': FileSubmodule, - 'file-symlink-directory': FileSymlinkDirectory, - 'file-symlink-file': FileSymlinkFile, - 'file': File, - 'file-zip': FileZip, - 'flame': Flame, - 'fold': Fold, - 'gear': Gear, - 'gift': Gift, - 'gist-secret': GistSecret, - 'gist': Gist, - 'git-branch': GitBranch, - 'git-commit': GitCommit, - 'git-compare': GitCompare, - 'git-merge': GitMerge, - 'git-pull-request': GitPullRequest, - 'globe': Globe, - 'graph': Graph, - 'heart': Heart, - 'history': History, - 'home': Home, - 'horizontal-rule': HorizontalRule, - 'hubot': Hubot, - 'inbox': Inbox, - 'info': Info, - 'issue-closed': IssueClosed, - 'issue-opened': IssueOpened, - 'issue-reopened': IssueReopened, - 'italic': Italic, - 'jersey': Jersey, - 'keyboard': Keyboard, - 'law': Law, - 'link': Link, - 'list-ordered': ListOrdered, - 'list-unordered': ListUnordered, - 'location': Location, - 'lock': Lock, - 'logo-gist': LogoGist, - 'logo-github': LogoGithub, - 'mail-read': MailRead, - 'reply': Reply, - 'mail': Mail, - 'mark-github': MarkGithub, - 'markdown': Markdown, - 'megaphone': Megaphone, - 'mention': Mention, - 'milestone': Milestone, - 'mirror': Mirror, - 'mortar-board': MortarBoard, - 'mute': Mute, - 'no-newline': NoNewline, - 'octoface': Octoface, - 'organization': Organization, - 'package': Package, - 'paintcan': Paintcan, - 'pencil': Pencil, - 'person': Person, - 'pin': Pin, - 'plug': Plug, - 'plus': Plus, - 'primitive-dot': PrimitiveDot, - 'primitive-square': PrimitiveSquare, - 'pulse': Pulse, - 'question': Question, - 'quote': Quote, - 'radio-tower': RadioTower, - 'repo-clone': RepoClone, - 'repo-force-push': RepoForcePush, - 'repo-forked': RepoForked, - 'repo-pull': RepoPull, - 'repo-push': RepoPush, - 'repo': Repo, - 'rocket': Rocket, - 'rss': Rss, - 'ruby': Ruby, - 'search': Search, - 'server': Server, - 'settings': Settings, - 'shield': Shield, - 'sign-in': SignIn, - 'sign-out': SignOut, - 'smiley': Smiley, - 'squirrel': Squirrel, - 'star': Star, - 'stop': Stop, - 'sync': Sync, - 'tag': Tag, - 'tasklist': Tasklist, - 'telescope': Telescope, - 'terminal': Terminal, - 'text-size': TextSize, - 'three-bars': ThreeBars, - 'thumbsdown': Thumbsdown, - 'thumbsup': Thumbsup, - 'tools': Tools, - 'trashcan': Trashcan, - 'triangle-down': TriangleDown, - 'triangle-left': TriangleLeft, - 'triangle-right': TriangleRight, - 'triangle-up': TriangleUp, - 'unfold': Unfold, - 'unmute': Unmute, - 'project': Project, - 'kebab-horizontal': KebabHorizontal, - 'kebab-vertical': KebabVertical, - 'report': Report, - 'note': Note, - 'screen-full': ScreenFull, - 'screen-normal': ScreenNormal, - 'unverified': Unverified, - 'verified': Verified, - 'versions': Versions, - 'watch': Watch, - 'x': X, - 'zap': Zap, - 'key': Key, - 'grabber': Grabber, - 'plus-small': PlusSmall, - 'light-bulb': LightBulb, - 'link-external': LinkExternal, -} - -export default function getIconByName(name) { - return iconsByName[name] -} - -export { - iconsByName -} diff --git a/lib/octicons_react/icons/index.js b/lib/octicons_react/icons/index.js index 371393b01..e64f39bd7 100644 --- a/lib/octicons_react/icons/index.js +++ b/lib/octicons_react/icons/index.js @@ -1,176 +1,541 @@ -export {default as Alert} from './alert' -export {default as ArrowDown} from './arrow-down' -export {default as ArrowLeft} from './arrow-left' -export {default as ArrowRight} from './arrow-right' -export {default as ArrowUp} from './arrow-up' -export {default as ArrowSmallDown} from './arrow-small-down' -export {default as ArrowSmallLeft} from './arrow-small-left' -export {default as ArrowSmallRight} from './arrow-small-right' -export {default as ArrowSmallUp} from './arrow-small-up' -export {default as Beaker} from './beaker' -export {default as Bell} from './bell' -export {default as Bold} from './bold' -export {default as Book} from './book' -export {default as Bookmark} from './bookmark' -export {default as Briefcase} from './briefcase' -export {default as Broadcast} from './broadcast' -export {default as Browser} from './browser' -export {default as Bug} from './bug' -export {default as Calendar} from './calendar' -export {default as Check} from './check' -export {default as Checklist} from './checklist' -export {default as ChevronDown} from './chevron-down' -export {default as ChevronLeft} from './chevron-left' -export {default as ChevronRight} from './chevron-right' -export {default as ChevronUp} from './chevron-up' -export {default as CircleSlash} from './circle-slash' -export {default as CircuitBoard} from './circuit-board' -export {default as Clippy} from './clippy' -export {default as Clock} from './clock' -export {default as CloudDownload} from './cloud-download' -export {default as CloudUpload} from './cloud-upload' -export {default as Code} from './code' -export {default as CommentDiscussion} from './comment-discussion' -export {default as Comment} from './comment' -export {default as CreditCard} from './credit-card' -export {default as Dash} from './dash' -export {default as Dashboard} from './dashboard' -export {default as Database} from './database' -export {default as DesktopDownload} from './desktop-download' -export {default as DeviceCameraVideo} from './device-camera-video' -export {default as DeviceCamera} from './device-camera' -export {default as DeviceDesktop} from './device-desktop' -export {default as DeviceMobile} from './device-mobile' -export {default as DiffAdded} from './diff-added' -export {default as DiffIgnored} from './diff-ignored' -export {default as DiffModified} from './diff-modified' -export {default as DiffRemoved} from './diff-removed' -export {default as DiffRenamed} from './diff-renamed' -export {default as Diff} from './diff' -export {default as Ellipsis} from './ellipsis' -export {default as Eye} from './eye' -export {default as FileBinary} from './file-binary' -export {default as FileCode} from './file-code' -export {default as FileDirectory} from './file-directory' -export {default as FileMedia} from './file-media' -export {default as FilePdf} from './file-pdf' -export {default as FileSubmodule} from './file-submodule' -export {default as FileSymlinkDirectory} from './file-symlink-directory' -export {default as FileSymlinkFile} from './file-symlink-file' -export {default as File} from './file' -export {default as FileZip} from './file-zip' -export {default as Flame} from './flame' -export {default as Fold} from './fold' -export {default as Gear} from './gear' -export {default as Gift} from './gift' -export {default as GistSecret} from './gist-secret' -export {default as Gist} from './gist' -export {default as GitBranch} from './git-branch' -export {default as GitCommit} from './git-commit' -export {default as GitCompare} from './git-compare' -export {default as GitMerge} from './git-merge' -export {default as GitPullRequest} from './git-pull-request' -export {default as Globe} from './globe' -export {default as Graph} from './graph' -export {default as Heart} from './heart' -export {default as History} from './history' -export {default as Home} from './home' -export {default as HorizontalRule} from './horizontal-rule' -export {default as Hubot} from './hubot' -export {default as Inbox} from './inbox' -export {default as Info} from './info' -export {default as IssueClosed} from './issue-closed' -export {default as IssueOpened} from './issue-opened' -export {default as IssueReopened} from './issue-reopened' -export {default as Italic} from './italic' -export {default as Jersey} from './jersey' -export {default as Keyboard} from './keyboard' -export {default as Law} from './law' -export {default as Link} from './link' -export {default as ListOrdered} from './list-ordered' -export {default as ListUnordered} from './list-unordered' -export {default as Location} from './location' -export {default as Lock} from './lock' -export {default as LogoGist} from './logo-gist' -export {default as LogoGithub} from './logo-github' -export {default as MailRead} from './mail-read' -export {default as Reply} from './reply' -export {default as Mail} from './mail' -export {default as MarkGithub} from './mark-github' -export {default as Markdown} from './markdown' -export {default as Megaphone} from './megaphone' -export {default as Mention} from './mention' -export {default as Milestone} from './milestone' -export {default as Mirror} from './mirror' -export {default as MortarBoard} from './mortar-board' -export {default as Mute} from './mute' -export {default as NoNewline} from './no-newline' -export {default as Octoface} from './octoface' -export {default as Organization} from './organization' -export {default as Package} from './package' -export {default as Paintcan} from './paintcan' -export {default as Pencil} from './pencil' -export {default as Person} from './person' -export {default as Pin} from './pin' -export {default as Plug} from './plug' -export {default as Plus} from './plus' -export {default as PrimitiveDot} from './primitive-dot' -export {default as PrimitiveSquare} from './primitive-square' -export {default as Pulse} from './pulse' -export {default as Question} from './question' -export {default as Quote} from './quote' -export {default as RadioTower} from './radio-tower' -export {default as RepoClone} from './repo-clone' -export {default as RepoForcePush} from './repo-force-push' -export {default as RepoForked} from './repo-forked' -export {default as RepoPull} from './repo-pull' -export {default as RepoPush} from './repo-push' -export {default as Repo} from './repo' -export {default as Rocket} from './rocket' -export {default as Rss} from './rss' -export {default as Ruby} from './ruby' -export {default as Search} from './search' -export {default as Server} from './server' -export {default as Settings} from './settings' -export {default as Shield} from './shield' -export {default as SignIn} from './sign-in' -export {default as SignOut} from './sign-out' -export {default as Smiley} from './smiley' -export {default as Squirrel} from './squirrel' -export {default as Star} from './star' -export {default as Stop} from './stop' -export {default as Sync} from './sync' -export {default as Tag} from './tag' -export {default as Tasklist} from './tasklist' -export {default as Telescope} from './telescope' -export {default as Terminal} from './terminal' -export {default as TextSize} from './text-size' -export {default as ThreeBars} from './three-bars' -export {default as Thumbsdown} from './thumbsdown' -export {default as Thumbsup} from './thumbsup' -export {default as Tools} from './tools' -export {default as Trashcan} from './trashcan' -export {default as TriangleDown} from './triangle-down' -export {default as TriangleLeft} from './triangle-left' -export {default as TriangleRight} from './triangle-right' -export {default as TriangleUp} from './triangle-up' -export {default as Unfold} from './unfold' -export {default as Unmute} from './unmute' -export {default as Project} from './project' -export {default as KebabHorizontal} from './kebab-horizontal' -export {default as KebabVertical} from './kebab-vertical' -export {default as Report} from './report' -export {default as Note} from './note' -export {default as ScreenFull} from './screen-full' -export {default as ScreenNormal} from './screen-normal' -export {default as Unverified} from './unverified' -export {default as Verified} from './verified' -export {default as Versions} from './versions' -export {default as Watch} from './watch' -export {default as X} from './x' -export {default as Zap} from './zap' -export {default as Key} from './key' -export {default as Grabber} from './grabber' -export {default as PlusSmall} from './plus-small' -export {default as LightBulb} from './light-bulb' -export {default as LinkExternal} from './link-external' \ No newline at end of file +/* THIS FILE IS GENERATED. DO NOT EDIT IT. */ +import {default as Alert} from './alert' +import {default as ArrowDown} from './arrow-down' +import {default as ArrowLeft} from './arrow-left' +import {default as ArrowRight} from './arrow-right' +import {default as ArrowSmallDown} from './arrow-small-down' +import {default as ArrowSmallLeft} from './arrow-small-left' +import {default as ArrowSmallRight} from './arrow-small-right' +import {default as ArrowSmallUp} from './arrow-small-up' +import {default as ArrowUp} from './arrow-up' +import {default as Beaker} from './beaker' +import {default as Bell} from './bell' +import {default as Bold} from './bold' +import {default as Book} from './book' +import {default as Bookmark} from './bookmark' +import {default as Briefcase} from './briefcase' +import {default as Broadcast} from './broadcast' +import {default as Browser} from './browser' +import {default as Bug} from './bug' +import {default as Calendar} from './calendar' +import {default as Check} from './check' +import {default as Checklist} from './checklist' +import {default as ChevronDown} from './chevron-down' +import {default as ChevronLeft} from './chevron-left' +import {default as ChevronRight} from './chevron-right' +import {default as ChevronUp} from './chevron-up' +import {default as CircleSlash} from './circle-slash' +import {default as CircuitBoard} from './circuit-board' +import {default as Clippy} from './clippy' +import {default as Clock} from './clock' +import {default as CloudDownload} from './cloud-download' +import {default as CloudUpload} from './cloud-upload' +import {default as Code} from './code' +import {default as Comment} from './comment' +import {default as CommentDiscussion} from './comment-discussion' +import {default as CreditCard} from './credit-card' +import {default as Dash} from './dash' +import {default as Dashboard} from './dashboard' +import {default as Database} from './database' +import {default as DesktopDownload} from './desktop-download' +import {default as DeviceCamera} from './device-camera' +import {default as DeviceCameraVideo} from './device-camera-video' +import {default as DeviceDesktop} from './device-desktop' +import {default as DeviceMobile} from './device-mobile' +import {default as Diff} from './diff' +import {default as DiffAdded} from './diff-added' +import {default as DiffIgnored} from './diff-ignored' +import {default as DiffModified} from './diff-modified' +import {default as DiffRemoved} from './diff-removed' +import {default as DiffRenamed} from './diff-renamed' +import {default as Ellipsis} from './ellipsis' +import {default as Eye} from './eye' +import {default as File} from './file' +import {default as FileBinary} from './file-binary' +import {default as FileCode} from './file-code' +import {default as FileDirectory} from './file-directory' +import {default as FileMedia} from './file-media' +import {default as FilePdf} from './file-pdf' +import {default as FileSubmodule} from './file-submodule' +import {default as FileSymlinkDirectory} from './file-symlink-directory' +import {default as FileSymlinkFile} from './file-symlink-file' +import {default as FileZip} from './file-zip' +import {default as Flame} from './flame' +import {default as Fold} from './fold' +import {default as Gear} from './gear' +import {default as Gift} from './gift' +import {default as Gist} from './gist' +import {default as GistSecret} from './gist-secret' +import {default as GitBranch} from './git-branch' +import {default as GitCommit} from './git-commit' +import {default as GitCompare} from './git-compare' +import {default as GitMerge} from './git-merge' +import {default as GitPullRequest} from './git-pull-request' +import {default as Globe} from './globe' +import {default as Grabber} from './grabber' +import {default as Graph} from './graph' +import {default as Heart} from './heart' +import {default as History} from './history' +import {default as Home} from './home' +import {default as HorizontalRule} from './horizontal-rule' +import {default as Hubot} from './hubot' +import {default as Inbox} from './inbox' +import {default as Info} from './info' +import {default as IssueClosed} from './issue-closed' +import {default as IssueOpened} from './issue-opened' +import {default as IssueReopened} from './issue-reopened' +import {default as Italic} from './italic' +import {default as Jersey} from './jersey' +import {default as KebabHorizontal} from './kebab-horizontal' +import {default as KebabVertical} from './kebab-vertical' +import {default as Key} from './key' +import {default as Keyboard} from './keyboard' +import {default as Law} from './law' +import {default as LightBulb} from './light-bulb' +import {default as Link} from './link' +import {default as LinkExternal} from './link-external' +import {default as ListOrdered} from './list-ordered' +import {default as ListUnordered} from './list-unordered' +import {default as Location} from './location' +import {default as Lock} from './lock' +import {default as LogoGist} from './logo-gist' +import {default as LogoGithub} from './logo-github' +import {default as Mail} from './mail' +import {default as MailRead} from './mail-read' +import {default as MarkGithub} from './mark-github' +import {default as Markdown} from './markdown' +import {default as Megaphone} from './megaphone' +import {default as Mention} from './mention' +import {default as Milestone} from './milestone' +import {default as Mirror} from './mirror' +import {default as MortarBoard} from './mortar-board' +import {default as Mute} from './mute' +import {default as NoNewline} from './no-newline' +import {default as Note} from './note' +import {default as Octoface} from './octoface' +import {default as Organization} from './organization' +import {default as Package} from './package' +import {default as Paintcan} from './paintcan' +import {default as Pencil} from './pencil' +import {default as Person} from './person' +import {default as Pin} from './pin' +import {default as Plug} from './plug' +import {default as Plus} from './plus' +import {default as PlusSmall} from './plus-small' +import {default as PrimitiveDot} from './primitive-dot' +import {default as PrimitiveSquare} from './primitive-square' +import {default as Project} from './project' +import {default as Pulse} from './pulse' +import {default as Question} from './question' +import {default as Quote} from './quote' +import {default as RadioTower} from './radio-tower' +import {default as Reply} from './reply' +import {default as Repo} from './repo' +import {default as RepoClone} from './repo-clone' +import {default as RepoForcePush} from './repo-force-push' +import {default as RepoForked} from './repo-forked' +import {default as RepoPull} from './repo-pull' +import {default as RepoPush} from './repo-push' +import {default as Report} from './report' +import {default as Rocket} from './rocket' +import {default as Rss} from './rss' +import {default as Ruby} from './ruby' +import {default as ScreenFull} from './screen-full' +import {default as ScreenNormal} from './screen-normal' +import {default as Search} from './search' +import {default as Server} from './server' +import {default as Settings} from './settings' +import {default as Shield} from './shield' +import {default as SignIn} from './sign-in' +import {default as SignOut} from './sign-out' +import {default as Smiley} from './smiley' +import {default as Squirrel} from './squirrel' +import {default as Star} from './star' +import {default as Stop} from './stop' +import {default as Sync} from './sync' +import {default as Tag} from './tag' +import {default as Tasklist} from './tasklist' +import {default as Telescope} from './telescope' +import {default as Terminal} from './terminal' +import {default as TextSize} from './text-size' +import {default as ThreeBars} from './three-bars' +import {default as Thumbsdown} from './thumbsdown' +import {default as Thumbsup} from './thumbsup' +import {default as Tools} from './tools' +import {default as Trashcan} from './trashcan' +import {default as TriangleDown} from './triangle-down' +import {default as TriangleLeft} from './triangle-left' +import {default as TriangleRight} from './triangle-right' +import {default as TriangleUp} from './triangle-up' +import {default as Unfold} from './unfold' +import {default as Unmute} from './unmute' +import {default as Unverified} from './unverified' +import {default as Verified} from './verified' +import {default as Versions} from './versions' +import {default as Watch} from './watch' +import {default as X} from './x' +import {default as Zap} from './zap' + +const iconsByName = { + 'alert': Alert, + 'arrow-down': ArrowDown, + 'arrow-left': ArrowLeft, + 'arrow-right': ArrowRight, + 'arrow-small-down': ArrowSmallDown, + 'arrow-small-left': ArrowSmallLeft, + 'arrow-small-right': ArrowSmallRight, + 'arrow-small-up': ArrowSmallUp, + 'arrow-up': ArrowUp, + 'beaker': Beaker, + 'bell': Bell, + 'bold': Bold, + 'book': Book, + 'bookmark': Bookmark, + 'briefcase': Briefcase, + 'broadcast': Broadcast, + 'browser': Browser, + 'bug': Bug, + 'calendar': Calendar, + 'check': Check, + 'checklist': Checklist, + 'chevron-down': ChevronDown, + 'chevron-left': ChevronLeft, + 'chevron-right': ChevronRight, + 'chevron-up': ChevronUp, + 'circle-slash': CircleSlash, + 'circuit-board': CircuitBoard, + 'clippy': Clippy, + 'clock': Clock, + 'cloud-download': CloudDownload, + 'cloud-upload': CloudUpload, + 'code': Code, + 'comment': Comment, + 'comment-discussion': CommentDiscussion, + 'credit-card': CreditCard, + 'dash': Dash, + 'dashboard': Dashboard, + 'database': Database, + 'desktop-download': DesktopDownload, + 'device-camera': DeviceCamera, + 'device-camera-video': DeviceCameraVideo, + 'device-desktop': DeviceDesktop, + 'device-mobile': DeviceMobile, + 'diff': Diff, + 'diff-added': DiffAdded, + 'diff-ignored': DiffIgnored, + 'diff-modified': DiffModified, + 'diff-removed': DiffRemoved, + 'diff-renamed': DiffRenamed, + 'ellipsis': Ellipsis, + 'eye': Eye, + 'file': File, + 'file-binary': FileBinary, + 'file-code': FileCode, + 'file-directory': FileDirectory, + 'file-media': FileMedia, + 'file-pdf': FilePdf, + 'file-submodule': FileSubmodule, + 'file-symlink-directory': FileSymlinkDirectory, + 'file-symlink-file': FileSymlinkFile, + 'file-zip': FileZip, + 'flame': Flame, + 'fold': Fold, + 'gear': Gear, + 'gift': Gift, + 'gist': Gist, + 'gist-secret': GistSecret, + 'git-branch': GitBranch, + 'git-commit': GitCommit, + 'git-compare': GitCompare, + 'git-merge': GitMerge, + 'git-pull-request': GitPullRequest, + 'globe': Globe, + 'grabber': Grabber, + 'graph': Graph, + 'heart': Heart, + 'history': History, + 'home': Home, + 'horizontal-rule': HorizontalRule, + 'hubot': Hubot, + 'inbox': Inbox, + 'info': Info, + 'issue-closed': IssueClosed, + 'issue-opened': IssueOpened, + 'issue-reopened': IssueReopened, + 'italic': Italic, + 'jersey': Jersey, + 'kebab-horizontal': KebabHorizontal, + 'kebab-vertical': KebabVertical, + 'key': Key, + 'keyboard': Keyboard, + 'law': Law, + 'light-bulb': LightBulb, + 'link': Link, + 'link-external': LinkExternal, + 'list-ordered': ListOrdered, + 'list-unordered': ListUnordered, + 'location': Location, + 'lock': Lock, + 'logo-gist': LogoGist, + 'logo-github': LogoGithub, + 'mail': Mail, + 'mail-read': MailRead, + 'mark-github': MarkGithub, + 'markdown': Markdown, + 'megaphone': Megaphone, + 'mention': Mention, + 'milestone': Milestone, + 'mirror': Mirror, + 'mortar-board': MortarBoard, + 'mute': Mute, + 'no-newline': NoNewline, + 'note': Note, + 'octoface': Octoface, + 'organization': Organization, + 'package': Package, + 'paintcan': Paintcan, + 'pencil': Pencil, + 'person': Person, + 'pin': Pin, + 'plug': Plug, + 'plus': Plus, + 'plus-small': PlusSmall, + 'primitive-dot': PrimitiveDot, + 'primitive-square': PrimitiveSquare, + 'project': Project, + 'pulse': Pulse, + 'question': Question, + 'quote': Quote, + 'radio-tower': RadioTower, + 'reply': Reply, + 'repo': Repo, + 'repo-clone': RepoClone, + 'repo-force-push': RepoForcePush, + 'repo-forked': RepoForked, + 'repo-pull': RepoPull, + 'repo-push': RepoPush, + 'report': Report, + 'rocket': Rocket, + 'rss': Rss, + 'ruby': Ruby, + 'screen-full': ScreenFull, + 'screen-normal': ScreenNormal, + 'search': Search, + 'server': Server, + 'settings': Settings, + 'shield': Shield, + 'sign-in': SignIn, + 'sign-out': SignOut, + 'smiley': Smiley, + 'squirrel': Squirrel, + 'star': Star, + 'stop': Stop, + 'sync': Sync, + 'tag': Tag, + 'tasklist': Tasklist, + 'telescope': Telescope, + 'terminal': Terminal, + 'text-size': TextSize, + 'three-bars': ThreeBars, + 'thumbsdown': Thumbsdown, + 'thumbsup': Thumbsup, + 'tools': Tools, + 'trashcan': Trashcan, + 'triangle-down': TriangleDown, + 'triangle-left': TriangleLeft, + 'triangle-right': TriangleRight, + 'triangle-up': TriangleUp, + 'unfold': Unfold, + 'unmute': Unmute, + 'unverified': Unverified, + 'verified': Verified, + 'versions': Versions, + 'watch': Watch, + 'x': X, + 'zap': Zap +} + +function getIconByName(name) { + return iconsByName[name] +} + +export { + getIconByName, + iconsByName, + Alert, + ArrowDown, + ArrowLeft, + ArrowRight, + ArrowSmallDown, + ArrowSmallLeft, + ArrowSmallRight, + ArrowSmallUp, + ArrowUp, + Beaker, + Bell, + Bold, + Book, + Bookmark, + Briefcase, + Broadcast, + Browser, + Bug, + Calendar, + Check, + Checklist, + ChevronDown, + ChevronLeft, + ChevronRight, + ChevronUp, + CircleSlash, + CircuitBoard, + Clippy, + Clock, + CloudDownload, + CloudUpload, + Code, + Comment, + CommentDiscussion, + CreditCard, + Dash, + Dashboard, + Database, + DesktopDownload, + DeviceCamera, + DeviceCameraVideo, + DeviceDesktop, + DeviceMobile, + Diff, + DiffAdded, + DiffIgnored, + DiffModified, + DiffRemoved, + DiffRenamed, + Ellipsis, + Eye, + File, + FileBinary, + FileCode, + FileDirectory, + FileMedia, + FilePdf, + FileSubmodule, + FileSymlinkDirectory, + FileSymlinkFile, + FileZip, + Flame, + Fold, + Gear, + Gift, + Gist, + GistSecret, + GitBranch, + GitCommit, + GitCompare, + GitMerge, + GitPullRequest, + Globe, + Grabber, + Graph, + Heart, + History, + Home, + HorizontalRule, + Hubot, + Inbox, + Info, + IssueClosed, + IssueOpened, + IssueReopened, + Italic, + Jersey, + KebabHorizontal, + KebabVertical, + Key, + Keyboard, + Law, + LightBulb, + Link, + LinkExternal, + ListOrdered, + ListUnordered, + Location, + Lock, + LogoGist, + LogoGithub, + Mail, + MailRead, + MarkGithub, + Markdown, + Megaphone, + Mention, + Milestone, + Mirror, + MortarBoard, + Mute, + NoNewline, + Note, + Octoface, + Organization, + Package, + Paintcan, + Pencil, + Person, + Pin, + Plug, + Plus, + PlusSmall, + PrimitiveDot, + PrimitiveSquare, + Project, + Pulse, + Question, + Quote, + RadioTower, + Reply, + Repo, + RepoClone, + RepoForcePush, + RepoForked, + RepoPull, + RepoPush, + Report, + Rocket, + Rss, + Ruby, + ScreenFull, + ScreenNormal, + Search, + Server, + Settings, + Shield, + SignIn, + SignOut, + Smiley, + Squirrel, + Star, + Stop, + Sync, + Tag, + Tasklist, + Telescope, + Terminal, + TextSize, + ThreeBars, + Thumbsdown, + Thumbsup, + Tools, + Trashcan, + TriangleDown, + TriangleLeft, + TriangleRight, + TriangleUp, + Unfold, + Unmute, + Unverified, + Verified, + Versions, + Watch, + X, + Zap +} \ No newline at end of file diff --git a/lib/octicons_react/script/build.js b/lib/octicons_react/script/build.js index 0ff62e8f1..6429ac06f 100755 --- a/lib/octicons_react/script/build.js +++ b/lib/octicons_react/script/build.js @@ -28,55 +28,46 @@ ${name}.size = [${width}, ${height}] } }) -const tasks = icons.map(({key, name, code}) => { - const file = join(DIR, key + '.js') - return fse.writeFile(file, code, 'utf8') - .then(() => ({key, name, file})) -}) +const tasks = icons + // sort them alphabetically + .sort((a, b) => a.key.localeCompare(b.key)) + .map(({key, name, code}) => { + const file = join(DIR, key + '.js') + return fse.writeFile(file, code, 'utf8') + .then(() => ({key, name, file})) + }) function writeIndex(icons) { const count = icons.length console.warn('wrote %d files to %s.', count, DIR) const file = join(DIR, 'index.js') - const code = icons.map(({key, name}) => ( - `export {default as ${name}} from './${key}'` - )).join('\n') - return fse.writeFile(file, code, 'utf8') - .then(() => { - console.warn('wrote %s with %d exports', file, count) - return icons - }) -} - -function writeAll(icons) { - const file = join(DIR, 'all.js') - const code = `${icons.map(({key, name}) => ( + const code = `/* THIS FILE IS GENERATED. DO NOT EDIT IT. */ +${icons.map(({key, name}) => ( `import {default as ${name}} from './${key}'` )).join('\n')} const iconsByName = { -${icons.map(({key, name}) => ` '${key}': ${name},`).join('\n')} + ${icons.map(({key, name}) => `'${key}': ${name}`).join(',\n ')} } -export default function getIconByName(name) { +function getIconByName(name) { return iconsByName[name] } export { - iconsByName -} -` + getIconByName, + iconsByName, + ${icons.map(({name}) => name).join(',\n ')} +}` return fse.writeFile(file, code, 'utf8') .then(() => { - console.warn('wrote %s with all exports', file) + console.warn('wrote %s with %d exports', file, count) + return icons }) } Promise.all(tasks) - .then(icons => Promise.all([ - writeIndex(icons), - writeAll(icons) - ])) + .then(writeIndex) .catch(error => { console.error(error) process.exit(1) From 0386dc2c45e42caa9662099d64df8174d4dbcf61 Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Tue, 26 Jun 2018 09:56:07 -0700 Subject: [PATCH 49/97] update docs for new all icons exports --- lib/octicons_react/README.md | 43 ++++++++++++++++++------------------ 1 file changed, 21 insertions(+), 22 deletions(-) diff --git a/lib/octicons_react/README.md b/lib/octicons_react/README.md index 0398bd5a7..9dca31bb9 100644 --- a/lib/octicons_react/README.md +++ b/lib/octicons_react/README.md @@ -43,39 +43,38 @@ export default function Icon({boom}) { } ``` -If you were to compile this example with a tool that supports [tree-shaking], -the resulting bundle would only include the "zap" and "beaker" icons. +If you were to compile this example with a tool that supports [tree-shaking][] +(such as Webpack, Rollup, or Parcel) the resulting bundle would only include +the "zap" and "beaker" icons. ### All icons If you don't mind your bundle being huge or you need to be able to render -arbitrarily named icons at runtime, there's a special `icons/all` entry which -provides you with two ways to get any icon: +arbitrarily named icons at runtime, you can import either the following named +exports: #### `getIconByName()` -The default export of `@github/octicons-react/icons/all` is a function that -takes a lowercase octicon name (such as `arrow-right`) and returns the -corresponding icon class. Using this helper, it's possible to create an Octicon -class that takes a `name` prop and resolves it to the right component: +The `getIconByName` export is a function that takes a lowercase octicon name +(such as `arrow-right`) and returns the corresponding icon class. Using this +helper, it's possible to create an Octicon class that takes a `name` prop and +resolves it to the right component: ```jsx import React from 'react' -import Octicon from '@github/octicons-react' -import getIcon from '@github/octicons-react/icons/all' +import Octicon, {getIconByName} from '@github/octicons-react' export default function OcticonByName({name, ...props}) { return } ``` -#### `iconsByName` object -`@github/octicons-react/icons/all` also exports a `iconsByName` object that -maps keys (such as `arrow-right`) to component functions, which you can use to -generate listings of all the octicons: +#### `iconsByName` +The `iconsByName` export is an object that maps keys (such as `arrow-right` or +`zap`) to component functions, which you can use to generate listings of all +the octicons: ```jsx import React from 'react' -import Octicon from '@github/octicons-react' -import {iconsByName} from '@github/octicons-react/icons/all' +import Octicon, {iconsByName} from '@github/octicons-react' export default function OcticonsList() { return ( @@ -97,11 +96,11 @@ styles. You can change the alignment via the `verticalAlign` prop, which can be either `middle`, `text-bottom`, `text-top`, or `top`. ```js -import Octicon from '@github/octicons-react' +import Octicon, {Repo} from '@github/octicons-react' export default () => (

    - github/github + github/github

    ) ``` @@ -114,11 +113,11 @@ capitalization of `L`!). ```js // Example usage -import Octicon from "@github/octicons-react" +import Octicon, {Plus} from '@github/octicons-react' export default () => ( ) ``` @@ -137,12 +136,12 @@ render octicons at standard sizes: ```js // Example usage -import Octicon from '@github/octicons-react' +import Octicon, {LogoGithub} from '@github/octicons-react' export default () => (

    - +

    ) From 5173a5474158bca6f28b1088a468e6473383b831 Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Tue, 26 Jun 2018 09:58:17 -0700 Subject: [PATCH 50/97] nix "ES6" --- lib/octicons_react/README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/octicons_react/README.md b/lib/octicons_react/README.md index 9dca31bb9..434c1e606 100644 --- a/lib/octicons_react/README.md +++ b/lib/octicons_react/README.md @@ -28,7 +28,7 @@ icon, you must pass it either via `icon` prop or as a child: ``` ### Icons -The `@github/octicons-react` ES6 module exports the `Octicon` component as +The `@github/octicons-react` module exports the `Octicon` component as `default` and the individual icon symbols as separate [named exports](https://ponyfoo.com/articles/es6-modules-in-depth#named-exports). This allows you to import only the icons that you need without blowing up your From 5f23980484146a1d79684819fa6826a2e0310459 Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Tue, 26 Jun 2018 09:58:46 -0700 Subject: [PATCH 51/97] update the "about" bit --- lib/octicons_react/README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/octicons_react/README.md b/lib/octicons_react/README.md index 434c1e606..8c2ff0f00 100644 --- a/lib/octicons_react/README.md +++ b/lib/octicons_react/README.md @@ -3,7 +3,7 @@ [![npm version](https://img.shields.io/npm/v/%40github%2Focticons-react.svg)](https://www.npmjs.org/package/%40github%2Focticons-react) [![Build Status](https://travis-ci.org/primer/octicons.svg?branch=master)](https://travis-ci.org/primer/octicons) -> A react component for installing octicons +> [Octicons] as React components ## Install From 91e7dfee4be6d55db4e1e86f5b59d8609d73f0fe Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Tue, 26 Jun 2018 09:59:46 -0700 Subject: [PATCH 52/97] "Octicons for React" sounds better --- lib/octicons_react/README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/octicons_react/README.md b/lib/octicons_react/README.md index 8c2ff0f00..15d07132e 100644 --- a/lib/octicons_react/README.md +++ b/lib/octicons_react/README.md @@ -3,7 +3,7 @@ [![npm version](https://img.shields.io/npm/v/%40github%2Focticons-react.svg)](https://www.npmjs.org/package/%40github%2Focticons-react) [![Build Status](https://travis-ci.org/primer/octicons.svg?branch=master)](https://travis-ci.org/primer/octicons) -> [Octicons] as React components +> [Octicons] for React ## Install From c996c55470b43929f13d9756aecdaa175267e2bb Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Tue, 26 Jun 2018 10:11:39 -0700 Subject: [PATCH 53/97] linty --- lib/octicons_react/index.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/octicons_react/index.js b/lib/octicons_react/index.js index fe4f64d70..aa9da3a54 100644 --- a/lib/octicons_react/index.js +++ b/lib/octicons_react/index.js @@ -32,7 +32,7 @@ export default function Octicon(props) { const attrs = { ariaLabel, className, - height: height, + height, role: 'img', viewBox: [0, 0, width, height].join(' ') } From 4666318f024c8fbda3f6793d5e4060273077bb28 Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Tue, 26 Jun 2018 10:11:51 -0700 Subject: [PATCH 54/97] add bit on custom icons, tweak Octicon language --- lib/octicons_react/README.md | 37 ++++++++++++++++++++++++++++++++---- 1 file changed, 33 insertions(+), 4 deletions(-) diff --git a/lib/octicons_react/README.md b/lib/octicons_react/README.md index 15d07132e..b09320076 100644 --- a/lib/octicons_react/README.md +++ b/lib/octicons_react/README.md @@ -14,9 +14,9 @@ $ npm install @github/octicons-react --save ## Usage ### `` -The `` component is really just the "shell" of an octicon which -handles the `` element and all of its attributes. To render a specific -icon, you must pass it either via `icon` prop or as a child: +The `` component is really just the "shell" of an Octicon that renders +the `` element and all of its attributes. To render a specific icon, you +must pass it either via the `icon` prop, or as the only child: ```jsx // icon prop (function) @@ -124,7 +124,6 @@ export default () => ( ### Sizes - The `size` prop takes `small`, `medium`, and `large` values that can be used to render octicons at standard sizes: @@ -147,6 +146,36 @@ export default () => ( ) ``` + +## Custom icons +Each of our icon components is really just a function that renders its SVG +``. To accommodate icons varying aspect ratios, the `Octicon` component +determines the `viewBox` of the `` element by first looking for a `size` +array on the icon component class. For instance, if you wanted to create a +custom icon that consisted of three circles side by side, you could do this: + +```jsx +import React from 'react' +import Octicon from '@github/octicons-react' + +function CirclesIcon() { + return ( + + + + + + ) +} + +CirclesIcon.size = [30, 10] + +export default CirclesOcticon(props) { + return +} +``` + + ## License (c) GitHub, Inc. From de30402b176a3292eee70e7fd38f3448bf48c853 Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Tue, 26 Jun 2018 10:17:55 -0700 Subject: [PATCH 55/97] better explain the icon usage options --- lib/octicons_react/README.md | 16 +++++++++++----- 1 file changed, 11 insertions(+), 5 deletions(-) diff --git a/lib/octicons_react/README.md b/lib/octicons_react/README.md index b09320076..de2e3e5d1 100644 --- a/lib/octicons_react/README.md +++ b/lib/octicons_react/README.md @@ -19,14 +19,20 @@ the `` element and all of its attributes. To render a specific icon, you must pass it either via the `icon` prop, or as the only child: ```jsx -// icon prop (function) +/** + * The prop form is shorter, but doesn't allow you to pass icon props. + */ -// icon prop (element) -} /> -// child - + +/** + * The child form allows you to pass props. + */ + ``` +Note that none of our builtin icons take props, so unless you're creating +[custom icons](#custom-icons) you'll probably want to use the `icon` prop form. + ### Icons The `@github/octicons-react` module exports the `Octicon` component as `default` and the individual icon symbols as separate [named From ff8c9978a065bcef6b50a83e26fe18db6889af07 Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Wed, 27 Jun 2018 09:34:23 -0700 Subject: [PATCH 56/97] v0.1.0 --- lib/octicons_react/package.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/octicons_react/package.json b/lib/octicons_react/package.json index 434d0b782..11bab5601 100644 --- a/lib/octicons_react/package.json +++ b/lib/octicons_react/package.json @@ -1,12 +1,12 @@ { "name": "@github/octicons-react", - "version": "1.1.0", + "version": "0.1.0", "description": "A scalable set of icons handcrafted with <3 by GitHub.", "homepage": "https://octicons.github.com", "author": "GitHub Inc.", "license": "MIT", "main": "index.js", - "repository": "https://github.com/primer/octicons.git", + "repository": "primer/octicons", "files": [ "icons", "index.js", From fae9547da142617b9d65bcaa70ef065b8c7e168e Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Wed, 27 Jun 2018 09:39:19 -0700 Subject: [PATCH 57/97] move script/build.js => script/build --- lib/octicons_react/script/{build.js => build} | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename lib/octicons_react/script/{build.js => build} (100%) diff --git a/lib/octicons_react/script/build.js b/lib/octicons_react/script/build similarity index 100% rename from lib/octicons_react/script/build.js rename to lib/octicons_react/script/build From 959f0b735359b10ee368ce32934ec221c24dcbc4 Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Wed, 27 Jun 2018 09:39:35 -0700 Subject: [PATCH 58/97] add comma in "GitHub, Inc." --- lib/octicons_react/package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/octicons_react/package.json b/lib/octicons_react/package.json index 11bab5601..e2480c2f6 100644 --- a/lib/octicons_react/package.json +++ b/lib/octicons_react/package.json @@ -3,7 +3,7 @@ "version": "0.1.0", "description": "A scalable set of icons handcrafted with <3 by GitHub.", "homepage": "https://octicons.github.com", - "author": "GitHub Inc.", + "author": "GitHub, Inc.", "license": "MIT", "main": "index.js", "repository": "primer/octicons", From c1db936c7b53a31ca200934049fdd860043c595e Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Wed, 27 Jun 2018 09:39:57 -0700 Subject: [PATCH 59/97] update build script name; add preversion run-script --- lib/octicons_react/package.json | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/octicons_react/package.json b/lib/octicons_react/package.json index e2480c2f6..abcde87ea 100644 --- a/lib/octicons_react/package.json +++ b/lib/octicons_react/package.json @@ -15,9 +15,10 @@ "scripts": { "start": "next", "test": "jest", + "preversion": "script/build", "publish": "../../script/notify success", "prepublishOnly": "../../script/notify pending", - "prepare": "script/build.js" + "prepare": "script/build" }, "bugs": { "url": "https://github.com/primer/octicons/issues" From 131bb287e92700ab9667b2f9242159067db43334 Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Wed, 27 Jun 2018 09:43:08 -0700 Subject: [PATCH 60/97] move react into peer and dev dependencies I did some digging and discovered that you can avoid users inadvertently bundling two versions of React (and all of the other madness that may come with that) by declaring it as a peer dependency. Because peer deps aren't installed by default, we also have to add a more specific version to devDependencies for testing. See this PR for an example: https://github.com/moroshko/react-autosuggest/pull/26/files --- lib/octicons_react/package.json | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/lib/octicons_react/package.json b/lib/octicons_react/package.json index abcde87ea..d88a8c453 100644 --- a/lib/octicons_react/package.json +++ b/lib/octicons_react/package.json @@ -32,7 +32,6 @@ "primer" ], "dependencies": { - "react": "^16.4.0", "prop-types": "^15.6.1" }, "devDependencies": { @@ -42,7 +41,11 @@ "jest": "^23.2.0", "next": "^6.0.3", "octicons": "7.2.0", + "react": "^16.4.0", "react-dom": "^16.4.1", "react-test-renderer": "^16.4.1" + }, + "peerDependencies": { + "react": ">=15" } } From 3e8f4878bed6963222524074fdb09e916daab800 Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Wed, 27 Jun 2018 09:50:43 -0700 Subject: [PATCH 61/97] suggest node 8+ --- lib/octicons_react/.nvmrc | 1 + lib/octicons_react/package.json | 3 +++ 2 files changed, 4 insertions(+) create mode 100644 lib/octicons_react/.nvmrc diff --git a/lib/octicons_react/.nvmrc b/lib/octicons_react/.nvmrc new file mode 100644 index 000000000..45a4fb75d --- /dev/null +++ b/lib/octicons_react/.nvmrc @@ -0,0 +1 @@ +8 diff --git a/lib/octicons_react/package.json b/lib/octicons_react/package.json index d88a8c453..b5838ff8b 100644 --- a/lib/octicons_react/package.json +++ b/lib/octicons_react/package.json @@ -12,6 +12,9 @@ "index.js", "pages" ], + "engines": { + "node": ">=8" + }, "scripts": { "start": "next", "test": "jest", From 9267ee96154420710bbb6a2b3414179a13f7052d Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Wed, 27 Jun 2018 15:09:31 -0700 Subject: [PATCH 62/97] move script/build => script/build.js --- lib/octicons_react/script/{build => build.js} | 43 ++++++++----------- 1 file changed, 19 insertions(+), 24 deletions(-) rename lib/octicons_react/script/{build => build.js} (61%) diff --git a/lib/octicons_react/script/build b/lib/octicons_react/script/build.js similarity index 61% rename from lib/octicons_react/script/build rename to lib/octicons_react/script/build.js index 6429ac06f..a9dc4ebac 100755 --- a/lib/octicons_react/script/build +++ b/lib/octicons_react/script/build.js @@ -9,32 +9,30 @@ function CamelCase(str) { return str.replace(/(^|-)([a-z])/g, (_, __, c) => c.toUpperCase()) } -const icons = [...Object.entries(octicons)] - .map(([key, octicon]) => { - const name = CamelCase(key) - const {width, height, path} = octicon - const code = `import React from 'react' +const icons = [...Object.entries(octicons)].map(([key, octicon]) => { + const name = CamelCase(key) + const {width, height, path} = octicon + const code = `import React from 'react' export default function ${name}() { - return ${path} +return ${path} } ${name}.size = [${width}, ${height}] ` - return { - key, - name, - octicon, - code - } - }) + return { + key, + name, + octicon, + code + } +}) const tasks = icons // sort them alphabetically .sort((a, b) => a.key.localeCompare(b.key)) .map(({key, name, code}) => { - const file = join(DIR, key + '.js') - return fse.writeFile(file, code, 'utf8') - .then(() => ({key, name, file})) + const file = join(DIR, `${key}.js`) + return fse.writeFile(file, code, 'utf8').then(() => ({key, name, file})) }) function writeIndex(icons) { @@ -42,9 +40,7 @@ function writeIndex(icons) { console.warn('wrote %d files to %s.', count, DIR) const file = join(DIR, 'index.js') const code = `/* THIS FILE IS GENERATED. DO NOT EDIT IT. */ -${icons.map(({key, name}) => ( - `import {default as ${name}} from './${key}'` -)).join('\n')} +${icons.map(({key, name}) => `import {default as ${name}} from './${key}'`).join('\n')} const iconsByName = { ${icons.map(({key, name}) => `'${key}': ${name}`).join(',\n ')} @@ -59,11 +55,10 @@ export { iconsByName, ${icons.map(({name}) => name).join(',\n ')} }` - return fse.writeFile(file, code, 'utf8') - .then(() => { - console.warn('wrote %s with %d exports', file, count) - return icons - }) + return fse.writeFile(file, code, 'utf8').then(() => { + console.warn('wrote %s with %d exports', file, count) + return icons + }) } Promise.all(tasks) From 4f4a9dfcb6992602df8444394c7a79962c399667 Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Wed, 27 Jun 2018 15:10:18 -0700 Subject: [PATCH 63/97] add eslint, tidy package.json, build scripts --- lib/octicons_react/package.json | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/lib/octicons_react/package.json b/lib/octicons_react/package.json index b5838ff8b..72302ce36 100644 --- a/lib/octicons_react/package.json +++ b/lib/octicons_react/package.json @@ -18,13 +18,11 @@ "scripts": { "start": "next", "test": "jest", - "preversion": "script/build", + "build": "script/build.js", + "preversion": "npm run build -s", "publish": "../../script/notify success", "prepublishOnly": "../../script/notify pending", - "prepare": "script/build" - }, - "bugs": { - "url": "https://github.com/primer/octicons/issues" + "prepare": "npm run build -s" }, "keywords": [ "GitHub", @@ -40,6 +38,9 @@ "devDependencies": { "babel-preset-env": "^1.7.0", "babel-preset-react": "^6.24.1", + "eslint": "^5.0.1", + "eslint-plugin-github": "^1.1.0", + "eslint-plugin-jest": "^21.17.0", "fs-extra": "^6.0.1", "jest": "^23.2.0", "next": "^6.0.3", From 44ee3c61d88336d12e2de0a3df773584d8b8d087 Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Wed, 27 Jun 2018 15:10:29 -0700 Subject: [PATCH 64/97] add eslint configs --- lib/octicons_react/.eslintrc.json | 10 ++++++++++ lib/octicons_react/prettier.config.js | 1 + lib/octicons_react/script/.eslintrc.json | 9 +++++++++ 3 files changed, 20 insertions(+) create mode 100644 lib/octicons_react/.eslintrc.json create mode 100644 lib/octicons_react/prettier.config.js create mode 100644 lib/octicons_react/script/.eslintrc.json diff --git a/lib/octicons_react/.eslintrc.json b/lib/octicons_react/.eslintrc.json new file mode 100644 index 000000000..5f2203418 --- /dev/null +++ b/lib/octicons_react/.eslintrc.json @@ -0,0 +1,10 @@ +{ + "extends": [ + "plugin:github/recommended", + "plugin:github/es6", + "plugin:github/react" + ], + "rules": { + "quotes": ["warn", "single"] + } +} diff --git a/lib/octicons_react/prettier.config.js b/lib/octicons_react/prettier.config.js new file mode 100644 index 000000000..7d9937db5 --- /dev/null +++ b/lib/octicons_react/prettier.config.js @@ -0,0 +1 @@ +module.exports = require('eslint-plugin-github/prettier.config') diff --git a/lib/octicons_react/script/.eslintrc.json b/lib/octicons_react/script/.eslintrc.json new file mode 100644 index 000000000..9f1520bef --- /dev/null +++ b/lib/octicons_react/script/.eslintrc.json @@ -0,0 +1,9 @@ +{ + "env": { + "node": true, + "browser": false + }, + "rules": { + "no-console": 0 + } +} From babe5c456125fcfbf9a33e41f9c958f75c221468 Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Wed, 27 Jun 2018 15:18:00 -0700 Subject: [PATCH 65/97] tidy up icon builds --- lib/octicons_react/icons/alert.js | 2 +- lib/octicons_react/icons/arrow-down.js | 2 +- lib/octicons_react/icons/arrow-left.js | 2 +- lib/octicons_react/icons/arrow-right.js | 2 +- lib/octicons_react/icons/arrow-small-down.js | 2 +- lib/octicons_react/icons/arrow-small-left.js | 2 +- lib/octicons_react/icons/arrow-small-right.js | 2 +- lib/octicons_react/icons/arrow-small-up.js | 2 +- lib/octicons_react/icons/arrow-up.js | 2 +- lib/octicons_react/icons/beaker.js | 2 +- lib/octicons_react/icons/bell.js | 2 +- lib/octicons_react/icons/bold.js | 2 +- lib/octicons_react/icons/book.js | 2 +- lib/octicons_react/icons/bookmark.js | 2 +- lib/octicons_react/icons/briefcase.js | 2 +- lib/octicons_react/icons/broadcast.js | 2 +- lib/octicons_react/icons/browser.js | 2 +- lib/octicons_react/icons/bug.js | 2 +- lib/octicons_react/icons/calendar.js | 2 +- lib/octicons_react/icons/check.js | 2 +- lib/octicons_react/icons/checklist.js | 2 +- lib/octicons_react/icons/chevron-down.js | 2 +- lib/octicons_react/icons/chevron-left.js | 2 +- lib/octicons_react/icons/chevron-right.js | 2 +- lib/octicons_react/icons/chevron-up.js | 2 +- lib/octicons_react/icons/circle-slash.js | 2 +- lib/octicons_react/icons/circuit-board.js | 2 +- lib/octicons_react/icons/clippy.js | 2 +- lib/octicons_react/icons/clock.js | 2 +- lib/octicons_react/icons/cloud-download.js | 2 +- lib/octicons_react/icons/cloud-upload.js | 2 +- lib/octicons_react/icons/code.js | 2 +- lib/octicons_react/icons/comment-discussion.js | 2 +- lib/octicons_react/icons/comment.js | 2 +- lib/octicons_react/icons/credit-card.js | 2 +- lib/octicons_react/icons/dash.js | 2 +- lib/octicons_react/icons/dashboard.js | 2 +- lib/octicons_react/icons/database.js | 2 +- lib/octicons_react/icons/desktop-download.js | 2 +- lib/octicons_react/icons/device-camera-video.js | 2 +- lib/octicons_react/icons/device-camera.js | 2 +- lib/octicons_react/icons/device-desktop.js | 2 +- lib/octicons_react/icons/device-mobile.js | 2 +- lib/octicons_react/icons/diff-added.js | 2 +- lib/octicons_react/icons/diff-ignored.js | 2 +- lib/octicons_react/icons/diff-modified.js | 2 +- lib/octicons_react/icons/diff-removed.js | 2 +- lib/octicons_react/icons/diff-renamed.js | 2 +- lib/octicons_react/icons/diff.js | 2 +- lib/octicons_react/icons/ellipsis.js | 2 +- lib/octicons_react/icons/eye.js | 2 +- lib/octicons_react/icons/file-binary.js | 2 +- lib/octicons_react/icons/file-code.js | 2 +- lib/octicons_react/icons/file-directory.js | 2 +- lib/octicons_react/icons/file-media.js | 2 +- lib/octicons_react/icons/file-pdf.js | 2 +- lib/octicons_react/icons/file-submodule.js | 2 +- lib/octicons_react/icons/file-symlink-directory.js | 2 +- lib/octicons_react/icons/file-symlink-file.js | 2 +- lib/octicons_react/icons/file-zip.js | 2 +- lib/octicons_react/icons/file.js | 2 +- lib/octicons_react/icons/flame.js | 2 +- lib/octicons_react/icons/fold.js | 2 +- lib/octicons_react/icons/gear.js | 2 +- lib/octicons_react/icons/gift.js | 2 +- lib/octicons_react/icons/gist-secret.js | 2 +- lib/octicons_react/icons/gist.js | 2 +- lib/octicons_react/icons/git-branch.js | 2 +- lib/octicons_react/icons/git-commit.js | 2 +- lib/octicons_react/icons/git-compare.js | 2 +- lib/octicons_react/icons/git-merge.js | 2 +- lib/octicons_react/icons/git-pull-request.js | 2 +- lib/octicons_react/icons/globe.js | 2 +- lib/octicons_react/icons/grabber.js | 2 +- lib/octicons_react/icons/graph.js | 2 +- lib/octicons_react/icons/heart.js | 2 +- lib/octicons_react/icons/history.js | 2 +- lib/octicons_react/icons/home.js | 2 +- lib/octicons_react/icons/horizontal-rule.js | 2 +- lib/octicons_react/icons/hubot.js | 2 +- lib/octicons_react/icons/inbox.js | 2 +- lib/octicons_react/icons/info.js | 2 +- lib/octicons_react/icons/issue-closed.js | 2 +- lib/octicons_react/icons/issue-opened.js | 2 +- lib/octicons_react/icons/issue-reopened.js | 2 +- lib/octicons_react/icons/italic.js | 2 +- lib/octicons_react/icons/jersey.js | 2 +- lib/octicons_react/icons/kebab-horizontal.js | 2 +- lib/octicons_react/icons/kebab-vertical.js | 2 +- lib/octicons_react/icons/key.js | 2 +- lib/octicons_react/icons/keyboard.js | 2 +- lib/octicons_react/icons/law.js | 2 +- lib/octicons_react/icons/light-bulb.js | 2 +- lib/octicons_react/icons/link-external.js | 2 +- lib/octicons_react/icons/link.js | 2 +- lib/octicons_react/icons/list-ordered.js | 2 +- lib/octicons_react/icons/list-unordered.js | 2 +- lib/octicons_react/icons/location.js | 2 +- lib/octicons_react/icons/lock.js | 2 +- lib/octicons_react/icons/logo-gist.js | 2 +- lib/octicons_react/icons/logo-github.js | 2 +- lib/octicons_react/icons/mail-read.js | 2 +- lib/octicons_react/icons/mail.js | 2 +- lib/octicons_react/icons/mark-github.js | 2 +- lib/octicons_react/icons/markdown.js | 2 +- lib/octicons_react/icons/megaphone.js | 2 +- lib/octicons_react/icons/mention.js | 2 +- lib/octicons_react/icons/milestone.js | 2 +- lib/octicons_react/icons/mirror.js | 2 +- lib/octicons_react/icons/mortar-board.js | 2 +- lib/octicons_react/icons/mute.js | 2 +- lib/octicons_react/icons/no-newline.js | 2 +- lib/octicons_react/icons/note.js | 2 +- lib/octicons_react/icons/octoface.js | 2 +- lib/octicons_react/icons/organization.js | 2 +- lib/octicons_react/icons/package.js | 2 +- lib/octicons_react/icons/paintcan.js | 2 +- lib/octicons_react/icons/pencil.js | 2 +- lib/octicons_react/icons/person.js | 2 +- lib/octicons_react/icons/pin.js | 2 +- lib/octicons_react/icons/plug.js | 2 +- lib/octicons_react/icons/plus-small.js | 2 +- lib/octicons_react/icons/plus.js | 2 +- lib/octicons_react/icons/primitive-dot.js | 2 +- lib/octicons_react/icons/primitive-square.js | 2 +- lib/octicons_react/icons/project.js | 2 +- lib/octicons_react/icons/pulse.js | 2 +- lib/octicons_react/icons/question.js | 2 +- lib/octicons_react/icons/quote.js | 2 +- lib/octicons_react/icons/radio-tower.js | 2 +- lib/octicons_react/icons/reply.js | 2 +- lib/octicons_react/icons/repo-clone.js | 2 +- lib/octicons_react/icons/repo-force-push.js | 2 +- lib/octicons_react/icons/repo-forked.js | 2 +- lib/octicons_react/icons/repo-pull.js | 2 +- lib/octicons_react/icons/repo-push.js | 2 +- lib/octicons_react/icons/repo.js | 2 +- lib/octicons_react/icons/report.js | 2 +- lib/octicons_react/icons/rocket.js | 2 +- lib/octicons_react/icons/rss.js | 2 +- lib/octicons_react/icons/ruby.js | 2 +- lib/octicons_react/icons/screen-full.js | 2 +- lib/octicons_react/icons/screen-normal.js | 2 +- lib/octicons_react/icons/search.js | 2 +- lib/octicons_react/icons/server.js | 2 +- lib/octicons_react/icons/settings.js | 2 +- lib/octicons_react/icons/shield.js | 2 +- lib/octicons_react/icons/sign-in.js | 2 +- lib/octicons_react/icons/sign-out.js | 2 +- lib/octicons_react/icons/smiley.js | 2 +- lib/octicons_react/icons/squirrel.js | 2 +- lib/octicons_react/icons/star.js | 2 +- lib/octicons_react/icons/stop.js | 2 +- lib/octicons_react/icons/sync.js | 2 +- lib/octicons_react/icons/tag.js | 2 +- lib/octicons_react/icons/tasklist.js | 2 +- lib/octicons_react/icons/telescope.js | 2 +- lib/octicons_react/icons/terminal.js | 2 +- lib/octicons_react/icons/text-size.js | 2 +- lib/octicons_react/icons/three-bars.js | 2 +- lib/octicons_react/icons/thumbsdown.js | 2 +- lib/octicons_react/icons/thumbsup.js | 2 +- lib/octicons_react/icons/tools.js | 2 +- lib/octicons_react/icons/trashcan.js | 2 +- lib/octicons_react/icons/triangle-down.js | 2 +- lib/octicons_react/icons/triangle-left.js | 2 +- lib/octicons_react/icons/triangle-right.js | 2 +- lib/octicons_react/icons/triangle-up.js | 2 +- lib/octicons_react/icons/unfold.js | 2 +- lib/octicons_react/icons/unmute.js | 2 +- lib/octicons_react/icons/unverified.js | 2 +- lib/octicons_react/icons/verified.js | 2 +- lib/octicons_react/icons/versions.js | 2 +- lib/octicons_react/icons/watch.js | 2 +- lib/octicons_react/icons/x.js | 2 +- lib/octicons_react/icons/zap.js | 2 +- lib/octicons_react/script/build.js | 4 +++- 177 files changed, 179 insertions(+), 177 deletions(-) diff --git a/lib/octicons_react/icons/alert.js b/lib/octicons_react/icons/alert.js index 0316b1ce9..99fd19f21 100644 --- a/lib/octicons_react/icons/alert.js +++ b/lib/octicons_react/icons/alert.js @@ -1,5 +1,5 @@ import React from 'react' export default function Alert() { - return + return } Alert.size = [16, 16] diff --git a/lib/octicons_react/icons/arrow-down.js b/lib/octicons_react/icons/arrow-down.js index 94a4db708..449de7e14 100644 --- a/lib/octicons_react/icons/arrow-down.js +++ b/lib/octicons_react/icons/arrow-down.js @@ -1,5 +1,5 @@ import React from 'react' export default function ArrowDown() { - return + return } ArrowDown.size = [10, 16] diff --git a/lib/octicons_react/icons/arrow-left.js b/lib/octicons_react/icons/arrow-left.js index d5898d391..fa6fa8aa2 100644 --- a/lib/octicons_react/icons/arrow-left.js +++ b/lib/octicons_react/icons/arrow-left.js @@ -1,5 +1,5 @@ import React from 'react' export default function ArrowLeft() { - return + return } ArrowLeft.size = [10, 16] diff --git a/lib/octicons_react/icons/arrow-right.js b/lib/octicons_react/icons/arrow-right.js index cf91d224d..a7ddddcf6 100644 --- a/lib/octicons_react/icons/arrow-right.js +++ b/lib/octicons_react/icons/arrow-right.js @@ -1,5 +1,5 @@ import React from 'react' export default function ArrowRight() { - return + return } ArrowRight.size = [10, 16] diff --git a/lib/octicons_react/icons/arrow-small-down.js b/lib/octicons_react/icons/arrow-small-down.js index 5d67639a2..e604d209d 100644 --- a/lib/octicons_react/icons/arrow-small-down.js +++ b/lib/octicons_react/icons/arrow-small-down.js @@ -1,5 +1,5 @@ import React from 'react' export default function ArrowSmallDown() { - return + return } ArrowSmallDown.size = [6, 16] diff --git a/lib/octicons_react/icons/arrow-small-left.js b/lib/octicons_react/icons/arrow-small-left.js index 399be002b..d087c8b10 100644 --- a/lib/octicons_react/icons/arrow-small-left.js +++ b/lib/octicons_react/icons/arrow-small-left.js @@ -1,5 +1,5 @@ import React from 'react' export default function ArrowSmallLeft() { - return + return } ArrowSmallLeft.size = [6, 16] diff --git a/lib/octicons_react/icons/arrow-small-right.js b/lib/octicons_react/icons/arrow-small-right.js index 2cc53478a..8908b6dee 100644 --- a/lib/octicons_react/icons/arrow-small-right.js +++ b/lib/octicons_react/icons/arrow-small-right.js @@ -1,5 +1,5 @@ import React from 'react' export default function ArrowSmallRight() { - return + return } ArrowSmallRight.size = [6, 16] diff --git a/lib/octicons_react/icons/arrow-small-up.js b/lib/octicons_react/icons/arrow-small-up.js index efbf0b2c4..31fd47222 100644 --- a/lib/octicons_react/icons/arrow-small-up.js +++ b/lib/octicons_react/icons/arrow-small-up.js @@ -1,5 +1,5 @@ import React from 'react' export default function ArrowSmallUp() { - return + return } ArrowSmallUp.size = [6, 16] diff --git a/lib/octicons_react/icons/arrow-up.js b/lib/octicons_react/icons/arrow-up.js index b017291c5..d5a66a14a 100644 --- a/lib/octicons_react/icons/arrow-up.js +++ b/lib/octicons_react/icons/arrow-up.js @@ -1,5 +1,5 @@ import React from 'react' export default function ArrowUp() { - return + return } ArrowUp.size = [10, 16] diff --git a/lib/octicons_react/icons/beaker.js b/lib/octicons_react/icons/beaker.js index 9f1f430ac..fd81c9dac 100644 --- a/lib/octicons_react/icons/beaker.js +++ b/lib/octicons_react/icons/beaker.js @@ -1,5 +1,5 @@ import React from 'react' export default function Beaker() { - return + return } Beaker.size = [16, 16] diff --git a/lib/octicons_react/icons/bell.js b/lib/octicons_react/icons/bell.js index c4a6282bd..5d3d66ff8 100644 --- a/lib/octicons_react/icons/bell.js +++ b/lib/octicons_react/icons/bell.js @@ -1,5 +1,5 @@ import React from 'react' export default function Bell() { - return + return } Bell.size = [14, 16] diff --git a/lib/octicons_react/icons/bold.js b/lib/octicons_react/icons/bold.js index ad3f6893a..5c2bf8073 100644 --- a/lib/octicons_react/icons/bold.js +++ b/lib/octicons_react/icons/bold.js @@ -1,5 +1,5 @@ import React from 'react' export default function Bold() { - return + return } Bold.size = [10, 16] diff --git a/lib/octicons_react/icons/book.js b/lib/octicons_react/icons/book.js index 0897e677a..7f632b71f 100644 --- a/lib/octicons_react/icons/book.js +++ b/lib/octicons_react/icons/book.js @@ -1,5 +1,5 @@ import React from 'react' export default function Book() { - return + return } Book.size = [16, 16] diff --git a/lib/octicons_react/icons/bookmark.js b/lib/octicons_react/icons/bookmark.js index 0f9fe0665..52422b291 100644 --- a/lib/octicons_react/icons/bookmark.js +++ b/lib/octicons_react/icons/bookmark.js @@ -1,5 +1,5 @@ import React from 'react' export default function Bookmark() { - return + return } Bookmark.size = [10, 16] diff --git a/lib/octicons_react/icons/briefcase.js b/lib/octicons_react/icons/briefcase.js index 760947053..930046f4d 100644 --- a/lib/octicons_react/icons/briefcase.js +++ b/lib/octicons_react/icons/briefcase.js @@ -1,5 +1,5 @@ import React from 'react' export default function Briefcase() { - return + return } Briefcase.size = [14, 16] diff --git a/lib/octicons_react/icons/broadcast.js b/lib/octicons_react/icons/broadcast.js index a8cf1d4b6..397db9abc 100644 --- a/lib/octicons_react/icons/broadcast.js +++ b/lib/octicons_react/icons/broadcast.js @@ -1,5 +1,5 @@ import React from 'react' export default function Broadcast() { - return + return } Broadcast.size = [16, 16] diff --git a/lib/octicons_react/icons/browser.js b/lib/octicons_react/icons/browser.js index 325682778..1467b7f19 100644 --- a/lib/octicons_react/icons/browser.js +++ b/lib/octicons_react/icons/browser.js @@ -1,5 +1,5 @@ import React from 'react' export default function Browser() { - return + return } Browser.size = [14, 16] diff --git a/lib/octicons_react/icons/bug.js b/lib/octicons_react/icons/bug.js index 80f9e16b8..4bc22a37d 100644 --- a/lib/octicons_react/icons/bug.js +++ b/lib/octicons_react/icons/bug.js @@ -1,5 +1,5 @@ import React from 'react' export default function Bug() { - return + return } Bug.size = [16, 16] diff --git a/lib/octicons_react/icons/calendar.js b/lib/octicons_react/icons/calendar.js index 17de83d2a..ba4f9ee89 100644 --- a/lib/octicons_react/icons/calendar.js +++ b/lib/octicons_react/icons/calendar.js @@ -1,5 +1,5 @@ import React from 'react' export default function Calendar() { - return + return } Calendar.size = [14, 16] diff --git a/lib/octicons_react/icons/check.js b/lib/octicons_react/icons/check.js index 476f14ffe..e3f21e992 100644 --- a/lib/octicons_react/icons/check.js +++ b/lib/octicons_react/icons/check.js @@ -1,5 +1,5 @@ import React from 'react' export default function Check() { - return + return } Check.size = [12, 16] diff --git a/lib/octicons_react/icons/checklist.js b/lib/octicons_react/icons/checklist.js index 995119db3..85339d59f 100644 --- a/lib/octicons_react/icons/checklist.js +++ b/lib/octicons_react/icons/checklist.js @@ -1,5 +1,5 @@ import React from 'react' export default function Checklist() { - return + return } Checklist.size = [16, 16] diff --git a/lib/octicons_react/icons/chevron-down.js b/lib/octicons_react/icons/chevron-down.js index f9f57a2ba..f8d539ecf 100644 --- a/lib/octicons_react/icons/chevron-down.js +++ b/lib/octicons_react/icons/chevron-down.js @@ -1,5 +1,5 @@ import React from 'react' export default function ChevronDown() { - return + return } ChevronDown.size = [10, 16] diff --git a/lib/octicons_react/icons/chevron-left.js b/lib/octicons_react/icons/chevron-left.js index 451634d7b..598f1b997 100644 --- a/lib/octicons_react/icons/chevron-left.js +++ b/lib/octicons_react/icons/chevron-left.js @@ -1,5 +1,5 @@ import React from 'react' export default function ChevronLeft() { - return + return } ChevronLeft.size = [8, 16] diff --git a/lib/octicons_react/icons/chevron-right.js b/lib/octicons_react/icons/chevron-right.js index 7d0aee4c6..21610f1db 100644 --- a/lib/octicons_react/icons/chevron-right.js +++ b/lib/octicons_react/icons/chevron-right.js @@ -1,5 +1,5 @@ import React from 'react' export default function ChevronRight() { - return + return } ChevronRight.size = [8, 16] diff --git a/lib/octicons_react/icons/chevron-up.js b/lib/octicons_react/icons/chevron-up.js index 3eab3daf9..35ba5c4fb 100644 --- a/lib/octicons_react/icons/chevron-up.js +++ b/lib/octicons_react/icons/chevron-up.js @@ -1,5 +1,5 @@ import React from 'react' export default function ChevronUp() { - return + return } ChevronUp.size = [10, 16] diff --git a/lib/octicons_react/icons/circle-slash.js b/lib/octicons_react/icons/circle-slash.js index ae418669e..4fc2ab920 100644 --- a/lib/octicons_react/icons/circle-slash.js +++ b/lib/octicons_react/icons/circle-slash.js @@ -1,5 +1,5 @@ import React from 'react' export default function CircleSlash() { - return + return } CircleSlash.size = [14, 16] diff --git a/lib/octicons_react/icons/circuit-board.js b/lib/octicons_react/icons/circuit-board.js index 125dc4f6c..358391a9e 100644 --- a/lib/octicons_react/icons/circuit-board.js +++ b/lib/octicons_react/icons/circuit-board.js @@ -1,5 +1,5 @@ import React from 'react' export default function CircuitBoard() { - return + return } CircuitBoard.size = [14, 16] diff --git a/lib/octicons_react/icons/clippy.js b/lib/octicons_react/icons/clippy.js index bd94bbc51..62c5433bd 100644 --- a/lib/octicons_react/icons/clippy.js +++ b/lib/octicons_react/icons/clippy.js @@ -1,5 +1,5 @@ import React from 'react' export default function Clippy() { - return + return } Clippy.size = [14, 16] diff --git a/lib/octicons_react/icons/clock.js b/lib/octicons_react/icons/clock.js index 8554c248f..0e315f92a 100644 --- a/lib/octicons_react/icons/clock.js +++ b/lib/octicons_react/icons/clock.js @@ -1,5 +1,5 @@ import React from 'react' export default function Clock() { - return + return } Clock.size = [14, 16] diff --git a/lib/octicons_react/icons/cloud-download.js b/lib/octicons_react/icons/cloud-download.js index 01dfa4844..3375e308b 100644 --- a/lib/octicons_react/icons/cloud-download.js +++ b/lib/octicons_react/icons/cloud-download.js @@ -1,5 +1,5 @@ import React from 'react' export default function CloudDownload() { - return + return } CloudDownload.size = [16, 16] diff --git a/lib/octicons_react/icons/cloud-upload.js b/lib/octicons_react/icons/cloud-upload.js index ff5cb3cee..b237728a3 100644 --- a/lib/octicons_react/icons/cloud-upload.js +++ b/lib/octicons_react/icons/cloud-upload.js @@ -1,5 +1,5 @@ import React from 'react' export default function CloudUpload() { - return + return } CloudUpload.size = [16, 16] diff --git a/lib/octicons_react/icons/code.js b/lib/octicons_react/icons/code.js index 01b88d8fb..8f6c732d7 100644 --- a/lib/octicons_react/icons/code.js +++ b/lib/octicons_react/icons/code.js @@ -1,5 +1,5 @@ import React from 'react' export default function Code() { - return + return } Code.size = [14, 16] diff --git a/lib/octicons_react/icons/comment-discussion.js b/lib/octicons_react/icons/comment-discussion.js index cfcfbfcc1..9f6691c2e 100644 --- a/lib/octicons_react/icons/comment-discussion.js +++ b/lib/octicons_react/icons/comment-discussion.js @@ -1,5 +1,5 @@ import React from 'react' export default function CommentDiscussion() { - return + return } CommentDiscussion.size = [16, 16] diff --git a/lib/octicons_react/icons/comment.js b/lib/octicons_react/icons/comment.js index 677eed952..f1b8ddc43 100644 --- a/lib/octicons_react/icons/comment.js +++ b/lib/octicons_react/icons/comment.js @@ -1,5 +1,5 @@ import React from 'react' export default function Comment() { - return + return } Comment.size = [16, 16] diff --git a/lib/octicons_react/icons/credit-card.js b/lib/octicons_react/icons/credit-card.js index e12adb916..94890bef0 100644 --- a/lib/octicons_react/icons/credit-card.js +++ b/lib/octicons_react/icons/credit-card.js @@ -1,5 +1,5 @@ import React from 'react' export default function CreditCard() { - return + return } CreditCard.size = [16, 16] diff --git a/lib/octicons_react/icons/dash.js b/lib/octicons_react/icons/dash.js index 9130f660b..4abfc35ca 100644 --- a/lib/octicons_react/icons/dash.js +++ b/lib/octicons_react/icons/dash.js @@ -1,5 +1,5 @@ import React from 'react' export default function Dash() { - return + return } Dash.size = [8, 16] diff --git a/lib/octicons_react/icons/dashboard.js b/lib/octicons_react/icons/dashboard.js index a7da612e8..3664f08d3 100644 --- a/lib/octicons_react/icons/dashboard.js +++ b/lib/octicons_react/icons/dashboard.js @@ -1,5 +1,5 @@ import React from 'react' export default function Dashboard() { - return + return } Dashboard.size = [16, 16] diff --git a/lib/octicons_react/icons/database.js b/lib/octicons_react/icons/database.js index a28eb44a1..13ccad9d5 100644 --- a/lib/octicons_react/icons/database.js +++ b/lib/octicons_react/icons/database.js @@ -1,5 +1,5 @@ import React from 'react' export default function Database() { - return + return } Database.size = [12, 16] diff --git a/lib/octicons_react/icons/desktop-download.js b/lib/octicons_react/icons/desktop-download.js index bde481abb..2e5570bed 100644 --- a/lib/octicons_react/icons/desktop-download.js +++ b/lib/octicons_react/icons/desktop-download.js @@ -1,5 +1,5 @@ import React from 'react' export default function DesktopDownload() { - return + return } DesktopDownload.size = [16, 16] diff --git a/lib/octicons_react/icons/device-camera-video.js b/lib/octicons_react/icons/device-camera-video.js index ea2624ea7..dc0dcf775 100644 --- a/lib/octicons_react/icons/device-camera-video.js +++ b/lib/octicons_react/icons/device-camera-video.js @@ -1,5 +1,5 @@ import React from 'react' export default function DeviceCameraVideo() { - return + return } DeviceCameraVideo.size = [16, 16] diff --git a/lib/octicons_react/icons/device-camera.js b/lib/octicons_react/icons/device-camera.js index 0d7a2cfef..453ffd8c5 100644 --- a/lib/octicons_react/icons/device-camera.js +++ b/lib/octicons_react/icons/device-camera.js @@ -1,5 +1,5 @@ import React from 'react' export default function DeviceCamera() { - return + return } DeviceCamera.size = [16, 16] diff --git a/lib/octicons_react/icons/device-desktop.js b/lib/octicons_react/icons/device-desktop.js index 435e83915..692d01a08 100644 --- a/lib/octicons_react/icons/device-desktop.js +++ b/lib/octicons_react/icons/device-desktop.js @@ -1,5 +1,5 @@ import React from 'react' export default function DeviceDesktop() { - return + return } DeviceDesktop.size = [16, 16] diff --git a/lib/octicons_react/icons/device-mobile.js b/lib/octicons_react/icons/device-mobile.js index 6a3a1b721..f258aa178 100644 --- a/lib/octicons_react/icons/device-mobile.js +++ b/lib/octicons_react/icons/device-mobile.js @@ -1,5 +1,5 @@ import React from 'react' export default function DeviceMobile() { - return + return } DeviceMobile.size = [10, 16] diff --git a/lib/octicons_react/icons/diff-added.js b/lib/octicons_react/icons/diff-added.js index dce7c8ea5..03b19b415 100644 --- a/lib/octicons_react/icons/diff-added.js +++ b/lib/octicons_react/icons/diff-added.js @@ -1,5 +1,5 @@ import React from 'react' export default function DiffAdded() { - return + return } DiffAdded.size = [14, 16] diff --git a/lib/octicons_react/icons/diff-ignored.js b/lib/octicons_react/icons/diff-ignored.js index aa38d390c..6bedea651 100644 --- a/lib/octicons_react/icons/diff-ignored.js +++ b/lib/octicons_react/icons/diff-ignored.js @@ -1,5 +1,5 @@ import React from 'react' export default function DiffIgnored() { - return + return } DiffIgnored.size = [14, 16] diff --git a/lib/octicons_react/icons/diff-modified.js b/lib/octicons_react/icons/diff-modified.js index 0bae6241c..0b1eb9f67 100644 --- a/lib/octicons_react/icons/diff-modified.js +++ b/lib/octicons_react/icons/diff-modified.js @@ -1,5 +1,5 @@ import React from 'react' export default function DiffModified() { - return + return } DiffModified.size = [14, 16] diff --git a/lib/octicons_react/icons/diff-removed.js b/lib/octicons_react/icons/diff-removed.js index 0489b56cc..e914be2c9 100644 --- a/lib/octicons_react/icons/diff-removed.js +++ b/lib/octicons_react/icons/diff-removed.js @@ -1,5 +1,5 @@ import React from 'react' export default function DiffRemoved() { - return + return } DiffRemoved.size = [14, 16] diff --git a/lib/octicons_react/icons/diff-renamed.js b/lib/octicons_react/icons/diff-renamed.js index 34ac7bb8e..37e5bd2cc 100644 --- a/lib/octicons_react/icons/diff-renamed.js +++ b/lib/octicons_react/icons/diff-renamed.js @@ -1,5 +1,5 @@ import React from 'react' export default function DiffRenamed() { - return + return } DiffRenamed.size = [14, 16] diff --git a/lib/octicons_react/icons/diff.js b/lib/octicons_react/icons/diff.js index 0ef722230..8b18b44c2 100644 --- a/lib/octicons_react/icons/diff.js +++ b/lib/octicons_react/icons/diff.js @@ -1,5 +1,5 @@ import React from 'react' export default function Diff() { - return + return } Diff.size = [13, 16] diff --git a/lib/octicons_react/icons/ellipsis.js b/lib/octicons_react/icons/ellipsis.js index 2c360166f..fbf41dfcf 100644 --- a/lib/octicons_react/icons/ellipsis.js +++ b/lib/octicons_react/icons/ellipsis.js @@ -1,5 +1,5 @@ import React from 'react' export default function Ellipsis() { - return + return } Ellipsis.size = [12, 16] diff --git a/lib/octicons_react/icons/eye.js b/lib/octicons_react/icons/eye.js index 04554f2ba..654a297ac 100644 --- a/lib/octicons_react/icons/eye.js +++ b/lib/octicons_react/icons/eye.js @@ -1,5 +1,5 @@ import React from 'react' export default function Eye() { - return + return } Eye.size = [16, 16] diff --git a/lib/octicons_react/icons/file-binary.js b/lib/octicons_react/icons/file-binary.js index 1d509f9d4..a3f4b6da8 100644 --- a/lib/octicons_react/icons/file-binary.js +++ b/lib/octicons_react/icons/file-binary.js @@ -1,5 +1,5 @@ import React from 'react' export default function FileBinary() { - return + return } FileBinary.size = [12, 16] diff --git a/lib/octicons_react/icons/file-code.js b/lib/octicons_react/icons/file-code.js index edead1234..e49974203 100644 --- a/lib/octicons_react/icons/file-code.js +++ b/lib/octicons_react/icons/file-code.js @@ -1,5 +1,5 @@ import React from 'react' export default function FileCode() { - return + return } FileCode.size = [12, 16] diff --git a/lib/octicons_react/icons/file-directory.js b/lib/octicons_react/icons/file-directory.js index 173133d76..e7106c8f4 100644 --- a/lib/octicons_react/icons/file-directory.js +++ b/lib/octicons_react/icons/file-directory.js @@ -1,5 +1,5 @@ import React from 'react' export default function FileDirectory() { - return + return } FileDirectory.size = [14, 16] diff --git a/lib/octicons_react/icons/file-media.js b/lib/octicons_react/icons/file-media.js index 5183cae21..4f3899eee 100644 --- a/lib/octicons_react/icons/file-media.js +++ b/lib/octicons_react/icons/file-media.js @@ -1,5 +1,5 @@ import React from 'react' export default function FileMedia() { - return + return } FileMedia.size = [12, 16] diff --git a/lib/octicons_react/icons/file-pdf.js b/lib/octicons_react/icons/file-pdf.js index d866ee8dd..8b3413540 100644 --- a/lib/octicons_react/icons/file-pdf.js +++ b/lib/octicons_react/icons/file-pdf.js @@ -1,5 +1,5 @@ import React from 'react' export default function FilePdf() { - return + return } FilePdf.size = [12, 16] diff --git a/lib/octicons_react/icons/file-submodule.js b/lib/octicons_react/icons/file-submodule.js index 1c000131c..a046419be 100644 --- a/lib/octicons_react/icons/file-submodule.js +++ b/lib/octicons_react/icons/file-submodule.js @@ -1,5 +1,5 @@ import React from 'react' export default function FileSubmodule() { - return + return } FileSubmodule.size = [14, 16] diff --git a/lib/octicons_react/icons/file-symlink-directory.js b/lib/octicons_react/icons/file-symlink-directory.js index 11f0fec27..a46a0de36 100644 --- a/lib/octicons_react/icons/file-symlink-directory.js +++ b/lib/octicons_react/icons/file-symlink-directory.js @@ -1,5 +1,5 @@ import React from 'react' export default function FileSymlinkDirectory() { - return + return } FileSymlinkDirectory.size = [14, 16] diff --git a/lib/octicons_react/icons/file-symlink-file.js b/lib/octicons_react/icons/file-symlink-file.js index b044a26f1..6615115cf 100644 --- a/lib/octicons_react/icons/file-symlink-file.js +++ b/lib/octicons_react/icons/file-symlink-file.js @@ -1,5 +1,5 @@ import React from 'react' export default function FileSymlinkFile() { - return + return } FileSymlinkFile.size = [12, 16] diff --git a/lib/octicons_react/icons/file-zip.js b/lib/octicons_react/icons/file-zip.js index 8c61731c9..a1e23b1d2 100644 --- a/lib/octicons_react/icons/file-zip.js +++ b/lib/octicons_react/icons/file-zip.js @@ -1,5 +1,5 @@ import React from 'react' export default function FileZip() { - return + return } FileZip.size = [12, 16] diff --git a/lib/octicons_react/icons/file.js b/lib/octicons_react/icons/file.js index 29b51761d..230088fea 100644 --- a/lib/octicons_react/icons/file.js +++ b/lib/octicons_react/icons/file.js @@ -1,5 +1,5 @@ import React from 'react' export default function File() { - return + return } File.size = [12, 16] diff --git a/lib/octicons_react/icons/flame.js b/lib/octicons_react/icons/flame.js index 1e2e059d3..5149d83e8 100644 --- a/lib/octicons_react/icons/flame.js +++ b/lib/octicons_react/icons/flame.js @@ -1,5 +1,5 @@ import React from 'react' export default function Flame() { - return + return } Flame.size = [12, 16] diff --git a/lib/octicons_react/icons/fold.js b/lib/octicons_react/icons/fold.js index 55136d783..c4ed96b80 100644 --- a/lib/octicons_react/icons/fold.js +++ b/lib/octicons_react/icons/fold.js @@ -1,5 +1,5 @@ import React from 'react' export default function Fold() { - return + return } Fold.size = [14, 16] diff --git a/lib/octicons_react/icons/gear.js b/lib/octicons_react/icons/gear.js index 49ae5d43f..f46ed6b76 100644 --- a/lib/octicons_react/icons/gear.js +++ b/lib/octicons_react/icons/gear.js @@ -1,5 +1,5 @@ import React from 'react' export default function Gear() { - return + return } Gear.size = [14, 16] diff --git a/lib/octicons_react/icons/gift.js b/lib/octicons_react/icons/gift.js index 8ac766f7a..42483f168 100644 --- a/lib/octicons_react/icons/gift.js +++ b/lib/octicons_react/icons/gift.js @@ -1,5 +1,5 @@ import React from 'react' export default function Gift() { - return + return } Gift.size = [14, 16] diff --git a/lib/octicons_react/icons/gist-secret.js b/lib/octicons_react/icons/gist-secret.js index a15ad0424..2d31e6475 100644 --- a/lib/octicons_react/icons/gist-secret.js +++ b/lib/octicons_react/icons/gist-secret.js @@ -1,5 +1,5 @@ import React from 'react' export default function GistSecret() { - return + return } GistSecret.size = [14, 16] diff --git a/lib/octicons_react/icons/gist.js b/lib/octicons_react/icons/gist.js index 4aaeb864d..34da17054 100644 --- a/lib/octicons_react/icons/gist.js +++ b/lib/octicons_react/icons/gist.js @@ -1,5 +1,5 @@ import React from 'react' export default function Gist() { - return + return } Gist.size = [12, 16] diff --git a/lib/octicons_react/icons/git-branch.js b/lib/octicons_react/icons/git-branch.js index ccb788428..f06f1b3b8 100644 --- a/lib/octicons_react/icons/git-branch.js +++ b/lib/octicons_react/icons/git-branch.js @@ -1,5 +1,5 @@ import React from 'react' export default function GitBranch() { - return + return } GitBranch.size = [10, 16] diff --git a/lib/octicons_react/icons/git-commit.js b/lib/octicons_react/icons/git-commit.js index 1fb31cad6..69c5d927d 100644 --- a/lib/octicons_react/icons/git-commit.js +++ b/lib/octicons_react/icons/git-commit.js @@ -1,5 +1,5 @@ import React from 'react' export default function GitCommit() { - return + return } GitCommit.size = [14, 16] diff --git a/lib/octicons_react/icons/git-compare.js b/lib/octicons_react/icons/git-compare.js index 075eb41a3..cd764b2bd 100644 --- a/lib/octicons_react/icons/git-compare.js +++ b/lib/octicons_react/icons/git-compare.js @@ -1,5 +1,5 @@ import React from 'react' export default function GitCompare() { - return + return } GitCompare.size = [14, 16] diff --git a/lib/octicons_react/icons/git-merge.js b/lib/octicons_react/icons/git-merge.js index 1465a72bb..1c9465b5a 100644 --- a/lib/octicons_react/icons/git-merge.js +++ b/lib/octicons_react/icons/git-merge.js @@ -1,5 +1,5 @@ import React from 'react' export default function GitMerge() { - return + return } GitMerge.size = [12, 16] diff --git a/lib/octicons_react/icons/git-pull-request.js b/lib/octicons_react/icons/git-pull-request.js index 1cf8f67db..2ae310fe3 100644 --- a/lib/octicons_react/icons/git-pull-request.js +++ b/lib/octicons_react/icons/git-pull-request.js @@ -1,5 +1,5 @@ import React from 'react' export default function GitPullRequest() { - return + return } GitPullRequest.size = [12, 16] diff --git a/lib/octicons_react/icons/globe.js b/lib/octicons_react/icons/globe.js index 92015f566..d1a1b304c 100644 --- a/lib/octicons_react/icons/globe.js +++ b/lib/octicons_react/icons/globe.js @@ -1,5 +1,5 @@ import React from 'react' export default function Globe() { - return + return } Globe.size = [14, 16] diff --git a/lib/octicons_react/icons/grabber.js b/lib/octicons_react/icons/grabber.js index 76a6d995b..1092ec941 100644 --- a/lib/octicons_react/icons/grabber.js +++ b/lib/octicons_react/icons/grabber.js @@ -1,5 +1,5 @@ import React from 'react' export default function Grabber() { - return + return } Grabber.size = [8, 16] diff --git a/lib/octicons_react/icons/graph.js b/lib/octicons_react/icons/graph.js index 890f10175..8c261c0ee 100644 --- a/lib/octicons_react/icons/graph.js +++ b/lib/octicons_react/icons/graph.js @@ -1,5 +1,5 @@ import React from 'react' export default function Graph() { - return + return } Graph.size = [16, 16] diff --git a/lib/octicons_react/icons/heart.js b/lib/octicons_react/icons/heart.js index e966d27ff..46122d158 100644 --- a/lib/octicons_react/icons/heart.js +++ b/lib/octicons_react/icons/heart.js @@ -1,5 +1,5 @@ import React from 'react' export default function Heart() { - return + return } Heart.size = [12, 16] diff --git a/lib/octicons_react/icons/history.js b/lib/octicons_react/icons/history.js index f798fd3e6..1446a92c6 100644 --- a/lib/octicons_react/icons/history.js +++ b/lib/octicons_react/icons/history.js @@ -1,5 +1,5 @@ import React from 'react' export default function History() { - return + return } History.size = [14, 16] diff --git a/lib/octicons_react/icons/home.js b/lib/octicons_react/icons/home.js index 0fde82216..ca522b41d 100644 --- a/lib/octicons_react/icons/home.js +++ b/lib/octicons_react/icons/home.js @@ -1,5 +1,5 @@ import React from 'react' export default function Home() { - return + return } Home.size = [16, 16] diff --git a/lib/octicons_react/icons/horizontal-rule.js b/lib/octicons_react/icons/horizontal-rule.js index 1052c55ea..0a9601dca 100644 --- a/lib/octicons_react/icons/horizontal-rule.js +++ b/lib/octicons_react/icons/horizontal-rule.js @@ -1,5 +1,5 @@ import React from 'react' export default function HorizontalRule() { - return + return } HorizontalRule.size = [10, 16] diff --git a/lib/octicons_react/icons/hubot.js b/lib/octicons_react/icons/hubot.js index 5389522c9..5cd600dfb 100644 --- a/lib/octicons_react/icons/hubot.js +++ b/lib/octicons_react/icons/hubot.js @@ -1,5 +1,5 @@ import React from 'react' export default function Hubot() { - return + return } Hubot.size = [14, 16] diff --git a/lib/octicons_react/icons/inbox.js b/lib/octicons_react/icons/inbox.js index dec40fff6..dd4e332d1 100644 --- a/lib/octicons_react/icons/inbox.js +++ b/lib/octicons_react/icons/inbox.js @@ -1,5 +1,5 @@ import React from 'react' export default function Inbox() { - return + return } Inbox.size = [14, 16] diff --git a/lib/octicons_react/icons/info.js b/lib/octicons_react/icons/info.js index 8e95fdc8d..b29ea587a 100644 --- a/lib/octicons_react/icons/info.js +++ b/lib/octicons_react/icons/info.js @@ -1,5 +1,5 @@ import React from 'react' export default function Info() { - return + return } Info.size = [14, 16] diff --git a/lib/octicons_react/icons/issue-closed.js b/lib/octicons_react/icons/issue-closed.js index 52694f7ed..da40d74f3 100644 --- a/lib/octicons_react/icons/issue-closed.js +++ b/lib/octicons_react/icons/issue-closed.js @@ -1,5 +1,5 @@ import React from 'react' export default function IssueClosed() { - return + return } IssueClosed.size = [16, 16] diff --git a/lib/octicons_react/icons/issue-opened.js b/lib/octicons_react/icons/issue-opened.js index e2102adb8..1b7a5bace 100644 --- a/lib/octicons_react/icons/issue-opened.js +++ b/lib/octicons_react/icons/issue-opened.js @@ -1,5 +1,5 @@ import React from 'react' export default function IssueOpened() { - return + return } IssueOpened.size = [14, 16] diff --git a/lib/octicons_react/icons/issue-reopened.js b/lib/octicons_react/icons/issue-reopened.js index c7250e6d3..3d0f62892 100644 --- a/lib/octicons_react/icons/issue-reopened.js +++ b/lib/octicons_react/icons/issue-reopened.js @@ -1,5 +1,5 @@ import React from 'react' export default function IssueReopened() { - return + return } IssueReopened.size = [14, 16] diff --git a/lib/octicons_react/icons/italic.js b/lib/octicons_react/icons/italic.js index 91f945d19..8a09a4529 100644 --- a/lib/octicons_react/icons/italic.js +++ b/lib/octicons_react/icons/italic.js @@ -1,5 +1,5 @@ import React from 'react' export default function Italic() { - return + return } Italic.size = [6, 16] diff --git a/lib/octicons_react/icons/jersey.js b/lib/octicons_react/icons/jersey.js index 22ae80585..aee2f16f5 100644 --- a/lib/octicons_react/icons/jersey.js +++ b/lib/octicons_react/icons/jersey.js @@ -1,5 +1,5 @@ import React from 'react' export default function Jersey() { - return + return } Jersey.size = [14, 16] diff --git a/lib/octicons_react/icons/kebab-horizontal.js b/lib/octicons_react/icons/kebab-horizontal.js index 649912f75..580d71127 100644 --- a/lib/octicons_react/icons/kebab-horizontal.js +++ b/lib/octicons_react/icons/kebab-horizontal.js @@ -1,5 +1,5 @@ import React from 'react' export default function KebabHorizontal() { - return + return } KebabHorizontal.size = [13, 16] diff --git a/lib/octicons_react/icons/kebab-vertical.js b/lib/octicons_react/icons/kebab-vertical.js index 793a5ec8a..8f671046b 100644 --- a/lib/octicons_react/icons/kebab-vertical.js +++ b/lib/octicons_react/icons/kebab-vertical.js @@ -1,5 +1,5 @@ import React from 'react' export default function KebabVertical() { - return + return } KebabVertical.size = [3, 16] diff --git a/lib/octicons_react/icons/key.js b/lib/octicons_react/icons/key.js index 0cdbb4e14..0dbf986d1 100644 --- a/lib/octicons_react/icons/key.js +++ b/lib/octicons_react/icons/key.js @@ -1,5 +1,5 @@ import React from 'react' export default function Key() { - return + return } Key.size = [14, 16] diff --git a/lib/octicons_react/icons/keyboard.js b/lib/octicons_react/icons/keyboard.js index f653ed01e..58b2b9b3d 100644 --- a/lib/octicons_react/icons/keyboard.js +++ b/lib/octicons_react/icons/keyboard.js @@ -1,5 +1,5 @@ import React from 'react' export default function Keyboard() { - return + return } Keyboard.size = [16, 16] diff --git a/lib/octicons_react/icons/law.js b/lib/octicons_react/icons/law.js index bcc651cd5..ebbae4e03 100644 --- a/lib/octicons_react/icons/law.js +++ b/lib/octicons_react/icons/law.js @@ -1,5 +1,5 @@ import React from 'react' export default function Law() { - return + return } Law.size = [14, 16] diff --git a/lib/octicons_react/icons/light-bulb.js b/lib/octicons_react/icons/light-bulb.js index b15ea431b..db182b808 100644 --- a/lib/octicons_react/icons/light-bulb.js +++ b/lib/octicons_react/icons/light-bulb.js @@ -1,5 +1,5 @@ import React from 'react' export default function LightBulb() { - return + return } LightBulb.size = [12, 16] diff --git a/lib/octicons_react/icons/link-external.js b/lib/octicons_react/icons/link-external.js index 9ad902d22..d4cf9c4bc 100644 --- a/lib/octicons_react/icons/link-external.js +++ b/lib/octicons_react/icons/link-external.js @@ -1,5 +1,5 @@ import React from 'react' export default function LinkExternal() { - return + return } LinkExternal.size = [12, 16] diff --git a/lib/octicons_react/icons/link.js b/lib/octicons_react/icons/link.js index cadc433a0..bc013ee2d 100644 --- a/lib/octicons_react/icons/link.js +++ b/lib/octicons_react/icons/link.js @@ -1,5 +1,5 @@ import React from 'react' export default function Link() { - return + return } Link.size = [16, 16] diff --git a/lib/octicons_react/icons/list-ordered.js b/lib/octicons_react/icons/list-ordered.js index 4ae3633e0..2184b73d5 100644 --- a/lib/octicons_react/icons/list-ordered.js +++ b/lib/octicons_react/icons/list-ordered.js @@ -1,5 +1,5 @@ import React from 'react' export default function ListOrdered() { - return + return } ListOrdered.size = [12, 16] diff --git a/lib/octicons_react/icons/list-unordered.js b/lib/octicons_react/icons/list-unordered.js index d5df18c2a..f8475df59 100644 --- a/lib/octicons_react/icons/list-unordered.js +++ b/lib/octicons_react/icons/list-unordered.js @@ -1,5 +1,5 @@ import React from 'react' export default function ListUnordered() { - return + return } ListUnordered.size = [12, 16] diff --git a/lib/octicons_react/icons/location.js b/lib/octicons_react/icons/location.js index 618d8b8ea..81f86e17f 100644 --- a/lib/octicons_react/icons/location.js +++ b/lib/octicons_react/icons/location.js @@ -1,5 +1,5 @@ import React from 'react' export default function Location() { - return + return } Location.size = [12, 16] diff --git a/lib/octicons_react/icons/lock.js b/lib/octicons_react/icons/lock.js index 9729fca8e..1403b135a 100644 --- a/lib/octicons_react/icons/lock.js +++ b/lib/octicons_react/icons/lock.js @@ -1,5 +1,5 @@ import React from 'react' export default function Lock() { - return + return } Lock.size = [12, 16] diff --git a/lib/octicons_react/icons/logo-gist.js b/lib/octicons_react/icons/logo-gist.js index 4773fa392..5d829e73c 100644 --- a/lib/octicons_react/icons/logo-gist.js +++ b/lib/octicons_react/icons/logo-gist.js @@ -1,5 +1,5 @@ import React from 'react' export default function LogoGist() { - return + return } LogoGist.size = [25, 16] diff --git a/lib/octicons_react/icons/logo-github.js b/lib/octicons_react/icons/logo-github.js index 6501976c7..12ea8fe35 100644 --- a/lib/octicons_react/icons/logo-github.js +++ b/lib/octicons_react/icons/logo-github.js @@ -1,5 +1,5 @@ import React from 'react' export default function LogoGithub() { - return + return } LogoGithub.size = [45, 16] diff --git a/lib/octicons_react/icons/mail-read.js b/lib/octicons_react/icons/mail-read.js index d216b5792..94872a9be 100644 --- a/lib/octicons_react/icons/mail-read.js +++ b/lib/octicons_react/icons/mail-read.js @@ -1,5 +1,5 @@ import React from 'react' export default function MailRead() { - return + return } MailRead.size = [14, 16] diff --git a/lib/octicons_react/icons/mail.js b/lib/octicons_react/icons/mail.js index 3449a3b05..83120dcd7 100644 --- a/lib/octicons_react/icons/mail.js +++ b/lib/octicons_react/icons/mail.js @@ -1,5 +1,5 @@ import React from 'react' export default function Mail() { - return + return } Mail.size = [14, 16] diff --git a/lib/octicons_react/icons/mark-github.js b/lib/octicons_react/icons/mark-github.js index 0b2841fb9..6668c8f17 100644 --- a/lib/octicons_react/icons/mark-github.js +++ b/lib/octicons_react/icons/mark-github.js @@ -1,5 +1,5 @@ import React from 'react' export default function MarkGithub() { - return + return } MarkGithub.size = [16, 16] diff --git a/lib/octicons_react/icons/markdown.js b/lib/octicons_react/icons/markdown.js index d3b0f080b..e483a58a9 100644 --- a/lib/octicons_react/icons/markdown.js +++ b/lib/octicons_react/icons/markdown.js @@ -1,5 +1,5 @@ import React from 'react' export default function Markdown() { - return + return } Markdown.size = [16, 16] diff --git a/lib/octicons_react/icons/megaphone.js b/lib/octicons_react/icons/megaphone.js index 76f356235..bc40997b0 100644 --- a/lib/octicons_react/icons/megaphone.js +++ b/lib/octicons_react/icons/megaphone.js @@ -1,5 +1,5 @@ import React from 'react' export default function Megaphone() { - return + return } Megaphone.size = [16, 16] diff --git a/lib/octicons_react/icons/mention.js b/lib/octicons_react/icons/mention.js index 577b787ee..8aef19180 100644 --- a/lib/octicons_react/icons/mention.js +++ b/lib/octicons_react/icons/mention.js @@ -1,5 +1,5 @@ import React from 'react' export default function Mention() { - return + return } Mention.size = [14, 16] diff --git a/lib/octicons_react/icons/milestone.js b/lib/octicons_react/icons/milestone.js index 0022c94b5..50e939fc4 100644 --- a/lib/octicons_react/icons/milestone.js +++ b/lib/octicons_react/icons/milestone.js @@ -1,5 +1,5 @@ import React from 'react' export default function Milestone() { - return + return } Milestone.size = [14, 16] diff --git a/lib/octicons_react/icons/mirror.js b/lib/octicons_react/icons/mirror.js index 4e299b752..6f9498894 100644 --- a/lib/octicons_react/icons/mirror.js +++ b/lib/octicons_react/icons/mirror.js @@ -1,5 +1,5 @@ import React from 'react' export default function Mirror() { - return + return } Mirror.size = [16, 16] diff --git a/lib/octicons_react/icons/mortar-board.js b/lib/octicons_react/icons/mortar-board.js index 38662e187..70bf2ef9b 100644 --- a/lib/octicons_react/icons/mortar-board.js +++ b/lib/octicons_react/icons/mortar-board.js @@ -1,5 +1,5 @@ import React from 'react' export default function MortarBoard() { - return + return } MortarBoard.size = [16, 16] diff --git a/lib/octicons_react/icons/mute.js b/lib/octicons_react/icons/mute.js index 78ea728f6..bbc46c242 100644 --- a/lib/octicons_react/icons/mute.js +++ b/lib/octicons_react/icons/mute.js @@ -1,5 +1,5 @@ import React from 'react' export default function Mute() { - return + return } Mute.size = [16, 16] diff --git a/lib/octicons_react/icons/no-newline.js b/lib/octicons_react/icons/no-newline.js index 1701315fa..c92f7a498 100644 --- a/lib/octicons_react/icons/no-newline.js +++ b/lib/octicons_react/icons/no-newline.js @@ -1,5 +1,5 @@ import React from 'react' export default function NoNewline() { - return + return } NoNewline.size = [16, 16] diff --git a/lib/octicons_react/icons/note.js b/lib/octicons_react/icons/note.js index 642ec1f13..70a370a71 100644 --- a/lib/octicons_react/icons/note.js +++ b/lib/octicons_react/icons/note.js @@ -1,5 +1,5 @@ import React from 'react' export default function Note() { - return + return } Note.size = [14, 16] diff --git a/lib/octicons_react/icons/octoface.js b/lib/octicons_react/icons/octoface.js index 34149f2f6..9ac6cb61f 100644 --- a/lib/octicons_react/icons/octoface.js +++ b/lib/octicons_react/icons/octoface.js @@ -1,5 +1,5 @@ import React from 'react' export default function Octoface() { - return + return } Octoface.size = [16, 16] diff --git a/lib/octicons_react/icons/organization.js b/lib/octicons_react/icons/organization.js index 6a6522482..6c45abb4b 100644 --- a/lib/octicons_react/icons/organization.js +++ b/lib/octicons_react/icons/organization.js @@ -1,5 +1,5 @@ import React from 'react' export default function Organization() { - return + return } Organization.size = [16, 16] diff --git a/lib/octicons_react/icons/package.js b/lib/octicons_react/icons/package.js index c063ae4e3..587546f10 100644 --- a/lib/octicons_react/icons/package.js +++ b/lib/octicons_react/icons/package.js @@ -1,5 +1,5 @@ import React from 'react' export default function Package() { - return + return } Package.size = [16, 16] diff --git a/lib/octicons_react/icons/paintcan.js b/lib/octicons_react/icons/paintcan.js index da1af3574..15e9d2658 100644 --- a/lib/octicons_react/icons/paintcan.js +++ b/lib/octicons_react/icons/paintcan.js @@ -1,5 +1,5 @@ import React from 'react' export default function Paintcan() { - return + return } Paintcan.size = [12, 16] diff --git a/lib/octicons_react/icons/pencil.js b/lib/octicons_react/icons/pencil.js index 650ed192c..d3c99cd2b 100644 --- a/lib/octicons_react/icons/pencil.js +++ b/lib/octicons_react/icons/pencil.js @@ -1,5 +1,5 @@ import React from 'react' export default function Pencil() { - return + return } Pencil.size = [14, 16] diff --git a/lib/octicons_react/icons/person.js b/lib/octicons_react/icons/person.js index 6336210cc..97f5cb7af 100644 --- a/lib/octicons_react/icons/person.js +++ b/lib/octicons_react/icons/person.js @@ -1,5 +1,5 @@ import React from 'react' export default function Person() { - return + return } Person.size = [12, 16] diff --git a/lib/octicons_react/icons/pin.js b/lib/octicons_react/icons/pin.js index 2e5e7bc79..3b2a20c94 100644 --- a/lib/octicons_react/icons/pin.js +++ b/lib/octicons_react/icons/pin.js @@ -1,5 +1,5 @@ import React from 'react' export default function Pin() { - return + return } Pin.size = [16, 16] diff --git a/lib/octicons_react/icons/plug.js b/lib/octicons_react/icons/plug.js index ce742c38b..0edae3ebb 100644 --- a/lib/octicons_react/icons/plug.js +++ b/lib/octicons_react/icons/plug.js @@ -1,5 +1,5 @@ import React from 'react' export default function Plug() { - return + return } Plug.size = [14, 16] diff --git a/lib/octicons_react/icons/plus-small.js b/lib/octicons_react/icons/plus-small.js index 633b81a90..d12158521 100644 --- a/lib/octicons_react/icons/plus-small.js +++ b/lib/octicons_react/icons/plus-small.js @@ -1,5 +1,5 @@ import React from 'react' export default function PlusSmall() { - return + return } PlusSmall.size = [7, 16] diff --git a/lib/octicons_react/icons/plus.js b/lib/octicons_react/icons/plus.js index 384611bcb..4156950c0 100644 --- a/lib/octicons_react/icons/plus.js +++ b/lib/octicons_react/icons/plus.js @@ -1,5 +1,5 @@ import React from 'react' export default function Plus() { - return + return } Plus.size = [12, 16] diff --git a/lib/octicons_react/icons/primitive-dot.js b/lib/octicons_react/icons/primitive-dot.js index 2e8bcb623..074a54b0a 100644 --- a/lib/octicons_react/icons/primitive-dot.js +++ b/lib/octicons_react/icons/primitive-dot.js @@ -1,5 +1,5 @@ import React from 'react' export default function PrimitiveDot() { - return + return } PrimitiveDot.size = [8, 16] diff --git a/lib/octicons_react/icons/primitive-square.js b/lib/octicons_react/icons/primitive-square.js index 7b8852a95..dd0ec3c4c 100644 --- a/lib/octicons_react/icons/primitive-square.js +++ b/lib/octicons_react/icons/primitive-square.js @@ -1,5 +1,5 @@ import React from 'react' export default function PrimitiveSquare() { - return + return } PrimitiveSquare.size = [8, 16] diff --git a/lib/octicons_react/icons/project.js b/lib/octicons_react/icons/project.js index 3bc8ca90a..50aa19e7f 100644 --- a/lib/octicons_react/icons/project.js +++ b/lib/octicons_react/icons/project.js @@ -1,5 +1,5 @@ import React from 'react' export default function Project() { - return + return } Project.size = [15, 16] diff --git a/lib/octicons_react/icons/pulse.js b/lib/octicons_react/icons/pulse.js index d1ccfa44f..a8acc1858 100644 --- a/lib/octicons_react/icons/pulse.js +++ b/lib/octicons_react/icons/pulse.js @@ -1,5 +1,5 @@ import React from 'react' export default function Pulse() { - return + return } Pulse.size = [14, 16] diff --git a/lib/octicons_react/icons/question.js b/lib/octicons_react/icons/question.js index f47c7dbd1..7c6b88b89 100644 --- a/lib/octicons_react/icons/question.js +++ b/lib/octicons_react/icons/question.js @@ -1,5 +1,5 @@ import React from 'react' export default function Question() { - return + return } Question.size = [14, 16] diff --git a/lib/octicons_react/icons/quote.js b/lib/octicons_react/icons/quote.js index 53a3c7a3f..480b41e8a 100644 --- a/lib/octicons_react/icons/quote.js +++ b/lib/octicons_react/icons/quote.js @@ -1,5 +1,5 @@ import React from 'react' export default function Quote() { - return + return } Quote.size = [14, 16] diff --git a/lib/octicons_react/icons/radio-tower.js b/lib/octicons_react/icons/radio-tower.js index fbd9bed7c..8f5a05060 100644 --- a/lib/octicons_react/icons/radio-tower.js +++ b/lib/octicons_react/icons/radio-tower.js @@ -1,5 +1,5 @@ import React from 'react' export default function RadioTower() { - return + return } RadioTower.size = [16, 16] diff --git a/lib/octicons_react/icons/reply.js b/lib/octicons_react/icons/reply.js index f36b3880f..8fb8274c9 100644 --- a/lib/octicons_react/icons/reply.js +++ b/lib/octicons_react/icons/reply.js @@ -1,5 +1,5 @@ import React from 'react' export default function Reply() { - return + return } Reply.size = [14, 16] diff --git a/lib/octicons_react/icons/repo-clone.js b/lib/octicons_react/icons/repo-clone.js index 7984bbea1..f2efe36b7 100644 --- a/lib/octicons_react/icons/repo-clone.js +++ b/lib/octicons_react/icons/repo-clone.js @@ -1,5 +1,5 @@ import React from 'react' export default function RepoClone() { - return + return } RepoClone.size = [16, 16] diff --git a/lib/octicons_react/icons/repo-force-push.js b/lib/octicons_react/icons/repo-force-push.js index d5f0a64b0..f520f8d95 100644 --- a/lib/octicons_react/icons/repo-force-push.js +++ b/lib/octicons_react/icons/repo-force-push.js @@ -1,5 +1,5 @@ import React from 'react' export default function RepoForcePush() { - return + return } RepoForcePush.size = [12, 16] diff --git a/lib/octicons_react/icons/repo-forked.js b/lib/octicons_react/icons/repo-forked.js index 6a48c0209..07d1a685f 100644 --- a/lib/octicons_react/icons/repo-forked.js +++ b/lib/octicons_react/icons/repo-forked.js @@ -1,5 +1,5 @@ import React from 'react' export default function RepoForked() { - return + return } RepoForked.size = [10, 16] diff --git a/lib/octicons_react/icons/repo-pull.js b/lib/octicons_react/icons/repo-pull.js index 38038e29c..d66167948 100644 --- a/lib/octicons_react/icons/repo-pull.js +++ b/lib/octicons_react/icons/repo-pull.js @@ -1,5 +1,5 @@ import React from 'react' export default function RepoPull() { - return + return } RepoPull.size = [16, 16] diff --git a/lib/octicons_react/icons/repo-push.js b/lib/octicons_react/icons/repo-push.js index 8d921def6..3751f5ea0 100644 --- a/lib/octicons_react/icons/repo-push.js +++ b/lib/octicons_react/icons/repo-push.js @@ -1,5 +1,5 @@ import React from 'react' export default function RepoPush() { - return + return } RepoPush.size = [12, 16] diff --git a/lib/octicons_react/icons/repo.js b/lib/octicons_react/icons/repo.js index 1088ef5da..c93a40730 100644 --- a/lib/octicons_react/icons/repo.js +++ b/lib/octicons_react/icons/repo.js @@ -1,5 +1,5 @@ import React from 'react' export default function Repo() { - return + return } Repo.size = [12, 16] diff --git a/lib/octicons_react/icons/report.js b/lib/octicons_react/icons/report.js index c7622c380..5987aada4 100644 --- a/lib/octicons_react/icons/report.js +++ b/lib/octicons_react/icons/report.js @@ -1,5 +1,5 @@ import React from 'react' export default function Report() { - return + return } Report.size = [16, 16] diff --git a/lib/octicons_react/icons/rocket.js b/lib/octicons_react/icons/rocket.js index 8c506da8c..55f81b0d2 100644 --- a/lib/octicons_react/icons/rocket.js +++ b/lib/octicons_react/icons/rocket.js @@ -1,5 +1,5 @@ import React from 'react' export default function Rocket() { - return + return } Rocket.size = [16, 16] diff --git a/lib/octicons_react/icons/rss.js b/lib/octicons_react/icons/rss.js index 36a630b8a..6ca3650c6 100644 --- a/lib/octicons_react/icons/rss.js +++ b/lib/octicons_react/icons/rss.js @@ -1,5 +1,5 @@ import React from 'react' export default function Rss() { - return + return } Rss.size = [10, 16] diff --git a/lib/octicons_react/icons/ruby.js b/lib/octicons_react/icons/ruby.js index d36883a85..f2f221bc5 100644 --- a/lib/octicons_react/icons/ruby.js +++ b/lib/octicons_react/icons/ruby.js @@ -1,5 +1,5 @@ import React from 'react' export default function Ruby() { - return + return } Ruby.size = [16, 16] diff --git a/lib/octicons_react/icons/screen-full.js b/lib/octicons_react/icons/screen-full.js index 29ff6f06d..24d07ee23 100644 --- a/lib/octicons_react/icons/screen-full.js +++ b/lib/octicons_react/icons/screen-full.js @@ -1,5 +1,5 @@ import React from 'react' export default function ScreenFull() { - return + return } ScreenFull.size = [14, 16] diff --git a/lib/octicons_react/icons/screen-normal.js b/lib/octicons_react/icons/screen-normal.js index c6e6b357e..e3e3e314e 100644 --- a/lib/octicons_react/icons/screen-normal.js +++ b/lib/octicons_react/icons/screen-normal.js @@ -1,5 +1,5 @@ import React from 'react' export default function ScreenNormal() { - return + return } ScreenNormal.size = [14, 16] diff --git a/lib/octicons_react/icons/search.js b/lib/octicons_react/icons/search.js index 6af268d09..b5e9343e7 100644 --- a/lib/octicons_react/icons/search.js +++ b/lib/octicons_react/icons/search.js @@ -1,5 +1,5 @@ import React from 'react' export default function Search() { - return + return } Search.size = [16, 16] diff --git a/lib/octicons_react/icons/server.js b/lib/octicons_react/icons/server.js index b1b20501c..4e08d0f6d 100644 --- a/lib/octicons_react/icons/server.js +++ b/lib/octicons_react/icons/server.js @@ -1,5 +1,5 @@ import React from 'react' export default function Server() { - return + return } Server.size = [12, 16] diff --git a/lib/octicons_react/icons/settings.js b/lib/octicons_react/icons/settings.js index 73bc9c219..353c70e35 100644 --- a/lib/octicons_react/icons/settings.js +++ b/lib/octicons_react/icons/settings.js @@ -1,5 +1,5 @@ import React from 'react' export default function Settings() { - return + return } Settings.size = [16, 16] diff --git a/lib/octicons_react/icons/shield.js b/lib/octicons_react/icons/shield.js index 285d89af0..3b90d337d 100644 --- a/lib/octicons_react/icons/shield.js +++ b/lib/octicons_react/icons/shield.js @@ -1,5 +1,5 @@ import React from 'react' export default function Shield() { - return + return } Shield.size = [14, 16] diff --git a/lib/octicons_react/icons/sign-in.js b/lib/octicons_react/icons/sign-in.js index 522b5d398..dccaccc47 100644 --- a/lib/octicons_react/icons/sign-in.js +++ b/lib/octicons_react/icons/sign-in.js @@ -1,5 +1,5 @@ import React from 'react' export default function SignIn() { - return + return } SignIn.size = [14, 16] diff --git a/lib/octicons_react/icons/sign-out.js b/lib/octicons_react/icons/sign-out.js index 88f779454..3a0dc8d45 100644 --- a/lib/octicons_react/icons/sign-out.js +++ b/lib/octicons_react/icons/sign-out.js @@ -1,5 +1,5 @@ import React from 'react' export default function SignOut() { - return + return } SignOut.size = [16, 16] diff --git a/lib/octicons_react/icons/smiley.js b/lib/octicons_react/icons/smiley.js index 8aa509c9e..57104b959 100644 --- a/lib/octicons_react/icons/smiley.js +++ b/lib/octicons_react/icons/smiley.js @@ -1,5 +1,5 @@ import React from 'react' export default function Smiley() { - return + return } Smiley.size = [16, 16] diff --git a/lib/octicons_react/icons/squirrel.js b/lib/octicons_react/icons/squirrel.js index aef5f326d..91a2fac1f 100644 --- a/lib/octicons_react/icons/squirrel.js +++ b/lib/octicons_react/icons/squirrel.js @@ -1,5 +1,5 @@ import React from 'react' export default function Squirrel() { - return + return } Squirrel.size = [16, 16] diff --git a/lib/octicons_react/icons/star.js b/lib/octicons_react/icons/star.js index e7e1456a3..514164d08 100644 --- a/lib/octicons_react/icons/star.js +++ b/lib/octicons_react/icons/star.js @@ -1,5 +1,5 @@ import React from 'react' export default function Star() { - return + return } Star.size = [14, 16] diff --git a/lib/octicons_react/icons/stop.js b/lib/octicons_react/icons/stop.js index e558cf2d9..3865e5bbb 100644 --- a/lib/octicons_react/icons/stop.js +++ b/lib/octicons_react/icons/stop.js @@ -1,5 +1,5 @@ import React from 'react' export default function Stop() { - return + return } Stop.size = [14, 16] diff --git a/lib/octicons_react/icons/sync.js b/lib/octicons_react/icons/sync.js index 1952c0d48..2bd22c00b 100644 --- a/lib/octicons_react/icons/sync.js +++ b/lib/octicons_react/icons/sync.js @@ -1,5 +1,5 @@ import React from 'react' export default function Sync() { - return + return } Sync.size = [12, 16] diff --git a/lib/octicons_react/icons/tag.js b/lib/octicons_react/icons/tag.js index 5da8cf47a..52e923068 100644 --- a/lib/octicons_react/icons/tag.js +++ b/lib/octicons_react/icons/tag.js @@ -1,5 +1,5 @@ import React from 'react' export default function Tag() { - return + return } Tag.size = [14, 16] diff --git a/lib/octicons_react/icons/tasklist.js b/lib/octicons_react/icons/tasklist.js index 98265fefb..310aadb25 100644 --- a/lib/octicons_react/icons/tasklist.js +++ b/lib/octicons_react/icons/tasklist.js @@ -1,5 +1,5 @@ import React from 'react' export default function Tasklist() { - return + return } Tasklist.size = [16, 16] diff --git a/lib/octicons_react/icons/telescope.js b/lib/octicons_react/icons/telescope.js index 28888e65e..f43753f97 100644 --- a/lib/octicons_react/icons/telescope.js +++ b/lib/octicons_react/icons/telescope.js @@ -1,5 +1,5 @@ import React from 'react' export default function Telescope() { - return + return } Telescope.size = [14, 16] diff --git a/lib/octicons_react/icons/terminal.js b/lib/octicons_react/icons/terminal.js index 5003ab1bb..4a4156f75 100644 --- a/lib/octicons_react/icons/terminal.js +++ b/lib/octicons_react/icons/terminal.js @@ -1,5 +1,5 @@ import React from 'react' export default function Terminal() { - return + return } Terminal.size = [14, 16] diff --git a/lib/octicons_react/icons/text-size.js b/lib/octicons_react/icons/text-size.js index e943a72a1..b86db24e7 100644 --- a/lib/octicons_react/icons/text-size.js +++ b/lib/octicons_react/icons/text-size.js @@ -1,5 +1,5 @@ import React from 'react' export default function TextSize() { - return + return } TextSize.size = [18, 16] diff --git a/lib/octicons_react/icons/three-bars.js b/lib/octicons_react/icons/three-bars.js index d786b4320..604eecce7 100644 --- a/lib/octicons_react/icons/three-bars.js +++ b/lib/octicons_react/icons/three-bars.js @@ -1,5 +1,5 @@ import React from 'react' export default function ThreeBars() { - return + return } ThreeBars.size = [12, 16] diff --git a/lib/octicons_react/icons/thumbsdown.js b/lib/octicons_react/icons/thumbsdown.js index c21192fc0..40373f261 100644 --- a/lib/octicons_react/icons/thumbsdown.js +++ b/lib/octicons_react/icons/thumbsdown.js @@ -1,5 +1,5 @@ import React from 'react' export default function Thumbsdown() { - return + return } Thumbsdown.size = [16, 16] diff --git a/lib/octicons_react/icons/thumbsup.js b/lib/octicons_react/icons/thumbsup.js index 225a2f4bf..5ce407360 100644 --- a/lib/octicons_react/icons/thumbsup.js +++ b/lib/octicons_react/icons/thumbsup.js @@ -1,5 +1,5 @@ import React from 'react' export default function Thumbsup() { - return + return } Thumbsup.size = [16, 16] diff --git a/lib/octicons_react/icons/tools.js b/lib/octicons_react/icons/tools.js index 07c49dd7d..dea686981 100644 --- a/lib/octicons_react/icons/tools.js +++ b/lib/octicons_react/icons/tools.js @@ -1,5 +1,5 @@ import React from 'react' export default function Tools() { - return + return } Tools.size = [16, 16] diff --git a/lib/octicons_react/icons/trashcan.js b/lib/octicons_react/icons/trashcan.js index 7369ce7ca..2800b7358 100644 --- a/lib/octicons_react/icons/trashcan.js +++ b/lib/octicons_react/icons/trashcan.js @@ -1,5 +1,5 @@ import React from 'react' export default function Trashcan() { - return + return } Trashcan.size = [12, 16] diff --git a/lib/octicons_react/icons/triangle-down.js b/lib/octicons_react/icons/triangle-down.js index a3ba3afff..7fb3d8f6b 100644 --- a/lib/octicons_react/icons/triangle-down.js +++ b/lib/octicons_react/icons/triangle-down.js @@ -1,5 +1,5 @@ import React from 'react' export default function TriangleDown() { - return + return } TriangleDown.size = [12, 16] diff --git a/lib/octicons_react/icons/triangle-left.js b/lib/octicons_react/icons/triangle-left.js index 188df9997..04edd03dd 100644 --- a/lib/octicons_react/icons/triangle-left.js +++ b/lib/octicons_react/icons/triangle-left.js @@ -1,5 +1,5 @@ import React from 'react' export default function TriangleLeft() { - return + return } TriangleLeft.size = [6, 16] diff --git a/lib/octicons_react/icons/triangle-right.js b/lib/octicons_react/icons/triangle-right.js index 0db185e15..323f41ce8 100644 --- a/lib/octicons_react/icons/triangle-right.js +++ b/lib/octicons_react/icons/triangle-right.js @@ -1,5 +1,5 @@ import React from 'react' export default function TriangleRight() { - return + return } TriangleRight.size = [6, 16] diff --git a/lib/octicons_react/icons/triangle-up.js b/lib/octicons_react/icons/triangle-up.js index c62d1c631..0bed44d8d 100644 --- a/lib/octicons_react/icons/triangle-up.js +++ b/lib/octicons_react/icons/triangle-up.js @@ -1,5 +1,5 @@ import React from 'react' export default function TriangleUp() { - return + return } TriangleUp.size = [12, 16] diff --git a/lib/octicons_react/icons/unfold.js b/lib/octicons_react/icons/unfold.js index b67c8cd98..c411d15be 100644 --- a/lib/octicons_react/icons/unfold.js +++ b/lib/octicons_react/icons/unfold.js @@ -1,5 +1,5 @@ import React from 'react' export default function Unfold() { - return + return } Unfold.size = [14, 16] diff --git a/lib/octicons_react/icons/unmute.js b/lib/octicons_react/icons/unmute.js index a638b7cd9..2b05fc834 100644 --- a/lib/octicons_react/icons/unmute.js +++ b/lib/octicons_react/icons/unmute.js @@ -1,5 +1,5 @@ import React from 'react' export default function Unmute() { - return + return } Unmute.size = [16, 16] diff --git a/lib/octicons_react/icons/unverified.js b/lib/octicons_react/icons/unverified.js index aea1d5342..9cf29e846 100644 --- a/lib/octicons_react/icons/unverified.js +++ b/lib/octicons_react/icons/unverified.js @@ -1,5 +1,5 @@ import React from 'react' export default function Unverified() { - return + return } Unverified.size = [16, 16] diff --git a/lib/octicons_react/icons/verified.js b/lib/octicons_react/icons/verified.js index 134522b80..ec8765e66 100644 --- a/lib/octicons_react/icons/verified.js +++ b/lib/octicons_react/icons/verified.js @@ -1,5 +1,5 @@ import React from 'react' export default function Verified() { - return + return } Verified.size = [16, 16] diff --git a/lib/octicons_react/icons/versions.js b/lib/octicons_react/icons/versions.js index 62f05c050..0078d7f9e 100644 --- a/lib/octicons_react/icons/versions.js +++ b/lib/octicons_react/icons/versions.js @@ -1,5 +1,5 @@ import React from 'react' export default function Versions() { - return + return } Versions.size = [14, 16] diff --git a/lib/octicons_react/icons/watch.js b/lib/octicons_react/icons/watch.js index 09cbde259..a86c6c88e 100644 --- a/lib/octicons_react/icons/watch.js +++ b/lib/octicons_react/icons/watch.js @@ -1,5 +1,5 @@ import React from 'react' export default function Watch() { - return + return } Watch.size = [12, 16] diff --git a/lib/octicons_react/icons/x.js b/lib/octicons_react/icons/x.js index 50291adf6..17269f8ee 100644 --- a/lib/octicons_react/icons/x.js +++ b/lib/octicons_react/icons/x.js @@ -1,5 +1,5 @@ import React from 'react' export default function X() { - return + return } X.size = [12, 16] diff --git a/lib/octicons_react/icons/zap.js b/lib/octicons_react/icons/zap.js index 9d2f89288..3a5775fd0 100644 --- a/lib/octicons_react/icons/zap.js +++ b/lib/octicons_react/icons/zap.js @@ -1,5 +1,5 @@ import React from 'react' export default function Zap() { - return + return } Zap.size = [10, 16] diff --git a/lib/octicons_react/script/build.js b/lib/octicons_react/script/build.js index a9dc4ebac..baaa0665f 100755 --- a/lib/octicons_react/script/build.js +++ b/lib/octicons_react/script/build.js @@ -12,9 +12,11 @@ function CamelCase(str) { const icons = [...Object.entries(octicons)].map(([key, octicon]) => { const name = CamelCase(key) const {width, height, path} = octicon + // convert attributes like fill-rule into JSX equivalents, e.g. fillRule + const svg = path.replace(/([a-z]+)-([a-z]+)=/g, (_, a, b) => `${a}${CamelCase(b)}=`) const code = `import React from 'react' export default function ${name}() { -return ${path} + return ${svg} } ${name}.size = [${width}, ${height}] ` From c3e4956969a7dbcb5edac409889590a9d1143dd8 Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Wed, 27 Jun 2018 15:27:05 -0700 Subject: [PATCH 66/97] remove un-applied quotes rule --- lib/octicons_react/.eslintrc.json | 1 - 1 file changed, 1 deletion(-) diff --git a/lib/octicons_react/.eslintrc.json b/lib/octicons_react/.eslintrc.json index 5f2203418..dc20bf90b 100644 --- a/lib/octicons_react/.eslintrc.json +++ b/lib/octicons_react/.eslintrc.json @@ -5,6 +5,5 @@ "plugin:github/react" ], "rules": { - "quotes": ["warn", "single"] } } From 35029db1f6319ab873ea8453e59b2d1188f25f54 Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Wed, 27 Jun 2018 15:27:29 -0700 Subject: [PATCH 67/97] don't lint generated .js files --- lib/octicons_react/.eslintignore | 1 + 1 file changed, 1 insertion(+) create mode 100644 lib/octicons_react/.eslintignore diff --git a/lib/octicons_react/.eslintignore b/lib/octicons_react/.eslintignore new file mode 100644 index 000000000..f9d122e9d --- /dev/null +++ b/lib/octicons_react/.eslintignore @@ -0,0 +1 @@ +icons/*.js From e3c85df8b4f0fd44ff20e378f8083ba95ebc3c37 Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Wed, 27 Jun 2018 15:28:33 -0700 Subject: [PATCH 68/97] eslint --fix --- lib/octicons_react/index.js | 19 ++++--------------- 1 file changed, 4 insertions(+), 15 deletions(-) diff --git a/lib/octicons_react/index.js b/lib/octicons_react/index.js index aa9da3a54..b955e2f52 100644 --- a/lib/octicons_react/index.js +++ b/lib/octicons_react/index.js @@ -15,18 +15,9 @@ const alignMap = { const defaultSize = [16, 16] export default function Octicon(props) { - const { - ariaLabel, - children, - className = 'octicon', - icon: Icon, - size, - verticalAlign - } = props + const {ariaLabel, children, className = 'octicon', icon: Icon, size, verticalAlign} = props - const child = (typeof Icon === 'function') - ? - : React.Children.only(children) + const child = typeof Icon === 'function' ? : React.Children.only(children) const [width, height] = child.type.size || defaultSize const attrs = { @@ -41,7 +32,7 @@ export default function Octicon(props) { attrs.height = sizeMap[size] } - attrs.width = attrs.height * width / height + attrs.width = (attrs.height * width) / height const alignment = alignMap[verticalAlign] || 'text-bottom' @@ -59,9 +50,7 @@ Octicon.propTypes = { children: PropTypes.element, icon: PropTypes.func, size: PropTypes.oneOf(Object.keys(sizeMap)), - verticalAlign: PropTypes.oneOf([ - 'middle', 'text-bottom', 'text-top', 'top' - ]) + verticalAlign: PropTypes.oneOf(['middle', 'text-bottom', 'text-top', 'top']) } // this exports all of the icon classes as named exports, which can be From 6b9c1f9fa358a870a5cd836d5b0754ae3a62316a Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Wed, 27 Jun 2018 15:28:45 -0700 Subject: [PATCH 69/97] add lint script --- lib/octicons_react/package.json | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/octicons_react/package.json b/lib/octicons_react/package.json index 72302ce36..bd4c34dce 100644 --- a/lib/octicons_react/package.json +++ b/lib/octicons_react/package.json @@ -16,8 +16,9 @@ "node": ">=8" }, "scripts": { - "start": "next", "test": "jest", + "start": "next", + "lint": "eslint index.js script", "build": "script/build.js", "preversion": "npm run build -s", "publish": "../../script/notify success", From 0bec8ae7742c249f72d9e2e9dd0195320d2b91cc Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Wed, 27 Jun 2018 15:29:39 -0700 Subject: [PATCH 70/97] lint before testing --- lib/octicons_react/package.json | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/octicons_react/package.json b/lib/octicons_react/package.json index bd4c34dce..a8fafb35f 100644 --- a/lib/octicons_react/package.json +++ b/lib/octicons_react/package.json @@ -16,6 +16,7 @@ "node": ">=8" }, "scripts": { + "pretest": "npm run lint -s", "test": "jest", "start": "next", "lint": "eslint index.js script", From 970a58ce465bd58c2c1d320240819e596ef45e26 Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Wed, 27 Jun 2018 15:32:54 -0700 Subject: [PATCH 71/97] lint tests --- lib/octicons_react/__tests__/all.js | 9 +++----- lib/octicons_react/__tests__/octicon.js | 30 ++++++++++++++++++------- lib/octicons_react/package.json | 2 +- 3 files changed, 26 insertions(+), 15 deletions(-) diff --git a/lib/octicons_react/__tests__/all.js b/lib/octicons_react/__tests__/all.js index 79ae88818..75a234f23 100644 --- a/lib/octicons_react/__tests__/all.js +++ b/lib/octicons_react/__tests__/all.js @@ -1,17 +1,14 @@ -import React from 'react' import {Alert, Zap, getIconByName, iconsByName} from '../' import renderer from 'react-test-renderer' -const render = el => renderer.create(el).toJSON() - -describe("import {getIconByName}", () => { +describe('import {getIconByName}', () => { it('gets named icons', () => { const Icon = getIconByName('zap') - expect(render()).toEqual(render()) + expect(Icon).toEqual(Zap) }) }) -describe("import {iconsByName} from '...'", () => { +describe('import {iconsByName}', () => { it('gets all the icons', () => { expect(iconsByName.alert).toEqual(Alert) }) diff --git a/lib/octicons_react/__tests__/octicon.js b/lib/octicons_react/__tests__/octicon.js index 40e86617f..1e60bc5fc 100644 --- a/lib/octicons_react/__tests__/octicon.js +++ b/lib/octicons_react/__tests__/octicon.js @@ -5,46 +5,60 @@ import renderer from 'react-test-renderer' const render = el => renderer.create(el).toJSON() describe('', () => { - it('throws an error without a single child or icon prop', () => { expect(() => render()).toThrow() expect(() => render()).toThrow() }) it('outputs ', () => { - const rendered = render() + const rendered = render( + + + + ) expect(rendered.type).toEqual('svg') }) describe('with as child', () => { it('generates a default viewBox', () => { - const rendered = render() + const rendered = render( + + + + ) expect(rendered.props.viewBox).toEqual('0 0 16 16') }) it('generates default viewBox', () => { - const rendered = render() + const rendered = render( + + + + ) expect(rendered.props.viewBox).toEqual('0 0 16 16') }) }) function Icon() { - return + return } Icon.size = [12, 20] describe('with an child', () => { it('generates the right viewBox', () => { - const rendered = render() + const rendered = render( + + + + ) expect(rendered.props.viewBox).toEqual('0 0 12 20') }) }) describe('with an icon={Icon} prop', () => { it('generates the right viewBox', () => { - const rendered = render() + const rendered = render() expect(rendered.props.viewBox).toEqual('0 0 12 20') }) }) - }) diff --git a/lib/octicons_react/package.json b/lib/octicons_react/package.json index a8fafb35f..67c259a54 100644 --- a/lib/octicons_react/package.json +++ b/lib/octicons_react/package.json @@ -19,7 +19,7 @@ "pretest": "npm run lint -s", "test": "jest", "start": "next", - "lint": "eslint index.js script", + "lint": "eslint index.js __tests__ script", "build": "script/build.js", "preversion": "npm run build -s", "publish": "../../script/notify success", From b57bf2da8bf82123b2db9f367ee6d54ba7e43bd3 Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Wed, 27 Jun 2018 15:37:56 -0700 Subject: [PATCH 72/97] doh --- lib/octicons_react/__tests__/all.js | 1 - 1 file changed, 1 deletion(-) diff --git a/lib/octicons_react/__tests__/all.js b/lib/octicons_react/__tests__/all.js index 75a234f23..ff73947be 100644 --- a/lib/octicons_react/__tests__/all.js +++ b/lib/octicons_react/__tests__/all.js @@ -1,5 +1,4 @@ import {Alert, Zap, getIconByName, iconsByName} from '../' -import renderer from 'react-test-renderer' describe('import {getIconByName}', () => { it('gets named icons', () => { From f78cf2167d79af1663f2dfd1c3243e3b22c05fac Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Wed, 27 Jun 2018 16:18:04 -0700 Subject: [PATCH 73/97] add snapshot to Octicon test, hush console.error() --- .../__tests__/__snapshots__/octicon.js.snap | 20 +++++++++++++++++++ lib/octicons_react/__tests__/octicon.js | 2 ++ 2 files changed, 22 insertions(+) create mode 100644 lib/octicons_react/__tests__/__snapshots__/octicon.js.snap diff --git a/lib/octicons_react/__tests__/__snapshots__/octicon.js.snap b/lib/octicons_react/__tests__/__snapshots__/octicon.js.snap new file mode 100644 index 000000000..4a478f372 --- /dev/null +++ b/lib/octicons_react/__tests__/__snapshots__/octicon.js.snap @@ -0,0 +1,20 @@ +// Jest Snapshot v1, https://goo.gl/fbAQLP + +exports[` outputs 1`] = ` + + + +`; diff --git a/lib/octicons_react/__tests__/octicon.js b/lib/octicons_react/__tests__/octicon.js index 1e60bc5fc..eea2a8ddb 100644 --- a/lib/octicons_react/__tests__/octicon.js +++ b/lib/octicons_react/__tests__/octicon.js @@ -6,6 +6,7 @@ const render = el => renderer.create(el).toJSON() describe('', () => { it('throws an error without a single child or icon prop', () => { + jest.spyOn(console, 'error').mockImplementation(() => jest.fn()) expect(() => render()).toThrow() expect(() => render()).toThrow() }) @@ -16,6 +17,7 @@ describe('', () => { ) + expect(rendered).toMatchSnapshot() expect(rendered.type).toEqual('svg') }) From e494f3df45450bf11609d49df6cf651260a74e3d Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Wed, 27 Jun 2018 16:19:05 -0700 Subject: [PATCH 74/97] add aria-hidden="true", user-select: none --- lib/octicons_react/__tests__/__snapshots__/octicon.js.snap | 2 ++ lib/octicons_react/index.js | 2 ++ 2 files changed, 4 insertions(+) diff --git a/lib/octicons_react/__tests__/__snapshots__/octicon.js.snap b/lib/octicons_react/__tests__/__snapshots__/octicon.js.snap index 4a478f372..d5a78d73d 100644 --- a/lib/octicons_react/__tests__/__snapshots__/octicon.js.snap +++ b/lib/octicons_react/__tests__/__snapshots__/octicon.js.snap @@ -2,6 +2,7 @@ exports[` outputs 1`] = ` outputs 1`] = ` Object { "display": "inline-block", "fill": "currentColor", + "userSelect": "none", "verticalAlign": "text-bottom", } } diff --git a/lib/octicons_react/index.js b/lib/octicons_react/index.js index b955e2f52..4bbbdc1f3 100644 --- a/lib/octicons_react/index.js +++ b/lib/octicons_react/index.js @@ -21,6 +21,7 @@ export default function Octicon(props) { const [width, height] = child.type.size || defaultSize const attrs = { + ariaHidden: 'true', ariaLabel, className, height, @@ -39,6 +40,7 @@ export default function Octicon(props) { attrs.style = { display: 'inline-block', fill: 'currentColor', + userSelect: 'none', verticalAlign: alignment } From ea74679863afbed16a8298612e9ce925818bf006 Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Wed, 27 Jun 2018 17:40:12 -0700 Subject: [PATCH 75/97] try rollup? --- lib/octicons_react/package.json | 12 +++++++++--- lib/octicons_react/rollup.config.js | 18 ++++++++++++++++++ 2 files changed, 27 insertions(+), 3 deletions(-) create mode 100644 lib/octicons_react/rollup.config.js diff --git a/lib/octicons_react/package.json b/lib/octicons_react/package.json index 67c259a54..53867588a 100644 --- a/lib/octicons_react/package.json +++ b/lib/octicons_react/package.json @@ -5,9 +5,11 @@ "homepage": "https://octicons.github.com", "author": "GitHub, Inc.", "license": "MIT", - "main": "index.js", + "main": "build/index.js", + "module": "index.js", "repository": "primer/octicons", "files": [ + "build", "icons", "index.js", "pages" @@ -20,7 +22,8 @@ "test": "jest", "start": "next", "lint": "eslint index.js __tests__ script", - "build": "script/build.js", + "prebuild": "script/build.js", + "build": "rollup -c rollup.config.js", "preversion": "npm run build -s", "publish": "../../script/notify success", "prepublishOnly": "../../script/notify pending", @@ -49,7 +52,10 @@ "octicons": "7.2.0", "react": "^16.4.0", "react-dom": "^16.4.1", - "react-test-renderer": "^16.4.1" + "react-test-renderer": "^16.4.1", + "rollup": "^0.62.0", + "rollup-plugin-babel": "^3.0.5", + "rollup-plugin-commonjs": "^9.1.3" }, "peerDependencies": { "react": ">=15" diff --git a/lib/octicons_react/rollup.config.js b/lib/octicons_react/rollup.config.js new file mode 100644 index 000000000..1ac4b65ea --- /dev/null +++ b/lib/octicons_react/rollup.config.js @@ -0,0 +1,18 @@ +import babel from 'rollup-plugin-babel' +import commonjs from 'rollup-plugin-commonjs' + +export default { + input: 'index.js', + plugins: [ + babel({ + babelrc: false, + exclude: 'node_modules/**', + presets: [['env', {modules: false}], 'react'] + }), + commonjs() + ], + output: { + file: 'build/index.js', + format: 'esm' + } +} From 7115814c6627d5914a4b214ad8eb8ce5bf06ec85 Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Thu, 28 Jun 2018 09:35:53 -0700 Subject: [PATCH 76/97] update version to match --- lib/octicons_react/package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/octicons_react/package.json b/lib/octicons_react/package.json index 53867588a..009818b49 100644 --- a/lib/octicons_react/package.json +++ b/lib/octicons_react/package.json @@ -1,6 +1,6 @@ { "name": "@github/octicons-react", - "version": "0.1.0", + "version": "7.3.0", "description": "A scalable set of icons handcrafted with <3 by GitHub.", "homepage": "https://octicons.github.com", "author": "GitHub, Inc.", From 83517620fde553334a74df0aeb814b09526b9051 Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Thu, 28 Jun 2018 10:10:46 -0700 Subject: [PATCH 77/97] tidy up, improve Octicon tests --- lib/octicons_react/__tests__/octicon.js | 52 +++++++++++++------------ lib/octicons_react/index.js | 9 ++--- 2 files changed, 32 insertions(+), 29 deletions(-) diff --git a/lib/octicons_react/__tests__/octicon.js b/lib/octicons_react/__tests__/octicon.js index eea2a8ddb..9d2d53b3c 100644 --- a/lib/octicons_react/__tests__/octicon.js +++ b/lib/octicons_react/__tests__/octicon.js @@ -4,50 +4,56 @@ import renderer from 'react-test-renderer' const render = el => renderer.create(el).toJSON() +// set a default child; this is essentially a shallow render helper +const TestOcticon = ({children, ...props}) => { + return {children || } +} + describe('', () => { it('throws an error without a single child or icon prop', () => { + // console.error() is ugly af in jest; mock it with a noop jest.spyOn(console, 'error').mockImplementation(() => jest.fn()) expect(() => render()).toThrow() expect(() => render()).toThrow() }) it('outputs ', () => { - const rendered = render( - - - - ) + const rendered = render() expect(rendered).toMatchSnapshot() expect(rendered.type).toEqual('svg') }) + it('respects the className prop', () => { + expect(render().props.className).toEqual('foo') + }) + + it('respects the verticalAlign prop', () => { + expect(render().props.style.verticalAlign).toEqual('middle') + expect(render().props.style.verticalAlign).toEqual('text-bottom') + // FIXME: I have no idea why this fails! + // expect(render().props.style.verticalAlign).toEqual('text-top') + expect(render().props.style.verticalAlign).toEqual('text-top') + }) + describe('with as child', () => { it('generates a default viewBox', () => { - const rendered = render( - - - - ) + const rendered = render() expect(rendered.props.viewBox).toEqual('0 0 16 16') }) it('generates default viewBox', () => { - const rendered = render( - - - - ) + const rendered = render() expect(rendered.props.viewBox).toEqual('0 0 16 16') }) }) - function Icon() { - return - } - Icon.size = [12, 20] + describe('Icon type support', () => { + function Icon() { + return + } + Icon.size = [12, 20] - describe('with an child', () => { - it('generates the right viewBox', () => { + it('generates the right viewBox with an child', () => { const rendered = render( @@ -55,10 +61,8 @@ describe('', () => { ) expect(rendered.props.viewBox).toEqual('0 0 12 20') }) - }) - describe('with an icon={Icon} prop', () => { - it('generates the right viewBox', () => { + it('generates the right viewBox with icon={Icon}', () => { const rendered = render() expect(rendered.props.viewBox).toEqual('0 0 12 20') }) diff --git a/lib/octicons_react/index.js b/lib/octicons_react/index.js index 4bbbdc1f3..7d7c62994 100644 --- a/lib/octicons_react/index.js +++ b/lib/octicons_react/index.js @@ -21,8 +21,8 @@ export default function Octicon(props) { const [width, height] = child.type.size || defaultSize const attrs = { - ariaHidden: 'true', - ariaLabel, + 'aria-hidden': 'true', + 'aria-label': ariaLabel, className, height, role: 'img', @@ -35,13 +35,11 @@ export default function Octicon(props) { attrs.width = (attrs.height * width) / height - const alignment = alignMap[verticalAlign] || 'text-bottom' - attrs.style = { display: 'inline-block', fill: 'currentColor', userSelect: 'none', - verticalAlign: alignment + verticalAlign: alignMap[verticalAlign] || verticalAlign } return {child} @@ -51,6 +49,7 @@ Octicon.propTypes = { ariaLabel: PropTypes.string, children: PropTypes.element, icon: PropTypes.func, + // TODO: support size as a number size: PropTypes.oneOf(Object.keys(sizeMap)), verticalAlign: PropTypes.oneOf(['middle', 'text-bottom', 'text-top', 'top']) } From 02a007a6394cfa8bfed0b5b85f51c4ba684f4bd5 Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Thu, 28 Jun 2018 10:11:03 -0700 Subject: [PATCH 78/97] don't set 'module' in package.json --- lib/octicons_react/package.json | 1 - 1 file changed, 1 deletion(-) diff --git a/lib/octicons_react/package.json b/lib/octicons_react/package.json index 009818b49..ec6e220e4 100644 --- a/lib/octicons_react/package.json +++ b/lib/octicons_react/package.json @@ -6,7 +6,6 @@ "author": "GitHub, Inc.", "license": "MIT", "main": "build/index.js", - "module": "index.js", "repository": "primer/octicons", "files": [ "build", From 4fce348a755224f5e24d7f32203f8eb82d37a263 Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Thu, 28 Jun 2018 10:36:34 -0700 Subject: [PATCH 79/97] do sizing right, moar tests --- .../__tests__/__snapshots__/octicon.js.snap | 2 +- lib/octicons_react/__tests__/octicon.js | 61 ++++++++++++++++++- lib/octicons_react/index.js | 32 +++++++--- 3 files changed, 83 insertions(+), 12 deletions(-) diff --git a/lib/octicons_react/__tests__/__snapshots__/octicon.js.snap b/lib/octicons_react/__tests__/__snapshots__/octicon.js.snap index d5a78d73d..d2f4ec7d8 100644 --- a/lib/octicons_react/__tests__/__snapshots__/octicon.js.snap +++ b/lib/octicons_react/__tests__/__snapshots__/octicon.js.snap @@ -2,7 +2,7 @@ exports[` outputs 1`] = `
    Node.js package with Javascript API | [![npm version](https://img.shields.io/npm/v/octicons.svg)](https://www.npmjs.org/package/octicons) | -| **[@github/octicons-react](/lib/octicons_react)**
    React.js octicons components | [![npm version](https://img.shields.io/npm/v/%40github%2Focticons-react.svg)](https://www.npmjs.org/package/%40github%2Focticons-react) | +| **[@github/octicons-react](/lib/octicons_react)**
    React octicons components | [![npm version](https://img.shields.io/npm/v/%40github%2Focticons-react.svg)](https://www.npmjs.org/package/%40github%2Focticons-react) | ### Ruby From d80832b656989b2ea2d7aaca0220f97f7f34df57 Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Fri, 29 Jun 2018 09:49:55 -0700 Subject: [PATCH 86/97] add stage-0, rename next env to "production" --- lib/octicons_react/.babelrc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/octicons_react/.babelrc b/lib/octicons_react/.babelrc index a0b632b1a..1224b59fc 100644 --- a/lib/octicons_react/.babelrc +++ b/lib/octicons_react/.babelrc @@ -1,7 +1,7 @@ { - "presets": ["env", "react"], + "presets": ["env", "stage-0", "react"], "env": { - "development": { + "production": { "presets": ["next/babel"] } } From d23a00cd3241375f8360203d06f0ac9bd5145e99 Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Fri, 29 Jun 2018 09:51:04 -0700 Subject: [PATCH 87/97] use .npmignore instead of files; downgrade next, install stage-0 --- lib/octicons_react/.npmignore | 10 ++++++++++ lib/octicons_react/package.json | 17 ++++++----------- 2 files changed, 16 insertions(+), 11 deletions(-) create mode 100644 lib/octicons_react/.npmignore diff --git a/lib/octicons_react/.npmignore b/lib/octicons_react/.npmignore new file mode 100644 index 000000000..c87675509 --- /dev/null +++ b/lib/octicons_react/.npmignore @@ -0,0 +1,10 @@ +*.config.js +.*.sw? +.*rc +.cache +.eslint* +.gitignore +.next +pages +script +src diff --git a/lib/octicons_react/package.json b/lib/octicons_react/package.json index e4d169aaa..ef269e0dd 100644 --- a/lib/octicons_react/package.json +++ b/lib/octicons_react/package.json @@ -7,19 +7,10 @@ "license": "MIT", "main": "build/index.js", "repository": "primer/octicons", - "files": [ - "build", - "icons", - "index.js", - "pages" - ], - "engines": { - "node": ">=8" - }, "scripts": { "pretest": "npm run lint -s", "test": "jest", - "start": "next", + "start": "NODE_ENV=production next", "lint": "eslint src script", "prebuild": "script/build.js", "build": "rollup -c rollup.config.js", @@ -42,12 +33,13 @@ "devDependencies": { "babel-preset-env": "^1.7.0", "babel-preset-react": "^6.24.1", + "babel-preset-stage-0": "^6.24.1", "eslint": "^5.0.1", "eslint-plugin-github": "^1.1.0", "eslint-plugin-jest": "^21.17.0", "fs-extra": "^6.0.1", "jest": "^23.2.0", - "next": "^6.0.3", + "next": "^5.1.0", "octicons": "7.2.0", "react": "^16.4.0", "react-dom": "^16.4.1", @@ -58,5 +50,8 @@ }, "peerDependencies": { "react": ">=15" + }, + "engines": { + "node": ">=8" } } From 9d8aca00f364aef4f8b291868d3784ddfad83729 Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Fri, 29 Jun 2018 09:52:28 -0700 Subject: [PATCH 88/97] refactor rollup config, output ESM + UMD --- lib/octicons_react/package.json | 11 +++++++---- lib/octicons_react/rollup.config.js | 25 ++++++++++++++++--------- 2 files changed, 23 insertions(+), 13 deletions(-) diff --git a/lib/octicons_react/package.json b/lib/octicons_react/package.json index ef269e0dd..065236929 100644 --- a/lib/octicons_react/package.json +++ b/lib/octicons_react/package.json @@ -5,7 +5,8 @@ "homepage": "https://octicons.github.com", "author": "GitHub, Inc.", "license": "MIT", - "main": "build/index.js", + "main": "dist/index.umd.js", + "module": "dist/index.esm.js", "repository": "primer/octicons", "scripts": { "pretest": "npm run lint -s", @@ -13,11 +14,12 @@ "start": "NODE_ENV=production next", "lint": "eslint src script", "prebuild": "script/build.js", - "build": "rollup -c rollup.config.js", - "preversion": "npm run build -s", + "build": "npm -s run build", + "preversion": "npm -s run build", "publish": "../../script/notify success", "prepublishOnly": "../../script/notify pending", - "prepare": "npm run build -s" + "prepare": "npm -s run build", + "rollup": "rollup -c" }, "keywords": [ "GitHub", @@ -32,6 +34,7 @@ }, "devDependencies": { "babel-preset-env": "^1.7.0", + "babel-preset-es2015": "^6.24.1", "babel-preset-react": "^6.24.1", "babel-preset-stage-0": "^6.24.1", "eslint": "^5.0.1", diff --git a/lib/octicons_react/rollup.config.js b/lib/octicons_react/rollup.config.js index 4d2980068..9f3305397 100644 --- a/lib/octicons_react/rollup.config.js +++ b/lib/octicons_react/rollup.config.js @@ -1,18 +1,25 @@ import babel from 'rollup-plugin-babel' import commonjs from 'rollup-plugin-commonjs' +import {readFileSync} from 'fs' +import {name} from './package.json' + +const formats = ['esm', 'umd'] // 'cjs' ? + +const presets = [ + ['es2015', {modules: false}], + 'stage-0', + 'react' +] export default { input: 'src/index.js', plugins: [ - babel({ - babelrc: false, - exclude: 'node_modules/**', - presets: [['env', {modules: false}], 'react'] - }), + babel({babelrc: false, presets}), commonjs() ], - output: { - file: 'build/index.js', - format: 'esm' - } + output: formats.map(format => ({ + file: `dist/index.${format}.js`, + format, + name: 'reocticons' + })) } From ebbe36b61a0dbac37952ea053a07568da3c6f524 Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Fri, 29 Jun 2018 09:52:43 -0700 Subject: [PATCH 89/97] ignore dist/ --- lib/octicons_react/.gitignore | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/octicons_react/.gitignore b/lib/octicons_react/.gitignore index 18acff14b..1c24e517f 100644 --- a/lib/octicons_react/.gitignore +++ b/lib/octicons_react/.gitignore @@ -1,2 +1,3 @@ .cache .next +dist/ From 8269535422bc1a25a3152fa23feafc40c698fea5 Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Fri, 29 Jun 2018 09:53:35 -0700 Subject: [PATCH 90/97] show all the octicons! --- lib/octicons_react/pages/index.js | 60 +++++++++++++++---------------- 1 file changed, 28 insertions(+), 32 deletions(-) diff --git a/lib/octicons_react/pages/index.js b/lib/octicons_react/pages/index.js index 688103f5c..dfeb38aa6 100644 --- a/lib/octicons_react/pages/index.js +++ b/lib/octicons_react/pages/index.js @@ -1,47 +1,43 @@ import React from 'react' -import Octicon, {Alert, X, Zap} from '../' -import getIcon from '../icons/all' +import Octicon, {iconsByName} from '../' export default function App() { + const sizes = ['small', 'medium', 'large'] return (
    - - - - - - - + + + + - {[[Alert, 'alert'], [X, 'x'], [Zap, 'zap']].map(([Icon, key], i) => ( - - - - - - - - - - ))} + {Object.keys(iconsByName).map(key => { + const Icon = iconsByName[key] + return ( + + + + + + + ) + })}
    Name{'icon={Icon}'}{''}{"getIcon('name')"}mediumlargeno {''}keyimportsmall, medium, largecode sample
    {Icon.name} - - - - - - - - - - - -
    {key}{Icon.name} + {sizes.map(size => ( + + + + ))} + +
    {`
    +import Octicon, {${Icon.name}} from '@github/octicons-react'
    +export default () => 
    +                  `.trim()}
    +
    From db11ac745c6b22d8634f994d3493cf791d3f26fc Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Fri, 29 Jun 2018 09:57:04 -0700 Subject: [PATCH 91/97] tidy up rollup config, use env preset --- lib/octicons_react/rollup.config.js | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/lib/octicons_react/rollup.config.js b/lib/octicons_react/rollup.config.js index 9f3305397..7f3afea4c 100644 --- a/lib/octicons_react/rollup.config.js +++ b/lib/octicons_react/rollup.config.js @@ -1,12 +1,10 @@ import babel from 'rollup-plugin-babel' import commonjs from 'rollup-plugin-commonjs' -import {readFileSync} from 'fs' -import {name} from './package.json' const formats = ['esm', 'umd'] // 'cjs' ? const presets = [ - ['es2015', {modules: false}], + ['env', {modules: false}], 'stage-0', 'react' ] From 7c9d61d57bf6c39e77ce7ec5d729a92703635b86 Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Fri, 29 Jun 2018 09:57:22 -0700 Subject: [PATCH 92/97] nix es2015 preset (always use env!) --- lib/octicons_react/package.json | 1 - 1 file changed, 1 deletion(-) diff --git a/lib/octicons_react/package.json b/lib/octicons_react/package.json index 065236929..297a8132e 100644 --- a/lib/octicons_react/package.json +++ b/lib/octicons_react/package.json @@ -34,7 +34,6 @@ }, "devDependencies": { "babel-preset-env": "^1.7.0", - "babel-preset-es2015": "^6.24.1", "babel-preset-react": "^6.24.1", "babel-preset-stage-0": "^6.24.1", "eslint": "^5.0.1", From b8f4a034e9687c49d0193c0f794478ef1d906e4b Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Fri, 29 Jun 2018 10:11:34 -0700 Subject: [PATCH 93/97] oops --- lib/octicons_react/package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/octicons_react/package.json b/lib/octicons_react/package.json index 297a8132e..07ce1439f 100644 --- a/lib/octicons_react/package.json +++ b/lib/octicons_react/package.json @@ -14,7 +14,7 @@ "start": "NODE_ENV=production next", "lint": "eslint src script", "prebuild": "script/build.js", - "build": "npm -s run build", + "build": "npm -s run rollup", "preversion": "npm -s run build", "publish": "../../script/notify success", "prepublishOnly": "../../script/notify pending", From 34a532edb083ed7e5517fb9eac58e820e2632bbc Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Fri, 29 Jun 2018 10:11:42 -0700 Subject: [PATCH 94/97] simplify rollup config --- lib/octicons_react/rollup.config.js | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/lib/octicons_react/rollup.config.js b/lib/octicons_react/rollup.config.js index 7f3afea4c..342b58c29 100644 --- a/lib/octicons_react/rollup.config.js +++ b/lib/octicons_react/rollup.config.js @@ -3,16 +3,17 @@ import commonjs from 'rollup-plugin-commonjs' const formats = ['esm', 'umd'] // 'cjs' ? -const presets = [ - ['env', {modules: false}], - 'stage-0', - 'react' -] - export default { input: 'src/index.js', plugins: [ - babel({babelrc: false, presets}), + babel({ + babelrc: false, + presets: [ + ['env', {modules: false}], + 'stage-0', + 'react' + ] + }), commonjs() ], output: formats.map(format => ({ From b0144126c64754a2e00b07b7e9dcdfda789d6278 Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Fri, 29 Jun 2018 10:14:11 -0700 Subject: [PATCH 95/97] nix prepare run-script --- lib/octicons_react/package.json | 1 - 1 file changed, 1 deletion(-) diff --git a/lib/octicons_react/package.json b/lib/octicons_react/package.json index 07ce1439f..7bb5bc770 100644 --- a/lib/octicons_react/package.json +++ b/lib/octicons_react/package.json @@ -18,7 +18,6 @@ "preversion": "npm -s run build", "publish": "../../script/notify success", "prepublishOnly": "../../script/notify pending", - "prepare": "npm -s run build", "rollup": "rollup -c" }, "keywords": [ From a008e251c6874b37473897440aafccb99321b23d Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Fri, 29 Jun 2018 11:14:22 -0700 Subject: [PATCH 96/97] use some primer components --- lib/octicons_react/package.json | 1 + lib/octicons_react/pages/index.js | 13 +++++++------ 2 files changed, 8 insertions(+), 6 deletions(-) diff --git a/lib/octicons_react/package.json b/lib/octicons_react/package.json index 7bb5bc770..557e389d6 100644 --- a/lib/octicons_react/package.json +++ b/lib/octicons_react/package.json @@ -42,6 +42,7 @@ "jest": "^23.2.0", "next": "^5.1.0", "octicons": "7.2.0", + "primer-react": "0.0.6-alpha.1", "react": "^16.4.0", "react-dom": "^16.4.1", "react-test-renderer": "^16.4.1", diff --git a/lib/octicons_react/pages/index.js b/lib/octicons_react/pages/index.js index dfeb38aa6..7eb919ad6 100644 --- a/lib/octicons_react/pages/index.js +++ b/lib/octicons_react/pages/index.js @@ -1,11 +1,12 @@ import React from 'react' import Octicon, {iconsByName} from '../' +import {Block, Box, Text} from 'primer-react' export default function App() { const sizes = ['small', 'medium', 'large'] return ( -
    + @@ -20,13 +21,13 @@ export default function App() { const Icon = iconsByName[key] return ( - - + +
    {key}{Icon.name}{key}{Icon.name} {sizes.map(size => ( - + - + ))} @@ -40,6 +41,6 @@ export default () => })}
    -
    + ) } From b61e03c0ff17843adfe0a1defb5333f32b5693e4 Mon Sep 17 00:00:00 2001 From: Shawn Allen Date: Fri, 29 Jun 2018 11:14:55 -0700 Subject: [PATCH 97/97] clean up build run-script logic, remove pages/ from .npmignore --- lib/octicons_react/.npmignore | 1 - lib/octicons_react/package.json | 7 +++---- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/lib/octicons_react/.npmignore b/lib/octicons_react/.npmignore index c87675509..be73bc345 100644 --- a/lib/octicons_react/.npmignore +++ b/lib/octicons_react/.npmignore @@ -5,6 +5,5 @@ .eslint* .gitignore .next -pages script src diff --git a/lib/octicons_react/package.json b/lib/octicons_react/package.json index 557e389d6..1147c64b9 100644 --- a/lib/octicons_react/package.json +++ b/lib/octicons_react/package.json @@ -13,11 +13,10 @@ "test": "jest", "start": "NODE_ENV=production next", "lint": "eslint src script", - "prebuild": "script/build.js", - "build": "npm -s run rollup", - "preversion": "npm -s run build", - "publish": "../../script/notify success", + "prepare": "script/build.js && npm -s run rollup", "prepublishOnly": "../../script/notify pending", + "preversion": "npm -s run prepare", + "publish": "../../script/notify success", "rollup": "rollup -c" }, "keywords": [