@dicebear/avataaars 5.0.0-beta.4 → 5.0.0-beta.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (43) hide show
  1. package/LICENSE +14 -1
  2. package/README.md +17 -5
  3. package/lib/components/accessories.d.ts +1 -1
  4. package/lib/components/accessories.js +1 -1
  5. package/lib/components/clothing.d.ts +1 -1
  6. package/lib/components/clothing.js +1 -1
  7. package/lib/components/clothingGraphic.d.ts +1 -1
  8. package/lib/components/clothingGraphic.js +1 -1
  9. package/lib/components/eyebrows.d.ts +1 -1
  10. package/lib/components/eyebrows.js +1 -1
  11. package/lib/components/eyes.d.ts +1 -1
  12. package/lib/components/eyes.js +1 -1
  13. package/lib/components/facialHair.d.ts +1 -1
  14. package/lib/components/facialHair.js +1 -1
  15. package/lib/components/index.d.ts +1 -1
  16. package/lib/components/index.js +1 -1
  17. package/lib/components/mouth.d.ts +1 -1
  18. package/lib/components/mouth.js +1 -1
  19. package/lib/components/nose.d.ts +1 -1
  20. package/lib/components/nose.js +1 -1
  21. package/lib/components/style.d.ts +1 -1
  22. package/lib/components/style.js +3 -3
  23. package/lib/components/top.d.ts +1 -1
  24. package/lib/components/top.js +1 -1
  25. package/lib/hooks/onPostCreate.d.ts +2 -2
  26. package/lib/hooks/onPostCreate.js +1 -1
  27. package/lib/hooks/onPreCreate.d.ts +2 -2
  28. package/lib/hooks/onPreCreate.js +1 -1
  29. package/lib/index.d.ts +17 -3
  30. package/lib/index.js +31 -15
  31. package/lib/schema.d.ts +1 -1
  32. package/lib/schema.js +1 -1
  33. package/lib/types.d.ts +7 -7
  34. package/lib/types.js +1 -1
  35. package/lib/utils/getColors.d.ts +2 -2
  36. package/lib/utils/getColors.js +1 -1
  37. package/lib/utils/getComponents.d.ts +2 -2
  38. package/lib/utils/getComponents.js +1 -1
  39. package/lib/utils/pickComponent.d.ts +2 -2
  40. package/lib/utils/pickComponent.js +1 -1
  41. package/package.json +4 -3
  42. package/lib/core.d.ts +0 -9
  43. package/lib/core.js +0 -39
