Socket
Socket
Sign inDemoInstall

@dicebear/adventurer-neutral

Package Overview
Dependencies
Maintainers
2
Versions
122
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@dicebear/adventurer-neutral - npm Package Compare versions

Comparing version 5.0.0-alpha.11 to 5.0.0-alpha.12

lib/components/features.d.ts

5

lib/components/eyebrows.js

@@ -12,2 +12,7 @@ export const eyebrows = {

variant01: (components, colors) => `<path d="M613.54 401.51c1.6 1 1.08 2.86 1.24 4.48-.06 11.34-.05 22.7-.12 34.04.32 2.75-2.42 4.22-4.62 5-40 13.74-80.12 27.25-120.05 41.12-2.53.2-2.84-1.75-3.5-3.66-1.64-6-3.31-11.98-5.02-17.95.97 5.75.98 11.66 1.36 17.47-.02 1.44.45 3.94-1 4.85-1.94 1.4-4.06.13-4.59-2.03-3.64-12.73-7.02-25.58-10.66-38.32-.39-1.83-.65-3.9 1.36-4.88 2.11-.5 3.41.47 4 2.44 1.27 4.55 2.55 9.11 3.68 13.7-.73-5.24-.94-10.5-1.18-15.77 0-1.27-.14-3.73 1.66-3.8 1.47-.25 2.98-.37 4.43-.7 41.23-11.75 82.37-23.45 123.6-35.23 3.27-.87 6.02-2.08 9.4-.76ZM324 433.87c13.64 1.39 27.36 1.44 41 2.58 21.04 1.05 42.11 2.67 63.14 3.42 7.8.78 15.61 1.12 23.44 1.68 2.77 2.19 1.08 8.08 1.91 11.33.56-2.97.18-6.9 1.92-9.46a2.85 2.85 0 0 1 4.76 2.56c-2.36 14.03-4.77 28.14-7.02 42.18-.8 2.93-4.48 2.56-5.29-.15-.27-4.92-.21-9.89-.28-14.83-1.03 4.3-1.47 8.69-2.47 12.98-.42 1.64-1.16 2.84-3.1 2.4-39.47-6.89-79.39-14.23-118.86-21.3-1.88-.19-2.83-1.45-3.09-3.25-1.45-7.98-2.5-16.04-4.12-24-.23-1.7-.74-3.13.56-4.57 2.12-2.3 4.72-1.68 7.5-1.57Z" fill="#000"/>`,
variant15: (components, colors) => `<path d="M568.44 405.96c-.6-2.92-2.48-4.87-4.6-6.82-11.98-10.95-29.88-15.87-45.64-11.58-9.72 2.4-18.51 8.36-23.63 17.06-2.83 5.03-4.78 10.54-3.98 16.4.08.42.13.83.18 1.23.2 1.63.37 3 2.44 3.54 2.17.12 4.4-.29 6.54-.68l.31-.06 6.22-1.2c5.24-1 10.48-2 15.68-3.19a640.08 640.08 0 0 0 44.88-11.08c1.77-.25 1.7-1.62 1.63-3.02l-.03-.6ZM430.1 431.05c-.81-9.8-8.9-17.41-17.88-20.31a39.68 39.68 0 0 0-38.34 9.13c-4.45 4.18-8.39 9.97-9.12 16.14-.08 2.74 2.36 2.78 4.44 2.82.26 0 .52 0 .77.02 3.02-.08 6.05-.14 9.07-.2 9.34-.17 18.7-.35 27.98-1.3 2.4-.21 4.83-.38 7.24-.54 4.26-.3 8.52-.58 12.74-1.14 2.42.03 3.28-2.6 3.1-4.62Z" fill="#000"/>`,
variant14: (components, colors) => `<g fill="#222F05"><path d="M517.07 379.66c.86-.91 2.17-2.3 1.77-3.56-.35-2.45-3.58-3.11-5.22-1.46a221.7 221.7 0 0 0-8.34 7.33c-2.16 1.96-4.3 3.92-6.5 5.8a117.9 117.9 0 0 1-3.06 2.73c-2.64 2.3-5.21 4.56-7.32 7.5.33.33.6.68.88 1.02.72.9 1.4 1.74 2.73 1.81 1.5-.08 2.71-1.13 3.82-2.1l.41-.35c4.3-4 8.7-7.9 13.1-11.8 2.52-2.24 5.05-4.47 7.55-6.73l.06-.07.12-.12ZM539.69 378.66c.54-1.8-.18-2.95-1.6-4-2-.34-3.84.74-5.58 1.76-.44.26-.87.51-1.3.74-4.43 2.64-8.92 5.2-13.4 7.77-4.83 2.76-9.66 5.51-14.4 8.37-1.63.86-1.65 2.04-1.68 3.44 0 .45-.02.93-.08 1.42.46.1.9.24 1.31.38 1.2.4 2.27.75 3.58-.05 5.06-2.8 10.07-5.7 15.09-8.62a959.63 959.63 0 0 1 14.42-8.28c1.36-.8 2.87-1.67 3.65-2.94ZM566.39 378.4c2.1-.74 4.24.22 4.44 2.6-.08 2.3-1.76 2.9-3.53 3.51l-.77.28c-12.18 3.72-24.35 7.5-36.5 11.31-.37.09-.73.2-1.08.3-1.34.4-2.64.78-4 .08-1.82-1.26-1.8-4.32.36-5.22 1.8-.82 3.73-1.38 5.65-1.93a4048.39 4048.39 0 0 0 14.1-4.35c7.1-2.22 14.2-4.44 21.33-6.58ZM589.38 390.36c1.02-1.63.62-2.97-.45-4.43-2.25-.73-4.9-.11-7.4.47-.87.2-1.72.4-2.52.53-2.84.58-5.7 1.14-8.54 1.7h-.02c-4.14.81-8.27 1.62-12.4 2.5-1.87.47-3.69 1.64-3.1 3.87.65 2.02 2.02 2.45 4.03 2.12 4.01-.7 8-1.52 12-2.35 3.85-.8 7.7-1.6 11.56-2.27l1.3-.26c1.93-.36 4.05-.75 5.54-1.88ZM405.8 394.7c1.93 1.26 3.85 2.5 5.81 3.7.74.48 1.5.94 2.25 1.4 1.73 1.05 3.47 2.11 5 3.4 1.7 1.35 1.2 4.27-.83 5-1.8.35-3.06-.44-4.43-1.29l-.94-.56c-4.3-2.78-8.62-5.51-12.95-8.25l-4.17-2.64c-.1-.08-.22-.17-.35-.25l-.37-.27c-1.1-.75-2.42-1.66-2.4-2.93-.35-2.43 2.22-4.08 4.37-2.87 3.08 1.7 6.05 3.64 9.01 5.57Z"/><path d="M383.94 395.53a45.88 45.88 0 0 0-5.95-1.72c-2.5-.5-4.12 2.02-3.31 4.28 1.14 1.27 2.56 1.75 4.08 2.26l.4.14.32.1c4.02 1.26 8.03 2.55 12.03 3.85h.03c4.14 1.34 8.27 2.68 12.42 3.96 2.46.78 4.88.57 5.36-2.42-.17-2.11-2-2.8-3.72-3.44l-.15-.05-.23-.09-.5-.2c-6.06-1.95-12.14-3.89-18.22-5.83-.85-.26-1.7-.55-2.56-.84ZM587.13 395.34c3.45-.22 6.9-.28 10.37-.34 2.5-.05 5-.1 7.5-.2.4.03.84.03 1.3.03 1.67 0 3.6 0 4.35 1.53 1.26 1.74-.2 3.78-2.02 4.19-2.91.62-6.04.6-9.1.58-1.19 0-2.37-.01-3.53.02-1 0-2 .04-3 .07-1.68.05-3.36.1-5.04.04-1.22 0-3.12-.35-3.5-1.7a3 3 0 0 1 2.67-4.22ZM360.28 402.87c-2.04-.1-4.17-.2-6.08.32-1.5 1.2-1.47 3.44-.15 4.8 1.66.7 3.64.86 5.45 1l.16.01.32.03c3.43.16 6.85.37 10.27.58 3.92.25 7.83.49 11.74.66.85.02 1.72.1 2.6.18 1.84.18 3.72.35 5.44-.06a2.78 2.78 0 0 0 1.12-4.59c-.84-.99-1.87-1.05-2.98-1.12-.38-.03-.77-.05-1.16-.11l-12.51-.81-12.5-.81c-.57-.01-1.14-.04-1.73-.07ZM348.97 411.64l4.48-.33c4.19-.34 8.4-.68 12.56-.42 2.93.26 3.13 4.75.25 5.42-2.9.73-5.97.84-9.03.96-1.76.06-3.52.13-5.23.31-1.17.04-2.36.15-3.55.25-2.47.22-4.96.44-7.36.12-2.45-.43-2.74-4.43-.52-5.35 1.77-.65 3.79-.73 5.76-.8.9-.04 1.79-.07 2.64-.16ZM345.51 425.36c2.91-.95 2.78-5.26-.48-5.63-2.85.03-5.72.55-8.57 1.06-1.35.24-2.69.48-4.02.67-.74.18-1.6.3-2.52.4-2.27.28-4.78.6-6.04 2.18-1.16 2.39.53 4.6 3.07 4.38 6.17-.74 12.5-1.76 18.56-3.06Z"/></g>`,
variant13: (components, colors) => `<path d="M614 406.99c-24.74-23-58.3-35.43-92-35.08-8.9.26-17.67 1.52-26.42 3.12-1.5 3.24-2.51 6.6-3.52 9.98-.37 1.22-.73 2.44-1.12 3.66l-.13-1.4a170 170 0 0 0-1.31-11.32l-3.23-1.56c-.21.37-.5.74-.8 1.12-.6.76-1.23 1.55-1.26 2.44-.1 3.74.3 7.48.71 11.22.3 2.78.6 5.57.7 8.37.08.67.12 1.4.16 2.16.13 2.41.28 5.08 1.65 6.85 2.83.76 6.04-.34 9.02-1.36 1.06-.36 2.08-.7 3.05-.96 18.93-5.52 39.16-6.87 58.7-4.41 20 2.31 40.08 8.25 57.45 18.55 1.95 1.1 4 1.81 6.12 2.5l1.77-3.35c-2.7-3.96-6.05-7.28-9.54-10.53ZM422.26 399.6c.13-4.24.27-8.47.03-12.67-.25-2.54-1.86-2.58-3.72-2.62-.33 0-.66 0-1-.03-.92 3.61-1.06 7.52-1.21 11.37-.06 1.66-.13 3.3-.25 4.91a198.7 198.7 0 0 1-4.5-11.36c-.14-.25-.25-.54-.37-.83-.43-1.08-.9-2.26-2.24-2.23-2.5-.06-5.02.4-7.53.84-1.15.2-2.3.42-3.44.57-18.15 3.2-37.02 9.52-52.08 20.37-6.61 4.82-13.05 11.1-16.67 18.52-1.44 3.11-2.83 6.47-1.59 9.9l.41.12c1.08.33 2.6.8 3.42.06.93-.7 1.82-1.43 2.72-2.15 2.06-1.68 4.1-3.34 6.5-4.6 7.97-4.3 16.79-7.19 25.5-9.59 13.84-3.56 28.46-6.2 42.8-5.7 1.83.01 3.63.27 5.43.53 1.88.26 3.77.53 5.67.53 1.8-1.27 1.85-3.62 1.89-5.77 0-.62.02-1.2.07-1.76-.02-2.8.07-5.6.16-8.42Z" fill="#000"/>`,
variant12: (components, colors) => `<path d="M414.18 389.84c-5.5-7.26-14.52-9.33-23.2-8.38-13.12 1.9-24.56 8.53-34.46 17.08-10.76 9.47-19.88 21.7-24.72 35.27-.66 1.92-1.27 4.69 1.03 5.74 2.1.24 2.83.08 4.11-1.6 11.58-14.9 26.26-27.61 43.54-35.44 8.2-3.6 17.55-6.09 26.55-5.69 1.03.04 2.1.21 3.15.39 1.67.27 3.35.55 4.96.3 2.9-2.23.74-5.27-.86-7.53l-.1-.14ZM592.9 408.15c-18.2-10.23-38.04-17.1-58.92-18.97-10.05-.75-21.44-.2-30.72 4.09-6.76 3.16-12.37 8.56-13.57 16.22l-.12.95c-.38 2.89-.88 6.8 1.32 8.78 1.99.78 3.6-.34 5.23-1.46.74-.51 1.49-1.03 2.27-1.36 13.86-6.86 30.29-9.28 45.61-9.7 15.48.06 31.36 2.13 46.03 7.2l.48.13c1.46.4 2.74.74 3.89-.62 1.8-1.88.48-4.24-1.5-5.25Z" fill="#000"/>`,
variant11: (components, colors) => `<path d="M530.99 353.9c17.06 1.95 34 7.42 48.62 16.5 6.84 4.33 13.98 9.93 18.27 16.9.9 1.17 1.25 3.53-.22 4.34-1.19 1.18-2.85.5-4.15-.1-16.36-8.83-35.52-13.28-53.92-15.02-13.52-.79-28.3-.86-41.16 3.86-2.92 1.03-5.5 2.98-8.47 3.85-1.37.25-2.43-1.11-2.88-2.26-1.81-4.7-2.23-10.24.18-14.8 2.6-5.35 7.91-8.65 13.31-10.66 9.68-3.6 20.27-3.32 30.42-2.61ZM414.04 408.09c8.18 2.36 14.6 10.77 13.54 19.42-1.87.56-3.6 1-5.58.73-14.22-1.45-29.3 1.52-42.82 5.85-14.05 4.67-28.5 11.6-39.42 21.77-1.34 1.3-4.25 2.95-5.5.75-1.73-2.36.02-4.07 1.38-5.97 12.84-16.22 29.69-30.97 48.9-39.03 8.9-3.65 20.04-6.5 29.5-3.53Z" fill="#000"/>`,
};

