26 lines
598 B
JavaScript
26 lines
598 B
JavaScript
"use strict";
|
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
exports.Parallax = void 0;
|
|
class Parallax {
|
|
constructor() {
|
|
this.enable = false;
|
|
this.force = 2;
|
|
this.smooth = 10;
|
|
}
|
|
load(data) {
|
|
if (!data) {
|
|
return;
|
|
}
|
|
if (data.enable !== undefined) {
|
|
this.enable = data.enable;
|
|
}
|
|
if (data.force !== undefined) {
|
|
this.force = data.force;
|
|
}
|
|
if (data.smooth !== undefined) {
|
|
this.smooth = data.smooth;
|
|
}
|
|
}
|
|
}
|
|
exports.Parallax = Parallax;
|