define('ember-overlays/components/mark-overlay', ['exports', 'ember-overlays/templates/components/mark-overlay', 'ember-overlays/mark-info', 'ember-overlays/ember-private-api'], function (exports, _markOverlay, _markInfo, _emberPrivateApi) {
  'use strict';

  Object.defineProperty(exports, "__esModule", {
    value: true
  });
  var guidFor = Ember.guidFor;
  exports.default = Ember.Component.extend({
    layout: _markOverlay.default,
    tagName: '',
    service: Ember.inject.service('ember-overlays'),

    // Addon authors should group their overlays under a unique group
    // name so they don't interfere with other uses. An app can use the
    // default group.
    group: 'default',

    // this is an optional parameter that will be made available as
    // mark.model inside overlay-marks
    model: null,

    didRender: function didRender() {
      this.get('service').registerMark(guidFor(this), this.info());
    },
    willDestroyElement: function willDestroyElement() {
      this.get('service').unregisterMark(guidFor(this));
    },
    info: function info() {
      var _componentNodes = (0, _emberPrivateApi.componentNodes)(this),
          firstNode = _componentNodes.firstNode,
          lastNode = _componentNodes.lastNode;

      return new _markInfo.default(this.get('id'), firstNode, lastNode, this.get('group') || 'default', this.get('model'));
    }
  });
});