3

lib/components/index.d.ts
export { eyes } from './eyes.js';
export { eyebrows } from './eyebrows.js';
export { mouth } from './mouth.js';
export { accessoires } from './accessoires.js';
export { features } from './features.js';
export { glasses } from './glasses.js';
export { eyes } from './eyes.js';
export { eyebrows } from './eyebrows.js';
export { mouth } from './mouth.js';
export { accessoires } from './accessoires.js';
export { features } from './features.js';
export { glasses } from './glasses.js';

@@ -19,3 +19,3 @@ import { schema } from './schema.js';

create: ({ prng, options }) => {
var _a, _b, _c, _d, _e, _f, _g, _h;
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
onPreCreate({ prng, options, preview: false });

@@ -32,3 +32,3 @@ const components = getComponents({ prng, options });

},
body: `<g transform="translate(-279 -322)">${(_b = (_a = components.eyes) === null || _a === void 0 ? void 0 : _a.value(components, colors)) !== null && _b !== void 0 ? _b : ''}</g><g transform="translate(-279 -322)">${(_d = (_c = components.eyebrows) === null || _c === void 0 ? void 0 : _c.value(components, colors)) !== null && _d !== void 0 ? _d : ''}</g><g transform="translate(-279 -322)">${(_f = (_e = components.mouth) === null || _e === void 0 ? void 0 : _e.value(components, colors)) !== null && _f !== void 0 ? _f : ''}</g><g transform="translate(-279 -322)">${(_h = (_g = components.accessoires) === null || _g === void 0 ? void 0 : _g.value(components, colors)) !== null && _h !== void 0 ? _h : ''}</g>`,
body: `<g transform="translate(-279 -322)">${(_b = (_a = components.eyes) === null || _a === void 0 ? void 0 : _a.value(components, colors)) !== null && _b !== void 0 ? _b : ''}</g><g transform="translate(-279 -322)">${(_d = (_c = components.eyebrows) === null || _c === void 0 ? void 0 : _c.value(components, colors)) !== null && _d !== void 0 ? _d : ''}</g><g transform="translate(-279 -322)">${(_f = (_e = components.mouth) === null || _e === void 0 ? void 0 : _e.value(components, colors)) !== null && _f !== void 0 ? _f : ''}</g><g transform="translate(-279 -322)">${(_h = (_g = components.features) === null || _g === void 0 ? void 0 : _g.value(components, colors)) !== null && _h !== void 0 ? _h : ''}</g><g transform="translate(-279 -322)">${(_k = (_j = components.glasses) === null || _j === void 0 ? void 0 : _j.value(components, colors)) !== null && _k !== void 0 ? _k : ''}</g>`,
};

