@onairos/react-native 1.0.0 → 1.0.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/lib/commonjs/components/OnairosButton.js +6 -415
- package/lib/commonjs/components/OnairosButton.js.map +1 -1
- package/lib/commonjs/components/Overlay.js +0 -549
- package/lib/commonjs/components/PinInput.js +160 -0
- package/lib/commonjs/components/PinInput.js.map +1 -0
- package/lib/commonjs/components/PlatformList.js +137 -0
- package/lib/commonjs/components/PlatformList.js.map +1 -0
- package/lib/commonjs/components/TrainingModal.js +130 -0
- package/lib/commonjs/components/TrainingModal.js.map +1 -0
- package/lib/commonjs/index.js +12 -276
- package/lib/commonjs/index.js.map +1 -1
- package/lib/module/components/OnairosButton.js +121 -514
- package/lib/module/components/OnairosButton.js.map +1 -1
- package/lib/module/components/Overlay.js +0 -565
- package/lib/module/components/PinInput.js +151 -0
- package/lib/module/components/PinInput.js.map +1 -0
- package/lib/module/components/PlatformList.js +129 -0
- package/lib/module/components/PlatformList.js.map +1 -0
- package/lib/module/components/TrainingModal.js +122 -0
- package/lib/module/components/TrainingModal.js.map +1 -0
- package/package.json +5 -4
- package/src/components/OnairosButton.tsx +5 -5
- package/src/components/PinInput.tsx +189 -0
- package/src/components/PlatformList.tsx +145 -0
- package/src/components/TrainingModal.tsx +132 -0
- package/lib/commonjs/components/Notification.js +0 -106
- package/lib/commonjs/components/Notification.js.map +0 -1
- package/lib/module/components/Notification.js +0 -99
- package/lib/module/components/Notification.js.map +0 -1
- package/src/components/Notification.js +0 -101
- package/src/components/OnairosButton.js +0 -604
- package/src/components/Overlay.js +0 -854
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["_react","_interopRequireWildcard","require","_reactNative","_MaterialIcons","_interopRequireDefault","_constants","e","__esModule","default","t","WeakMap","r","n","o","i","f","__proto__","has","get","set","hasOwnProperty","call","Object","defineProperty","getOwnPropertyDescriptor","PinInput","onSubmit","minLength","requireSpecialChar","requireNumber","pin","setPin","useState","error","setError","showPin","setShowPin","validatePin","useCallback","value","length","test","handleSubmit","validationError","handlePinChange","createElement","View","style","styles","container","Text","title","subtitle","inputContainer","TextInput","input","onChangeText","secureTextEntry","placeholder","keyboardType","maxLength","autoCapitalize","autoCorrect","TouchableOpacity","visibilityButton","onPress","name","size","color","COLORS","text","secondary","requirements","requirementTitle","requirement","requirementMet","submitButton","submitButtonDisabled","disabled","submitButtonText","exports","StyleSheet","create","flex","padding","fontSize","fontWeight","marginBottom","primary","flexDirection","alignItems","borderWidth","borderColor","border","borderRadius","success","backgroundColor","paddingVertical","opacity"],"sourceRoot":"..\\..\\..\\src","sources":["components/PinInput.tsx"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,uBAAA,CAAAC,OAAA;AACA,IAAAC,YAAA,GAAAD,OAAA;AAQA,IAAAE,cAAA,GAAAC,sBAAA,CAAAH,OAAA;AACA,IAAAI,UAAA,GAAAJ,OAAA;AAAsC,SAAAG,uBAAAE,CAAA,WAAAA,CAAA,IAAAA,CAAA,CAAAC,UAAA,GAAAD,CAAA,KAAAE,OAAA,EAAAF,CAAA;AAAA,SAAAN,wBAAAM,CAAA,EAAAG,CAAA,6BAAAC,OAAA,MAAAC,CAAA,OAAAD,OAAA,IAAAE,CAAA,OAAAF,OAAA,YAAAV,uBAAA,YAAAA,CAAAM,CAAA,EAAAG,CAAA,SAAAA,CAAA,IAAAH,CAAA,IAAAA,CAAA,CAAAC,UAAA,SAAAD,CAAA,MAAAO,CAAA,EAAAC,CAAA,EAAAC,CAAA,KAAAC,SAAA,QAAAR,OAAA,EAAAF,CAAA,iBAAAA,CAAA,uBAAAA,CAAA,yBAAAA,CAAA,SAAAS,CAAA,MAAAF,CAAA,GAAAJ,CAAA,GAAAG,CAAA,GAAAD,CAAA,QAAAE,CAAA,CAAAI,GAAA,CAAAX,CAAA,UAAAO,CAAA,CAAAK,GAAA,CAAAZ,CAAA,GAAAO,CAAA,CAAAM,GAAA,CAAA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AAW,EAAE,CAAC;IACdC,WAAW,EAAEvB,iBAAM,CAACwB,MAAM;IAC1BC,YAAY,EAAE,CAAC;IACfP,YAAY,EAAE;EAChB,CAAC;EACDhC,KAAK,EAAE;IACL4B,IAAI,EAAE,CAAC;IACPC,OAAO,EAAE,EAAE;IACXC,QAAQ,EAAE;EACZ,CAAC;EACDrB,gBAAgB,EAAE;IAChBoB,OAAO,EAAE;EACX,CAAC;EACDnD,KAAK,EAAE;IACLmC,KAAK,EAAEC,iBAAM,CAACpC,KAAK;IACnBsD,YAAY,EAAE;EAChB,CAAC;EACDf,YAAY,EAAE;IACZe,YAAY,EAAE;EAChB,CAAC;EACDd,gBAAgB,EAAE;IAChBY,QAAQ,EAAE,EAAE;IACZC,UAAU,EAAE,KAAK;IACjBC,YAAY,EAAE,CAAC;IACfnB,KAAK,EAAEC,iBAAM,CAACC,IAAI,CAACkB;EACrB,CAAC;EACDd,WAAW,EAAE;IACXW,QAAQ,EAAE,EAAE;IACZjB,KAAK,EAAEC,iBAAM,CAACC,IAAI,CAACC,SAAS;IAC5BgB,YAAY,EAAE;EAChB,CAAC;EACDZ,cAAc,EAAE;IACdP,KAAK,EAAEC,iBAAM,CAAC0B;EAChB,CAAC;EACDnB,YAAY,EAAE;IACZoB,eAAe,EAAE3B,iBAAM,CAACmB,OAAO;IAC/BS,eAAe,EAAE,EAAE;IACnBH,YAAY,EAAE,EAAE;IAChBJ,UAAU,EAAE;EACd,CAAC;EACDb,oBAAoB,EAAE;IACpBqB,OAAO,EAAE;EACX,CAAC;EACDnB,gBAAgB,EAAE;IAChBX,KAAK,EAAE,MAAM;IACbiB,QAAQ,EAAE,EAAE;IACZC,UAAU,EAAE;EACd;AACF,CAAC,CAAC","ignoreList":[]}
|
|
@@ -0,0 +1,137 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.PlatformList = void 0;
|
|
7
|
+
var _react = _interopRequireDefault(require("react"));
|
|
8
|
+
var _reactNative = require("react-native");
|
|
9
|
+
var _MaterialIcons = _interopRequireDefault(require("react-native-vector-icons/MaterialIcons"));
|
|
10
|
+
var _constants = require("../constants");
|
|
11
|
+
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
|
12
|
+
const PlatformList = ({
|
|
13
|
+
connections,
|
|
14
|
+
onToggle,
|
|
15
|
+
isLoading,
|
|
16
|
+
canProceed,
|
|
17
|
+
onProceed
|
|
18
|
+
}) => {
|
|
19
|
+
const renderPlatformItem = (platform, isConnected) => {
|
|
20
|
+
const platformConfig = _constants.PLATFORMS[platform];
|
|
21
|
+
if (!platformConfig) return null;
|
|
22
|
+
return /*#__PURE__*/_react.default.createElement(_reactNative.View, {
|
|
23
|
+
key: platform,
|
|
24
|
+
style: styles.platformContainer
|
|
25
|
+
}, /*#__PURE__*/_react.default.createElement(_reactNative.View, {
|
|
26
|
+
style: styles.platformHeader
|
|
27
|
+
}, /*#__PURE__*/_react.default.createElement(_MaterialIcons.default, {
|
|
28
|
+
name: platformConfig.icon,
|
|
29
|
+
size: 24,
|
|
30
|
+
color: platformConfig.color
|
|
31
|
+
}), /*#__PURE__*/_react.default.createElement(_reactNative.Text, {
|
|
32
|
+
style: styles.platformName
|
|
33
|
+
}, platformConfig.name)), platformConfig.description && /*#__PURE__*/_react.default.createElement(_reactNative.Text, {
|
|
34
|
+
style: styles.platformDescription
|
|
35
|
+
}, platformConfig.description), /*#__PURE__*/_react.default.createElement(_reactNative.TouchableOpacity, {
|
|
36
|
+
style: [styles.connectButton, isConnected ? styles.connectedButton : styles.disconnectedButton],
|
|
37
|
+
onPress: () => onToggle(platform, !isConnected),
|
|
38
|
+
disabled: isLoading
|
|
39
|
+
}, isLoading ? /*#__PURE__*/_react.default.createElement(_reactNative.ActivityIndicator, {
|
|
40
|
+
color: "#fff"
|
|
41
|
+
}) : /*#__PURE__*/_react.default.createElement(_reactNative.Text, {
|
|
42
|
+
style: styles.buttonText
|
|
43
|
+
}, isConnected ? 'Disconnect' : 'Connect')));
|
|
44
|
+
};
|
|
45
|
+
return /*#__PURE__*/_react.default.createElement(_reactNative.View, {
|
|
46
|
+
style: styles.container
|
|
47
|
+
}, /*#__PURE__*/_react.default.createElement(_reactNative.Text, {
|
|
48
|
+
style: styles.title
|
|
49
|
+
}, "Connect your platforms"), /*#__PURE__*/_react.default.createElement(_reactNative.Text, {
|
|
50
|
+
style: styles.subtitle
|
|
51
|
+
}, "Connect at least 2 platforms to proceed"), /*#__PURE__*/_react.default.createElement(_reactNative.View, {
|
|
52
|
+
style: styles.platformsList
|
|
53
|
+
}, Object.entries(connections).map(([platform, status]) => renderPlatformItem(platform, !!status))), /*#__PURE__*/_react.default.createElement(_reactNative.TouchableOpacity, {
|
|
54
|
+
style: [styles.proceedButton, !canProceed && styles.disabledButton],
|
|
55
|
+
onPress: onProceed,
|
|
56
|
+
disabled: !canProceed || isLoading
|
|
57
|
+
}, /*#__PURE__*/_react.default.createElement(_reactNative.Text, {
|
|
58
|
+
style: styles.proceedButtonText
|
|
59
|
+
}, "Proceed")));
|
|
60
|
+
};
|
|
61
|
+
exports.PlatformList = PlatformList;
|
|
62
|
+
const styles = _reactNative.StyleSheet.create({
|
|
63
|
+
container: {
|
|
64
|
+
flex: 1,
|
|
65
|
+
padding: 16
|
|
66
|
+
},
|
|
67
|
+
title: {
|
|
68
|
+
fontSize: 20,
|
|
69
|
+
fontWeight: '600',
|
|
70
|
+
marginBottom: 8,
|
|
71
|
+
color: _constants.COLORS.text.primary
|
|
72
|
+
},
|
|
73
|
+
subtitle: {
|
|
74
|
+
fontSize: 14,
|
|
75
|
+
color: _constants.COLORS.text.secondary,
|
|
76
|
+
marginBottom: 24
|
|
77
|
+
},
|
|
78
|
+
platformsList: {
|
|
79
|
+
flex: 1
|
|
80
|
+
},
|
|
81
|
+
platformContainer: {
|
|
82
|
+
backgroundColor: '#fff',
|
|
83
|
+
borderRadius: 12,
|
|
84
|
+
padding: 16,
|
|
85
|
+
marginBottom: 16,
|
|
86
|
+
borderWidth: 1,
|
|
87
|
+
borderColor: _constants.COLORS.border
|
|
88
|
+
},
|
|
89
|
+
platformHeader: {
|
|
90
|
+
flexDirection: 'row',
|
|
91
|
+
alignItems: 'center',
|
|
92
|
+
marginBottom: 8
|
|
93
|
+
},
|
|
94
|
+
platformName: {
|
|
95
|
+
fontSize: 16,
|
|
96
|
+
fontWeight: '600',
|
|
97
|
+
marginLeft: 12,
|
|
98
|
+
color: _constants.COLORS.text.primary
|
|
99
|
+
},
|
|
100
|
+
platformDescription: {
|
|
101
|
+
fontSize: 14,
|
|
102
|
+
color: _constants.COLORS.text.secondary,
|
|
103
|
+
marginBottom: 16
|
|
104
|
+
},
|
|
105
|
+
connectButton: {
|
|
106
|
+
paddingVertical: 8,
|
|
107
|
+
paddingHorizontal: 16,
|
|
108
|
+
borderRadius: 8,
|
|
109
|
+
alignItems: 'center'
|
|
110
|
+
},
|
|
111
|
+
connectedButton: {
|
|
112
|
+
backgroundColor: _constants.COLORS.success
|
|
113
|
+
},
|
|
114
|
+
disconnectedButton: {
|
|
115
|
+
backgroundColor: _constants.COLORS.primary
|
|
116
|
+
},
|
|
117
|
+
buttonText: {
|
|
118
|
+
color: '#fff',
|
|
119
|
+
fontWeight: '600'
|
|
120
|
+
},
|
|
121
|
+
proceedButton: {
|
|
122
|
+
backgroundColor: _constants.COLORS.primary,
|
|
123
|
+
paddingVertical: 16,
|
|
124
|
+
borderRadius: 12,
|
|
125
|
+
alignItems: 'center',
|
|
126
|
+
marginTop: 16
|
|
127
|
+
},
|
|
128
|
+
disabledButton: {
|
|
129
|
+
opacity: 0.5
|
|
130
|
+
},
|
|
131
|
+
proceedButtonText: {
|
|
132
|
+
color: '#fff',
|
|
133
|
+
fontSize: 16,
|
|
134
|
+
fontWeight: '600'
|
|
135
|
+
}
|
|
136
|
+
});
|
|
137
|
+
//# sourceMappingURL=PlatformList.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["_react","_interopRequireDefault","require","_reactNative","_MaterialIcons","_constants","e","__esModule","default","PlatformList","connections","onToggle","isLoading","canProceed","onProceed","renderPlatformItem","platform","isConnected","platformConfig","PLATFORMS","createElement","View","key","style","styles","platformContainer","platformHeader","name","icon","size","color","Text","platformName","description","platformDescription","TouchableOpacity","connectButton","connectedButton","disconnectedButton","onPress","disabled","ActivityIndicator","buttonText","container","title","subtitle","platformsList","Object","entries","map","status","proceedButton","disabledButton","proceedButtonText","exports","StyleSheet","create","flex","padding","fontSize","fontWeight","marginBottom","COLORS","text","primary","secondary","backgroundColor","borderRadius","borderWidth","borderColor","border","flexDirection","alignItems","marginLeft","paddingVertical","paddingHorizontal","success","marginTop","opacity"],"sourceRoot":"..\\..\\..\\src","sources":["components/PlatformList.tsx"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,sBAAA,CAAAC,OAAA;AACA,IAAAC,YAAA,GAAAD,OAAA;AACA,IAAAE,cAAA,GAAAH,sBAAA,CAAAC,OAAA;AACA,IAAAG,UAAA,GAAAH,OAAA;AAAiD,SAAAD,uBAAAK,CAAA,WAAAA,CAAA,IAAAA,CAAA,CAAAC,UAAA,GAAAD,CAAA,KAAAE,OAAA,EAAAF,CAAA;AAG1C,MAAMG,YAAyC,GAAGA,CAAC;EACxDC,WAAW;EACXC,QAAQ;EACRC,SAAS;EACTC,UAAU;EACVC;AACF,CAAC,KAAK;EACJ,MAAMC,kBAAkB,GAAGA,CAACC,QAAgB,EAAEC,WAAoB,KAAK;IACrE,MAAMC,cAAc,GAAGC,oBAAS,CAACH,QAAQ,CAAC;IAC1C,IAAI,CAACE,cAAc,EAAE,OAAO,IAAI;IAEhC,oBACElB,MAAA,CAAAQ,OAAA,CAAAY,aAAA,CAACjB,YAAA,CAAAkB,IAAI;MAACC,GAAG,EAAEN,QAAS;MAACO,KAAK,EAAEC,MAAM,CAACC;IAAkB,gBACnDzB,MAAA,CAAAQ,OA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J,iBAAM,CAACE,OAAO;IAC/BU,eAAe,EAAE,EAAE;IACnBP,YAAY,EAAE,EAAE;IAChBK,UAAU,EAAE,QAAQ;IACpBK,SAAS,EAAE;EACb,CAAC;EACDzB,cAAc,EAAE;IACd0B,OAAO,EAAE;EACX,CAAC;EACDzB,iBAAiB,EAAE;IACjBvB,KAAK,EAAE,MAAM;IACb6B,QAAQ,EAAE,EAAE;IACZC,UAAU,EAAE;EACd;AACF,CAAC,CAAC","ignoreList":[]}
|
|
@@ -0,0 +1,130 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.TrainingModal = void 0;
|
|
7
|
+
var _react = _interopRequireDefault(require("react"));
|
|
8
|
+
var _reactNative = require("react-native");
|
|
9
|
+
var _MaterialIcons = _interopRequireDefault(require("react-native-vector-icons/MaterialIcons"));
|
|
10
|
+
var _constants = require("../constants");
|
|
11
|
+
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
|
12
|
+
const TrainingModal = ({
|
|
13
|
+
progress,
|
|
14
|
+
eta,
|
|
15
|
+
onCancel
|
|
16
|
+
}) => {
|
|
17
|
+
const progressPercentage = Math.round(progress * 100);
|
|
18
|
+
return /*#__PURE__*/_react.default.createElement(_reactNative.View, {
|
|
19
|
+
style: styles.container
|
|
20
|
+
}, /*#__PURE__*/_react.default.createElement(_reactNative.View, {
|
|
21
|
+
style: styles.content
|
|
22
|
+
}, /*#__PURE__*/_react.default.createElement(_MaterialIcons.default, {
|
|
23
|
+
name: "auto_awesome",
|
|
24
|
+
size: 48,
|
|
25
|
+
color: _constants.COLORS.primary
|
|
26
|
+
}), /*#__PURE__*/_react.default.createElement(_reactNative.Text, {
|
|
27
|
+
style: styles.title
|
|
28
|
+
}, "Training Your AI Model"), /*#__PURE__*/_react.default.createElement(_reactNative.Text, {
|
|
29
|
+
style: styles.subtitle
|
|
30
|
+
}, "We're analyzing your social media data to create your personalized AI model"), /*#__PURE__*/_react.default.createElement(_reactNative.View, {
|
|
31
|
+
style: styles.progressContainer
|
|
32
|
+
}, /*#__PURE__*/_react.default.createElement(_reactNative.View, {
|
|
33
|
+
style: styles.progressBar
|
|
34
|
+
}, /*#__PURE__*/_react.default.createElement(_reactNative.View, {
|
|
35
|
+
style: [styles.progressFill, {
|
|
36
|
+
width: `${progressPercentage}%`
|
|
37
|
+
}]
|
|
38
|
+
})), /*#__PURE__*/_react.default.createElement(_reactNative.Text, {
|
|
39
|
+
style: styles.progressText
|
|
40
|
+
}, progressPercentage, "%")), /*#__PURE__*/_react.default.createElement(_reactNative.Text, {
|
|
41
|
+
style: styles.etaText
|
|
42
|
+
}, "Estimated time remaining: ", eta), /*#__PURE__*/_react.default.createElement(_reactNative.View, {
|
|
43
|
+
style: styles.loadingContainer
|
|
44
|
+
}, /*#__PURE__*/_react.default.createElement(_reactNative.ActivityIndicator, {
|
|
45
|
+
size: "small",
|
|
46
|
+
color: _constants.COLORS.primary
|
|
47
|
+
}), /*#__PURE__*/_react.default.createElement(_reactNative.Text, {
|
|
48
|
+
style: styles.loadingText
|
|
49
|
+
}, "Processing your data...")), /*#__PURE__*/_react.default.createElement(_reactNative.TouchableOpacity, {
|
|
50
|
+
style: styles.cancelButton,
|
|
51
|
+
onPress: onCancel
|
|
52
|
+
}, /*#__PURE__*/_react.default.createElement(_reactNative.Text, {
|
|
53
|
+
style: styles.cancelButtonText
|
|
54
|
+
}, "Cancel"))));
|
|
55
|
+
};
|
|
56
|
+
exports.TrainingModal = TrainingModal;
|
|
57
|
+
const styles = _reactNative.StyleSheet.create({
|
|
58
|
+
container: {
|
|
59
|
+
flex: 1,
|
|
60
|
+
justifyContent: 'center',
|
|
61
|
+
alignItems: 'center',
|
|
62
|
+
padding: 24
|
|
63
|
+
},
|
|
64
|
+
content: {
|
|
65
|
+
width: '100%',
|
|
66
|
+
alignItems: 'center'
|
|
67
|
+
},
|
|
68
|
+
title: {
|
|
69
|
+
fontSize: 24,
|
|
70
|
+
fontWeight: '600',
|
|
71
|
+
marginTop: 24,
|
|
72
|
+
marginBottom: 8,
|
|
73
|
+
color: _constants.COLORS.text.primary,
|
|
74
|
+
textAlign: 'center'
|
|
75
|
+
},
|
|
76
|
+
subtitle: {
|
|
77
|
+
fontSize: 16,
|
|
78
|
+
color: _constants.COLORS.text.secondary,
|
|
79
|
+
textAlign: 'center',
|
|
80
|
+
marginBottom: 32
|
|
81
|
+
},
|
|
82
|
+
progressContainer: {
|
|
83
|
+
width: '100%',
|
|
84
|
+
marginBottom: 16
|
|
85
|
+
},
|
|
86
|
+
progressBar: {
|
|
87
|
+
height: 8,
|
|
88
|
+
backgroundColor: _constants.COLORS.border,
|
|
89
|
+
borderRadius: 4,
|
|
90
|
+
overflow: 'hidden'
|
|
91
|
+
},
|
|
92
|
+
progressFill: {
|
|
93
|
+
height: '100%',
|
|
94
|
+
backgroundColor: _constants.COLORS.primary,
|
|
95
|
+
borderRadius: 4
|
|
96
|
+
},
|
|
97
|
+
progressText: {
|
|
98
|
+
fontSize: 14,
|
|
99
|
+
color: _constants.COLORS.text.secondary,
|
|
100
|
+
textAlign: 'center',
|
|
101
|
+
marginTop: 8
|
|
102
|
+
},
|
|
103
|
+
etaText: {
|
|
104
|
+
fontSize: 14,
|
|
105
|
+
color: _constants.COLORS.text.secondary,
|
|
106
|
+
marginBottom: 24
|
|
107
|
+
},
|
|
108
|
+
loadingContainer: {
|
|
109
|
+
flexDirection: 'row',
|
|
110
|
+
alignItems: 'center',
|
|
111
|
+
marginBottom: 32
|
|
112
|
+
},
|
|
113
|
+
loadingText: {
|
|
114
|
+
fontSize: 14,
|
|
115
|
+
color: _constants.COLORS.text.secondary,
|
|
116
|
+
marginLeft: 8
|
|
117
|
+
},
|
|
118
|
+
cancelButton: {
|
|
119
|
+
paddingVertical: 12,
|
|
120
|
+
paddingHorizontal: 24,
|
|
121
|
+
borderRadius: 8,
|
|
122
|
+
borderWidth: 1,
|
|
123
|
+
borderColor: _constants.COLORS.border
|
|
124
|
+
},
|
|
125
|
+
cancelButtonText: {
|
|
126
|
+
fontSize: 16,
|
|
127
|
+
color: _constants.COLORS.text.secondary
|
|
128
|
+
}
|
|
129
|
+
});
|
|
130
|
+
//# sourceMappingURL=TrainingModal.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["_react","_interopRequireDefault","require","_reactNative","_MaterialIcons","_constants","e","__esModule","default","TrainingModal","progress","eta","onCancel","progressPercentage","Math","round","createElement","View","style","styles","container","content","name","size","color","COLORS","primary","Text","title","subtitle","progressContainer","progressBar","progressFill","width","progressText","etaText","loadingContainer","ActivityIndicator","loadingText","TouchableOpacity","cancelButton","onPress","cancelButtonText","exports","StyleSheet","create","flex","justifyContent","alignItems","padding","fontSize","fontWeight","marginTop","marginBottom","text","textAlign","secondary","height","backgroundColor","border","borderRadius","overflow","flexDirection","marginLeft","paddingVertical","paddingHorizontal","borderWidth","borderColor"],"sourceRoot":"..\\..\\..\\src","sources":["components/TrainingModal.tsx"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,sBAAA,CAAAC,OAAA;AACA,IAAAC,YAAA,GAAAD,OAAA;AAOA,IAAAE,cAAA,GAAAH,sBAAA,CAAAC,OAAA;AACA,IAAAG,UAAA,GAAAH,OAAA;AAAsC,SAAAD,uBAAAK,CAAA,WAAAA,CAAA,IAAAA,CAAA,CAAAC,UAAA,GAAAD,CAAA,KAAAE,OAAA,EAAAF,CAAA;AAG/B,MAAMG,aAA2C,GAAGA,CAAC;EAC1DC,QAAQ;EACRC,GAAG;EACHC;AACF,CAAC,KAAK;EACJ,MAAMC,kBAAkB,GAAGC,IAAI,CAACC,KAAK,CAACL,QAAQ,GAAG,GAAG,CAAC;EAErD,oBACEV,MAAA,CAAAQ,OAAA,CAAAQ,aAAA,CAACb,YAAA,CAAAc,IAAI;IAACC,KAAK,EAAEC,MAAM,CAACC;EAAU,gBAC5BpB,MA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E;EACrB;AACF,CAAC,CAAC","ignoreList":[]}
|
package/lib/commonjs/index.js
CHANGED
|
@@ -3,280 +3,16 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
Object.defineProperty(exports, "ConnectorScreen", {
|
|
19
|
-
enumerable: true,
|
|
20
|
-
get: function () {
|
|
21
|
-
return _ConnectorScreen.ConnectorScreen;
|
|
22
|
-
}
|
|
23
|
-
});
|
|
24
|
-
Object.defineProperty(exports, "DEEP_LINK_CONFIG", {
|
|
25
|
-
enumerable: true,
|
|
26
|
-
get: function () {
|
|
27
|
-
return _constants.DEEP_LINK_CONFIG;
|
|
28
|
-
}
|
|
29
|
-
});
|
|
30
|
-
Object.defineProperty(exports, "LoadingScreen", {
|
|
31
|
-
enumerable: true,
|
|
32
|
-
get: function () {
|
|
33
|
-
return _LoadingScreen.LoadingScreen;
|
|
34
|
-
}
|
|
35
|
-
});
|
|
36
|
-
Object.defineProperty(exports, "OAuthWebView", {
|
|
37
|
-
enumerable: true,
|
|
38
|
-
get: function () {
|
|
39
|
-
return _OAuthWebView.OAuthWebView;
|
|
40
|
-
}
|
|
41
|
-
});
|
|
42
|
-
Object.defineProperty(exports, "OnairosButton", {
|
|
43
|
-
enumerable: true,
|
|
44
|
-
get: function () {
|
|
45
|
-
return _OnairosButton.OnairosButton;
|
|
46
|
-
}
|
|
47
|
-
});
|
|
48
|
-
Object.defineProperty(exports, "OnboardingHeader", {
|
|
49
|
-
enumerable: true,
|
|
50
|
-
get: function () {
|
|
51
|
-
return _OnboardingHeader.OnboardingHeader;
|
|
52
|
-
}
|
|
53
|
-
});
|
|
54
|
-
Object.defineProperty(exports, "Overlay", {
|
|
55
|
-
enumerable: true,
|
|
56
|
-
get: function () {
|
|
57
|
-
return _Overlay.Overlay;
|
|
58
|
-
}
|
|
59
|
-
});
|
|
60
|
-
Object.defineProperty(exports, "PIN_REQUIREMENTS", {
|
|
61
|
-
enumerable: true,
|
|
62
|
-
get: function () {
|
|
63
|
-
return _constants.PIN_REQUIREMENTS;
|
|
64
|
-
}
|
|
65
|
-
});
|
|
66
|
-
Object.defineProperty(exports, "PLATFORMS", {
|
|
67
|
-
enumerable: true,
|
|
68
|
-
get: function () {
|
|
69
|
-
return _constants.PLATFORMS;
|
|
70
|
-
}
|
|
71
|
-
});
|
|
72
|
-
Object.defineProperty(exports, "PinCreationScreen", {
|
|
73
|
-
enumerable: true,
|
|
74
|
-
get: function () {
|
|
75
|
-
return _PinCreationScreen.PinCreationScreen;
|
|
76
|
-
}
|
|
77
|
-
});
|
|
78
|
-
Object.defineProperty(exports, "PinInput", {
|
|
79
|
-
enumerable: true,
|
|
80
|
-
get: function () {
|
|
81
|
-
return _PinInput.PinInput;
|
|
82
|
-
}
|
|
83
|
-
});
|
|
84
|
-
Object.defineProperty(exports, "PlatformConnector", {
|
|
85
|
-
enumerable: true,
|
|
86
|
-
get: function () {
|
|
87
|
-
return _PlatformConnector.PlatformConnector;
|
|
88
|
-
}
|
|
89
|
-
});
|
|
90
|
-
Object.defineProperty(exports, "STORAGE_KEYS", {
|
|
91
|
-
enumerable: true,
|
|
92
|
-
get: function () {
|
|
93
|
-
return _constants.STORAGE_KEYS;
|
|
94
|
-
}
|
|
95
|
-
});
|
|
96
|
-
Object.defineProperty(exports, "UniversalOnboarding", {
|
|
97
|
-
enumerable: true,
|
|
98
|
-
get: function () {
|
|
99
|
-
return _UniversalOnboarding.UniversalOnboarding;
|
|
100
|
-
}
|
|
101
|
-
});
|
|
102
|
-
Object.defineProperty(exports, "authenticate", {
|
|
103
|
-
enumerable: true,
|
|
104
|
-
get: function () {
|
|
105
|
-
return _onairosApi.authenticate;
|
|
106
|
-
}
|
|
107
|
-
});
|
|
108
|
-
Object.defineProperty(exports, "base64ToBuffer", {
|
|
109
|
-
enumerable: true,
|
|
110
|
-
get: function () {
|
|
111
|
-
return _crypto.base64ToBuffer;
|
|
112
|
-
}
|
|
113
|
-
});
|
|
114
|
-
Object.defineProperty(exports, "cleanupOAuthService", {
|
|
115
|
-
enumerable: true,
|
|
116
|
-
get: function () {
|
|
117
|
-
return _oauthService.cleanupOAuthService;
|
|
118
|
-
}
|
|
119
|
-
});
|
|
120
|
-
Object.defineProperty(exports, "connectPlatform", {
|
|
121
|
-
enumerable: true,
|
|
122
|
-
get: function () {
|
|
123
|
-
return _oauthService.connectPlatform;
|
|
124
|
-
}
|
|
125
|
-
});
|
|
126
|
-
Object.defineProperty(exports, "createAccount", {
|
|
127
|
-
enumerable: true,
|
|
128
|
-
get: function () {
|
|
129
|
-
return _onairosApi.createAccount;
|
|
130
|
-
}
|
|
131
|
-
});
|
|
132
|
-
Object.defineProperty(exports, "deleteCredentials", {
|
|
133
|
-
enumerable: true,
|
|
134
|
-
get: function () {
|
|
135
|
-
return _secureStorage.deleteCredentials;
|
|
136
|
-
}
|
|
137
|
-
});
|
|
138
|
-
Object.defineProperty(exports, "disconnectPlatform", {
|
|
139
|
-
enumerable: true,
|
|
140
|
-
get: function () {
|
|
141
|
-
return _oauthService.disconnectPlatform;
|
|
142
|
-
}
|
|
143
|
-
});
|
|
144
|
-
Object.defineProperty(exports, "generateDeviceUsername", {
|
|
145
|
-
enumerable: true,
|
|
146
|
-
get: function () {
|
|
147
|
-
return _secureStorage.generateDeviceUsername;
|
|
148
|
-
}
|
|
149
|
-
});
|
|
150
|
-
Object.defineProperty(exports, "getCredentials", {
|
|
151
|
-
enumerable: true,
|
|
152
|
-
get: function () {
|
|
153
|
-
return _secureStorage.getCredentials;
|
|
154
|
-
}
|
|
155
|
-
});
|
|
156
|
-
Object.defineProperty(exports, "getPlatformData", {
|
|
157
|
-
enumerable: true,
|
|
158
|
-
get: function () {
|
|
159
|
-
return _onairosApi.getPlatformData;
|
|
160
|
-
}
|
|
161
|
-
});
|
|
162
|
-
Object.defineProperty(exports, "getUserProfile", {
|
|
163
|
-
enumerable: true,
|
|
164
|
-
get: function () {
|
|
165
|
-
return _onairosApi.getUserProfile;
|
|
166
|
-
}
|
|
167
|
-
});
|
|
168
|
-
Object.defineProperty(exports, "hasCredentials", {
|
|
169
|
-
enumerable: true,
|
|
170
|
-
get: function () {
|
|
171
|
-
return _secureStorage.hasCredentials;
|
|
172
|
-
}
|
|
173
|
-
});
|
|
174
|
-
Object.defineProperty(exports, "initializeOAuthService", {
|
|
175
|
-
enumerable: true,
|
|
176
|
-
get: function () {
|
|
177
|
-
return _oauthService.initializeOAuthService;
|
|
178
|
-
}
|
|
179
|
-
});
|
|
180
|
-
Object.defineProperty(exports, "isDebugMode", {
|
|
181
|
-
enumerable: true,
|
|
182
|
-
get: function () {
|
|
183
|
-
return _debugHelper.isDebugMode;
|
|
184
|
-
}
|
|
185
|
-
});
|
|
186
|
-
Object.defineProperty(exports, "logDebug", {
|
|
187
|
-
enumerable: true,
|
|
188
|
-
get: function () {
|
|
189
|
-
return _debugHelper.logDebug;
|
|
190
|
-
}
|
|
191
|
-
});
|
|
192
|
-
Object.defineProperty(exports, "logError", {
|
|
193
|
-
enumerable: true,
|
|
194
|
-
get: function () {
|
|
195
|
-
return _debugHelper.logError;
|
|
196
|
-
}
|
|
197
|
-
});
|
|
198
|
-
Object.defineProperty(exports, "refreshToken", {
|
|
199
|
-
enumerable: true,
|
|
200
|
-
get: function () {
|
|
201
|
-
return _onairosApi.refreshToken;
|
|
202
|
-
}
|
|
203
|
-
});
|
|
204
|
-
Object.defineProperty(exports, "rsaEncrypt", {
|
|
205
|
-
enumerable: true,
|
|
206
|
-
get: function () {
|
|
207
|
-
return _crypto.rsaEncrypt;
|
|
208
|
-
}
|
|
209
|
-
});
|
|
210
|
-
Object.defineProperty(exports, "sha256", {
|
|
211
|
-
enumerable: true,
|
|
212
|
-
get: function () {
|
|
213
|
-
return _crypto.sha256;
|
|
214
|
-
}
|
|
215
|
-
});
|
|
216
|
-
Object.defineProperty(exports, "storeCredentials", {
|
|
217
|
-
enumerable: true,
|
|
218
|
-
get: function () {
|
|
219
|
-
return _secureStorage.storeCredentials;
|
|
220
|
-
}
|
|
221
|
-
});
|
|
222
|
-
Object.defineProperty(exports, "storePlatformConnection", {
|
|
223
|
-
enumerable: true,
|
|
224
|
-
get: function () {
|
|
225
|
-
return _oauthService.storePlatformConnection;
|
|
226
|
-
}
|
|
227
|
-
});
|
|
228
|
-
Object.defineProperty(exports, "updateCredentials", {
|
|
229
|
-
enumerable: true,
|
|
230
|
-
get: function () {
|
|
231
|
-
return _secureStorage.updateCredentials;
|
|
232
|
-
}
|
|
233
|
-
});
|
|
234
|
-
Object.defineProperty(exports, "updatePlatformConnections", {
|
|
235
|
-
enumerable: true,
|
|
236
|
-
get: function () {
|
|
237
|
-
return _onairosApi.updatePlatformConnections;
|
|
238
|
-
}
|
|
239
|
-
});
|
|
240
|
-
Object.defineProperty(exports, "useConnections", {
|
|
241
|
-
enumerable: true,
|
|
242
|
-
get: function () {
|
|
243
|
-
return _useConnections.useConnections;
|
|
244
|
-
}
|
|
245
|
-
});
|
|
246
|
-
Object.defineProperty(exports, "useCredentials", {
|
|
247
|
-
enumerable: true,
|
|
248
|
-
get: function () {
|
|
249
|
-
return _useCredentials.useCredentials;
|
|
250
|
-
}
|
|
251
|
-
});
|
|
252
|
-
Object.defineProperty(exports, "validateCredentials", {
|
|
253
|
-
enumerable: true,
|
|
254
|
-
get: function () {
|
|
255
|
-
return _onairosApi.validateCredentials;
|
|
256
|
-
}
|
|
257
|
-
});
|
|
258
|
-
Object.defineProperty(exports, "verifyCredentials", {
|
|
259
|
-
enumerable: true,
|
|
260
|
-
get: function () {
|
|
261
|
-
return _secureStorage.verifyCredentials;
|
|
262
|
-
}
|
|
263
|
-
});
|
|
264
|
-
var _OnairosButton = require("./components/OnairosButton");
|
|
265
|
-
var _UniversalOnboarding = require("./components/UniversalOnboarding");
|
|
266
|
-
var _Overlay = require("./components/Overlay");
|
|
267
|
-
var _ConnectorScreen = require("./components/screens/ConnectorScreen");
|
|
268
|
-
var _PinCreationScreen = require("./components/screens/PinCreationScreen");
|
|
269
|
-
var _LoadingScreen = require("./components/screens/LoadingScreen");
|
|
270
|
-
var _OAuthWebView = require("./components/onboarding/OAuthWebView");
|
|
271
|
-
var _PlatformConnector = require("./components/onboarding/PlatformConnector");
|
|
272
|
-
var _OnboardingHeader = require("./components/onboarding/OnboardingHeader");
|
|
273
|
-
var _PinInput = require("./components/onboarding/PinInput");
|
|
274
|
-
var _useConnections = require("./hooks/useConnections");
|
|
275
|
-
var _useCredentials = require("./hooks/useCredentials");
|
|
276
|
-
var _secureStorage = require("./utils/secureStorage");
|
|
277
|
-
var _onairosApi = require("./utils/onairosApi");
|
|
278
|
-
var _crypto = require("./utils/crypto");
|
|
279
|
-
var _debugHelper = require("./utils/debugHelper");
|
|
280
|
-
var _oauthService = require("./services/oauthService");
|
|
281
|
-
var _constants = require("./constants");
|
|
6
|
+
exports.default = exports.CryptoUtils = exports.AuthUtils = exports.ApiUtils = void 0;
|
|
7
|
+
var _OnairosButton = _interopRequireDefault(require("./components/OnairosButton"));
|
|
8
|
+
var AuthUtils = _interopRequireWildcard(require("./utils/auth"));
|
|
9
|
+
exports.AuthUtils = AuthUtils;
|
|
10
|
+
var CryptoUtils = _interopRequireWildcard(require("./utils/crypto"));
|
|
11
|
+
exports.CryptoUtils = CryptoUtils;
|
|
12
|
+
var ApiUtils = _interopRequireWildcard(require("./utils/api"));
|
|
13
|
+
exports.ApiUtils = ApiUtils;
|
|
14
|
+
function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r = new WeakMap(), n = new WeakMap(); return (_interopRequireWildcard = function (e, t) { if (!t && e && e.__esModule) return e; var o, i, f = { __proto__: null, default: e }; if (null === e || "object" != typeof e && "function" != typeof e) return f; if (o = t ? n : r) { if (o.has(e)) return o.get(e); o.set(e, f); } for (const t in e) "default" !== t && {}.hasOwnProperty.call(e, t) && ((i = (o = Object.defineProperty) && Object.getOwnPropertyDescriptor(e, t)) && (i.get || i.set) ? o(f, t, i) : f[t] = e[t]); return f; })(e, t); }
|
|
15
|
+
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
|
16
|
+
// Export the main component
|
|
17
|
+
var _default = exports.default = _OnairosButton.default; // Export utilities for advanced usage
|
|
282
18
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["_OnairosButton","require","
|
|
1
|
+
{"version":3,"names":["_OnairosButton","_interopRequireDefault","require","AuthUtils","_interopRequireWildcard","exports","CryptoUtils","ApiUtils","e","t","WeakMap","r","n","__esModule","o","i","f","__proto__","default","has","get","set","hasOwnProperty","call","Object","defineProperty","getOwnPropertyDescriptor","_default","OnairosButton"],"sourceRoot":"..\\..\\src","sources":["index.js"],"mappings":";;;;;;AAAA,IAAAA,cAAA,GAAAC,sBAAA,CAAAC,OAAA;AACA,IAAAC,SAAA,GAAAC,uBAAA,CAAAF,OAAA;AAA0CG,OAAA,CAAAF,SAAA,GAAAA,SAAA;AAC1C,IAAAG,WAAA,GAAAF,uBAAA,CAAAF,OAAA;AAA8CG,OAAA,CAAAC,WAAA,GAAAA,WAAA;AAC9C,IAAAC,QAAA,GAAAH,uBAAA,CAAAF,OAAA;AAAwCG,OAAA,CAAAE,QAAA,GAAAA,QAAA;AAAA,SAAAH,wBAAAI,CAAA,EAAAC,CAAA,6BAAAC,OAAA,MAAAC,CAAA,OAAAD,OAAA,IAAAE,CAAA,OAAAF,OAAA,YAAAN,uBAAA,YAAAA,CAAAI,CAAA,EAAAC,CAAA,SAAAA,CAAA,IAAAD,CAAA,IAAAA,CAAA,CAAAK,UAAA,SAAAL,CAAA,MAAAM,CAAA,EAAAC,CAAA,EAAAC,CAAA,KAAAC,SAAA,QAAAC,OAAA,EAAAV,CAAA,iBAAAA,CAAA,uBAAAA,CAAA,y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