@coorpacademy/components 10.24.5 → 10.25.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/es/atom/choice/test/fixtures.native.d.ts +2 -0
- package/es/atom/choice/test/fixtures.native.d.ts.map +1 -0
- package/es/atom/gradient/test/fixtures.native.d.ts +2 -0
- package/es/atom/gradient/test/fixtures.native.d.ts.map +1 -0
- package/es/atom/header-back-button/test/fixtures.native.d.ts +2 -0
- package/es/atom/header-back-button/test/fixtures.native.d.ts.map +1 -0
- package/es/atom/header-back-icon/test/fixtures.native.d.ts +2 -0
- package/es/atom/header-back-icon/test/fixtures.native.d.ts.map +1 -0
- package/es/atom/html/test/fixtures.native.d.ts +2 -0
- package/es/atom/html/test/fixtures.native.d.ts.map +1 -0
- package/es/atom/image-background/test/fixtures.native.d.ts +2 -0
- package/es/atom/image-background/test/fixtures.native.d.ts.map +1 -0
- package/es/atom/loader/index.d.ts +13 -0
- package/es/atom/loader/index.d.ts.map +1 -0
- package/es/atom/lottie-wrapper/index.d.ts +8 -0
- package/es/atom/lottie-wrapper/index.d.ts.map +1 -0
- package/es/atom/lottie-wrapper/prop-types.d.ts +26 -9
- package/es/atom/lottie-wrapper/prop-types.d.ts.map +1 -1
- package/es/atom/lottie-wrapper/prop-types.js +2 -1
- package/es/atom/lottie-wrapper/prop-types.js.map +1 -1
- package/es/atom/lottie-wrapper/test/fixtures/confetti.d.ts +20 -0
- package/es/atom/lottie-wrapper/test/fixtures/confetti.d.ts.map +1 -0
- package/es/atom/lottie-wrapper/test/fixtures/default.d.ts +20 -0
- package/es/atom/lottie-wrapper/test/fixtures/default.d.ts.map +1 -0
- package/es/atom/lottie-wrapper/test/fixtures/rank.d.ts +16 -0
- package/es/atom/lottie-wrapper/test/fixtures/rank.d.ts.map +1 -0
- package/es/atom/provider/index.d.ts +1 -1
- package/es/atom/provider/web-context.js +1 -1
- package/es/atom/provider/web-context.js.map +1 -1
- package/es/atom/range/handle.d.ts +34 -0
- package/es/atom/range/handle.d.ts.map +1 -0
- package/es/atom/range/index.d.ts +32 -0
- package/es/atom/range/index.d.ts.map +1 -0
- package/es/atom/review-background/index.d.ts +7 -0
- package/es/atom/review-background/index.d.ts.map +1 -0
- package/es/atom/review-header-step-item/index.d.ts +2 -2
- package/es/atom/review-header-step-item/index.d.ts.map +1 -1
- package/es/atom/review-header-step-item/index.js.map +1 -1
- package/es/atom/review-header-step-item/index.native.d.ts +2 -2
- package/es/atom/review-header-step-item/index.native.d.ts.map +1 -1
- package/es/atom/review-header-step-item/index.native.js.map +1 -1
- package/es/atom/review-header-step-item/test/fixtures.native.d.ts +2 -0
- package/es/atom/review-header-step-item/test/fixtures.native.d.ts.map +1 -0
- package/es/atom/review-header-step-item/types.d.ts +2 -2
- package/es/atom/review-header-step-item/types.d.ts.map +1 -1
- package/es/atom/review-header-step-item/types.js.map +1 -1
- package/es/atom/review-presentation/index.d.ts +7 -0
- package/es/atom/review-presentation/index.d.ts.map +1 -0
- package/es/atom/review-presentation/prop-types.d.ts +26 -0
- package/es/atom/review-presentation/prop-types.d.ts.map +1 -0
- package/es/atom/review-presentation/test/fixtures/default.d.ts +28 -0
- package/es/atom/review-presentation/test/fixtures/default.d.ts.map +1 -0
- package/es/atom/select/index.d.ts +56 -0
- package/es/atom/select/index.d.ts.map +1 -0
- package/es/atom/select-modal/test/fixtures.native.d.ts +2 -0
- package/es/atom/select-modal/test/fixtures.native.d.ts.map +1 -0
- package/es/atom/space/test/fixtures.native.d.ts +2 -0
- package/es/atom/space/test/fixtures.native.d.ts.map +1 -0
- package/es/atom/text/test/fixtures.native.d.ts +2 -0
- package/es/atom/text/test/fixtures.native.d.ts.map +1 -0
- package/es/hoc/animation/index.d.ts +54 -0
- package/es/hoc/animation/index.d.ts.map +1 -0
- package/es/hoc/animation-scheduler/index.d.ts +38 -0
- package/es/hoc/animation-scheduler/index.d.ts.map +1 -0
- package/es/hoc/animation-scheduler/index.js +3 -3
- package/es/hoc/animation-scheduler/index.js.map +1 -1
- package/es/hoc/modal/select/test/fixtures.native.d.ts +2 -0
- package/es/hoc/modal/select/test/fixtures.native.d.ts.map +1 -0
- package/es/hoc/modal/select-item/test/fixtures.native.d.ts +2 -0
- package/es/hoc/modal/select-item/test/fixtures.native.d.ts.map +1 -0
- package/es/hoc/modal/test/fixtures.native.d.ts +2 -0
- package/es/hoc/modal/test/fixtures.native.d.ts.map +1 -0
- package/es/hoc/swapper/index.js +1 -1
- package/es/hoc/swapper/index.js.map +1 -1
- package/es/hoc/touchable/test/fixtures.native.d.ts +2 -0
- package/es/hoc/touchable/test/fixtures.native.d.ts.map +1 -0
- package/es/hoc/transition/index.d.ts +11 -0
- package/es/hoc/transition/index.d.ts.map +1 -0
- package/es/hoc/transition/index.js +1 -1
- package/es/hoc/transition/index.js.map +1 -1
- package/es/molecule/add-to-my-list/index.js +1 -1
- package/es/molecule/add-to-my-list/index.js.map +1 -1
- package/es/molecule/answer/index.d.ts +7 -0
- package/es/molecule/answer/index.d.ts.map +1 -0
- package/es/molecule/answer/index.native.d.ts +2 -2
- package/es/molecule/answer/index.native.d.ts.map +1 -1
- package/es/molecule/answer/index.native.js.map +1 -1
- package/es/molecule/answer/prop-types.d.ts +27 -10
- package/es/molecule/answer/prop-types.d.ts.map +1 -1
- package/es/molecule/answer/prop-types.js.map +1 -1
- package/es/molecule/answer/test/fixtures/audio.d.ts +7 -0
- package/es/molecule/answer/test/fixtures/audio.d.ts.map +1 -0
- package/es/molecule/answer/test/fixtures/default.d.ts +7 -0
- package/es/molecule/answer/test/fixtures/default.d.ts.map +1 -0
- package/es/molecule/answer/test/fixtures/drop-down.d.ts +2 -2
- package/es/molecule/answer/test/fixtures/drop-down.d.ts.map +1 -1
- package/es/molecule/answer/test/fixtures/qcm-arabic.d.ts +7 -0
- package/es/molecule/answer/test/fixtures/qcm-arabic.d.ts.map +1 -0
- package/es/molecule/answer/test/fixtures/qcm-drag.d.ts +7 -0
- package/es/molecule/answer/test/fixtures/qcm-drag.d.ts.map +1 -0
- package/es/molecule/answer/test/fixtures/qcm-graphic.d.ts +7 -0
- package/es/molecule/answer/test/fixtures/qcm-graphic.d.ts.map +1 -0
- package/es/molecule/answer/test/fixtures/qcm-short-audio.d.ts +7 -0
- package/es/molecule/answer/test/fixtures/qcm-short-audio.d.ts.map +1 -0
- package/es/molecule/answer/test/fixtures/qcm-short-video.d.ts +7 -0
- package/es/molecule/answer/test/fixtures/qcm-short-video.d.ts.map +1 -0
- package/es/molecule/answer/test/fixtures/qcm-short.d.ts +7 -0
- package/es/molecule/answer/test/fixtures/qcm-short.d.ts.map +1 -0
- package/es/molecule/answer/test/fixtures/qcm.d.ts +7 -0
- package/es/molecule/answer/test/fixtures/qcm.d.ts.map +1 -0
- package/es/molecule/answer/test/fixtures/range.d.ts +7 -0
- package/es/molecule/answer/test/fixtures/range.d.ts.map +1 -0
- package/es/molecule/answer/test/fixtures/template.d.ts +2 -2
- package/es/molecule/answer/test/fixtures/template.d.ts.map +1 -1
- package/es/molecule/answer/test/fixtures.native.d.ts +2 -0
- package/es/molecule/answer/test/fixtures.native.d.ts.map +1 -0
- package/es/molecule/audio/index.d.ts +42 -0
- package/es/molecule/audio/index.d.ts.map +1 -0
- package/es/molecule/brand-logo/test/fixtures.native.d.ts +2 -0
- package/es/molecule/brand-logo/test/fixtures.native.d.ts.map +1 -0
- package/es/molecule/card/index.js +1 -1
- package/es/molecule/card/index.js.map +1 -1
- package/es/molecule/cm-popin/index.d.ts +2 -51
- package/es/molecule/cm-popin/index.js +2 -37
- package/es/molecule/cm-popin/index.js.map +1 -1
- package/es/molecule/cm-popin/test/fixtures/on-review-quit.d.ts +7 -0
- package/es/molecule/cm-popin/test/fixtures/on-review-quit.d.ts.map +1 -0
- package/es/molecule/cm-popin/types.d.ts +70 -0
- package/es/molecule/cm-popin/types.d.ts.map +1 -0
- package/es/molecule/cm-popin/types.js +41 -0
- package/es/molecule/cm-popin/types.js.map +1 -0
- package/es/molecule/dashboard/battle-request-list/index.js +1 -1
- package/es/molecule/dashboard/battle-request-list/index.js.map +1 -1
- package/es/molecule/dashboard/news-list/index.js +1 -1
- package/es/molecule/dashboard/news-list/index.js.map +1 -1
- package/es/molecule/dashboard/review-banner/index.js +1 -1
- package/es/molecule/dashboard/review-banner/index.js.map +1 -1
- package/es/molecule/dashboard/start-battle/index.js +1 -1
- package/es/molecule/dashboard/start-battle/index.js.map +1 -1
- package/es/molecule/questions/drop-down/index.d.ts +16 -0
- package/es/molecule/questions/drop-down/index.d.ts.map +1 -0
- package/es/molecule/questions/free-text/index.d.ts +35 -0
- package/es/molecule/questions/free-text/index.d.ts.map +1 -0
- package/es/molecule/questions/free-text/test/fixtures/default.d.ts +7 -0
- package/es/molecule/questions/free-text/test/fixtures/default.d.ts.map +1 -0
- package/es/molecule/questions/free-text/test/fixtures/with-value-on-change.d.ts +10 -0
- package/es/molecule/questions/free-text/test/fixtures/with-value-on-change.d.ts.map +1 -0
- package/es/molecule/questions/free-text/test/fixtures/with-value.d.ts +8 -0
- package/es/molecule/questions/free-text/test/fixtures/with-value.d.ts.map +1 -0
- package/es/molecule/questions/free-text/test/fixtures.native.d.ts +2 -0
- package/es/molecule/questions/free-text/test/fixtures.native.d.ts.map +1 -0
- package/es/molecule/questions/mobile/draggable/test/fixtures.native.d.ts +2 -0
- package/es/molecule/questions/mobile/draggable/test/fixtures.native.d.ts.map +1 -0
- package/es/molecule/questions/mobile/slider/test/fixtures.native.d.ts +2 -0
- package/es/molecule/questions/mobile/slider/test/fixtures.native.d.ts.map +1 -0
- package/es/molecule/questions/mobile/switch/test/fixtures.native.d.ts +2 -0
- package/es/molecule/questions/mobile/switch/test/fixtures.native.d.ts.map +1 -0
- package/es/molecule/questions/mobile/template/test/fixtures.native.d.ts +2 -0
- package/es/molecule/questions/mobile/template/test/fixtures.native.d.ts.map +1 -0
- package/es/molecule/questions/qcm/index.d.ts +37 -0
- package/es/molecule/questions/qcm/index.d.ts.map +1 -0
- package/es/molecule/questions/qcm/test/fixtures/arabic.d.ts +11 -0
- package/es/molecule/questions/qcm/test/fixtures/arabic.d.ts.map +1 -0
- package/es/molecule/questions/qcm/test/fixtures/default.d.ts +12 -0
- package/es/molecule/questions/qcm/test/fixtures/default.d.ts.map +1 -0
- package/es/molecule/questions/qcm/test/fixtures/short-answers.d.ts +11 -0
- package/es/molecule/questions/qcm/test/fixtures/short-answers.d.ts.map +1 -0
- package/es/molecule/questions/qcm-drag/index.d.ts +68 -0
- package/es/molecule/questions/qcm-drag/index.d.ts.map +1 -0
- package/es/molecule/questions/qcm-drag/test/fixtures/default.d.ts +17 -0
- package/es/molecule/questions/qcm-drag/test/fixtures/default.d.ts.map +1 -0
- package/es/molecule/questions/qcm-graphic/index.d.ts +38 -0
- package/es/molecule/questions/qcm-graphic/index.d.ts.map +1 -0
- package/es/molecule/questions/qcm-graphic/test/fixtures/default.d.ts +12 -0
- package/es/molecule/questions/qcm-graphic/test/fixtures/default.d.ts.map +1 -0
- package/es/molecule/questions/question-range/index.d.ts +38 -0
- package/es/molecule/questions/question-range/index.d.ts.map +1 -0
- package/es/molecule/questions/question-range/test/fixtures/default.d.ts +11 -0
- package/es/molecule/questions/question-range/test/fixtures/default.d.ts.map +1 -0
- package/es/molecule/questions/template/index.d.ts +31 -0
- package/es/molecule/questions/template/index.d.ts.map +1 -0
- package/es/molecule/review-card-congrats/index.d.ts +8 -0
- package/es/molecule/review-card-congrats/index.d.ts.map +1 -0
- package/es/molecule/review-card-congrats/prop-types.d.ts +14 -1
- package/es/molecule/review-card-congrats/prop-types.d.ts.map +1 -1
- package/es/molecule/review-card-congrats/prop-types.js.map +1 -1
- package/es/molecule/review-card-congrats/test/fixtures/rank.d.ts +28 -0
- package/es/molecule/review-card-congrats/test/fixtures/rank.d.ts.map +1 -0
- package/es/molecule/review-card-congrats/test/fixtures/star.d.ts +31 -0
- package/es/molecule/review-card-congrats/test/fixtures/star.d.ts.map +1 -0
- package/es/molecule/review-correction-popin/index.d.ts +7 -0
- package/es/molecule/review-correction-popin/index.d.ts.map +1 -0
- package/es/molecule/review-correction-popin/prop-types.d.ts +26 -9
- package/es/molecule/review-correction-popin/prop-types.d.ts.map +1 -1
- package/es/molecule/review-correction-popin/prop-types.js +2 -1
- package/es/molecule/review-correction-popin/prop-types.js.map +1 -1
- package/es/molecule/review-correction-popin/test/fixtures/right.d.ts +18 -0
- package/es/molecule/review-correction-popin/test/fixtures/right.d.ts.map +1 -0
- package/es/molecule/review-correction-popin/test/fixtures/wrong.d.ts +22 -0
- package/es/molecule/review-correction-popin/test/fixtures/wrong.d.ts.map +1 -0
- package/es/molecule/review-header-steps/index.d.ts +7 -0
- package/es/molecule/review-header-steps/index.d.ts.map +1 -0
- package/es/molecule/review-header-steps/prop-types.d.ts +9 -5
- package/es/molecule/review-header-steps/prop-types.d.ts.map +1 -1
- package/es/molecule/review-header-steps/prop-types.js +2 -1
- package/es/molecule/review-header-steps/prop-types.js.map +1 -1
- package/es/molecule/review-header-steps/test/fixtures/all-questions-ok.d.ts +7 -0
- package/es/molecule/review-header-steps/test/fixtures/all-questions-ok.d.ts.map +1 -0
- package/es/molecule/review-header-steps/test/fixtures/current-question-no-aswered.d.ts +7 -0
- package/es/molecule/review-header-steps/test/fixtures/current-question-no-aswered.d.ts.map +1 -0
- package/es/molecule/review-header-steps/test/fixtures/current-question-wrong.d.ts +7 -0
- package/es/molecule/review-header-steps/test/fixtures/current-question-wrong.d.ts.map +1 -0
- package/es/molecule/review-header-steps/test/fixtures/first-question-current-right.d.ts +7 -0
- package/es/molecule/review-header-steps/test/fixtures/first-question-current-right.d.ts.map +1 -0
- package/es/molecule/review-header-steps/test/fixtures/no-answered-question.d.ts +7 -0
- package/es/molecule/review-header-steps/test/fixtures/no-answered-question.d.ts.map +1 -0
- package/es/molecule/review-header-steps/test/fixtures/question-to-repeat.d.ts +7 -0
- package/es/molecule/review-header-steps/test/fixtures/question-to-repeat.d.ts.map +1 -0
- package/es/molecule/share/index.js +1 -1
- package/es/molecule/share/index.js.map +1 -1
- package/es/molecule/skill-card/index.d.ts +7 -0
- package/es/molecule/skill-card/index.d.ts.map +1 -0
- package/es/molecule/skill-card/test/fixtures/default.d.ts +16 -0
- package/es/molecule/skill-card/test/fixtures/default.d.ts.map +1 -0
- package/es/molecule/video-iframe/index.d.ts +22 -0
- package/es/molecule/video-iframe/index.d.ts.map +1 -0
- package/es/molecule/video-player/index.d.ts +51 -0
- package/es/molecule/video-player/index.d.ts.map +1 -0
- package/es/molecule/video-player/jwplayer.d.ts +58 -0
- package/es/molecule/video-player/jwplayer.d.ts.map +1 -0
- package/es/molecule/video-player/vimeo.d.ts +154 -0
- package/es/molecule/video-player/vimeo.d.ts.map +1 -0
- package/es/organism/header-v2/test/fixtures.native.d.ts +2 -0
- package/es/organism/header-v2/test/fixtures.native.d.ts.map +1 -0
- package/es/organism/mobile-navigation/test/fixtures.native.d.ts +2 -0
- package/es/organism/mobile-navigation/test/fixtures.native.d.ts.map +1 -0
- package/es/organism/review-congrats/index.d.ts +8 -0
- package/es/organism/review-congrats/index.d.ts.map +1 -0
- package/es/organism/review-congrats/prop-types.d.ts +25 -3
- package/es/organism/review-congrats/prop-types.d.ts.map +1 -1
- package/es/organism/review-congrats/prop-types.js +2 -1
- package/es/organism/review-congrats/prop-types.js.map +1 -1
- package/es/organism/review-congrats/test/fixtures/default.d.ts +7 -0
- package/es/organism/review-congrats/test/fixtures/default.d.ts.map +1 -0
- package/es/organism/review-header/index.d.ts +7 -0
- package/es/organism/review-header/index.d.ts.map +1 -0
- package/es/organism/review-header/index.native.d.ts +2 -2
- package/es/organism/review-header/index.native.d.ts.map +1 -1
- package/es/organism/review-header/index.native.js.map +1 -1
- package/es/organism/review-header/test/fixtures/all-questions-ok.d.ts +15 -0
- package/es/organism/review-header/test/fixtures/all-questions-ok.d.ts.map +1 -0
- package/es/organism/review-header/test/fixtures/current-question-no-answered.d.ts +7 -0
- package/es/organism/review-header/test/fixtures/current-question-no-answered.d.ts.map +1 -0
- package/es/organism/review-header/test/fixtures/current-question-wrong.d.ts +7 -0
- package/es/organism/review-header/test/fixtures/current-question-wrong.d.ts.map +1 -0
- package/es/organism/review-header/test/fixtures/first-question-current-right.d.ts +7 -0
- package/es/organism/review-header/test/fixtures/first-question-current-right.d.ts.map +1 -0
- package/es/organism/review-header/test/fixtures/no-answered-question.d.ts +7 -0
- package/es/organism/review-header/test/fixtures/no-answered-question.d.ts.map +1 -0
- package/es/organism/review-header/test/fixtures/question-to-repeat.d.ts +7 -0
- package/es/organism/review-header/test/fixtures/question-to-repeat.d.ts.map +1 -0
- package/es/organism/review-header/test/fixtures/steps-animation.d.ts +7 -0
- package/es/organism/review-header/test/fixtures/steps-animation.d.ts.map +1 -0
- package/es/organism/review-header/test/fixtures.native.d.ts +2 -0
- package/es/organism/review-header/test/fixtures.native.d.ts.map +1 -0
- package/es/organism/review-header/types.d.ts +4 -4
- package/es/organism/review-header/types.d.ts.map +1 -1
- package/es/organism/review-header/types.js.map +1 -1
- package/es/organism/review-skills/index.d.ts +7 -0
- package/es/organism/review-skills/index.d.ts.map +1 -0
- package/es/organism/review-skills/test/fixtures/many-skills.d.ts +22 -0
- package/es/organism/review-skills/test/fixtures/many-skills.d.ts.map +1 -0
- package/es/organism/review-skills/test/fixtures/no-skills.d.ts +12 -0
- package/es/organism/review-skills/test/fixtures/no-skills.d.ts.map +1 -0
- package/es/organism/review-slide/index.d.ts +7 -0
- package/es/organism/review-slide/index.d.ts.map +1 -0
- package/es/organism/review-slide/index.native.d.ts +2 -2
- package/es/organism/review-slide/index.native.d.ts.map +1 -1
- package/es/organism/review-slide/index.native.js +3 -3
- package/es/organism/review-slide/index.native.js.map +1 -1
- package/es/organism/review-slide/prop-types.d.ts +21 -36
- package/es/organism/review-slide/prop-types.d.ts.map +1 -1
- package/es/organism/review-slide/prop-types.js.map +1 -1
- package/es/organism/review-slide/test/fixtures/choices-selected.d.ts +22 -0
- package/es/organism/review-slide/test/fixtures/choices-selected.d.ts.map +1 -0
- package/es/organism/review-slide/test/fixtures/correction-ok-animated.d.ts +36 -0
- package/es/organism/review-slide/test/fixtures/correction-ok-animated.d.ts.map +1 -0
- package/es/organism/review-slide/test/fixtures/correction-ok.d.ts +36 -0
- package/es/organism/review-slide/test/fixtures/correction-ok.d.ts.map +1 -0
- package/es/organism/review-slide/test/fixtures/correction-wrong-animated.d.ts +38 -0
- package/es/organism/review-slide/test/fixtures/correction-wrong-animated.d.ts.map +1 -0
- package/es/organism/review-slide/test/fixtures/correction-wrong.d.ts +38 -0
- package/es/organism/review-slide/test/fixtures/correction-wrong.d.ts.map +1 -0
- package/es/organism/review-slide/test/fixtures/initial-state.d.ts +22 -0
- package/es/organism/review-slide/test/fixtures/initial-state.d.ts.map +1 -0
- package/es/organism/review-slide/test/fixtures/loading.d.ts +12 -0
- package/es/organism/review-slide/test/fixtures/loading.d.ts.map +1 -0
- package/es/organism/review-slide/test/fixtures.native.d.ts +2 -0
- package/es/organism/review-slide/test/fixtures.native.d.ts.map +1 -0
- package/es/organism/review-stacked-slides/index.d.ts +13 -0
- package/es/organism/review-stacked-slides/index.d.ts.map +1 -0
- package/es/organism/review-stacked-slides/index.js +3 -6
- package/es/organism/review-stacked-slides/index.js.map +1 -1
- package/es/organism/review-stacked-slides/index.native.d.ts +2 -2
- package/es/organism/review-stacked-slides/index.native.d.ts.map +1 -1
- package/es/organism/review-stacked-slides/index.native.js +3 -6
- package/es/organism/review-stacked-slides/index.native.js.map +1 -1
- package/es/organism/review-stacked-slides/prop-types.d.ts +26 -25
- package/es/organism/review-stacked-slides/prop-types.d.ts.map +1 -1
- package/es/organism/review-stacked-slides/prop-types.js.map +1 -1
- package/es/organism/review-stacked-slides/test/fixtures/all-ok.d.ts +9 -0
- package/es/organism/review-stacked-slides/test/fixtures/all-ok.d.ts.map +1 -0
- package/es/organism/review-stacked-slides/test/fixtures/end-review.d.ts +7 -0
- package/es/organism/review-stacked-slides/test/fixtures/end-review.d.ts.map +1 -0
- package/es/organism/review-stacked-slides/test/fixtures/first-correct.d.ts +9 -0
- package/es/organism/review-stacked-slides/test/fixtures/first-correct.d.ts.map +1 -0
- package/es/organism/review-stacked-slides/test/fixtures/initial-state.d.ts +7 -0
- package/es/organism/review-stacked-slides/test/fixtures/initial-state.d.ts.map +1 -0
- package/es/organism/review-stacked-slides/test/fixtures/loading.d.ts +7 -0
- package/es/organism/review-stacked-slides/test/fixtures/loading.d.ts.map +1 -0
- package/es/organism/review-stacked-slides/test/fixtures/restack.d.ts +9 -0
- package/es/organism/review-stacked-slides/test/fixtures/restack.d.ts.map +1 -0
- package/es/organism/review-stacked-slides/test/fixtures/second-wrong.d.ts +9 -0
- package/es/organism/review-stacked-slides/test/fixtures/second-wrong.d.ts.map +1 -0
- package/es/organism/review-stacked-slides/test/fixtures/unstack.d.ts +9 -0
- package/es/organism/review-stacked-slides/test/fixtures/unstack.d.ts.map +1 -0
- package/es/organism/review-stacked-slides/test/fixtures/wrong.d.ts +9 -0
- package/es/organism/review-stacked-slides/test/fixtures/wrong.d.ts.map +1 -0
- package/es/organism/review-stacked-slides/test/fixtures.native.d.ts +2 -0
- package/es/organism/review-stacked-slides/test/fixtures.native.d.ts.map +1 -0
- package/es/template/app-player/popin-end/summary.js +3 -4
- package/es/template/app-player/popin-end/summary.js.map +1 -1
- package/es/template/app-review/demo-ts/test/fixtures.native.d.ts +2 -0
- package/es/template/app-review/demo-ts/test/fixtures.native.d.ts.map +1 -0
- package/es/template/app-review/index.d.ts +603 -0
- package/es/template/app-review/index.d.ts.map +1 -0
- package/es/template/app-review/index.js +16 -21
- package/es/template/app-review/index.js.map +1 -1
- package/es/template/app-review/index.native.d.ts +5 -0
- package/es/template/app-review/index.native.d.ts.map +1 -0
- package/es/template/app-review/index.native.js +20 -25
- package/es/template/app-review/index.native.js.map +1 -1
- package/es/template/app-review/onboarding/index.d.ts +3 -0
- package/es/template/app-review/onboarding/index.d.ts.map +1 -0
- package/es/template/app-review/onboarding/index.native.d.ts +9 -0
- package/es/template/app-review/onboarding/index.native.d.ts.map +1 -0
- package/es/template/app-review/onboarding/test/fixtures/default.d.ts +3 -0
- package/es/template/app-review/onboarding/test/fixtures/default.d.ts.map +1 -0
- package/es/template/app-review/onboarding/test/fixtures.native.d.ts +2 -0
- package/es/template/app-review/onboarding/test/fixtures.native.d.ts.map +1 -0
- package/es/template/app-review/player/index.d.ts +13 -0
- package/es/template/app-review/player/index.d.ts.map +1 -0
- package/es/template/app-review/player/index.native.d.ts +2 -2
- package/es/template/app-review/player/index.native.d.ts.map +1 -1
- package/es/template/app-review/player/index.native.js.map +1 -1
- package/es/template/app-review/player/prop-types.d.ts +31 -31
- package/es/template/app-review/player/prop-types.d.ts.map +1 -1
- package/es/template/app-review/player/prop-types.js.map +1 -1
- package/es/template/app-review/player/test/fixtures/all-ok.d.ts +7 -0
- package/es/template/app-review/player/test/fixtures/all-ok.d.ts.map +1 -0
- package/es/template/app-review/player/test/fixtures/end-review.d.ts +7 -0
- package/es/template/app-review/player/test/fixtures/end-review.d.ts.map +1 -0
- package/es/template/app-review/player/test/fixtures/first-right.d.ts +7 -0
- package/es/template/app-review/player/test/fixtures/first-right.d.ts.map +1 -0
- package/es/template/app-review/player/test/fixtures/initial-state.d.ts +7 -0
- package/es/template/app-review/player/test/fixtures/initial-state.d.ts.map +1 -0
- package/es/template/app-review/player/test/fixtures/loading.d.ts +7 -0
- package/es/template/app-review/player/test/fixtures/loading.d.ts.map +1 -0
- package/es/template/app-review/player/test/fixtures/on-quit.d.ts +7 -0
- package/es/template/app-review/player/test/fixtures/on-quit.d.ts.map +1 -0
- package/es/template/app-review/player/test/fixtures/one-fail.d.ts +7 -0
- package/es/template/app-review/player/test/fixtures/one-fail.d.ts.map +1 -0
- package/es/template/app-review/player/test/fixtures/restack.d.ts +7 -0
- package/es/template/app-review/player/test/fixtures/restack.d.ts.map +1 -0
- package/es/template/app-review/player/test/fixtures/second-failed-question.d.ts +7 -0
- package/es/template/app-review/player/test/fixtures/second-failed-question.d.ts.map +1 -0
- package/es/template/app-review/player/test/fixtures/unstack.d.ts +7 -0
- package/es/template/app-review/player/test/fixtures/unstack.d.ts.map +1 -0
- package/es/template/app-review/player/test/fixtures.native.d.ts +2 -0
- package/es/template/app-review/player/test/fixtures.native.d.ts.map +1 -0
- package/es/template/app-review/prop-types.d.ts +610 -0
- package/es/template/app-review/prop-types.d.ts.map +1 -0
- package/es/template/app-review/prop-types.js +3 -9
- package/es/template/app-review/prop-types.js.map +1 -1
- package/es/template/app-review/skills/index.d.ts +3 -0
- package/es/template/app-review/skills/index.d.ts.map +1 -0
- package/es/template/app-review/skills/test/fixtures/many-skills.d.ts +3 -0
- package/es/template/app-review/skills/test/fixtures/many-skills.d.ts.map +1 -0
- package/es/template/app-review/skills/test/fixtures/no-skills.d.ts +3 -0
- package/es/template/app-review/skills/test/fixtures/no-skills.d.ts.map +1 -0
- package/es/template/app-review/skills/test/fixtures.native.d.ts +2 -0
- package/es/template/app-review/skills/test/fixtures.native.d.ts.map +1 -0
- package/es/template/app-review/template-context.js +1 -1
- package/es/template/app-review/template-context.js.map +1 -1
- package/es/template/app-review/test/fixtures/onboarding.d.ts +7 -0
- package/es/template/app-review/test/fixtures/onboarding.d.ts.map +1 -0
- package/es/template/app-review/test/fixtures/player.d.ts +7 -0
- package/es/template/app-review/test/fixtures/player.d.ts.map +1 -0
- package/es/template/app-review/test/fixtures/skills.d.ts +7 -0
- package/es/template/app-review/test/fixtures/skills.d.ts.map +1 -0
- package/es/template/app-review/test/fixtures.native.d.ts +2 -0
- package/es/template/app-review/test/fixtures.native.d.ts.map +1 -0
- package/es/template/common/dashboard/index.js +1 -1
- package/es/template/common/dashboard/index.js.map +1 -1
- package/es/test/helpers/render-component.d.ts +20 -0
- package/es/test/helpers/render-component.d.ts.map +1 -0
- package/es/util/get-shadow-box-color-from-primary.d.ts +2 -0
- package/es/util/get-shadow-box-color-from-primary.d.ts.map +1 -0
- package/lib/atom/choice/test/fixtures.native.d.ts +2 -0
- package/lib/atom/choice/test/fixtures.native.d.ts.map +1 -0
- package/lib/atom/gradient/test/fixtures.native.d.ts +2 -0
- package/lib/atom/gradient/test/fixtures.native.d.ts.map +1 -0
- package/lib/atom/header-back-button/test/fixtures.native.d.ts +2 -0
- package/lib/atom/header-back-button/test/fixtures.native.d.ts.map +1 -0
- package/lib/atom/header-back-icon/test/fixtures.native.d.ts +2 -0
- package/lib/atom/header-back-icon/test/fixtures.native.d.ts.map +1 -0
- package/lib/atom/html/test/fixtures.native.d.ts +2 -0
- package/lib/atom/html/test/fixtures.native.d.ts.map +1 -0
- package/lib/atom/image-background/test/fixtures.native.d.ts +2 -0
- package/lib/atom/image-background/test/fixtures.native.d.ts.map +1 -0
- package/lib/atom/loader/index.d.ts +13 -0
- package/lib/atom/loader/index.d.ts.map +1 -0
- package/lib/atom/lottie-wrapper/index.d.ts +8 -0
- package/lib/atom/lottie-wrapper/index.d.ts.map +1 -0
- package/lib/atom/lottie-wrapper/prop-types.d.ts +26 -9
- package/lib/atom/lottie-wrapper/prop-types.d.ts.map +1 -1
- package/lib/atom/lottie-wrapper/prop-types.js +2 -1
- package/lib/atom/lottie-wrapper/prop-types.js.map +1 -1
- package/lib/atom/lottie-wrapper/test/fixtures/confetti.d.ts +20 -0
- package/lib/atom/lottie-wrapper/test/fixtures/confetti.d.ts.map +1 -0
- package/lib/atom/lottie-wrapper/test/fixtures/default.d.ts +20 -0
- package/lib/atom/lottie-wrapper/test/fixtures/default.d.ts.map +1 -0
- package/lib/atom/lottie-wrapper/test/fixtures/rank.d.ts +16 -0
- package/lib/atom/lottie-wrapper/test/fixtures/rank.d.ts.map +1 -0
- package/lib/atom/provider/index.d.ts +1 -1
- package/lib/atom/provider/web-context.js +1 -1
- package/lib/atom/provider/web-context.js.map +1 -1
- package/lib/atom/range/handle.d.ts +34 -0
- package/lib/atom/range/handle.d.ts.map +1 -0
- package/lib/atom/range/index.d.ts +32 -0
- package/lib/atom/range/index.d.ts.map +1 -0
- package/lib/atom/review-background/index.d.ts +7 -0
- package/lib/atom/review-background/index.d.ts.map +1 -0
- package/lib/atom/review-header-step-item/index.d.ts +2 -2
- package/lib/atom/review-header-step-item/index.d.ts.map +1 -1
- package/lib/atom/review-header-step-item/index.js.map +1 -1
- package/lib/atom/review-header-step-item/index.native.d.ts +2 -2
- package/lib/atom/review-header-step-item/index.native.d.ts.map +1 -1
- package/lib/atom/review-header-step-item/index.native.js.map +1 -1
- package/lib/atom/review-header-step-item/test/fixtures.native.d.ts +2 -0
- package/lib/atom/review-header-step-item/test/fixtures.native.d.ts.map +1 -0
- package/lib/atom/review-header-step-item/types.d.ts +2 -2
- package/lib/atom/review-header-step-item/types.d.ts.map +1 -1
- package/lib/atom/review-header-step-item/types.js.map +1 -1
- package/lib/atom/review-presentation/index.d.ts +7 -0
- package/lib/atom/review-presentation/index.d.ts.map +1 -0
- package/lib/atom/review-presentation/prop-types.d.ts +26 -0
- package/lib/atom/review-presentation/prop-types.d.ts.map +1 -0
- package/lib/atom/review-presentation/test/fixtures/default.d.ts +28 -0
- package/lib/atom/review-presentation/test/fixtures/default.d.ts.map +1 -0
- package/lib/atom/select/index.d.ts +56 -0
- package/lib/atom/select/index.d.ts.map +1 -0
- package/lib/atom/select-modal/test/fixtures.native.d.ts +2 -0
- package/lib/atom/select-modal/test/fixtures.native.d.ts.map +1 -0
- package/lib/atom/space/test/fixtures.native.d.ts +2 -0
- package/lib/atom/space/test/fixtures.native.d.ts.map +1 -0
- package/lib/atom/text/test/fixtures.native.d.ts +2 -0
- package/lib/atom/text/test/fixtures.native.d.ts.map +1 -0
- package/lib/hoc/animation/index.d.ts +54 -0
- package/lib/hoc/animation/index.d.ts.map +1 -0
- package/lib/hoc/animation-scheduler/index.d.ts +38 -0
- package/lib/hoc/animation-scheduler/index.d.ts.map +1 -0
- package/lib/hoc/animation-scheduler/index.js +3 -3
- package/lib/hoc/animation-scheduler/index.js.map +1 -1
- package/lib/hoc/modal/select/test/fixtures.native.d.ts +2 -0
- package/lib/hoc/modal/select/test/fixtures.native.d.ts.map +1 -0
- package/lib/hoc/modal/select-item/test/fixtures.native.d.ts +2 -0
- package/lib/hoc/modal/select-item/test/fixtures.native.d.ts.map +1 -0
- package/lib/hoc/modal/test/fixtures.native.d.ts +2 -0
- package/lib/hoc/modal/test/fixtures.native.d.ts.map +1 -0
- package/lib/hoc/swapper/index.js +1 -1
- package/lib/hoc/swapper/index.js.map +1 -1
- package/lib/hoc/touchable/test/fixtures.native.d.ts +2 -0
- package/lib/hoc/touchable/test/fixtures.native.d.ts.map +1 -0
- package/lib/hoc/transition/index.d.ts +11 -0
- package/lib/hoc/transition/index.d.ts.map +1 -0
- package/lib/hoc/transition/index.js +1 -1
- package/lib/hoc/transition/index.js.map +1 -1
- package/lib/molecule/add-to-my-list/index.js +1 -1
- package/lib/molecule/add-to-my-list/index.js.map +1 -1
- package/lib/molecule/answer/index.d.ts +7 -0
- package/lib/molecule/answer/index.d.ts.map +1 -0
- package/lib/molecule/answer/index.native.d.ts +2 -2
- package/lib/molecule/answer/index.native.d.ts.map +1 -1
- package/lib/molecule/answer/index.native.js.map +1 -1
- package/lib/molecule/answer/prop-types.d.ts +27 -10
- package/lib/molecule/answer/prop-types.d.ts.map +1 -1
- package/lib/molecule/answer/prop-types.js.map +1 -1
- package/lib/molecule/answer/test/fixtures/audio.d.ts +7 -0
- package/lib/molecule/answer/test/fixtures/audio.d.ts.map +1 -0
- package/lib/molecule/answer/test/fixtures/default.d.ts +7 -0
- package/lib/molecule/answer/test/fixtures/default.d.ts.map +1 -0
- package/lib/molecule/answer/test/fixtures/drop-down.d.ts +2 -2
- package/lib/molecule/answer/test/fixtures/drop-down.d.ts.map +1 -1
- package/lib/molecule/answer/test/fixtures/qcm-arabic.d.ts +7 -0
- package/lib/molecule/answer/test/fixtures/qcm-arabic.d.ts.map +1 -0
- package/lib/molecule/answer/test/fixtures/qcm-drag.d.ts +7 -0
- package/lib/molecule/answer/test/fixtures/qcm-drag.d.ts.map +1 -0
- package/lib/molecule/answer/test/fixtures/qcm-graphic.d.ts +7 -0
- package/lib/molecule/answer/test/fixtures/qcm-graphic.d.ts.map +1 -0
- package/lib/molecule/answer/test/fixtures/qcm-short-audio.d.ts +7 -0
- package/lib/molecule/answer/test/fixtures/qcm-short-audio.d.ts.map +1 -0
- package/lib/molecule/answer/test/fixtures/qcm-short-video.d.ts +7 -0
- package/lib/molecule/answer/test/fixtures/qcm-short-video.d.ts.map +1 -0
- package/lib/molecule/answer/test/fixtures/qcm-short.d.ts +7 -0
- package/lib/molecule/answer/test/fixtures/qcm-short.d.ts.map +1 -0
- package/lib/molecule/answer/test/fixtures/qcm.d.ts +7 -0
- package/lib/molecule/answer/test/fixtures/qcm.d.ts.map +1 -0
- package/lib/molecule/answer/test/fixtures/range.d.ts +7 -0
- package/lib/molecule/answer/test/fixtures/range.d.ts.map +1 -0
- package/lib/molecule/answer/test/fixtures/template.d.ts +2 -2
- package/lib/molecule/answer/test/fixtures/template.d.ts.map +1 -1
- package/lib/molecule/answer/test/fixtures.native.d.ts +2 -0
- package/lib/molecule/answer/test/fixtures.native.d.ts.map +1 -0
- package/lib/molecule/audio/index.d.ts +42 -0
- package/lib/molecule/audio/index.d.ts.map +1 -0
- package/lib/molecule/brand-logo/test/fixtures.native.d.ts +2 -0
- package/lib/molecule/brand-logo/test/fixtures.native.d.ts.map +1 -0
- package/lib/molecule/card/index.js +1 -1
- package/lib/molecule/card/index.js.map +1 -1
- package/lib/molecule/cm-popin/index.d.ts +2 -51
- package/lib/molecule/cm-popin/index.js +3 -38
- package/lib/molecule/cm-popin/index.js.map +1 -1
- package/lib/molecule/cm-popin/test/fixtures/on-review-quit.d.ts +7 -0
- package/lib/molecule/cm-popin/test/fixtures/on-review-quit.d.ts.map +1 -0
- package/lib/molecule/cm-popin/types.d.ts +70 -0
- package/lib/molecule/cm-popin/types.d.ts.map +1 -0
- package/lib/molecule/cm-popin/types.js +52 -0
- package/lib/molecule/cm-popin/types.js.map +1 -0
- package/lib/molecule/dashboard/battle-request-list/index.js +1 -1
- package/lib/molecule/dashboard/battle-request-list/index.js.map +1 -1
- package/lib/molecule/dashboard/news-list/index.js +1 -1
- package/lib/molecule/dashboard/news-list/index.js.map +1 -1
- package/lib/molecule/dashboard/review-banner/index.js +1 -1
- package/lib/molecule/dashboard/review-banner/index.js.map +1 -1
- package/lib/molecule/dashboard/start-battle/index.js +1 -1
- package/lib/molecule/dashboard/start-battle/index.js.map +1 -1
- package/lib/molecule/questions/drop-down/index.d.ts +16 -0
- package/lib/molecule/questions/drop-down/index.d.ts.map +1 -0
- package/lib/molecule/questions/free-text/index.d.ts +35 -0
- package/lib/molecule/questions/free-text/index.d.ts.map +1 -0
- package/lib/molecule/questions/free-text/test/fixtures/default.d.ts +7 -0
- package/lib/molecule/questions/free-text/test/fixtures/default.d.ts.map +1 -0
- package/lib/molecule/questions/free-text/test/fixtures/with-value-on-change.d.ts +10 -0
- package/lib/molecule/questions/free-text/test/fixtures/with-value-on-change.d.ts.map +1 -0
- package/lib/molecule/questions/free-text/test/fixtures/with-value.d.ts +8 -0
- package/lib/molecule/questions/free-text/test/fixtures/with-value.d.ts.map +1 -0
- package/lib/molecule/questions/free-text/test/fixtures.native.d.ts +2 -0
- package/lib/molecule/questions/free-text/test/fixtures.native.d.ts.map +1 -0
- package/lib/molecule/questions/mobile/draggable/test/fixtures.native.d.ts +2 -0
- package/lib/molecule/questions/mobile/draggable/test/fixtures.native.d.ts.map +1 -0
- package/lib/molecule/questions/mobile/slider/test/fixtures.native.d.ts +2 -0
- package/lib/molecule/questions/mobile/slider/test/fixtures.native.d.ts.map +1 -0
- package/lib/molecule/questions/mobile/switch/test/fixtures.native.d.ts +2 -0
- package/lib/molecule/questions/mobile/switch/test/fixtures.native.d.ts.map +1 -0
- package/lib/molecule/questions/mobile/template/test/fixtures.native.d.ts +2 -0
- package/lib/molecule/questions/mobile/template/test/fixtures.native.d.ts.map +1 -0
- package/lib/molecule/questions/qcm/index.d.ts +37 -0
- package/lib/molecule/questions/qcm/index.d.ts.map +1 -0
- package/lib/molecule/questions/qcm/test/fixtures/arabic.d.ts +11 -0
- package/lib/molecule/questions/qcm/test/fixtures/arabic.d.ts.map +1 -0
- package/lib/molecule/questions/qcm/test/fixtures/default.d.ts +12 -0
- package/lib/molecule/questions/qcm/test/fixtures/default.d.ts.map +1 -0
- package/lib/molecule/questions/qcm/test/fixtures/short-answers.d.ts +11 -0
- package/lib/molecule/questions/qcm/test/fixtures/short-answers.d.ts.map +1 -0
- package/lib/molecule/questions/qcm-drag/index.d.ts +68 -0
- package/lib/molecule/questions/qcm-drag/index.d.ts.map +1 -0
- package/lib/molecule/questions/qcm-drag/test/fixtures/default.d.ts +17 -0
- package/lib/molecule/questions/qcm-drag/test/fixtures/default.d.ts.map +1 -0
- package/lib/molecule/questions/qcm-graphic/index.d.ts +38 -0
- package/lib/molecule/questions/qcm-graphic/index.d.ts.map +1 -0
- package/lib/molecule/questions/qcm-graphic/test/fixtures/default.d.ts +12 -0
- package/lib/molecule/questions/qcm-graphic/test/fixtures/default.d.ts.map +1 -0
- package/lib/molecule/questions/question-range/index.d.ts +38 -0
- package/lib/molecule/questions/question-range/index.d.ts.map +1 -0
- package/lib/molecule/questions/question-range/test/fixtures/default.d.ts +11 -0
- package/lib/molecule/questions/question-range/test/fixtures/default.d.ts.map +1 -0
- package/lib/molecule/questions/template/index.d.ts +31 -0
- package/lib/molecule/questions/template/index.d.ts.map +1 -0
- package/lib/molecule/review-card-congrats/index.d.ts +8 -0
- package/lib/molecule/review-card-congrats/index.d.ts.map +1 -0
- package/lib/molecule/review-card-congrats/prop-types.d.ts +14 -1
- package/lib/molecule/review-card-congrats/prop-types.d.ts.map +1 -1
- package/lib/molecule/review-card-congrats/prop-types.js.map +1 -1
- package/lib/molecule/review-card-congrats/test/fixtures/rank.d.ts +28 -0
- package/lib/molecule/review-card-congrats/test/fixtures/rank.d.ts.map +1 -0
- package/lib/molecule/review-card-congrats/test/fixtures/star.d.ts +31 -0
- package/lib/molecule/review-card-congrats/test/fixtures/star.d.ts.map +1 -0
- package/lib/molecule/review-correction-popin/index.d.ts +7 -0
- package/lib/molecule/review-correction-popin/index.d.ts.map +1 -0
- package/lib/molecule/review-correction-popin/prop-types.d.ts +26 -9
- package/lib/molecule/review-correction-popin/prop-types.d.ts.map +1 -1
- package/lib/molecule/review-correction-popin/prop-types.js +2 -1
- package/lib/molecule/review-correction-popin/prop-types.js.map +1 -1
- package/lib/molecule/review-correction-popin/test/fixtures/right.d.ts +18 -0
- package/lib/molecule/review-correction-popin/test/fixtures/right.d.ts.map +1 -0
- package/lib/molecule/review-correction-popin/test/fixtures/wrong.d.ts +22 -0
- package/lib/molecule/review-correction-popin/test/fixtures/wrong.d.ts.map +1 -0
- package/lib/molecule/review-header-steps/index.d.ts +7 -0
- package/lib/molecule/review-header-steps/index.d.ts.map +1 -0
- package/lib/molecule/review-header-steps/prop-types.d.ts +9 -5
- package/lib/molecule/review-header-steps/prop-types.d.ts.map +1 -1
- package/lib/molecule/review-header-steps/prop-types.js +2 -1
- package/lib/molecule/review-header-steps/prop-types.js.map +1 -1
- package/lib/molecule/review-header-steps/test/fixtures/all-questions-ok.d.ts +7 -0
- package/lib/molecule/review-header-steps/test/fixtures/all-questions-ok.d.ts.map +1 -0
- package/lib/molecule/review-header-steps/test/fixtures/current-question-no-aswered.d.ts +7 -0
- package/lib/molecule/review-header-steps/test/fixtures/current-question-no-aswered.d.ts.map +1 -0
- package/lib/molecule/review-header-steps/test/fixtures/current-question-wrong.d.ts +7 -0
- package/lib/molecule/review-header-steps/test/fixtures/current-question-wrong.d.ts.map +1 -0
- package/lib/molecule/review-header-steps/test/fixtures/first-question-current-right.d.ts +7 -0
- package/lib/molecule/review-header-steps/test/fixtures/first-question-current-right.d.ts.map +1 -0
- package/lib/molecule/review-header-steps/test/fixtures/no-answered-question.d.ts +7 -0
- package/lib/molecule/review-header-steps/test/fixtures/no-answered-question.d.ts.map +1 -0
- package/lib/molecule/review-header-steps/test/fixtures/question-to-repeat.d.ts +7 -0
- package/lib/molecule/review-header-steps/test/fixtures/question-to-repeat.d.ts.map +1 -0
- package/lib/molecule/share/index.js +1 -1
- package/lib/molecule/share/index.js.map +1 -1
- package/lib/molecule/skill-card/index.d.ts +7 -0
- package/lib/molecule/skill-card/index.d.ts.map +1 -0
- package/lib/molecule/skill-card/test/fixtures/default.d.ts +16 -0
- package/lib/molecule/skill-card/test/fixtures/default.d.ts.map +1 -0
- package/lib/molecule/video-iframe/index.d.ts +22 -0
- package/lib/molecule/video-iframe/index.d.ts.map +1 -0
- package/lib/molecule/video-player/index.d.ts +51 -0
- package/lib/molecule/video-player/index.d.ts.map +1 -0
- package/lib/molecule/video-player/jwplayer.d.ts +58 -0
- package/lib/molecule/video-player/jwplayer.d.ts.map +1 -0
- package/lib/molecule/video-player/vimeo.d.ts +154 -0
- package/lib/molecule/video-player/vimeo.d.ts.map +1 -0
- package/lib/organism/header-v2/test/fixtures.native.d.ts +2 -0
- package/lib/organism/header-v2/test/fixtures.native.d.ts.map +1 -0
- package/lib/organism/mobile-navigation/test/fixtures.native.d.ts +2 -0
- package/lib/organism/mobile-navigation/test/fixtures.native.d.ts.map +1 -0
- package/lib/organism/review-congrats/index.d.ts +8 -0
- package/lib/organism/review-congrats/index.d.ts.map +1 -0
- package/lib/organism/review-congrats/prop-types.d.ts +25 -3
- package/lib/organism/review-congrats/prop-types.d.ts.map +1 -1
- package/lib/organism/review-congrats/prop-types.js +2 -1
- package/lib/organism/review-congrats/prop-types.js.map +1 -1
- package/lib/organism/review-congrats/test/fixtures/default.d.ts +7 -0
- package/lib/organism/review-congrats/test/fixtures/default.d.ts.map +1 -0
- package/lib/organism/review-header/index.d.ts +7 -0
- package/lib/organism/review-header/index.d.ts.map +1 -0
- package/lib/organism/review-header/index.native.d.ts +2 -2
- package/lib/organism/review-header/index.native.d.ts.map +1 -1
- package/lib/organism/review-header/index.native.js.map +1 -1
- package/lib/organism/review-header/test/fixtures/all-questions-ok.d.ts +15 -0
- package/lib/organism/review-header/test/fixtures/all-questions-ok.d.ts.map +1 -0
- package/lib/organism/review-header/test/fixtures/current-question-no-answered.d.ts +7 -0
- package/lib/organism/review-header/test/fixtures/current-question-no-answered.d.ts.map +1 -0
- package/lib/organism/review-header/test/fixtures/current-question-wrong.d.ts +7 -0
- package/lib/organism/review-header/test/fixtures/current-question-wrong.d.ts.map +1 -0
- package/lib/organism/review-header/test/fixtures/first-question-current-right.d.ts +7 -0
- package/lib/organism/review-header/test/fixtures/first-question-current-right.d.ts.map +1 -0
- package/lib/organism/review-header/test/fixtures/no-answered-question.d.ts +7 -0
- package/lib/organism/review-header/test/fixtures/no-answered-question.d.ts.map +1 -0
- package/lib/organism/review-header/test/fixtures/question-to-repeat.d.ts +7 -0
- package/lib/organism/review-header/test/fixtures/question-to-repeat.d.ts.map +1 -0
- package/lib/organism/review-header/test/fixtures/steps-animation.d.ts +7 -0
- package/lib/organism/review-header/test/fixtures/steps-animation.d.ts.map +1 -0
- package/lib/organism/review-header/test/fixtures.native.d.ts +2 -0
- package/lib/organism/review-header/test/fixtures.native.d.ts.map +1 -0
- package/lib/organism/review-header/types.d.ts +4 -4
- package/lib/organism/review-header/types.d.ts.map +1 -1
- package/lib/organism/review-header/types.js.map +1 -1
- package/lib/organism/review-skills/index.d.ts +7 -0
- package/lib/organism/review-skills/index.d.ts.map +1 -0
- package/lib/organism/review-skills/test/fixtures/many-skills.d.ts +22 -0
- package/lib/organism/review-skills/test/fixtures/many-skills.d.ts.map +1 -0
- package/lib/organism/review-skills/test/fixtures/no-skills.d.ts +12 -0
- package/lib/organism/review-skills/test/fixtures/no-skills.d.ts.map +1 -0
- package/lib/organism/review-slide/index.d.ts +7 -0
- package/lib/organism/review-slide/index.d.ts.map +1 -0
- package/lib/organism/review-slide/index.native.d.ts +2 -2
- package/lib/organism/review-slide/index.native.d.ts.map +1 -1
- package/lib/organism/review-slide/index.native.js +3 -3
- package/lib/organism/review-slide/index.native.js.map +1 -1
- package/lib/organism/review-slide/prop-types.d.ts +21 -36
- package/lib/organism/review-slide/prop-types.d.ts.map +1 -1
- package/lib/organism/review-slide/prop-types.js.map +1 -1
- package/lib/organism/review-slide/test/fixtures/choices-selected.d.ts +22 -0
- package/lib/organism/review-slide/test/fixtures/choices-selected.d.ts.map +1 -0
- package/lib/organism/review-slide/test/fixtures/correction-ok-animated.d.ts +36 -0
- package/lib/organism/review-slide/test/fixtures/correction-ok-animated.d.ts.map +1 -0
- package/lib/organism/review-slide/test/fixtures/correction-ok.d.ts +36 -0
- package/lib/organism/review-slide/test/fixtures/correction-ok.d.ts.map +1 -0
- package/lib/organism/review-slide/test/fixtures/correction-wrong-animated.d.ts +38 -0
- package/lib/organism/review-slide/test/fixtures/correction-wrong-animated.d.ts.map +1 -0
- package/lib/organism/review-slide/test/fixtures/correction-wrong.d.ts +38 -0
- package/lib/organism/review-slide/test/fixtures/correction-wrong.d.ts.map +1 -0
- package/lib/organism/review-slide/test/fixtures/initial-state.d.ts +22 -0
- package/lib/organism/review-slide/test/fixtures/initial-state.d.ts.map +1 -0
- package/lib/organism/review-slide/test/fixtures/loading.d.ts +12 -0
- package/lib/organism/review-slide/test/fixtures/loading.d.ts.map +1 -0
- package/lib/organism/review-slide/test/fixtures.native.d.ts +2 -0
- package/lib/organism/review-slide/test/fixtures.native.d.ts.map +1 -0
- package/lib/organism/review-stacked-slides/index.d.ts +13 -0
- package/lib/organism/review-stacked-slides/index.d.ts.map +1 -0
- package/lib/organism/review-stacked-slides/index.js +3 -6
- package/lib/organism/review-stacked-slides/index.js.map +1 -1
- package/lib/organism/review-stacked-slides/index.native.d.ts +2 -2
- package/lib/organism/review-stacked-slides/index.native.d.ts.map +1 -1
- package/lib/organism/review-stacked-slides/index.native.js +3 -6
- package/lib/organism/review-stacked-slides/index.native.js.map +1 -1
- package/lib/organism/review-stacked-slides/prop-types.d.ts +26 -25
- package/lib/organism/review-stacked-slides/prop-types.d.ts.map +1 -1
- package/lib/organism/review-stacked-slides/prop-types.js.map +1 -1
- package/lib/organism/review-stacked-slides/test/fixtures/all-ok.d.ts +9 -0
- package/lib/organism/review-stacked-slides/test/fixtures/all-ok.d.ts.map +1 -0
- package/lib/organism/review-stacked-slides/test/fixtures/end-review.d.ts +7 -0
- package/lib/organism/review-stacked-slides/test/fixtures/end-review.d.ts.map +1 -0
- package/lib/organism/review-stacked-slides/test/fixtures/first-correct.d.ts +9 -0
- package/lib/organism/review-stacked-slides/test/fixtures/first-correct.d.ts.map +1 -0
- package/lib/organism/review-stacked-slides/test/fixtures/initial-state.d.ts +7 -0
- package/lib/organism/review-stacked-slides/test/fixtures/initial-state.d.ts.map +1 -0
- package/lib/organism/review-stacked-slides/test/fixtures/loading.d.ts +7 -0
- package/lib/organism/review-stacked-slides/test/fixtures/loading.d.ts.map +1 -0
- package/lib/organism/review-stacked-slides/test/fixtures/restack.d.ts +9 -0
- package/lib/organism/review-stacked-slides/test/fixtures/restack.d.ts.map +1 -0
- package/lib/organism/review-stacked-slides/test/fixtures/second-wrong.d.ts +9 -0
- package/lib/organism/review-stacked-slides/test/fixtures/second-wrong.d.ts.map +1 -0
- package/lib/organism/review-stacked-slides/test/fixtures/unstack.d.ts +9 -0
- package/lib/organism/review-stacked-slides/test/fixtures/unstack.d.ts.map +1 -0
- package/lib/organism/review-stacked-slides/test/fixtures/wrong.d.ts +9 -0
- package/lib/organism/review-stacked-slides/test/fixtures/wrong.d.ts.map +1 -0
- package/lib/organism/review-stacked-slides/test/fixtures.native.d.ts +2 -0
- package/lib/organism/review-stacked-slides/test/fixtures.native.d.ts.map +1 -0
- package/lib/template/app-player/popin-end/summary.js +3 -4
- package/lib/template/app-player/popin-end/summary.js.map +1 -1
- package/lib/template/app-review/demo-ts/test/fixtures.native.d.ts +2 -0
- package/lib/template/app-review/demo-ts/test/fixtures.native.d.ts.map +1 -0
- package/lib/template/app-review/index.d.ts +603 -0
- package/lib/template/app-review/index.d.ts.map +1 -0
- package/lib/template/app-review/index.js +15 -24
- package/lib/template/app-review/index.js.map +1 -1
- package/lib/template/app-review/index.native.d.ts +5 -0
- package/lib/template/app-review/index.native.d.ts.map +1 -0
- package/lib/template/app-review/index.native.js +20 -26
- package/lib/template/app-review/index.native.js.map +1 -1
- package/lib/template/app-review/onboarding/index.d.ts +3 -0
- package/lib/template/app-review/onboarding/index.d.ts.map +1 -0
- package/lib/template/app-review/onboarding/index.native.d.ts +9 -0
- package/lib/template/app-review/onboarding/index.native.d.ts.map +1 -0
- package/lib/template/app-review/onboarding/test/fixtures/default.d.ts +3 -0
- package/lib/template/app-review/onboarding/test/fixtures/default.d.ts.map +1 -0
- package/lib/template/app-review/onboarding/test/fixtures.native.d.ts +2 -0
- package/lib/template/app-review/onboarding/test/fixtures.native.d.ts.map +1 -0
- package/lib/template/app-review/player/index.d.ts +13 -0
- package/lib/template/app-review/player/index.d.ts.map +1 -0
- package/lib/template/app-review/player/index.native.d.ts +2 -2
- package/lib/template/app-review/player/index.native.d.ts.map +1 -1
- package/lib/template/app-review/player/index.native.js.map +1 -1
- package/lib/template/app-review/player/prop-types.d.ts +31 -31
- package/lib/template/app-review/player/prop-types.d.ts.map +1 -1
- package/lib/template/app-review/player/prop-types.js.map +1 -1
- package/lib/template/app-review/player/test/fixtures/all-ok.d.ts +7 -0
- package/lib/template/app-review/player/test/fixtures/all-ok.d.ts.map +1 -0
- package/lib/template/app-review/player/test/fixtures/end-review.d.ts +7 -0
- package/lib/template/app-review/player/test/fixtures/end-review.d.ts.map +1 -0
- package/lib/template/app-review/player/test/fixtures/first-right.d.ts +7 -0
- package/lib/template/app-review/player/test/fixtures/first-right.d.ts.map +1 -0
- package/lib/template/app-review/player/test/fixtures/initial-state.d.ts +7 -0
- package/lib/template/app-review/player/test/fixtures/initial-state.d.ts.map +1 -0
- package/lib/template/app-review/player/test/fixtures/loading.d.ts +7 -0
- package/lib/template/app-review/player/test/fixtures/loading.d.ts.map +1 -0
- package/lib/template/app-review/player/test/fixtures/on-quit.d.ts +7 -0
- package/lib/template/app-review/player/test/fixtures/on-quit.d.ts.map +1 -0
- package/lib/template/app-review/player/test/fixtures/one-fail.d.ts +7 -0
- package/lib/template/app-review/player/test/fixtures/one-fail.d.ts.map +1 -0
- package/lib/template/app-review/player/test/fixtures/restack.d.ts +7 -0
- package/lib/template/app-review/player/test/fixtures/restack.d.ts.map +1 -0
- package/lib/template/app-review/player/test/fixtures/second-failed-question.d.ts +7 -0
- package/lib/template/app-review/player/test/fixtures/second-failed-question.d.ts.map +1 -0
- package/lib/template/app-review/player/test/fixtures/unstack.d.ts +7 -0
- package/lib/template/app-review/player/test/fixtures/unstack.d.ts.map +1 -0
- package/lib/template/app-review/player/test/fixtures.native.d.ts +2 -0
- package/lib/template/app-review/player/test/fixtures.native.d.ts.map +1 -0
- package/lib/template/app-review/prop-types.d.ts +610 -0
- package/lib/template/app-review/prop-types.d.ts.map +1 -0
- package/lib/template/app-review/prop-types.js +4 -12
- package/lib/template/app-review/prop-types.js.map +1 -1
- package/lib/template/app-review/skills/index.d.ts +3 -0
- package/lib/template/app-review/skills/index.d.ts.map +1 -0
- package/lib/template/app-review/skills/test/fixtures/many-skills.d.ts +3 -0
- package/lib/template/app-review/skills/test/fixtures/many-skills.d.ts.map +1 -0
- package/lib/template/app-review/skills/test/fixtures/no-skills.d.ts +3 -0
- package/lib/template/app-review/skills/test/fixtures/no-skills.d.ts.map +1 -0
- package/lib/template/app-review/skills/test/fixtures.native.d.ts +2 -0
- package/lib/template/app-review/skills/test/fixtures.native.d.ts.map +1 -0
- package/lib/template/app-review/template-context.js +1 -1
- package/lib/template/app-review/template-context.js.map +1 -1
- package/lib/template/app-review/test/fixtures/onboarding.d.ts +7 -0
- package/lib/template/app-review/test/fixtures/onboarding.d.ts.map +1 -0
- package/lib/template/app-review/test/fixtures/player.d.ts +7 -0
- package/lib/template/app-review/test/fixtures/player.d.ts.map +1 -0
- package/lib/template/app-review/test/fixtures/skills.d.ts +7 -0
- package/lib/template/app-review/test/fixtures/skills.d.ts.map +1 -0
- package/lib/template/app-review/test/fixtures.native.d.ts +2 -0
- package/lib/template/app-review/test/fixtures.native.d.ts.map +1 -0
- package/lib/template/common/dashboard/index.js +1 -1
- package/lib/template/common/dashboard/index.js.map +1 -1
- package/lib/test/helpers/render-component.d.ts +20 -0
- package/lib/test/helpers/render-component.d.ts.map +1 -0
- package/lib/util/get-shadow-box-color-from-primary.d.ts +2 -0
- package/lib/util/get-shadow-box-color-from-primary.d.ts.map +1 -0
- package/package.json +2 -2
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"fixtures.native.d.ts","sourceRoot":"","sources":["../../../../src/atom/space/test/fixtures.native.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"fixtures.native.d.ts","sourceRoot":"","sources":["../../../../src/atom/text/test/fixtures.native.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
export const LINEAR: any;
|
|
2
|
+
export const EASE_IN_QUAD: any;
|
|
3
|
+
export const EASE_IN_CUBIC: any;
|
|
4
|
+
export const EASE_IN_QUART: any;
|
|
5
|
+
export const EASE_IN_QUINT: any;
|
|
6
|
+
export const EASE_IN_SINE: any;
|
|
7
|
+
export const EASE_IN_EXPO: any;
|
|
8
|
+
export const EASE_IN_CIRC: any;
|
|
9
|
+
export const EASE_IN_BACK: any;
|
|
10
|
+
export const EASE_OUT_QUAD: any;
|
|
11
|
+
export const EASE_OUT_CUBIC: any;
|
|
12
|
+
export const EASE_OUT_QUART: any;
|
|
13
|
+
export const EASE_OUT_QUINT: any;
|
|
14
|
+
export const EASE_OUT_SINE: any;
|
|
15
|
+
export const EASE_OUT_EXPO: any;
|
|
16
|
+
export const EASE_OUT_CIRC: any;
|
|
17
|
+
export const EASE_OUT_BACK: any;
|
|
18
|
+
export const EASE_IN_OUT_QUAD: any;
|
|
19
|
+
export const EASE_IN_OUT_CUBIC: any;
|
|
20
|
+
export const EASE_IN_OUT_QUART: any;
|
|
21
|
+
export const EASE_IN_OUT_QUINT: any;
|
|
22
|
+
export const EASE_IN_OUT_SINE: any;
|
|
23
|
+
export const EASE_IN_OUT_EXPO: any;
|
|
24
|
+
export const EASE_IN_OUT_CIRC: any;
|
|
25
|
+
export const EASE_IN_OUT_BACK: any;
|
|
26
|
+
export const SWIFT_OUT: any;
|
|
27
|
+
export const BOUNCE: any;
|
|
28
|
+
export default Animation;
|
|
29
|
+
declare class Animation extends React.Component<any, any, any> {
|
|
30
|
+
static propTypes: {
|
|
31
|
+
name: PropTypes.Validator<string>;
|
|
32
|
+
bezier: PropTypes.Validator<(...args: any[]) => any>;
|
|
33
|
+
duration: PropTypes.Validator<number>;
|
|
34
|
+
onAnimationEnd: PropTypes.Requireable<(...args: any[]) => any>;
|
|
35
|
+
animated: PropTypes.Requireable<boolean>;
|
|
36
|
+
children: PropTypes.Requireable<(...args: any[]) => any>;
|
|
37
|
+
};
|
|
38
|
+
constructor(props: any);
|
|
39
|
+
state: {
|
|
40
|
+
progress: number;
|
|
41
|
+
requestID: null;
|
|
42
|
+
};
|
|
43
|
+
componentDidMount(): void;
|
|
44
|
+
componentDidUpdate(prevProps: any): void;
|
|
45
|
+
componentWillUnmount(): void;
|
|
46
|
+
startAnimation(): void;
|
|
47
|
+
stopAnimation(): void;
|
|
48
|
+
tick(timestamp: any): void;
|
|
49
|
+
getProgress(deltaDuration: any): number;
|
|
50
|
+
render(): any;
|
|
51
|
+
}
|
|
52
|
+
import React from "react";
|
|
53
|
+
import PropTypes from "prop-types";
|
|
54
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/hoc/animation/index.js"],"names":[],"mappings":"AAMA,yBAAkD;AAClD,+BAAoE;AACpE,gCAAqE;AACrE,gCAAqE;AACrE,gCAAqE;AACrE,+BAAiE;AACjE,+BAAoE;AACpE,+BAAmE;AACnE,+BAAoE;AACpE,gCAAqE;AACrE,iCAAmE;AACnE,iCAAmE;AACnE,iCAAgE;AAChE,gCAAkE;AAClE,gCAA+D;AAC/D,gCAAkE;AAClE,gCAAqE;AACrE,mCAAwE;AACxE,oCAAsE;AACtE,oCAAmE;AACnE,oCAAmE;AACnE,mCAAwE;AACxE,mCAA4D;AAC5D,mCAAwE;AACxE,mCAAyE;AACzE,4BAA0D;AAC1D,yBAA6D;;AAE7D;IACE;;;;;;;MAOE;IAEF,wBAOC;IAJC;;;MAGC;IAGH,0BAGC;IAED,yCAQC;IAED,6BAEC;IAED,uBAUC;IAED,sBAWC;IAED,2BAuBC;IAED,wCAGC;IAED,cAMC;CACF"}
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
export default AnimationScheduler;
|
|
2
|
+
declare class AnimationScheduler extends React.Component<any, any, any> {
|
|
3
|
+
static propTypes: {
|
|
4
|
+
onAnimationEnd: PropTypes.Requireable<(...args: any[]) => any>;
|
|
5
|
+
animated: PropTypes.Requireable<boolean>;
|
|
6
|
+
children: PropTypes.Requireable<PropTypes.ReactNodeLike>;
|
|
7
|
+
};
|
|
8
|
+
static getDerivedStateFromProps(props: any, state: any): {
|
|
9
|
+
animations: any;
|
|
10
|
+
};
|
|
11
|
+
constructor(props: any);
|
|
12
|
+
state: {
|
|
13
|
+
animations: any;
|
|
14
|
+
};
|
|
15
|
+
isAnimated(after: any): boolean;
|
|
16
|
+
handlerAnimationEnd(name: any): void;
|
|
17
|
+
processAnimation(child: any): React.DetailedReactHTMLElement<{
|
|
18
|
+
animated: any;
|
|
19
|
+
onAnimationEnd: (name: React.AnimationEvent<HTMLElement>) => any;
|
|
20
|
+
}, HTMLElement>;
|
|
21
|
+
render(): any;
|
|
22
|
+
}
|
|
23
|
+
export function AnimationAdapter({ animated, onAnimationEnd, name, children }: {
|
|
24
|
+
animated: any;
|
|
25
|
+
onAnimationEnd?: import("lodash/fp").LodashNoop | undefined;
|
|
26
|
+
name: any;
|
|
27
|
+
children: any;
|
|
28
|
+
}): any;
|
|
29
|
+
export namespace AnimationAdapter {
|
|
30
|
+
namespace propTypes {
|
|
31
|
+
const name: PropTypes.Validator<string>;
|
|
32
|
+
const onAnimationEnd: PropTypes.Requireable<(...args: any[]) => any>;
|
|
33
|
+
const animated: PropTypes.Requireable<boolean>;
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
import React from "react";
|
|
37
|
+
import PropTypes from "prop-types";
|
|
38
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/hoc/animation-scheduler/index.js"],"names":[],"mappings":";AAoFA;IACE;;;;MAIE;IAEF;;MAMC;IAED,wBAOC;IAHC;;MAEC;IAGH,gCAWC;IAED,qCAUC;IAED;;;oBAWC;IAED,cAOC;CACF;AAlID;;;;;QAOC"}
|
|
@@ -26,7 +26,7 @@ const AnimationAdapter = ({
|
|
|
26
26
|
name,
|
|
27
27
|
children
|
|
28
28
|
}) => {
|
|
29
|
-
return React.Children.map(children, child => React.cloneElement(child, {
|
|
29
|
+
return React.Children.map(children, child => /*#__PURE__*/React.cloneElement(child, {
|
|
30
30
|
animated,
|
|
31
31
|
onAnimationEnd: () => onAnimationEnd(name)
|
|
32
32
|
}));
|
|
@@ -47,7 +47,7 @@ const walker = (type, handler) => children => {
|
|
|
47
47
|
if (_isNil(child) || _isString(child)) return child;
|
|
48
48
|
const newChild = child.type === type ? handler(child) : child;
|
|
49
49
|
if (React.Children.count(newChild.props.children) === 0) return newChild;
|
|
50
|
-
return React.cloneElement(newChild, {}, walker(type, handler)(newChild.props.children));
|
|
50
|
+
return /*#__PURE__*/React.cloneElement(newChild, {}, walker(type, handler)(newChild.props.children));
|
|
51
51
|
});
|
|
52
52
|
};
|
|
53
53
|
|
|
@@ -136,7 +136,7 @@ class AnimationScheduler extends React.Component {
|
|
|
136
136
|
onAnimationEnd = _noop,
|
|
137
137
|
after
|
|
138
138
|
} = child.props;
|
|
139
|
-
return React.cloneElement(child, {
|
|
139
|
+
return /*#__PURE__*/React.cloneElement(child, {
|
|
140
140
|
animated: parentAnimated ? this.isAnimated(after) || animated : animated,
|
|
141
141
|
onAnimationEnd: name => {
|
|
142
142
|
this.handlerAnimationEnd(name);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","names":["React","PropTypes","Animation","Transition","AnimationAdapter","animated","onAnimationEnd","name","children","Children","map","child","cloneElement","propTypes","string","isRequired","func","bool","pickByWithKey","convert","cap","walker","type","handler","index","newChild","count","props","reduceChildren","fun","acc","newAcc","getAnimationNames","mergeAnimationStates","animations","names","value","key","AnimationScheduler","Component","getDerivedStateFromProps","state","constructor","isAnimated","after","handlerAnimationEnd","setState","hasPendingAnimation","processAnimation","parentAnimated","render","bind","node"],"sources":["../../../src/hoc/animation-scheduler/index.js"],"sourcesContent":["import React from 'react';\nimport PropTypes from 'prop-types';\nimport {\n assign,\n every,\n getOr,\n get,\n includes,\n isArray,\n isNil,\n isString,\n noop,\n pickBy,\n some,\n negate,\n identity,\n values,\n pipe,\n reduce,\n set\n} from 'lodash/fp';\nimport Animation from '../animation';\nimport Transition from '../transition';\n\nconst AnimationAdapter = ({animated, onAnimationEnd = noop, name, children}) => {\n return React.Children.map(children, child =>\n React.cloneElement(child, {\n animated,\n onAnimationEnd: () => onAnimationEnd(name)\n })\n );\n};\n\nAnimationAdapter.propTypes = {\n name: PropTypes.string.isRequired,\n onAnimationEnd: PropTypes.func,\n animated: PropTypes.bool\n};\n\nconst pickByWithKey = pickBy.convert({cap: true});\n\nconst walker = (type, handler) => children => {\n return React.Children.map(children, (child, index) => {\n if (isNil(child) || isString(child)) return child;\n const newChild = child.type === type ? handler(child) : child;\n if (React.Children.count(newChild.props.children) === 0) return newChild;\n return React.cloneElement(newChild, {}, walker(type, handler)(newChild.props.children));\n });\n};\n\nconst reduceChildren = fun => acc => children => {\n let newAcc = acc;\n React.Children.map(children, child => {\n newAcc = fun(newAcc, child);\n return child;\n });\n return newAcc;\n};\n\nconst getAnimationNames = reduceChildren((acc, child) => {\n if (isString(child)) return acc;\n\n const {\n type,\n props: {children}\n } = child;\n if (Animation !== type && Transition !== type && AnimationAdapter !== type)\n return [...acc, ...getAnimationNames(children)];\n\n const {\n props: {name}\n } = child;\n return [name, ...acc, ...getAnimationNames(children)];\n})([]);\n\nconst mergeAnimationStates = (animations, children) => {\n const names = getAnimationNames(children);\n\n return pipe(\n pickByWithKey((value, key) => includes(key, names)),\n assign(reduce((acc, name) => set(name, false, acc), {}, names))\n )(animations);\n};\n\nclass AnimationScheduler extends React.Component {\n static propTypes = {\n onAnimationEnd: PropTypes.func,\n animated: PropTypes.bool,\n children: PropTypes.node\n };\n\n static getDerivedStateFromProps(props, state) {\n const {children} = props;\n const {animations} = state;\n return {\n animations: mergeAnimationStates(animations, children)\n };\n }\n\n constructor(props) {\n super(props);\n\n const {children} = props;\n this.state = {\n animations: mergeAnimationStates({}, children)\n };\n }\n\n isAnimated(after) {\n if (isNil(after)) return true;\n\n const {animations} = this.state;\n\n const isAnimated = every(\n name => getOr(false, name, animations),\n isArray(after) ? after : [after]\n );\n\n return isAnimated;\n }\n\n handlerAnimationEnd(name) {\n this.setState(set(['animations', name], true), () => {\n const hasPendingAnimation = pipe(\n get('state.animations'),\n values,\n some(negate(identity))\n )(this);\n const {onAnimationEnd = noop} = this.props;\n if (!hasPendingAnimation) return onAnimationEnd();\n });\n }\n\n processAnimation(child) {\n const {animated: parentAnimated} = this.props;\n const {animated, onAnimationEnd = noop, after} = child.props;\n\n return React.cloneElement(child, {\n animated: parentAnimated ? this.isAnimated(after) || animated : animated,\n onAnimationEnd: name => {\n this.handlerAnimationEnd(name);\n return onAnimationEnd(name);\n }\n });\n }\n\n render() {\n const {children} = this.props;\n return pipe(\n walker(Animation, this.processAnimation.bind(this)),\n walker(Transition, this.processAnimation.bind(this)),\n walker(AnimationAdapter, this.processAnimation.bind(this))\n )(children);\n }\n}\n\nexport default AnimationScheduler;\n\nexport {AnimationAdapter};\n"],"mappings":";;;;;;;;;;;;;;;;;AAAA,OAAOA,KAAP,MAAkB,OAAlB;AACA,OAAOC,SAAP,MAAsB,YAAtB;AAoBA,OAAOC,SAAP,MAAsB,cAAtB;AACA,OAAOC,UAAP,MAAuB,eAAvB;;AAEA,MAAMC,gBAAgB,GAAG,CAAC;EAACC,QAAD;EAAWC,cAAc,QAAzB;EAAkCC,IAAlC;EAAwCC;AAAxC,CAAD,KAAuD;EAC9E,OAAOR,KAAK,CAACS,QAAN,CAAeC,GAAf,CAAmBF,QAAnB,EAA6BG,KAAK,
|
|
1
|
+
{"version":3,"file":"index.js","names":["React","PropTypes","Animation","Transition","AnimationAdapter","animated","onAnimationEnd","name","children","Children","map","child","cloneElement","propTypes","string","isRequired","func","bool","pickByWithKey","convert","cap","walker","type","handler","index","newChild","count","props","reduceChildren","fun","acc","newAcc","getAnimationNames","mergeAnimationStates","animations","names","value","key","AnimationScheduler","Component","getDerivedStateFromProps","state","constructor","isAnimated","after","handlerAnimationEnd","setState","hasPendingAnimation","processAnimation","parentAnimated","render","bind","node"],"sources":["../../../src/hoc/animation-scheduler/index.js"],"sourcesContent":["import React from 'react';\nimport PropTypes from 'prop-types';\nimport {\n assign,\n every,\n getOr,\n get,\n includes,\n isArray,\n isNil,\n isString,\n noop,\n pickBy,\n some,\n negate,\n identity,\n values,\n pipe,\n reduce,\n set\n} from 'lodash/fp';\nimport Animation from '../animation';\nimport Transition from '../transition';\n\nconst AnimationAdapter = ({animated, onAnimationEnd = noop, name, children}) => {\n return React.Children.map(children, child =>\n React.cloneElement(child, {\n animated,\n onAnimationEnd: () => onAnimationEnd(name)\n })\n );\n};\n\nAnimationAdapter.propTypes = {\n name: PropTypes.string.isRequired,\n onAnimationEnd: PropTypes.func,\n animated: PropTypes.bool\n};\n\nconst pickByWithKey = pickBy.convert({cap: true});\n\nconst walker = (type, handler) => children => {\n return React.Children.map(children, (child, index) => {\n if (isNil(child) || isString(child)) return child;\n const newChild = child.type === type ? handler(child) : child;\n if (React.Children.count(newChild.props.children) === 0) return newChild;\n return React.cloneElement(newChild, {}, walker(type, handler)(newChild.props.children));\n });\n};\n\nconst reduceChildren = fun => acc => children => {\n let newAcc = acc;\n React.Children.map(children, child => {\n newAcc = fun(newAcc, child);\n return child;\n });\n return newAcc;\n};\n\nconst getAnimationNames = reduceChildren((acc, child) => {\n if (isString(child)) return acc;\n\n const {\n type,\n props: {children}\n } = child;\n if (Animation !== type && Transition !== type && AnimationAdapter !== type)\n return [...acc, ...getAnimationNames(children)];\n\n const {\n props: {name}\n } = child;\n return [name, ...acc, ...getAnimationNames(children)];\n})([]);\n\nconst mergeAnimationStates = (animations, children) => {\n const names = getAnimationNames(children);\n\n return pipe(\n pickByWithKey((value, key) => includes(key, names)),\n assign(reduce((acc, name) => set(name, false, acc), {}, names))\n )(animations);\n};\n\nclass AnimationScheduler extends React.Component {\n static propTypes = {\n onAnimationEnd: PropTypes.func,\n animated: PropTypes.bool,\n children: PropTypes.node\n };\n\n static getDerivedStateFromProps(props, state) {\n const {children} = props;\n const {animations} = state;\n return {\n animations: mergeAnimationStates(animations, children)\n };\n }\n\n constructor(props) {\n super(props);\n\n const {children} = props;\n this.state = {\n animations: mergeAnimationStates({}, children)\n };\n }\n\n isAnimated(after) {\n if (isNil(after)) return true;\n\n const {animations} = this.state;\n\n const isAnimated = every(\n name => getOr(false, name, animations),\n isArray(after) ? after : [after]\n );\n\n return isAnimated;\n }\n\n handlerAnimationEnd(name) {\n this.setState(set(['animations', name], true), () => {\n const hasPendingAnimation = pipe(\n get('state.animations'),\n values,\n some(negate(identity))\n )(this);\n const {onAnimationEnd = noop} = this.props;\n if (!hasPendingAnimation) return onAnimationEnd();\n });\n }\n\n processAnimation(child) {\n const {animated: parentAnimated} = this.props;\n const {animated, onAnimationEnd = noop, after} = child.props;\n\n return React.cloneElement(child, {\n animated: parentAnimated ? this.isAnimated(after) || animated : animated,\n onAnimationEnd: name => {\n this.handlerAnimationEnd(name);\n return onAnimationEnd(name);\n }\n });\n }\n\n render() {\n const {children} = this.props;\n return pipe(\n walker(Animation, this.processAnimation.bind(this)),\n walker(Transition, this.processAnimation.bind(this)),\n walker(AnimationAdapter, this.processAnimation.bind(this))\n )(children);\n }\n}\n\nexport default AnimationScheduler;\n\nexport {AnimationAdapter};\n"],"mappings":";;;;;;;;;;;;;;;;;AAAA,OAAOA,KAAP,MAAkB,OAAlB;AACA,OAAOC,SAAP,MAAsB,YAAtB;AAoBA,OAAOC,SAAP,MAAsB,cAAtB;AACA,OAAOC,UAAP,MAAuB,eAAvB;;AAEA,MAAMC,gBAAgB,GAAG,CAAC;EAACC,QAAD;EAAWC,cAAc,QAAzB;EAAkCC,IAAlC;EAAwCC;AAAxC,CAAD,KAAuD;EAC9E,OAAOR,KAAK,CAACS,QAAN,CAAeC,GAAf,CAAmBF,QAAnB,EAA6BG,KAAK,iBACvCX,KAAK,CAACY,YAAN,CAAmBD,KAAnB,EAA0B;IACxBN,QADwB;IAExBC,cAAc,EAAE,MAAMA,cAAc,CAACC,IAAD;EAFZ,CAA1B,CADK,CAAP;AAMD,CAPD;;AASAH,gBAAgB,CAACS,SAAjB,2CAA6B;EAC3BN,IAAI,EAAEN,SAAS,CAACa,MAAV,CAAiBC,UADI;EAE3BT,cAAc,EAAEL,SAAS,CAACe,IAFC;EAG3BX,QAAQ,EAAEJ,SAAS,CAACgB;AAHO,CAA7B;;AAMA,MAAMC,aAAa,GAAG,QAAOC,OAAP,CAAe;EAACC,GAAG,EAAE;AAAN,CAAf,CAAtB;;AAEA,MAAMC,MAAM,GAAG,CAACC,IAAD,EAAOC,OAAP,KAAmBf,QAAQ,IAAI;EAC5C,OAAOR,KAAK,CAACS,QAAN,CAAeC,GAAf,CAAmBF,QAAnB,EAA6B,CAACG,KAAD,EAAQa,KAAR,KAAkB;IACpD,IAAI,OAAMb,KAAN,KAAgB,UAASA,KAAT,CAApB,EAAqC,OAAOA,KAAP;IACrC,MAAMc,QAAQ,GAAGd,KAAK,CAACW,IAAN,KAAeA,IAAf,GAAsBC,OAAO,CA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AACe,IADT;EAEjBX,QAAQ,EAAEJ,SAAS,CAACgB,IAFH;EAGjBT,QAAQ,EAAEP,SAAS,CAACmD;AAHH,C;AAuErB,eAAed,kBAAf;AAEA,SAAQlC,gBAAR"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"fixtures.native.d.ts","sourceRoot":"","sources":["../../../../../src/hoc/modal/select/test/fixtures.native.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"fixtures.native.d.ts","sourceRoot":"","sources":["../../../../../src/hoc/modal/select-item/test/fixtures.native.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"fixtures.native.d.ts","sourceRoot":"","sources":["../../../../src/hoc/modal/test/fixtures.native.ts"],"names":[],"mappings":""}
|
package/es/hoc/swapper/index.js
CHANGED
|
@@ -40,7 +40,7 @@ class Swapper extends React.Component {
|
|
|
40
40
|
props = _objectWithoutPropertiesLoose(_this$props, _excluded);
|
|
41
41
|
|
|
42
42
|
const child = React.Children.only(children);
|
|
43
|
-
return init ? React.cloneElement(child, props) : child;
|
|
43
|
+
return init ? /*#__PURE__*/React.cloneElement(child, props) : child;
|
|
44
44
|
}
|
|
45
45
|
|
|
46
46
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","names":["React","PropTypes","safeCancelAnimationFrame","requestId","cancelAnimationFrame","Swapper","Component","constructor","props","state","init","componentDidMount","requestAnimationFrame","requestID","setState","componentWillUnmount","undefined","render","children","child","Children","only","cloneElement","propTypes","node"],"sources":["../../../src/hoc/swapper/index.js"],"sourcesContent":["import React from 'react';\nimport PropTypes from 'prop-types';\n\nexport const safeCancelAnimationFrame = requestId => requestId && cancelAnimationFrame(requestId);\n\nclass Swapper extends React.Component {\n static propTypes = {\n children: PropTypes.node\n };\n\n constructor(props) {\n super(props);\n\n this.state = {\n init: true\n };\n }\n\n componentDidMount() {\n if (typeof requestAnimationFrame !== 'undefined') {\n this.requestID = requestAnimationFrame(() => this.setState({init: false}));\n }\n }\n\n componentWillUnmount() {\n if (this.requestID !== undefined) {\n safeCancelAnimationFrame(this.requestID);\n }\n }\n\n render() {\n const {init} = this.state;\n const {children, ...props} = this.props;\n const child = React.Children.only(children);\n\n return init ? React.cloneElement(child, props) : child;\n }\n}\n\nexport default Swapper;\n"],"mappings":";;;;AAAA,OAAOA,KAAP,MAAkB,OAAlB;AACA,OAAOC,SAAP,MAAsB,YAAtB;AAEA,OAAO,MAAMC,wBAAwB,GAAGC,SAAS,IAAIA,SAAS,IAAIC,oBAAoB,CAACD,SAAD,CAA/E;;AAEP,MAAME,OAAN,SAAsBL,KAAK,CAACM,SAA5B,CAAsC;EAKpCC,WAAW,CAACC,KAAD,EAAQ;IACjB,MAAMA,KAAN;IAEA,KAAKC,KAAL,GAAa;MACXC,IAAI,EAAE;IADK,CAAb;EAGD;;EAEDC,iBAAiB,GAAG;IAClB,IAAI,OAAOC,qBAAP,KAAiC,WAArC,EAAkD;MAChD,KAAKC,SAAL,GAAiBD,qBAAqB,CAAC,MAAM,KAAKE,QAAL,CAAc;QAACJ,IAAI,EAAE;MAAP,CAAd,CAAP,CAAtC;IACD;EACF;;EAEDK,oBAAoB,GAAG;IACrB,IAAI,KAAKF,SAAL,KAAmBG,SAAvB,EAAkC;MAChCd,wBAAwB,CAAC,KAAKW,SAAN,CAAxB;IACD;EACF;;EAEDI,MAAM,GAAG;IACP,MAAM;MAACP;IAAD,IAAS,KAAKD,KAApB;;IACA,oBAA6B,KAAKD,KAAlC;IAAA,MAAM;MAACU;IAAD,CAAN;IAAA,MAAoBV,KAApB;;IACA,MAAMW,KAAK,GAAGnB,KAAK,CAACoB,QAAN,CAAeC,IAAf,CAAoBH,QAApB,CAAd;IAEA,OAAOR,IAAI,
|
|
1
|
+
{"version":3,"file":"index.js","names":["React","PropTypes","safeCancelAnimationFrame","requestId","cancelAnimationFrame","Swapper","Component","constructor","props","state","init","componentDidMount","requestAnimationFrame","requestID","setState","componentWillUnmount","undefined","render","children","child","Children","only","cloneElement","propTypes","node"],"sources":["../../../src/hoc/swapper/index.js"],"sourcesContent":["import React from 'react';\nimport PropTypes from 'prop-types';\n\nexport const safeCancelAnimationFrame = requestId => requestId && cancelAnimationFrame(requestId);\n\nclass Swapper extends React.Component {\n static propTypes = {\n children: PropTypes.node\n };\n\n constructor(props) {\n super(props);\n\n this.state = {\n init: true\n };\n }\n\n componentDidMount() {\n if (typeof requestAnimationFrame !== 'undefined') {\n this.requestID = requestAnimationFrame(() => this.setState({init: false}));\n }\n }\n\n componentWillUnmount() {\n if (this.requestID !== undefined) {\n safeCancelAnimationFrame(this.requestID);\n }\n }\n\n render() {\n const {init} = this.state;\n const {children, ...props} = this.props;\n const child = React.Children.only(children);\n\n return init ? React.cloneElement(child, props) : child;\n }\n}\n\nexport default Swapper;\n"],"mappings":";;;;AAAA,OAAOA,KAAP,MAAkB,OAAlB;AACA,OAAOC,SAAP,MAAsB,YAAtB;AAEA,OAAO,MAAMC,wBAAwB,GAAGC,SAAS,IAAIA,SAAS,IAAIC,oBAAoB,CAACD,SAAD,CAA/E;;AAEP,MAAME,OAAN,SAAsBL,KAAK,CAACM,SAA5B,CAAsC;EAKpCC,WAAW,CAACC,KAAD,EAAQ;IACjB,MAAMA,KAAN;IAEA,KAAKC,KAAL,GAAa;MACXC,IAAI,EAAE;IADK,CAAb;EAGD;;EAEDC,iBAAiB,GAAG;IAClB,IAAI,OAAOC,qBAAP,KAAiC,WAArC,EAAkD;MAChD,KAAKC,SAAL,GAAiBD,qBAAqB,CAAC,MAAM,KAAKE,QAAL,CAAc;QAACJ,IAAI,EAAE;MAAP,CAAd,CAAP,CAAtC;IACD;EACF;;EAEDK,oBAAoB,GAAG;IACrB,IAAI,KAAKF,SAAL,KAAmBG,SAAvB,EAAkC;MAChCd,wBAAwB,CAAC,KAAKW,SAAN,CAAxB;IACD;EACF;;EAEDI,MAAM,GAAG;IACP,MAAM;MAACP;IAAD,IAAS,KAAKD,KAApB;;IACA,oBAA6B,KAAKD,KAAlC;IAAA,MAAM;MAACU;IAAD,CAAN;IAAA,MAAoBV,KAApB;;IACA,MAAMW,KAAK,GAAGnB,KAAK,CAACoB,QAAN,CAAeC,IAAf,CAAoBH,QAApB,CAAd;IAEA,OAAOR,IAAI,gBAAGV,KAAK,CAACsB,YAAN,CAAmBH,KAAnB,EAA0BX,KAA1B,CAAH,GAAsCW,KAAjD;EACD;;AA/BmC;;AAAhCd,O,CACGkB,S,2CAAY;EACjBL,QAAQ,EAAEjB,SAAS,CAACuB;AADH,C;AAiCrB,eAAenB,OAAf"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"fixtures.native.d.ts","sourceRoot":"","sources":["../../../../src/hoc/touchable/test/fixtures.native.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
export default Transition;
|
|
2
|
+
declare function Transition(props: any): any;
|
|
3
|
+
declare namespace Transition {
|
|
4
|
+
namespace propTypes {
|
|
5
|
+
const name: PropTypes.Validator<string>;
|
|
6
|
+
const onAnimationEnd: PropTypes.Requireable<(...args: any[]) => any>;
|
|
7
|
+
const animated: PropTypes.Requireable<boolean>;
|
|
8
|
+
}
|
|
9
|
+
}
|
|
10
|
+
import PropTypes from "prop-types";
|
|
11
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/hoc/transition/index.js"],"names":[],"mappings":";AAKA,6CAyBC"}
|
|
@@ -24,7 +24,7 @@ const Transition = props => {
|
|
|
24
24
|
const handlerAnimationEnd = useMemo(() => () => {
|
|
25
25
|
return onAnimationEnd(name);
|
|
26
26
|
}, []);
|
|
27
|
-
return React.cloneElement(child, {
|
|
27
|
+
return /*#__PURE__*/React.cloneElement(child, {
|
|
28
28
|
className: classnames(propClassName, className),
|
|
29
29
|
onTransitionEnd: handlerAnimationEnd,
|
|
30
30
|
onAnimationEnd: handlerAnimationEnd
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","names":["React","useMemo","PropTypes","classnames","Transition","props","name","children","className","animated","onAnimationEnd","Child","child","propClassName","handlerAnimationEnd","cloneElement","onTransitionEnd","Children","map","propTypes","string","isRequired","func","bool"],"sources":["../../../src/hoc/transition/index.js"],"sourcesContent":["import React, {useMemo} from 'react';\nimport {noop} from 'lodash/fp';\nimport PropTypes from 'prop-types';\nimport classnames from 'classnames';\n\nconst Transition = props => {\n const {name, children, className, animated, onAnimationEnd = noop} = props;\n\n if (!animated) return children;\n\n const Child = ({child}) => {\n const {\n props: {className: propClassName}\n } = child;\n\n const handlerAnimationEnd = useMemo(\n () => () => {\n return onAnimationEnd(name);\n },\n []\n );\n\n return React.cloneElement(child, {\n className: classnames(propClassName, className),\n onTransitionEnd: handlerAnimationEnd,\n onAnimationEnd: handlerAnimationEnd\n });\n };\n\n return React.Children.map(children, child => <Child child={child} />);\n};\n\nTransition.propTypes = {\n name: PropTypes.string.isRequired,\n onAnimationEnd: PropTypes.func,\n animated: PropTypes.bool\n};\n\nexport default Transition;\n"],"mappings":";AAAA,OAAOA,KAAP,IAAeC,OAAf,QAA6B,OAA7B;AAEA,OAAOC,SAAP,MAAsB,YAAtB;AACA,OAAOC,UAAP,MAAuB,YAAvB;;AAEA,MAAMC,UAAU,GAAGC,KAAK,IAAI;EAC1B,MAAM;IAACC,IAAD;IAAOC,QAAP;IAAiBC,SAAjB;IAA4BC,QAA5B;IAAsCC,cAAc;EAApD,IAA+DL,KAArE;EAEA,IAAI,CAACI,QAAL,EAAe,OAAOF,QAAP;;EAEf,MAAMI,KAAK,GAAG,CAAC;IAACC;EAAD,CAAD,KAAa;IACzB,MAAM;MACJP,KAAK,EAAE;QAACG,SAAS,EAAEK;MAAZ;IADH,IAEFD,KAFJ;IAIA,MAAME,mBAAmB,GAAGb,OAAO,CACjC,MAAM,MAAM;MACV,OAAOS,cAAc,CAACJ,IAAD,CAArB;IACD,CAHgC,EAIjC,EAJiC,CAAnC;IAOA,
|
|
1
|
+
{"version":3,"file":"index.js","names":["React","useMemo","PropTypes","classnames","Transition","props","name","children","className","animated","onAnimationEnd","Child","child","propClassName","handlerAnimationEnd","cloneElement","onTransitionEnd","Children","map","propTypes","string","isRequired","func","bool"],"sources":["../../../src/hoc/transition/index.js"],"sourcesContent":["import React, {useMemo} from 'react';\nimport {noop} from 'lodash/fp';\nimport PropTypes from 'prop-types';\nimport classnames from 'classnames';\n\nconst Transition = props => {\n const {name, children, className, animated, onAnimationEnd = noop} = props;\n\n if (!animated) return children;\n\n const Child = ({child}) => {\n const {\n props: {className: propClassName}\n } = child;\n\n const handlerAnimationEnd = useMemo(\n () => () => {\n return onAnimationEnd(name);\n },\n []\n );\n\n return React.cloneElement(child, {\n className: classnames(propClassName, className),\n onTransitionEnd: handlerAnimationEnd,\n onAnimationEnd: handlerAnimationEnd\n });\n };\n\n return React.Children.map(children, child => <Child child={child} />);\n};\n\nTransition.propTypes = {\n name: PropTypes.string.isRequired,\n onAnimationEnd: PropTypes.func,\n animated: PropTypes.bool\n};\n\nexport default Transition;\n"],"mappings":";AAAA,OAAOA,KAAP,IAAeC,OAAf,QAA6B,OAA7B;AAEA,OAAOC,SAAP,MAAsB,YAAtB;AACA,OAAOC,UAAP,MAAuB,YAAvB;;AAEA,MAAMC,UAAU,GAAGC,KAAK,IAAI;EAC1B,MAAM;IAACC,IAAD;IAAOC,QAAP;IAAiBC,SAAjB;IAA4BC,QAA5B;IAAsCC,cAAc;EAApD,IAA+DL,KAArE;EAEA,IAAI,CAACI,QAAL,EAAe,OAAOF,QAAP;;EAEf,MAAMI,KAAK,GAAG,CAAC;IAACC;EAAD,CAAD,KAAa;IACzB,MAAM;MACJP,KAAK,EAAE;QAACG,SAAS,EAAEK;MAAZ;IADH,IAEFD,KAFJ;IAIA,MAAME,mBAAmB,GAAGb,OAAO,CACjC,MAAM,MAAM;MACV,OAAOS,cAAc,CAACJ,IAAD,CAArB;IACD,CAHgC,EAIjC,EAJiC,CAAnC;IAOA,oBAAON,KAAK,CAACe,YAAN,CAAmBH,KAAnB,EAA0B;MAC/BJ,SAAS,EAAEL,UAAU,CAACU,aAAD,EAAgBL,SAAhB,CADU;MAE/BQ,eAAe,EAAEF,mBAFc;MAG/BJ,cAAc,EAAEI;IAHe,CAA1B,CAAP;EAKD,CAjBD;;EAmBA,OAAOd,KAAK,CAACiB,QAAN,CAAeC,GAAf,CAAmBX,QAAnB,EAA6BK,KAAK,iBAAI,oBAAC,KAAD;IAAO,KAAK,EAAEA;EAAd,EAAtC,CAAP;AACD,CAzBD;;AA2BAR,UAAU,CAACe,SAAX,2CAAuB;EACrBb,IAAI,EAAEJ,SAAS,CAACkB,MAAV,CAAiBC,UADF;EAErBX,cAAc,EAAER,SAAS,CAACoB,IAFL;EAGrBb,QAAQ,EAAEP,SAAS,CAACqB;AAHC,CAAvB;AAMA,eAAenB,UAAf"}
|
|
@@ -8,7 +8,7 @@ const ADD_TO_MY_LIST_STATUS = {
|
|
|
8
8
|
IDLE: 'IDLE',
|
|
9
9
|
SUCCESS: 'SUCCESS'
|
|
10
10
|
};
|
|
11
|
-
const StatusContext = React.createContext(ADD_TO_MY_LIST_STATUS.IDLE);
|
|
11
|
+
const StatusContext = /*#__PURE__*/React.createContext(ADD_TO_MY_LIST_STATUS.IDLE);
|
|
12
12
|
export const AddToMyListStatusProvider = ({
|
|
13
13
|
children
|
|
14
14
|
}) => {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","names":["React","useState","useContext","useEffect","useMemo","PropTypes","classnames","NovaCompositionCoorpacademyCheck","CheckIcon","NovaCompositionNavigationMore","MoreIcon","Link","styles","ADD_TO_MY_LIST_STATUS","IDLE","SUCCESS","StatusContext","createContext","AddToMyListStatusProvider","children","status","setStatus","timeoutId","DURATION","setTimeout","clearTimeout","statusValue","AddToMyListFeedback","addToMyListText","removeFromMyListText","favorite","feedback","checkIcon","AddToMyList","style","addToMyListButton","onFavoriteClick","cb","onClick","container","cta","wrapper","shareIcon","propTypes","node","string","bool","func"],"sources":["../../../src/molecule/add-to-my-list/index.js"],"sourcesContent":["import React, {useState, useContext, useEffect, useMemo} from 'react';\nimport PropTypes from 'prop-types';\nimport classnames from 'classnames';\nimport {\n NovaCompositionCoorpacademyCheck as CheckIcon,\n NovaCompositionNavigationMore as MoreIcon\n} from '@coorpacademy/nova-icons';\nimport Link from '../../atom/link';\nimport styles from './style.css';\n\nconst ADD_TO_MY_LIST_STATUS = {\n IDLE: 'IDLE',\n SUCCESS: 'SUCCESS'\n};\n\nconst StatusContext = React.createContext(ADD_TO_MY_LIST_STATUS.IDLE);\n\nexport const AddToMyListStatusProvider = ({children}) => {\n const [status, setStatus] = useState(ADD_TO_MY_LIST_STATUS.IDLE);\n useEffect(() => {\n let timeoutId;\n const DURATION = 3000;\n if (status !== ADD_TO_MY_LIST_STATUS.IDLE) {\n timeoutId = setTimeout(() => setStatus(ADD_TO_MY_LIST_STATUS.IDLE), DURATION);\n }\n return () => clearTimeout(timeoutId);\n }, [status]);\n const statusValue = useMemo(() => [status, setStatus], [status, setStatus]);\n return <StatusContext.Provider value={statusValue}>{children}</StatusContext.Provider>;\n};\n\nexport const AddToMyListFeedback = ({addToMyListText, removeFromMyListText, favorite}) => {\n const [status] = useContext(StatusContext);\n if (status === ADD_TO_MY_LIST_STATUS.IDLE) return null;\n\n return (\n <div className={classnames(styles.feedback)} data-name={'add-to-my-list-feedback'}>\n <CheckIcon className={styles.checkIcon} width={13} height={13} />\n <p>{favorite ? addToMyListText : removeFromMyListText}</p>\n </div>\n );\n};\n\nconst AddToMyList = ({style, addToMyListButton, favorite, onFavoriteClick}) => {\n const [, setStatus] = useContext(StatusContext);\n const cb = () => setStatus(ADD_TO_MY_LIST_STATUS.SUCCESS);\n\n function onClick() {\n onFavoriteClick(cb);\n }\n\n return (\n <div className={(styles.container, style)}>\n <Link data-name={'add-to-my-list-button'} onClick={onClick} className={styles.cta}>\n <div className={styles.wrapper}>\n {favorite ? (\n <CheckIcon className={styles.shareIcon} width={15} height={15} />\n ) : (\n <MoreIcon className={styles.shareIcon} width={12} height={12} />\n )}\n <p>{addToMyListButton}</p>\n </div>\n </Link>\n </div>\n );\n};\n\nAddToMyListStatusProvider.propTypes = {\n children: PropTypes.node\n};\n\nAddToMyListFeedback.propTypes = {\n addToMyListText: PropTypes.string,\n removeFromMyListText: PropTypes.string,\n favorite: PropTypes.bool\n};\n\nAddToMyList.propTypes = {\n style: PropTypes.string,\n addToMyListButton: PropTypes.string,\n favorite: PropTypes.bool,\n onFavoriteClick: PropTypes.func\n};\n\nexport default AddToMyList;\n"],"mappings":"AAAA,OAAOA,KAAP,IAAeC,QAAf,EAAyBC,UAAzB,EAAqCC,SAArC,EAAgDC,OAAhD,QAA8D,OAA9D;AACA,OAAOC,SAAP,MAAsB,YAAtB;AACA,OAAOC,UAAP,MAAuB,YAAvB;AACA,SACEC,gCAAgC,IAAIC,SADtC,EAEEC,6BAA6B,IAAIC,QAFnC,QAGO,0BAHP;AAIA,OAAOC,IAAP,MAAiB,iBAAjB;AACA,OAAOC,MAAP,MAAmB,aAAnB;AAEA,MAAMC,qBAAqB,GAAG;EAC5BC,IAAI,EAAE,MADsB;EAE5BC,OAAO,EAAE;AAFmB,CAA9B;AAKA,MAAMC,aAAa,
|
|
1
|
+
{"version":3,"file":"index.js","names":["React","useState","useContext","useEffect","useMemo","PropTypes","classnames","NovaCompositionCoorpacademyCheck","CheckIcon","NovaCompositionNavigationMore","MoreIcon","Link","styles","ADD_TO_MY_LIST_STATUS","IDLE","SUCCESS","StatusContext","createContext","AddToMyListStatusProvider","children","status","setStatus","timeoutId","DURATION","setTimeout","clearTimeout","statusValue","AddToMyListFeedback","addToMyListText","removeFromMyListText","favorite","feedback","checkIcon","AddToMyList","style","addToMyListButton","onFavoriteClick","cb","onClick","container","cta","wrapper","shareIcon","propTypes","node","string","bool","func"],"sources":["../../../src/molecule/add-to-my-list/index.js"],"sourcesContent":["import React, {useState, useContext, useEffect, useMemo} from 'react';\nimport PropTypes from 'prop-types';\nimport classnames from 'classnames';\nimport {\n NovaCompositionCoorpacademyCheck as CheckIcon,\n NovaCompositionNavigationMore as MoreIcon\n} from '@coorpacademy/nova-icons';\nimport Link from '../../atom/link';\nimport styles from './style.css';\n\nconst ADD_TO_MY_LIST_STATUS = {\n IDLE: 'IDLE',\n SUCCESS: 'SUCCESS'\n};\n\nconst StatusContext = React.createContext(ADD_TO_MY_LIST_STATUS.IDLE);\n\nexport const AddToMyListStatusProvider = ({children}) => {\n const [status, setStatus] = useState(ADD_TO_MY_LIST_STATUS.IDLE);\n useEffect(() => {\n let timeoutId;\n const DURATION = 3000;\n if (status !== ADD_TO_MY_LIST_STATUS.IDLE) {\n timeoutId = setTimeout(() => setStatus(ADD_TO_MY_LIST_STATUS.IDLE), DURATION);\n }\n return () => clearTimeout(timeoutId);\n }, [status]);\n const statusValue = useMemo(() => [status, setStatus], [status, setStatus]);\n return <StatusContext.Provider value={statusValue}>{children}</StatusContext.Provider>;\n};\n\nexport const AddToMyListFeedback = ({addToMyListText, removeFromMyListText, favorite}) => {\n const [status] = useContext(StatusContext);\n if (status === ADD_TO_MY_LIST_STATUS.IDLE) return null;\n\n return (\n <div className={classnames(styles.feedback)} data-name={'add-to-my-list-feedback'}>\n <CheckIcon className={styles.checkIcon} width={13} height={13} />\n <p>{favorite ? addToMyListText : removeFromMyListText}</p>\n </div>\n );\n};\n\nconst AddToMyList = ({style, addToMyListButton, favorite, onFavoriteClick}) => {\n const [, setStatus] = useContext(StatusContext);\n const cb = () => setStatus(ADD_TO_MY_LIST_STATUS.SUCCESS);\n\n function onClick() {\n onFavoriteClick(cb);\n }\n\n return (\n <div className={(styles.container, style)}>\n <Link data-name={'add-to-my-list-button'} onClick={onClick} className={styles.cta}>\n <div className={styles.wrapper}>\n {favorite ? (\n <CheckIcon className={styles.shareIcon} width={15} height={15} />\n ) : (\n <MoreIcon className={styles.shareIcon} width={12} height={12} />\n )}\n <p>{addToMyListButton}</p>\n </div>\n </Link>\n </div>\n );\n};\n\nAddToMyListStatusProvider.propTypes = {\n children: PropTypes.node\n};\n\nAddToMyListFeedback.propTypes = {\n addToMyListText: PropTypes.string,\n removeFromMyListText: PropTypes.string,\n favorite: PropTypes.bool\n};\n\nAddToMyList.propTypes = {\n style: PropTypes.string,\n addToMyListButton: PropTypes.string,\n favorite: PropTypes.bool,\n onFavoriteClick: PropTypes.func\n};\n\nexport default AddToMyList;\n"],"mappings":"AAAA,OAAOA,KAAP,IAAeC,QAAf,EAAyBC,UAAzB,EAAqCC,SAArC,EAAgDC,OAAhD,QAA8D,OAA9D;AACA,OAAOC,SAAP,MAAsB,YAAtB;AACA,OAAOC,UAAP,MAAuB,YAAvB;AACA,SACEC,gCAAgC,IAAIC,SADtC,EAEEC,6BAA6B,IAAIC,QAFnC,QAGO,0BAHP;AAIA,OAAOC,IAAP,MAAiB,iBAAjB;AACA,OAAOC,MAAP,MAAmB,aAAnB;AAEA,MAAMC,qBAAqB,GAAG;EAC5BC,IAAI,EAAE,MADsB;EAE5BC,OAAO,EAAE;AAFmB,CAA9B;AAKA,MAAMC,aAAa,gBAAGhB,KAAK,CAACiB,aAAN,CAAoBJ,qBAAqB,CAACC,IAA1C,CAAtB;AAEA,OAAO,MAAMI,yBAAyB,GAAG,CAAC;EAACC;AAAD,CAAD,KAAgB;EACvD,MAAM,CAACC,MAAD,EAASC,SAAT,IAAsBpB,QAAQ,CAACY,qBAAqB,CAACC,IAAvB,CAApC;EACAX,SAAS,CAAC,MAAM;IACd,IAAImB,SAAJ;IACA,MAAMC,QAAQ,GAAG,IAAjB;;IACA,IAAIH,MAAM,KAAKP,qBAAqB,CAACC,IAArC,EAA2C;MACzCQ,SAAS,GAAGE,UAAU,CAAC,MAAMH,SAAS,CAACR,qBAAqB,CAACC,IAAvB,CAAhB,EAA8CS,QAA9C,CAAtB;IACD;;IACD,OAAO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,OAAnD;IAA4D,SAAS,EAAE1B,MAAM,CAAC4B;EAA9E,gBACE;IAAK,SAAS,EAAE5B,MAAM,CAAC6B;EAAvB,GACGX,QAAQ,gBACP,oBAAC,SAAD;IAAW,SAAS,EAAElB,MAAM,CAAC8B,SAA7B;IAAwC,KAAK,EAAE,EAA/C;IAAmD,MAAM,EAAE;EAA3D,EADO,gBAGP,oBAAC,QAAD;IAAU,SAAS,EAAE9B,MAAM,CAAC8B,SAA5B;IAAuC,KAAK,EAAE,EAA9C;IAAkD,MAAM,EAAE;EAA1D,EAJJ,eAME,+BAAIP,iBAAJ,CANF,CADF,CADF,CADF;AAcD,CAtBD;;AAwBAjB,yBAAyB,CAACyB,SAA1B,2CAAsC;EACpCxB,QAAQ,EAAEd,SAAS,CAACuC;AADgB,CAAtC;AAIAjB,mBAAmB,CAACgB,SAApB,2CAAgC;EAC9Bf,eAAe,EAAEvB,SAAS,CAACwC,MADG;EAE9BhB,oBAAoB,EAAExB,SAAS,CAACwC,MAFF;EAG9Bf,QAAQ,EAAEzB,SAAS,CAACyC;AAHU,CAAhC;AAMAb,WAAW,CAACU,SAAZ,2CAAwB;EACtBT,KAAK,EAAE7B,SAAS,CAACwC,MADK;EAEtBV,iBAAiB,EAAE9B,SAAS,CAACwC,MAFP;EAGtBf,QAAQ,EAAEzB,SAAS,CAACyC,IAHE;EAItBV,eAAe,EAAE/B,SAAS,CAAC0C;AAJL,CAAxB;AAOA,eAAed,WAAf"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/molecule/answer/index.js"],"names":[],"mappings":";AAuEA,iDASC"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
import {
|
|
3
|
-
declare const Answer: (props:
|
|
2
|
+
import { AnswerProps } from './prop-types';
|
|
3
|
+
declare const Answer: (props: AnswerProps) => JSX.Element;
|
|
4
4
|
export default Answer;
|
|
5
5
|
//# sourceMappingURL=index.native.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.native.d.ts","sourceRoot":"","sources":["../../../src/molecule/answer/index.native.tsx"],"names":[],"mappings":";AAGA,OAAO,EAAC,
|
|
1
|
+
{"version":3,"file":"index.native.d.ts","sourceRoot":"","sources":["../../../src/molecule/answer/index.native.tsx"],"names":[],"mappings":";AAGA,OAAO,EAAC,WAAW,EAAC,MAAM,cAAc,CAAC;AAuCzC,QAAA,MAAM,MAAM,UAAW,WAAW,gBA8BjC,CAAC;AAEF,eAAe,MAAM,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.native.js","names":["React","Switch","convertType","modelType","convertToChoices","answers","map","answer","index","_id","label","title","value","onPress","onClick","onChange","selected","media","image","type","src","url","undefined","name","items","options","text","Answer","props","model","template","onSliderChange","minLabel","maxLabel","switchProps","onInputValueChange","choices","min","Number","parseInt","split","max","unit"],"sources":["../../../src/molecule/answer/index.native.tsx"],"sourcesContent":["import React from 'react';\nimport {Choice, QuestionType} from '../questions/types';\nimport Switch, {Props as SwitchProps} from '../questions/mobile/switch/index.native';\nimport {
|
|
1
|
+
{"version":3,"file":"index.native.js","names":["React","Switch","convertType","modelType","convertToChoices","answers","map","answer","index","_id","label","title","value","onPress","onClick","onChange","selected","media","image","type","src","url","undefined","name","items","options","text","Answer","props","model","template","onSliderChange","minLabel","maxLabel","switchProps","onInputValueChange","choices","min","Number","parseInt","split","max","unit"],"sources":["../../../src/molecule/answer/index.native.tsx"],"sourcesContent":["import React from 'react';\nimport {Choice, QuestionType} from '../questions/types';\nimport Switch, {Props as SwitchProps} from '../questions/mobile/switch/index.native';\nimport {AnswerProps} from './prop-types';\n\nconst convertType = (modelType: AnswerProps['model']['type']): QuestionType => {\n switch (modelType) {\n case 'freeText':\n return 'basic';\n case 'dropDown':\n return 'template';\n default:\n return modelType;\n }\n};\n\nconst convertToChoices = (answers: AnswerProps['model']['answers'] = []): Choice[] =>\n answers.map((answer, index) => ({\n _id: `${index}`,\n label: answer.title,\n value: answer.title,\n onPress: answer.onClick || answer.onChange,\n selected: answer.selected,\n media: answer.image\n ? {\n type: 'img',\n src: [{url: answer.image}]\n }\n : undefined,\n // ---- custom properties for template choice\n type: answer.type,\n name: answer.name,\n items:\n answer.options &&\n answer.options.map(({name, selected, value}) => ({\n text: name,\n selected,\n value,\n _id: name\n }))\n }));\n\nconst Answer = (props: AnswerProps) => {\n const {\n model: {answers, onChange, template, type, onSliderChange, minLabel, maxLabel, title}\n } = props;\n\n const switchProps: SwitchProps = {\n type: convertType(type)\n };\n\n if (type === 'freeText') {\n switchProps.onInputValueChange = onChange;\n }\n\n if (type === 'qcm' || type === 'qcmDrag' || type === 'qcmGraphic' || type === 'template') {\n switchProps.choices = convertToChoices(answers);\n }\n\n if (type === 'template') {\n switchProps.template = template;\n }\n\n if (type === 'slider') {\n switchProps.onSliderChange = onSliderChange;\n switchProps.min = minLabel ? Number.parseInt(minLabel.split(' ')[0]) : 0;\n switchProps.max = maxLabel ? Number.parseInt(maxLabel.split(' ')[0]) : 1;\n switchProps.value = title ? Number.parseInt(title.split(' ')[0]) : 0;\n switchProps.unit = minLabel ? minLabel.split(' ')[1] : '';\n }\n\n return <Switch {...switchProps} />;\n};\n\nexport default Answer;\n"],"mappings":"AAAA,OAAOA,KAAP,MAAkB,OAAlB;AAEA,OAAOC,MAAP,MAA2C,yCAA3C;;AAGA,MAAMC,WAAW,GAAIC,SAAD,IAA2D;EAC7E,QAAQA,SAAR;IACE,KAAK,UAAL;MACE,OAAO,OAAP;;IACF,KAAK,UAAL;MACE,OAAO,UAAP;;IACF;MACE,OAAOA,SAAP;EANJ;AAQD,CATD;;AAWA,MAAMC,gBAAgB,GAAG,CAACC,OAAwC,GAAG,EAA5C,KACvBA,OAAO,CAACC,GAAR,CAAY,CAACC,MAAD,EAASC,KAAT,MAAoB;EAC9BC,GAAG,EAAG,GAAED,KAAM,EADgB;EAE9BE,KAAK,E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Z,GAAsBhC,gBAAgB,CAACC,OAAD,CAAtC;EACD;;EAED,IAAIc,IAAI,KAAK,UAAb,EAAyB;IACvBe,WAAW,CAACJ,QAAZ,GAAuBA,QAAvB;EACD;;EAED,IAAIX,IAAI,KAAK,QAAb,EAAuB;IACrBe,WAAW,CAACH,cAAZ,GAA6BA,cAA7B;IACAG,WAAW,CAACG,GAAZ,GAAkBL,QAAQ,GAAGM,MAAM,CAACC,QAAP,CAAgBP,QAAQ,CAACQ,KAAT,CAAe,GAAf,EAAoB,CAApB,CAAhB,CAAH,GAA6C,CAAvE;IACAN,WAAW,CAACO,GAAZ,GAAkBR,QAAQ,GAAGK,MAAM,CAACC,QAAP,CAAgBN,QAAQ,CAACO,KAAT,CAAe,GAAf,EAAoB,CAApB,CAAhB,CAAH,GAA6C,CAAvE;IACAN,WAAW,CAACtB,KAAZ,GAAoBD,KAAK,GAAG2B,MAAM,CAACC,QAAP,CAAgB5B,KAAK,CAAC6B,KAAN,CAAY,GAAZ,EAAiB,CAAjB,CAAhB,CAAH,GAA0C,CAAnE;IACAN,WAAW,CAACQ,IAAZ,GAAmBV,QAAQ,GAAGA,QAAQ,CAACQ,KAAT,CAAe,GAAf,EAAoB,CAApB,CAAH,GAA4B,EAAvD;EACD;;EAED,oBAAO,oBAAC,MAAD,EAAYN,WAAZ,CAAP;AACD,CA9BD;;AAgCA,eAAeP,MAAf"}
|
|
@@ -3,7 +3,7 @@ export declare const TYPE_IMAGE = "img";
|
|
|
3
3
|
export declare const TYPE_VIDEO = "video";
|
|
4
4
|
export declare const TYPE_AUDIO = "audio";
|
|
5
5
|
export declare const MediaViewPropTypes: {
|
|
6
|
-
media: PropTypes.Requireable<PropTypes.InferProps<{
|
|
6
|
+
media: PropTypes.Requireable<NonNullable<PropTypes.InferProps<{
|
|
7
7
|
type: PropTypes.Validator<string>;
|
|
8
8
|
id: PropTypes.Requireable<string>;
|
|
9
9
|
width: PropTypes.Requireable<string>;
|
|
@@ -43,10 +43,10 @@ export declare const MediaViewPropTypes: {
|
|
|
43
43
|
}> | PropTypes.InferProps<{
|
|
44
44
|
type: PropTypes.Validator<string>;
|
|
45
45
|
mediaUrl: PropTypes.Validator<string>;
|
|
46
|
-
}>>;
|
|
46
|
+
}> | null | undefined>>;
|
|
47
47
|
};
|
|
48
48
|
declare const propTypes: {
|
|
49
|
-
model: PropTypes.Validator<PropTypes.InferProps<{
|
|
49
|
+
model: PropTypes.Validator<NonNullable<PropTypes.InferProps<{
|
|
50
50
|
type: PropTypes.Validator<string>;
|
|
51
51
|
answer: PropTypes.Requireable<(PropTypes.InferProps<{
|
|
52
52
|
title: PropTypes.Validator<string>;
|
|
@@ -64,9 +64,9 @@ declare const propTypes: {
|
|
|
64
64
|
type: PropTypes.Requireable<string>;
|
|
65
65
|
name: PropTypes.Requireable<string>;
|
|
66
66
|
}> | null | undefined)[]>;
|
|
67
|
-
}
|
|
67
|
+
}>>>;
|
|
68
68
|
help: PropTypes.Requireable<string>;
|
|
69
|
-
media: PropTypes.Requireable<PropTypes.InferProps<{
|
|
69
|
+
media: PropTypes.Requireable<NonNullable<PropTypes.InferProps<{
|
|
70
70
|
type: PropTypes.Validator<string>;
|
|
71
71
|
id: PropTypes.Requireable<string>;
|
|
72
72
|
width: PropTypes.Requireable<string>;
|
|
@@ -106,7 +106,7 @@ declare const propTypes: {
|
|
|
106
106
|
}> | PropTypes.InferProps<{
|
|
107
107
|
type: PropTypes.Validator<string>;
|
|
108
108
|
mediaUrl: PropTypes.Validator<string>;
|
|
109
|
-
}>>;
|
|
109
|
+
}> | null | undefined>>;
|
|
110
110
|
};
|
|
111
111
|
declare type SelectOptions = {
|
|
112
112
|
name: string;
|
|
@@ -114,7 +114,7 @@ declare type SelectOptions = {
|
|
|
114
114
|
validOption: boolean;
|
|
115
115
|
value: string;
|
|
116
116
|
};
|
|
117
|
-
declare type Answer = {
|
|
117
|
+
export declare type Answer = {
|
|
118
118
|
title?: string;
|
|
119
119
|
'aria-label'?: string;
|
|
120
120
|
onClick?: () => void;
|
|
@@ -122,10 +122,10 @@ declare type Answer = {
|
|
|
122
122
|
selected?: boolean;
|
|
123
123
|
image?: string;
|
|
124
124
|
options?: SelectOptions[];
|
|
125
|
-
type
|
|
125
|
+
type?: 'text' | 'select';
|
|
126
126
|
name?: string;
|
|
127
127
|
};
|
|
128
|
-
export declare type
|
|
128
|
+
export declare type AnswerProps = {
|
|
129
129
|
model: {
|
|
130
130
|
type: 'qcmDrag' | 'qcm' | 'qcmGraphic' | 'freeText' | 'dropDown' | 'slider' | 'template';
|
|
131
131
|
answers?: Answer[];
|
|
@@ -137,7 +137,24 @@ export declare type Props = {
|
|
|
137
137
|
title?: string;
|
|
138
138
|
};
|
|
139
139
|
help: string;
|
|
140
|
-
media
|
|
140
|
+
media?: {
|
|
141
|
+
type: 'img' | 'audio' | 'video';
|
|
142
|
+
url?: string;
|
|
143
|
+
mediaUrl?: string;
|
|
144
|
+
mimeType?: string;
|
|
145
|
+
poster?: string;
|
|
146
|
+
videoId?: string;
|
|
147
|
+
_id?: string;
|
|
148
|
+
description?: string;
|
|
149
|
+
subtitles?: string[];
|
|
150
|
+
posters?: string[];
|
|
151
|
+
src?: string[];
|
|
152
|
+
onClick?: () => void;
|
|
153
|
+
onPlay?: () => void;
|
|
154
|
+
onPause?: () => void;
|
|
155
|
+
onResume?: () => void;
|
|
156
|
+
onEnded?: () => void;
|
|
157
|
+
};
|
|
141
158
|
};
|
|
142
159
|
export default propTypes;
|
|
143
160
|
//# sourceMappingURL=prop-types.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"prop-types.d.ts","sourceRoot":"","sources":["../../../src/molecule/answer/prop-types.ts"],"names":[],"mappings":"AAAA,OAAO,SAAS,MAAM,YAAY,CAAC;AAGnC,eAAO,MAAM,UAAU,QAAQ,CAAC;AAChC,eAAO,MAAM,UAAU,UAAU,CAAC;AAClC,eAAO,MAAM,UAAU,UAAU,CAAC;AAmBlC,eAAO,MAAM,kBAAkB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AAC,EAAE,MAAM,IAAI,CAAC;QACtB,OAAO,CAAC,EAAE,MAAM,IAAI,CAAC;KACtB,CAAC;CACH,CAAC;AAEF,eAAe,SAAS,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"prop-types.js","names":["PropTypes","VideoPlayerPropTypes","TYPE_IMAGE","TYPE_VIDEO","TYPE_AUDIO","isType","name","oneOf","videoPropType","shape","type","isRequired","imgPropType","url","string","audioPropType","mediaUrl","MediaViewPropTypes","media","oneOfType","SelectOptionsPropTypes","selected","bool","validOption","value","AnswerPropTypes","title","onClick","func","onChange","image","options","arrayOf","propTypes","model","answer","help"],"sources":["../../../src/molecule/answer/prop-types.ts"],"sourcesContent":["import PropTypes from 'prop-types';\nimport VideoPlayerPropTypes from '../video-player/prop-types';\n\nexport const TYPE_IMAGE = 'img';\nexport const TYPE_VIDEO = 'video';\nexport const TYPE_AUDIO = 'audio';\n\nconst isType = (name: string) => PropTypes.oneOf([name]);\n\nconst videoPropType = PropTypes.shape({\n ...VideoPlayerPropTypes,\n type: isType(TYPE_VIDEO).isRequired\n});\n\nconst imgPropType = PropTypes.shape({\n type: isType(TYPE_IMAGE).isRequired,\n url: PropTypes.string.isRequired\n});\n\nconst audioPropType = PropTypes.shape({\n type: isType(TYPE_AUDIO).isRequired,\n mediaUrl: PropTypes.string.isRequired\n});\n\nexport const MediaViewPropTypes = {\n media: PropTypes.oneOfType([videoPropType, imgPropType, audioPropType])\n};\n\nconst SelectOptionsPropTypes = PropTypes.shape({\n name: PropTypes.string,\n selected: PropTypes.bool,\n validOption: PropTypes.bool,\n value: PropTypes.string\n});\n\nconst AnswerPropTypes = PropTypes.shape({\n title: PropTypes.string.isRequired,\n 'aria-label': PropTypes.string,\n onClick: PropTypes.func,\n onChange: PropTypes.func,\n selected: PropTypes.bool,\n image: PropTypes.string,\n options: PropTypes.arrayOf(SelectOptionsPropTypes),\n type: PropTypes.oneOf(['text', 'select']),\n name: PropTypes.string\n});\n\nconst propTypes = {\n model: PropTypes.shape({\n type: PropTypes.oneOf([\n 'qcmDrag',\n 'qcm',\n 'qcmGraphic',\n 'freeText',\n 'dropDown',\n 'slider',\n 'template'\n ]).isRequired,\n answer: PropTypes.arrayOf(AnswerPropTypes)\n }).isRequired,\n help: PropTypes.string,\n media: MediaViewPropTypes.media\n};\n\ntype SelectOptions = {\n name: string;\n selected: boolean;\n validOption: boolean;\n value: string;\n};\n\
|
|
1
|
+
{"version":3,"file":"prop-types.js","names":["PropTypes","VideoPlayerPropTypes","TYPE_IMAGE","TYPE_VIDEO","TYPE_AUDIO","isType","name","oneOf","videoPropType","shape","type","isRequired","imgPropType","url","string","audioPropType","mediaUrl","MediaViewPropTypes","media","oneOfType","SelectOptionsPropTypes","selected","bool","validOption","value","AnswerPropTypes","title","onClick","func","onChange","image","options","arrayOf","propTypes","model","answer","help"],"sources":["../../../src/molecule/answer/prop-types.ts"],"sourcesContent":["import PropTypes from 'prop-types';\nimport VideoPlayerPropTypes from '../video-player/prop-types';\n\nexport const TYPE_IMAGE = 'img';\nexport const TYPE_VIDEO = 'video';\nexport const TYPE_AUDIO = 'audio';\n\nconst isType = (name: string) => PropTypes.oneOf([name]);\n\nconst videoPropType = PropTypes.shape({\n ...VideoPlayerPropTypes,\n type: isType(TYPE_VIDEO).isRequired\n});\n\nconst imgPropType = PropTypes.shape({\n type: isType(TYPE_IMAGE).isRequired,\n url: PropTypes.string.isRequired\n});\n\nconst audioPropType = PropTypes.shape({\n type: isType(TYPE_AUDIO).isRequired,\n mediaUrl: PropTypes.string.isRequired\n});\n\nexport const MediaViewPropTypes = {\n media: PropTypes.oneOfType([videoPropType, imgPropType, audioPropType])\n};\n\nconst SelectOptionsPropTypes = PropTypes.shape({\n name: PropTypes.string,\n selected: PropTypes.bool,\n validOption: PropTypes.bool,\n value: PropTypes.string\n});\n\nconst AnswerPropTypes = PropTypes.shape({\n title: PropTypes.string.isRequired,\n 'aria-label': PropTypes.string,\n onClick: PropTypes.func,\n onChange: PropTypes.func,\n selected: PropTypes.bool,\n image: PropTypes.string,\n options: PropTypes.arrayOf(SelectOptionsPropTypes),\n type: PropTypes.oneOf(['text', 'select']),\n name: PropTypes.string\n});\n\nconst propTypes = {\n model: PropTypes.shape({\n type: PropTypes.oneOf([\n 'qcmDrag',\n 'qcm',\n 'qcmGraphic',\n 'freeText',\n 'dropDown',\n 'slider',\n 'template'\n ]).isRequired,\n answer: PropTypes.arrayOf(AnswerPropTypes)\n }).isRequired,\n help: PropTypes.string,\n media: MediaViewPropTypes.media\n};\n\ntype SelectOptions = {\n name: string;\n selected: boolean;\n validOption: boolean;\n value: string;\n};\n\nexport type Answer = {\n title?: string;\n 'aria-label'?: string;\n onClick?: () => void;\n onChange?: (value: string) => void;\n selected?: boolean;\n image?: string;\n options?: SelectOptions[];\n type?: 'text' | 'select';\n name?: string;\n};\n\nexport type AnswerProps = {\n model: {\n type: 'qcmDrag' | 'qcm' | 'qcmGraphic' | 'freeText' | 'dropDown' | 'slider' | 'template';\n answers?: Answer[];\n template?: string;\n onChange?: (value: string | number) => void;\n onSliderChange?: (value: number) => void;\n minLabel?: string;\n maxLabel?: string;\n title?: string;\n };\n help: string;\n media?: {\n type: 'img' | 'audio' | 'video';\n url?: string;\n mediaUrl?: string;\n mimeType?: string;\n poster?: string;\n videoId?: string;\n _id?: string;\n description?: string;\n subtitles?: string[];\n posters?: string[];\n src?: string[];\n onClick?: () => void;\n onPlay?: () => void;\n onPause?: () => void;\n onResume?: () => void;\n onEnded?: () => void;\n };\n};\n\nexport default propTypes;\n"],"mappings":";;AAAA,OAAOA,SAAP,MAAsB,YAAtB;AACA,OAAOC,oBAAP,MAAiC,4BAAjC;AAEA,OAAO,MAAMC,UAAU,GAAG,KAAnB;AACP,OAAO,MAAMC,UAAU,GAAG,OAAnB;AACP,OAAO,MAAMC,UAAU,GAAG,OAAnB;;AAEP,MAAMC,MAAM,GAAIC,IAAD,IAAkBN,SAAS,CAACO,KAAV,CAAgB,CAACD,IAAD,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OAAV,CAAkBZ,sBAAlB,CAP6B;EAQtCV,IAAI,EAAEV,SAAS,CAACO,KAAV,CAAgB,CAAC,MAAD,EAAS,QAAT,CAAhB,CARgC;EAStCD,IAAI,EAAEN,SAAS,CAACc;AATsB,CAAhB,CAAxB;AAYA,MAAMmB,SAAS,GAAG;EAChBC,KAAK,EAAElC,SAAS,CAACS,KAAV,CAAgB;IACrBC,IAAI,EAAEV,SAAS,CAACO,KAAV,CAAgB,CACpB,SADoB,EAEpB,KAFoB,EAGpB,YAHoB,EAIpB,UAJoB,EAKpB,UALoB,EAMpB,QANoB,EAOpB,UAPoB,CAAhB,EAQHI,UATkB;IAUrBwB,MAAM,EAAEnC,SAAS,CAACgC,OAAV,CAAkBP,eAAlB;EAVa,CAAhB,EAWJd,UAZa;EAahByB,IAAI,EAAEpC,SAAS,CAACc,MAbA;EAchBI,KAAK,EAAED,kBAAkB,CAACC;AAdV,CAAlB;AAoEA,eAAee,SAAf"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"audio.d.ts","sourceRoot":"","sources":["../../../../../src/molecule/answer/test/fixtures/audio.ts"],"names":[],"mappings":"AACA,OAAO,EAAC,WAAW,EAAC,MAAM,kBAAkB,CAAC;AAE7C,aAAK,OAAO,GAAG;IACb,KAAK,EAAE,WAAW,CAAC;CACpB,CAAC;AAEF,QAAA,MAAM,OAAO,EAAE,OAad,CAAC;AAEF,eAAe,OAAO,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"default.d.ts","sourceRoot":"","sources":["../../../../../src/molecule/answer/test/fixtures/default.ts"],"names":[],"mappings":"AACA,OAAO,EAAC,WAAW,EAAC,MAAM,kBAAkB,CAAC;AAE7C,aAAK,OAAO,GAAG;IACb,KAAK,EAAE,WAAW,CAAC;CACpB,CAAC;AAEF,QAAA,MAAM,OAAO,EAAE,OAYd,CAAC;AAEF,eAAe,OAAO,CAAC"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { TemplateContextValues } from '../../../../template/app-review/template-context';
|
|
2
|
-
import {
|
|
2
|
+
import { AnswerProps } from '../../prop-types';
|
|
3
3
|
declare type Fixture = {
|
|
4
|
-
props:
|
|
4
|
+
props: AnswerProps;
|
|
5
5
|
mobileContext?: TemplateContextValues;
|
|
6
6
|
};
|
|
7
7
|
declare const fixture: Fixture;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"drop-down.d.ts","sourceRoot":"","sources":["../../../../../src/molecule/answer/test/fixtures/drop-down.ts"],"names":[],"mappings":"AACA,OAAO,EAAC,qBAAqB,EAAC,MAAM,kDAAkD,CAAC;AAGvF,OAAO,EAAC,
|
|
1
|
+
{"version":3,"file":"drop-down.d.ts","sourceRoot":"","sources":["../../../../../src/molecule/answer/test/fixtures/drop-down.ts"],"names":[],"mappings":"AACA,OAAO,EAAC,qBAAqB,EAAC,MAAM,kDAAkD,CAAC;AAGvF,OAAO,EAAC,WAAW,EAAC,MAAM,kBAAkB,CAAC;AAI7C,aAAK,OAAO,GAAG;IACb,KAAK,EAAE,WAAW,CAAC;IACnB,aAAa,CAAC,EAAE,qBAAqB,CAAC;CACvC,CAAC;AAEF,QAAA,MAAM,OAAO,EAAE,OAoBd,CAAC;AAEF,eAAe,OAAO,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"qcm-arabic.d.ts","sourceRoot":"","sources":["../../../../../src/molecule/answer/test/fixtures/qcm-arabic.ts"],"names":[],"mappings":"AACA,OAAO,EAAC,WAAW,EAAC,MAAM,kBAAkB,CAAC;AAE7C,aAAK,OAAO,GAAG;IACb,KAAK,EAAE,WAAW,CAAC;CACpB,CAAC;AAIF,QAAA,MAAM,OAAO,EAAE,OAYd,CAAC;AAEF,eAAe,OAAO,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"qcm-drag.d.ts","sourceRoot":"","sources":["../../../../../src/molecule/answer/test/fixtures/qcm-drag.ts"],"names":[],"mappings":"AACA,OAAO,EAAC,WAAW,EAAC,MAAM,kBAAkB,CAAC;AAI7C,aAAK,OAAO,GAAG;IACb,KAAK,EAAE,WAAW,CAAC;CACpB,CAAC;AAEF,QAAA,MAAM,OAAO,EAAE,OAQd,CAAC;AAEF,eAAe,OAAO,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"qcm-graphic.d.ts","sourceRoot":"","sources":["../../../../../src/molecule/answer/test/fixtures/qcm-graphic.ts"],"names":[],"mappings":"AACA,OAAO,EAAC,WAAW,EAAC,MAAM,kBAAkB,CAAC;AAE7C,aAAK,OAAO,GAAG;IACb,KAAK,EAAE,WAAW,CAAC;CACpB,CAAC;AAIF,QAAA,MAAM,OAAO,EAAE,OAQd,CAAC;AAEF,eAAe,OAAO,CAAC"}
|