@controleonline/ui-common 1.2.70 → 1.2.75
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/.github/actions/workers/manager/action.yml +147 -0
- package/.github/actions/workers/qa/action.yml +44 -0
- package/.github/actions/workers/security/action.yml +44 -0
- package/.github/actions/workers/technical-documenter/action.yml +51 -0
- package/.github/workflows/manager-worker.yml +168 -0
- package/.github/workflows/publish-npm.yml +45 -0
- package/.gitmodules +3 -0
- package/AGENTS.md +6 -0
- package/README.md +14 -0
- package/package.json +32 -28
- package/src/api/fetch.js +1 -1
- package/src/api/index.js +328 -58
- package/src/react/components/AddImportModal.js +95 -111
- package/src/react/components/AnimatedModal.js +171 -0
- package/src/react/components/AnimatedModal.styles.js +21 -0
- package/src/react/components/AppTypeSwitcher.js +164 -0
- package/src/react/components/AppTypeSwitcher.styles.js +109 -0
- package/src/react/components/BackgroundRuntimeBridge.js +5 -4
- package/src/react/components/BottomNavigationBar.config.js +211 -231
- package/src/react/components/BottomNavigationBar.js +86 -31
- package/src/react/components/BottomNavigationBar.styles.js +118 -110
- package/src/react/components/CategoryForm.js +52 -35
- package/src/react/components/DefaultProvider.native.js +194 -156
- package/src/react/components/DefaultProvider.web.js +188 -112
- package/src/react/components/DeliveryPushBridge.native.js +2 -2
- package/src/react/components/DeviceAlertSoundService.js +3 -3
- package/src/react/components/KioskModeBridge.js +2 -2
- package/src/react/components/LauncherModeBridge.js +2 -2
- package/src/react/components/ManagerPushBridge.native.js +2 -2
- package/src/react/components/NetworkPrinterPreviewModal.js +249 -0
- package/src/react/components/NetworkPrinterPreviewModal.styles.js +159 -0
- package/src/react/components/RemoteCheckoutService.js +28 -20
- package/src/react/components/RuntimeBottomNavigationBar.js +146 -119
- package/src/react/components/RuntimeInfoFooter.js +137 -45
- package/src/react/components/RuntimeInfoFooter.styles.js +3 -0
- package/src/react/components/StateStore.js +258 -0
- package/src/react/components/UnifiedPaymentBar.js +7 -4
- package/src/react/components/UserAvatar.js +160 -0
- package/src/react/components/WebsocketListener.native.js +11 -11
- package/src/react/components/integrations/IntegrationHero/index.js +48 -0
- package/src/react/components/integrations/IntegrationHero/styles.js +57 -0
- package/src/react/components/integrations/IntegrationTabs/index.js +89 -0
- package/src/react/components/integrations/IntegrationTabs/styles.js +44 -0
- package/src/react/config/deviceConfigBootstrap.js +71 -30
- package/src/react/css/orders.js +72 -0
- package/src/react/pages/Connections.js +229 -0
- package/src/react/pages/Connections.styles.js +222 -0
- package/src/react/pages/DeviceDetailPage.js +2814 -0
- package/src/react/pages/DeviceDetailPage.styles.js +308 -0
- package/src/react/pages/Devices/currentDevice.js +194 -0
- package/src/react/pages/Devices/deviceTypes/DeviceGroupCard.js +257 -0
- package/src/react/pages/Devices/deviceTypes/all.js +23 -0
- package/src/react/pages/Devices/deviceTypes/device.js +25 -0
- package/src/react/pages/Devices/deviceTypes/deviceListHelpers.js +178 -0
- package/src/react/pages/Devices/deviceTypes/display.js +26 -0
- package/src/react/pages/Devices/deviceTypes/index.js +145 -0
- package/src/react/pages/Devices/deviceTypes/ipCamera.js +35 -0
- package/src/react/pages/Devices/deviceTypes/pdv.js +88 -0
- package/src/react/pages/Devices/deviceTypes/printer.js +37 -0
- package/src/react/pages/Devices/deviceTypes/shared.js +453 -0
- package/src/react/pages/Devices/deviceTypes/useDeviceNetworkConnectivity.js +145 -0
- package/src/react/pages/Devices.js +183 -0
- package/src/react/pages/Devices.styles.js +353 -0
- package/src/react/pages/Food99IntegrationPage/components/Food99CatalogTab.js +219 -0
- package/src/react/pages/Food99IntegrationPage/components/Food99OverviewTab.js +134 -0
- package/src/react/pages/Food99IntegrationPage/components/Food99PreviewModal.js +173 -0
- package/src/react/pages/Food99IntegrationPage/components/Food99ProductCard.js +1 -0
- package/src/react/pages/Food99IntegrationPage/components/Food99QuickWalletModal.js +181 -0
- package/src/react/pages/Food99IntegrationPage/components/Food99SettingsTab.js +306 -0
- package/src/react/pages/Food99IntegrationPage/components/Food99StoreTab.js +417 -0
- package/src/react/pages/Food99IntegrationPage/index.js +1530 -0
- package/src/react/pages/Food99IntegrationPage/styles.js +792 -0
- package/src/react/pages/Food99IntegrationPage/utils.js +155 -0
- package/src/react/pages/Food99IntegrationPage.js +1 -0
- package/src/react/pages/Food99IntegrationPage.styles.js +1 -0
- package/src/react/pages/GenericLogPage.js +42 -167
- package/src/react/pages/IFoodIntegrationPage/components/IFoodCatalogTab.js +8 -0
- package/src/react/pages/IFoodIntegrationPage/components/IFoodOperationsTab.js +420 -0
- package/src/react/pages/IFoodIntegrationPage/components/IFoodOverviewTab.js +118 -0
- package/src/react/pages/IFoodIntegrationPage/components/IFoodPreviewModal.js +103 -0
- package/src/react/pages/IFoodIntegrationPage/components/IFoodProductCard.js +1 -0
- package/src/react/pages/IFoodIntegrationPage/components/IFoodStoreTab.js +150 -0
- package/src/react/pages/IFoodIntegrationPage/index.js +1298 -0
- package/src/react/pages/IFoodIntegrationPage/styles.js +764 -0
- package/src/react/pages/IFoodIntegrationPage/utils.js +91 -0
- package/src/react/pages/IFoodIntegrationPage.js +1 -0
- package/src/react/pages/IFoodIntegrationPage.styles.js +1 -0
- package/src/react/pages/Imports.js +214 -166
- package/src/react/pages/IntegrationConfigPage.js +744 -0
- package/src/react/pages/IntegrationConfigPage.styles.js +269 -0
- package/src/react/pages/Integrations.js +299 -0
- package/src/react/pages/Integrations.styles.js +130 -0
- package/src/react/pages/ManagerOrderNotificationsPage.js +642 -0
- package/src/react/pages/MarketplaceIntegrationPage/components/MarketplaceProductCard.js +205 -0
- package/src/react/pages/MarketplaceIntegrationPage/components/RemoteMarketplaceMenuTab.js +335 -0
- package/src/react/pages/MarketplaceIntegrationPage/index.js +60 -0
- package/src/react/pages/MarketplaceIntegrationPage/utils.js +137 -0
- package/src/react/pages/MercadoLivreIntegrationPage.js +538 -0
- package/src/react/pages/PrinterDeviceDetailPage.js +1916 -0
- package/src/react/pages/PrinterDeviceDetailPage.styles.js +223 -0
- package/src/react/pages/PrinterDeviceFormPage.js +521 -0
- package/src/react/pages/PrinterDeviceFormPage.styles.js +159 -0
- package/src/react/pages/SettingsPage/PaymentTypesByWalletTab.js +484 -454
- package/src/react/pages/SettingsPage/index.js +1266 -1167
- package/src/react/pages/WhatsAppConnectionPage.js +459 -0
- package/src/react/pages/WhatsAppConnectionPage.styles.js +284 -0
- package/src/react/pages/integrationsCatalog.js +399 -0
- package/src/react/print/providers/local.js +1 -1
- package/src/react/router/publicRoutes.js +25 -0
- package/src/react/services/Cielo/Checkout.js +39 -0
- package/src/react/services/Cielo/Cielo.js +193 -0
- package/src/react/services/Cielo/Print.js +7 -0
- package/src/react/services/InfinitePay/Checkout.js +33 -0
- package/src/react/services/InfinitePay/InfinitePay.js +24 -0
- package/src/react/{utils → services}/paymentGatewayExecution.js +91 -91
- package/src/react/styles/global.js +115 -0
- package/src/react/utils/categoryContexts.js +46 -0
- package/src/react/utils/entityDisplay.js +222 -217
- package/src/react/utils/fileUrl.js +201 -16
- package/src/react/utils/integrationPage.js +16 -0
- package/src/react/utils/menuNavigation.js +31 -0
- package/src/react/utils/orderIdentity.js +277 -0
- package/src/react/utils/remotePayment.js +115 -61
- package/src/react/utils/runtimeFooter.js +40 -22
- package/src/react/utils/runtimeLanguage.js +50 -9
- package/src/react/utils/runtimeMenu.js +190 -98
- package/src/react/utils/runtimeZoom.js +43 -0
- package/src/react/utils/shopConfig.js +72 -34
- package/src/react/utils/shopFranchises.js +182 -23
- package/src/react/utils/socketRuntimePipeline.js +14 -14
- package/src/react/utils/storeColumns.js +23 -4
- package/src/react/utils/userAvatar.js +104 -0
- package/src/store/categories/index.js +48 -20
- package/src/store/configs/index.js +2 -2
- package/src/store/device_config/index.js +62 -21
- package/src/store/entity_log/index.js +22 -1
- package/src/store/imports/customActions.js +51 -0
- package/src/store/imports/index.js +89 -88
- package/src/store/status/index.js +11 -11
- package/src/store/themes/index.js +22 -0
- package/src/store/timezones/index.js +3 -1
- package/src/tests/browser/manager/connections.spec.js +143 -0
- package/src/tests/browser/manager/devices-current.spec.js +343 -0
- package/src/tests/browser/manager/mercado-livre-integration.spec.js +268 -0
- package/src/tests/react/api/deviceHeaders.test.js +114 -0
- package/src/tests/react/api/loadSmokeIndex.test.js +75 -0
- package/src/tests/react/components/AddImportModal.test.js +166 -0
- package/src/tests/react/components/BottomNavigationBar.config.test.js +20 -0
- package/src/tests/react/components/UserAvatar.test.js +52 -0
- package/src/tests/react/config/deviceConfigBootstrap.test.js +47 -0
- package/src/tests/react/pages/DevicePickerStyles.test.js +47 -0
- package/src/tests/react/pages/Devices/deviceListHelpers.test.js +39 -0
- package/src/tests/react/pages/DevicesCurrentDevice.test.js +198 -0
- package/src/tests/react/pages/connectionsHelpers.test.js +34 -0
- package/src/tests/react/pages/mercadoLivreIntegrationPageContract.test.mjs +16 -0
- package/src/tests/react/print/localPrintProvider.test.js +1 -1
- package/src/tests/react/services/Cielo.test.js +190 -0
- package/src/tests/react/store/categoriesOrdering.test.js +26 -0
- package/src/tests/react/utils/appDomain.test.js +62 -0
- package/src/tests/react/utils/entityDisplay.test.js +2 -2
- package/src/tests/react/utils/fileUrl.test.js +62 -0
- package/src/tests/react/utils/formatter.test.mjs +33 -0
- package/src/tests/react/utils/importStatus.test.js +2 -2
- package/src/tests/react/utils/orderIdentity.test.js +139 -0
- package/src/tests/react/utils/remotePayment.test.js +62 -0
- package/src/tests/react/utils/runtimeFooter.test.js +32 -9
- package/src/tests/react/utils/runtimeLanguage.test.js +80 -10
- package/src/tests/react/utils/runtimeMenu.test.js +195 -111
- package/src/tests/react/utils/runtimeZoom.test.js +38 -0
- package/src/tests/react/utils/shopConfig.test.js +75 -0
- package/src/tests/react/utils/shopFranchises.test.js +122 -12
- package/src/tests/react/utils/translate.discovery.test.mjs +170 -0
- package/src/tests/react/utils/translate.test.helpers.mjs +152 -0
- package/src/tests/react/utils/translate.test.mjs +252 -396
- package/src/tests/react/utils/userAvatar.test.js +63 -0
- package/src/utils/appDomain.js +15 -4
- package/src/utils/formatter.js +122 -16
- package/src/utils/integrationConfigs.js +1 -0
- package/src/utils/translate.js +277 -398
- package/src/utils/translateDiscovery.js +96 -0
- package/src/utils/translateNormalize.js +33 -0
- package/src/utils/translatePending.js +92 -0
- package/src/utils/translateStorage.js +142 -0
- package/.github/agents/developer.agent.md +0 -30
- package/.github/agents/devops.agent.md +0 -30
- package/.github/agents/qa.agent.md +0 -30
- package/.github/agents/security.agent.md +0 -30
- package/.github/workflows/npmjs.yml +0 -35
|
@@ -0,0 +1,223 @@
|
|
|
1
|
+
import {Platform, StyleSheet} from 'react-native';
|
|
2
|
+
|
|
3
|
+
const cardShadow = Platform.select({
|
|
4
|
+
ios: {
|
|
5
|
+
shadowColor: '#0F172A',
|
|
6
|
+
shadowOffset: {width: 0, height: 4},
|
|
7
|
+
shadowOpacity: 0.06,
|
|
8
|
+
shadowRadius: 12,
|
|
9
|
+
},
|
|
10
|
+
android: {elevation: 2},
|
|
11
|
+
web: {boxShadow: '0 4px 12px rgba(15,23,42,0.06)'},
|
|
12
|
+
});
|
|
13
|
+
|
|
14
|
+
const styles = StyleSheet.create({
|
|
15
|
+
container: {
|
|
16
|
+
flex: 1,
|
|
17
|
+
paddingHorizontal: 16,
|
|
18
|
+
paddingTop: 14,
|
|
19
|
+
},
|
|
20
|
+
scroll: {
|
|
21
|
+
paddingBottom: 28,
|
|
22
|
+
gap: 12,
|
|
23
|
+
},
|
|
24
|
+
heroCard: {
|
|
25
|
+
backgroundColor: '#fff',
|
|
26
|
+
borderRadius: 18,
|
|
27
|
+
padding: 16,
|
|
28
|
+
flexDirection: 'row',
|
|
29
|
+
alignItems: 'center',
|
|
30
|
+
gap: 14,
|
|
31
|
+
...cardShadow,
|
|
32
|
+
},
|
|
33
|
+
heroIcon: {
|
|
34
|
+
width: 44,
|
|
35
|
+
height: 44,
|
|
36
|
+
borderRadius: 12,
|
|
37
|
+
alignItems: 'center',
|
|
38
|
+
justifyContent: 'center',
|
|
39
|
+
},
|
|
40
|
+
heroCopy: {
|
|
41
|
+
flex: 1,
|
|
42
|
+
gap: 4,
|
|
43
|
+
},
|
|
44
|
+
heroTitle: {
|
|
45
|
+
fontSize: 17,
|
|
46
|
+
fontWeight: '800',
|
|
47
|
+
color: '#0F172A',
|
|
48
|
+
},
|
|
49
|
+
heroText: {
|
|
50
|
+
fontSize: 12,
|
|
51
|
+
lineHeight: 18,
|
|
52
|
+
color: '#64748B',
|
|
53
|
+
},
|
|
54
|
+
loadingRow: {
|
|
55
|
+
flexDirection: 'row',
|
|
56
|
+
alignItems: 'center',
|
|
57
|
+
gap: 8,
|
|
58
|
+
},
|
|
59
|
+
loadingText: {
|
|
60
|
+
fontSize: 12,
|
|
61
|
+
color: '#64748B',
|
|
62
|
+
fontWeight: '600',
|
|
63
|
+
},
|
|
64
|
+
sectionCard: {
|
|
65
|
+
backgroundColor: '#fff',
|
|
66
|
+
borderRadius: 18,
|
|
67
|
+
padding: 16,
|
|
68
|
+
gap: 12,
|
|
69
|
+
...cardShadow,
|
|
70
|
+
},
|
|
71
|
+
sectionTitle: {
|
|
72
|
+
fontSize: 15,
|
|
73
|
+
fontWeight: '800',
|
|
74
|
+
color: '#0F172A',
|
|
75
|
+
},
|
|
76
|
+
sectionDescription: {
|
|
77
|
+
fontSize: 12,
|
|
78
|
+
lineHeight: 18,
|
|
79
|
+
color: '#64748B',
|
|
80
|
+
},
|
|
81
|
+
statusCard: {
|
|
82
|
+
borderWidth: 1,
|
|
83
|
+
borderRadius: 14,
|
|
84
|
+
paddingHorizontal: 14,
|
|
85
|
+
paddingVertical: 13,
|
|
86
|
+
flexDirection: 'row',
|
|
87
|
+
alignItems: 'center',
|
|
88
|
+
gap: 12,
|
|
89
|
+
},
|
|
90
|
+
statusCopy: {
|
|
91
|
+
flex: 1,
|
|
92
|
+
gap: 4,
|
|
93
|
+
},
|
|
94
|
+
statusTitleRow: {
|
|
95
|
+
flexDirection: 'row',
|
|
96
|
+
alignItems: 'center',
|
|
97
|
+
gap: 6,
|
|
98
|
+
},
|
|
99
|
+
statusTitle: {
|
|
100
|
+
fontSize: 14,
|
|
101
|
+
fontWeight: '800',
|
|
102
|
+
},
|
|
103
|
+
statusDescription: {
|
|
104
|
+
fontSize: 12,
|
|
105
|
+
lineHeight: 18,
|
|
106
|
+
color: '#475569',
|
|
107
|
+
},
|
|
108
|
+
fieldBlock: {
|
|
109
|
+
gap: 6,
|
|
110
|
+
},
|
|
111
|
+
fieldLabel: {
|
|
112
|
+
fontSize: 12,
|
|
113
|
+
fontWeight: '700',
|
|
114
|
+
color: '#475569',
|
|
115
|
+
},
|
|
116
|
+
input: {
|
|
117
|
+
borderWidth: 1,
|
|
118
|
+
borderColor: '#E2E8F0',
|
|
119
|
+
borderRadius: 12,
|
|
120
|
+
paddingHorizontal: 12,
|
|
121
|
+
paddingVertical: 11,
|
|
122
|
+
backgroundColor: '#F8FAFC',
|
|
123
|
+
color: '#0F172A',
|
|
124
|
+
fontSize: 14,
|
|
125
|
+
},
|
|
126
|
+
readonlyInput: {
|
|
127
|
+
color: '#475569',
|
|
128
|
+
backgroundColor: '#F1F5F9',
|
|
129
|
+
},
|
|
130
|
+
inlineFields: {
|
|
131
|
+
flexDirection: 'row',
|
|
132
|
+
gap: 10,
|
|
133
|
+
},
|
|
134
|
+
inlineField: {
|
|
135
|
+
flex: 1,
|
|
136
|
+
},
|
|
137
|
+
pickerWrap: {
|
|
138
|
+
borderWidth: 1,
|
|
139
|
+
borderColor: '#E2E8F0',
|
|
140
|
+
borderRadius: 12,
|
|
141
|
+
overflow: 'hidden',
|
|
142
|
+
backgroundColor: '#F8FAFC',
|
|
143
|
+
},
|
|
144
|
+
picker: {
|
|
145
|
+
minHeight: 44,
|
|
146
|
+
color: '#0F172A',
|
|
147
|
+
backgroundColor: '#F8FAFC',
|
|
148
|
+
fontSize: 14,
|
|
149
|
+
},
|
|
150
|
+
toggleRow: {
|
|
151
|
+
borderWidth: 1,
|
|
152
|
+
borderColor: '#E2E8F0',
|
|
153
|
+
borderRadius: 12,
|
|
154
|
+
backgroundColor: '#F8FAFC',
|
|
155
|
+
paddingHorizontal: 14,
|
|
156
|
+
paddingVertical: 12,
|
|
157
|
+
flexDirection: 'row',
|
|
158
|
+
justifyContent: 'space-between',
|
|
159
|
+
alignItems: 'center',
|
|
160
|
+
gap: 12,
|
|
161
|
+
},
|
|
162
|
+
toggleRowActive: {
|
|
163
|
+
borderColor: 'rgba(34,197,94,0.4)',
|
|
164
|
+
backgroundColor: 'rgba(34,197,94,0.08)',
|
|
165
|
+
},
|
|
166
|
+
toggleRowLabel: {
|
|
167
|
+
fontSize: 13,
|
|
168
|
+
fontWeight: '700',
|
|
169
|
+
color: '#0F172A',
|
|
170
|
+
},
|
|
171
|
+
toggleRowValue: {
|
|
172
|
+
marginTop: 4,
|
|
173
|
+
fontSize: 12,
|
|
174
|
+
color: '#64748B',
|
|
175
|
+
},
|
|
176
|
+
primaryButton: {
|
|
177
|
+
minHeight: 46,
|
|
178
|
+
borderRadius: 14,
|
|
179
|
+
alignItems: 'center',
|
|
180
|
+
justifyContent: 'center',
|
|
181
|
+
flexDirection: 'row',
|
|
182
|
+
gap: 8,
|
|
183
|
+
...cardShadow,
|
|
184
|
+
},
|
|
185
|
+
primaryButtonDisabled: {
|
|
186
|
+
opacity: 0.65,
|
|
187
|
+
},
|
|
188
|
+
primaryButtonText: {
|
|
189
|
+
fontSize: 14,
|
|
190
|
+
fontWeight: '800',
|
|
191
|
+
color: '#fff',
|
|
192
|
+
},
|
|
193
|
+
actionButtonRow: {
|
|
194
|
+
flexDirection: 'row',
|
|
195
|
+
gap: 10,
|
|
196
|
+
flexWrap: 'wrap',
|
|
197
|
+
},
|
|
198
|
+
actionButton: {
|
|
199
|
+
flex: 1,
|
|
200
|
+
minWidth: 240,
|
|
201
|
+
},
|
|
202
|
+
secondaryButton: {
|
|
203
|
+
minHeight: 40,
|
|
204
|
+
borderRadius: 12,
|
|
205
|
+
borderWidth: 1,
|
|
206
|
+
borderColor: '#CBD5E1',
|
|
207
|
+
backgroundColor: '#fff',
|
|
208
|
+
paddingHorizontal: 12,
|
|
209
|
+
alignItems: 'center',
|
|
210
|
+
justifyContent: 'center',
|
|
211
|
+
flexDirection: 'row',
|
|
212
|
+
gap: 6,
|
|
213
|
+
},
|
|
214
|
+
secondaryButtonDisabled: {
|
|
215
|
+
opacity: 0.65,
|
|
216
|
+
},
|
|
217
|
+
secondaryButtonText: {
|
|
218
|
+
fontSize: 13,
|
|
219
|
+
fontWeight: '800',
|
|
220
|
+
},
|
|
221
|
+
});
|
|
222
|
+
|
|
223
|
+
export default styles;
|