@coorpacademy/components 10.30.10-alpha.7 → 10.30.11-alpha.1
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/picture/index.d.ts +1 -0
- package/es/atom/picture/index.js +5 -4
- package/es/atom/picture/index.js.map +1 -1
- package/es/behaviours/use-translate-vertically.native.d.ts +16 -0
- package/es/behaviours/use-translate-vertically.native.d.ts.map +1 -0
- package/es/behaviours/use-translate-vertically.native.js +44 -0
- package/es/behaviours/use-translate-vertically.native.js.map +1 -0
- package/es/behaviours/use-update-opacity.native.d.ts +14 -0
- package/es/behaviours/use-update-opacity.native.d.ts.map +1 -0
- package/es/behaviours/use-update-opacity.native.js +55 -0
- package/es/behaviours/use-update-opacity.native.js.map +1 -0
- package/es/molecule/card-congrats/index.native.js +2 -2
- package/es/molecule/card-congrats/index.native.js.map +1 -1
- package/es/molecule/card-congrats/types.d.ts +1 -1
- package/es/molecule/card-congrats/types.d.ts.map +1 -1
- package/es/molecule/card-congrats/types.js.map +1 -1
- package/es/molecule/review-correction-popin/index.native.d.ts.map +1 -1
- package/es/molecule/review-correction-popin/index.native.js +12 -25
- package/es/molecule/review-correction-popin/index.native.js.map +1 -1
- package/es/organism/get-the-app/index.d.ts.map +1 -1
- package/es/organism/get-the-app/index.js +15 -2
- package/es/organism/get-the-app/index.js.map +1 -1
- package/es/organism/mooc-footer/index.d.ts.map +1 -1
- package/es/organism/mooc-footer/index.js +3 -2
- package/es/organism/mooc-footer/index.js.map +1 -1
- package/es/organism/mooc-header/index.d.ts.map +1 -1
- package/es/organism/mooc-header/index.js +0 -2
- package/es/organism/mooc-header/index.js.map +1 -1
- package/es/organism/review-congrats/index.native.d.ts.map +1 -1
- package/es/organism/review-congrats/index.native.js +91 -15
- package/es/organism/review-congrats/index.native.js.map +1 -1
- package/es/organism/review-slide/index.native.d.ts.map +1 -1
- package/es/organism/review-slide/index.native.js +10 -22
- package/es/organism/review-slide/index.native.js.map +1 -1
- package/es/organism/review-stacked-slides/index.native.d.ts.map +1 -1
- package/es/organism/review-stacked-slides/index.native.js +17 -4
- package/es/organism/review-stacked-slides/index.native.js.map +1 -1
- package/lib/atom/picture/index.d.ts +1 -0
- package/lib/atom/picture/index.js +5 -4
- package/lib/atom/picture/index.js.map +1 -1
- package/lib/behaviours/use-translate-vertically.native.d.ts +16 -0
- package/lib/behaviours/use-translate-vertically.native.d.ts.map +1 -0
- package/lib/behaviours/use-translate-vertically.native.js +51 -0
- package/lib/behaviours/use-translate-vertically.native.js.map +1 -0
- package/lib/behaviours/use-update-opacity.native.d.ts +14 -0
- package/lib/behaviours/use-update-opacity.native.d.ts.map +1 -0
- package/lib/behaviours/use-update-opacity.native.js +62 -0
- package/lib/behaviours/use-update-opacity.native.js.map +1 -0
- package/lib/molecule/card-congrats/index.native.js +2 -2
- package/lib/molecule/card-congrats/index.native.js.map +1 -1
- package/lib/molecule/card-congrats/types.d.ts +1 -1
- package/lib/molecule/card-congrats/types.d.ts.map +1 -1
- package/lib/molecule/card-congrats/types.js.map +1 -1
- package/lib/molecule/review-correction-popin/index.native.d.ts.map +1 -1
- package/lib/molecule/review-correction-popin/index.native.js +12 -24
- package/lib/molecule/review-correction-popin/index.native.js.map +1 -1
- package/lib/organism/get-the-app/index.d.ts.map +1 -1
- package/lib/organism/get-the-app/index.js +16 -2
- package/lib/organism/get-the-app/index.js.map +1 -1
- package/lib/organism/mooc-footer/index.d.ts.map +1 -1
- package/lib/organism/mooc-footer/index.js +4 -2
- package/lib/organism/mooc-footer/index.js.map +1 -1
- package/lib/organism/mooc-header/index.d.ts.map +1 -1
- package/lib/organism/mooc-header/index.js +0 -2
- package/lib/organism/mooc-header/index.js.map +1 -1
- package/lib/organism/review-congrats/index.native.d.ts.map +1 -1
- package/lib/organism/review-congrats/index.native.js +91 -13
- package/lib/organism/review-congrats/index.native.js.map +1 -1
- package/lib/organism/review-slide/index.native.d.ts.map +1 -1
- package/lib/organism/review-slide/index.native.js +10 -21
- package/lib/organism/review-slide/index.native.js.map +1 -1
- package/lib/organism/review-stacked-slides/index.native.d.ts.map +1 -1
- package/lib/organism/review-stacked-slides/index.native.js +21 -3
- package/lib/organism/review-stacked-slides/index.native.js.map +1 -1
- package/package.json +2 -2
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.native.js","names":["React","useCallback","useEffect","useState","useRef","Animated","Easing","StyleSheet","useWindowDimensions","View","get","getOr","Text","Answer","ReviewCorrectionPopin","useTemplateContext","Button","styles","create","correctionPopinWrapper","position","bottom","width","CorrectionPopin","correctionPopinProps","slideIndex","showCorrectionPopin","animateCorrectionPopin","translateAnim","Value","current","translateYAnim","timing","toValue","duration","easing","bezier","useNativeDriver","start","klf","undefined","information","label","message","next","onClick","_correctionPopinProps","type","resultLabel","transform","translateY","createQuestionStyle","theme","questionHeading","justifyContent","questionOrigin","fontSize","lineHeight","color","colors","text","primary","marginBottom","spacing","tiny","marginTop","small","textAlign","questionText","fontWeight","questionHelp","gray","medium","choicesContainer","flex","Question","props","answerUI","style","setStyle","questionStyle","createSlideStyle","num","screenWidth","slideWidth","slide","left","backgroundColor","height","alignItems","padding","shadowColor","shadowOffset","shadowOpacity","shadowRadius","elevation","borderRadius","Slide","validateButton","slideStyle","loading","parentContentTitle","handleValidatePress","disabled"],"sources":["../../../src/organism/review-slide/index.native.tsx"],"sourcesContent":["import React, {useCallback, useEffect, useState, useRef} from 'react';\nimport {\n Animated,\n Easing,\n StyleSheet,\n TextStyle,\n useWindowDimensions,\n View,\n ViewStyle\n} from 'react-native';\nimport get from 'lodash/fp/get';\nimport getOr from 'lodash/fp/getOr';\nimport Text from '../../atom/text/index.native';\nimport Answer from '../../molecule/answer/index.native';\nimport ReviewCorrectionPopin from '../../molecule/review-correction-popin/index.native';\nimport {useTemplateContext} from '../../template/app-review/template-context';\nimport {Theme} from '../../variables/theme.native';\nimport Button from '../../atom/button/index.native';\nimport {PopinProps, ReviewSlideProps, SlideProps} from './prop-types';\n\nconst styles = StyleSheet.create({\n correctionPopinWrapper: {\n position: 'absolute',\n bottom: 16,\n width: '105%'\n }\n});\n\nconst CorrectionPopin = ({\n correctionPopinProps,\n slideIndex,\n showCorrectionPopin,\n animateCorrectionPopin\n}: PopinProps) => {\n const translateAnim = useRef(new Animated.Value(1000)).current;\n\n const translateYAnim = useCallback(() => {\n Animated.timing(translateAnim, {\n toValue: 0,\n duration: 800,\n easing: Easing.bezier(0.37, 0, 0.63, 1),\n useNativeDriver: true\n }).start();\n }, [translateAnim]);\n\n if (animateCorrectionPopin) {\n translateYAnim();\n }\n\n if (!showCorrectionPopin) return null;\n\n const klf = getOr(undefined, 'klf', correctionPopinProps);\n const information = getOr({label: '', message: ''}, 'information', correctionPopinProps);\n const next = get('next', correctionPopinProps);\n const onClick = get(['next', 'onClick'], correctionPopinProps);\n\n const _correctionPopinProps = {\n next: {\n onClick,\n label: next && next.label,\n 'data-name': `next-question-button-${slideIndex}`,\n 'aria-label': next && next['aria-label']\n },\n klf,\n information,\n type: correctionPopinProps.type,\n resultLabel: correctionPopinProps.resultLabel\n };\n\n return (\n <Animated.View\n style={{\n ...styles.correctionPopinWrapper,\n transform: [\n {\n translateY: translateAnim\n }\n ]\n }}\n >\n <ReviewCorrectionPopin {..._correctionPopinProps} />\n </Animated.View>\n );\n};\n\ntype StyleSheetType = {\n questionHeading: ViewStyle;\n questionOrigin: ViewStyle;\n questionText: TextStyle;\n questionHelp: ViewStyle;\n choicesContainer: ViewStyle;\n};\n\nconst createQuestionStyle = (theme: Theme): StyleSheetType =>\n StyleSheet.create({\n questionHeading: {\n justifyContent: 'space-between'\n },\n questionOrigin: {\n fontSize: 12,\n lineHeight: 16,\n color: theme.colors.text.primary,\n marginBottom: theme.spacing.tiny,\n marginTop: theme.spacing.small,\n textAlign: 'center'\n },\n questionText: {\n fontSize: 16,\n lineHeight: 22,\n fontWeight: '700',\n color: theme.colors.text.primary,\n textAlign: 'center'\n },\n questionHelp: {\n fontSize: 12,\n lineHeight: 16,\n color: theme.colors.gray.medium,\n marginBottom: 0,\n marginTop: theme.spacing.small,\n textAlign: 'center'\n },\n choicesContainer: {\n flex: 1,\n width: '100%',\n justifyContent: 'center'\n }\n });\n\ntype QuestionProps = {\n answerUI: SlideProps['answerUI'];\n questionText: SlideProps['questionText'];\n questionOrigin: SlideProps['parentContentTitle'];\n};\n\nconst Question = (props: QuestionProps) => {\n const {answerUI, questionText, questionOrigin} = props;\n const {theme} = useTemplateContext();\n const [style, setStyle] = useState<StyleSheetType>();\n\n useEffect(() => {\n const questionStyle = createQuestionStyle(theme);\n setStyle(questionStyle);\n }, [theme]);\n\n if (!answerUI || !questionText || !style) return null;\n\n return (\n <>\n <View style={style.questionHeading}>\n <Text style={style.questionOrigin}>{questionOrigin}</Text>\n <Text style={style.questionText}>{questionText}</Text>\n <Text style={style.questionHelp}>{get('help', answerUI)}</Text>\n </View>\n <View style={style.choicesContainer}>\n <Answer {...answerUI} />\n </View>\n </>\n );\n};\n\ntype SlideStyle = {\n slide: ViewStyle;\n};\n\nconst createSlideStyle = (num: number, screenWidth: number): SlideStyle => {\n const slideWidth = screenWidth - 40 - num * 8;\n\n return StyleSheet.create({\n slide: {\n position: 'absolute',\n left: 20 + num * 4,\n bottom: 34 + num * 5,\n backgroundColor: '#fff', // theme.colors.white\n height: '90%',\n width: slideWidth,\n justifyContent: 'space-between',\n alignItems: 'center',\n padding: 25,\n shadowColor: '#000',\n shadowOffset: {width: 0, height: -1},\n shadowOpacity: 0.05,\n shadowRadius: 16,\n elevation: 10 - num * 1,\n borderRadius: 16\n }\n });\n};\n\nconst Slide = (props: ReviewSlideProps) => {\n const {slide, correctionPopinProps, validateButton, num, slideIndex = '0'} = props;\n\n const {width} = useWindowDimensions();\n const slideStyle = createSlideStyle(num, width);\n\n const {\n loading,\n parentContentTitle,\n questionText,\n answerUI,\n showCorrectionPopin,\n animateCorrectionPopin\n } = slide;\n\n if (loading) {\n return <Text>@todo loader {num}</Text>;\n }\n\n const {onClick: handleValidatePress} = validateButton;\n\n return (\n <View style={slideStyle.slide}>\n <Question\n questionOrigin={parentContentTitle}\n questionText={questionText}\n answerUI={answerUI}\n key=\"question-container\"\n />\n <Button\n disabled={validateButton.disabled}\n submitValue={validateButton.label}\n onPress={handleValidatePress}\n testID={`slide-validate-button-${slideIndex}`}\n />\n {correctionPopinProps ? (\n <CorrectionPopin\n correctionPopinProps={correctionPopinProps}\n slideIndex={slideIndex}\n showCorrectionPopin={showCorrectionPopin}\n animateCorrectionPopin={animateCorrectionPopin}\n key=\"correction-popin\"\n />\n ) : null}\n </View>\n );\n};\n\nexport default Slide;\n"],"mappings":";;AAAA,OAAOA,KAAP,IAAeC,WAAf,EAA4BC,SAA5B,EAAuCC,QAAvC,EAAiDC,MAAjD,QAA8D,OAA9D;AACA,SACEC,QADF,EAEEC,MAFF,EAGEC,UAHF,EAKEC,mBALF,EAMEC,IANF,QAQO,cARP;AASA,OAAOC,GAAP,MAAgB,eAAhB;AACA,OAAOC,KAAP,MAAkB,iBAAlB;AACA,OAAOC,IAAP,MAAiB,8BAAjB;AACA,OAAOC,MAAP,MAAmB,oCAAnB;AACA,OAAOC,qBAAP,MAAkC,qDAAlC;AACA,SAAQC,kBAAR,QAAiC,4CAAjC;AAEA,OAAOC,MAAP,MAAmB,gCAAnB;AAGA,MAAMC,MAAM,GAAGV,UAAU,CAACW,MAAX,CAAkB;EAC/BC,sBAAsB,EAAE;IACtBC,QAAQ,EAAE,UADY;IAEtBC,MAAM,EAAE,EAFc;IAGtBC,KAAK,EAAE;EAHe;AADO,CAAlB,CAAf;;AAQA,MAAMC,eAAe,GAAG,CAAC;EACvBC,oBADuB;EAEvBC,UAFuB;EAGvBC,mBAHuB;EAIvBC;AAJuB,CAAD,KAKN;EAChB,MAAMC,aAAa,GAAGxB,MAAM,CAAC,IAAIC,QAAQ,CAACwB,KAAb,CAAmB,IAAnB,CAAD,CAAN,CAAiCC,OAAvD;EAEA,MAAMC,cAAc,GAAG9B,WAAW,CAAC,MA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GE,mBAAmB,EAAEC,mBAHvB;IAIE,sBAAsB,EAAEC,sBAJ1B;IAKE,GAAG,EAAC;EALN,EADmB,GAQjB,IArBN,CADF;AAyBD,CA9CD;;AAgDA,eAAesE,KAAf"}
|
|
1
|
+
{"version":3,"file":"index.native.js","names":["React","useEffect","useState","Animated","Easing","StyleSheet","useWindowDimensions","View","get","getOr","Text","Answer","ReviewCorrectionPopin","useTemplateContext","Button","useTranslateVertically","styles","create","correctionPopinWrapper","position","bottom","width","CorrectionPopin","correctionPopinProps","slideIndex","showCorrectionPopin","animateCorrectionPopin","translateUp","fromValue","toValue","duration","easing","bezier","klf","undefined","information","label","message","next","onClick","_correctionPopinProps","type","resultLabel","style","animatedY","createQuestionStyle","theme","questionHeading","justifyContent","questionOrigin","fontSize","lineHeight","color","colors","text","primary","marginBottom","spacing","tiny","marginTop","small","textAlign","questionText","fontWeight","questionHelp","gray","medium","choicesContainer","flex","Question","props","answerUI","setStyle","questionStyle","createSlideStyle","num","screenWidth","slideWidth","slide","left","backgroundColor","height","alignItems","padding","shadowColor","shadowOffset","shadowOpacity","shadowRadius","elevation","borderRadius","Slide","validateButton","slideStyle","loading","parentContentTitle","handleValidatePress","disabled"],"sources":["../../../src/organism/review-slide/index.native.tsx"],"sourcesContent":["import React, {useEffect, useState} from 'react';\nimport {\n Animated,\n Easing,\n StyleSheet,\n TextStyle,\n useWindowDimensions,\n View,\n ViewStyle\n} from 'react-native';\nimport get from 'lodash/fp/get';\nimport getOr from 'lodash/fp/getOr';\nimport Text from '../../atom/text/index.native';\nimport Answer from '../../molecule/answer/index.native';\nimport ReviewCorrectionPopin from '../../molecule/review-correction-popin/index.native';\nimport {useTemplateContext} from '../../template/app-review/template-context';\nimport {Theme} from '../../variables/theme.native';\nimport Button from '../../atom/button/index.native';\nimport useTranslateVertically from '../../behaviours/use-translate-vertically.native';\nimport {PopinProps, ReviewSlideProps, SlideProps} from './prop-types';\n\nconst styles = StyleSheet.create({\n correctionPopinWrapper: {\n position: 'absolute',\n bottom: 16,\n width: '105%'\n }\n});\n\nconst CorrectionPopin = ({\n correctionPopinProps,\n slideIndex,\n showCorrectionPopin,\n animateCorrectionPopin\n}: PopinProps) => {\n const translateUp = useTranslateVertically({\n fromValue: 1000,\n toValue: 0,\n duration: 800,\n easing: Easing.bezier(0.37, 0, 0.63, 1)\n });\n\n if (!showCorrectionPopin) return null;\n\n const klf = getOr(undefined, 'klf', correctionPopinProps);\n const information = getOr({label: '', message: ''}, 'information', correctionPopinProps);\n const next = get('next', correctionPopinProps);\n const onClick = get(['next', 'onClick'], correctionPopinProps);\n\n const _correctionPopinProps = {\n next: {\n onClick,\n label: next && next.label,\n 'data-name': `next-question-button-${slideIndex}`,\n 'aria-label': next && next['aria-label']\n },\n klf,\n information,\n type: correctionPopinProps.type,\n resultLabel: correctionPopinProps.resultLabel\n };\n\n const style = animateCorrectionPopin\n ? [styles.correctionPopinWrapper, translateUp.animatedY]\n : styles.correctionPopinWrapper;\n\n return (\n <Animated.View style={style}>\n <ReviewCorrectionPopin {..._correctionPopinProps} />\n </Animated.View>\n );\n};\n\ntype StyleSheetType = {\n questionHeading: ViewStyle;\n questionOrigin: ViewStyle;\n questionText: TextStyle;\n questionHelp: ViewStyle;\n choicesContainer: ViewStyle;\n};\n\nconst createQuestionStyle = (theme: Theme): StyleSheetType =>\n StyleSheet.create({\n questionHeading: {\n justifyContent: 'space-between'\n },\n questionOrigin: {\n fontSize: 12,\n lineHeight: 16,\n color: theme.colors.text.primary,\n marginBottom: theme.spacing.tiny,\n marginTop: theme.spacing.small,\n textAlign: 'center'\n },\n questionText: {\n fontSize: 16,\n lineHeight: 22,\n fontWeight: '700',\n color: theme.colors.text.primary,\n textAlign: 'center'\n },\n questionHelp: {\n fontSize: 12,\n lineHeight: 16,\n color: theme.colors.gray.medium,\n marginBottom: 0,\n marginTop: theme.spacing.small,\n textAlign: 'center'\n },\n choicesContainer: {\n flex: 1,\n width: '100%',\n justifyContent: 'center'\n }\n });\n\ntype QuestionProps = {\n answerUI: SlideProps['answerUI'];\n questionText: SlideProps['questionText'];\n questionOrigin: SlideProps['parentContentTitle'];\n};\n\nconst Question = (props: QuestionProps) => {\n const {answerUI, questionText, questionOrigin} = props;\n const {theme} = useTemplateContext();\n const [style, setStyle] = useState<StyleSheetType>();\n\n useEffect(() => {\n const questionStyle = createQuestionStyle(theme);\n setStyle(questionStyle);\n }, [theme]);\n\n if (!answerUI || !questionText || !style) return null;\n\n return (\n <>\n <View style={style.questionHeading}>\n <Text style={style.questionOrigin}>{questionOrigin}</Text>\n <Text style={style.questionText}>{questionText}</Text>\n <Text style={style.questionHelp}>{get('help', answerUI)}</Text>\n </View>\n <View style={style.choicesContainer}>\n <Answer {...answerUI} />\n </View>\n </>\n );\n};\n\ntype SlideStyle = {\n slide: ViewStyle;\n};\n\nconst createSlideStyle = (num: number, screenWidth: number): SlideStyle => {\n const slideWidth = screenWidth - 40 - num * 8;\n\n return StyleSheet.create({\n slide: {\n position: 'absolute',\n left: 20 + num * 4,\n bottom: 34 + num * 5,\n backgroundColor: '#fff', // theme.colors.white\n height: '90%',\n width: slideWidth,\n justifyContent: 'space-between',\n alignItems: 'center',\n padding: 25,\n shadowColor: '#000',\n shadowOffset: {width: 0, height: -1},\n shadowOpacity: 0.05,\n shadowRadius: 16,\n elevation: 10 - num * 1,\n borderRadius: 16\n }\n });\n};\n\nconst Slide = (props: ReviewSlideProps) => {\n const {slide, correctionPopinProps, validateButton, num, slideIndex = '0'} = props;\n\n const {width} = useWindowDimensions();\n const slideStyle = createSlideStyle(num, width);\n\n const {\n loading,\n parentContentTitle,\n questionText,\n answerUI,\n showCorrectionPopin,\n animateCorrectionPopin\n } = slide;\n\n if (loading) {\n return <Text>@todo loader {num}</Text>;\n }\n\n const {onClick: handleValidatePress} = validateButton;\n\n return (\n <View style={slideStyle.slide}>\n <Question\n questionOrigin={parentContentTitle}\n questionText={questionText}\n answerUI={answerUI}\n key=\"question-container\"\n />\n <Button\n disabled={validateButton.disabled}\n submitValue={validateButton.label}\n onPress={handleValidatePress}\n testID={`slide-validate-button-${slideIndex}`}\n />\n {correctionPopinProps ? (\n <CorrectionPopin\n correctionPopinProps={correctionPopinProps}\n slideIndex={slideIndex}\n showCorrectionPopin={showCorrectionPopin}\n animateCorrectionPopin={animateCorrectionPopin}\n key=\"correction-popin\"\n />\n ) : null}\n </View>\n );\n};\n\nexport default Slide;\n"],"mappings":"AAAA,OAAOA,KAAP,IAAeC,SAAf,EAA0BC,QAA1B,QAAyC,OAAzC;AACA,SACEC,QADF,EAEEC,MAFF,EAGEC,UAHF,EAKEC,mBALF,EAMEC,IANF,QAQO,cARP;AASA,OAAOC,GAAP,MAAgB,eAAhB;AACA,OAAOC,KAAP,MAAkB,iBAAlB;AACA,OAAOC,IAAP,MAAiB,8BAAjB;AACA,OAAOC,MAAP,MAAmB,oCAAnB;AACA,OAAOC,qBAAP,MAAkC,qDAAlC;AACA,SAAQC,kBAAR,QAAiC,4CAAjC;AAEA,OAAOC,MAAP,MAAmB,gCAAnB;AACA,OAAOC,sBAAP,MAAmC,kDAAnC;AAGA,MAAMC,MAAM,GAAGX,UAAU,CAACY,MAAX,CAAkB;EAC/BC,sBAAsB,EAAE;IACtBC,QAAQ,EAAE,UADY;IAEtBC,MAAM,EAAE,EAFc;IAGtBC,KAAK,EAAE;EAHe;AADO,CAAlB,CAAf;;AAQA,MAAMC,eAAe,GAAG,CAAC;EACvBC,oBADuB;EAEvBC,UAFuB;EAGvBC,mBAHuB;EAIvBC;AAJuB,CAAD,KAKN;EAChB,MAAMC,WAAW,GAAGZ,sBAAsB,CAAC;IACzCa,SAAS,EAAE,IAD8B;IAEzCC,OAAO,EAAE,CAFgC;IAGzCC,QAAQ,EAAE,GAH+B;IAIzCC,MAAM,EAAE3B,MAAM,CAAC4B,MAAP,CAAc,IAAd,EAAoB,CAApB,EAAuB,IAAvB,EAA6B,CAA7B;EAJiC,CAAD,CAA1C;EAOA,IAAI,CAACP,mBAAL,EAA0B,OAAO,IA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A9B;IAA8ChB,GAA9C;IAAmDnD,UAAU,GAAG;EAAhE,IAAuE8C,KAA7E;EAEA,MAAM;IAACjD;EAAD,IAAUf,mBAAmB,EAAnC;EACA,MAAMsF,UAAU,GAAGlB,gBAAgB,CAACC,GAAD,EAAMtD,KAAN,CAAnC;EAEA,MAAM;IACJwE,OADI;IAEJC,kBAFI;IAGJhC,YAHI;IAIJS,QAJI;IAKJ9C,mBALI;IAMJC;EANI,IAOFoD,KAPJ;;EASA,IAAIe,OAAJ,EAAa;IACX,oBAAO,oBAAC,IAAD,yBAAoBlB,GAApB,CAAP;EACD;;EAED,MAAM;IAACpC,OAAO,EAAEwD;EAAV,IAAiCJ,cAAvC;EAEA,oBACE,oBAAC,IAAD;IAAM,KAAK,EAAEC,UAAU,CAACd;EAAxB,gBACE,oBAAC,QAAD;IACE,cAAc,EAAEgB,kBADlB;IAEE,YAAY,EAAEhC,YAFhB;IAGE,QAAQ,EAAES,QAHZ;IAIE,GAAG,EAAC;EAJN,EADF,eAOE,oBAAC,MAAD;IACE,QAAQ,EAAEoB,cAAc,CAACK,QAD3B;IAEE,WAAW,EAAEL,cAAc,CAACvD,KAF9B;IAGE,OAAO,EAAE2D,mBAHX;IAIE,MAAM,EAAG,yBAAwBvE,UAAW;EAJ9C,EAPF,EAaGD,oBAAoB,gBACnB,oBAAC,eAAD;IACE,oBAAoB,EAAEA,oBADxB;IAEE,UAAU,EAAEC,UAFd;IAGE,mBAAmB,EAAEC,mBAHvB;IAIE,sBAAsB,EAAEC,sBAJ1B;IAKE,GAAG,EAAC;EALN,EADmB,GAQjB,IArBN,CADF;AAyBD,CA9CD;;AAgDA,eAAegE,KAAf"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.native.d.ts","sourceRoot":"","sources":["../../../src/organism/review-stacked-slides/index.native.tsx"],"names":[],"mappings":";
|
|
1
|
+
{"version":3,"file":"index.native.d.ts","sourceRoot":"","sources":["../../../src/organism/review-stacked-slides/index.native.tsx"],"names":[],"mappings":";AAKA,OAAO,EAAC,gBAAgB,EAAC,MAAM,cAAc,CAAC;AAE9C,eAAO,MAAM,kBAAkB,IAAI,CAAC;AAUpC,QAAA,MAAM,aAAa,UAAW,gBAAgB,gBA+B7C,CAAC;AAEF,eAAe,aAAa,CAAC"}
|
|
@@ -1,7 +1,8 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { StyleSheet,
|
|
1
|
+
import React, { useEffect } from 'react';
|
|
2
|
+
import { Animated, StyleSheet, useWindowDimensions } from 'react-native';
|
|
3
3
|
import keys from 'lodash/fp/keys';
|
|
4
4
|
import Slide from '../review-slide/index.native';
|
|
5
|
+
import useTranslateVertically from '../../behaviours/use-translate-vertically.native';
|
|
5
6
|
export const TOTAL_SLIDES_STACK = 5;
|
|
6
7
|
const style = StyleSheet.create({
|
|
7
8
|
slides: {
|
|
@@ -12,11 +13,23 @@ const style = StyleSheet.create({
|
|
|
12
13
|
});
|
|
13
14
|
|
|
14
15
|
const StackedSlides = props => {
|
|
16
|
+
const {
|
|
17
|
+
height: windowHeight
|
|
18
|
+
} = useWindowDimensions();
|
|
15
19
|
const {
|
|
16
20
|
slides,
|
|
17
21
|
validateButton,
|
|
18
22
|
correctionPopinProps
|
|
19
23
|
} = props;
|
|
24
|
+
const {
|
|
25
|
+
translate,
|
|
26
|
+
animatedY
|
|
27
|
+
} = useTranslateVertically({
|
|
28
|
+
fromValue: 0,
|
|
29
|
+
toValue: windowHeight,
|
|
30
|
+
duration: 800
|
|
31
|
+
});
|
|
32
|
+
useEffect(translate, [translate]);
|
|
20
33
|
const indexes = keys(slides).reverse();
|
|
21
34
|
const stackedSlides = indexes.map(slideIndex => {
|
|
22
35
|
const slide = slides[slideIndex];
|
|
@@ -29,8 +42,8 @@ const StackedSlides = props => {
|
|
|
29
42
|
key: slideIndex
|
|
30
43
|
});
|
|
31
44
|
});
|
|
32
|
-
return /*#__PURE__*/React.createElement(View, {
|
|
33
|
-
style: style.slides
|
|
45
|
+
return /*#__PURE__*/React.createElement(Animated.View, {
|
|
46
|
+
style: [style.slides, animatedY]
|
|
34
47
|
}, stackedSlides);
|
|
35
48
|
};
|
|
36
49
|
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.native.js","names":["React","StyleSheet","
|
|
1
|
+
{"version":3,"file":"index.native.js","names":["React","useEffect","Animated","StyleSheet","useWindowDimensions","keys","Slide","useTranslateVertically","TOTAL_SLIDES_STACK","style","create","slides","flex","height","width","StackedSlides","props","windowHeight","validateButton","correctionPopinProps","translate","animatedY","fromValue","toValue","duration","indexes","reverse","stackedSlides","map","slideIndex","slide","num","Number","parseInt"],"sources":["../../../src/organism/review-stacked-slides/index.native.tsx"],"sourcesContent":["import React, {useEffect} from 'react';\nimport {Animated, StyleSheet, useWindowDimensions} from 'react-native';\nimport keys from 'lodash/fp/keys';\nimport Slide from '../review-slide/index.native';\nimport useTranslateVertically from '../../behaviours/use-translate-vertically.native';\nimport {ReviewStackProps} from './prop-types';\n\nexport const TOTAL_SLIDES_STACK = 5;\n\nconst style = StyleSheet.create({\n slides: {\n flex: 1,\n height: '100%',\n width: '100%'\n }\n});\n\nconst StackedSlides = (props: ReviewStackProps) => {\n const {height: windowHeight} = useWindowDimensions();\n const {slides, validateButton, correctionPopinProps} = props;\n\n const {translate, animatedY} = useTranslateVertically({\n fromValue: 0,\n toValue: windowHeight,\n duration: 800\n });\n\n useEffect(translate, [translate]);\n\n const indexes = keys(slides).reverse();\n const stackedSlides = indexes.map(slideIndex => {\n const slide = slides[slideIndex];\n\n return (\n <Slide\n {...{\n num: Number.parseInt(slideIndex),\n slideIndex,\n slide,\n validateButton,\n correctionPopinProps\n }}\n key={slideIndex}\n />\n );\n });\n\n return <Animated.View style={[style.slides, animatedY]}>{stackedSlides}</Animated.View>;\n};\n\nexport default StackedSlides;\n"],"mappings":"AAAA,OAAOA,KAAP,IAAeC,SAAf,QAA+B,OAA/B;AACA,SAAQC,QAAR,EAAkBC,UAAlB,EAA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A/BD;;AAiCA,eAAeZ,aAAf"}
|
|
@@ -43,11 +43,11 @@ const toSrcSet = ({
|
|
|
43
43
|
const toSetAlt = ({
|
|
44
44
|
alt
|
|
45
45
|
}) => {
|
|
46
|
-
return
|
|
46
|
+
return alt ? {
|
|
47
|
+
alt
|
|
48
|
+
} : {
|
|
47
49
|
alt: '',
|
|
48
50
|
'aria-hidden': true
|
|
49
|
-
} : {
|
|
50
|
-
alt
|
|
51
51
|
};
|
|
52
52
|
};
|
|
53
53
|
|
|
@@ -66,7 +66,8 @@ const Picture = props => {
|
|
|
66
66
|
};
|
|
67
67
|
|
|
68
68
|
Picture.propTypes = process.env.NODE_ENV !== "production" ? {
|
|
69
|
-
src: _propTypes.default.oneOfType([_proptypes.SrcPropType, _propTypes.default.objectOf(_proptypes.SrcPropType)])
|
|
69
|
+
src: _propTypes.default.oneOfType([_proptypes.SrcPropType, _propTypes.default.objectOf(_proptypes.SrcPropType)]),
|
|
70
|
+
alt: _propTypes.default.string
|
|
70
71
|
} : {};
|
|
71
72
|
var _default = Picture;
|
|
72
73
|
exports.default = _default;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","names":["toSrcSet","src","key","url","toSetAlt","alt","Picture","props","style","empty","propTypes","PropTypes","oneOfType","SrcPropType","objectOf"],"sources":["../../../src/atom/picture/index.js"],"sourcesContent":["import React from 'react';\nimport PropTypes from 'prop-types';\nimport {filter, get, isNil, isObject, join, map, pipe, set, toPairs} from 'lodash/fp';\nimport {SrcPropType} from '../../util/proptypes';\nimport style from './style.css';\n\nconst toSrcSet = ({src}) => {\n if (!isObject(src)) return {};\n return pipe(\n set(\n 'srcSet',\n pipe(\n toPairs,\n filter(([key, url]) => url),\n map(([key, url]) => `${url} ${key}`),\n join(',')\n )(src)\n ),\n set('src', get('1x', src))\n )({});\n};\n\nconst toSetAlt = ({alt}) => {\n return
|
|
1
|
+
{"version":3,"file":"index.js","names":["toSrcSet","src","key","url","toSetAlt","alt","Picture","props","style","empty","propTypes","PropTypes","oneOfType","SrcPropType","objectOf","string"],"sources":["../../../src/atom/picture/index.js"],"sourcesContent":["import React from 'react';\nimport PropTypes from 'prop-types';\nimport {filter, get, isNil, isObject, join, map, pipe, set, toPairs} from 'lodash/fp';\nimport {SrcPropType} from '../../util/proptypes';\nimport style from './style.css';\n\nconst toSrcSet = ({src}) => {\n if (!isObject(src)) return {};\n return pipe(\n set(\n 'srcSet',\n pipe(\n toPairs,\n filter(([key, url]) => url),\n map(([key, url]) => `${url} ${key}`),\n join(',')\n )(src)\n ),\n set('src', get('1x', src))\n )({});\n};\n\nconst toSetAlt = ({alt}) => {\n return alt ? {alt} : {alt: '', 'aria-hidden': true};\n};\n\nconst Picture = props => {\n const {src} = props;\n if (isNil(src)) {\n return <div className={style.empty} />;\n }\n return <img {...props} {...toSrcSet(props)} {...toSetAlt(props)} />;\n};\n\nPicture.propTypes = {\n src: PropTypes.oneOfType([SrcPropType, PropTypes.objectOf(SrcPropType)]),\n alt: PropTypes.string\n};\n\nexport default Picture;\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;AAAA;;AACA;;AAEA;;AACA;;;;;;AAEA,MAAMA,QAAQ,GAAG,CAAC;EAACC;AAAD,CAAD,KAAW;EAC1B,IAAI,CAAC,wBAASA,GAAT,CAAL,EAAoB,OAAO,EAAP;EACpB,OAAO,oBACL,mBACE,QADF,EAEE,uCAEE,sBAAO,CAAC,CAACC,GAAD,EAAMC,GAAN,CAAD,KAAgBA,GAAvB,CAFF,EAGE,mBAAI,CAAC,CAACD,GAAD,EAAMC,GAAN,CAAD,KAAiB,GAAEA,GAAI,IAAGD,GAAI,EAAlC,CAHF,EAIE,oBAAK,GAAL,CAJF,EAKED,GALF,CAFF,CADK,EAUL,mBAAI,KAAJ,EAAW,mBAAI,IAAJ,EAAUA,GAAV,CAAX,CAVK,EAWL,EAXK,CAAP;AAYD,CAdD;;AAgBA,MAAMG,QAAQ,GAAG,CAAC;EAACC;AAAD,CAAD,KAAW;EAC1B,OAAOA,GAAG,GAAG;IAACA;EAAD,CAAH,GAAW;IAACA,GAAG,EAAE,EAAN;IAAU,eAAe;EAAzB,CAArB;AACD,CAFD;;AAIA,MAAMC,OAAO,GAAGC,KAAK,IAAI;EACvB,MAAM;IAACN;EAAD,IAAQM,KAAd;;EACA,IAAI,qBAAMN,GAAN,CAAJ,EAAgB;IACd,oBAAO;MAAK,SAAS,EAAEO,cAAA,CAAMC;IAAtB,EAAP;EACD;;EACD,oBAAO,iDAASF,KAAT,EAAoBP,QAAQ,CAACO,KAAD,CAA5B,EAAyCH,QAAQ,CAACG,KAAD,CAAjD,EAAP;AACD,CAND;;AAQAD,OAAO,CAACI,SAAR,2CAAoB;EAClBT,GAAG,EAAEU,kBAAA,CAAUC,SAAV,CAAoB,CAACC,sBAAD,EAAcF,kBAAA,CAAUG,QAAV,CAAmBD,sBAAnB,CAAd,CAApB,CADa;EAElBR,GAAG,EAAEM,kBAAA,CAAUI;AAFG,CAApB;eAKeT,O"}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { Animated } from 'react-native';
|
|
2
|
+
declare type Params = Omit<Animated.TimingAnimationConfig, 'useNativeDriver' | 'toValue'> & {
|
|
3
|
+
onFinished?: () => void;
|
|
4
|
+
fromValue?: number;
|
|
5
|
+
toValue?: Animated.TimingAnimationConfig['toValue'];
|
|
6
|
+
};
|
|
7
|
+
declare const useTranslateVertically: (params?: Params) => {
|
|
8
|
+
translate: () => void;
|
|
9
|
+
animatedY: {
|
|
10
|
+
transform: {
|
|
11
|
+
translateY: Animated.Value;
|
|
12
|
+
}[];
|
|
13
|
+
};
|
|
14
|
+
};
|
|
15
|
+
export default useTranslateVertically;
|
|
16
|
+
//# sourceMappingURL=use-translate-vertically.native.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"use-translate-vertically.native.d.ts","sourceRoot":"","sources":["../../src/behaviours/use-translate-vertically.native.tsx"],"names":[],"mappings":"AACA,OAAO,EAAC,QAAQ,EAAC,MAAM,cAAc,CAAC;AAEtC,aAAK,MAAM,GAAG,IAAI,CAAC,QAAQ,CAAC,qBAAqB,EAAE,iBAAiB,GAAG,SAAS,CAAC,GAAG;IAClF,UAAU,CAAC,EAAE,MAAM,IAAI,CAAC;IACxB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,OAAO,CAAC,EAAE,QAAQ,CAAC,qBAAqB,CAAC,SAAS,CAAC,CAAC;CACrD,CAAC;AAEF,QAAA,MAAM,sBAAsB,YAAY,MAAM;;;;;;;CAkB7C,CAAC;AAEF,eAAe,sBAAsB,CAAC"}
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
exports.__esModule = true;
|
|
4
|
+
exports.default = void 0;
|
|
5
|
+
|
|
6
|
+
var _react = require("react");
|
|
7
|
+
|
|
8
|
+
var _reactNative = require("react-native");
|
|
9
|
+
|
|
10
|
+
const _excluded = ["fromValue", "toValue", "duration", "onFinished"];
|
|
11
|
+
|
|
12
|
+
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
13
|
+
|
|
14
|
+
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
|
15
|
+
|
|
16
|
+
const useTranslateVertically = (params = {}) => {
|
|
17
|
+
const {
|
|
18
|
+
fromValue = 0,
|
|
19
|
+
toValue = 100,
|
|
20
|
+
duration = 550,
|
|
21
|
+
onFinished
|
|
22
|
+
} = params,
|
|
23
|
+
othersParams = _objectWithoutPropertiesLoose(params, _excluded);
|
|
24
|
+
|
|
25
|
+
const translateY = (0, _react.useRef)(new _reactNative.Animated.Value(fromValue)).current;
|
|
26
|
+
const translate = (0, _react.useCallback)(() => {
|
|
27
|
+
_reactNative.Animated.timing(translateY, _extends({}, othersParams, {
|
|
28
|
+
toValue,
|
|
29
|
+
duration,
|
|
30
|
+
useNativeDriver: true
|
|
31
|
+
})).start(({
|
|
32
|
+
finished
|
|
33
|
+
}) => {
|
|
34
|
+
if (finished) {
|
|
35
|
+
onFinished?.();
|
|
36
|
+
}
|
|
37
|
+
});
|
|
38
|
+
}, [onFinished, duration, othersParams, toValue, translateY]);
|
|
39
|
+
return {
|
|
40
|
+
translate,
|
|
41
|
+
animatedY: {
|
|
42
|
+
transform: [{
|
|
43
|
+
translateY
|
|
44
|
+
}]
|
|
45
|
+
}
|
|
46
|
+
};
|
|
47
|
+
};
|
|
48
|
+
|
|
49
|
+
var _default = useTranslateVertically;
|
|
50
|
+
exports.default = _default;
|
|
51
|
+
//# sourceMappingURL=use-translate-vertically.native.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"use-translate-vertically.native.js","names":["useTranslateVertically","params","fromValue","toValue","duration","onFinished","othersParams","translateY","useRef","Animated","Value","current","translate","useCallback","timing","useNativeDriver","start","finished","animatedY","transform"],"sources":["../../src/behaviours/use-translate-vertically.native.tsx"],"sourcesContent":["import {useCallback, useRef} from 'react';\nimport {Animated} from 'react-native';\n\ntype Params = Omit<Animated.TimingAnimationConfig, 'useNativeDriver' | 'toValue'> & {\n onFinished?: () => void;\n fromValue?: number;\n toValue?: Animated.TimingAnimationConfig['toValue'];\n};\n\nconst useTranslateVertically = (params: Params = {}) => {\n const {fromValue = 0, toValue = 100, duration = 550, onFinished, ...othersParams} = params;\n const translateY = useRef(new Animated.Value(fromValue)).current;\n\n const translate = useCallback(() => {\n Animated.timing(translateY, {\n ...othersParams,\n toValue,\n duration,\n useNativeDriver: true\n }).start(({finished}) => {\n if (finished) {\n onFinished?.();\n }\n });\n }, [onFinished, duration, othersParams, toValue, translateY]);\n\n return {translate, animatedY: {transform: [{translateY}]}};\n};\n\nexport default useTranslateVertically;\n"],"mappings":";;;;;AAAA;;AACA;;;;;;;;AAQA,MAAMA,sBAAsB,GAAG,CAACC,MAAc,GAAG,EAAlB,KAAyB;EACtD,MAAM;IAACC,SAAS,GAAG,CAAb;IAAgBC,OAAO,GAAG,GAA1B;IAA+BC,QAAQ,GAAG,GAA1C;IAA+CC;EAA/C,IAA8EJ,MAApF;EAAA,MAAoEK,YAApE,iCAAoFL,MAApF;;EACA,MAAMM,UAAU,GAAG,IAAAC,aAAA,EAAO,IAAIC,qBAAA,CAASC,KAAb,CAAmBR,SAAnB,CAAP,EAAsCS,OAAzD;EAEA,MAAMC,SAAS,GAAG,IAAAC,kBAAA,EAAY,MAAM;IAClCJ,qBAAA,CAASK,MAAT,CAAgBP,UAAhB,eACKD,YADL;MAEEH,OAFF;MAGEC,QAHF;MAIEW,eAAe,EAAE;IAJnB,IAKGC,KALH,CAKS,CAAC;MAACC;IAAD,CAAD,KAAgB;MACvB,IAAIA,QAAJ,EAAc;QACZZ,UAAU;MACX;IACF,CATD;EAUD,CAXiB,EAWf,CAACA,UAAD,EAAaD,QAAb,EAAuBE,YAAvB,EAAqCH,OAArC,EAA8CI,UAA9C,CAXe,CAAlB;EAaA,OAAO;IAACK,SAAD;IAAYM,SAAS,EAAE;MAACC,SAAS,EAAE,CAAC;QAACZ;MAAD,CAAD;IAAZ;EAAvB,CAAP;AACD,CAlBD;;eAoBeP,sB"}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { Animated } from 'react-native';
|
|
2
|
+
declare type Params = Omit<Animated.TimingAnimationConfig, 'useNativeDriver' | 'toValue'> & {
|
|
3
|
+
onFadeInFinished?: () => void;
|
|
4
|
+
onFadeOutFinished?: () => void;
|
|
5
|
+
};
|
|
6
|
+
declare const useUpdateOpacity: (params?: Params) => {
|
|
7
|
+
fadeIn: () => void;
|
|
8
|
+
fadeOut: () => void;
|
|
9
|
+
animatedOpacity: {
|
|
10
|
+
opacity: Animated.Value;
|
|
11
|
+
};
|
|
12
|
+
};
|
|
13
|
+
export default useUpdateOpacity;
|
|
14
|
+
//# sourceMappingURL=use-update-opacity.native.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"use-update-opacity.native.d.ts","sourceRoot":"","sources":["../../src/behaviours/use-update-opacity.native.tsx"],"names":[],"mappings":"AACA,OAAO,EAAC,QAAQ,EAAC,MAAM,cAAc,CAAC;AAEtC,aAAK,MAAM,GAAG,IAAI,CAAC,QAAQ,CAAC,qBAAqB,EAAE,iBAAiB,GAAG,SAAS,CAAC,GAAG;IAClF,gBAAgB,CAAC,EAAE,MAAM,IAAI,CAAC;IAC9B,iBAAiB,CAAC,EAAE,MAAM,IAAI,CAAC;CAChC,CAAC;AAEF,QAAA,MAAM,gBAAgB,YAAY,MAAM;;;;;;CAgCvC,CAAC;AAEF,eAAe,gBAAgB,CAAC"}
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
exports.__esModule = true;
|
|
4
|
+
exports.default = void 0;
|
|
5
|
+
|
|
6
|
+
var _react = require("react");
|
|
7
|
+
|
|
8
|
+
var _reactNative = require("react-native");
|
|
9
|
+
|
|
10
|
+
const _excluded = ["duration", "onFadeInFinished", "onFadeOutFinished"];
|
|
11
|
+
|
|
12
|
+
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
13
|
+
|
|
14
|
+
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
|
15
|
+
|
|
16
|
+
const useUpdateOpacity = (params = {}) => {
|
|
17
|
+
const {
|
|
18
|
+
duration = 750,
|
|
19
|
+
onFadeInFinished,
|
|
20
|
+
onFadeOutFinished
|
|
21
|
+
} = params,
|
|
22
|
+
othersParams = _objectWithoutPropertiesLoose(params, _excluded);
|
|
23
|
+
|
|
24
|
+
const fadeAnim = (0, _react.useRef)(new _reactNative.Animated.Value(0)).current;
|
|
25
|
+
const fadeIn = (0, _react.useCallback)(() => {
|
|
26
|
+
_reactNative.Animated.timing(fadeAnim, _extends({}, othersParams, {
|
|
27
|
+
toValue: 1,
|
|
28
|
+
duration,
|
|
29
|
+
useNativeDriver: true
|
|
30
|
+
})).start(({
|
|
31
|
+
finished
|
|
32
|
+
}) => {
|
|
33
|
+
if (finished) {
|
|
34
|
+
onFadeInFinished?.();
|
|
35
|
+
}
|
|
36
|
+
});
|
|
37
|
+
}, [duration, fadeAnim, onFadeInFinished, othersParams]);
|
|
38
|
+
const fadeOut = (0, _react.useCallback)(() => {
|
|
39
|
+
_reactNative.Animated.timing(fadeAnim, _extends({}, othersParams, {
|
|
40
|
+
toValue: 0,
|
|
41
|
+
duration,
|
|
42
|
+
useNativeDriver: true
|
|
43
|
+
})).start(({
|
|
44
|
+
finished
|
|
45
|
+
}) => {
|
|
46
|
+
if (finished) {
|
|
47
|
+
onFadeOutFinished?.();
|
|
48
|
+
}
|
|
49
|
+
});
|
|
50
|
+
}, [duration, fadeAnim, onFadeOutFinished, othersParams]);
|
|
51
|
+
return {
|
|
52
|
+
fadeIn,
|
|
53
|
+
fadeOut,
|
|
54
|
+
animatedOpacity: {
|
|
55
|
+
opacity: fadeAnim
|
|
56
|
+
}
|
|
57
|
+
};
|
|
58
|
+
};
|
|
59
|
+
|
|
60
|
+
var _default = useUpdateOpacity;
|
|
61
|
+
exports.default = _default;
|
|
62
|
+
//# sourceMappingURL=use-update-opacity.native.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"use-update-opacity.native.js","names":["useUpdateOpacity","params","duration","onFadeInFinished","onFadeOutFinished","othersParams","fadeAnim","useRef","Animated","Value","current","fadeIn","useCallback","timing","toValue","useNativeDriver","start","finished","fadeOut","animatedOpacity","opacity"],"sources":["../../src/behaviours/use-update-opacity.native.tsx"],"sourcesContent":["import {useCallback, useRef} from 'react';\nimport {Animated} from 'react-native';\n\ntype Params = Omit<Animated.TimingAnimationConfig, 'useNativeDriver' | 'toValue'> & {\n onFadeInFinished?: () => void;\n onFadeOutFinished?: () => void;\n};\n\nconst useUpdateOpacity = (params: Params = {}) => {\n const {duration = 750, onFadeInFinished, onFadeOutFinished, ...othersParams} = params;\n\n const fadeAnim = useRef(new Animated.Value(0)).current;\n\n const fadeIn = useCallback(() => {\n Animated.timing(fadeAnim, {\n ...othersParams,\n toValue: 1,\n duration,\n useNativeDriver: true\n }).start(({finished}) => {\n if (finished) {\n onFadeInFinished?.();\n }\n });\n }, [duration, fadeAnim, onFadeInFinished, othersParams]);\n\n const fadeOut = useCallback(() => {\n Animated.timing(fadeAnim, {\n ...othersParams,\n toValue: 0,\n duration,\n useNativeDriver: true\n }).start(({finished}) => {\n if (finished) {\n onFadeOutFinished?.();\n }\n });\n }, [duration, fadeAnim, onFadeOutFinished, othersParams]);\n\n return {fadeIn, fadeOut, animatedOpacity: {opacity: fadeAnim}};\n};\n\nexport default useUpdateOpacity;\n"],"mappings":";;;;;AAAA;;AACA;;;;;;;;AAOA,MAAMA,gBAAgB,GAAG,CAACC,MAAc,GAAG,EAAlB,KAAyB;EAChD,MAAM;IAACC,QAAQ,GAAG,GAAZ;IAAiBC,gBAAjB;IAAmCC;EAAnC,IAAyEH,MAA/E;EAAA,MAA+DI,YAA/D,iCAA+EJ,MAA/E;;EAEA,MAAMK,QAAQ,GAAG,IAAAC,aAAA,EAAO,IAAIC,qBAAA,CAASC,KAAb,CAAmB,CAAnB,CAAP,EAA8BC,OAA/C;EAEA,MAAMC,MAAM,GAAG,IAAAC,kBAAA,EAAY,MAAM;IAC/BJ,qBAAA,CAASK,MAAT,CAAgBP,QAAhB,eACKD,YADL;MAEES,OAAO,EAAE,CAFX;MAGEZ,QAHF;MAIEa,eAAe,EAAE;IAJnB,IAKGC,KALH,CAKS,CAAC;MAACC;IAAD,CAAD,KAAgB;MACvB,IAAIA,QAAJ,EAAc;QACZd,gBAAgB;MACjB;IACF,CATD;EAUD,CAXc,EAWZ,CAACD,QAAD,EAAWI,QAAX,EAAqBH,gBAArB,EAAuCE,YAAvC,CAXY,CAAf;EAaA,MAAMa,OAAO,GAAG,IAAAN,kBAAA,EAAY,MAAM;IAChCJ,qBAAA,CAASK,MAAT,CAAgBP,QAAhB,eACKD,YADL;MAEES,OAAO,EAAE,CAFX;MAGEZ,QAHF;MAIEa,eAAe,EAAE;IAJnB,IAKGC,KALH,CAKS,CAAC;MAACC;IAAD,CAAD,KAAgB;MACvB,IAAIA,QAAJ,EAAc;QACZb,iBAAiB;MAClB;IACF,CATD;EAUD,CAXe,EAWb,CAACF,QAAD,EAAWI,QAAX,EAAqBF,iBAArB,EAAwCC,YAAxC,CAXa,CAAhB;EAaA,OAAO;IAACM,MAAD;IAASO,OAAT;IAAkBC,eAAe,EAAE;MAACC,OAAO,EAAEd;IAAV;EAAnC,CAAP;AACD,CAhCD;;eAkCeN,gB"}
|
|
@@ -91,13 +91,13 @@ const CardCongrats = ({
|
|
|
91
91
|
style: styleSheet.card
|
|
92
92
|
}, /*#__PURE__*/_react.default.createElement(_reactNative.View, {
|
|
93
93
|
style: styleSheet.animation
|
|
94
|
-
}, /*#__PURE__*/_react.default.createElement(_lottieReactNative.default, {
|
|
94
|
+
}, animationUri ? /*#__PURE__*/_react.default.createElement(_lottieReactNative.default, {
|
|
95
95
|
source: {
|
|
96
96
|
uri: animationUri
|
|
97
97
|
},
|
|
98
98
|
autoPlay: true,
|
|
99
99
|
loop: false
|
|
100
|
-
})), /*#__PURE__*/_react.default.createElement(_reactNative.Text, {
|
|
100
|
+
}) : null), /*#__PURE__*/_react.default.createElement(_reactNative.Text, {
|
|
101
101
|
style: styleSheet.cardTitle
|
|
102
102
|
}, text), /*#__PURE__*/_react.default.createElement(_reactNative.View, {
|
|
103
103
|
style: [styleSheet.reward, {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.native.js","names":["createStyleSheet","theme","StyleSheet","create","animation","marginBottom","width","height","card","alignItems","paddingTop","paddingBottom","borderRadius","margin","BOX_STYLE","backgroundColor","colors","white","cardTitle","fontWeight","fontSize","lineHeight","color","text","primary","reward","rewardText","marginHorizontal","iconBig","iconSmall","CardCongrats","animationUri","Icon","value","iconColor","textColor","direction","useTemplateContext","styleSheet","setStylesheet","useState","useEffect","_stylesheet","uri","flexDirection"],"sources":["../../../src/molecule/card-congrats/index.native.tsx"],"sourcesContent":["import React, {useEffect, useState} from 'react';\nimport {StyleSheet, Text, TextStyle, View, ViewStyle} from 'react-native';\nimport LottieView from 'lottie-react-native';\nimport {useTemplateContext} from '../../template/app-review/template-context';\nimport {Theme} from '../../variables/theme.native';\nimport {BOX_STYLE} from '../../variables/shadow';\nimport {CardCongratsProps} from './types';\n\ntype StyleSheetType = {\n animation: ViewStyle;\n card: ViewStyle;\n cardTitle: TextStyle;\n iconBig: ViewStyle;\n iconSmall: ViewStyle;\n reward: ViewStyle;\n rewardText: TextStyle;\n};\n\nconst createStyleSheet = (theme: Theme): StyleSheetType =>\n StyleSheet.create({\n animation: {\n marginBottom: 12,\n width: 132,\n height: 132\n },\n // eslint-disable-next-line @coorpacademy/coorpacademy/no-overwriting-spread\n card: {\n alignItems: 'center',\n paddingTop: 32,\n paddingBottom: 24,\n borderRadius: 24,\n margin: 10,\n width: 280,\n height: 317,\n ...BOX_STYLE,\n backgroundColor: theme.colors.white\n },\n cardTitle: {\n fontWeight: '400',\n fontSize: 32,\n lineHeight: 40,\n color: theme.colors.text.primary\n },\n reward: {\n alignItems: 'center'\n },\n rewardText: {\n fontWeight: '700',\n fontSize: 64,\n lineHeight: 77,\n marginHorizontal: 10\n },\n iconBig: {\n width: 70,\n height: 70\n },\n iconSmall: {\n width: 53,\n height: 53\n }\n });\n\nconst CardCongrats = ({\n animationUri,\n Icon,\n value,\n text,\n iconColor,\n textColor,\n direction\n}: CardCongratsProps) => {\n const {theme} = useTemplateContext();\n\n const [styleSheet, setStylesheet] = useState<StyleSheetType | null>(null);\n\n useEffect(() => {\n const _stylesheet = createStyleSheet(theme);\n setStylesheet(_stylesheet);\n }, [theme]);\n\n if (!styleSheet) {\n return null;\n }\n\n return (\n <View style={styleSheet.card}>\n <View style={styleSheet.animation}>\n <LottieView source={{uri: animationUri}} autoPlay loop={false}
|
|
1
|
+
{"version":3,"file":"index.native.js","names":["createStyleSheet","theme","StyleSheet","create","animation","marginBottom","width","height","card","alignItems","paddingTop","paddingBottom","borderRadius","margin","BOX_STYLE","backgroundColor","colors","white","cardTitle","fontWeight","fontSize","lineHeight","color","text","primary","reward","rewardText","marginHorizontal","iconBig","iconSmall","CardCongrats","animationUri","Icon","value","iconColor","textColor","direction","useTemplateContext","styleSheet","setStylesheet","useState","useEffect","_stylesheet","uri","flexDirection"],"sources":["../../../src/molecule/card-congrats/index.native.tsx"],"sourcesContent":["import React, {useEffect, useState} from 'react';\nimport {StyleSheet, Text, TextStyle, View, ViewStyle} from 'react-native';\nimport LottieView from 'lottie-react-native';\nimport {useTemplateContext} from '../../template/app-review/template-context';\nimport {Theme} from '../../variables/theme.native';\nimport {BOX_STYLE} from '../../variables/shadow';\nimport {CardCongratsProps} from './types';\n\ntype StyleSheetType = {\n animation: ViewStyle;\n card: ViewStyle;\n cardTitle: TextStyle;\n iconBig: ViewStyle;\n iconSmall: ViewStyle;\n reward: ViewStyle;\n rewardText: TextStyle;\n};\n\nconst createStyleSheet = (theme: Theme): StyleSheetType =>\n StyleSheet.create({\n animation: {\n marginBottom: 12,\n width: 132,\n height: 132\n },\n // eslint-disable-next-line @coorpacademy/coorpacademy/no-overwriting-spread\n card: {\n alignItems: 'center',\n paddingTop: 32,\n paddingBottom: 24,\n borderRadius: 24,\n margin: 10,\n width: 280,\n height: 317,\n ...BOX_STYLE,\n backgroundColor: theme.colors.white\n },\n cardTitle: {\n fontWeight: '400',\n fontSize: 32,\n lineHeight: 40,\n color: theme.colors.text.primary\n },\n reward: {\n alignItems: 'center'\n },\n rewardText: {\n fontWeight: '700',\n fontSize: 64,\n lineHeight: 77,\n marginHorizontal: 10\n },\n iconBig: {\n width: 70,\n height: 70\n },\n iconSmall: {\n width: 53,\n height: 53\n }\n });\n\nconst CardCongrats = ({\n animationUri,\n Icon,\n value,\n text,\n iconColor,\n textColor,\n direction\n}: CardCongratsProps) => {\n const {theme} = useTemplateContext();\n\n const [styleSheet, setStylesheet] = useState<StyleSheetType | null>(null);\n\n useEffect(() => {\n const _stylesheet = createStyleSheet(theme);\n setStylesheet(_stylesheet);\n }, [theme]);\n\n if (!styleSheet) {\n return null;\n }\n\n return (\n <View style={styleSheet.card}>\n <View style={styleSheet.animation}>\n {animationUri ? <LottieView source={{uri: animationUri}} autoPlay loop={false} /> : null}\n </View>\n <Text style={styleSheet.cardTitle}>{text}</Text>\n <View style={[styleSheet.reward, {flexDirection: direction}]}>\n <Text style={[styleSheet.rewardText, {color: textColor}]}>{value}</Text>\n <Icon style={styleSheet.iconSmall} color={iconColor} />\n </View>\n </View>\n );\n};\n\nexport default CardCongrats;\n"],"mappings":";;;;;AAAA;;AACA;;AACA;;AACA;;AAEA;;;;;;;;;;AAaA,MAAMA,gBAAgB,GAAIC,KAAD,IACvBC,uBAAA,CAAWC,MAAX,CAAkB;EAChBC,SAAS,EAAE;IACTC,YAAY,EAAE,EADL;IAETC,KAAK,EAAE,GAFE;IAGTC,MAAM,EAAE;EAHC,CADK;EAMhB;EACAC,IAAI;IACFC,UAAU,EAAE,QADV;IAEFC,UAAU,EAAE,EAFV;IAGFC,aAAa,EAAE,EAHb;IAIFC,YAAY,EAAE,EAJZ;IAKFC,MAAM,EAAE,EALN;IAMFP,KAAK,EAAE,GANL;IAOFC,MAAM,EAA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Y,gBAAG,6BAAC,0BAAD;IAAY,MAAM,EAAE;MAACY,GAAG,EAAEZ;IAAN,CAApB;IAAyC,QAAQ,MAAjD;IAAkD,IAAI,EAAE;EAAxD,EAAH,GAAuE,IADtF,CADF,eAIE,6BAAC,iBAAD;IAAM,KAAK,EAAEO,UAAU,CAACpB;EAAxB,GAAoCK,IAApC,CAJF,eAKE,6BAAC,iBAAD;IAAM,KAAK,EAAE,CAACe,UAAU,CAACb,MAAZ,EAAoB;MAACmB,aAAa,EAAER;IAAhB,CAApB;EAAb,gBACE,6BAAC,iBAAD;IAAM,KAAK,EAAE,CAACE,UAAU,CAACZ,UAAZ,EAAwB;MAACJ,KAAK,EAAEa;IAAR,CAAxB;EAAb,GAA2DF,KAA3D,CADF,eAEE,6BAAC,IAAD;IAAM,KAAK,EAAEK,UAAU,CAACT,SAAxB;IAAmC,KAAK,EAAEK;EAA1C,EAFF,CALF,CADF;AAYD,CAlCD;;eAoCeJ,Y"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/molecule/card-congrats/types.ts"],"names":[],"mappings":";AAAA,OAAO,EAAC,UAAU,EAAE,SAAS,EAAC,MAAM,cAAc,CAAC;AAEnD,oBAAY,iBAAiB,GAAG;IAC9B,YAAY,EAAE,MAAM,CAAC;
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/molecule/card-congrats/types.ts"],"names":[],"mappings":";AAAA,OAAO,EAAC,UAAU,EAAE,SAAS,EAAC,MAAM,cAAc,CAAC;AAEnD,oBAAY,iBAAiB,GAAG;IAC9B,YAAY,EAAE,MAAM,GAAG,IAAI,CAAC;IAC5B,IAAI,EAAE,KAAK,CAAC,EAAE,CAAC;QAAC,KAAK,EAAE,SAAS,CAAC;QAAC,KAAK,EAAE,UAAU,CAAA;KAAC,CAAC,CAAC;IACtD,KAAK,EAAE,MAAM,CAAC;IACd,IAAI,EAAE,MAAM,CAAC;IACb,SAAS,EAAE,UAAU,CAAC;IACtB,SAAS,EAAE,UAAU,CAAC;IACtB,SAAS,EAAE,SAAS,CAAC,eAAe,CAAC,CAAC;CACvC,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.js","names":[],"sources":["../../../src/molecule/card-congrats/types.ts"],"sourcesContent":["import {ColorValue, ViewStyle} from 'react-native';\n\nexport type CardCongratsProps = {\n animationUri: string;\n Icon: React.FC<{style: ViewStyle; color: ColorValue}>;\n value: string;\n text: string;\n iconColor: ColorValue;\n textColor: ColorValue;\n direction: ViewStyle['flexDirection'];\n};\n"],"mappings":""}
|
|
1
|
+
{"version":3,"file":"types.js","names":[],"sources":["../../../src/molecule/card-congrats/types.ts"],"sourcesContent":["import {ColorValue, ViewStyle} from 'react-native';\n\nexport type CardCongratsProps = {\n animationUri: string | null;\n Icon: React.FC<{style: ViewStyle; color: ColorValue}>;\n value: string;\n text: string;\n iconColor: ColorValue;\n textColor: ColorValue;\n direction: ViewStyle['flexDirection'];\n};\n"],"mappings":""}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.native.d.ts","sourceRoot":"","sources":["../../../src/molecule/review-correction-popin/index.native.tsx"],"names":[],"mappings":";
|
|
1
|
+
{"version":3,"file":"index.native.d.ts","sourceRoot":"","sources":["../../../src/molecule/review-correction-popin/index.native.tsx"],"names":[],"mappings":";AAaA,OAAO,EAAgC,0BAA0B,EAAC,MAAM,cAAc,CAAC;AAyPvF,QAAA,MAAM,qBAAqB,kDAMxB,0BAA0B,uBAiD5B,CAAC;AAEF,eAAe,qBAAqB,CAAC"}
|
|
@@ -17,6 +17,8 @@ var _index3 = _interopRequireDefault(require("../../hoc/touchable/index.native")
|
|
|
17
17
|
|
|
18
18
|
var _templateContext = require("../../template/app-review/template-context");
|
|
19
19
|
|
|
20
|
+
var _useUpdateOpacity = _interopRequireDefault(require("../../behaviours/use-update-opacity.native"));
|
|
21
|
+
|
|
20
22
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
21
23
|
|
|
22
24
|
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
@@ -71,8 +73,7 @@ const createStyleSheet = (theme, type) => _reactNative.StyleSheet.create({
|
|
|
71
73
|
fontWeight: '600',
|
|
72
74
|
lineHeight: 24,
|
|
73
75
|
marginLeft: 12,
|
|
74
|
-
textTransform: 'uppercase'
|
|
75
|
-
wordBreak: 'break-word'
|
|
76
|
+
textTransform: 'uppercase'
|
|
76
77
|
},
|
|
77
78
|
feedbackSection: {
|
|
78
79
|
marginVertical: theme.spacing.medium
|
|
@@ -89,8 +90,7 @@ const createStyleSheet = (theme, type) => _reactNative.StyleSheet.create({
|
|
|
89
90
|
color: theme.colors.white,
|
|
90
91
|
fontSize: 14,
|
|
91
92
|
fontWeight: theme.fontWeight.extraBold,
|
|
92
|
-
lineHeight: 17
|
|
93
|
-
wordBreak: 'break-word'
|
|
93
|
+
lineHeight: 17
|
|
94
94
|
},
|
|
95
95
|
htmlInfoMessage: {
|
|
96
96
|
color: theme.colors.white,
|
|
@@ -198,23 +198,13 @@ const KlfButton = ({
|
|
|
198
198
|
styleSheet
|
|
199
199
|
}) => {
|
|
200
200
|
const [displayTooltip, setDisplayTooltip] = (0, _react.useState)(false);
|
|
201
|
-
const
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
}).start();
|
|
209
|
-
}, [fadeAnim]);
|
|
210
|
-
const fadeOut = (0, _react.useCallback)(() => {
|
|
211
|
-
_reactNative.Animated.timing(fadeAnim, {
|
|
212
|
-
toValue: 0,
|
|
213
|
-
duration: 500,
|
|
214
|
-
easing: _reactNative.Easing.bezier(0.25, 1, 0.5, 1),
|
|
215
|
-
useNativeDriver: true
|
|
216
|
-
}).start();
|
|
217
|
-
}, [fadeAnim]);
|
|
201
|
+
const {
|
|
202
|
+
fadeIn,
|
|
203
|
+
fadeOut,
|
|
204
|
+
animatedOpacity
|
|
205
|
+
} = (0, _useUpdateOpacity.default)({
|
|
206
|
+
easing: _reactNative.Easing.bezier(0.25, 1, 0.5, 1)
|
|
207
|
+
});
|
|
218
208
|
const handlePressKey = (0, _react.useCallback)(() => {
|
|
219
209
|
setDisplayTooltip(!displayTooltip);
|
|
220
210
|
!displayTooltip ? fadeIn() : fadeOut();
|
|
@@ -237,9 +227,7 @@ const KlfButton = ({
|
|
|
237
227
|
return /*#__PURE__*/_react.default.createElement(_reactNative.View, {
|
|
238
228
|
style: containerButtonKlf
|
|
239
229
|
}, /*#__PURE__*/_react.default.createElement(_reactNative.Animated.View, {
|
|
240
|
-
style: [containerTooltip,
|
|
241
|
-
opacity: fadeAnim
|
|
242
|
-
}]
|
|
230
|
+
style: [containerTooltip, animatedOpacity]
|
|
243
231
|
}, /*#__PURE__*/_react.default.createElement(_index3.default, {
|
|
244
232
|
style: buttonTooltip,
|
|
245
233
|
accessibilityLabel: `aria-label-tooltip`,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.native.js","names":["createStyleSheet","theme","type","StyleSheet","create","wrapper","height","color","colors","white","display","popin","padding","spacing","medium","borderRadius","flexDirection","alignItems","backgroundColor","negative","positive","shadowColor","shadowOpacity","shadowOffset","width","shadowRadius","elevation","correctionSection","iconCircle","justifyContent","opacity","icon","resultLabel","fontSize","fontWeight","lineHeight","marginLeft","textTransform","wordBreak","feedbackSection","marginVertical","labelContainer","alignSelf","paddingHorizontal","tiny","paddingVertical","micro","marginBottom","label","extraBold","htmlInfoMessage","button","base","small","buttonText","cta","bold","textAlign","containerButtonKlf","buttonKlf","buttonKlfActive","buttonKlfText","iconKey","marginRight","containerTooltip","zIndex","position","black","buttonTooltip","bottom","right","htmlTooltipText","text","primary","triangleTooltip","borderStyle","borderLeftWidth","borderRightWidth","borderBottomWidth","borderTopWidth","borderLeftColor","borderTopColor","borderRightColor","borderBottomColor","transform","rotate","left","top","KlfButton","klf","styleSheet","displayTooltip","setDisplayTooltip","useState","fadeAnim","useRef","Animated","Value","current","fadeIn","useCallback","timing","toValue","duration","easing","Easing","bezier","useNativeDriver","start","fadeOut","handlePressKey","tooltip","ICONS","RightIcon","wrong","WrongIcon","ReviewCorrectionPopin","information","next","templateContext","useTemplateContext","setStylesheet","handlePressNext","onClick","Icon","useEffect","_stylesheet","message"],"sources":["../../../src/molecule/review-correction-popin/index.native.tsx"],"sourcesContent":["import React, {useCallback, useEffect, useRef, useState} from 'react';\nimport {Animated, Easing, TextStyle, StyleSheet, View, ViewStyle} from 'react-native';\nimport {\n NovaCompositionCoorpacademyCheck as RightIcon,\n NovaSolidStatusClose as WrongIcon,\n NovaLineLoginKey1 as KlfIcon\n} from '@coorpacademy/nova-icons';\nimport Html from '../../atom/html/index.native';\nimport {Theme} from '../../variables/theme.native';\nimport Text from '../../atom/text/index.native';\nimport Touchable from '../../hoc/touchable/index.native';\nimport {useTemplateContext} from '../../template/app-review/template-context';\nimport {ReviewCorrectionPopinKLFProps, ReviewCorrectionPopinProps} from './prop-types';\n\ninterface StyleSheetType {\n wrapper: ViewStyle;\n popin: ViewStyle;\n correctionSection: ViewStyle;\n iconCircle: ViewStyle;\n icon: ViewStyle;\n resultLabel: TextStyle;\n feedbackSection: ViewStyle;\n labelContainer: ViewStyle;\n label: TextStyle;\n htmlInfoMessage: TextStyle;\n button: ViewStyle;\n buttonText: TextStyle;\n buttonKlf: ViewStyle;\n buttonKlfActive: TextStyle;\n buttonKlfText: TextStyle;\n iconKey: ViewStyle;\n containerTooltip: ViewStyle;\n buttonTooltip: ViewStyle;\n containerButtonKlf: ViewStyle;\n triangleTooltip: ViewStyle;\n htmlTooltipText: TextStyle;\n}\n\nconst createStyleSheet = (theme: Theme, type: string): StyleSheetType =>\n StyleSheet.create({\n wrapper: {\n height: 'auto',\n color: theme.colors.white,\n display: 'flex'\n },\n popin: {\n padding: theme.spacing.medium,\n borderRadius: 16,\n display: 'flex',\n flexDirection: 'column',\n alignItems: 'flex-start',\n backgroundColor: type === 'wrong' ? theme.colors.negative : theme.colors.positive,\n shadowColor: type === 'wrong' ? theme.colors.negative : theme.colors.positive,\n shadowOpacity: 0.5,\n shadowOffset: {width: 0, height: 0},\n shadowRadius: 15,\n elevation: 4\n },\n correctionSection: {\n flexDirection: 'row',\n alignItems: 'center',\n width: '80%'\n },\n iconCircle: {\n width: 60,\n height: 60,\n alignItems: 'center',\n justifyContent: 'center',\n backgroundColor: theme.colors.white,\n opacity: 0.7,\n borderRadius: 50\n },\n icon: {\n height: 30,\n width: 30\n },\n resultLabel: {\n color: theme.colors.white,\n fontSize: 24,\n fontWeight: '600',\n lineHeight: 24,\n marginLeft: 12,\n textTransform: 'uppercase',\n wordBreak: 'break-word'\n },\n feedbackSection: {\n marginVertical: theme.spacing.medium\n },\n labelContainer: {\n alignSelf: 'flex-start',\n backgroundColor: 'rgba(255, 255, 255, 0.3)',\n borderRadius: 56,\n paddingHorizontal: theme.spacing.tiny,\n paddingVertical: theme.spacing.micro,\n marginBottom: 8\n },\n label: {\n color: theme.colors.white,\n fontSize: 14,\n fontWeight: theme.fontWeight.extraBold,\n lineHeight: 17,\n wordBreak: 'break-word'\n },\n htmlInfoMessage: {\n color: theme.colors.white,\n fontSize: 16,\n fontWeight: '600',\n lineHeight: 19\n },\n button: {\n alignSelf: 'stretch',\n backgroundColor: theme.colors.white,\n borderRadius: 7,\n paddingHorizontal: theme.spacing.base,\n paddingVertical: theme.spacing.small\n },\n buttonText: {\n color: theme.colors.cta,\n fontSize: 14,\n fontWeight: theme.fontWeight.bold,\n lineHeight: 20,\n textAlign: 'center'\n },\n containerButtonKlf: {\n width: '100%'\n },\n buttonKlf: {\n flexDirection: 'row',\n alignItems: 'center',\n justifyContent: 'center',\n backgroundColor: 'rgba(255, 255, 255, 0.1)',\n borderRadius: 7,\n paddingHorizontal: theme.spacing.base,\n paddingVertical: theme.spacing.small,\n marginBottom: theme.spacing.tiny\n },\n buttonKlfActive: {\n backgroundColor:\n 'linear-gradient(0deg, rgba(0, 0, 0, 0.25), rgba(0, 0, 0, 0.25)), rgba(255, 255, 255, 0.1)'\n },\n buttonKlfText: {\n color: 'white',\n fontSize: 14,\n fontWeight: theme.fontWeight.bold,\n lineHeight: 20,\n textAlign: 'center'\n },\n iconKey: {\n width: 12,\n height: 12,\n marginRight: theme.spacing.tiny\n },\n containerTooltip: {\n zIndex: 30,\n position: 'relative',\n shadowColor: theme.colors.black,\n shadowOpacity: 0.3,\n shadowOffset: {width: 0, height: 0},\n shadowRadius: 8\n },\n buttonTooltip: {\n flexDirection: 'column',\n justifyContent: 'center',\n backgroundColor: theme.colors.white,\n borderRadius: 15,\n padding: theme.spacing.small,\n width: '112%',\n position: 'absolute',\n bottom: 4,\n right: -15,\n zIndex: 20\n },\n htmlTooltipText: {\n color: theme.colors.text.primary,\n fontSize: 16,\n fontWeight: '600',\n lineHeight: 22,\n textAlign: 'center'\n },\n triangleTooltip: {\n width: 0,\n height: 0,\n backgroundColor: 'transparent',\n borderStyle: 'solid',\n borderLeftWidth: 13,\n borderRightWidth: 13,\n borderBottomWidth: 13,\n borderTopWidth: 13,\n borderLeftColor: 'transparent',\n borderTopColor: 'transparent',\n borderRightColor: theme.colors.white,\n borderBottomColor: theme.colors.white,\n transform: [{rotate: '45deg'}],\n position: 'absolute',\n left: 110,\n top: -20,\n borderRadius: 4\n }\n });\n\nconst KlfButton = ({\n klf,\n styleSheet\n}: {\n klf: ReviewCorrectionPopinKLFProps;\n styleSheet: StyleSheetType;\n}) => {\n const [displayTooltip, setDisplayTooltip] = useState(false);\n\n const fadeAnim = useRef(new Animated.Value(0)).current;\n\n const fadeIn = useCallback(() => {\n Animated.timing(fadeAnim, {\n toValue: 1,\n duration: 1000,\n easing: Easing.bezier(0.25, 1, 0.5, 1),\n useNativeDriver: true\n }).start();\n }, [fadeAnim]);\n\n const fadeOut = useCallback(() => {\n Animated.timing(fadeAnim, {\n toValue: 0,\n duration: 500,\n easing: Easing.bezier(0.25, 1, 0.5, 1),\n useNativeDriver: true\n }).start();\n }, [fadeAnim]);\n\n const handlePressKey = useCallback(() => {\n setDisplayTooltip(!displayTooltip);\n !displayTooltip ? fadeIn() : fadeOut();\n }, [displayTooltip, fadeIn, fadeOut]);\n\n const {\n buttonKlf,\n buttonKlfActive,\n buttonKlfText,\n containerButtonKlf,\n containerTooltip,\n buttonTooltip,\n htmlTooltipText,\n iconKey,\n triangleTooltip\n } = styleSheet;\n\n const {label, tooltip} = klf;\n\n return (\n <View style={containerButtonKlf}>\n <Animated.View style={[containerTooltip, {opacity: fadeAnim}]}>\n <Touchable\n style={buttonTooltip}\n accessibilityLabel={`aria-label-tooltip`}\n isHighlight\n onPress={handlePressKey}\n testID=\"button-tooltip\"\n >\n <Html style={htmlTooltipText}>{tooltip}</Html>\n </Touchable>\n <View style={triangleTooltip} />\n </Animated.View>\n <Touchable\n style={displayTooltip ? {...buttonKlf, ...buttonKlfActive} : buttonKlf}\n accessibilityLabel={`aria-label-${label}`}\n onPress={handlePressKey}\n testID=\"button-klf\"\n >\n <KlfIcon style={iconKey} color=\"white\" />\n <Text style={buttonKlfText}>{label}</Text>\n </Touchable>\n </View>\n );\n};\n\nconst ICONS = {\n right: RightIcon,\n wrong: WrongIcon\n};\n\nconst ReviewCorrectionPopin = ({\n information,\n klf,\n next,\n type,\n resultLabel\n}: ReviewCorrectionPopinProps) => {\n const templateContext = useTemplateContext();\n const [styleSheet, setStylesheet] = useState<StyleSheetType | null>(null);\n const {theme} = templateContext;\n const handlePressNext = next.onClick;\n\n const Icon = ICONS[type];\n\n useEffect(() => {\n const _stylesheet = createStyleSheet(theme, type);\n setStylesheet(_stylesheet);\n }, [theme, type]);\n\n if (!styleSheet) {\n return null;\n }\n\n return (\n <View style={styleSheet.wrapper}>\n <View style={styleSheet.popin}>\n <View style={styleSheet.correctionSection}>\n <View style={styleSheet.iconCircle}>\n <Icon\n style={styleSheet.icon}\n color={type === 'wrong' ? theme.colors.negative : theme.colors.positive}\n />\n </View>\n <Text style={styleSheet.resultLabel}>{resultLabel}</Text>\n </View>\n <View style={styleSheet.feedbackSection} accessibilityLabel=\"answer-information\">\n <View style={styleSheet.labelContainer} needsOffscreenAlphaCompositing>\n <Text accessibilityLabel={information.label} style={styleSheet.label}>\n {information.label}\n </Text>\n </View>\n <Html style={styleSheet.htmlInfoMessage}>{information.message}</Html>\n </View>\n {klf && type === 'wrong' ? <KlfButton styleSheet={styleSheet} klf={klf} /> : null}\n <Touchable\n style={styleSheet.button}\n onPress={handlePressNext}\n accessibilityLabel={next['aria-label']}\n testID={next['data-name']}\n >\n <Text style={styleSheet.buttonText}>{next.label}</Text>\n </Touchable>\n </View>\n </View>\n );\n};\n\nexport default ReviewCorrectionPopin;\n"],"mappings":";;;;;AAAA;;AACA;;AACA;;AAKA;;AAEA;;AACA;;AACA;;;;;;;;;;AA2BA,MAAMA,gBAAgB,GAAG,CAACC,KAAD,EAAeC,IAAf,KACvBC,uBAAA,CAAWC,MAAX,CAAkB;EAChBC,OAAO,EAAE;IACPC,MAAM,EAAE,MADD;IAEPC,KAAK,EAAEN,KAAK,CAACO,MAAN,CAAaC,KAFb;IAGPC,OAAO,EAAE;EAHF,CADO;EAMhBC,KAAK,EAAE;IACLC,OAAO,EAAEX,KAAK,CAACY,OAAN,CAAcC,MADlB;IAELC,YAAY,EAAE,EAFT;IAGLL,OAAO,EAAE,MAHJ;IAILM,aAAa,EAAE,QAJV;IAKLC,UAAU,EAAE,YALP;IAMLC,eAAe,EAAEhB,IAAI,KAAK,OAAT,GAAmBD,KAAK,CAACO,MAAN,CAAaW,QAAhC,GAA2ClB,KAAK,CAACO,MAAN,CAAaY,QANpE;IAOLC,WAAW,EAAEnB,IAAI,KAAK,OAAT,GAAmBD,KAAK,CAACO,MAAN,CAAaW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,KAAK,EAAE7B,IAAI,KAAK,OAAT,GAAmBD,KAAK,CAACO,MAAN,CAAaW,QAAhC,GAA2ClB,KAAK,CAACO,MAAN,CAAaY;EAFjE,EADF,CADF,eAOE,6BAAC,eAAD;IAAM,KAAK,EAAEsE,UAAU,CAAC1D;EAAxB,GAAsCA,WAAtC,CAPF,CADF,eAUE,6BAAC,iBAAD;IAAM,KAAK,EAAE0D,UAAU,CAACnD,eAAxB;IAAyC,kBAAkB,EAAC;EAA5D,gBACE,6BAAC,iBAAD;IAAM,KAAK,EAAEmD,UAAU,CAACjD,cAAxB;IAAwC,8BAA8B;EAAtE,gBACE,6BAAC,eAAD;IAAM,kBAAkB,EAAE4E,WAAW,CAACrE,KAAtC;IAA6C,KAAK,EAAE0C,UAAU,CAAC1C;EAA/D,GACGqE,WAAW,CAACrE,KADf,CADF,CADF,eAME,6BAAC,cAAD;IAAM,KAAK,EAAE0C,UAAU,CAACxC;EAAxB,GAA0CmE,WAAW,CAACU,OAAtD,CANF,CAVF,EAkBGtC,GAAG,IAAIvF,IAAI,KAAK,OAAhB,gBAA0B,6BAAC,SAAD;IAAW,UAAU,EAAEwF,UAAvB;IAAmC,GAAG,EAAED;EAAxC,EAA1B,GAA4E,IAlB/E,eAmBE,6BAAC,eAAD;IACE,KAAK,EAAEC,UAAU,CAACvC,MADpB;IAEE,OAAO,EAAEuE,eAFX;IAGE,kBAAkB,EAAEJ,IAAI,CAAC,YAAD,CAH1B;IAIE,MAAM,EAAEA,IAAI,CAAC,WAAD;EAJd,gBAME,6BAAC,eAAD;IAAM,KAAK,EAAE5B,UAAU,CAACpC;EAAxB,GAAqCgE,IAAI,CAACtE,KAA1C,CANF,CAnBF,CADF,CADF;AAgCD,CAvDD;;eAyDeoE,qB"}
|
|
1
|
+
{"version":3,"file":"index.native.js","names":["createStyleSheet","theme","type","StyleSheet","create","wrapper","height","color","colors","white","display","popin","padding","spacing","medium","borderRadius","flexDirection","alignItems","backgroundColor","negative","positive","shadowColor","shadowOpacity","shadowOffset","width","shadowRadius","elevation","correctionSection","iconCircle","justifyContent","opacity","icon","resultLabel","fontSize","fontWeight","lineHeight","marginLeft","textTransform","feedbackSection","marginVertical","labelContainer","alignSelf","paddingHorizontal","tiny","paddingVertical","micro","marginBottom","label","extraBold","htmlInfoMessage","button","base","small","buttonText","cta","bold","textAlign","containerButtonKlf","buttonKlf","buttonKlfActive","buttonKlfText","iconKey","marginRight","containerTooltip","zIndex","position","black","buttonTooltip","bottom","right","htmlTooltipText","text","primary","triangleTooltip","borderStyle","borderLeftWidth","borderRightWidth","borderBottomWidth","borderTopWidth","borderLeftColor","borderTopColor","borderRightColor","borderBottomColor","transform","rotate","left","top","KlfButton","klf","styleSheet","displayTooltip","setDisplayTooltip","useState","fadeIn","fadeOut","animatedOpacity","useUpdateOpacity","easing","Easing","bezier","handlePressKey","useCallback","tooltip","ICONS","RightIcon","wrong","WrongIcon","ReviewCorrectionPopin","information","next","templateContext","useTemplateContext","setStylesheet","handlePressNext","onClick","Icon","useEffect","_stylesheet","message"],"sources":["../../../src/molecule/review-correction-popin/index.native.tsx"],"sourcesContent":["import React, {useCallback, useEffect, useState} from 'react';\nimport {Animated, Easing, TextStyle, StyleSheet, View, ViewStyle} from 'react-native';\nimport {\n NovaCompositionCoorpacademyCheck as RightIcon,\n NovaSolidStatusClose as WrongIcon,\n NovaLineLoginKey1 as KlfIcon\n} from '@coorpacademy/nova-icons';\nimport Html from '../../atom/html/index.native';\nimport {Theme} from '../../variables/theme.native';\nimport Text from '../../atom/text/index.native';\nimport Touchable from '../../hoc/touchable/index.native';\nimport {useTemplateContext} from '../../template/app-review/template-context';\nimport useUpdateOpacity from '../../behaviours/use-update-opacity.native';\nimport {ReviewCorrectionPopinKLFProps, ReviewCorrectionPopinProps} from './prop-types';\n\ninterface StyleSheetType {\n wrapper: ViewStyle;\n popin: ViewStyle;\n correctionSection: ViewStyle;\n iconCircle: ViewStyle;\n icon: ViewStyle;\n resultLabel: TextStyle;\n feedbackSection: ViewStyle;\n labelContainer: ViewStyle;\n label: TextStyle;\n htmlInfoMessage: TextStyle;\n button: ViewStyle;\n buttonText: TextStyle;\n buttonKlf: ViewStyle;\n buttonKlfActive: TextStyle;\n buttonKlfText: TextStyle;\n iconKey: ViewStyle;\n containerTooltip: ViewStyle;\n buttonTooltip: ViewStyle;\n containerButtonKlf: ViewStyle;\n triangleTooltip: ViewStyle;\n htmlTooltipText: TextStyle;\n}\n\nconst createStyleSheet = (theme: Theme, type: string): StyleSheetType =>\n StyleSheet.create({\n wrapper: {\n height: 'auto',\n color: theme.colors.white,\n display: 'flex'\n },\n popin: {\n padding: theme.spacing.medium,\n borderRadius: 16,\n display: 'flex',\n flexDirection: 'column',\n alignItems: 'flex-start',\n backgroundColor: type === 'wrong' ? theme.colors.negative : theme.colors.positive,\n shadowColor: type === 'wrong' ? theme.colors.negative : theme.colors.positive,\n shadowOpacity: 0.5,\n shadowOffset: {width: 0, height: 0},\n shadowRadius: 15,\n elevation: 4\n },\n correctionSection: {\n flexDirection: 'row',\n alignItems: 'center',\n width: '80%'\n },\n iconCircle: {\n width: 60,\n height: 60,\n alignItems: 'center',\n justifyContent: 'center',\n backgroundColor: theme.colors.white,\n opacity: 0.7,\n borderRadius: 50\n },\n icon: {\n height: 30,\n width: 30\n },\n resultLabel: {\n color: theme.colors.white,\n fontSize: 24,\n fontWeight: '600',\n lineHeight: 24,\n marginLeft: 12,\n textTransform: 'uppercase'\n },\n feedbackSection: {\n marginVertical: theme.spacing.medium\n },\n labelContainer: {\n alignSelf: 'flex-start',\n backgroundColor: 'rgba(255, 255, 255, 0.3)',\n borderRadius: 56,\n paddingHorizontal: theme.spacing.tiny,\n paddingVertical: theme.spacing.micro,\n marginBottom: 8\n },\n label: {\n color: theme.colors.white,\n fontSize: 14,\n fontWeight: theme.fontWeight.extraBold,\n lineHeight: 17\n },\n htmlInfoMessage: {\n color: theme.colors.white,\n fontSize: 16,\n fontWeight: '600',\n lineHeight: 19\n },\n button: {\n alignSelf: 'stretch',\n backgroundColor: theme.colors.white,\n borderRadius: 7,\n paddingHorizontal: theme.spacing.base,\n paddingVertical: theme.spacing.small\n },\n buttonText: {\n color: theme.colors.cta,\n fontSize: 14,\n fontWeight: theme.fontWeight.bold,\n lineHeight: 20,\n textAlign: 'center'\n },\n containerButtonKlf: {\n width: '100%'\n },\n buttonKlf: {\n flexDirection: 'row',\n alignItems: 'center',\n justifyContent: 'center',\n backgroundColor: 'rgba(255, 255, 255, 0.1)',\n borderRadius: 7,\n paddingHorizontal: theme.spacing.base,\n paddingVertical: theme.spacing.small,\n marginBottom: theme.spacing.tiny\n },\n buttonKlfActive: {\n backgroundColor:\n 'linear-gradient(0deg, rgba(0, 0, 0, 0.25), rgba(0, 0, 0, 0.25)), rgba(255, 255, 255, 0.1)'\n },\n buttonKlfText: {\n color: 'white',\n fontSize: 14,\n fontWeight: theme.fontWeight.bold,\n lineHeight: 20,\n textAlign: 'center'\n },\n iconKey: {\n width: 12,\n height: 12,\n marginRight: theme.spacing.tiny\n },\n containerTooltip: {\n zIndex: 30,\n position: 'relative',\n shadowColor: theme.colors.black,\n shadowOpacity: 0.3,\n shadowOffset: {width: 0, height: 0},\n shadowRadius: 8\n },\n buttonTooltip: {\n flexDirection: 'column',\n justifyContent: 'center',\n backgroundColor: theme.colors.white,\n borderRadius: 15,\n padding: theme.spacing.small,\n width: '112%',\n position: 'absolute',\n bottom: 4,\n right: -15,\n zIndex: 20\n },\n htmlTooltipText: {\n color: theme.colors.text.primary,\n fontSize: 16,\n fontWeight: '600',\n lineHeight: 22,\n textAlign: 'center'\n },\n triangleTooltip: {\n width: 0,\n height: 0,\n backgroundColor: 'transparent',\n borderStyle: 'solid',\n borderLeftWidth: 13,\n borderRightWidth: 13,\n borderBottomWidth: 13,\n borderTopWidth: 13,\n borderLeftColor: 'transparent',\n borderTopColor: 'transparent',\n borderRightColor: theme.colors.white,\n borderBottomColor: theme.colors.white,\n transform: [{rotate: '45deg'}],\n position: 'absolute',\n left: 110,\n top: -20,\n borderRadius: 4\n }\n });\n\nconst KlfButton = ({\n klf,\n styleSheet\n}: {\n klf: ReviewCorrectionPopinKLFProps;\n styleSheet: StyleSheetType;\n}) => {\n const [displayTooltip, setDisplayTooltip] = useState(false);\n const {fadeIn, fadeOut, animatedOpacity} = useUpdateOpacity({\n easing: Easing.bezier(0.25, 1, 0.5, 1)\n });\n\n const handlePressKey = useCallback(() => {\n setDisplayTooltip(!displayTooltip);\n !displayTooltip ? fadeIn() : fadeOut();\n }, [displayTooltip, fadeIn, fadeOut]);\n\n const {\n buttonKlf,\n buttonKlfActive,\n buttonKlfText,\n containerButtonKlf,\n containerTooltip,\n buttonTooltip,\n htmlTooltipText,\n iconKey,\n triangleTooltip\n } = styleSheet;\n\n const {label, tooltip} = klf;\n\n return (\n <View style={containerButtonKlf}>\n <Animated.View style={[containerTooltip, animatedOpacity]}>\n <Touchable\n style={buttonTooltip}\n accessibilityLabel={`aria-label-tooltip`}\n isHighlight\n onPress={handlePressKey}\n testID=\"button-tooltip\"\n >\n <Html style={htmlTooltipText}>{tooltip}</Html>\n </Touchable>\n <View style={triangleTooltip} />\n </Animated.View>\n <Touchable\n style={displayTooltip ? {...buttonKlf, ...buttonKlfActive} : buttonKlf}\n accessibilityLabel={`aria-label-${label}`}\n onPress={handlePressKey}\n testID=\"button-klf\"\n >\n <KlfIcon style={iconKey} color=\"white\" />\n <Text style={buttonKlfText}>{label}</Text>\n </Touchable>\n </View>\n );\n};\n\nconst ICONS = {\n right: RightIcon,\n wrong: WrongIcon\n};\n\nconst ReviewCorrectionPopin = ({\n information,\n klf,\n next,\n type,\n resultLabel\n}: ReviewCorrectionPopinProps) => {\n const templateContext = useTemplateContext();\n const [styleSheet, setStylesheet] = useState<StyleSheetType | null>(null);\n const {theme} = templateContext;\n const handlePressNext = next.onClick;\n\n const Icon = ICONS[type];\n\n useEffect(() => {\n const _stylesheet = createStyleSheet(theme, type);\n setStylesheet(_stylesheet);\n }, [theme, type]);\n\n if (!styleSheet) {\n return null;\n }\n\n return (\n <View style={styleSheet.wrapper}>\n <View style={styleSheet.popin}>\n <View style={styleSheet.correctionSection}>\n <View style={styleSheet.iconCircle}>\n <Icon\n style={styleSheet.icon}\n color={type === 'wrong' ? theme.colors.negative : theme.colors.positive}\n />\n </View>\n <Text style={styleSheet.resultLabel}>{resultLabel}</Text>\n </View>\n <View style={styleSheet.feedbackSection} accessibilityLabel=\"answer-information\">\n <View style={styleSheet.labelContainer} needsOffscreenAlphaCompositing>\n <Text accessibilityLabel={information.label} style={styleSheet.label}>\n {information.label}\n </Text>\n </View>\n <Html style={styleSheet.htmlInfoMessage}>{information.message}</Html>\n </View>\n {klf && type === 'wrong' ? <KlfButton styleSheet={styleSheet} klf={klf} /> : null}\n <Touchable\n style={styleSheet.button}\n onPress={handlePressNext}\n accessibilityLabel={next['aria-label']}\n testID={next['data-name']}\n >\n <Text style={styleSheet.buttonText}>{next.label}</Text>\n </Touchable>\n </View>\n </View>\n );\n};\n\nexport default ReviewCorrectionPopin;\n"],"mappings":";;;;;AAAA;;AACA;;AACA;;AAKA;;AAEA;;AACA;;AACA;;AACA;;;;;;;;;;AA2BA,MAAMA,gBAAgB,GAAG,CAACC,KAAD,EAAeC,IAAf,KACvBC,uBAAA,CAAWC,MAAX,CAAkB;EAChBC,OAAO,EAAE;IACPC,MAAM,EAAE,MADD;IAEPC,KAAK,EAAEN,KAAK,CAACO,MAAN,CAAaC,KAFb;IAGPC,OAAO,EAAE;EAHF,CADO;EAMhBC,KAAK,EAAE;IACLC,OAAO,EAAEX,KAAK,CAACY,OAAN,CAAcC,MADlB;IAELC,YAAY,EAAE,EAFT;IAGLL,OAAO,EAAE,MAHJ;IAILM,aAAa,EAAE,QAJV;IAKLC,UAAU,EAAE,YALP;IAMLC,eAAe,EAAEhB,IAAI,KAAK,OAAT,GAAmBD,KAAK,CAACO,MAAN,CAAaW,QAAhC,GAA2ClB,KAAK,CAACO,MAAN,CAAaY,QANpE;IAOLC,WAAW,EAAEnB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BG9B,GAAG,IAAItF,IAAI,KAAK,OAAhB,gBAA0B,6BAAC,SAAD;IAAW,UAAU,EAAEuF,UAAvB;IAAmC,GAAG,EAAED;EAAxC,EAA1B,GAA4E,IAlB/E,eAmBE,6BAAC,eAAD;IACE,KAAK,EAAEC,UAAU,CAACvC,MADpB;IAEE,OAAO,EAAE+D,eAFX;IAGE,kBAAkB,EAAEJ,IAAI,CAAC,YAAD,CAH1B;IAIE,MAAM,EAAEA,IAAI,CAAC,WAAD;EAJd,gBAME,6BAAC,eAAD;IAAM,KAAK,EAAEpB,UAAU,CAACpC;EAAxB,GAAqCwD,IAAI,CAAC9D,KAA1C,CANF,CAnBF,CADF,CADF;AAgCD,CAvDD;;eAyDe4D,qB"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/organism/get-the-app/index.js"],"names":[],"mappings":";
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/organism/get-the-app/index.js"],"names":[],"mappings":";AAoIA,kEA+DC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA3ED;;gBAMC"}
|