|
|
@ -10,6 +10,8 @@ import { findUpClassName } from "../lib/utils"; |
|
|
|
import appImManager from "../lib/appManagers/appImManager"; |
|
|
|
import appImManager from "../lib/appManagers/appImManager"; |
|
|
|
import { StickerSet } from "../layer"; |
|
|
|
import { StickerSet } from "../layer"; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
const ANIMATION_GROUP = 'STICKERS-POPUP'; |
|
|
|
|
|
|
|
|
|
|
|
export default class PopupStickers extends PopupElement { |
|
|
|
export default class PopupStickers extends PopupElement { |
|
|
|
private stickersFooter: HTMLElement; |
|
|
|
private stickersFooter: HTMLElement; |
|
|
|
private stickersDiv: HTMLElement; |
|
|
|
private stickersDiv: HTMLElement; |
|
|
@ -30,6 +32,7 @@ export default class PopupStickers extends PopupElement { |
|
|
|
this.header.append(this.h6); |
|
|
|
this.header.append(this.h6); |
|
|
|
|
|
|
|
|
|
|
|
this.onClose = () => { |
|
|
|
this.onClose = () => { |
|
|
|
|
|
|
|
animationIntersector.setOnlyOnePlayableGroup(''); |
|
|
|
animationIntersector.checkAnimations(false); |
|
|
|
animationIntersector.checkAnimations(false); |
|
|
|
this.stickersFooter.removeEventListener('click', this.onFooterClick); |
|
|
|
this.stickersFooter.removeEventListener('click', this.onFooterClick); |
|
|
|
this.stickersDiv.removeEventListener('click', this.onStickersClick); |
|
|
|
this.stickersDiv.removeEventListener('click', this.onStickersClick); |
|
|
@ -37,7 +40,7 @@ export default class PopupStickers extends PopupElement { |
|
|
|
}; |
|
|
|
}; |
|
|
|
|
|
|
|
|
|
|
|
this.onCloseAfterTimeout = () => { |
|
|
|
this.onCloseAfterTimeout = () => { |
|
|
|
animationIntersector.checkAnimations(undefined, 'STICKERS-POPUP'); |
|
|
|
animationIntersector.checkAnimations(undefined, ANIMATION_GROUP); |
|
|
|
}; |
|
|
|
}; |
|
|
|
|
|
|
|
|
|
|
|
const onOverlayClick = (e: MouseEvent) => { |
|
|
|
const onOverlayClick = (e: MouseEvent) => { |
|
|
@ -104,6 +107,7 @@ export default class PopupStickers extends PopupElement { |
|
|
|
this.set = set.set; |
|
|
|
this.set = set.set; |
|
|
|
|
|
|
|
|
|
|
|
animationIntersector.checkAnimations(true); |
|
|
|
animationIntersector.checkAnimations(true); |
|
|
|
|
|
|
|
animationIntersector.setOnlyOnePlayableGroup(ANIMATION_GROUP); |
|
|
|
|
|
|
|
|
|
|
|
this.h6.innerHTML = RichTextProcessor.wrapEmojiText(set.set.title); |
|
|
|
this.h6.innerHTML = RichTextProcessor.wrapEmojiText(set.set.title); |
|
|
|
!set.set.installed_date ? this.stickersFooter.classList.add('add') : this.stickersFooter.classList.remove('add'); |
|
|
|
!set.set.installed_date ? this.stickersFooter.classList.add('add') : this.stickersFooter.classList.remove('add'); |
|
|
@ -130,7 +134,7 @@ export default class PopupStickers extends PopupElement { |
|
|
|
doc, |
|
|
|
doc, |
|
|
|
div, |
|
|
|
div, |
|
|
|
lazyLoadQueue, |
|
|
|
lazyLoadQueue, |
|
|
|
group: 'STICKERS-POPUP', |
|
|
|
group: ANIMATION_GROUP, |
|
|
|
play: true, |
|
|
|
play: true, |
|
|
|
loop: true, |
|
|
|
loop: true, |
|
|
|
width: 80, |
|
|
|
width: 80, |
|
|
|