package/LICENSE CHANGED
@@ -1,6 +1,19 @@
1
+ Licenses
2
+ --------
3
+
4
+ # Design
5
+ Applies to all design files in this package.
6
+
7
+ Source: Avataaars (https://avataaars.com/)
8
+ Designer: Pablo Stanley (https://twitter.com/pablostanley)
9
+ License: Free for personal and commercial use (https://avataaars.com/)
10
+
11
+ # Code
12
+ Applies to all non-design files in this package.
13
+
1
14
  MIT License
2
15
 
3
- Copyright (c) 2022 Florian Körner
16
+ Copyright (c) 2023 Florian Körner
4
17
 
5
18
  Permission is hereby granted, free of charge, to any person obtaining a copy
6
19
  of this software and associated documentation files (the "Software"), to deal
package/README.md CHANGED
@@ -1,13 +1,25 @@
1
- <h1 align="center"><img src="./tests/svg/0.svg" width="124" /> <br />Avataaars</h1>
1
+ <h1 align="center"><img src="https://dicebear.com/logo-readme.svg" width="96" /> <br />DiceBear Avataaars</h1>
2
2
  <p align="center">
3
3
  <strong>Avatar Style for <a href="https://dicebear.com/">DiceBear</a></strong><br />
4
- <a href="https://avataaars.com/">Avataaars</a>
5
- by <a href="https://twitter.com/pablostanley">Pablo Stanley</a>
4
+ <a href="https://avataaars.com/">Avataaars</a> by <a href="https://twitter.com/pablostanley">Pablo Stanley</a>
6
5
  </p>
7
6
 
8
7
  <p align="center">
9
- While our code is MIT licensed, the design is licensed under
10
- <a href="https://avataaars.com/">Free for personal and commercial use</a>.
8
+ <img src="https://api.dicebear.com/5.x/avataaars/svg?seed=Mimi" width="64" />
9
+ <img src="https://api.dicebear.com/5.x/avataaars/svg?seed=Sasha" width="64" />
10
+ <img src="https://api.dicebear.com/5.x/avataaars/svg?seed=Lilly" width="64" />
11
+ <img src="https://api.dicebear.com/5.x/avataaars/svg?seed=Tigger" width="64" />
12
+ <img src="https://api.dicebear.com/5.x/avataaars/svg?seed=Bella" width="64" />
13
+ <img src="https://api.dicebear.com/5.x/avataaars/svg?seed=Zoe" width="64" />
14
+ <img src="https://api.dicebear.com/5.x/avataaars/svg?seed=Kitty" width="64" />
15
+ </p>
16
+
17
+ <p align="center">
18
+ The avatar style is based on <a href="https://avataaars.com/">Avataaars</a> by
19
+ <a href="https://twitter.com/pablostanley">Pablo Stanley</a>, licensed under
20
+ <a href="https://avataaars.com/">Free for personal and commercial use</a>. / Remix of the original.
21
+ </p>
22
+ <p align="center">
11
23
  See <a href="https://dicebear.com/licenses">license overview</a> for more information.
12
24
  </p>
13
25
 
@@ -2,7 +2,7 @@
2
2
  * Do not change this file manually! This file was generated with the "Dicebear Exporter"-Plugin for Figma.
3
3
  *
4
4
  * Plugin: https://www.figma.com/community/plugin/1005765655729342787
5
- * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h/%40dicebear%2Favataaars?node-id=10%3A108
5
+ * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h
6
6
  */
7
7
  import type { ComponentGroup } from '../types.js';
8
8
  export declare const accessories: ComponentGroup;
@@ -2,7 +2,7 @@
2
2
  * Do not change this file manually! This file was generated with the "Dicebear Exporter"-Plugin for Figma.
3
3
  *
4
4
  * Plugin: https://www.figma.com/community/plugin/1005765655729342787
5
- * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h/%40dicebear%2Favataaars?node-id=10%3A108
5
+ * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h
6
6
  */
7
7
  import { escape } from '@dicebear/core';
8
8
  export const accessories = {
@@ -2,7 +2,7 @@
2
2
  * Do not change this file manually! This file was generated with the "Dicebear Exporter"-Plugin for Figma.
3
3
  *
4
4
  * Plugin: https://www.figma.com/community/plugin/1005765655729342787
5
- * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h/%40dicebear%2Favataaars?node-id=10%3A108
5
+ * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h
6
6
  */
7
7
  import type { ComponentGroup } from '../types.js';
8
8
  export declare const clothing: ComponentGroup;
@@ -2,7 +2,7 @@
2
2
  * Do not change this file manually! This file was generated with the "Dicebear Exporter"-Plugin for Figma.
3
3
  *
4
4
  * Plugin: https://www.figma.com/community/plugin/1005765655729342787
5
- * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h/%40dicebear%2Favataaars?node-id=10%3A108
5
+ * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h
6
6
  */
7
7
  import { escape } from '@dicebear/core';
8
8
  export const clothing = {
@@ -2,7 +2,7 @@
2
2
  * Do not change this file manually! This file was generated with the "Dicebear Exporter"-Plugin for Figma.
3
3
  *
4
4
  * Plugin: https://www.figma.com/community/plugin/1005765655729342787
5
- * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h/%40dicebear%2Favataaars?node-id=10%3A108
5
+ * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h
6
6
  */
7
7
  import type { ComponentGroup } from '../types.js';
8
8
  export declare const clothingGraphic: ComponentGroup;
@@ -2,7 +2,7 @@
2
2
  * Do not change this file manually! This file was generated with the "Dicebear Exporter"-Plugin for Figma.
3
3
  *
4
4
  * Plugin: https://www.figma.com/community/plugin/1005765655729342787
5
- * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h/%40dicebear%2Favataaars?node-id=10%3A108
5
+ * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h
6
6
  */
7
7
  export const clothingGraphic = {
8
8
  'bat': (components, colors) => `<path fill-rule="evenodd" clip-rule="evenodd" d="M87.69 13.4c-1.4-6.43-6.21-10.15-12.5-11.58-2.53-.58-10.92-2.4-9.61 2.4.6 2.18.26 3.97-1.55 5.77-1.77 1.76-5.24 2.2-6.96-.01-1.47-1.9.43-4.72-.72-6.57-.44-.71-1.21-1.08-2.03-.73-1.14.5-.53 1.56-1.07 2.32-.85 1.2-1.24.83-2-.37-.49-.76-.02-1.58-1.26-1.9-1.43-.37-1.9.83-2.03 1.92-.08.69.32 1.8.34 2.5.03 1.35-.1 3.31-.73 4.52-1.12 2.14-2.7 1.45-4.38.1-1.98-1.6-2.56-3.39-2.18-5.82.46-2.92.3-5.71-3.28-3.89-5.02 2.57-9.68 7.14-12.59 11.92-2.44 4.02-4.36 8.9-2.2 13.48 2.21 4.67 5.86 8.69 10.97 9.88 1.32.3 5.09 1.81 6.34.55 1.95-1.96-2.54-3.78-3.43-4.97-1.26-1.7-2.34-4.92-.96-6.83 1.76-2.43 3.6-1.08 5.05.64 1.13 1.35 2.75 4.82 4.5 2.02 1.21-1.93 1.1-5.1 4.4-3.72 4.73 1.98 4.87 11.12 5.71 15.3.37 1.82 2.04 4.06 3.47 1.52.8-1.4.37-4.42.22-5.86-.3-2.99-1.08-5.92-.1-8.88.55-1.71 2-4.16 4.12-2.84 1.73 1.06 1 5.81 3.35 5.8 2.07 0 1.5-3.79 2.6-5.04 1.69-1.9 4.92-1 5.92 1.25 1.33 3.03-2.2 5.13-2.05 7.79.16 2.59 3.5 1.58 4.9.92 2.87-1.35 5.11-3.85 6.67-6.57 2.4-4.2 4.13-10.22 3.08-15.03" fill="#fff"/>`,
@@ -2,7 +2,7 @@
2
2
  * Do not change this file manually! This file was generated with the "Dicebear Exporter"-Plugin for Figma.
3
3
  *
4
4
  * Plugin: https://www.figma.com/community/plugin/1005765655729342787
5
- * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h/%40dicebear%2Favataaars?node-id=10%3A108
5
+ * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h
6
6
  */
7
7
  import type { ComponentGroup } from '../types.js';
8
8
  export declare const eyebrows: ComponentGroup;
@@ -2,7 +2,7 @@
2
2
  * Do not change this file manually! This file was generated with the "Dicebear Exporter"-Plugin for Figma.
3
3
  *
4
4
  * Plugin: https://www.figma.com/community/plugin/1005765655729342787
5
- * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h/%40dicebear%2Favataaars?node-id=10%3A108
5
+ * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h
6
6
  */
7
7
  export const eyebrows = {
8
8
  'angryNatural': (components, colors) => `<path d="M44.1 17.12ZM19.27 5.01a7.16 7.16 0 0 0-6.42 2.43c-.6.73-1.56 2.48-1.51 3.42.02.35.22.37 1.12.59 1.65.39 4.5-1.12 6.36-.98 2.58.2 5.04 1.4 7.28 2.68 3.84 2.2 8.35 6.84 13.1 6.6.35-.02 5.41-1.74 4.4-2.72-.31-.49-3.03-1.13-3.5-1.36-2.17-1.09-4.37-2.45-6.44-3.72C29.14 9.18 24.72 5.6 19.28 5ZM68.03 17.12ZM92.91 5.01c2.36-.27 4.85.5 6.42 2.43.6.73 1.56 2.48 1.51 3.42-.02.35-.22.37-1.12.59-1.65.39-4.5-1.12-6.36-.98-2.58.2-5.04 1.4-7.28 2.68-3.84 2.2-8.35 6.84-13.1 6.6-.35-.02-5.41-1.74-4.4-2.72.31-.49 3.03-1.13 3.5-1.36 2.17-1.09 4.36-2.45 6.44-3.72C83.05 9.18 87.46 5.6 92.91 5Z" fill-rule="evenodd" clip-rule="evenodd" fill="#000" fill-opacity=".6"/>`,
@@ -2,7 +2,7 @@
2
2
  * Do not change this file manually! This file was generated with the "Dicebear Exporter"-Plugin for Figma.
3
3
  *
4
4
  * Plugin: https://www.figma.com/community/plugin/1005765655729342787
5
- * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h/%40dicebear%2Favataaars?node-id=10%3A108
5
+ * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h
6
6
  */
7
7
  import type { ComponentGroup } from '../types.js';
8
8
  export declare const eyes: ComponentGroup;
@@ -2,7 +2,7 @@
2
2
  * Do not change this file manually! This file was generated with the "Dicebear Exporter"-Plugin for Figma.
3
3
  *
4
4
  * Plugin: https://www.figma.com/community/plugin/1005765655729342787
5
- * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h/%40dicebear%2Favataaars?node-id=10%3A108
5
+ * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h
6
6
  */
7
7
  export const eyes = {
8
8
  'closed': (components, colors) => `<path d="M16.16 27.55c1.85 3.8 6 6.45 10.84 6.45 4.81 0 8.96-2.63 10.82-6.4.55-1.13-.24-2.05-1.03-1.37a15.05 15.05 0 0 1-9.8 3.43c-3.73 0-7.12-1.24-9.55-3.23-.9-.73-1.82.01-1.28 1.12ZM74.16 27.55c1.85 3.8 6 6.45 10.84 6.45 4.81 0 8.96-2.63 10.82-6.4.55-1.13-.24-2.05-1.03-1.37a15.05 15.05 0 0 1-9.8 3.43c-3.74 0-7.13-1.24-9.56-3.23-.9-.73-1.82.01-1.28 1.12Z" fill-rule="evenodd" clip-rule="evenodd" fill="#000" fill-opacity=".6"/>`,
@@ -2,7 +2,7 @@
2
2
  * Do not change this file manually! This file was generated with the "Dicebear Exporter"-Plugin for Figma.
3
3
  *
4
4
  * Plugin: https://www.figma.com/community/plugin/1005765655729342787
5
- * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h/%40dicebear%2Favataaars?node-id=10%3A108
5
+ * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h
6
6
  */
7
7
  import type { ComponentGroup } from '../types.js';
8
8
  export declare const facialHair: ComponentGroup;
@@ -2,7 +2,7 @@
2
2
  * Do not change this file manually! This file was generated with the "Dicebear Exporter"-Plugin for Figma.
3
3
  *
4
4
  * Plugin: https://www.figma.com/community/plugin/1005765655729342787
5
- * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h/%40dicebear%2Favataaars?node-id=10%3A108
5
+ * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h
6
6
  */
7
7
  import { escape } from '@dicebear/core';
8
8
  export const facialHair = {
@@ -2,7 +2,7 @@
2
2
  * Do not change this file manually! This file was generated with the "Dicebear Exporter"-Plugin for Figma.
3
3
  *
4
4
  * Plugin: https://www.figma.com/community/plugin/1005765655729342787
5
- * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h/%40dicebear%2Favataaars?node-id=10%3A108
5
+ * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h
6
6
  */
7
7
  export { style } from './style.js';
8
8
  export { clothing } from './clothing.js';
@@ -2,7 +2,7 @@
2
2
  * Do not change this file manually! This file was generated with the "Dicebear Exporter"-Plugin for Figma.
3
3
  *
4
4
  * Plugin: https://www.figma.com/community/plugin/1005765655729342787
5
- * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h/%40dicebear%2Favataaars?node-id=10%3A108
5
+ * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h
6
6
  */
7
7
  export { style } from './style.js';
8
8
  export { clothing } from './clothing.js';
@@ -2,7 +2,7 @@
2
2
  * Do not change this file manually! This file was generated with the "Dicebear Exporter"-Plugin for Figma.
3
3
  *
4
4
  * Plugin: https://www.figma.com/community/plugin/1005765655729342787
5
- * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h/%40dicebear%2Favataaars?node-id=10%3A108
5
+ * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h
6
6
  */
7
7
  import type { ComponentGroup } from '../types.js';
8
8
  export declare const mouth: ComponentGroup;
@@ -2,7 +2,7 @@
2
2
  * Do not change this file manually! This file was generated with the "Dicebear Exporter"-Plugin for Figma.
3
3
  *
4
4
  * Plugin: https://www.figma.com/community/plugin/1005765655729342787
5
- * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h/%40dicebear%2Favataaars?node-id=10%3A108
5
+ * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h
6
6
  */
7
7
  export const mouth = {
8
8
  'concerned': (components, colors) => `<path fill-rule="evenodd" clip-rule="evenodd" d="M35.12 29.87a19 19 0 0 1 37.77.09c.08.77-.77 2.04-1.85 2.04H37.1C36 32 35 30.82 35.12 29.87Z" fill="#000" fill-opacity=".7"/><path d="M69.59 32H38.4a11 11 0 0 1 15.6-6.8A11 11 0 0 1 69.59 32Z" fill="#FF4F6D"/><path d="M66.57 17.75A5 5 0 0 1 65 18H44c-.8 0-1.57-.2-2.24-.53A18.92 18.92 0 0 1 54 13c4.82 0 9.22 1.8 12.57 4.75Z" fill="#fff"/>`,
@@ -2,7 +2,7 @@
2
2
  * Do not change this file manually! This file was generated with the "Dicebear Exporter"-Plugin for Figma.
3
3
  *
4
4
  * Plugin: https://www.figma.com/community/plugin/1005765655729342787
5
- * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h/%40dicebear%2Favataaars?node-id=10%3A108
5
+ * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h
6
6
  */
7
7
  import type { ComponentGroup } from '../types.js';
8
8
  export declare const nose: ComponentGroup;
@@ -2,7 +2,7 @@
2
2
  * Do not change this file manually! This file was generated with the "Dicebear Exporter"-Plugin for Figma.
3
3
  *
4
4
  * Plugin: https://www.figma.com/community/plugin/1005765655729342787
5
- * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h/%40dicebear%2Favataaars?node-id=10%3A108
5
+ * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h
6
6
  */
7
7
  export const nose = {
8
8
  'default': (components, colors) => `<path fill-rule="evenodd" clip-rule="evenodd" d="M16 8c0 4.42 5.37 8 12 8s12-3.58 12-8" fill="#000" fill-opacity=".16"/>`,
@@ -2,7 +2,7 @@
2
2
  * Do not change this file manually! This file was generated with the "Dicebear Exporter"-Plugin for Figma.
3
3
  *
4
4
  * Plugin: https://www.figma.com/community/plugin/1005765655729342787
5
- * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h/%40dicebear%2Favataaars?node-id=10%3A108
5
+ * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h
6
6
  */
7
7
  import type { ComponentGroup } from '../types.js';
8
8
  export declare const style: ComponentGroup;
@@ -2,10 +2,10 @@
2
2
  * Do not change this file manually! This file was generated with the "Dicebear Exporter"-Plugin for Figma.
3
3
  *
4
4
  * Plugin: https://www.figma.com/community/plugin/1005765655729342787
5
- * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h/%40dicebear%2Favataaars?node-id=10%3A108
5
+ * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h
6
6
  */
7
7
  import { escape } from '@dicebear/core';
8
8
  export const style = {
9
- 'circle': (components, colors) => { var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m; return `<circle cx="132" cy="160" r="120" fill="#E6E6E6"/><mask id="styleCircle-a" style="mask-type:alpha" maskUnits="userSpaceOnUse" x="12" y="40" width="240" height="240"><circle cx="132" cy="160" r="120" fill="#fff"/></mask><g mask="url(#styleCircle-a)"><path d="M12 40h240v240H12V40Z" fill="${escape.xml(`#${colors.background}`)}"/></g><mask id="styleCircle-b" style="mask-type:alpha" maskUnits="userSpaceOnUse" x="0" y="0" width="264" height="280"><path d="M264 0H0v160h12c0 66.27 53.73 120 120 120 66.27 0 120-53.73 120-120h12V0Z" fill="#000"/></mask><g mask="url(#styleCircle-b)"><path d="M132 36a56 56 0 0 0-56 56v6.17A12 12 0 0 0 66 110v14a12 12 0 0 0 10.3 11.88 56.04 56.04 0 0 0 31.7 44.73v18.4h-4a72 72 0 0 0-72 72v9h200v-9a72 72 0 0 0-72-72h-4v-18.39a56.04 56.04 0 0 0 31.7-44.73A12 12 0 0 0 198 124v-14a12 12 0 0 0-10-11.83V92a56 56 0 0 0-56-56Z" fill="#D0C6AC"/><mask id="styleCircle-c" style="mask-type:alpha" maskUnits="userSpaceOnUse" x="32" y="36" width="200" height="244"><path d="M132 36a56 56 0 0 0-56 56v6.17A12 12 0 0 0 66 110v14a12 12 0 0 0 10.3 11.88 56.04 56.04 0 0 0 31.7 44.73v18.4h-4a72 72 0 0 0-72 72v9h200v-9a72 72 0 0 0-72-72h-4v-18.39a56.04 56.04 0 0 0 31.7-44.73A12 12 0 0 0 198 124v-14a12 12 0 0 0-10-11.83V92a56 56 0 0 0-56-56Z" fill="#D0C6AC"/></mask><g mask="url(#styleCircle-c)"><path fill="${escape.xml(`#${colors.skin}`)}" d="M0 36h264v244H0z"/><path d="M76 130v8a56 56 0 1 0 112 0v-8a56 56 0 1 1-112 0Z" fill="#000" fill-opacity=".1"/></g><g transform="translate(0 170)">${(_b = (_a = components.clothing) === null || _a === void 0 ? void 0 : _a.value(components, colors)) !== null && _b !== void 0 ? _b : ''}</g><g transform="translate(78 134)">${(_d = (_c = components.mouth) === null || _c === void 0 ? void 0 : _c.value(components, colors)) !== null && _d !== void 0 ? _d : ''}</g><g transform="translate(104 122)">${(_f = (_e = components.nose) === null || _e === void 0 ? void 0 : _e.value(components, colors)) !== null && _f !== void 0 ? _f : ''}</g><g transform="translate(76 90)">${(_h = (_g = components.eyes) === null || _g === void 0 ? void 0 : _g.value(components, colors)) !== null && _h !== void 0 ? _h : ''}</g><g transform="translate(76 82)">${(_k = (_j = components.eyebrows) === null || _j === void 0 ? void 0 : _j.value(components, colors)) !== null && _k !== void 0 ? _k : ''}</g><mask id="styleCircle-d" style="mask-type:alpha" maskUnits="userSpaceOnUse" x="0" y="0" width="264" height="280"><path fill="#fff" d="M0 0h264v280H0z"/></mask><g mask="url(#styleCircle-d)"><g transform="translate(-1)">${(_m = (_l = components.top) === null || _l === void 0 ? void 0 : _l.value(components, colors)) !== null && _m !== void 0 ? _m : ''}</g></g></g>`; },
10
- 'default': (components, colors) => { var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m; return `<path d="M132 36a56 56 0 0 0-56 56v6.17A12 12 0 0 0 66 110v14a12 12 0 0 0 10.3 11.88 56.04 56.04 0 0 0 31.7 44.73v18.4h-4a72 72 0 0 0-72 72v9h200v-9a72 72 0 0 0-72-72h-4v-18.39a56.04 56.04 0 0 0 31.7-44.73A12 12 0 0 0 198 124v-14a12 12 0 0 0-10-11.83V92a56 56 0 0 0-56-56Z" fill="#D0C6AC"/><mask id="styleDefault-a" style="mask-type:alpha" maskUnits="userSpaceOnUse" x="32" y="36" width="200" height="244"><path d="M132 36a56 56 0 0 0-56 56v6.17A12 12 0 0 0 66 110v14a12 12 0 0 0 10.3 11.88 56.04 56.04 0 0 0 31.7 44.73v18.4h-4a72 72 0 0 0-72 72v9h200v-9a72 72 0 0 0-72-72h-4v-18.39a56.04 56.04 0 0 0 31.7-44.73A12 12 0 0 0 198 124v-14a12 12 0 0 0-10-11.83V92a56 56 0 0 0-56-56Z" fill="#D0C6AC"/></mask><g mask="url(#styleDefault-a)"><path fill="${escape.xml(`#${colors.skin}`)}" d="M0 36h264v244H0z"/><path d="M76 130v8a56 56 0 1 0 112 0v-8a56 56 0 1 1-112 0Z" fill="#000" fill-opacity=".1"/></g><g transform="translate(0 170)">${(_b = (_a = components.clothing) === null || _a === void 0 ? void 0 : _a.value(components, colors)) !== null && _b !== void 0 ? _b : ''}</g><g transform="translate(78 134)">${(_d = (_c = components.mouth) === null || _c === void 0 ? void 0 : _c.value(components, colors)) !== null && _d !== void 0 ? _d : ''}</g><g transform="translate(104 122)">${(_f = (_e = components.nose) === null || _e === void 0 ? void 0 : _e.value(components, colors)) !== null && _f !== void 0 ? _f : ''}</g><g transform="translate(76 90)">${(_h = (_g = components.eyes) === null || _g === void 0 ? void 0 : _g.value(components, colors)) !== null && _h !== void 0 ? _h : ''}</g><g transform="translate(76 82)">${(_k = (_j = components.eyebrows) === null || _j === void 0 ? void 0 : _j.value(components, colors)) !== null && _k !== void 0 ? _k : ''}</g><mask id="styleDefault-b" style="mask-type:alpha" maskUnits="userSpaceOnUse" x="0" y="0" width="264" height="280"><path fill="#fff" d="M0 0h264v280H0z"/></mask><g mask="url(#styleDefault-b)"><g transform="translate(-1)">${(_m = (_l = components.top) === null || _l === void 0 ? void 0 : _l.value(components, colors)) !== null && _m !== void 0 ? _m : ''}</g></g>`; },
9
+ 'circle': (components, colors) => { var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m; return `<circle cx="132" cy="160" r="120" fill="#E6E6E6"/><mask id="styleCircle-a" style="mask-type:luminance" maskUnits="userSpaceOnUse" x="12" y="40" width="240" height="240"><circle cx="132" cy="160" r="120" fill="#fff"/></mask><g mask="url(#styleCircle-a)"><path d="M12 40h240v240H12V40Z" fill="${escape.xml(`#${colors.background}`)}"/></g><mask id="styleCircle-b" style="mask-type:alpha" maskUnits="userSpaceOnUse" x="0" y="0" width="264" height="280"><path d="M264 0H0v160h12c0 66.27 53.73 120 120 120 66.27 0 120-53.73 120-120h12V0Z" fill="#000"/></mask><g mask="url(#styleCircle-b)"><path d="M132 36a56 56 0 0 0-56 56v6.17A12 12 0 0 0 66 110v14a12 12 0 0 0 10.3 11.88 56.04 56.04 0 0 0 31.7 44.73v18.4h-4a72 72 0 0 0-72 72v9h200v-9a72 72 0 0 0-72-72h-4v-18.39a56.04 56.04 0 0 0 31.7-44.73A12 12 0 0 0 198 124v-14a12 12 0 0 0-10-11.83V92a56 56 0 0 0-56-56Z" fill="#D0C6AC"/><mask id="styleCircle-c" style="mask-type:alpha" maskUnits="userSpaceOnUse" x="32" y="36" width="200" height="244"><path d="M132 36a56 56 0 0 0-56 56v6.17A12 12 0 0 0 66 110v14a12 12 0 0 0 10.3 11.88 56.04 56.04 0 0 0 31.7 44.73v18.4h-4a72 72 0 0 0-72 72v9h200v-9a72 72 0 0 0-72-72h-4v-18.39a56.04 56.04 0 0 0 31.7-44.73A12 12 0 0 0 198 124v-14a12 12 0 0 0-10-11.83V92a56 56 0 0 0-56-56Z" fill="#D0C6AC"/></mask><g mask="url(#styleCircle-c)"><path fill="${escape.xml(`#${colors.skin}`)}" d="M0 36h264v244H0z"/><path d="M76 130v8a56 56 0 1 0 112 0v-8a56 56 0 1 1-112 0Z" fill="#000" fill-opacity=".1"/></g><g transform="translate(0 170)">${(_b = (_a = components.clothing) === null || _a === void 0 ? void 0 : _a.value(components, colors)) !== null && _b !== void 0 ? _b : ''}</g><g transform="translate(78 134)">${(_d = (_c = components.mouth) === null || _c === void 0 ? void 0 : _c.value(components, colors)) !== null && _d !== void 0 ? _d : ''}</g><g transform="translate(104 122)">${(_f = (_e = components.nose) === null || _e === void 0 ? void 0 : _e.value(components, colors)) !== null && _f !== void 0 ? _f : ''}</g><g transform="translate(76 90)">${(_h = (_g = components.eyes) === null || _g === void 0 ? void 0 : _g.value(components, colors)) !== null && _h !== void 0 ? _h : ''}</g><g transform="translate(76 82)">${(_k = (_j = components.eyebrows) === null || _j === void 0 ? void 0 : _j.value(components, colors)) !== null && _k !== void 0 ? _k : ''}</g><mask id="styleCircle-d" style="mask-type:luminance" maskUnits="userSpaceOnUse" x="0" y="0" width="264" height="280"><path fill="#fff" d="M0 0h264v280H0z"/></mask><g mask="url(#styleCircle-d)"><g transform="translate(-1)">${(_m = (_l = components.top) === null || _l === void 0 ? void 0 : _l.value(components, colors)) !== null && _m !== void 0 ? _m : ''}</g></g></g>`; },
10
+ 'default': (components, colors) => { var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m; return `<path d="M132 36a56 56 0 0 0-56 56v6.17A12 12 0 0 0 66 110v14a12 12 0 0 0 10.3 11.88 56.04 56.04 0 0 0 31.7 44.73v18.4h-4a72 72 0 0 0-72 72v9h200v-9a72 72 0 0 0-72-72h-4v-18.39a56.04 56.04 0 0 0 31.7-44.73A12 12 0 0 0 198 124v-14a12 12 0 0 0-10-11.83V92a56 56 0 0 0-56-56Z" fill="#D0C6AC"/><mask id="styleDefault-a" style="mask-type:alpha" maskUnits="userSpaceOnUse" x="32" y="36" width="200" height="244"><path d="M132 36a56 56 0 0 0-56 56v6.17A12 12 0 0 0 66 110v14a12 12 0 0 0 10.3 11.88 56.04 56.04 0 0 0 31.7 44.73v18.4h-4a72 72 0 0 0-72 72v9h200v-9a72 72 0 0 0-72-72h-4v-18.39a56.04 56.04 0 0 0 31.7-44.73A12 12 0 0 0 198 124v-14a12 12 0 0 0-10-11.83V92a56 56 0 0 0-56-56Z" fill="#D0C6AC"/></mask><g mask="url(#styleDefault-a)"><path fill="${escape.xml(`#${colors.skin}`)}" d="M0 36h264v244H0z"/><path d="M76 130v8a56 56 0 1 0 112 0v-8a56 56 0 1 1-112 0Z" fill="#000" fill-opacity=".1"/></g><g transform="translate(0 170)">${(_b = (_a = components.clothing) === null || _a === void 0 ? void 0 : _a.value(components, colors)) !== null && _b !== void 0 ? _b : ''}</g><g transform="translate(78 134)">${(_d = (_c = components.mouth) === null || _c === void 0 ? void 0 : _c.value(components, colors)) !== null && _d !== void 0 ? _d : ''}</g><g transform="translate(104 122)">${(_f = (_e = components.nose) === null || _e === void 0 ? void 0 : _e.value(components, colors)) !== null && _f !== void 0 ? _f : ''}</g><g transform="translate(76 90)">${(_h = (_g = components.eyes) === null || _g === void 0 ? void 0 : _g.value(components, colors)) !== null && _h !== void 0 ? _h : ''}</g><g transform="translate(76 82)">${(_k = (_j = components.eyebrows) === null || _j === void 0 ? void 0 : _j.value(components, colors)) !== null && _k !== void 0 ? _k : ''}</g><mask id="styleDefault-b" style="mask-type:luminance" maskUnits="userSpaceOnUse" x="0" y="0" width="264" height="280"><path fill="#fff" d="M0 0h264v280H0z"/></mask><g mask="url(#styleDefault-b)"><g transform="translate(-1)">${(_m = (_l = components.top) === null || _l === void 0 ? void 0 : _l.value(components, colors)) !== null && _m !== void 0 ? _m : ''}</g></g>`; },
11
11
  };
@@ -2,7 +2,7 @@
2
2
  * Do not change this file manually! This file was generated with the "Dicebear Exporter"-Plugin for Figma.
3
3
  *
4
4
  * Plugin: https://www.figma.com/community/plugin/1005765655729342787
5
- * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h/%40dicebear%2Favataaars?node-id=10%3A108
5
+ * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h
6
6
  */
7
7
  import type { ComponentGroup } from '../types.js';
8
8
  export declare const top: ComponentGroup;
@@ -2,7 +2,7 @@
2
2
  * Do not change this file manually! This file was generated with the "Dicebear Exporter"-Plugin for Figma.
3
3
  *
4
4
  * Plugin: https://www.figma.com/community/plugin/1005765655729342787
5
- * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h/%40dicebear%2Favataaars?node-id=10%3A108
5
+ * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h
6
6
  */
7
7
  import { escape } from '@dicebear/core';
8
8
  export const top = {
@@ -2,11 +2,11 @@
2
2
  * Do not change this file manually! This file was generated with the "Dicebear Exporter"-Plugin for Figma.
3
3
  *
4
4
  * Plugin: https://www.figma.com/community/plugin/1005765655729342787
5
- * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h/%40dicebear%2Favataaars?node-id=10%3A108
5
+ * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h
6
6
  */
7
7
  import { Prng, StyleOptions } from "@dicebear/core";
8
8
  import { Options, ColorPickCollection, ComponentPickCollection } from "../types.js";
9
- declare type Props = {
9
+ type Props = {
10
10
  prng: Prng;
11
11
  options: StyleOptions<Options>;
12
12
  components: ComponentPickCollection;
@@ -2,7 +2,7 @@
2
2
  * Do not change this file manually! This file was generated with the "Dicebear Exporter"-Plugin for Figma.
3
3
  *
4
4
  * Plugin: https://www.figma.com/community/plugin/1005765655729342787
5
- * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h/%40dicebear%2Favataaars?node-id=10%3A108
5
+ * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h
6
6
  */
7
7
  export function onPostCreate({ prng, options, components, colors }) {
8
8
  var _a, _b;
@@ -2,11 +2,11 @@
2
2
  * Do not change this file manually! This file was generated with the "Dicebear Exporter"-Plugin for Figma.
3
3
  *
4
4
  * Plugin: https://www.figma.com/community/plugin/1005765655729342787
5
- * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h/%40dicebear%2Favataaars?node-id=10%3A108
5
+ * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h
6
6
  */
7
7
  import { Prng, StyleOptions } from "@dicebear/core";
8
8
  import { Options } from "../types.js";
9
- declare type Props = {
9
+ type Props = {
10
10
  prng: Prng;
11
11
  options: StyleOptions<Options>;
12
12
  };
@@ -2,7 +2,7 @@
2
2
  * Do not change this file manually! This file was generated with the "Dicebear Exporter"-Plugin for Figma.
3
3
  *
4
4
  * Plugin: https://www.figma.com/community/plugin/1005765655729342787
5
- * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h/%40dicebear%2Favataaars?node-id=10%3A108
5
+ * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h
6
6
  */
7
7
  export function onPreCreate({ prng, options }) {
8
8
  // Write your modifications here
package/lib/index.d.ts CHANGED
@@ -2,8 +2,22 @@
2
2
  * Do not change this file manually! This file was generated with the "Dicebear Exporter"-Plugin for Figma.
3
3
  *
4
4
  * Plugin: https://www.figma.com/community/plugin/1005765655729342787
5
- * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h/%40dicebear%2Favataaars?node-id=10%3A108
5
+ * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h
6
6
  */
7
- declare const create: import("@dicebear/core").StyleCreate<import("./types.js").Options>, meta: import("@dicebear/core").StyleMeta, schema: import("json-schema").JSONSchema7;
8
- export { create, meta, schema };
7
+ /*!
8
+ * Avataaars (@dicebear/avataaars)
9
+ *
10
+ * Code licensed under MIT License.
11
+ * Copyright (c) 2023 Florian Körner
12
+ *
13
+ * Design "Avataaars" by Pablo Stanley licensed under Free for personal and commercial use. / Remix of the original.
14
+ * Source: https://avataaars.com/
15
+ * Homepage: https://twitter.com/pablostanley
16
+ * License: https://avataaars.com/
17
+ */
18
+ import type { StyleCreate, StyleMeta } from '@dicebear/core';
19
+ import type { Options } from './types.js';
20
+ export declare const meta: StyleMeta;
21
+ export declare const create: StyleCreate<Options>;
22
+ export { schema } from './schema.js';
9
23
  export type { Options } from './types.js';
package/lib/index.js CHANGED
@@ -2,19 +2,35 @@
2
2
  * Do not change this file manually! This file was generated with the "Dicebear Exporter"-Plugin for Figma.
3
3
  *
4
4
  * Plugin: https://www.figma.com/community/plugin/1005765655729342787
5
- * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h/%40dicebear%2Favataaars?node-id=10%3A108
5
+ * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h
6
6
  */
7
- /*!
8
- * Avataaars (@dicebear/avataaars)
9
- *
10
- * Code licensed under MIT License.
11
- * Copyright (c) 2022 Florian Körner
12
- *
13
- * Design "Avataaars" by Pablo Stanley licensed under Free for personal and commercial use. / Remix of the original.
14
- * Source: https://avataaars.com/
15
- * Homepage: https://twitter.com/pablostanley
16
- * License: https://avataaars.com/
17
- */
18
- import { style } from './core.js';
19
- const { create, meta, schema } = style;
20
- export { create, meta, schema };
7
+ import { getComponents } from './utils/getComponents.js';
8
+ import { getColors } from './utils/getColors.js';
9
+ import { onPreCreate } from './hooks/onPreCreate.js';
10
+ import { onPostCreate } from './hooks/onPostCreate.js';
11
+ export const meta = {
12
+ title: 'Avataaars',
13
+ creator: 'Pablo Stanley',
14
+ source: 'https://avataaars.com/',
15
+ homepage: 'https://twitter.com/pablostanley',
16
+ license: {
17
+ name: 'Free for personal and commercial use',
18
+ url: 'https://avataaars.com/',
19
+ },
20
+ };
21
+ export const create = ({ prng, options }) => {
22
+ var _a, _b;
23
+ onPreCreate({ prng, options });
24
+ const components = getComponents({ prng, options });
25
+ const colors = getColors({ prng, options });
26
+ onPostCreate({ prng, options, components, colors });
27
+ return {
28
+ attributes: {
29
+ viewBox: '0 0 280 280',
30
+ fill: 'none',
31
+ 'shape-rendering': 'auto'
32
+ },
33
+ body: `<g transform="translate(8)">${(_b = (_a = components.style) === null || _a === void 0 ? void 0 : _a.value(components, colors)) !== null && _b !== void 0 ? _b : ''}</g>`,
34
+ };
35
+ };
36
+ export { schema } from './schema.js';
package/lib/schema.d.ts CHANGED
@@ -2,7 +2,7 @@
2
2
  * Do not change this file manually! This file was generated with the "Dicebear Exporter"-Plugin for Figma.
3
3
  *
4
4
  * Plugin: https://www.figma.com/community/plugin/1005765655729342787
5
- * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h/%40dicebear%2Favataaars?node-id=10%3A108
5
+ * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h
6
6
  */
7
7
  import type { StyleSchema } from '@dicebear/core';
8
8
  export declare const schema: StyleSchema;
package/lib/schema.js CHANGED
@@ -2,7 +2,7 @@
2
2
  * Do not change this file manually! This file was generated with the "Dicebear Exporter"-Plugin for Figma.
3
3
  *
4
4
  * Plugin: https://www.figma.com/community/plugin/1005765655729342787
5
- * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h/%40dicebear%2Favataaars?node-id=10%3A108
5
+ * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h
6
6
  */
7
7
  export const schema = {
8
8
  "$schema": "http://json-schema.org/draft-07/schema#",
package/lib/types.d.ts CHANGED
@@ -2,7 +2,7 @@
2
2
  * Do not change this file manually! This file was generated with the "Dicebear Exporter"-Plugin for Figma.
3
3
  *
4
4
  * Plugin: https://www.figma.com/community/plugin/1005765655729342787
5
- * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h/%40dicebear%2Favataaars?node-id=10%3A108
5
+ * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h
6
6
  */
7
7
  export interface Options {
8
8
  style?: ('circle' | 'default')[];
@@ -26,12 +26,12 @@ export interface Options {
26
26
  facialHairColor?: string[];
27
27
  backgroundColor?: string[];
28
28
  }
29
- export declare type ColorPickCollection = Record<string, string>;
30
- export declare type ComponentGroup = Record<string, ComponentGroupItem>;
31
- export declare type ComponentGroupCollection = Record<string, ComponentGroup>;
32
- export declare type ComponentGroupItem = (components: ComponentPickCollection, colors: ColorPickCollection) => string;
33
- export declare type ComponentPickCollection = Record<string, ComponentPick>;
34
- export declare type ComponentPick = {
29
+ export type ColorPickCollection = Record<string, string>;
30
+ export type ComponentGroup = Record<string, ComponentGroupItem>;
31
+ export type ComponentGroupCollection = Record<string, ComponentGroup>;
32
+ export type ComponentGroupItem = (components: ComponentPickCollection, colors: ColorPickCollection) => string;
33
+ export type ComponentPickCollection = Record<string, ComponentPick>;
34
+ export type ComponentPick = {
35
35
  name: string;
36
36
  value: ComponentGroupItem;
37
37
  } | undefined;
package/lib/types.js CHANGED
@@ -2,6 +2,6 @@
2
2
  * Do not change this file manually! This file was generated with the "Dicebear Exporter"-Plugin for Figma.
3
3
  *
4
4
  * Plugin: https://www.figma.com/community/plugin/1005765655729342787
5
- * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h/%40dicebear%2Favataaars?node-id=10%3A108
5
+ * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h
6
6
  */
7
7
  export {};
@@ -2,11 +2,11 @@
2
2
  * Do not change this file manually! This file was generated with the "Dicebear Exporter"-Plugin for Figma.
3
3
  *
4
4
  * Plugin: https://www.figma.com/community/plugin/1005765655729342787
5
- * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h/%40dicebear%2Favataaars?node-id=10%3A108
5
+ * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h
6
6
  */
7
7
  import type { Prng } from '@dicebear/core';
8
8
  import type { Options, ColorPickCollection } from '../types.js';
9
- declare type Props = {
9
+ type Props = {
10
10
  prng: Prng;
11
11
  options: Options;
12
12
  };
@@ -2,7 +2,7 @@
2
2
  * Do not change this file manually! This file was generated with the "Dicebear Exporter"-Plugin for Figma.
3
3
  *
4
4
  * Plugin: https://www.figma.com/community/plugin/1005765655729342787
5
- * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h/%40dicebear%2Favataaars?node-id=10%3A108
5
+ * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h
6
6
  */
7
7
  export function getColors({ prng, options }) {
8
8
  var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p;
@@ -2,11 +2,11 @@
2
2
  * Do not change this file manually! This file was generated with the "Dicebear Exporter"-Plugin for Figma.
3
3
  *
4
4
  * Plugin: https://www.figma.com/community/plugin/1005765655729342787
5
- * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h/%40dicebear%2Favataaars?node-id=10%3A108
5
+ * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h
6
6
  */
7
7
  import type { Prng } from '@dicebear/core';
8
8
  import type { Options, ComponentPickCollection } from '../types.js';
9
- declare type Props = {
9
+ type Props = {
10
10
  prng: Prng;
11
11
  options: Options;
12
12
  };
@@ -2,7 +2,7 @@
2
2
  * Do not change this file manually! This file was generated with the "Dicebear Exporter"-Plugin for Figma.
3
3
  *
4
4
  * Plugin: https://www.figma.com/community/plugin/1005765655729342787
5
- * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h/%40dicebear%2Favataaars?node-id=10%3A108
5
+ * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h
6
6
  */
7
7
  import { pickComponent } from './pickComponent.js';
8
8
  export function getComponents({ prng, options }) {
@@ -2,11 +2,11 @@
2
2
  * Do not change this file manually! This file was generated with the "Dicebear Exporter"-Plugin for Figma.
3
3
  *
4
4
  * Plugin: https://www.figma.com/community/plugin/1005765655729342787
5
- * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h/%40dicebear%2Favataaars?node-id=10%3A108
5
+ * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h
6
6
  */
7
7
  import type { Prng } from '@dicebear/core';
8
8
  import type { ComponentPick } from '../types.js';
9
- declare type Props = {
9
+ type Props = {
10
10
  prng: Prng;
11
11
  group: string;
12
12
  values?: string[];
@@ -2,7 +2,7 @@
2
2
  * Do not change this file manually! This file was generated with the "Dicebear Exporter"-Plugin for Figma.
3
3
  *
4
4
  * Plugin: https://www.figma.com/community/plugin/1005765655729342787
5
- * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h/%40dicebear%2Favataaars?node-id=10%3A108
5
+ * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h
6
6
  */
7
7
  import * as components from '../components/index.js';
8
8
  export function pickComponent({ prng, group, values = [] }) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@dicebear/avataaars",
3
- "version": "5.0.0-beta.4",
3
+ "version": "5.0.0-beta.6",
4
4
  "description": "Avatar style for DiceBear",
5
5
  "keywords": [
6
6
  "dicebear"
@@ -14,6 +14,7 @@
14
14
  },
15
15
  "license": "MIT",
16
16
  "type": "module",
17
+ "main": "./lib/index.js",
17
18
  "exports": "./lib/index.js",
18
19
  "types": "./lib/index.d.ts",
19
20
  "files": [
@@ -28,7 +29,7 @@
28
29
  "test": "uvu tests"
29
30
  },
30
31
  "devDependencies": {
31
- "@dicebear/core": "^5.0.0-beta.4",
32
+ "@dicebear/core": "^5.0.0-beta.6",
32
33
  "@tsconfig/recommended": "^1.0.1",
33
34
  "del-cli": "^4.0.1",
34
35
  "typescript": "^4.6.3",
@@ -43,5 +44,5 @@
43
44
  "publishConfig": {
44
45
  "access": "public"
45
46
  },
46
- "gitHead": "5fcae5a84a2b4b2dd338c4f7a0e461c1efef1e9d"
47
+ "gitHead": "1a81759251d30336383497f31843b48809d0f56b"
47
48
  }
package/lib/core.d.ts DELETED
@@ -1,9 +0,0 @@
1
- /**
2
- * Do not change this file manually! This file was generated with the "Dicebear Exporter"-Plugin for Figma.
3
- *
4
- * Plugin: https://www.figma.com/community/plugin/1005765655729342787
5
- * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h/%40dicebear%2Favataaars?node-id=10%3A108
6
- */
7
- import type { Style } from '@dicebear/core';
8
- import type { Options } from './types.js';
9
- export declare const style: Style<Options>;
package/lib/core.js DELETED
@@ -1,39 +0,0 @@
1
- /**
2
- * Do not change this file manually! This file was generated with the "Dicebear Exporter"-Plugin for Figma.
3
- *
4
- * Plugin: https://www.figma.com/community/plugin/1005765655729342787
5
- * File: https://www.figma.com/file/HBLdITkkTnLs4M09BmCe4h/%40dicebear%2Favataaars?node-id=10%3A108
6
- */
7
- import { schema } from './schema.js';
8
- import { getComponents } from './utils/getComponents.js';
9
- import { getColors } from './utils/getColors.js';
10
- import { onPreCreate } from './hooks/onPreCreate.js';
11
- import { onPostCreate } from './hooks/onPostCreate.js';
12
- export const style = {
13
- meta: {
14
- title: 'Avataaars',
15
- creator: 'Pablo Stanley',
16
- source: 'https://avataaars.com/',
17
- homepage: 'https://twitter.com/pablostanley',
18
- license: {
19
- name: 'Free for personal and commercial use',
20
- url: 'https://avataaars.com/',
21
- },
22
- },
23
- schema: schema,
24
- create: ({ prng, options }) => {
25
- var _a, _b;
26
- onPreCreate({ prng, options });
27
- const components = getComponents({ prng, options });
28
- const colors = getColors({ prng, options });
29
- onPostCreate({ prng, options, components, colors });
30
- return {
31
- attributes: {
32
- viewBox: '0 0 280 280',
33
- fill: 'none',
34
- 'shape-rendering': 'auto'
35
- },
36
- body: `<g transform="translate(8)">${(_b = (_a = components.style) === null || _a === void 0 ? void 0 : _a.value(components, colors)) !== null && _b !== void 0 ? _b : ''}</g>`,
37
- };
38
- },
39
- };