@kiosinc/commons-rn 0.1.19 → 0.1.21

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.
Files changed (38) hide show
  1. package/lib/commonjs/auth/screens/LoginScreen.js +8 -8
  2. package/lib/commonjs/auth/screens/LoginScreen.js.map +1 -1
  3. package/lib/commonjs/auth/screens/ResetPassword.js +8 -2
  4. package/lib/commonjs/auth/screens/ResetPassword.js.map +1 -1
  5. package/lib/commonjs/auth/screens/SignUp.js +9 -3
  6. package/lib/commonjs/auth/screens/SignUp.js.map +1 -1
  7. package/lib/commonjs/auth/screens/SignUpPassword.js +8 -2
  8. package/lib/commonjs/auth/screens/SignUpPassword.js.map +1 -1
  9. package/lib/commonjs/auth/screens/VerifyPhoneNumber.js +8 -2
  10. package/lib/commonjs/auth/screens/VerifyPhoneNumber.js.map +1 -1
  11. package/lib/commonjs/components/TextInput.js +4 -2
  12. package/lib/commonjs/components/TextInput.js.map +1 -1
  13. package/lib/module/auth/screens/LoginScreen.js +9 -9
  14. package/lib/module/auth/screens/LoginScreen.js.map +1 -1
  15. package/lib/module/auth/screens/ResetPassword.js +9 -3
  16. package/lib/module/auth/screens/ResetPassword.js.map +1 -1
  17. package/lib/module/auth/screens/SignUp.js +10 -4
  18. package/lib/module/auth/screens/SignUp.js.map +1 -1
  19. package/lib/module/auth/screens/SignUpPassword.js +9 -3
  20. package/lib/module/auth/screens/SignUpPassword.js.map +1 -1
  21. package/lib/module/auth/screens/VerifyPhoneNumber.js +9 -3
  22. package/lib/module/auth/screens/VerifyPhoneNumber.js.map +1 -1
  23. package/lib/module/components/TextInput.js +4 -2
  24. package/lib/module/components/TextInput.js.map +1 -1
  25. package/lib/typescript/src/auth/screens/LoginScreen.d.ts.map +1 -1
  26. package/lib/typescript/src/auth/screens/ResetPassword.d.ts.map +1 -1
  27. package/lib/typescript/src/auth/screens/SignUp.d.ts.map +1 -1
  28. package/lib/typescript/src/auth/screens/SignUpPassword.d.ts.map +1 -1
  29. package/lib/typescript/src/auth/screens/VerifyPhoneNumber.d.ts.map +1 -1
  30. package/lib/typescript/src/components/TextInput.d.ts +1 -0
  31. package/lib/typescript/src/components/TextInput.d.ts.map +1 -1
  32. package/package.json +1 -1
  33. package/src/auth/screens/LoginScreen.tsx +85 -91
  34. package/src/auth/screens/ResetPassword.tsx +46 -42
  35. package/src/auth/screens/SignUp.tsx +106 -102
  36. package/src/auth/screens/SignUpPassword.tsx +69 -65
  37. package/src/auth/screens/VerifyPhoneNumber.tsx +56 -52
  38. package/src/components/TextInput.tsx +11 -6
@@ -1,4 +1,4 @@
1
- import { ParentView, Text, View, Button, LinkButton, OtpInputs, KeyboardAvoidingView } from '../../components';
1
+ import { ParentView, Text, View, Button, LinkButton, OtpInputs, KeyboardAvoidingView, Header } from '../../components';
2
2
  import React from 'react';
3
3
  import { useTranslation } from 'react-i18next';
4
4
  import { Controller, useForm } from 'react-hook-form';
@@ -40,8 +40,14 @@ export const VerifyPhoneNumberScreen = ({
40
40
  });
41
41
  };
42
42
  return /*#__PURE__*/React.createElement(ParentView, {
43
- justifyContent: "center",
44
43
  px: "16"
44
+ }, /*#__PURE__*/React.createElement(Header, {
45
+ left: 10,
46
+ position: 'absolute',
47
+ zIndex: '100'
48
+ }), /*#__PURE__*/React.createElement(View, {
49
+ flex: 1,
50
+ justifyContent: 'center'
45
51
  }, /*#__PURE__*/React.createElement(KeyboardAvoidingView, {
46
52
  alignSelf: "center",
47
53
  justifyContent: 'center',
@@ -89,6 +95,6 @@ export const VerifyPhoneNumberScreen = ({
89
95
  onPress: () => {
90
96
  resendCode(params);
91
97
  }
92
- }, t('authentication.resendCode'))));
98
+ }, t('authentication.resendCode')))));
93
99
  };
