- App.tsx: full navigation (Auth stack + Main tabs with 5 screens) - Auth: LoginScreen, RegisterScreen, ForgotPasswordScreen - HomeScreen: dashboard with IoT metrics, weather widget, alerts, quick actions, sensors - MapScreen: interactive map with layer toggles (6 layers) - MarketplaceScreen: categories (6), products (5), search - ChatScreen: AI chat with quick prompts (4), bot responses - ProfileScreen: user info, stats, menu (9 items), logout - AlertsScreen: alert list with severity, acknowledge - SensorsScreen: sensor list with type filters (6 types), search - ZonesScreen: zone cards with stats - SettingsScreen: language picker (FR/EN/ES/DE), privacy, about - Stores: iotStore (sensors, zones, alerts), notificationStore, uiStore + i18n - Hooks: useSensors, useAlerts, useNotifications, useLocation - Components: Card, Button, LoadingSpinner, ErrorBoundary, Header - Services: iotService, notificationService (with axios API client) - Utils: formatters (temp, AQI, noise, dates), validators (email, password, IBAN) - Theme: colors.ts with full design system (Blue Ocean palette) - Ditto: fixed MongoDB connection, new JWT secrets, official gateway image
55 lines
1.4 KiB
JavaScript
55 lines
1.4 KiB
JavaScript
"use strict";
|
|
|
|
Object.defineProperty(exports, "__esModule", {
|
|
value: true
|
|
});
|
|
exports.parsePropertiesFile = parsePropertiesFile;
|
|
exports.propertiesListToString = propertiesListToString;
|
|
function parsePropertiesFile(contents) {
|
|
const propertiesList = [];
|
|
const lines = contents.split('\n');
|
|
for (let i = 0; i < lines.length; i++) {
|
|
const line = lines[i].trim();
|
|
if (!line) {
|
|
propertiesList.push({
|
|
type: 'empty'
|
|
});
|
|
} else if (line.startsWith('#')) {
|
|
propertiesList.push({
|
|
type: 'comment',
|
|
value: line.substring(1).trimStart()
|
|
});
|
|
} else {
|
|
const eok = line.indexOf('=');
|
|
const key = line.slice(0, eok);
|
|
const value = line.slice(eok + 1, line.length);
|
|
propertiesList.push({
|
|
type: 'property',
|
|
key,
|
|
value
|
|
});
|
|
}
|
|
}
|
|
return propertiesList;
|
|
}
|
|
function propertiesListToString(props) {
|
|
let output = '';
|
|
for (let i = 0; i < props.length; i++) {
|
|
const prop = props[i];
|
|
if (prop.type === 'empty') {
|
|
output += '';
|
|
} else if (prop.type === 'comment') {
|
|
output += '# ' + prop.value;
|
|
} else if (prop.type === 'property') {
|
|
output += `${prop.key}=${prop.value}`;
|
|
} else {
|
|
// @ts-ignore: assertion
|
|
throw new Error(`Invalid properties type "${prop.type}"`);
|
|
}
|
|
if (i < props.length - 1) {
|
|
output += '\n';
|
|
}
|
|
}
|
|
return output;
|
|
}
|
|
//# sourceMappingURL=Properties.js.map
|