Improve bubble animation effect
This commit is contained in:
@@ -3,6 +3,13 @@ import { nextFrame } from "helpers/timing_helpers"
|
||||
|
||||
export default class extends Controller {
|
||||
static classes = [ "play" ]
|
||||
static values = { playOnLoad: { type: Boolean, default: false } }
|
||||
|
||||
connect() {
|
||||
if (this.playOnLoadValue) {
|
||||
this.play()
|
||||
}
|
||||
}
|
||||
|
||||
async play() {
|
||||
await nextFrame()
|
||||
|
||||
Reference in New Issue
Block a user