init commit
This commit is contained in:
19
remotion/node_modules/@remotion/studio/dist/state/playbackrate.js
generated
vendored
Normal file
19
remotion/node_modules/@remotion/studio/dist/state/playbackrate.js
generated
vendored
Normal file
@@ -0,0 +1,19 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
exports.loadPlaybackRate = exports.persistPlaybackRate = void 0;
|
||||
const key = 'remotion.playbackrate';
|
||||
const persistPlaybackRate = (option) => {
|
||||
localStorage.setItem(key, String(option));
|
||||
};
|
||||
exports.persistPlaybackRate = persistPlaybackRate;
|
||||
const loadPlaybackRate = () => {
|
||||
if (typeof window !== 'undefined') {
|
||||
return 1;
|
||||
}
|
||||
const item = localStorage.getItem(key);
|
||||
if (item === null) {
|
||||
return 1;
|
||||
}
|
||||
return Number(item);
|
||||
};
|
||||
exports.loadPlaybackRate = loadPlaybackRate;
|
||||
Reference in New Issue
Block a user