@dicebear/open-peeps 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.
- package/LICENSE +14 -1
- package/README.md +17 -5
- package/lib/components/accessories.d.ts +1 -1
- package/lib/components/accessories.js +1 -1
- package/lib/components/face.d.ts +1 -1
- package/lib/components/face.js +1 -1
- package/lib/components/facialHair.d.ts +1 -1
- package/lib/components/facialHair.js +1 -1
- package/lib/components/head.d.ts +1 -1
- package/lib/components/head.js +1 -1
- package/lib/components/index.d.ts +1 -1
- package/lib/components/index.js +1 -1
- package/lib/components/mask.d.ts +1 -1
- package/lib/components/mask.js +1 -1
- package/lib/hooks/onPostCreate.d.ts +2 -2
- package/lib/hooks/onPostCreate.js +1 -1
- package/lib/hooks/onPreCreate.d.ts +2 -2
- package/lib/hooks/onPreCreate.js +1 -1
- package/lib/index.d.ts +17 -3
- package/lib/index.js +32 -15
- package/lib/schema.d.ts +1 -1
- package/lib/schema.js +1 -1
- package/lib/types.d.ts +7 -7
- package/lib/types.js +1 -1
- package/lib/utils/getColors.d.ts +2 -2
- package/lib/utils/getColors.js +1 -1
- package/lib/utils/getComponents.d.ts +2 -2
- package/lib/utils/getComponents.js +1 -1
- package/lib/utils/pickComponent.d.ts +2 -2
- package/lib/utils/pickComponent.js +1 -1
- package/package.json +4 -3
- package/lib/core.d.ts +0 -9
- package/lib/core.js +0 -40
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: Open Peeps (https://www.openpeeps.com/)
|
|
8
|
+
Designer: Pablo Stanley (https://twitter.com/pablostanley)
|
|
9
|
+
License: CC0 1.0 (https://creativecommons.org/publicdomain/zero/1.0/)
|
|
10
|
+
|
|
11
|
+
# Code
|
|
12
|
+
Applies to all non-design files in this package.
|
|
13
|
+
|
|
1
14
|
MIT License
|
|
2
15
|
|
|
3
|
-
Copyright (c)
|
|
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="
|
|
1
|
+
<h1 align="center"><img src="https://dicebear.com/logo-readme.svg" width="96" /> <br />DiceBear Open Peeps</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://www.openpeeps.com/">Open Peeps</a>
|
|
5
|
-
by <a href="https://twitter.com/pablostanley">Pablo Stanley</a>
|
|
4
|
+
<a href="https://www.openpeeps.com/">Open Peeps</a> by <a href="https://twitter.com/pablostanley">Pablo Stanley</a>
|
|
6
5
|
</p>
|
|
7
6
|
|
|
8
7
|
<p align="center">
|
|
9
|
-
|
|
10
|
-
<
|
|
8
|
+
<img src="https://api.dicebear.com/5.x/open-peeps/svg?seed=Mimi" width="64" />
|
|
9
|
+
<img src="https://api.dicebear.com/5.x/open-peeps/svg?seed=Sasha" width="64" />
|
|
10
|
+
<img src="https://api.dicebear.com/5.x/open-peeps/svg?seed=Lilly" width="64" />
|
|
11
|
+
<img src="https://api.dicebear.com/5.x/open-peeps/svg?seed=Tigger" width="64" />
|
|
12
|
+
<img src="https://api.dicebear.com/5.x/open-peeps/svg?seed=Bella" width="64" />
|
|
13
|
+
<img src="https://api.dicebear.com/5.x/open-peeps/svg?seed=Zoe" width="64" />
|
|
14
|
+
<img src="https://api.dicebear.com/5.x/open-peeps/svg?seed=Kitty" width="64" />
|
|
15
|
+
</p>
|
|
16
|
+
|
|
17
|
+
<p align="center">
|
|
18
|
+
The avatar style is based on <a href="https://www.openpeeps.com/">Open Peeps</a> by
|
|
19
|
+
<a href="https://twitter.com/pablostanley">Pablo Stanley</a>, licensed under
|
|
20
|
+
<a href="https://creativecommons.org/publicdomain/zero/1.0/">CC0 1.0</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/TArMPV7hXUhdCbfEFs3Pfm
|
|
5
|
+
* File: https://www.figma.com/file/TArMPV7hXUhdCbfEFs3Pfm
|
|
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/TArMPV7hXUhdCbfEFs3Pfm
|
|
5
|
+
* File: https://www.figma.com/file/TArMPV7hXUhdCbfEFs3Pfm
|
|
6
6
|
*/
|
|
7
7
|
export const accessories = {
|
|
8
8
|
'eyepatch': (components, colors) => `<path fill-rule="evenodd" clip-rule="evenodd" d="M335.4-59.6c5.8-2 10.4 4 9.3 9.3-1.3 6.1-7.8 11-12 15.4a335 335 0 0 1-42.2 36.7l-3 2.2A342.6 342.6 0 0 1 243.8 32c-2 1-4.3 2.6-6.7 3.8a45 45 0 0 1 17 26.8c3.7 24-11.8 46.3-33.6 55.1a71.3 71.3 0 0 1-34.7 4.4c-11.8-1.3-23.8-4.8-31.5-14.5a52 52 0 0 1-9.8-30.4 54 54 0 0 1 1-14.7h-14.2c-11.5.2-23 .2-34.6-.1-12-.4-23.8-.9-35.7-2-5.2-.4-10.4-1.2-15.5-2-5-.6-10.6-1-15.3-3-.3 0-.2-.6 0-.6 5-1.7 10.8-1.4 16-1.7l5-.3L64 52l29.4-.6h4.3c11.5-.3 23-.4 34.6-.8l14.4-.7c.6-1.3 1.4-2.4 2.2-3.6a64.5 64.5 0 0 1 30-21.5c8-2.7 19.5-4 27.9-3.9 8.4.2 20.3 1.4 24.2 8.2.4.7 7.7-.6 9.9-2.3 5-3.9 10-7.8 14.9-12 9-7.5 18.4-15 27-23.1a744.6 744.6 0 0 0 38.7-39c4.2-4.7 7.8-10.3 13.9-12.4Z" fill="#000"/>`,
|
package/lib/components/face.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/TArMPV7hXUhdCbfEFs3Pfm
|
|
5
|
+
* File: https://www.figma.com/file/TArMPV7hXUhdCbfEFs3Pfm
|
|
6
6
|
*/
|
|
7
7
|
import type { ComponentGroup } from '../types.js';
|
|
8
8
|
export declare const face: ComponentGroup;
|
package/lib/components/face.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/TArMPV7hXUhdCbfEFs3Pfm
|
|
5
|
+
* File: https://www.figma.com/file/TArMPV7hXUhdCbfEFs3Pfm
|
|
6
6
|
*/
|
|
7
7
|
export const face = {
|
|
8
8
|
'angryWithFang': (components, colors) => `<path fill-rule="evenodd" clip-rule="evenodd" d="M196.5 186c1.5-2 5.1 6.4 5.9 7.4 3.2 4 5.8 9.9 6.2 14.9v.4l15.4-2.2c2-1.5 4.8-1 7.5.3 6 3 3 12.7-3.4 12.5-17.5-.4-35.3 1.8-52.7 3.9-8.9 1-17.8 2-26.6 3.5-8.3 1.3-16.8 3.2-25.2 3.5-.4 0-.6-.6-.2-.8 7.4-3.8 15.8-6.1 23.8-8.4a344.1 344.1 0 0 1 49.8-10.7l-.2-.4c-1-3.4-1-7.3-1.2-10.8l-.1-2c-.2-3.2-.4-9.3 1-11.2Zm-25.7-41.6c7.6 4.6 19 15.3 11 26.6-9.6 10-23.4-1.4-30.2-6.6-6.3-4-13.3 6.3-7.5 11 49 36.3 69-29.8 30.5-36.4-4.2-.8-5.8 4-3.8 5.4ZM49.4 104c12.6-2 25.4-2.2 38.1-1.5a404.7 404.7 0 0 1 30 2.6c2.5.3 6.3 1.7 8.7 1 7.1-1.9 13.9 4.9 12 12-2 7-10.4 9-15.8 4.7-2.5-1-5-1.8-7.7-2.5-.2.8-.5 1.6-.9 2.3l-1.3 2.7-.6 1.5-.6 1.5c-1 2.5-2 4.8-4.6 6.1-3.6 1.8-9.2.8-10.7-3.4-2.3-4.5-.8-10.7.5-15.3l.1-.3C81 111.6 65 108.8 49.4 105c-.5-.2-.6-1 0-1.1ZM236 87.2c.8-1.6 2.7-1.6 3.8 0 2.4 3.3-3 8.2-5.4 10.5l-.2.2a91.4 91.4 0 0 1-21.6 15.5l.7 1.6c1 2.6 1 5.8 0 8.5-1.7 5.6-6.4 10-12.5 10-3.2 0-7-3-6.6-6.5l.5-4c-4.3 1.4-9.5-.2-12.3-3.8-3.7-4.9-2.7-13 3.1-16 4.3-2.2 9-2.8 13.6-4 4.6-1.1 9.2-2.5 13.6-4l13.3-4.6 6.5-2.2c1-.3 2.4-1 3.5-1.2Z" fill="#000"/>`,
|
|
@@ -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/TArMPV7hXUhdCbfEFs3Pfm
|
|
5
|
+
* File: https://www.figma.com/file/TArMPV7hXUhdCbfEFs3Pfm
|
|
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/TArMPV7hXUhdCbfEFs3Pfm
|
|
5
|
+
* File: https://www.figma.com/file/TArMPV7hXUhdCbfEFs3Pfm
|
|
6
6
|
*/
|
|
7
7
|
import { escape } from '@dicebear/core';
|
|
8
8
|
export const facialHair = {
|
package/lib/components/head.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/TArMPV7hXUhdCbfEFs3Pfm
|
|
5
|
+
* File: https://www.figma.com/file/TArMPV7hXUhdCbfEFs3Pfm
|
|
6
6
|
*/
|
|
7
7
|
import type { ComponentGroup } from '../types.js';
|
|
8
8
|
export declare const head: ComponentGroup;
|
package/lib/components/head.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/TArMPV7hXUhdCbfEFs3Pfm
|
|
5
|
+
* File: https://www.figma.com/file/TArMPV7hXUhdCbfEFs3Pfm
|
|
6
6
|
*/
|
|
7
7
|
import { escape } from '@dicebear/core';
|
|
8
8
|
export const head = {
|
|
@@ -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/TArMPV7hXUhdCbfEFs3Pfm
|
|
5
|
+
* File: https://www.figma.com/file/TArMPV7hXUhdCbfEFs3Pfm
|
|
6
6
|
*/
|
|
7
7
|
export { head } from './head.js';
|
|
8
8
|
export { face } from './face.js';
|
package/lib/components/index.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/TArMPV7hXUhdCbfEFs3Pfm
|
|
5
|
+
* File: https://www.figma.com/file/TArMPV7hXUhdCbfEFs3Pfm
|
|
6
6
|
*/
|
|
7
7
|
export { head } from './head.js';
|
|
8
8
|
export { face } from './face.js';
|
package/lib/components/mask.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/TArMPV7hXUhdCbfEFs3Pfm
|
|
5
|
+
* File: https://www.figma.com/file/TArMPV7hXUhdCbfEFs3Pfm
|
|
6
6
|
*/
|
|
7
7
|
import type { ComponentGroup } from '../types.js';
|
|
8
8
|
export declare const mask: ComponentGroup;
|
package/lib/components/mask.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/TArMPV7hXUhdCbfEFs3Pfm
|
|
5
|
+
* File: https://www.figma.com/file/TArMPV7hXUhdCbfEFs3Pfm
|
|
6
6
|
*/
|
|
7
7
|
export const mask = {
|
|
8
8
|
'medicalMask': (components, colors) => `<g fill-rule="evenodd" clip-rule="evenodd"><path d="M393.3 70.4c-2-24-32-34-47-37-50-11.8-92.5 18.3-152 19-6 0-23.2-1-31.2-3C122.5 40 82 30.3 42 18.1c-5.8 1.4-7.5 9-3.5 13.4 38.1 13.5 96.5 25.6 127.2 27a135.3 135.3 0 0 1-50.5 101.8c46 51 153.6 67.7 217 41 31-9.4 64-93 61-131" fill="#fff"/><path d="M39 19.4c-1.7 0-.7-5 3.1-4.3 49.9 11.6 112 33.8 163.2 33.7 37.7-1.3 71.5-22.3 109.4-22.4 25.4.5 58 4.1 75.7 24.6C414 125.5 361 227 277.7 227.6l-15.8-1.2c-53.7-4-112.6-10.3-147.3-55.9l-.2.3c-5.2-3.5-5-11-.5-14.9v.2l.4-.4v-.2c1.6-1.7 3.5-3.4 5.3-4.9 26-21.6 43-54.4 44-88.3C155 64.6 10.3 34.6 36 27.3A623.8 623.8 0 0 0 93 44a549 549 0 0 0 70.5 11.6l-.1-3.4C121.3 44 80 31.7 39 19.4Zm341 30.3c-86.3-43.7-129.2 20.8-212.8 3 8.8 39-12.8 81.1-42.1 106.6 42.6 36.9 61 42.5 116.9 48.5l7.3.8c11 1.3 22 2.5 33 2.7 57.2-4.1 100.3-63.6 106.8-117.4v-1.5c.3-13.7-.3-28.1-6.4-40.6-1-.4-2-1.1-2.6-2.1ZM259.9 84c3-.7 6 2.5 4.2 5.4-6 9.2-20.6 12.8-30.9 14.2a71.2 71.2 0 0 1-34.5-3.6c-.6-.3-.6-1.3.1-1.2 10.7 1.2 21.7.3 32.1-2.5 10.5-2 19-9 29-12.3Zm81.2-6.7c0-1.7 8.6 3.3 10 4 10.4 6.3 22.6 6.8 34.2 9.3 2.7 1 2.7 4.5 0 5.5-14.5 3.8-36.4-6.3-44.2-18.8Z" fill="#000"/></g>`,
|
|
@@ -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/TArMPV7hXUhdCbfEFs3Pfm
|
|
5
|
+
* File: https://www.figma.com/file/TArMPV7hXUhdCbfEFs3Pfm
|
|
6
6
|
*/
|
|
7
7
|
import { Prng, StyleOptions } from "@dicebear/core";
|
|
8
8
|
import { Options, ColorPickCollection, ComponentPickCollection } from "../types.js";
|
|
9
|
-
|
|
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/TArMPV7hXUhdCbfEFs3Pfm
|
|
5
|
+
* File: https://www.figma.com/file/TArMPV7hXUhdCbfEFs3Pfm
|
|
6
6
|
*/
|
|
7
7
|
export function onPostCreate({ prng, options, components, colors }) {
|
|
8
8
|
// Write your modifications here
|
|
@@ -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/TArMPV7hXUhdCbfEFs3Pfm
|
|
5
|
+
* File: https://www.figma.com/file/TArMPV7hXUhdCbfEFs3Pfm
|
|
6
6
|
*/
|
|
7
7
|
import { Prng, StyleOptions } from "@dicebear/core";
|
|
8
8
|
import { Options } from "../types.js";
|
|
9
|
-
|
|
9
|
+
type Props = {
|
|
10
10
|
prng: Prng;
|
|
11
11
|
options: StyleOptions<Options>;
|
|
12
12
|
};
|
package/lib/hooks/onPreCreate.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/TArMPV7hXUhdCbfEFs3Pfm
|
|
5
|
+
* File: https://www.figma.com/file/TArMPV7hXUhdCbfEFs3Pfm
|
|
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/TArMPV7hXUhdCbfEFs3Pfm
|
|
5
|
+
* File: https://www.figma.com/file/TArMPV7hXUhdCbfEFs3Pfm
|
|
6
6
|
*/
|
|
7
|
-
|
|
8
|
-
|
|
7
|
+
/*!
|
|
8
|
+
* Open Peeps (@dicebear/open-peeps)
|
|
9
|
+
*
|
|
10
|
+
* Code licensed under MIT License.
|
|
11
|
+
* Copyright (c) 2023 Florian Körner
|
|
12
|
+
*
|
|
13
|
+
* Design "Open Peeps" by Pablo Stanley licensed under CC0 1.0. / Remix of the original.
|
|
14
|
+
* Source: https://www.openpeeps.com/
|
|
15
|
+
* Homepage: https://twitter.com/pablostanley
|
|
16
|
+
* License: https://creativecommons.org/publicdomain/zero/1.0/
|
|
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,36 @@
|
|
|
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/TArMPV7hXUhdCbfEFs3Pfm
|
|
5
|
+
* File: https://www.figma.com/file/TArMPV7hXUhdCbfEFs3Pfm
|
|
6
6
|
*/
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
7
|
+
import { escape } from '@dicebear/core';
|
|
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 meta = {
|
|
13
|
+
title: 'Open Peeps',
|
|
14
|
+
creator: 'Pablo Stanley',
|
|
15
|
+
source: 'https://www.openpeeps.com/',
|
|
16
|
+
homepage: 'https://twitter.com/pablostanley',
|
|
17
|
+
license: {
|
|
18
|
+
name: 'CC0 1.0',
|
|
19
|
+
url: 'https://creativecommons.org/publicdomain/zero/1.0/',
|
|
20
|
+
},
|
|
21
|
+
};
|
|
22
|
+
export const create = ({ prng, options }) => {
|
|
23
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
24
|
+
onPreCreate({ prng, options });
|
|
25
|
+
const components = getComponents({ prng, options });
|
|
26
|
+
const colors = getColors({ prng, options });
|
|
27
|
+
onPostCreate({ prng, options, components, colors });
|
|
28
|
+
return {
|
|
29
|
+
attributes: {
|
|
30
|
+
viewBox: '0 0 704 704',
|
|
31
|
+
fill: 'none',
|
|
32
|
+
'shape-rendering': 'auto'
|
|
33
|
+
},
|
|
34
|
+
body: `<g fill-rule="evenodd" clip-rule="evenodd"><path d="M705.3 1074a2351.1 2351.1 0 0 1-15.6-101c-1-7.7-2.5-16.4 2.7-22 7.3-8 14-14.8 14.8-26.2.8-10.7-2.8-22.4-5-32.8a809.4 809.4 0 0 0-17.3-64.7c-6.6-21.7-13.9-43.2-21.3-64.6-6.9-20-13.5-40.3-22.5-59.5-17-36.5-46-63.5-81.6-81.6-9-4.5-27-20.5-36.3-24-8.5-3.4-8.5 6.3-16.9 2.6-6.7-2.9-13-6.7-16.7-13.2-4-7-14.3-16.9-15.9-25-3.3-17.4.3-32.2-12-45.3a90 90 0 0 0-41.1-23.8c-33.7-9.3-78.5-2.8-98.8 28.5-9.7 14.9-13 33-26.2 45.1-11.4 10.7-8.8 18-23.6 23.4-.9.3-23.6-4.5-24.4-4.2-16.2-3.5-31.7 6.2-46.5 11.8a325.4 325.4 0 0 0-63 32.3 399.2 399.2 0 0 0-102.3 98.5 482.5 482.5 0 0 0-76.4 161c-1.7 6.4-3.5 13-1.5 19.4 1.7 5.3 5.4 9.2 9.8 12.4 6 4.3 18 7 17.7 15.7-.1 6.6-2.4 13.5-3.5 20-1.3 7.7-2.3 15.5-3.4 23.2-4.8 35.4-8.6 71-10.3 106.6a920 920 0 0 0-.5 106c.1 2.3.8 4.5 2 6.2-1 .4-1.2 2.4.1 2.7l2.7.5a12 12 0 0 0 7 2.4l5.5.2c19.3 4 38.6 7.9 58.1 10.8 23.8 3.5 47.6 6.3 71.5 8.7 49.2 4.8 98 3.2 147.1.6a1877 1877 0 0 1 147.4-2c49.2 1.4 98.4 3.5 147.6 4.4 55 1 110-.5 164.8-5 7.5-.5 12.2-6.5 10.7-14-8.9-44.7-19-89.1-27-134Z" fill="${escape.xml(`#${colors.skin}`)}"/><path d="m201 597.5 1.2-.4c14.5-5.7 29.6-14.8 45.4-11.4.5-.2 10.8 1.9 17.9 3.2l-6.7 7L247 598c40.7 67.1 88.8 100.7 144.3 100.7 55.5 0 97.7-33.6 126.4-100.7l4-1c.4 0 1 .2 1.5.4 9.3 3.6 27.4 19.6 36.3 24.1 35.6 18 64.5 45 81.6 81.6 8.7 18.6 15.2 38 21.8 57.5l.7 2c7.4 21.4 14.7 43 21.3 64.6 6.3 20.4 12 41 16.6 61.8l.7 2.9c2.2 10.4 5.8 22 5 32.8a29 29 0 0 1-3 10.7l-80.4 29 38.4 261.3c-35.1 1.5-70.3 2-105.5 1.3-49.2-.9-98.4-3-147.6-4.3-47.7-1.2-95.3-.7-143 1.7l-12 .6a946.3 946.3 0 0 1-139.5-1l-3.1-.3v-38.3l16.3-212.9-83-15.6-81.3-39.5a21.7 21.7 0 0 1-5.6-8.8c-1.9-6-.5-12 1-18l.5-1.3a492.8 492.8 0 0 1 76.4-161A399.3 399.3 0 0 1 138 629.7c19.8-13 40.9-23.9 63-32.3Z" fill="${escape.xml(`#${colors.clothing}`)}"/><path d="M232.2 584.6c5.1-.3 10.3.6 15.4 1 .4.1.6.8 0 .9-9 1.9-18 4.5-26.9 7.1l-3.8 1.2c-10 3-19.8 6-29.6 10-19.4 7.9-37.8 18.5-54.8 30.8C67.2 682.8 20 754.3-9.9 828.3a526 526 0 0 0-24.3 77c-.4 1.6-2 5.4-1 7 .7 1.3 3.6 2.1 5 2.9l4.5 2.3 25.2 12.9 2.3 1.1c38 18.6 78.4 34.4 121 35.5l.4-3.7a342 342 0 0 1 9.9-60c.3-1 1.6-.6 1.7.3 3 23.1 2 46.4 1 69.7-1.8 41-4.3 82.2-6.5 123.3-1.2 20.6-2.6 41-3.9 61.7-1.3 20.5-1.7 41.6-4.7 62-.6 4.6-6 7-10 6.6-4.4-.5-7.9-4.5-8-9 0-11.9 1.5-24 2.4-35.8l2.5-33.8c3.1-41.1 6.8-82.2 10.2-123.3a4771 4771 0 0 1 3.8-43.7C76.4 979.8 34.2 963-6.1 943.5c-.6 13.2-2 26.5-3.4 39.6-3.8 36.8-7.1 73.6-9.6 110.5a2254.2 2254.2 0 0 0-4.2 92.7l-.2 7c0 4.4-.5 8.5-4.3 11.7-3.7 3.3-8.9 3.5-12.6 0-5-4.6-4.2-10.9-4-17.1a1675.6 1675.6 0 0 1 1.8-47.2 1321 1321 0 0 1 10.5-109.5l2-14c3.5-26 7.5-52.7 15.5-77.9-3.1-1.5-6.2-3-9.3-4.7-5.5-2.7-11.2-5.4-16.6-8.4-4.2-2.5-7.9-5.8-9-10.8-1.4-5.5.6-11.5 2-16.9v-.4a502 502 0 0 1 26.6-80 523.2 523.2 0 0 1 67.8-117 353.8 353.8 0 0 1 88.7-83.3 239 239 0 0 1 53.8-25.7 142.6 142.6 0 0 1 42.8-7.5Zm90.1-66c6-6.5 18.1.2 15.2 8.8a108.2 108.2 0 0 1-34.7 52A79.4 79.4 0 0 1 247 598l1.7 2.4a321.1 321.1 0 0 0 46.1 52.6c36 31.2 84.8 48 132 36 37.1-9.4 69.8-38.8 79.4-76.2-1.3.6-3 .9-4.8.5-7.7-1.7-15.3-9.8-20.3-15.6-5.3-6.3-9.5-13-12.6-20.7-5.6-14-7.4-32.1.3-45.7 1-1.7 3-.7 3.3 1l.3 2.5c1.5 12.7 3.3 25 9.3 36.6a76 76 0 0 0 18.2 23.1c2.6 2 5.8 3.6 8.1 6l.5.4c.6-5 4.1-7.3 7.6-7.2 3.3.2 7.3 1.6 8.8 2.3l.1.1a341 341 0 0 1 65.1 42 259 259 0 0 1 88.4 129c7.5 25.3 11.8 51.4 16.3 77.4l2.8 16c4.2 23.9 8.9 48.4 18.4 70.7 2.5 5.7.6 11.1-5.5 13.4A1493 1493 0 0 1 688 953c3.7 16 6 32.5 8.7 48.5 6 34.1 13.2 68 19.4 102 3.2 17.5 6.1 35 9.3 52.3l4.7 25.2 2.4 13.6.1.7c.5 2.4 1 4.9.4 7.3-.8 2.7-2.9 4.6-4.8 6.6-1.6 1.6-3.8 1.6-5.7.7l-.7-.3c-3.4-1.6-6-3.2-7.3-7-.7-2.5-1-5.2-1.5-7.7a3535.6 3535.6 0 0 1-7.8-43.6l-1.6-9.1c-5.2-31.4-10.2-62.9-12.8-94.5-1-14-2.3-28.1-3.5-42.2l-.9-10.5c-1.1-13.3-2.5-27-2.7-40.5l-4.5 1.6L657 964c-5.5 2-12.5 6-18.4 5.2-2.9-.3-5-1.2-6.8-2.9 2 28.8 4.8 57.4 8.5 86a1965.7 1965.7 0 0 0 22 135c.6 3.2 1.4 6.4 1.9 9.6.5 3.7-.5 5.9-2.5 9-1.7 2.4-5 3.7-7.8 2-3.6-2.3-5.5-4.3-6.5-8.4-1-3.7-1.6-7.6-2.3-11.4a1654.2 1654.2 0 0 1-11.4-65.2c-7.8-52-12.7-104.4-15.2-156.8a1388 1388 0 0 1-1.4-77.8c0-13.3.5-26.6 1.4-39.9 1-13.4 3-26.5 4.8-39.8 0-.5.7-.5.7 0 .8 14.9 2.1 29.8 2.8 44.7.6 14.3.9 28.5 1.4 42.8.6 18.7 1.5 37.5 2.7 56.2a9.6 9.6 0 0 1 8.5-3.1c4.7-1 9.7-3.4 14.1-5l16.8-5.5 26.4-8.7a679 679 0 0 1-18-80.8l-2-12.3c-4-24.2-8.5-48.5-15.8-72a229.8 229.8 0 0 0-34.8-68.2 370.2 370.2 0 0 0-52.7-55.3C557 627 539.7 614 523 600c.1.9.2 2 0 3-3.5 25.9-17 50-35.8 67.9-37.7 36-93.6 43.4-142 26.5-46.7-16.3-88-55-102.6-102.8-.3-.8.8-1 1.3-.5l2.4 3.3c0-.4.2-.9.7-1a129 129 0 0 0 46.6-29.2 100.2 100.2 0 0 0 21.3-33.3l.4-1c1.7-5 3.2-10.2 7-14.2Z" fill="#000"/></g><g transform="matrix(.99789 0 0 1 156 62)">${(_b = (_a = components.head) === null || _a === void 0 ? void 0 : _a.value(components, colors)) !== null && _b !== void 0 ? _b : ''}</g><g transform="translate(315 248)">${(_d = (_c = components.face) === null || _c === void 0 ? void 0 : _c.value(components, colors)) !== null && _d !== void 0 ? _d : ''}</g><g transform="translate(279 400)">${(_f = (_e = components.facialHair) === null || _e === void 0 ? void 0 : _e.value(components, colors)) !== null && _f !== void 0 ? _f : ''}</g><g transform="translate(179 343)">${(_h = (_g = components.mask) === null || _g === void 0 ? void 0 : _g.value(components, colors)) !== null && _h !== void 0 ? _h : ''}</g><g transform="translate(203 303)">${(_k = (_j = components.accessories) === null || _j === void 0 ? void 0 : _j.value(components, colors)) !== null && _k !== void 0 ? _k : ''}</g>`,
|
|
35
|
+
};
|
|
36
|
+
};
|
|
37
|
+
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/TArMPV7hXUhdCbfEFs3Pfm
|
|
5
|
+
* File: https://www.figma.com/file/TArMPV7hXUhdCbfEFs3Pfm
|
|
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/TArMPV7hXUhdCbfEFs3Pfm
|
|
5
|
+
* File: https://www.figma.com/file/TArMPV7hXUhdCbfEFs3Pfm
|
|
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/TArMPV7hXUhdCbfEFs3Pfm
|
|
5
|
+
* File: https://www.figma.com/file/TArMPV7hXUhdCbfEFs3Pfm
|
|
6
6
|
*/
|
|
7
7
|
export interface Options {
|
|
8
8
|
head?: ('afro' | 'bangs' | 'bangs2' | 'bantuKnots' | 'bear' | 'bun' | 'bun2' | 'buns' | 'cornrows' | 'cornrows2' | 'dreads1' | 'dreads2' | 'flatTop' | 'flatTopLong' | 'grayBun' | 'grayMedium' | 'grayShort' | 'hatBeanie' | 'hatHip' | 'hijab' | 'long' | 'longAfro' | 'longBangs' | 'longCurly' | 'medium1' | 'medium2' | 'medium3' | 'mediumBangs' | 'mediumBangs2' | 'mediumBangs3' | 'mediumStraight' | 'mohawk' | 'mohawk2' | 'noHair1' | 'noHair2' | 'noHair3' | 'pomp' | 'shaved1' | 'shaved2' | 'shaved3' | 'short1' | 'short2' | 'short3' | 'short4' | 'short5' | 'turban' | 'twists' | 'twists2')[];
|
|
@@ -17,12 +17,12 @@ export interface Options {
|
|
|
17
17
|
clothingColor?: string[];
|
|
18
18
|
hairColor?: string[];
|
|
19
19
|
}
|
|
20
|
-
export
|
|
21
|
-
export
|
|
22
|
-
export
|
|
23
|
-
export
|
|
24
|
-
export
|
|
25
|
-
export
|
|
20
|
+
export type ColorPickCollection = Record<string, string>;
|
|
21
|
+
export type ComponentGroup = Record<string, ComponentGroupItem>;
|
|
22
|
+
export type ComponentGroupCollection = Record<string, ComponentGroup>;
|
|
23
|
+
export type ComponentGroupItem = (components: ComponentPickCollection, colors: ColorPickCollection) => string;
|
|
24
|
+
export type ComponentPickCollection = Record<string, ComponentPick>;
|
|
25
|
+
export type ComponentPick = {
|
|
26
26
|
name: string;
|
|
27
27
|
value: ComponentGroupItem;
|
|
28
28
|
} | 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/TArMPV7hXUhdCbfEFs3Pfm
|
|
5
|
+
* File: https://www.figma.com/file/TArMPV7hXUhdCbfEFs3Pfm
|
|
6
6
|
*/
|
|
7
7
|
export {};
|
package/lib/utils/getColors.d.ts
CHANGED
|
@@ -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/TArMPV7hXUhdCbfEFs3Pfm
|
|
5
|
+
* File: https://www.figma.com/file/TArMPV7hXUhdCbfEFs3Pfm
|
|
6
6
|
*/
|
|
7
7
|
import type { Prng } from '@dicebear/core';
|
|
8
8
|
import type { Options, ColorPickCollection } from '../types.js';
|
|
9
|
-
|
|
9
|
+
type Props = {
|
|
10
10
|
prng: Prng;
|
|
11
11
|
options: Options;
|
|
12
12
|
};
|
package/lib/utils/getColors.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/TArMPV7hXUhdCbfEFs3Pfm
|
|
5
|
+
* File: https://www.figma.com/file/TArMPV7hXUhdCbfEFs3Pfm
|
|
6
6
|
*/
|
|
7
7
|
export function getColors({ prng, options }) {
|
|
8
8
|
var _a, _b, _c, _d, _e, _f;
|
|
@@ -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/TArMPV7hXUhdCbfEFs3Pfm
|
|
5
|
+
* File: https://www.figma.com/file/TArMPV7hXUhdCbfEFs3Pfm
|
|
6
6
|
*/
|
|
7
7
|
import type { Prng } from '@dicebear/core';
|
|
8
8
|
import type { Options, ComponentPickCollection } from '../types.js';
|
|
9
|
-
|
|
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/TArMPV7hXUhdCbfEFs3Pfm
|
|
5
|
+
* File: https://www.figma.com/file/TArMPV7hXUhdCbfEFs3Pfm
|
|
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/TArMPV7hXUhdCbfEFs3Pfm
|
|
5
|
+
* File: https://www.figma.com/file/TArMPV7hXUhdCbfEFs3Pfm
|
|
6
6
|
*/
|
|
7
7
|
import type { Prng } from '@dicebear/core';
|
|
8
8
|
import type { ComponentPick } from '../types.js';
|
|
9
|
-
|
|
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/TArMPV7hXUhdCbfEFs3Pfm
|
|
5
|
+
* File: https://www.figma.com/file/TArMPV7hXUhdCbfEFs3Pfm
|
|
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/open-peeps",
|
|
3
|
-
"version": "5.0.0-beta.
|
|
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.
|
|
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": "
|
|
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/TArMPV7hXUhdCbfEFs3Pfm/%40dicebear%2Fopen-peeps?node-id=3%3A134
|
|
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,40 +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/TArMPV7hXUhdCbfEFs3Pfm/%40dicebear%2Fopen-peeps?node-id=3%3A134
|
|
6
|
-
*/
|
|
7
|
-
import { escape } from '@dicebear/core';
|
|
8
|
-
import { schema } from './schema.js';
|
|
9
|
-
import { getComponents } from './utils/getComponents.js';
|
|
10
|
-
import { getColors } from './utils/getColors.js';
|
|
11
|
-
import { onPreCreate } from './hooks/onPreCreate.js';
|
|
12
|
-
import { onPostCreate } from './hooks/onPostCreate.js';
|
|
13
|
-
export const style = {
|
|
14
|
-
meta: {
|
|
15
|
-
title: 'Open Peeps',
|
|
16
|
-
creator: 'Pablo Stanley',
|
|
17
|
-
source: 'https://www.openpeeps.com/',
|
|
18
|
-
homepage: 'https://twitter.com/pablostanley',
|
|
19
|
-
license: {
|
|
20
|
-
name: 'CC0 1.0',
|
|
21
|
-
url: 'https://creativecommons.org/publicdomain/zero/1.0/',
|
|
22
|
-
},
|
|
23
|
-
},
|
|
24
|
-
schema: schema,
|
|
25
|
-
create: ({ prng, options }) => {
|
|
26
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
27
|
-
onPreCreate({ prng, options });
|
|
28
|
-
const components = getComponents({ prng, options });
|
|
29
|
-
const colors = getColors({ prng, options });
|
|
30
|
-
onPostCreate({ prng, options, components, colors });
|
|
31
|
-
return {
|
|
32
|
-
attributes: {
|
|
33
|
-
viewBox: '0 0 704 704',
|
|
34
|
-
fill: 'none',
|
|
35
|
-
'shape-rendering': 'auto'
|
|
36
|
-
},
|
|
37
|
-
body: `<g fill-rule="evenodd" clip-rule="evenodd"><path d="M705.3 1074a2351.1 2351.1 0 0 1-15.6-101c-1-7.7-2.5-16.4 2.7-22 7.3-8 14-14.8 14.8-26.2.8-10.7-2.8-22.4-5-32.8a809.4 809.4 0 0 0-17.3-64.7c-6.6-21.7-13.9-43.2-21.3-64.6-6.9-20-13.5-40.3-22.5-59.5-17-36.5-46-63.5-81.6-81.6-9-4.5-27-20.5-36.3-24-8.5-3.4-8.5 6.3-16.9 2.6-6.7-2.9-13-6.7-16.7-13.2-4-7-14.3-16.9-15.9-25-3.3-17.4.3-32.2-12-45.3a90 90 0 0 0-41.1-23.8c-33.7-9.3-78.5-2.8-98.8 28.5-9.7 14.9-13 33-26.2 45.1-11.4 10.7-8.8 18-23.6 23.4-.9.3-23.6-4.5-24.4-4.2-16.2-3.5-31.7 6.2-46.5 11.8a325.4 325.4 0 0 0-63 32.3 399.2 399.2 0 0 0-102.3 98.5 482.5 482.5 0 0 0-76.4 161c-1.7 6.4-3.5 13-1.5 19.4 1.7 5.3 5.4 9.2 9.8 12.4 6 4.3 18 7 17.7 15.7-.1 6.6-2.4 13.5-3.5 20-1.3 7.7-2.3 15.5-3.4 23.2-4.8 35.4-8.6 71-10.3 106.6a920 920 0 0 0-.5 106c.1 2.3.8 4.5 2 6.2-1 .4-1.2 2.4.1 2.7l2.7.5a12 12 0 0 0 7 2.4l5.5.2c19.3 4 38.6 7.9 58.1 10.8 23.8 3.5 47.6 6.3 71.5 8.7 49.2 4.8 98 3.2 147.1.6a1877 1877 0 0 1 147.4-2c49.2 1.4 98.4 3.5 147.6 4.4 55 1 110-.5 164.8-5 7.5-.5 12.2-6.5 10.7-14-8.9-44.7-19-89.1-27-134Z" fill="${escape.xml(`#${colors.skin}`)}"/><path d="m201 597.5 1.2-.4c14.5-5.7 29.6-14.8 45.4-11.4.5-.2 10.8 1.9 17.9 3.2l-6.7 7L247 598c40.7 67.1 88.8 100.7 144.3 100.7 55.5 0 97.7-33.6 126.4-100.7l4-1c.4 0 1 .2 1.5.4 9.3 3.6 27.4 19.6 36.3 24.1 35.6 18 64.5 45 81.6 81.6 8.7 18.6 15.2 38 21.8 57.5l.7 2c7.4 21.4 14.7 43 21.3 64.6 6.3 20.4 12 41 16.6 61.8l.7 2.9c2.2 10.4 5.8 22 5 32.8a29 29 0 0 1-3 10.7l-80.4 29 38.4 261.3c-35.1 1.5-70.3 2-105.5 1.3-49.2-.9-98.4-3-147.6-4.3-47.7-1.2-95.3-.7-143 1.7l-12 .6a946.3 946.3 0 0 1-139.5-1l-3.1-.3v-38.3l16.3-212.9-83-15.6-81.3-39.5a21.7 21.7 0 0 1-5.6-8.8c-1.9-6-.5-12 1-18l.5-1.3a492.8 492.8 0 0 1 76.4-161A399.3 399.3 0 0 1 138 629.7c19.8-13 40.9-23.9 63-32.3Z" fill="${escape.xml(`#${colors.clothing}`)}"/><path d="M232.2 584.6c5.1-.3 10.3.6 15.4 1 .4.1.6.8 0 .9-9 1.9-18 4.5-26.9 7.1l-3.8 1.2c-10 3-19.8 6-29.6 10-19.4 7.9-37.8 18.5-54.8 30.8C67.2 682.8 20 754.3-9.9 828.3a526 526 0 0 0-24.3 77c-.4 1.6-2 5.4-1 7 .7 1.3 3.6 2.1 5 2.9l4.5 2.3 25.2 12.9 2.3 1.1c38 18.6 78.4 34.4 121 35.5l.4-3.7a342 342 0 0 1 9.9-60c.3-1 1.6-.6 1.7.3 3 23.1 2 46.4 1 69.7-1.8 41-4.3 82.2-6.5 123.3-1.2 20.6-2.6 41-3.9 61.7-1.3 20.5-1.7 41.6-4.7 62-.6 4.6-6 7-10 6.6-4.4-.5-7.9-4.5-8-9 0-11.9 1.5-24 2.4-35.8l2.5-33.8c3.1-41.1 6.8-82.2 10.2-123.3a4771 4771 0 0 1 3.8-43.7C76.4 979.8 34.2 963-6.1 943.5c-.6 13.2-2 26.5-3.4 39.6-3.8 36.8-7.1 73.6-9.6 110.5a2254.2 2254.2 0 0 0-4.2 92.7l-.2 7c0 4.4-.5 8.5-4.3 11.7-3.7 3.3-8.9 3.5-12.6 0-5-4.6-4.2-10.9-4-17.1a1675.6 1675.6 0 0 1 1.8-47.2 1321 1321 0 0 1 10.5-109.5l2-14c3.5-26 7.5-52.7 15.5-77.9-3.1-1.5-6.2-3-9.3-4.7-5.5-2.7-11.2-5.4-16.6-8.4-4.2-2.5-7.9-5.8-9-10.8-1.4-5.5.6-11.5 2-16.9v-.4a502 502 0 0 1 26.6-80 523.2 523.2 0 0 1 67.8-117 353.8 353.8 0 0 1 88.7-83.3 239 239 0 0 1 53.8-25.7 142.6 142.6 0 0 1 42.8-7.5Zm90.1-66c6-6.5 18.1.2 15.2 8.8a108.2 108.2 0 0 1-34.7 52A79.4 79.4 0 0 1 247 598l1.7 2.4a321.1 321.1 0 0 0 46.1 52.6c36 31.2 84.8 48 132 36 37.1-9.4 69.8-38.8 79.4-76.2-1.3.6-3 .9-4.8.5-7.7-1.7-15.3-9.8-20.3-15.6-5.3-6.3-9.5-13-12.6-20.7-5.6-14-7.4-32.1.3-45.7 1-1.7 3-.7 3.3 1l.3 2.5c1.5 12.7 3.3 25 9.3 36.6a76 76 0 0 0 18.2 23.1c2.6 2 5.8 3.6 8.1 6l.5.4c.6-5 4.1-7.3 7.6-7.2 3.3.2 7.3 1.6 8.8 2.3l.1.1a341 341 0 0 1 65.1 42 259 259 0 0 1 88.4 129c7.5 25.3 11.8 51.4 16.3 77.4l2.8 16c4.2 23.9 8.9 48.4 18.4 70.7 2.5 5.7.6 11.1-5.5 13.4A1493 1493 0 0 1 688 953c3.7 16 6 32.5 8.7 48.5 6 34.1 13.2 68 19.4 102 3.2 17.5 6.1 35 9.3 52.3l4.7 25.2 2.4 13.6.1.7c.5 2.4 1 4.9.4 7.3-.8 2.7-2.9 4.6-4.8 6.6-1.6 1.6-3.8 1.6-5.7.7l-.7-.3c-3.4-1.6-6-3.2-7.3-7-.7-2.5-1-5.2-1.5-7.7a3535.6 3535.6 0 0 1-7.8-43.6l-1.6-9.1c-5.2-31.4-10.2-62.9-12.8-94.5-1-14-2.3-28.1-3.5-42.2l-.9-10.5c-1.1-13.3-2.5-27-2.7-40.5l-4.5 1.6L657 964c-5.5 2-12.5 6-18.4 5.2-2.9-.3-5-1.2-6.8-2.9 2 28.8 4.8 57.4 8.5 86a1965.7 1965.7 0 0 0 22 135c.6 3.2 1.4 6.4 1.9 9.6.5 3.7-.5 5.9-2.5 9-1.7 2.4-5 3.7-7.8 2-3.6-2.3-5.5-4.3-6.5-8.4-1-3.7-1.6-7.6-2.3-11.4a1654.2 1654.2 0 0 1-11.4-65.2c-7.8-52-12.7-104.4-15.2-156.8a1388 1388 0 0 1-1.4-77.8c0-13.3.5-26.6 1.4-39.9 1-13.4 3-26.5 4.8-39.8 0-.5.7-.5.7 0 .8 14.9 2.1 29.8 2.8 44.7.6 14.3.9 28.5 1.4 42.8.6 18.7 1.5 37.5 2.7 56.2a9.6 9.6 0 0 1 8.5-3.1c4.7-1 9.7-3.4 14.1-5l16.8-5.5 26.4-8.7a679 679 0 0 1-18-80.8l-2-12.3c-4-24.2-8.5-48.5-15.8-72a229.8 229.8 0 0 0-34.8-68.2 370.2 370.2 0 0 0-52.7-55.3C557 627 539.7 614 523 600c.1.9.2 2 0 3-3.5 25.9-17 50-35.8 67.9-37.7 36-93.6 43.4-142 26.5-46.7-16.3-88-55-102.6-102.8-.3-.8.8-1 1.3-.5l2.4 3.3c0-.4.2-.9.7-1a129 129 0 0 0 46.6-29.2 100.2 100.2 0 0 0 21.3-33.3l.4-1c1.7-5 3.2-10.2 7-14.2Z" fill="#000"/></g><g transform="matrix(.99789 0 0 1 156 62)">${(_b = (_a = components.head) === null || _a === void 0 ? void 0 : _a.value(components, colors)) !== null && _b !== void 0 ? _b : ''}</g><g transform="translate(315 248)">${(_d = (_c = components.face) === null || _c === void 0 ? void 0 : _c.value(components, colors)) !== null && _d !== void 0 ? _d : ''}</g><g transform="translate(279 400)">${(_f = (_e = components.facialHair) === null || _e === void 0 ? void 0 : _e.value(components, colors)) !== null && _f !== void 0 ? _f : ''}</g><g transform="translate(179 343)">${(_h = (_g = components.mask) === null || _g === void 0 ? void 0 : _g.value(components, colors)) !== null && _h !== void 0 ? _h : ''}</g><g transform="translate(203 303)">${(_k = (_j = components.accessories) === null || _j === void 0 ? void 0 : _j.value(components, colors)) !== null && _k !== void 0 ? _k : ''}</g>`,
|
|
38
|
-
};
|
|
39
|
-
},
|
|
40
|
-
};
|