diff --git a/acrobat/blocks/eventwrapper/eventwrapper.css b/acrobat/blocks/eventwrapper/eventwrapper.css index 5f080955..729ff72e 100644 --- a/acrobat/blocks/eventwrapper/eventwrapper.css +++ b/acrobat/blocks/eventwrapper/eventwrapper.css @@ -38,8 +38,25 @@ body:not([data-current-event]) [data-event-name=onload] { [data-current-event=complete] .fake-dc-wrapper, [data-current-event=complete] #CID, +[data-current-event=start] #CID, [data-current-event=uploadcomplete] .fake-dc-wrapper, [data-current-event=uploadcomplete] #CID { top: 30px; position: relative; } + +.review.fade-in { + animation-duration: 3s; + animation-name: fade-in; +} + + +@keyframes fade-in { + 0% { + opacity: 0; + } + + 100% { + opacity: 1; + } +} diff --git a/acrobat/blocks/eventwrapper/eventwrapper.js b/acrobat/blocks/eventwrapper/eventwrapper.js index 3857e570..8ac99597 100644 --- a/acrobat/blocks/eventwrapper/eventwrapper.js +++ b/acrobat/blocks/eventwrapper/eventwrapper.js @@ -19,9 +19,11 @@ const DROPZONE_DIS = 'dropzone-displayed'; const PREVIEW_DIS = 'preview-displayed'; const TRY_ANOTHER = 'try-another-file-start'; // const UPSELL_DIS = 'upsell-displayed'; +const FADE = 'review fade-in'; export default function init(element) { const wrapper = element; + const reviewBlock = document.querySelectorAll('.review'); const setCurrentEvent = (event) => { if (document.querySelectorAll(`[data-event-name="${event}"]`).length > 0) { document.body.dataset.currentEvent = event; @@ -49,7 +51,6 @@ export default function init(element) { }else{ browserExtAlloy('modalExist', browserName); } - }); } else { window.dispatchEvent(event); @@ -62,7 +63,6 @@ export default function init(element) { let browserName = parser.getBrowserName(); let extID; if (e === PROCESS_START) converterAnalytics(); - if (e === CONVERSION_COM && parser.parsedResult.platform.type === 'desktop' || e === PREVIEW_DIS && parser.parsedResult.platform.type === 'desktop') { // Browser Extension @@ -97,6 +97,7 @@ export default function init(element) { break; case UPLOAD_START: setCurrentEvent('upload'); + if (reviewBlock[0]) { reviewBlock[0].classList.add('hide'); }; break; case UPLOAD_COMPLETE: setCurrentEvent('uploadcomplete'); @@ -112,12 +113,15 @@ export default function init(element) { break; case CONVERSION_COM: setCurrentEvent('complete'); + if (reviewBlock[0]) { reviewBlock[0].classList = FADE; }; break; case PREVIEW_GEN: setCurrentEvent('preview'); + if (reviewBlock[0]) { reviewBlock[0].classList = FADE; }; break; case DROPZONE_DIS: setCurrentEvent(DROPZONE_DIS); + if (reviewBlock[0]) { reviewBlock[0].classList = FADE; }; break; case DOWNLOAD_START: setCurrentEvent('download');