94
100
  //# sourceMappingURL=VerifyPhoneNumber.js.map
@@ -1 +1 @@
1
- {"version":3,"names":["ParentView","Text","View","Button","LinkButton","OtpInputs","KeyboardAvoidingView","React","useTranslation","Controller","useForm","yupResolver","verificationValidationSchema","useAuthentication","VerifyPhoneNumberScreen","route","params","t","useSignUp","useVerifyPhoneNumber","mutate","signUp","isLoading","isSigningUp","resendCode","isResendingCode","handleSubmit","control","resolver","defaultValues","code","onSubmit","data","createElement","justifyContent","px","alignSelf","width","phone","tablet","alignItems","pb","textAlign","variant","color","render","field","onChange","value","handleChange","numberOfInputs","name","mt","disabled","loading","mode","onPress"],"sourceRoot":"../../../../src","sources":["auth/screens/VerifyPhoneNumber.tsx"],"mappings":"AAAA,SACEA,UAAU,EACVC,IAAI,EACJC,IAAI,EACJC,MAAM,EACNC,UAAU,EACVC,SAAS,EACTC,oBAAoB,QACf,kBAAkB;AAEzB,OAAOC,KAAK,MAAM,OAAO;AACzB,SAASC,cAAc,QAAQ,eAAe;AAC9C,SAASC,UAAU,EAAEC,OAAO,QAAQ,iBAAiB;AACrD,SAASC,WAAW,QAAQ,yBAAyB;AACrD,SAASC,4BAA4B,QAAQ,cAAc;AAC3D,SAASC,iBAAiB,QAAQ,4BAA4B;AAU9D,OAAO,MAAMC,uBAEZ,GAAGA,CAAC;EAAEC;AAAM,CAAC,KAAK;EACjB,MAAMC,MAAM,GAAGD,KAAK,CAACC,MAAM;EAC3B,MAAM;IAAEC;EAAE,CAAC,GAAGT,cAAc,CAAC,CAAC;EAC9B,MAAM;IAAEU,SAAS;IAAEC;EAAqB,CAAC,GAAGN,iBAAiB,CAAC,CAAC;EAE/D,MAAM;IAAEO,MAAM,EAAEC,MAAM;IAAEC,SAAS,EAAEC;EAAY,CAAC,GAAGL,SAAS,CAAC,CAAC;EAC9D,MAAM;IAAEE,MAAM,EAAEI,UAAU;IAAEF,SAAS,EAAEG;EAAgB,CAAC,GACtDN,oBAAoB,CAAC,CAAC;EAExB,MAAM;IAAEO,YAAY;IAAEC;EAAQ,CAAC,GAAGjB,OAAO,CAAW;IAClDkB,QAAQ,EAAEjB,WAAW,CAACC,4BAA4B,CAAC;IACnDiB,aAAa,EAAE;MACbC,IAAI,EAAE;IACR;EACF,CAAC,CAAC;EAEF,MA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IAAI;IACPC,QAAQ,EAAE5B,eAAe,IAAIF,WAAY;IACzC+B,OAAO,EAAE/B,WAAY;IACrBgC,IAAI,EAAC,WAAW;IAChBC,OAAO,EAAE9B,YAAY,CAACK,QAAQ;EAAE,GAE/Bd,CAAC,CAAC,UAAU,CACP,CAAC,eACTV,KAAA,CAAA0B,aAAA,CAAC7B,UAAU;IACTiD,QAAQ,EAAE5B,eAAe,IAAIF,WAAY;IACzC+B,OAAO,EAAE7B,eAAgB;IACzB2B,EAAE,EAAC,IAAI;IACPG,IAAI,EAAC,MAAM;IACXC,OAAO,EAAEA,CAAA,KAAM;MACbhC,UAAU,CAACR,MAAa,CAAC;IAC3B;EAAE,GAEDC,CAAC,CAAC,2BAA2B,CACpB,CACQ,CACZ,CAAC;AAEjB,CAAC"}
1
+ {"version":3,"names":["ParentView","Text","View","Button","LinkButton","OtpInputs","KeyboardAvoidingView","Header","React","useTranslation","Controller","useForm","yupResolver","verificationValidationSchema","useAuthentication","VerifyPhoneNumberScreen","route","params","t","useSignUp","useVerifyPhoneNumber","mutate","signUp","isLoading","isSigningUp","resendCode","isResendingCode","handleSubmit","control","resolver","defaultValues","code","onSubmit","data","createElement","px","left","position","zIndex","flex","justifyContent","alignSelf","width","phone","tablet","alignItems","pb","textAlign","variant","color","render","field","onChange","value","handleChange","numberOfInputs","name","mt","disabled","loading","mode","onPress"],"sourceRoot":"../../../../src","sources":["auth/screens/VerifyPhoneNumber.tsx"],"mappings":"AAAA,SACEA,UAAU,EACVC,IAAI,EACJC,IAAI,EACJC,MAAM,EACNC,UAAU,EACVC,SAAS,EACTC,oBAAoB,EACpBC,MAAM,QACD,kBAAkB;AAEzB,OAAOC,KAAK,MAAM,OAAO;AACzB,SAASC,cAAc,QAAQ,eAAe;AAC9C,SAASC,UAAU,EAAEC,OAAO,QAAQ,iBAAiB;AACrD,SAASC,WAAW,QAAQ,yBAAyB;AACrD,SAASC,4BAA4B,QAAQ,cAAc;AAC3D,SAASC,iBAAiB,QAAQ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,CAACR,MAAa,CAAC;IAC3B;EAAE,GAEDC,CAAC,CAAC,2BAA2B,CACpB,CACQ,CAClB,CACI,CAAC;AAEjB,CAAC"}
@@ -15,6 +15,7 @@ export const TextInputStyled = ({
15
15
  export const TextInput = ({
16
16
  errorMessage,
17
17
  secureTextEntry,
18
+ rightIcon,
18
19
  ...rest
19
20
  }) => {
20
21
  const [status, setStatus] = React.useState('checked');
@@ -28,13 +29,13 @@ export const TextInput = ({
28
29
  }, /*#__PURE__*/React.createElement(TextInputStyled, _extends({
29
30
  width: "100%",
30
31
  secureTextEntry: shouldShowPassword && secureTextEntry
31
- }, rest)), secureTextEntry && /*#__PURE__*/React.createElement(View, {
32
+ }, rest)), (secureTextEntry || rightIcon) && /*#__PURE__*/React.createElement(View, {
32
33
  pt: "4",
33
34
  justifyContent: "center",
34
35
  alignSelf: "flex-end",
35
36
  position: "absolute",
36
37
  width: 48
37
- }, /*#__PURE__*/React.createElement(ToggleButton, {
38
+ }, rightIcon ?? /*#__PURE__*/React.createElement(ToggleButton, {
38
39
  icon: shouldShowPassword ? 'eye' : 'eye-off',
39
40
  size: 20,
40
41
  onPress: onButtonToggle
@@ -47,6 +48,7 @@ export const TextInput = ({
47
48
  size: 14,
48
49
  width: 20,
49
50
  margin: "0",
51
+ bg: 'background',
50
52
  iconColor: theme.colors.error
51
53
  }), /*#__PURE__*/React.createElement(Text, {
52
54
  variant: "bodySmall",
@@ -1 +1 @@
1
- {"version":3,"names":["React","TextInput","T","ToggleButton","useTheme","View","IconButton","Text","useRestyle","spacing","border","backgroundColor","backgroundColorShorthand","composeRestyleFunctions","spacingShorthand","layout","position","restyleFunctions","TextInputStyled","rest","props","createElement","errorMessage","secureTextEntry","status","setStatus","useState","onButtonToggle","shouldShowPassword","theme","justifyContent","_extends","width","pt","alignSelf","icon","size","onPress","Fragment","flexDirection","alignItems","pb","margin","iconColor","colors","error","variant","color"],"sourceRoot":"../../../src","sources":["components/TextInput.tsx"],"mappings":";AAAA,OAAOA,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B,KAAA,CAAAqB,aAAA,CAACH,eAAe,EAAAa,QAAA;IACdC,KAAK,EAAC,MAAM;IACZT,eAAe,EAAEK,kBAAkB,IAAIL;EAAgB,GACnDJ,IAAI,CACT,CAAC,EACDI,eAAe,iBACdvB,KAAA,CAAAqB,aAAA,CAAChB,IAAI;IACH4B,EAAE,EAAC,GAAG;IACNH,cAAc,EAAC,QAAQ;IACvBI,SAAS,EAAC,UAAU;IACpBlB,QAAQ,EAAC,UAAU;IACnBgB,KAAK,EAAE;EAAG,gBAEVhC,KAAA,CAAAqB,aAAA,CAAClB,YAAY;IACXgC,IAAI,EAAEP,kBAAkB,GAAG,KAAK,GAAG,SAAU;IAC7CQ,IAAI,EAAE,EAAG;IACTC,OAAO,EAAEV;EAAe,CACzB,CACG,CAEJ,CAAC,EAEN,CAAC,CAACL,YAAY,iBACbtB,KAAA,CAAAqB,aAAA,CAAArB,KAAA,CAAAsC,QAAA,qBACEtC,KAAA,CAAAqB,aAAA,CAAChB,IAAI;IAACkC,aAAa,EAAC,KAAK;IAACC,UAAU,EAAC,QAAQ;IAACC,EAAE,EAAC;EAAG,gBAClDzC,KAAA,CAAAqB,aAAA,CAACf,UAAU;IACT6B,IAAI,EAAC,sBAAsB;IAC3BC,IAAI,EAAE,EAAG;IACTJ,KAAK,EAAE,EAAG;IACVU,MAAM,EAAC,GAAG;IACVC,SAAS,EAAEd,KAAK,CAACe,MAAM,CAACC;EAAM,CAC/B,CAAC,eACF7C,KAAA,CAAAqB,aAAA,CAACd,IAAI;IAACuC,OAAO,EAAC,WAAW;IAACC,KAAK,EAAC;EAAO,GACpCzB,YACG,CACF,CACN,CAEA,CAAC;AAEX,CAAC"}
1
+ {"version":3,"names":["React","TextInput","T","ToggleButton","useTheme","View","IconButton","Text","useRestyle","spacing","border","backgroundColor","backgroundColorShorthand","composeRestyleFunctions","spacingShorthand","layout","position","restyleFunctions","TextInputStyled","rest","props","createElement","errorMessage","secureTextEntry","rightIcon","status","setStatus","useState","onButtonToggle","shouldShowPassword","theme","justifyContent","_extends","width","pt","alignSelf","icon","size","onPress","Fragment","flexDirection","alignItems","pb","margin","bg","iconColor","colors","error","variant","color"],"sourceRoot":"../../../src","sources":["components/TextInput.tsx"],"mappings":";AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SACEC,SAAS,IAAIC,CAAC,EAEdC,YAAY,EACZC,QAAQ,QACH,oBAAoB;AAC3B,SAASC,IAAI,QAAQ,QAAQ;AAC7B,SAASC,UAAU,QAAQ,cAAc;AACzC,SAASC,IAAI,QAAQ,QAAQ;AAC7B,SACEC,UAAU,EACVC,OAAO,EACPC,MAAM,EACNC,eAAe,EACfC,wBAAwB,EAIxBC,uBAAuB,EAIvBC,gBAAgB,EAChBC,MAAM,EACNC,QAAQ,QAEH,kBAAkB;AAWzB,MAAMC,gBAAgB,GAAGJ,uBAAuB,CAA0B,CACxEJ,OAAO,EACPK,gBAAgB,EAChBC,MAAM,EACNC,QAAQ,EACRN,MAAM,EACNC,eAAe,EACfC,wBAAwB,CACzB,CAAC;AAQF,OAAO,MAAMM,eAAe,GAAGA,CAAC;EAAE,GAAGC;AAAY,CAAC,KAAK;EACrD,MAAMC,KAAK,GAAGZ,UAAU,CAACS,gBAAgB,EAASE,IAAI,CAAC;EAEvD,oBAAOnB,KAAA,CAAAqB,aAAA,CAACnB,CAAC,EAAKkB,KAAQ,CAAC;AACzB,CAAC;AAED,OAAO,MAAMnB,SAA0B,GAAGA,CAAC;EACzCqB,YAAY;EACZC,eAAe;EACfC,SAAS;EACT,GAAGL;AACL,CAAC,KAAK;EACJ,MAAM,CAACM,MAAM,EAAEC,SAAS,CAAC,GAAG1B,KAAK,CAAC2B,QAAQ,CAAC,SAAS,CAAC;EAErD,MAAMC,cAAc,GAAGA,CAAA,KAAM;IAC3BF,SAAS,CAACD,MAAM,KAAK,SAAS,GAAG,WAAW,GAAG,SAAS,CAAC;EAC3D,CAAC;EAED,MAAMI,kBAAkB,GAAGJ,MAAM,KAAK,SAAS;E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ACG,CACF,CACN,CAEA,CAAC;AAEX,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"LoginScreen.d.ts","sourceRoot":"","sources":["../../../../../src/auth/screens/LoginScreen.tsx"],"names":[],"mappings":";AA4BA,eAAO,MAAM,WAAW,mBA2IvB,CAAC"}
1
+ {"version":3,"file":"LoginScreen.d.ts","sourceRoot":"","sources":["../../../../../src/auth/screens/LoginScreen.tsx"],"names":[],"mappings":";AA6BA,eAAO,MAAM,WAAW,mBAoIvB,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"ResetPassword.d.ts","sourceRoot":"","sources":["../../../../../src/auth/screens/ResetPassword.tsx"],"names":[],"mappings":";AAoBA,eAAO,MAAM,mBAAmB,mBAmE/B,CAAC"}
1
+ {"version":3,"file":"ResetPassword.d.ts","sourceRoot":"","sources":["../../../../../src/auth/screens/ResetPassword.tsx"],"names":[],"mappings":";AAqBA,eAAO,MAAM,mBAAmB,mBAsE/B,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"SignUp.d.ts","sourceRoot":"","sources":["../../../../../src/auth/screens/SignUp.tsx"],"names":[],"mappings":";AAuBA,MAAM,MAAM,SAAS,GAAG;IACtB,WAAW,EAAE,MAAM,CAAC;IACpB,KAAK,EAAE,MAAM,CAAC;IACd,WAAW,EAAE,MAAM,CAAC;IACpB,IAAI,CAAC,EAAE,MAAM,CAAC;CACf,CAAC;AAEF,eAAO,MAAM,YAAY,mBAqJxB,CAAC"}
1
+ {"version":3,"file":"SignUp.d.ts","sourceRoot":"","sources":["../../../../../src/auth/screens/SignUp.tsx"],"names":[],"mappings":";AAwBA,MAAM,MAAM,SAAS,GAAG;IACtB,WAAW,EAAE,MAAM,CAAC;IACpB,KAAK,EAAE,MAAM,CAAC;IACd,WAAW,EAAE,MAAM,CAAC;IACpB,IAAI,CAAC,EAAE,MAAM,CAAC;CACf,CAAC;AAEF,eAAO,MAAM,YAAY,mBAwJxB,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"SignUpPassword.d.ts","sourceRoot":"","sources":["../../../../../src/auth/screens/SignUpPassword.tsx"],"names":[],"mappings":"AAQA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,0BAA0B,CAAC;AAC1D,OAAO,KAAK,MAAM,OAAO,CAAC;AAW1B,KAAK,mBAAmB,GAAG;IACzB,KAAK,EAAE,SAAS,CAAC,aAAa,EAAE,gBAAgB,CAAC,CAAC;CACnD,CAAC;AAEF,eAAO,MAAM,cAAc,EAAE,KAAK,CAAC,EAAE,CAAC,mBAAmB,CAuGxD,CAAC"}
1
+ {"version":3,"file":"SignUpPassword.d.ts","sourceRoot":"","sources":["../../../../../src/auth/screens/SignUpPassword.tsx"],"names":[],"mappings":"AASA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,0BAA0B,CAAC;AAC1D,OAAO,KAAK,MAAM,OAAO,CAAC;AAW1B,KAAK,mBAAmB,GAAG;IACzB,KAAK,EAAE,SAAS,CAAC,aAAa,EAAE,gBAAgB,CAAC,CAAC;CACnD,CAAC;AAEF,eAAO,MAAM,cAAc,EAAE,KAAK,CAAC,EAAE,CAAC,mBAAmB,CA0GxD,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"VerifyPhoneNumber.d.ts","sourceRoot":"","sources":["../../../../../src/auth/screens/VerifyPhoneNumber.tsx"],"names":[],"mappings":"AASA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,0BAA0B,CAAC;AAC1D,OAAO,KAAK,MAAM,OAAO,CAAC;AAW1B,KAAK,4BAA4B,GAAG;IAClC,KAAK,EAAE,SAAS,CAAC,aAAa,EAAE,mBAAmB,CAAC,CAAC;CACtD,CAAC;AAEF,eAAO,MAAM,uBAAuB,EAAE,KAAK,CAAC,EAAE,CAC5C,4BAA4B,CA6E7B,CAAC"}
1
+ {"version":3,"file":"VerifyPhoneNumber.d.ts","sourceRoot":"","sources":["../../../../../src/auth/screens/VerifyPhoneNumber.tsx"],"names":[],"mappings":"AAUA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,0BAA0B,CAAC;AAC1D,OAAO,KAAK,MAAM,OAAO,CAAC;AAW1B,KAAK,4BAA4B,GAAG;IAClC,KAAK,EAAE,SAAS,CAAC,aAAa,EAAE,mBAAmB,CAAC,CAAC;CACtD,CAAC;AAEF,eAAO,MAAM,uBAAuB,EAAE,KAAK,CAAC,EAAE,CAC5C,4BAA4B,CAgF7B,CAAC"}
@@ -5,6 +5,7 @@ import { type ThemeType } from '../theme';
5
5
  type RestyleProps = SpacingProps<ThemeType> & SpacingShorthandProps<ThemeType> & LayoutProps<ThemeType> & PositionProps<ThemeType> & BorderProps<ThemeType> & BackgroundColorProps<ThemeType> & BackgroundColorShorthandProps<ThemeType>;
6
6
  type Props = RestyleProps & TextInputProps & {
7
7
  errorMessage?: string;
8
+ rightIcon?: React.ReactNode;
8
9
  };
9
10
  export declare const TextInputStyled: ({ ...rest }: Props) => JSX.Element;
10
11
  export declare const TextInput: React.FC<Props>;
@@ -1 +1 @@
1
- {"version":3,"file":"TextInput.d.ts","sourceRoot":"","sources":["../../../../src/components/TextInput.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAEL,KAAK,cAAc,EAGpB,MAAM,oBAAoB,CAAC;AAI5B,OAAO,EAML,KAAK,YAAY,EACjB,KAAK,WAAW,EAChB,KAAK,oBAAoB,EAEzB,KAAK,qBAAqB,EAC1B,KAAK,WAAW,EAChB,KAAK,aAAa,EAIlB,KAAK,6BAA6B,EACnC,MAAM,kBAAkB,CAAC;AAC1B,OAAO,EAAE,KAAK,SAAS,EAAE,MAAM,UAAU,CAAC;AAE1C,KAAK,YAAY,GAAG,YAAY,CAAC,SAAS,CAAC,GACzC,qBAAqB,CAAC,SAAS,CAAC,GAChC,WAAW,CAAC,SAAS,CAAC,GACtB,aAAa,CAAC,SAAS,CAAC,GACxB,WAAW,CAAC,SAAS,CAAC,GACtB,oBAAoB,CAAC,SAAS,CAAC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  {
2
2
  "name": "@kiosinc/commons-rn",
3
- "version": "0.1.19",
3
+ "version": "0.1.21",
4
4
  "description": "Common Code",
5
5
  "main": "lib/commonjs/index",
6
6
  "module": "lib/module/index",
@@ -7,6 +7,7 @@ import {
7
7
  LinkButton,
8
8
  KeyboardAvoidingView,
9
9
  Snackbar,
10
+ Header,
10
11
  } from '../../components';
11
12
  import { type NavigationProp, useNavigation } from '@react-navigation/native';
12
13
  import React, { useEffect, useState } from 'react';
@@ -64,105 +65,98 @@ export const LoginScreen = () => {
64
65
  };
65
66
 
66
67
  return (
67
- <ParentView px="16" flex={1} justifyContent="center">
68
- <KeyboardAvoidingView
69
- alignSelf="center"
70
- justifyContent={'center'}
71
- width={{ phone: '100%', tablet: 372 }}
72
- >
73
- <View alignItems="center">
74
- <AppLogo />
75
- <Text py="48" variant="titleLarge">
76
- {t('authentication.logIn')}
77
- </Text>
78
- </View>
79
- <Controller
80
- control={control}
81
- render={({ field: { onChange, onBlur, value } }) => {
82
- return (
83
- <TextInput
84
- my="5"
85
- keyboardType="email-address"
86
- autoCapitalize="none"
87
- mode="outlined"
88
- autoComplete="email"
89
- error={!!errors.email?.message}
90
- errorMessage={errors.email?.message}
91
- onBlur={onBlur}
92
- onChangeText={onChange}
93
- value={value}
94
- label={t('authentication.email')}
95
- />
96
- );
97
- }}
98
- name="email"
99
- />
100
- <Controller
101
- control={control}
102
- render={({ field: { onChange, onBlur, value } }) => {
103
- return (
104
- <TextInput
105
- my="5"
106
- secureTextEntry={true}
107
- mode="outlined"
108
- autoComplete="current-password"
109
- error={!!errors.password?.message}
110
- errorMessage={errors.password?.message}
111
- onBlur={onBlur}
112
- onChangeText={onChange}
113
- value={value}
114
- label={t('authentication.password')}
115
- />
116
- );
117
- }}
118
- name="password"
119
- />
120
- <LinkButton
121
- alignSelf="flex-end"
122
- mode="text"
123
- onPress={() => {
124
- navigation.navigate('ResetPassword');
125
- }}
126
- >
127
- {t('authentication.forgotPassword')}
128
- </LinkButton>
129
- <Button
130
- loading={isLoading}
131
- mt="38"
132
- mode="contained"
133
- onPress={handleSubmit(onSubmit)}
68
+ <ParentView px="16">
69
+ <Header left={10} position={'absolute'} zIndex={'100'} />
70
+ <View flex={1} justifyContent={'center'}>
71
+ <KeyboardAvoidingView
72
+ alignSelf="center"
73
+ justifyContent={'center'}
74
+ width={{ phone: '100%', tablet: 372 }}
134
75
  >
135
- {t('authentication.logIn')}
136
- </Button>
137
- {Config.APP_NAME !== 'git' && (
138
- <View
139
- alignItems="center"
140
- justifyContent="center"
141
- pt="8"
142
- flexDirection="row"
143
- >
144
- <Text variant="labelLarge">{t('authentication.newToApp')}</Text>
145
- <LinkButton
146
- mode="text"
147
- onPress={() => {
148
- navigation.navigate('SignUp');
149
- }}
150
- >
151
- {t('authentication.signUp')}
152
- </LinkButton>
76
+ <View alignItems="center">
77
+ <AppLogo />
78
+ <Text py="48" variant="titleLarge">
79
+ {t('authentication.logIn')}
80
+ </Text>
153
81
  </View>
154
- )}
155
- {navigation.canGoBack() && (
82
+ <Controller
83
+ control={control}
84
+ render={({ field: { onChange, onBlur, value } }) => {
85
+ return (
86
+ <TextInput
87
+ my="5"
88
+ keyboardType="email-address"
89
+ autoCapitalize="none"
90
+ mode="outlined"
91
+ autoComplete="email"
92
+ error={!!errors.email?.message}
93
+ errorMessage={errors.email?.message}
94
+ onBlur={onBlur}
95
+ onChangeText={onChange}
96
+ value={value}
97
+ label={t('authentication.email')}
98
+ />
99
+ );
100
+ }}
101
+ name="email"
102
+ />
103
+ <Controller
104
+ control={control}
105
+ render={({ field: { onChange, onBlur, value } }) => {
106
+ return (
107
+ <TextInput
108
+ my="5"
109
+ secureTextEntry={true}
110
+ mode="outlined"
111
+ autoComplete="current-password"
112
+ error={!!errors.password?.message}
113
+ errorMessage={errors.password?.message}
114
+ onBlur={onBlur}
115
+ onChangeText={onChange}
116
+ value={value}
117
+ label={t('authentication.password')}
118
+ />
119
+ );
120
+ }}
121
+ name="password"
122
+ />
156
123
  <LinkButton
124
+ alignSelf="flex-end"
157
125
  mode="text"
158
126
  onPress={() => {
159
- navigation.goBack();
127
+ navigation.navigate('ResetPassword');
160
128
  }}
161
129
  >
162
- {t('cancel')}
130
+ {t('authentication.forgotPassword')}
163
131
  </LinkButton>
164
- )}
165
- </KeyboardAvoidingView>
132
+ <Button
133
+ loading={isLoading}
134
+ mt="38"
135
+ mode="contained"
136
+ onPress={handleSubmit(onSubmit)}
137
+ >
138
+ {t('authentication.logIn')}
139
+ </Button>
140
+ {Config.APP_NAME !== 'git' && (
141
+ <View
142
+ alignItems="center"
143
+ justifyContent="center"
144
+ pt="8"
145
+ flexDirection="row"
146
+ >
147
+ <Text variant="labelLarge">{t('authentication.newToApp')}</Text>
148
+ <LinkButton
149
+ mode="text"
150
+ onPress={() => {
151
+ navigation.navigate('SignUp');
152
+ }}
153
+ >
154
+ {t('authentication.signUp')}
155
+ </LinkButton>
156
+ </View>
157
+ )}
158
+ </KeyboardAvoidingView>
159
+ </View>
166
160
  </ParentView>
167
161
  );
168
162
  };
@@ -5,6 +5,7 @@ import {
5
5
  TextInput,
6
6
  Button,
7
7
  KeyboardAvoidingView,
8
+ Header,
8
9
  } from '../../components';
9
10
  import { type NavigationProp, useNavigation } from '@react-navigation/native';
10
11
  import React from 'react';
@@ -40,49 +41,52 @@ export const ResetPasswordScreen = () => {
40
41
  };
41
42
 
42
43
  return (
43
- <ParentView justifyContent="center" px="16">
44
- <KeyboardAvoidingView
45
- alignSelf="center"
46
- justifyContent={'center'}
47
- width={{ phone: '100%', tablet: 372 }}
48
- >
49
- <View alignItems="center">
50
- <Text py="48" textAlign="center" variant="titleLarge">
51
- {t('authentication.enterYour')}
52
- </Text>
53
- </View>
54
- <Controller
55
- control={control}
56
- render={({ field: { onChange, onBlur, value } }) => {
57
- return (
58
- <TextInput
59
- keyboardType="email-address"
60
- autoCapitalize="none"
61
- mode="outlined"
62
- autoComplete="email"
63
- error={!!errors.email?.message}
64
- errorMessage={errors.email?.message}
65
- onBlur={onBlur}
66
- onChangeText={onChange}
67
- value={value}
68
- label={t('authentication.email')}
69
- />
70
- );
71
- }}
72
- name="email"
73
- />
74
- <Button
75
- loading={isLoading}
76
- mt="16"
77
- mode="contained"
78
- onPress={handleSubmit(onSubmit)}
44
+ <ParentView px="16">
45
+ <Header left={10} position={'absolute'} zIndex={'100'} />
46
+ <View flex={1} justifyContent={'center'}>
47
+ <KeyboardAvoidingView
48
+ alignSelf="center"
49
+ justifyContent={'center'}
50
+ width={{ phone: '100%', tablet: 372 }}
79
51
  >
80
- {t('authentication.resetPassword')}
81
- </Button>
82
- <Button mt="48" mode="outlined" onPress={navigation.goBack}>
83
- {t('cancel')}
84
- </Button>
85
- </KeyboardAvoidingView>
52
+ <View alignItems="center">
53
+ <Text py="48" textAlign="center" variant="titleLarge">
54
+ {t('authentication.enterYour')}
55
+ </Text>
56
+ </View>
57
+ <Controller
58
+ control={control}
59
+ render={({ field: { onChange, onBlur, value } }) => {
60
+ return (
61
+ <TextInput
62
+ keyboardType="email-address"
63
+ autoCapitalize="none"
64
+ mode="outlined"
65
+ autoComplete="email"
66
+ error={!!errors.email?.message}
67
+ errorMessage={errors.email?.message}
68
+ onBlur={onBlur}
69
+ onChangeText={onChange}
70
+ value={value}
71
+ label={t('authentication.email')}
72
+ />
73
+ );
74
+ }}
75
+ name="email"
76
+ />
77
+ <Button
78
+ loading={isLoading}
79
+ mt="16"
80
+ mode="contained"
81
+ onPress={handleSubmit(onSubmit)}
82
+ >
83
+ {t('authentication.resetPassword')}
84
+ </Button>
85
+ <Button mt="48" mode="outlined" onPress={navigation.goBack}>
86
+ {t('cancel')}
87
+ </Button>
88
+ </KeyboardAvoidingView>
89
+ </View>
86
90
  </ParentView>
87
91
  );
88
92
  };