Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unicons revamp #7

Open
wants to merge 182 commits into
base: reskin
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
182 commits
Select commit Hold shift + click to select a range
47e2501
add: storybook N stories
booi-dev Jan 4, 2024
14927ff
add: svgs from main app
booi-dev Jan 5, 2024
74cca3b
add: pretty-quick n lint-staged
booi-dev Jan 5, 2024
745fe38
update: restructure folders
booi-dev Jan 6, 2024
cd03555
update: component
booi-dev Jan 6, 2024
84a7972
add: chevron icons
booi-dev Jan 6, 2024
8708125
add: clock icon
booi-dev Jan 6, 2024
b62ca11
add: arrow fill icon
booi-dev Jan 6, 2024
500b15b
add: alert icon
booi-dev Jan 6, 2024
5a44c19
add: clear icon
booi-dev Jan 8, 2024
706ff0d
add: contact support icon
booi-dev Jan 8, 2024
ee7c2d2
add: expand icon
booi-dev Jan 8, 2024
4574221
add: info icon
booi-dev Jan 8, 2024
b7ea37e
add: processing icon
booi-dev Jan 8, 2024
2bec509
update: make 24 defaul size
booi-dev Jan 8, 2024
c49e9ec
add: chevron variants
booi-dev Jan 8, 2024
1f4950f
add: arrow up down variant
booi-dev Jan 8, 2024
36764a1
add: base icon component
booi-dev Jan 8, 2024
b631bbd
update: base icon component
booi-dev Jan 8, 2024
51ecc30
add: border icon
booi-dev Jan 8, 2024
5935006
add: cart icon
booi-dev Jan 8, 2024
64f1137
add: shell script to generate story
booi-dev Jan 8, 2024
63d92e8
add: desc alpha and num icon
booi-dev Jan 8, 2024
dc536e2
add: diamond icon
booi-dev Jan 8, 2024
fe72130
add: error icon
booi-dev Jan 8, 2024
14dd3b4
add: exit icon
booi-dev Jan 8, 2024
9b748aa
add: export icon
booi-dev Jan 8, 2024
0ab6c05
add: eye checked icon
booi-dev Jan 8, 2024
ca85e09
add: special eye icon
booi-dev Jan 8, 2024
71b4d15
update: move alert icon to special folder
booi-dev Jan 9, 2024
0a7f989
add: folder icon
booi-dev Jan 9, 2024
264b760
add: grid icon
booi-dev Jan 9, 2024
1f5165c
add: color icon
booi-dev Jan 9, 2024
fc02841
add: loupe icon
booi-dev Jan 9, 2024
c13ff11
add: inactive icons
booi-dev Jan 9, 2024
f093ce9
add: sort icon
booi-dev Jan 9, 2024
cbccce5
add: spray icon
booi-dev Jan 9, 2024
d04c890
add: staricon secondary icon
booi-dev Jan 9, 2024
50feea4
add: add info icon variant
booi-dev Jan 9, 2024
562943a
add: arrow left right icons
booi-dev Jan 9, 2024
b95f4f4
add: selected list icon
booi-dev Jan 9, 2024
8dffc40
add: loop icon
booi-dev Jan 9, 2024
693fa62
add: network error icon
booi-dev Jan 9, 2024
1da629f
add: reload icon
booi-dev Jan 9, 2024
c611a2e
add: warning icon
booi-dev Jan 9, 2024
9db4e5c
add: zoom icon
booi-dev Jan 9, 2024
94842c8
update: move reskin icons to icons
booi-dev Jan 9, 2024
5a99164
add: move icon with bg to seperate folder
booi-dev Jan 9, 2024
f130229
add: icon accessibility
booi-dev Jan 9, 2024
300b7b6
add: shell scripts
booi-dev Jan 10, 2024
8f893f7
add: celebrate icon
booi-dev Jan 11, 2024
d403a44
update: change ref type to span
booi-dev Jan 11, 2024
b28d09b
add: coupon icon
booi-dev Jan 11, 2024
3e83cb2
add: crown icons
booi-dev Jan 11, 2024
67fc649
add: happy face
booi-dev Jan 11, 2024
eb3c563
add: open link icon
booi-dev Jan 11, 2024
4200341
add: stack 2 icon
booi-dev Jan 11, 2024
76dc028
add: inactive for more icon
booi-dev Jan 12, 2024
22a2d82
add: power icons
booi-dev Jan 12, 2024
dcbe568
add: more icons
booi-dev Jan 12, 2024
c3dbe9a
add: drag capture one
booi-dev Jan 12, 2024
778d6f5
update: folder name
booi-dev Jan 12, 2024
06e6720
add: add facebook icon
booi-dev Jan 12, 2024
4e29e2d
add: five star icons
booi-dev Jan 12, 2024
1e067b4
add: grid icons
booi-dev Jan 12, 2024
27b3de1
add: image border icon
booi-dev Jan 12, 2024
44af25c
add: face happy icon
booi-dev Jan 13, 2024
76ff469
add: LessGroupingIcon
booi-dev Jan 15, 2024
6a6e6f7
add: lightroom icon
booi-dev Jan 15, 2024
2a90c02
add: loop circle icon
booi-dev Jan 15, 2024
d5dfaac
add: more grouping icon
booi-dev Jan 15, 2024
228539b
add: question mark
booi-dev Jan 15, 2024
9f1b2ea
add: alert icons
booi-dev Jan 16, 2024
854dcdc
add: alert circle
booi-dev Jan 16, 2024
f9af95d
sort icons
booi-dev Jan 16, 2024
c9a29ef
add: spray icon
booi-dev Jan 16, 2024
e5a4abc
twiiter icons
booi-dev Jan 16, 2024
973a5e1
facebook
booi-dev Jan 16, 2024
98047f9
add: alert circle fill
booi-dev Jan 16, 2024
698fd00
add: aftershoot
booi-dev Jan 17, 2024
3bb6a15
add: collection icon
booi-dev Jan 18, 2024
1716e1c
add: confetti icons
booi-dev Jan 19, 2024
497cb82
add: delete
booi-dev Jan 19, 2024
0128423
update: cheveron icons
booi-dev Jan 19, 2024
9bd67de
update: move star icon to generic
booi-dev Jan 19, 2024
e03e181
add: export circle bg icon
booi-dev Jan 19, 2024
01b5488
update: global icons
booi-dev Jan 19, 2024
b8874c2
add: wifi icons
booi-dev Jan 19, 2024
2bea80d
update: check icons
booi-dev Jan 19, 2024
fa27e85
add: checkbox icons
booi-dev Jan 19, 2024
3f4e34e
add: play icons
booi-dev Jan 19, 2024
614838a
add: rotate icon
booi-dev Jan 19, 2024
a04172e
add: success fill bg icon
booi-dev Jan 20, 2024
7c1b62f
add: train icon
booi-dev Jan 20, 2024
35d02ba
add: twitter outline icon
booi-dev Jan 20, 2024
15f671e
add: upload icon
booi-dev Jan 20, 2024
17b71fd
add: alert triangle icon
booi-dev Jan 20, 2024
c13dfcd
refactor
booi-dev Jan 20, 2024
7e56582
refactoring
booi-dev Jan 20, 2024
54e7968
add: move files
booi-dev Jan 20, 2024
5349980
update: edit stories
booi-dev Jan 20, 2024
ae62152
add: clear bg folder
booi-dev Jan 20, 2024
2988ef5
update: add inactive to icons
booi-dev Jan 20, 2024
d3c4f27
add: grouping icons
booi-dev Jan 21, 2024
1601313
add: add inactive to all icons
booi-dev Jan 21, 2024
d32cac2
add: update: mood icon
booi-dev Jan 21, 2024
9e4aeb1
add: extract icons from app
booi-dev Jan 22, 2024
b21a619
update: culling icons
booi-dev Jan 22, 2024
9f1c395
update: general icons
booi-dev Jan 22, 2024
8767f59
update: edit icons
booi-dev Jan 22, 2024
5bc0508
update: logo
booi-dev Jan 22, 2024
e2cf27d
add: update enable icons
booi-dev Jan 22, 2024
92d8840
update: packages
booi-dev Jan 22, 2024
c47760c
update: culling icons
booi-dev Jan 23, 2024
c45a695
update: edit icons
booi-dev Jan 23, 2024
6526ad8
update: enable icons
booi-dev Jan 23, 2024
8c43e1f
add: update general icons
booi-dev Jan 23, 2024
4f7c127
update: logo icons
booi-dev Jan 23, 2024
4b37ae5
update: social icons
booi-dev Jan 23, 2024
6e45529
update: power icons
booi-dev Jan 23, 2024
b926e29
update: move all stories to one folder
booi-dev Jan 24, 2024
248cd21
update: icon
booi-dev Feb 2, 2024
903cd19
update: icons
booi-dev Feb 5, 2024
2236403
update: shell script
booi-dev Feb 7, 2024
429678f
add: arrow up icon
booi-dev Feb 7, 2024
5ec1e50
add: copy content icon
booi-dev Feb 7, 2024
da930d5
update: gc.sh
booi-dev Feb 7, 2024
bf68119
modify: read me
booi-dev Feb 7, 2024
56a6eae
add: culling icons
booi-dev Feb 8, 2024
953f7c9
update: survey mode icon
booi-dev Feb 8, 2024
bc8c28e
add: grid icon
booi-dev Feb 9, 2024
d1f0aae
update: show dublicate icon
booi-dev Feb 9, 2024
8c27d5a
update: list icons
booi-dev Feb 9, 2024
098075c
update: face icon - smiley
booi-dev Feb 13, 2024
3e8e91a
remove: unused svg
booi-dev Mar 6, 2024
47b6032
update chevron down icon
booi-dev Mar 19, 2024
50406a8
add: sort optios icons
booi-dev Mar 20, 2024
ea2a853
alter: add storybook live to readme
booi-dev Mar 20, 2024
d41119d
update: rename mouse left and right selected icon to click icon
booi-dev Mar 20, 2024
6a5394f
fix: UploadFolderIcon incorrect prop type
booi-dev Apr 24, 2024
7f740eb
fix: CheckBox icon type error
booi-dev Apr 24, 2024
f4350ed
fix: add inActive to all component
booi-dev Apr 24, 2024
34aa36a
add: inActive type to all component
booi-dev Apr 24, 2024
ce59b8b
update: computerIcon name
booi-dev Apr 26, 2024
d760157
update: shell script to generate components
booi-dev May 2, 2024
7636376
update: exporting
booi-dev May 2, 2024
800ca53
add: create script to export icons
booi-dev May 2, 2024
c88180f
update: improve logs for generate script
booi-dev May 2, 2024
deff9ae
udate: readme
booi-dev May 2, 2024
b0de0b2
update: add export to all component
booi-dev May 2, 2024
0908468
fix: dublicate errors
booi-dev May 2, 2024
822ad65
update: readme discription
booi-dev May 2, 2024
44c198e
pubish storybook
booi-dev May 3, 2024
5f11404
update: readme
booi-dev May 3, 2024
76c56b7
update: remove defaul export
booi-dev May 7, 2024
2cbbf53
add: bulb icon
booi-dev May 7, 2024
e74e93e
update: sort buld icon
booi-dev May 7, 2024
e25b730
add: catalog upload icons
booi-dev May 7, 2024
a320d20
move: new icons to its respected folder
booi-dev May 7, 2024
da8b567
add: image icon
booi-dev May 7, 2024
667681b
add: cart icon third variant
booi-dev May 8, 2024
fbc550a
fix: copy icon secondary width empty space
booi-dev May 8, 2024
de29cb1
add: x icon
booi-dev May 8, 2024
4dc8fea
add: whatsapp icon
booi-dev May 8, 2024
91986a2
update: readme
booi-dev May 8, 2024
e6ce356
add: bg opacity for crown bg
booi-dev May 8, 2024
ad0ff81
add: create trophy color icon
booi-dev May 8, 2024
e9dcc41
add: create arrow curve icon
booi-dev May 8, 2024
dcce87c
add: drawer icon
booi-dev May 8, 2024
251c920
add: create mail bg icon component
booi-dev May 8, 2024
2781f96
remove: export icon, update upload icon
booi-dev May 9, 2024
981096a
add: create export icon
booi-dev May 9, 2024
dea0dfd
update: checkicon
booi-dev May 9, 2024
ad50081
add: create pause bg icon
booi-dev May 10, 2024
c4af5c9
update: person icon to person two icon
booi-dev May 10, 2024
e700e19
update: stack icon proper names
booi-dev May 10, 2024
3aac969
update: facebook and twitter icon
booi-dev May 11, 2024
f40af0c
update: icons
booi-dev May 11, 2024
aa7707b
add: create drag bridge icon
booi-dev May 11, 2024
17dc33a
add: drag icons
booi-dev May 11, 2024
7fe8661
update: shell script
booi-dev May 13, 2024
2d30288
add: create not selected icons
booi-dev May 13, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
Binary file modified .DS_Store
Binary file not shown.
8 changes: 8 additions & 0 deletions .changeset/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
# Changesets

