execute(graphics, dimension) {
    return new Promise((resolve) => {
      this.undoData.size = {
        width: graphics.cssMaxWidth,
        height: graphics.cssMaxHeight,
      };

      graphics.setCssMaxDimension(dimension);
      graphics.adjustCanvasDimension();
      resolve();
    });
  }
resize the canvas with given dimension
@param {Graphics} graphics - Graphics instance
@param {{width: number, height: number}} dimension - Max width & height
@returns {Promise}