forked from Blendman974/faceclaw
Refactor (move some files around)
This commit is contained in:
1 parent
bcb162ecaf
commit
ef6cb3bf55
13 files changed
+10
-10
No files matched your search
+1
-1
@@ -1,2 +1,2 @@
|
|||||||
<Frame defaultPage="launch-page">
|
<Frame defaultPage="phone-ui/launch-page">
|
||||||
</Frame>
|
</Frame>
|
||||||
File renamed without changes.
File renamed without changes.
@@ -1,8 +1,8 @@
|
|||||||
import { Frame, Observable } from "@nativescript/core";
|
import { Frame, Observable } from "@nativescript/core";
|
||||||
|
|
||||||
import { ensureBlePermissions } from "./g2/android-permissions";
|
import { ensureBlePermissions } from "../g2/android-permissions";
|
||||||
import { isValidMacAddress, loadDeviceAddresses, normalizeMacAddress, saveDeviceAddresses } from "./g2/device-addresses";
|
import { isValidMacAddress, loadDeviceAddresses, normalizeMacAddress, saveDeviceAddresses } from "../g2/device-addresses";
|
||||||
import { buildAddressSet, DeviceDiscoveryBridge } from "./native/device-discovery";
|
import { buildAddressSet, DeviceDiscoveryBridge } from "../native/device-discovery";
|
||||||
|
|
||||||
type TextChangeArgs = { value?: string; object?: { text?: string } };
|
type TextChangeArgs = { value?: string; object?: { text?: string } };
|
||||||
|
|
||||||
@@ -112,7 +112,7 @@ export class ConfigViewModel extends Observable {
|
|||||||
|
|
||||||
onBackTap(): void {
|
onBackTap(): void {
|
||||||
Frame.topmost()?.navigate({
|
Frame.topmost()?.navigate({
|
||||||
moduleName: "main-page",
|
moduleName: "phone-ui/main-page",
|
||||||
clearHistory: true,
|
clearHistory: true,
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
@@ -6,7 +6,7 @@ export function navigatingTo(args: EventData): void {
|
|||||||
const page = args.object as Page;
|
const page = args.object as Page;
|
||||||
page.on(Page.loadedEvent, () => {
|
page.on(Page.loadedEvent, () => {
|
||||||
Frame.topmost()?.navigate({
|
Frame.topmost()?.navigate({
|
||||||
moduleName: hasCompletedOnboarding() ? "main-page" : "onboarding-page",
|
moduleName: hasCompletedOnboarding() ? "phone-ui/main-page" : "phone-ui/onboarding-page",
|
||||||
clearHistory: true,
|
clearHistory: true,
|
||||||
animated: false,
|
animated: false,
|
||||||
});
|
});
|
||||||
File renamed without changes.
@@ -1,6 +1,6 @@
|
|||||||
import { Color, EventData, isAndroid, Observable, Page, ScrollView, TextField } from '@nativescript/core'
|
import { Color, EventData, isAndroid, Observable, Page, ScrollView, TextField } from '@nativescript/core'
|
||||||
import { MainViewModel } from './main-view-model'
|
import { MainViewModel } from './main-view-model'
|
||||||
import { dashboardController } from './g2/dashboard-controller'
|
import { dashboardController } from '../g2/dashboard-controller'
|
||||||
|
|
||||||
const SETTINGS_TEXT_COLOR = new Color('#222222')
|
const SETTINGS_TEXT_COLOR = new Color('#222222')
|
||||||
const SETTINGS_BACKGROUND_COLOR = new Color('#ffffff')
|
const SETTINGS_BACKGROUND_COLOR = new Color('#ffffff')
|
||||||
File renamed without changes.
@@ -1,5 +1,5 @@
|
|||||||
import { Frame, ImageSource, Observable, Screen } from "@nativescript/core";
|
import { Frame, ImageSource, Observable, Screen } from "@nativescript/core";
|
||||||
import { dashboardController, type TextSettingEditorKind } from "./g2/dashboard-controller";
|
import { dashboardController, type TextSettingEditorKind } from "../g2/dashboard-controller";
|
||||||
|
|
||||||
export class MainViewModel extends Observable {
|
export class MainViewModel extends Observable {
|
||||||
private _status = "Disconnected.";
|
private _status = "Disconnected.";
|
||||||
@@ -247,7 +247,7 @@ export class MainViewModel extends Observable {
|
|||||||
|
|
||||||
onConfigureTap(): void {
|
onConfigureTap(): void {
|
||||||
if (!this.canRun) return;
|
if (!this.canRun) return;
|
||||||
Frame.topmost()?.navigate("config-page");
|
Frame.topmost()?.navigate("phone-ui/config-page");
|
||||||
}
|
}
|
||||||
|
|
||||||
onToggleLogTap(): void {
|
onToggleLogTap(): void {
|
||||||
File renamed without changes.
File renamed without changes.
File renamed without changes.
@@ -69,7 +69,7 @@ export class OnboardingViewModel extends Observable {
|
|||||||
}
|
}
|
||||||
setOnboardingCompleted(true);
|
setOnboardingCompleted(true);
|
||||||
Frame.topmost()?.navigate({
|
Frame.topmost()?.navigate({
|
||||||
moduleName: "config-page",
|
moduleName: "phone-ui/config-page",
|
||||||
clearHistory: true,
|
clearHistory: true,
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
Reference in new issue
Block a user