code: function definePreset(name, preset) {
    if (!name || !preset) {
      throw new Error('mdPanelProvider: The panel preset definition is ' +
          'malformed. The name and preset object are required.');
    } else if (_presets.hasOwnProperty(name)) {
      throw new Error('mdPanelProvider: The panel preset you have requested ' +
          'has already been defined.');
    }
  
    // Delete any property on the preset that is not allowed.
    delete preset.id;
    delete preset.position;
    delete preset.animation;
  
    _presets[name] = preset;
  }
docs: Takes the passed in panel configuration object and adds it to the `_presets`
  object at the specified name.
  @param {string} name Name of the preset to set.
  @param {!Object} preset Specific configuration object that can contain any
  and all of the parameters available within the `$mdPanel.create` method.
  However, parameters that pertain to id, position, animation, and user
  interaction are not allowed and will be removed from the preset
  configuration.