@@ -35,0 +35,0 @@ },

@@ -14,6 +14,10 @@ export const dimensions = {

},
accessoires: {
features: {
width: 1024,
height: 1024,
},
glasses: {
width: 1024,
height: 1024,
},
};

@@ -5,37 +5,2 @@ export const schema = {

properties: {
accessoires: {
type: 'array',
items: {
type: 'string',
enum: [
'sunglasses',
'glasses',
'smallGlasses',
'mustache',
'blush',
'birthmark',
],
},
default: [
'sunglasses',
'glasses',
'smallGlasses',
'mustache',
'birthmark',
],
examples: [
['sunglasses'],
['glasses'],
['smallGlasses'],
['mustache'],
['blush'],
['birthmark'],
],
},
accessoiresProbability: {
type: 'integer',
minimum: 0,
maximum: 100,
default: 10,
},
backgroundColor: {

@@ -71,2 +36,7 @@ type: 'array',

'variant01',
'variant15',
'variant14',
'variant13',
'variant12',
'variant11',
],

@@ -85,2 +55,7 @@ },

'variant01',
'variant15',
'variant14',
'variant13',
'variant12',
'variant11',
],

@@ -98,2 +73,7 @@ examples: [

['variant01'],
['variant15'],
['variant14'],
['variant13'],
['variant12'],
['variant11'],
],

