Skip to content

Commit be2c23f

Browse files
authored
Merge pull request #1345 from demc/master
Includes p5.js as a default library.
2 parents 3b25978 + f47bff1 commit be2c23f

4 files changed

Lines changed: 341 additions & 0 deletions

File tree

bower.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@
3333
"lodash": "^4.11.2",
3434
"mustache.js": "mustache#^2.2.1",
3535
"normalize-css": "normalize.css#^4.1.1",
36+
"p5js": "^0.5.13",
3637
"react": "^15.0.1",
3738
"roboto-webfont-bower": "roboto-webfont#^0.1.1",
3839
"underscore": "^1.8.3"

src/config/libraries.js

Lines changed: 330 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,4 +15,334 @@ export default {
1515
name: 'Bootstrap',
1616
dependsOn: ['jquery'],
1717
},
18+
p5: {
19+
name: 'p5.js',
20+
predefined: [
21+
'ADD',
22+
'ALT',
23+
'ARROW',
24+
'AUTO',
25+
'BACKSPACE',
26+
'BASELINE',
27+
'BEVEL',
28+
'BEZIER',
29+
'BLEND',
30+
'BOLD',
31+
'BOTTOM',
32+
'BURN',
33+
'CENTER',
34+
'CHORD',
35+
'CLOSE',
36+
'CONTROL',
37+
'CORNER',
38+
'CORNERS',
39+
'CROSS',
40+
'CURVE',
41+
'DARKEST',
42+
'DEGREES',
43+
'DELETE',
44+
'DIFFERENCE',
45+
'DODGE',
46+
'DOWN_ARROW',
47+
'ENTER',
48+
'ESCAPE',
49+
'EXCLUSION',
50+
'HALF_PI',
51+
'HAND',
52+
'HARD_LIGHT',
53+
'HSB',
54+
'ITALIC',
55+
'LEFT',
56+
'LEFT_ARROW',
57+
'LIGHTEST',
58+
'LINEAR',
59+
'LINES',
60+
'MITER',
61+
'MOVE',
62+
'MULTIPLY',
63+
'NORMAL',
64+
'OPEN',
65+
'OPTION',
66+
'OVERLAY',
67+
'PI',
68+
'PIE',
69+
'POINTS',
70+
'PROJECT',
71+
'QUADRATIC',
72+
'QUADS',
73+
'QUAD_STRIP',
74+
'QUARTER_PI',
75+
'RADIANS',
76+
'RADIUS',
77+
'REPLACE',
78+
'RETURN',
79+
'RGB',
80+
'RIGHT',
81+
'RIGHT_ARROW',
82+
'ROUND',
83+
'SCREEN',
84+
'SHIFT',
85+
'SOFT_LIGHT',
86+
'SQUARE',
87+
'TAB',
88+
'TAU',
89+
'TEXT',
90+
'TOP',
91+
'TRIANGLES',
92+
'TRIANGLE_FAN',
93+
'TRIANGLE_STRIP',
94+
'TWO_PI',
95+
'UP_ARROW',
96+
'WAIT',
97+
'abs',
98+
'acos',
99+
'alpha',
100+
'angleMode',
101+
'append',
102+
'applyMatrix',
103+
'arc',
104+
'arrayCopy',
105+
'asin',
106+
'atan',
107+
'atan2',
108+
'background',
109+
'beginContour',
110+
'beginRaw',
111+
'beginRecord',
112+
'beginShape',
113+
'bezier',
114+
'bezierDetail',
115+
'bezierPoint',
116+
'bezierTangent',
117+
'bezierVertex',
118+
'blend',
119+
'blendMode',
120+
'blue',
121+
'brightness',
122+
'ceil',
123+
'clear',
124+
'color',
125+
'colorMode',
126+
'concat',
127+
'constrain',
128+
'copy',
129+
'cos',
130+
'createCanvas',
131+
'createGraphics',
132+
'createImage',
133+
'createInput',
134+
'createOutput',
135+
'createReader',
136+
'createVector',
137+
'createWriter',
138+
'cursor',
139+
'curve',
140+
'curveDetail',
141+
'curvePoint',
142+
'curveTangent',
143+
'curveTightness',
144+
'curveVertex',
145+
'day',
146+
'degrees',
147+
'devicePixelScaling',
148+
'displayHeight',
149+
'displayWidth',
150+
'dist',
151+
'downloadFile',
152+
'draw',
153+
'ellipse',
154+
'ellipseMode',
155+
'endContour',
156+
'endRaw',
157+
'endRecord',
158+
'endShape',
159+
'exit',
160+
'exp',
161+
'fill',
162+
'filter',
163+
'float',
164+
'floor',
165+
'focused',
166+
'frameCount',
167+
'frameRate',
168+
'fullscreen',
169+
'get',
170+
'getFrameRate',
171+
'getURL',
172+
'getURLParams',
173+
'getURLPath',
174+
'green',
175+
'height',
176+
'hour',
177+
'httpDo',
178+
'httpGet',
179+
'httpPost',
180+
'hue',
181+
'image',
182+
'imageMode',
183+
'int',
184+
'isKeyPressed',
185+
'isMousePressed',
186+
'join',
187+
'key',
188+
'keyCode',
189+
'keyIsDown',
190+
'keyIsPressed',
191+
'lerp',
192+
'lerpColor',
193+
'line',
194+
'loadBytes',
195+
'loadImage',
196+
'loadJSON',
197+
'loadPixels',
198+
'loadStrings',
199+
'loadTable',
200+
'loadXML',
201+
'log',
202+
'loop',
203+
'mag',
204+
'map',
205+
'match',
206+
'matchAll',
207+
'max',
208+
'millis',
209+
'min',
210+
'minute',
211+
'month',
212+
'mouseButton',
213+
'mouseIsPressed',
214+
'mouseX',
215+
'mouseY',
216+
'nf',
217+
'nfc',
218+
'nfp',
219+
'nfs',
220+
'noCanvas',
221+
'noCursor',
222+
'noFill',
223+
'noLoop',
224+
'noSmooth',
225+
'noStroke',
226+
'noTint',
227+
'noise',
228+
'noiseDetail',
229+
'noiseSeed',
230+
'norm',
231+
'onblur',
232+
'onclick',
233+
'onkeydown',
234+
'onkeypress',
235+
'onkeyup',
236+
'onmousedown',
237+
'onmousemove',
238+
'onmouseup',
239+
'onmousewheel',
240+
'onresize',
241+
'ontouchend',
242+
'ontouchmove',
243+
'ontouchstart',
244+
'parseXML',
245+
'pixels',
246+
'pmouseX',
247+
'pmouseY',
248+
'point',
249+
'pop',
250+
'popMatrix',
251+
'popStyle',
252+
'pow',
253+
'print',
254+
'printMatrix',
255+
'println',
256+
'ptouchX',
257+
'ptouchY',
258+
'push',
259+
'pushMatrix',
260+
'pushStyle',
261+
'pwinMouseX',
262+
'pwinMouseY',
263+
'quad',
264+
'quadraticVertex',
265+
'radians',
266+
'random',
267+
'randomGaussian',
268+
'randomSeed',
269+
'rect',
270+
'rectMode',
271+
'red',
272+
'redraw',
273+
'registerMethod',
274+
'registerPreloadMethod',
275+
'resetMatrix',
276+
'resizeCanvas',
277+
'reverse',
278+
'rotate',
279+
'rotateX',
280+
'rotateY',
281+
'round',
282+
'saturation',
283+
'save',
284+
'saveBytes',
285+
'saveCanvas',
286+
'saveFrames',
287+
'saveJSON',
288+
'saveJSONArray',
289+
'saveJSONObject',
290+
'saveStream',
291+
'saveStrings',
292+
'saveTable',
293+
'saveXML',
294+
'scale',
295+
'second',
296+
'selectFolder',
297+
'selectInput',
298+
'selectOutput',
299+
'set',
300+
'setFrameRate',
301+
'setup',
302+
'shearX',
303+
'shearY',
304+
'shorten',
305+
'sin',
306+
'size',
307+
'smooth',
308+
'sort',
309+
'splice',
310+
'split',
311+
'splitTokens',
312+
'sq',
313+
'sqrt',
314+
'stroke',
315+
'strokeCap',
316+
'strokeJoin',
317+
'strokeWeight',
318+
'subset',
319+
'tan',
320+
'text',
321+
'textAlign',
322+
'textAscent',
323+
'textDescent',
324+
'textFont',
325+
'textLeading',
326+
'textSize',
327+
'textStyle',
328+
'textWidth',
329+
'tint',
330+
'touchIsDown',
331+
'touchX',
332+
'touchY',
333+
'touches',
334+
'translate',
335+
'triangle',
336+
'trim',
337+
'updatePixels',
338+
'vertex',
339+
'width',
340+
'winMouseX',
341+
'winMouseY',
342+
'windowHeight',
343+
'windowWidth',
344+
'writeFile',
345+
'year',
346+
],
347+
},
18348
};