Hello and welcome! This folder has been automatically generated by `@changesets/cli`, a build tool that works
with multi-package repos, or single-package repos to help you version and publish your code. You can
find the full documentation for it [in our repository](https://github.com/changesets/changesets)

We have a quick list of common questions to get you started engaging with this project in
[our documentation](https://github.com/changesets/changesets/blob/main/docs/common-questions.md)
11 changes: 11 additions & 0 deletions .changeset/config.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
{
"$schema": "https://unpkg.com/@changesets/[email protected]/schema.json",
"changelog": "@changesets/cli/changelog",
"commit": false,
"fixed": [],
"linked": [],
"access": "restricted",
"baseBranch": "main",
"updateInternalDependencies": "patch",
"ignore": []
}
5 changes: 5 additions & 0 deletions .changeset/khaki-glasses-grow.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'@aftershootco/unicorn-icons': major
---

ravamp icons components
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
**/node_modules
**/dist
yarn.lock
.vscode
.yarn
2 changes: 1 addition & 1 deletion .husky/pre-commit
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,6 @@
. "$(dirname "$0")/_/husky.sh"

# npx --no-install pretty-quick
yarn version --no-git-tag-version --patch && git add .
git add .
# npx pretty-quick --staged
# yarn lint-staged
41 changes: 41 additions & 0 deletions .storybook/main.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
import type { StorybookConfig } from '@storybook/react-webpack5'
import { dirname, join } from 'path'

/**
* This function is used to resolve the absolute path of a package.
* It is needed in projects that use Yarn PnP or are set up within a monorepo.
*/
function getAbsolutePath(value: string): any {
return dirname(require.resolve(join(value, 'package.json')))
}

const config: StorybookConfig = {
stories: ['../src/**/*.mdx', '../src/**/*.stories.@(js|jsx|mjs|ts|tsx)'],
addons: [
getAbsolutePath('@storybook/addon-links'),
getAbsolutePath('@storybook/addon-essentials'),
getAbsolutePath('@storybook/addon-onboarding'),
getAbsolutePath('@storybook/addon-interactions'),
getAbsolutePath('@storybook/addon-styling-webpack'),
],
framework: {
name: getAbsolutePath('@storybook/react-webpack5'),
options: {
builder: {
useSWC: true,
},
},
},
docs: {
autodocs: 'tag',
},
webpackFinal: async (config) => {
config?.module?.rules?.push({
test: /\.scss$/,
use: ['style-loader', 'css-loader', 'postcss-loader', 'sass-loader'],
})

return config
},
}
export default config
21 changes: 21 additions & 0 deletions .storybook/preview.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
import type { Preview } from '@storybook/react'
import '../src/styles/tailwind.css'

const preview: Preview = {
parameters: {
actions: { argTypesRegex: '^on[A-Z].*' },
controls: {
matchers: {
color: /(background|color)$/i,
date: /Date$/i,
},
},
// options: {
// storySort: {
// method: 'alphabetical',
// },
// },
},
}

export default preview
61 changes: 61 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,68 @@ yarn
yarn build
```

## How to Generate Components

0. Make sure the main color/stroke color of the svg is #E2E2E2. Otherwise, it will not work properly.

1. Put the new SVGs in `/src/new-svgs`.

2. Run `sh generate.sh`. This will generate a `src/new-components` and `src/new-stories` with icon components,
and stories respectively.

3. Inside the newly created components, update any additional icon variant and secondary colors with the correct prop names. Make sure to add correct types.

4. Once, tested and satisfied, move the component from `src/new-components` to the right folder - `src/icons/[subfolder]`, and stories from `src/new-stories` to `src/stories`. (Also update the stories titles - the default is New)

5. Now run `sh export.sh`. This will export the newly created components, ready to be used.

Inside the stories - The import of newly created component should look like this -
`import { NewlyCreatedComponent } from '../icons'`

You are all set

## Control Secondary Color

Many icons have secondary colors - background color, accent color etc. Make sure to modify the component with correct props name
background color - bgColor
accent color - accentColor.

## Practice for Correct Types

Every icon component have three type - 'primary' | 'secondary' | 'tertiary' by default
Keep only primary if there is only one icon type.
Add types if there the component have secondary colors such as bgColor or accentColor

## About Storybook

Stories are automatically generated when you run `sh generate.sh`.
New stories will have prefix folder name as NEW. Make sure to change this as per your require.
Also, remember to import icon correctly from the icon folder.

Live storybook: "[https://65bb4c7b2d4e48c0410f5829-cenawazgya.chromatic.com/?path=/story/culling-addfoldericon--default&globals=backgrounds.value:!hex(333333)](<https://65bb4c7b2d4e48c0410f5829-fgpcpxhxjl.chromatic.com/?path=/story/logo-aftershootlogoicon--default&globals=backgrounds.value:!hex(333333)>)"

## Publish storbook to Chromatic

run `yarn chromatic`

Chromatic Dashboard: https://www.chromatic.com/build?appId=65bb4c7b2d4e48c0410f5829&number=3

## Using icon components Tips

1. Import from '@aftershootco/unicorn-icons'

2. Props - size, color, fillColor (icons with fill), variant (if icon have more than one variant), bgColor (icon with bg), inActive (make icon color dull, this will have more priority than color props)

3. on hover effect example

```js
<button className='group' onClick={props.onClose}>
<CloseIcon size={14} color='#777777' className='group-hover:[&_*]:fill-white group-hover:[&_*]:stroke-white' />
</button>
```

## Contributors

- Akash Singh — [Github](https://github.com/frannkenstein)
- Yash Johri — [Github](https://github.com/yash1200)
- Booi Mangang - [Github](https://github.com/booi-dev)
Binary file added aftershootco-unicorn-icons-beta-1.0.0.tgz
Binary file not shown.
Loading