@@ -191,2 +171,41 @@ },

},
features: {
type: 'array',
items: { type: 'string', enum: ['blush', 'birthmark', 'freckles'] },
default: ['blush', 'birthmark', 'freckles'],
examples: [['blush'], ['birthmark'], ['freckles']],
},
featuresProbability: {
type: 'integer',
minimum: 0,
maximum: 100,
default: 5,
},
glasses: {
type: 'array',
items: {
type: 'string',
enum: ['variant01', 'variant02', 'variant03', 'variant04', 'variant05'],
},
default: [
'variant01',
'variant02',
'variant03',
'variant04',
'variant05',
],
examples: [
['variant01'],
['variant02'],
['variant03'],
['variant04'],
['variant05'],
],
},
glassesProbability: {
type: 'integer',
minimum: 0,
maximum: 100,
default: 10,
},
mouth: {

@@ -193,0 +212,0 @@ type: 'array',

export interface Options {
eyes?: ('variant26' | 'variant25' | 'variant24' | 'variant23' | 'variant22' | 'variant21' | 'variant20' | 'variant19' | 'variant18' | 'variant17' | 'variant16' | 'variant15' | 'variant14' | 'variant13' | 'variant12' | 'variant11' | 'variant10' | 'variant09' | 'variant08' | 'variant07' | 'variant06' | 'variant05' | 'variant04' | 'variant03' | 'variant02' | 'variant01')[];
eyebrows?: ('variant10' | 'variant09' | 'variant08' | 'variant07' | 'variant06' | 'variant05' | 'variant04' | 'variant03' | 'variant02' | 'variant01')[];
eyebrows?: ('variant10' | 'variant09' | 'variant08' | 'variant07' | 'variant06' | 'variant05' | 'variant04' | 'variant03' | 'variant02' | 'variant01' | 'variant15' | 'variant14' | 'variant13' | 'variant12' | 'variant11')[];
mouth?: ('variant30' | 'variant29' | 'variant28' | 'variant27' | 'variant26' | 'variant25' | 'variant24' | 'variant23' | 'variant22' | 'variant21' | 'variant20' | 'variant19' | 'variant18' | 'variant17' | 'variant16' | 'variant15' | 'variant14' | 'variant13' | 'variant12' | 'variant11' | 'variant10' | 'variant09' | 'variant08' | 'variant07' | 'variant06' | 'variant05' | 'variant04' | 'variant03' | 'variant02' | 'variant01')[];
accessoires?: ('sunglasses' | 'glasses' | 'smallGlasses' | 'mustache' | 'blush' | 'birthmark')[];
accessoiresProbability?: number;
features?: ('blush' | 'birthmark' | 'freckles')[];
featuresProbability?: number;
glasses?: ('variant01' | 'variant02' | 'variant03' | 'variant04' | 'variant05')[];
glassesProbability?: number;
backgroundColor?: string[];

@@ -8,0 +10,0 @@ }

@@ -18,7 +18,12 @@ import { pickComponent } from './pickComponent.js';

});
const accessoiresComponent = pickComponent({
const featuresComponent = pickComponent({
prng,
group: 'accessoires',
values: options.accessoires,
group: 'features',
values: options.features,
});
const glassesComponent = pickComponent({
prng,
group: 'glasses',
values: options.glasses,
});
return {

@@ -28,6 +33,9 @@ eyes: eyesComponent,

mouth: mouthComponent,
accessoires: prng.bool(options.accessoiresProbability)
? accessoiresComponent
features: prng.bool(options.featuresProbability)
? featuresComponent
: undefined,
glasses: prng.bool(options.glassesProbability)
? glassesComponent
: undefined,
};
}
{
"name": "@dicebear/adventurer-neutral",
"version": "5.0.0-alpha.11",
"version": "5.0.0-alpha.12",
"description": "Avatar style for DiceBear",

@@ -31,3 +31,3 @@ "keywords": [

"devDependencies": {
"@dicebear/core": "^5.0.0-alpha.11",
"@dicebear/core": "^5.0.0-alpha.12",
"@tsconfig/recommended": "^1.0.0",

@@ -48,3 +48,3 @@ "@types/jest": "^26.0.22",

},
"gitHead": "93e6f1be9fff392ded1f18c8320b6a0ca8e695c1"
"gitHead": "baa9eec32902faa13b4727237a99dbdba1f382c8"
}
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc