UNPKG

@cloudinary/url-gen

Version:

Cloudinary URL-Gen SDK ========================= [![Build Status](https://api.travis-ci.com/cloudinary/js-url-gen.svg?branch=master)](https://app.travis-ci.com/github/cloudinary/js-url-gen) ## About The Cloudinary URL-Gen SDK allows you to quickly and eas

28 lines (24 loc) 1.04 kB
'use strict'; var LeveledEffectAction = require('./LeveledEffectAction-7af017df.cjs'); /** * @description Delivers a video or animated GIF that contains additional loops of the video/GIF. * @extends LeveledEffectAction * @memberOf Actions.Effect * @see Visit {@link Actions.Effect|Effect} for an example */ class LoopEffectAction extends LeveledEffectAction.LeveledEffectAction { additionalIterations(value) { this._actionModel.iterations = value; const qualifierEffect = this.createEffectQualifier(this.effectType, value); this.addQualifier(qualifierEffect); return this; } static fromJson(actionModel) { const { actionType, iterations } = (actionModel); // We are using this() to allow inheriting classes to use super.fromJson.apply(this, [actionModel]) // This allows the inheriting classes to determine the class to be created const result = new this(actionType, iterations); return result; } } exports.LoopEffectAction = LoopEffectAction;