diff --git a/docs/api/device.md b/docs/api/device.md index 8c8782964..dca116c9e 100644 --- a/docs/api/device.md +++ b/docs/api/device.md @@ -12,12 +12,6 @@ * `widthMedia` **[String][1]?** The width which will be used in media queries, If empty the width will be used * `priority` **[Number][2]?** Setup the order of media queries -### getWidth - -Get device width. - -Returns **[String][1]** - [1]: https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String [2]: https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Number diff --git a/src/device_manager/model/Device.js b/src/device_manager/model/Device.js index 921ff23b1..0fc2aa7ce 100644 --- a/src/device_manager/model/Device.js +++ b/src/device_manager/model/Device.js @@ -1,7 +1,7 @@ import { Model } from 'backbone'; /** - * @typedef Component + * @typedef Device * @property {String} [name=''] Device type, eg. `Mobile` * @property {String} [width] Width to set for the editor iframe, eg. '900px' * @property {String} [height=''] Height to set for the editor iframe, eg. '600px' @@ -29,14 +29,6 @@ export default class Device extends Model { toCheck.forEach(prop => this.checkUnit(prop)); } - /** - * Get device width. - * @returns {String} - */ - getWidth() { - return this.get('width'); - } - checkUnit(prop) { const pr = this.get(prop) || ''; const noUnit = (parseFloat(pr) || 0).toString() === pr.toString();