diff --git a/README.md b/README.md index 5c7bd7d9..de3ed7fd 100644 --- a/README.md +++ b/README.md @@ -6,6 +6,7 @@ - [@nstudio/nativescript-aptabase](packages/nativescript-aptabase/README.md) - [@nstudio/nativescript-barcodescanner](packages/nativescript-barcodescanner/README.md) - [@nstudio/nativescript-blur](packages/nativescript-blur/README.md) +- [@nstudio/nativescript-branch](packages/nativescript-branch/README.md) - [@nstudio/nativescript-camera-plus](packages/nativescript-camera-plus/README.md) - [@nstudio/nativescript-cardview](packages/nativescript-cardview/README.md) - [@nstudio/nativescript-carousel](packages/nativescript-carousel/README.md) diff --git a/apps/demo-angular/package.json b/apps/demo-angular/package.json index deb16b9c..cced5edd 100644 --- a/apps/demo-angular/package.json +++ b/apps/demo-angular/package.json @@ -29,7 +29,8 @@ "@nstudio/nativescript-qr": "file:../../dist/packages/nativescript-qr", "@nstudio/nativescript-tracking-transparency": "file:../../dist/packages/nativescript-tracking-transparency", "@nstudio/nativescript-walletconnect": "file:../../dist/packages/nativescript-walletconnect", - "@nstudio/nativescript-web-server": "file:../../dist/packages/nativescript-web-server" + "@nstudio/nativescript-web-server": "file:../../dist/packages/nativescript-web-server", + "@nstudio/nativescript-branch": "file:../../dist/packages/nativescript-branch" }, "devDependencies": { "@nativescript/android": "~8.9.0", diff --git a/apps/demo-angular/src/app-routing.module.ts b/apps/demo-angular/src/app-routing.module.ts index c6bd5f41..1074c1eb 100644 --- a/apps/demo-angular/src/app-routing.module.ts +++ b/apps/demo-angular/src/app-routing.module.ts @@ -4,36 +4,37 @@ import { NativeScriptRouterModule } from '@nativescript/angular'; import { HomeComponent } from './home.component'; const routes: Routes = [ - { path: '', redirectTo: '/home', pathMatch: 'full' }, - { path: 'home', component: HomeComponent }, - { path: 'nativescript-airship', loadChildren: () => import('./plugin-demos/nativescript-airship.module').then(m => m.NativescriptAirshipModule) }, - { path: 'nativescript-airship-adm', loadChildren: () => import('./plugin-demos/nativescript-airship-adm.module').then(m => m.NativescriptAirshipAdmModule) }, - { path: 'nativescript-airship-fcm', loadChildren: () => import('./plugin-demos/nativescript-airship-fcm.module').then(m => m.NativescriptAirshipFcmModule) }, - { path: 'nativescript-airship-hms', loadChildren: () => import('./plugin-demos/nativescript-airship-hms.module').then(m => m.NativescriptAirshipHmsModule) }, - { path: 'nativescript-appcues', loadChildren: () => import('./plugin-demos/nativescript-appcues.module').then(m => m.NativescriptAppcuesModule) }, - { path: 'nativescript-aptabase', loadChildren: () => import('./plugin-demos/nativescript-aptabase.module').then(m => m.NativescriptAptabaseModule) }, - { path: 'nativescript-barcodescanner', loadChildren: () => import('./plugin-demos/nativescript-barcodescanner.module').then(m => m.NativescriptBarcodescannerModule) }, - { path: 'nativescript-blur', loadChildren: () => import('./plugin-demos/nativescript-blur.module').then(m => m.NativescriptBlurModule) }, - { path: 'nativescript-camera-plus', loadChildren: () => import('./plugin-demos/nativescript-camera-plus.module').then(m => m.NativescriptCameraPlusModule) }, - { path: 'nativescript-cardview', loadChildren: () => import('./plugin-demos/nativescript-cardview.module').then(m => m.NativescriptCardviewModule) }, - { path: 'nativescript-carousel', loadChildren: () => import('./plugin-demos/nativescript-carousel.module').then(m => m.NativescriptCarouselModule) }, - { path: 'nativescript-checkbox', loadChildren: () => import('./plugin-demos/nativescript-checkbox.module').then(m => m.NativescriptCheckboxModule) }, - { path: 'nativescript-dynatrace', loadChildren: () => import('./plugin-demos/nativescript-dynatrace.module').then(m => m.NativescriptDynatraceModule) }, - { path: 'nativescript-embrace', loadChildren: () => import('./plugin-demos/nativescript-embrace.module').then(m => m.NativescriptEmbraceModule) }, - { path: 'nativescript-exoplayer', loadChildren: () => import('./plugin-demos/nativescript-exoplayer.module').then(m => m.NativescriptExoplayerModule) }, - { path: 'nativescript-fancyalert', loadChildren: () => import('./plugin-demos/nativescript-fancyalert.module').then(m => m.NativescriptFancyalertModule) }, - { path: 'nativescript-filterable-listpicker', loadChildren: () => import('./plugin-demos/nativescript-filterable-listpicker.module').then(m => m.NativescriptFilterableListpickerModule) }, - { path: 'nativescript-freshchat', loadChildren: () => import('./plugin-demos/nativescript-freshchat.module').then(m => m.NativescriptFreshchatModule) }, - { path: 'nativescript-input-mask', loadChildren: () => import('./plugin-demos/nativescript-input-mask.module').then(m => m.NativescriptInputMaskModule) }, - { path: 'nativescript-intercom', loadChildren: () => import('./plugin-demos/nativescript-intercom.module').then(m => m.NativescriptIntercomModule) }, - { path: 'nativescript-loading-indicator', loadChildren: () => import('./plugin-demos/nativescript-loading-indicator.module').then(m => m.NativescriptLoadingIndicatorModule) }, - { path: 'nativescript-onfido', loadChildren: () => import('./plugin-demos/nativescript-onfido.module').then(m => m.NativescriptOnfidoModule) }, - { path: 'nativescript-persona', loadChildren: () => import('./plugin-demos/nativescript-persona.module').then(m => m.NativescriptPersonaModule) }, - { path: 'nativescript-plaid', loadChildren: () => import('./plugin-demos/nativescript-plaid.module').then(m => m.NativescriptPlaidModule) }, - { path: 'nativescript-qr', loadChildren: () => import('./plugin-demos/nativescript-qr.module').then(m => m.NativescriptQrModule) }, - { path: 'nativescript-tracking-transparency', loadChildren: () => import('./plugin-demos/nativescript-tracking-transparency.module').then(m => m.NativescriptTrackingTransparencyModule) }, - { path: 'nativescript-walletconnect', loadChildren: () => import('./plugin-demos/nativescript-walletconnect.module').then(m => m.NativescriptWalletconnectModule) }, - { path: 'nativescript-web-server', loadChildren: () => import('./plugin-demos/nativescript-web-server.module').then(m => m.NativescriptWebServerModule) } + { path: '', redirectTo: '/home', pathMatch: 'full' }, + { path: 'home', component: HomeComponent }, + { path: 'nativescript-airship', loadChildren: () => import('./plugin-demos/nativescript-airship.module').then((m) => m.NativescriptAirshipModule) }, + { path: 'nativescript-airship-adm', loadChildren: () => import('./plugin-demos/nativescript-airship-adm.module').then((m) => m.NativescriptAirshipAdmModule) }, + { path: 'nativescript-airship-fcm', loadChildren: () => import('./plugin-demos/nativescript-airship-fcm.module').then((m) => m.NativescriptAirshipFcmModule) }, + { path: 'nativescript-airship-hms', loadChildren: () => import('./plugin-demos/nativescript-airship-hms.module').then((m) => m.NativescriptAirshipHmsModule) }, + { path: 'nativescript-appcues', loadChildren: () => import('./plugin-demos/nativescript-appcues.module').then((m) => m.NativescriptAppcuesModule) }, + { path: 'nativescript-aptabase', loadChildren: () => import('./plugin-demos/nativescript-aptabase.module').then((m) => m.NativescriptAptabaseModule) }, + { path: 'nativescript-barcodescanner', loadChildren: () => import('./plugin-demos/nativescript-barcodescanner.module').then((m) => m.NativescriptBarcodescannerModule) }, + { path: 'nativescript-blur', loadChildren: () => import('./plugin-demos/nativescript-blur.module').then((m) => m.NativescriptBlurModule) }, + { path: 'nativescript-branch', loadChildren: () => import('./plugin-demos/nativescript-branch.module').then((m) => m.NativescriptBranchModule) }, + { path: 'nativescript-camera-plus', loadChildren: () => import('./plugin-demos/nativescript-camera-plus.module').then((m) => m.NativescriptCameraPlusModule) }, + { path: 'nativescript-cardview', loadChildren: () => import('./plugin-demos/nativescript-cardview.module').then((m) => m.NativescriptCardviewModule) }, + { path: 'nativescript-carousel', loadChildren: () => import('./plugin-demos/nativescript-carousel.module').then((m) => m.NativescriptCarouselModule) }, + { path: 'nativescript-checkbox', loadChildren: () => import('./plugin-demos/nativescript-checkbox.module').then((m) => m.NativescriptCheckboxModule) }, + { path: 'nativescript-dynatrace', loadChildren: () => import('./plugin-demos/nativescript-dynatrace.module').then((m) => m.NativescriptDynatraceModule) }, + { path: 'nativescript-embrace', loadChildren: () => import('./plugin-demos/nativescript-embrace.module').then((m) => m.NativescriptEmbraceModule) }, + { path: 'nativescript-exoplayer', loadChildren: () => import('./plugin-demos/nativescript-exoplayer.module').then((m) => m.NativescriptExoplayerModule) }, + { path: 'nativescript-fancyalert', loadChildren: () => import('./plugin-demos/nativescript-fancyalert.module').then((m) => m.NativescriptFancyalertModule) }, + { path: 'nativescript-filterable-listpicker', loadChildren: () => import('./plugin-demos/nativescript-filterable-listpicker.module').then((m) => m.NativescriptFilterableListpickerModule) }, + { path: 'nativescript-freshchat', loadChildren: () => import('./plugin-demos/nativescript-freshchat.module').then((m) => m.NativescriptFreshchatModule) }, + { path: 'nativescript-input-mask', loadChildren: () => import('./plugin-demos/nativescript-input-mask.module').then((m) => m.NativescriptInputMaskModule) }, + { path: 'nativescript-intercom', loadChildren: () => import('./plugin-demos/nativescript-intercom.module').then((m) => m.NativescriptIntercomModule) }, + { path: 'nativescript-loading-indicator', loadChildren: () => import('./plugin-demos/nativescript-loading-indicator.module').then((m) => m.NativescriptLoadingIndicatorModule) }, + { path: 'nativescript-onfido', loadChildren: () => import('./plugin-demos/nativescript-onfido.module').then((m) => m.NativescriptOnfidoModule) }, + { path: 'nativescript-persona', loadChildren: () => import('./plugin-demos/nativescript-persona.module').then((m) => m.NativescriptPersonaModule) }, + { path: 'nativescript-plaid', loadChildren: () => import('./plugin-demos/nativescript-plaid.module').then((m) => m.NativescriptPlaidModule) }, + { path: 'nativescript-qr', loadChildren: () => import('./plugin-demos/nativescript-qr.module').then((m) => m.NativescriptQrModule) }, + { path: 'nativescript-tracking-transparency', loadChildren: () => import('./plugin-demos/nativescript-tracking-transparency.module').then((m) => m.NativescriptTrackingTransparencyModule) }, + { path: 'nativescript-walletconnect', loadChildren: () => import('./plugin-demos/nativescript-walletconnect.module').then((m) => m.NativescriptWalletconnectModule) }, + { path: 'nativescript-web-server', loadChildren: () => import('./plugin-demos/nativescript-web-server.module').then((m) => m.NativescriptWebServerModule) }, ]; @NgModule({ diff --git a/apps/demo-angular/src/home.component.ts b/apps/demo-angular/src/home.component.ts index 0ca7b493..65e32076 100644 --- a/apps/demo-angular/src/home.component.ts +++ b/apps/demo-angular/src/home.component.ts @@ -6,89 +6,92 @@ import { Component } from '@angular/core'; }) export class HomeComponent { demos = [ - { - name: 'nativescript-airship' - }, - { - name: 'nativescript-airship-adm' - }, - { - name: 'nativescript-airship-fcm' - }, - { - name: 'nativescript-airship-hms' - }, - { - name: 'nativescript-appcues' - }, - { - name: 'nativescript-aptabase' - }, - { - name: 'nativescript-barcodescanner' - }, - { - name: 'nativescript-blur' - }, - { - name: 'nativescript-camera-plus' - }, - { - name: 'nativescript-cardview' - }, - { - name: 'nativescript-carousel' - }, - { - name: 'nativescript-checkbox' - }, - { - name: 'nativescript-dynatrace' - }, - { - name: 'nativescript-embrace' - }, - { - name: 'nativescript-exoplayer' - }, - { - name: 'nativescript-fancyalert' - }, - { - name: 'nativescript-filterable-listpicker' - }, - { - name: 'nativescript-freshchat' - }, - { - name: 'nativescript-input-mask' - }, - { - name: 'nativescript-intercom' - }, - { - name: 'nativescript-loading-indicator' - }, - { - name: 'nativescript-onfido' - }, - { - name: 'nativescript-persona' - }, - { - name: 'nativescript-plaid' - }, - { - name: 'nativescript-qr' - }, - { - name: 'nativescript-tracking-transparency' - }, - { - name: 'nativescript-walletconnect' - }, - { - name: 'nativescript-web-server' - } -]; -} \ No newline at end of file + { + name: 'nativescript-airship', + }, + { + name: 'nativescript-airship-adm', + }, + { + name: 'nativescript-airship-fcm', + }, + { + name: 'nativescript-airship-hms', + }, + { + name: 'nativescript-appcues', + }, + { + name: 'nativescript-aptabase', + }, + { + name: 'nativescript-barcodescanner', + }, + { + name: 'nativescript-blur', + }, + { + name: 'nativescript-branch', + }, + { + name: 'nativescript-camera-plus', + }, + { + name: 'nativescript-cardview', + }, + { + name: 'nativescript-carousel', + }, + { + name: 'nativescript-checkbox', + }, + { + name: 'nativescript-dynatrace', + }, + { + name: 'nativescript-embrace', + }, + { + name: 'nativescript-exoplayer', + }, + { + name: 'nativescript-fancyalert', + }, + { + name: 'nativescript-filterable-listpicker', + }, + { + name: 'nativescript-freshchat', + }, + { + name: 'nativescript-input-mask', + }, + { + name: 'nativescript-intercom', + }, + { + name: 'nativescript-loading-indicator', + }, + { + name: 'nativescript-onfido', + }, + { + name: 'nativescript-persona', + }, + { + name: 'nativescript-plaid', + }, + { + name: 'nativescript-qr', + }, + { + name: 'nativescript-tracking-transparency', + }, + { + name: 'nativescript-walletconnect', + }, + { + name: 'nativescript-web-server', + }, + ]; +} diff --git a/apps/demo-angular/src/plugin-demos/nativescript-branch.component.html b/apps/demo-angular/src/plugin-demos/nativescript-branch.component.html new file mode 100644 index 00000000..ce9fe7f7 --- /dev/null +++ b/apps/demo-angular/src/plugin-demos/nativescript-branch.component.html @@ -0,0 +1,8 @@ + + + + + + + + diff --git a/apps/demo-angular/src/plugin-demos/nativescript-branch.component.ts b/apps/demo-angular/src/plugin-demos/nativescript-branch.component.ts new file mode 100644 index 00000000..69b61a69 --- /dev/null +++ b/apps/demo-angular/src/plugin-demos/nativescript-branch.component.ts @@ -0,0 +1,17 @@ +import { Component, NgZone } from '@angular/core'; +import { DemoSharedNativescriptBranch } from '@demo/shared'; +import {} from '@nstudio/nativescript-branch'; + +@Component({ + selector: 'demo-nativescript-branch', + templateUrl: 'nativescript-branch.component.html', +}) +export class NativescriptBranchComponent { + demoShared: DemoSharedNativescriptBranch; + + constructor(private _ngZone: NgZone) {} + + ngOnInit() { + this.demoShared = new DemoSharedNativescriptBranch(); + } +} diff --git a/apps/demo-angular/src/plugin-demos/nativescript-branch.module.ts b/apps/demo-angular/src/plugin-demos/nativescript-branch.module.ts new file mode 100644 index 00000000..8295a4f0 --- /dev/null +++ b/apps/demo-angular/src/plugin-demos/nativescript-branch.module.ts @@ -0,0 +1,10 @@ +import { NgModule, NO_ERRORS_SCHEMA } from '@angular/core'; +import { NativeScriptCommonModule, NativeScriptRouterModule } from '@nativescript/angular'; +import { NativescriptBranchComponent } from './nativescript-branch.component'; + +@NgModule({ + imports: [NativeScriptCommonModule, NativeScriptRouterModule.forChild([{ path: '', component: NativescriptBranchComponent }])], + declarations: [NativescriptBranchComponent], + schemas: [NO_ERRORS_SCHEMA], +}) +export class NativescriptBranchModule {} diff --git a/apps/demo-angular/tsconfig.json b/apps/demo-angular/tsconfig.json index a87eb737..0fcbf0c7 100644 --- a/apps/demo-angular/tsconfig.json +++ b/apps/demo-angular/tsconfig.json @@ -34,7 +34,8 @@ "@nstudio/nativescript-freshchat": ["../../packages/nativescript-freshchat/index.d.ts"], "@nstudio/nativescript-persona": ["../../packages/nativescript-persona/index.d.ts"], "@nstudio/nativescript-walletconnect": ["../../packages/nativescript-walletconnect/index.d.ts"], - "@nstudio/nativescript-web-server": ["../../packages/nativescript-web-server/index.d.ts"] + "@nstudio/nativescript-web-server": ["../../packages/nativescript-web-server/index.d.ts"], + "@nstudio/nativescript-branch": ["../../packages/nativescript-branch/index.d.ts"] } }, "files": ["./references.d.ts", "./src/main.ts", "./src/polyfills.ts"], diff --git a/apps/demo/package.json b/apps/demo/package.json index 66209af2..758e434f 100644 --- a/apps/demo/package.json +++ b/apps/demo/package.json @@ -16,8 +16,8 @@ "@nstudio/nativescript-cardview": "file:../../packages/nativescript-cardview", "@nstudio/nativescript-carousel": "file:../../packages/nativescript-carousel", "@nstudio/nativescript-checkbox": "file:../../packages/nativescript-checkbox", - "@nstudio/nativescript-dynatrace": "file:../../packages/nativescript-dynatrace", - "@nstudio/nativescript-embrace": "file:../../packages/nativescript-embrace", + "@nstudio/nativescript-dynatrace": "file:../../dist/packages/nativescript-dynatrace", + "@nstudio/nativescript-embrace": "file:../../dist/packages/nativescript-embrace", "@nstudio/nativescript-exoplayer": "file:../../packages/nativescript-exoplayer", "@nstudio/nativescript-fancyalert": "file:../../packages/nativescript-fancyalert", "@nstudio/nativescript-filterable-listpicker": "file:../../packages/nativescript-filterable-listpicker", @@ -30,7 +30,8 @@ "@nstudio/nativescript-qr": "file:../../packages/nativescript-qr", "@nstudio/nativescript-tracking-transparency": "file:../../packages/nativescript-tracking-transparency", "@nstudio/nativescript-walletconnect": "file:../../packages/nativescript-walletconnect", - "@nstudio/nativescript-web-server": "file:../../packages/nativescript-web-server" + "@nstudio/nativescript-web-server": "file:../../packages/nativescript-web-server", + "@nstudio/nativescript-branch": "file:../../packages/nativescript-branch" }, "devDependencies": { "@nativescript/android": "~8.9.0", diff --git a/apps/demo/src/main-page.xml b/apps/demo/src/main-page.xml index 93e68642..6e41143c 100644 --- a/apps/demo/src/main-page.xml +++ b/apps/demo/src/main-page.xml @@ -33,6 +33,7 @@