!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports):"function"==typeof define&&define.amd?define(["exports"],t):t((e=e||self).lumino_properties={})}(this,(function(e){"use strict";var t;e.AttachedProperty=function(){function e(e){this._pid=t.nextPID(),this.name=e.name,this._create=e.create,this._coerce=e.coerce||null,this._compare=e.compare||null,this._changed=e.changed||null}return e.prototype.get=function(e){var r=t.ensureMap(e);return this._pid in r?r[this._pid]:r[this._pid]=this._createValue(e)},e.prototype.set=function(e,r){var i,n=t.ensureMap(e);i=this._pid in n?n[this._pid]:n[this._pid]=this._createValue(e);var a=this._coerceValue(e,r);this._maybeNotify(e,i,n[this._pid]=a)},e.prototype.coerce=function(e){var r,i=t.ensureMap(e);r=this._pid in i?i[this._pid]:i[this._pid]=this._createValue(e);var n=this._coerceValue(e,r);this._maybeNotify(e,r,i[this._pid]=n)},e.prototype._createValue=function(e){return(0,this._create)(e)},e.prototype._coerceValue=function(e,t){var r=this._coerce;return r?r(e,t):t},e.prototype._compareValue=function(e,t){var r=this._compare;return r?r(e,t):e===t},e.prototype._maybeNotify=function(e,t,r){var i=this._changed;i&&!this._compareValue(t,r)&&i(e,t,r)},e}(),(e.AttachedProperty||(e.AttachedProperty={})).clearData=function(e){t.ownerData.delete(e)},function(e){var t;e.ownerData=new WeakMap,e.nextPID=(t=0,function(){return"pid-"+(""+Math.random()).slice(2)+"-"+t++}),e.ensureMap=function(t){var r=e.ownerData.get(t);return r||(r=Object.create(null),e.ownerData.set(t,r),r)}}(t||(t={})),Object.defineProperty(e,"__esModule",{value:!0})}));
//# sourceMappingURL=index.min.js.map