@ng-native/router 0.4.0 → 0.6.0
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/README.md +10 -0
- package/dist/file-routes.d.ts +83 -0
- package/dist/file-routes.js +359 -0
- package/dist/file-routes.js.map +1 -0
- package/dist/in-tab.d.ts +20 -0
- package/dist/in-tab.js +13 -0
- package/dist/in-tab.js.map +1 -0
- package/dist/index.d.ts +3 -0
- package/dist/index.js +3 -0
- package/dist/index.js.map +1 -1
- package/dist/markdown-page.d.ts +39 -0
- package/dist/markdown-page.js +56 -0
- package/dist/markdown-page.js.map +1 -0
- package/dist/native-header.d.ts +4 -0
- package/dist/native-header.js +17 -4
- package/dist/native-header.js.map +1 -1
- package/dist/native-platform-location.d.ts +5 -0
- package/dist/native-platform-location.js +4 -0
- package/dist/native-platform-location.js.map +1 -1
- package/dist/native-stack-outlet.d.ts +6 -0
- package/dist/native-stack-outlet.js +18 -0
- package/dist/native-stack-outlet.js.map +1 -1
- package/dist/native-stack-reuse-strategy.d.ts +9 -0
- package/dist/native-stack-reuse-strategy.js +23 -4
- package/dist/native-stack-reuse-strategy.js.map +1 -1
- package/dist/native-tab.d.ts +6 -0
- package/dist/native-tab.js +11 -2
- package/dist/native-tab.js.map +1 -1
- package/dist/native-tabs-outlet.d.ts +29 -1
- package/dist/native-tabs-outlet.js +113 -28
- package/dist/native-tabs-outlet.js.map +1 -1
- package/dist/presented-route.d.ts +9 -1
- package/dist/presented-route.js +1 -1
- package/dist/presented-route.js.map +1 -1
- package/dist/provide-native-router.js +85 -2
- package/dist/provide-native-router.js.map +1 -1
- package/dist/route-parking.d.ts +30 -0
- package/dist/route-parking.js +60 -0
- package/dist/route-parking.js.map +1 -0
- package/dist/screen-header.d.ts +10 -0
- package/dist/screen-header.js +11 -0
- package/dist/screen-header.js.map +1 -0
- package/dist/screen-safe-area-view.d.ts +18 -0
- package/dist/screen-safe-area-view.js +74 -0
- package/dist/screen-safe-area-view.js.map +1 -0
- package/dist/screens.js +3 -2
- package/dist/screens.js.map +1 -1
- package/dist/tab-safe-area-view.d.ts +4 -11
- package/dist/tab-safe-area-view.js +8 -43
- package/dist/tab-safe-area-view.js.map +1 -1
- package/package.json +3 -3
|
@@ -8,56 +8,21 @@
|
|
|
8
8
|
* </view>
|
|
9
9
|
* ```
|
|
10
10
|
*
|
|
11
|
-
* `<safe-area-view>`
|
|
12
|
-
*
|
|
13
|
-
* unsafe areas: inside a tab its bottom inset is the home indicator, and anything pinned to the
|
|
14
|
-
* bottom of a tab ends up under the bar. On iOS 26 the bar floats over the screen's content, and
|
|
15
|
-
* on Android the bottom navigation bar overlays it, so there is no layout that avoids it either.
|
|
16
|
-
*
|
|
17
|
-
* This is react-native-screens' own `RNSSafeAreaView`, which asks the screen it is in instead.
|
|
18
|
-
* On iOS that is the tab screen's `safeAreaInsets`, which UIKit extends by the tab bar - floating
|
|
19
|
-
* or not, and with the gap under a floating one - on top of the home indicator; a stack inside a
|
|
20
|
-
* tab passes the same insets down to its pages. On Android it is the larger of the bottom
|
|
21
|
-
* navigation bar's height and the system bars. Both follow the bar as it changes, rotates, or is
|
|
22
|
-
* hidden.
|
|
23
|
-
*
|
|
24
|
-
* **The insets are applied as margin, not padding.** Whatever is beneath the inset shows through
|
|
25
|
-
* it, so a panel whose background has to reach the bottom of the screen puts that background on
|
|
26
|
-
* a parent and this inside it, as above: the parent grows by the margin and paints behind the
|
|
27
|
-
* bar, and the content ends where the bar begins.
|
|
28
|
-
*
|
|
29
|
-
* It has to be inside a tab, or a page of a stack inside one. On iOS, with no screen above it, it
|
|
30
|
-
* insets by nothing.
|
|
11
|
+
* It is `<screen-safe-area-view>` under the name it has inside a tab, where the screen it asks is
|
|
12
|
+
* the tab's and the bar it clears is the tab bar. See `screen-safe-area-view.ts`.
|
|
31
13
|
*/
|
|
32
|
-
import { Component
|
|
33
|
-
import {
|
|
14
|
+
import { Component } from '@angular/core';
|
|
15
|
+
import { ScreenSafeAreaView } from "./screen-safe-area-view.js";
|
|
34
16
|
import * as i0 from "@angular/core";
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
ownHost(inject(ElementRef).nativeElement, this.constructor);
|
|
39
|
-
}
|
|
40
|
-
/** Which edges to inset: usually `['bottom']`. Absent insets all four. */
|
|
41
|
-
edges = input(/* @ts-ignore */
|
|
42
|
-
...(ngDevMode ? [undefined, { debugName: "edges" }] : /* istanbul ignore next */ []));
|
|
43
|
-
/**
|
|
44
|
-
* Native takes all four edges every time, as booleans; a partial record leaves the missing
|
|
45
|
-
* ones at whatever they were.
|
|
46
|
-
*/
|
|
47
|
-
resolvedEdges = computed(() => {
|
|
48
|
-
const edges = this.edges() ?? ALL;
|
|
49
|
-
return Object.fromEntries(ALL.map((edge) => [edge, edges.includes(edge)]));
|
|
50
|
-
}, /* @ts-ignore */
|
|
51
|
-
...(ngDevMode ? [{ debugName: "resolvedEdges" }] : /* istanbul ignore next */ []));
|
|
52
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.2.0", ngImport: i0, type: TabSafeAreaView, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
53
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.2.0", type: TabSafeAreaView, isStandalone: true, selector: "tab-safe-area-view", inputs: { edges: { classPropertyName: "edges", publicName: "edges", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "edges": "resolvedEdges()" } }, ngImport: i0, template: '<ng-content />', isInline: true });
|
|
17
|
+
export class TabSafeAreaView extends ScreenSafeAreaView {
|
|
18
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.2.0", ngImport: i0, type: TabSafeAreaView, deps: null, target: i0.ɵɵFactoryTarget.Component });
|
|
19
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "22.2.0", type: TabSafeAreaView, isStandalone: true, selector: "tab-safe-area-view", usesInheritance: true, ngImport: i0, template: '<ng-content />', isInline: true });
|
|
54
20
|
}
|
|
55
21
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.2.0", ngImport: i0, type: TabSafeAreaView, decorators: [{
|
|
56
22
|
type: Component,
|
|
57
23
|
args: [{
|
|
58
24
|
selector: 'tab-safe-area-view',
|
|
59
25
|
template: '<ng-content />',
|
|
60
|
-
host: { '[edges]': 'resolvedEdges()' },
|
|
61
26
|
}]
|
|
62
|
-
}]
|
|
27
|
+
}] });
|
|
63
28
|
//# sourceMappingURL=tab-safe-area-view.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tab-safe-area-view.js","sourceRoot":"","sources":["../src/tab-safe-area-view.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"tab-safe-area-view.js","sourceRoot":"","sources":["../src/tab-safe-area-view.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;GAYG;AACH,OAAO,EAAE,SAAS,EAAE,MAAM,eAAe,CAAC;AAC1C,OAAO,EAAE,kBAAkB,EAA2B,MAAM,4BAA4B,CAAC;;AASzF,MAAM,OAAO,eAAgB,SAAQ,kBAAkB;uGAA1C,eAAe;2FAAf,eAAe,qGAFhB,gBAAgB;;2FAEf,eAAe;kBAJ3B,SAAS;mBAAC;oBACT,QAAQ,EAAE,oBAAoB;oBAC9B,QAAQ,EAAE,gBAAgB;iBAC3B","sourcesContent":["/**\n * A view that keeps its content clear of the tab bar, as well as the home indicator and the\n * system bars.\n *\n * ```html\n * <view class=\"panel absolute bottom-0 left-0 right-0\">\n * <tab-safe-area-view [edges]=\"['bottom']\">…</tab-safe-area-view>\n * </view>\n * ```\n *\n * It is `<screen-safe-area-view>` under the name it has inside a tab, where the screen it asks is\n * the tab's and the bar it clears is the tab bar. See `screen-safe-area-view.ts`.\n */\nimport { Component } from '@angular/core';\nimport { ScreenSafeAreaView, type ScreenSafeAreaEdge } from './screen-safe-area-view.ts';\n\n/** The edges of the screen. */\nexport type TabSafeAreaEdge = ScreenSafeAreaEdge;\n\n@Component({\n selector: 'tab-safe-area-view',\n template: '<ng-content />',\n})\nexport class TabSafeAreaView extends ScreenSafeAreaView {}\n"]}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ng-native/router",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.6.0",
|
|
4
4
|
"description": "@angular/router over native navigation for Angular Native: stack and tab outlets, native headers and links.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"angular",
|
|
@@ -17,8 +17,8 @@
|
|
|
17
17
|
"type": "module",
|
|
18
18
|
"main": "dist/index.js",
|
|
19
19
|
"dependencies": {
|
|
20
|
-
"@ng-native/device": "0.
|
|
21
|
-
"@ng-native/fabric": "0.
|
|
20
|
+
"@ng-native/device": "0.6.0",
|
|
21
|
+
"@ng-native/fabric": "0.6.0"
|
|
22
22
|
},
|
|
23
23
|
"peerDependencies": {
|
|
24
24
|
"@angular/common": "^22.0.0",
|