src/config/libraryAssets.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ import BOOTSTRAP_CSS from
77
'../../bower_components/bootstrap/dist/css/bootstrap.min.css';
88
import BOOTSTRAP_JS from
99
'../../bower_components/bootstrap/dist/js/bootstrap.min.js';
10+
import P5 from '../../bower_components/p5js/lib/p5.min.js';
1011

1112
export const jquery = {javascript: JQUERY};
1213

@@ -15,3 +16,5 @@ export const lodash = {javascript: LODASH};
1516
export const mustache = {javascript: MUSTACHE};
1617

1718
export const bootstrap = {css: BOOTSTRAP_CSS, javascript: BOOTSTRAP_JS};
19+
20+
export const p5 = {javascript: P5};

yarn.lock

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6368,6 +6368,10 @@ no-case@^2.2.0:
63686368
dependencies:
63696369
lower-case "^1.1.1"
63706370

6371+
node-bin-setup@^1.0.0:
6372+
version "1.0.6"
6373+
resolved "https://registry.yarnpkg.com/node-bin-setup/-/node-bin-setup-1.0.6.tgz#4b5c9bb937ece702d7069b36ca78af4684677528"
6374+
63716375
node-fetch@1.6.3:
63726376
version "1.6.3"
63736377
resolved "https://registry.yarnpkg.com/node-fetch/-/node-fetch-1.6.3.tgz#dc234edd6489982d58e8f0db4f695029abcd8c04"
@@ -6476,6 +6480,9 @@ node-static@^0.7.9:
64766480
mime "^1.2.9"
64776481
optimist ">=0.3.4"
64786482

6483+
node@^9.4.0:
6484+
version "9.4.0"
6485+
64796486
nopt@3.0.x:
64806487
version "3.0.6"
64816488
resolved "https://registry.yarnpkg.com/nopt/-/nopt-3.0.6.tgz#c6465dbf08abcd4db359317f79ac68a646b28ff9"

0 commit comments

Comments
 (0)