mirror of
https://github.com/TryGhost/Ghost.git
synced 2024-12-01 13:54:35 +03:00
19 lines
437 B
JavaScript
19 lines
437 B
JavaScript
|
import Service from '@ember/service';
|
||
|
|
||
|
export default Service.extend({
|
||
|
captionHasFocus: false,
|
||
|
isDragging: false,
|
||
|
|
||
|
captionGainedFocus(caption) {
|
||
|
this._focusedCaption = caption;
|
||
|
this.set('captionHasFocus', true);
|
||
|
},
|
||
|
|
||
|
captionLostFocus(caption) {
|
||
|
if (this._focusedCaption === caption) {
|
||
|
this._focusedCaption = null;
|
||
|
this.set('captionHasFocus', false);
|
||
|
}
|
||
|
}
|
||
|
});
|