motionUtil.js 307 B

123456789101112131415
  1. "use strict";
  2. Object.defineProperty(exports, "__esModule", {
  3. value: true
  4. });
  5. exports.getMotion = getMotion;
  6. function getMotion(mode, motion, defaultMotions) {
  7. if (motion) {
  8. return motion;
  9. }
  10. if (defaultMotions) {
  11. return defaultMotions[mode] || defaultMotions.other;
  12. }
  13. return undefined;
  14. }