Skip to content

Commit

Permalink
Add files via upload
Browse files Browse the repository at this point in the history
  • Loading branch information
parkmawani authored Mar 31, 2024
1 parent 61b3061 commit 485194e
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions scripts/background.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
import { Bokeh1Background } from 'https://cdn.jsdelivr.net/npm/[email protected]/build/backgrounds/bokeh1.cdn.min.js'

const bokeh1Background = Bokeh1Background(document.getElementById('webgl-canvas'))
bokeh1Background.loadMap('https://cdn.jsdelivr.net/npm/[email protected]/build/assets/bokeh-particles2.png')
bokeh1Background.setColors([0x6d4862, 0xfd826c, 0x22ccc1])

document.body.addEventListener('click', () => {
// bokeh1Background.setBackgroundColor(0xffffff * Math.random())
bokeh1Background.setColors([0xffffff * Math.random(), 0xffffff * Math.random(), 0xffffff * Math.random()])
})

0 comments on commit 485194e

Please sign in to comment.