Skip to content

Commit 9d59c02

Browse files
committed
Initial commit
0 parents  commit 9d59c02

11 files changed

+8271
-0
lines changed

.github/workflows/publish.yml

+41
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
name: Publish Package
2+
3+
on:
4+
create:
5+
tags:
6+
- v*
7+
8+
jobs:
9+
publish-npm:
10+
runs-on: ubuntu-latest
11+
steps:
12+
- uses: actions/checkout@v2
13+
with:
14+
persist-credentials: false
15+
fetch-depth: 0
16+
submodules: recursive
17+
- uses: actions/setup-node@v2
18+
with:
19+
node-version: 14.x
20+
registry-url: https://registry.npmjs.org
21+
always-auth: true
22+
- run: npm ci
23+
- run: npm version "${GITHUB_REF:11}" --no-git-tag-version
24+
- run: npm publish --access public
25+
env:
26+
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
27+
28+
- name: Commit files
29+
run: |
30+
git config --local user.email "projektas@gmail.com"
31+
git config --local user.name "FDiskas"
32+
git commit -m "Release: ${GITHUB_REF:11}" -a
33+
- name: Push changes
34+
uses: ad-m/github-push-action@master
35+
with:
36+
github_token: ${{ secrets.GITHUB_TOKEN }}
37+
branch: master
38+
39+
- uses: akhilmhdh/contributors-readme-action@v2.1.2
40+
env:
41+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

.gitignore

+6
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
node_modules/
2+
typings/
3+
*.log
4+
.DS_Store
5+
lib/
6+
src/icons/

.npmignore

+6
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
feather/
2+
api-extractor.json
3+
tsconfig.json
4+
.svgrrc.js
5+
.gitmodules
6+
src/

.svgo.yml

+26
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
plugins:
2+
- removeXMLNS: true
3+
- removeViewBox: false
4+
- removeDimensions: true # this deletes width/height and adds it to the viewBox
5+
- removeDoctype: true
6+
- removeComments: true
7+
- removeMetadata: true
8+
- removeEditorsNSData: true
9+
- cleanupIDs: true
10+
- removeRasterImages: true
11+
- removeUselessDefs: true
12+
- removeUnknownsAndDefaults: true
13+
- removeUselessStrokeAndFill: true
14+
- removeHiddenElems: true
15+
- removeEmptyText: true
16+
- removeEmptyAttrs: true
17+
- removeEmptyContainers: true
18+
- removeUnusedNS: true
19+
- removeDesc: true
20+
- prefixIds: false
21+
- prefixClassNames: false
22+
- convertStyleToAttrs: true
23+
- removeAttrs:
24+
attrs:
25+
- "class"
26+
- "style"

.svgrrc.js

+16
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
module.exports = {
2+
jsx: {
3+
babelConfig: {
4+
plugins: [
5+
[
6+
"@svgr/babel-plugin-replace-jsx-attribute-value",
7+
{
8+
"values": [
9+
{ "value": "1em", "newValue": 24 },
10+
]
11+
}
12+
]
13+
],
14+
},
15+
},
16+
}

README.md

+73
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,73 @@
1+
## React Native Unicons Icons
2+
3+
[![npm version](https://img.shields.io/npm/v/react-native-unicons.svg?style=flat-square)](https://www.npmjs.com/package/react-native-unicons)
4+
[![npm downloads](https://img.shields.io/npm/dm/react-native-unicons.svg?style=flat-square)](https://www.npmjs.com/package/react-native-unicons)
5+
6+
#### What is react-native-unicons?
7+
8+
react-native-unicons is a collection of simply beautiful open source icons for React Native. Each icon is designed on a 24x24 grid with an emphasis on simplicity, consistency and readability.
9+
10+
At its core, Unicons is a collection of SVG files. To use SVG files on React Native, [`react-native-svg`](https://github.com/react-native-community/react-native-svg) is needed. This component contains "line" style Unicons icons converted and made compatible with [`react-native-svg`](https://github.com/react-native-community/react-native-svg) package.
11+
12+
#### Based on Unicons Icons `v4.0.0`
13+
14+
## Installation
15+
16+
1. Ensure sure you've installed [`react-native-svg`](https://github.com/react-native-community/react-native-svg)
17+
2. `npm i react-native-unicons`
18+
19+
### Icons
20+
21+
List of available icons in this component.
22+
[https://iconscout.com](https://iconscout.com/unicons/explore/line)
23+
24+
### Usage
25+
26+
To use icons as component, all icon names is formatted to Pascal Case.
27+
award-alt => `<AwardAlt />`
28+
29+
```javascript
30+
import { AwardAlt } from "react-native-unicons";
31+
32+
const App = () => {
33+
return <AwardAlt />;
34+
};
35+
```
36+
37+
Icons can be configured with inline props:
38+
39+
```javascript
40+
<AwardAlt stroke="red" fill="#fff" width={32} height={32} />
41+
```
42+
43+
You can also include the whole icon pack:
44+
45+
```javascript
46+
import * as Icon from "react-native-unicons";
47+
48+
const App = () => {
49+
return <Icon.AwardAlt />;
50+
};
51+
```
52+
53+
### Properties
54+
55+
Any [Svg property](https://github.com/react-native-community/react-native-svg#common-props) and the following:
56+
57+
| Prop | Description | Default |
58+
| ----------------- | -------------------------------------------------------------------- | ---------------- |
59+
| **`width`** | Width of the icon. | `24` |
60+
| **`height`** | Height of the icon. | `24` |
61+
| **`stroke`** | The stroke prop refers to the color outline the icon. | `"currentColor"` |
62+
| **`strokeWidth`** | The strokeWidth prop specifies the width of the outline on the icon. | `2` |
63+
| **`fill`** | The fill prop refers to the color inside the icon. | `"none"` |
64+
65+
### Author
66+
67+
<!-- readme: FDiskas -start -->
68+
<!-- readme: yigithanyucedag -end -->
69+
70+
## Contributors
71+
72+
<!-- readme: contributors -start -->
73+
<!-- readme: contributors -end -->

0 commit comments

Comments
 (0)