@ng-desktop/platform 0.5.0 → 0.7.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 +0 -1
- package/fesm2022/bridge.d.ts +5 -0
- package/fesm2022/bridge.js +1 -0
- package/fesm2022/css-style-parser.d.ts +16 -3
- package/fesm2022/css-style-parser.js +534 -104
- package/fesm2022/ecosystem-compat.d.ts +3 -5
- package/fesm2022/ecosystem-compat.js +16 -25
- package/fesm2022/index.d.ts +3 -1
- package/fesm2022/index.js +3 -1
- package/fesm2022/native-directives.d.ts +5 -2
- package/fesm2022/native-directives.js +17 -11
- package/fesm2022/native-element.d.ts +2 -0
- package/fesm2022/native-element.js +2 -0
- package/fesm2022/native-renderer.d.ts +4 -1
- package/fesm2022/native-renderer.js +88 -6
- package/fesm2022/system-providers.js +2 -1
- package/fesm2022/virtual-grid.component.d.ts +68 -0
- package/fesm2022/virtual-grid.component.js +324 -0
- package/fesm2022/virtual-layout.d.ts +71 -0
- package/fesm2022/virtual-layout.js +279 -0
- package/fesm2022/virtual-list.component.d.ts +25 -13
- package/fesm2022/virtual-list.component.js +156 -73
- package/package.json +1 -1
package/README.md
CHANGED
package/fesm2022/bridge.d.ts
CHANGED
|
@@ -1,18 +1,23 @@
|
|
|
1
1
|
import { type NativeComputeMatch, type NativeXdgDirKind } from './bridge-fs-compute';
|
|
2
2
|
export type { NativeComputeMatch, NativeXdgDirKind } from './bridge-fs-compute';
|
|
3
|
+
/** Logical transport category reported to Rust `NativeHttpEngine` and telemetry. */
|
|
3
4
|
export type NativeHttpCallKind = 'json' | 'graphql' | 'asset' | 'batch' | 'text';
|
|
5
|
+
/** OS network reachability classification exposed by `NativeNetworkService`. */
|
|
4
6
|
export type NativeConnectivity = 'full' | 'limited' | 'offline';
|
|
7
|
+
/** Snapshot of OS connectivity and metered network status. */
|
|
5
8
|
export interface NativeNetworkStatus {
|
|
6
9
|
online: boolean;
|
|
7
10
|
metered: boolean;
|
|
8
11
|
connectivity: NativeConnectivity;
|
|
9
12
|
}
|
|
13
|
+
/** Per-request headers and options passed across `bridge.httpRequest`. */
|
|
10
14
|
export interface NativeHttpRequestOptions {
|
|
11
15
|
headers?: Record<string, string>;
|
|
12
16
|
responseType?: string;
|
|
13
17
|
callKind?: NativeHttpCallKind;
|
|
14
18
|
withCredentials?: boolean;
|
|
15
19
|
}
|
|
20
|
+
/** Global configuration shared with Rust `NativeHttpEngine` (HTTP/2, XSRF, caching). */
|
|
16
21
|
export interface NativeHttpConfig {
|
|
17
22
|
platform?: string;
|
|
18
23
|
useFetchTransport?: boolean;
|
package/fesm2022/bridge.js
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { NgNativeBridge } from './bridge';
|
|
2
|
+
export type SupportedMediaTheme = 'light' | 'dark';
|
|
2
3
|
export interface ParsedStyleRule {
|
|
3
4
|
className: string;
|
|
4
5
|
background: string;
|
|
@@ -18,16 +19,28 @@ export interface ParsedStyleRule {
|
|
|
18
19
|
minChildren: number | null;
|
|
19
20
|
maxChildren: number | null;
|
|
20
21
|
homogeneous: boolean | null;
|
|
22
|
+
pseudoClass: string | null;
|
|
23
|
+
mediaTheme: SupportedMediaTheme | null;
|
|
24
|
+
mediaMinWidth: number | null;
|
|
25
|
+
mediaMaxWidth: number | null;
|
|
26
|
+
opacity: number | null;
|
|
27
|
+
transitionMs: number | null;
|
|
28
|
+
transitionProp: string | null;
|
|
21
29
|
}
|
|
22
30
|
export declare function parsePixelInt(raw: string): number | null;
|
|
23
31
|
export declare function mapAlignKeyword(raw: string): string | null;
|
|
32
|
+
export interface SharedRuntimeCssVars {
|
|
33
|
+
baseVars: Map<string, string>;
|
|
34
|
+
lightVars: Map<string, string>;
|
|
35
|
+
darkVars: Map<string, string>;
|
|
36
|
+
}
|
|
24
37
|
/**
|
|
25
38
|
* Parses component CSS rules at runtime into `ParsedStyleRule` descriptors compatible with
|
|
26
|
-
* the Rust engine's CSS Flexbox/Grid and
|
|
39
|
+
* the Rust engine's CSS Flexbox/Grid, pseudo-classes, `@media`, variables, and encapsulation syntax.
|
|
27
40
|
*/
|
|
28
41
|
export declare function parseRuntimeStyles(cssSource: string): ParsedStyleRule[];
|
|
29
42
|
/**
|
|
30
|
-
* Formats optional `ParsedStyleRule` layout/typography fields as space-separated `key=value` tokens.
|
|
43
|
+
* Formats optional `ParsedStyleRule` layout/typography/media/pseudo fields as space-separated `key=value` tokens.
|
|
31
44
|
*/
|
|
32
45
|
export declare function formatParsedStyleExtensions(rule: ParsedStyleRule): string;
|
|
33
|
-
export declare function registerParsedStyles(bridge: NgNativeBridge, styles: readonly string[]): void;
|
|
46
|
+
export declare function registerParsedStyles(bridge: NgNativeBridge, styles: readonly string[], scopedClassesByScope?: Map<string, Set<string>>, sharedVars?: SharedRuntimeCssVars): void;
|