@symbiote-native/angular 0.6.0 → 0.6.1

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.
Files changed (151) hide show
  1. package/babel-register-composed.cjs +11 -3
  2. package/build/angular/anchor-host-registry.d.ts +2 -0
  3. package/build/angular/anchor-host-registry.js +84 -0
  4. package/build/angular/anchor-host-registry.js.map +1 -0
  5. package/build/angular/components/input-accessory-view/index.d.ts +2 -1
  6. package/build/angular/components/input-accessory-view/index.js +28 -39
  7. package/build/angular/components/input-accessory-view/index.js.map +1 -1
  8. package/build/angular/components/scroll-view/projection.js +70 -48
  9. package/build/angular/components/scroll-view/projection.js.map +1 -1
  10. package/build/angular/components/scroll-view/shared.js +28 -25
  11. package/build/angular/components/scroll-view/shared.js.map +1 -1
  12. package/build/angular/components/scroll-view/sticky-header.d.ts +6 -7
  13. package/build/angular/components/scroll-view/sticky-header.js +82 -65
  14. package/build/angular/components/scroll-view/sticky-header.js.map +1 -1
  15. package/build/angular/components/touchable/index.d.ts +2 -5
  16. package/build/angular/components/touchable/index.js +36 -56
  17. package/build/angular/components/touchable/index.js.map +1 -1
  18. package/build/angular/components/virtualized-list/index.d.ts +5 -20
  19. package/build/angular/components/virtualized-list/index.js +145 -275
  20. package/build/angular/components/virtualized-list/index.js.map +1 -1
  21. package/build/angular/components/virtualized-section-list/index.js +2 -4
  22. package/build/angular/components/virtualized-section-list/index.js.map +1 -1
  23. package/build/angular/index.d.ts +2 -1
  24. package/build/angular/index.js +6 -1
  25. package/build/angular/index.js.map +1 -1
  26. package/build/angular/renderer/index.d.ts +0 -1
  27. package/build/angular/renderer/index.js +5 -60
  28. package/build/angular/renderer/index.js.map +1 -1
  29. package/package.json +4 -3
  30. package/src/__tests__/responder-nested-cd.test.ts +1 -1
  31. package/src/anchor-host-registry.ts +88 -0
  32. package/src/components/input-accessory-view/index.ts +30 -39
  33. package/src/components/scroll-view/projection.ts +76 -46
  34. package/src/components/scroll-view/shared.ts +27 -19
  35. package/src/components/scroll-view/sticky-header.ts +89 -64
  36. package/src/components/touchable/index.ts +52 -66
  37. package/src/components/virtualized-list/index.ts +157 -368
  38. package/src/components/virtualized-section-list/index.ts +6 -3
  39. package/src/index.ts +6 -1
  40. package/src/renderer/index.ts +5 -63
  41. package/src/renderer/renderer.test.ts +2 -1
  42. package/build/bootstrap.d.ts +0 -7
  43. package/build/bootstrap.js +0 -14
  44. package/build/components/activity-indicator/index.android.d.ts +0 -9
  45. package/build/components/activity-indicator/index.android.js +0 -64
  46. package/build/components/activity-indicator/index.d.ts +0 -1
  47. package/build/components/activity-indicator/index.ios.d.ts +0 -5
  48. package/build/components/activity-indicator/index.ios.js +0 -64
  49. package/build/components/activity-indicator/index.js +0 -3
  50. package/build/components/activity-indicator/shared.d.ts +0 -64
  51. package/build/components/activity-indicator/shared.js +0 -424
  52. package/build/components/button.d.ts +0 -60
  53. package/build/components/button.js +0 -456
  54. package/build/components/flat-list/index.d.ts +0 -119
  55. package/build/components/flat-list/index.js +0 -691
  56. package/build/components/image/index.android.d.ts +0 -7
  57. package/build/components/image/index.android.js +0 -88
  58. package/build/components/image/index.d.ts +0 -1
  59. package/build/components/image/index.ios.d.ts +0 -7
  60. package/build/components/image/index.ios.js +0 -88
  61. package/build/components/image/index.js +0 -2
  62. package/build/components/image/shared.d.ts +0 -101
  63. package/build/components/image/shared.js +0 -405
  64. package/build/components/image-background.d.ts +0 -78
  65. package/build/components/image-background.js +0 -583
  66. package/build/components/input-accessory-view/index.d.ts +0 -56
  67. package/build/components/input-accessory-view/index.js +0 -403
  68. package/build/components/keyboard-avoiding-view/index.d.ts +0 -79
  69. package/build/components/keyboard-avoiding-view/index.js +0 -504
  70. package/build/components/modal/index.d.ts +0 -89
  71. package/build/components/modal/index.js +0 -529
  72. package/build/components/pressable/index.d.ts +0 -120
  73. package/build/components/pressable/index.js +0 -639
  74. package/build/components/refresh-control/index.d.ts +0 -83
  75. package/build/components/refresh-control/index.js +0 -509
  76. package/build/components/safe-area-view/index.d.ts +0 -54
  77. package/build/components/safe-area-view/index.js +0 -388
  78. package/build/components/scroll-view/index.android.d.ts +0 -16
  79. package/build/components/scroll-view/index.android.js +0 -228
  80. package/build/components/scroll-view/index.d.ts +0 -3
  81. package/build/components/scroll-view/index.ios.d.ts +0 -6
  82. package/build/components/scroll-view/index.ios.js +0 -113
  83. package/build/components/scroll-view/index.js +0 -5
  84. package/build/components/scroll-view/projection.d.ts +0 -32
  85. package/build/components/scroll-view/projection.js +0 -311
  86. package/build/components/scroll-view/shared.d.ts +0 -225
  87. package/build/components/scroll-view/shared.js +0 -757
  88. package/build/components/scroll-view/sticky-header.d.ts +0 -38
  89. package/build/components/scroll-view/sticky-header.js +0 -257
  90. package/build/components/section-list/index.d.ts +0 -113
  91. package/build/components/section-list/index.js +0 -768
  92. package/build/components/switch/index.android.d.ts +0 -17
  93. package/build/components/switch/index.android.js +0 -107
  94. package/build/components/switch/index.d.ts +0 -1
  95. package/build/components/switch/index.ios.d.ts +0 -16
  96. package/build/components/switch/index.ios.js +0 -106
  97. package/build/components/switch/index.js +0 -3
  98. package/build/components/switch/shared.d.ts +0 -37
  99. package/build/components/switch/shared.js +0 -176
  100. package/build/components/text-input.d.ts +0 -150
  101. package/build/components/text-input.js +0 -821
  102. package/build/components/touchable/index.d.ts +0 -241
  103. package/build/components/touchable/index.js +0 -1672
  104. package/build/components/touchable-native-feedback/index.d.ts +0 -80
  105. package/build/components/touchable-native-feedback/index.js +0 -545
  106. package/build/components/virtualized-list/directives.d.ts +0 -41
  107. package/build/components/virtualized-list/directives.js +0 -249
  108. package/build/components/virtualized-list/index.d.ts +0 -265
  109. package/build/components/virtualized-list/index.js +0 -1343
  110. package/build/components/virtualized-section-list/directives.d.ts +0 -28
  111. package/build/components/virtualized-section-list/directives.js +0 -148
  112. package/build/components/virtualized-section-list/index.d.ts +0 -175
  113. package/build/components/virtualized-section-list/index.js +0 -854
  114. package/build/components.d.ts +0 -39
  115. package/build/components.js +0 -37
  116. package/build/create-portal/index.d.ts +0 -17
  117. package/build/create-portal/index.js +0 -128
  118. package/build/create-tunnel/index.d.ts +0 -29
  119. package/build/create-tunnel/index.js +0 -181
  120. package/build/descriptor-to-angular/index.d.ts +0 -19
  121. package/build/descriptor-to-angular/index.js +0 -186
  122. package/build/host-instance/index.d.ts +0 -2
  123. package/build/host-instance/index.js +0 -36
  124. package/build/index.d.ts +0 -21
  125. package/build/index.js +0 -40
  126. package/build/modules/animated/animated-leaf-binder/index.d.ts +0 -14
  127. package/build/modules/animated/animated-leaf-binder/index.js +0 -90
  128. package/build/modules/animated/animated-leaf-binder.d.ts +0 -14
  129. package/build/modules/animated/animated-leaf-binder.js +0 -90
  130. package/build/modules/animated/create-animated-component.d.ts +0 -48
  131. package/build/modules/animated/create-animated-component.js +0 -425
  132. package/build/modules/animated/index.d.ts +0 -51
  133. package/build/modules/animated/index.js +0 -58
  134. package/build/modules/app-registry/index.d.ts +0 -7
  135. package/build/modules/app-registry/index.js +0 -22
  136. package/build/modules/status-bar/index.d.ts +0 -17
  137. package/build/modules/status-bar/index.js +0 -121
  138. package/build/primitives/index.d.ts +0 -32
  139. package/build/primitives/index.js +0 -386
  140. package/build/primitives/shared.d.ts +0 -83
  141. package/build/primitives/shared.js +0 -230
  142. package/build/render/index.d.ts +0 -11
  143. package/build/render/index.js +0 -170
  144. package/build/renderer/index.d.ts +0 -38
  145. package/build/renderer/index.js +0 -355
  146. package/build/services/color-scheme.service.d.ts +0 -13
  147. package/build/services/color-scheme.service.js +0 -72
  148. package/build/services/index.d.ts +0 -2
  149. package/build/services/index.js +0 -2
  150. package/build/services/window-dimensions.service.d.ts +0 -13
  151. package/build/services/window-dimensions.service.js +0 -83
@@ -33,6 +33,7 @@ import {
33
33
  } from '@angular/core';
34
34
  import {
35
35
  flattenSections,
36
+ resolveStickySectionHeaders,
36
37
  scrollLocationToFlatIndex,
37
38
  sectionEntryKey,
38
39
  unwrapEntryItem,
@@ -442,9 +443,11 @@ export class VirtualizedSectionList<ItemT = unknown>
442
443
  this.headerIndices = headerIndices;
443
444
 
444
445
  // RN sticks section headers by default only on iOS; Android does not unless asked.
445
- const stickyDefault = Platform.OS === 'ios';
446
- const stickyEnabled = this.stickySectionHeadersEnabled ?? stickyDefault;
447
- this.stickyHeaderIndices = stickyEnabled ? headerIndices : undefined;
446
+ this.stickyHeaderIndices = resolveStickySectionHeaders(
447
+ this.stickySectionHeadersEnabled,
448
+ headerIndices,
449
+ Platform.OS,
450
+ );
448
451
 
449
452
  dlog(
450
453
  `Angular VirtualizedSectionList: ${sections.length} sections flattened to ${entries.length} entries`,
package/src/index.ts CHANGED
@@ -135,7 +135,12 @@ export { DescriptorOutlet } from './descriptor-to-angular';
135
135
  // call.
136
136
  export { PortalDirective, PortalOutletDirective } from './create-portal';
137
137
  export { createTunnel, TunnelInDirective, TunnelOut, type ITunnelStore } from './create-tunnel';
138
- export { registerComposedComponent, SymbioteRenderer, SymbioteRendererFactory } from './renderer';
138
+ export { SymbioteRenderer, SymbioteRendererFactory } from './renderer';
139
+ // registerComposedComponent lives in the dependency-free leaf ./anchor-host-registry, NOT in the
140
+ // require-cyclic ./renderer — see the leaf header. The babel-register-composed plugin injects the
141
+ // import straight from that subpath so app-screen registration never routes through this cyclic
142
+ // barrel.
143
+ export { registerComposedComponent } from './anchor-host-registry';
139
144
  export { findNodeHandle } from './host-instance';
140
145
  export type { IHostInstance } from './host-instance';
141
146
  export { StatusBar } from './modules/status-bar';
@@ -26,6 +26,7 @@ import {
26
26
  } from '@symbiote-native/engine';
27
27
  import { descriptorFor } from '@symbiote-native/components';
28
28
  import type { Renderer2, RendererFactory2, RendererType2 } from '@angular/core';
29
+ import { isAnchorHostComponent } from '../anchor-host-registry';
29
30
  import {
30
31
  getScrollViewProjection,
31
32
  removeScrollViewProjectedChild,
@@ -76,68 +77,9 @@ const PRIMITIVE_SELECTOR_ALIAS: Record<string, string> = {
76
77
  Text: 'symbiote-text',
77
78
  };
78
79
 
79
- // A composed component's selector must be listed so createElement gives it a non-painting
80
- // anchor host (see the set comment below). Tests register their own child-component selectors
81
- // through this at module load; app-authored composed components can too.
82
- export function registerComposedComponent(selector: string): void {
83
- ANCHOR_HOST_COMPONENTS.add(selector.toLowerCase());
84
- }
85
-
86
- // Lowercased at construction — createElement's lookup and registerComposedComponent's insert
87
- // both normalize to lowercase (Angular lowercases a dynamically-mounted component's selector at
88
- // runtime, see §11a), so the literal entries below must match that or every capitalized one
89
- // (all but the handful already written lowercase) silently never matches .has() and falls
90
- // through to a real Fabric createNode — the exact "Unimplemented component" / extra-wrapper-node
91
- // bug this Set exists to prevent.
92
- const ANCHOR_HOST_COMPONENTS: Set<string> = new Set(
93
- [
94
- // Composed Angular components render their real Fabric descriptor tree from the template;
95
- // their Angular host element is only a framework bookkeeping node and must not paint. This
96
- // is NOT limited to adapter-authored components — ANY custom composed @Component used as a
97
- // plain <Tag> inside another template needs its selector listed here too, or Angular's
98
- // automatic host-element creation for it falls through to a raw Fabric createNode call with
99
- // an unrecognized view name, which paints RN's own "Unimplemented component: <Tag>" fallback
100
- // view instead (a real device-visible bug, not a silent no-op). This Set holds only
101
- // adapter/engine-owned selectors; app code and third-party packages self-register their own
102
- // composed components through registerComposedComponent instead of being hardcoded here.
103
- 'ActivityIndicator',
104
- 'Button',
105
- 'FlatList',
106
- 'AnimatedView',
107
- 'symbiote-animated-view',
108
- 'AnimatedText',
109
- 'symbiote-animated-text',
110
- 'AnimatedImage',
111
- 'symbiote-animated-image',
112
- 'AnimatedScrollView',
113
- 'symbiote-animated-scroll-view',
114
- 'symbiote-descriptor-outlet',
115
- 'tunnel-out',
116
- 'Image',
117
- 'ImageBackground',
118
- 'InputAccessoryView',
119
- 'KeyboardAvoidingView',
120
- 'Modal',
121
- 'Pressable',
122
- 'RefreshControl',
123
- 'SafeAreaView',
124
- 'ScrollView',
125
- 'ScrollViewStickyHeader',
126
- 'SectionList',
127
- 'symbiote-sticky-header',
128
- 'StatusBar',
129
- 'Switch',
130
- 'Text',
131
- 'TextInput',
132
- 'TouchableHighlight',
133
- 'TouchableNativeFeedback',
134
- 'TouchableOpacity',
135
- 'TouchableWithoutFeedback',
136
- 'VirtualizedList',
137
- 'VirtualizedSectionList',
138
- 'symbiote-pressable',
139
- ].map(selector => selector.toLowerCase()),
140
- );
80
+ // The ANCHOR_HOST_COMPONENTS Set and registerComposedComponent now live in the dependency-free
81
+ // leaf module ../anchor-host-registry (imported above as isAnchorHostComponent) — see its header
82
+ // for why the registry must NOT sit in this require-cyclic renderer module.
141
83
 
142
84
  // Inserting a bare raw-text node anywhere but inside a <Text> is invalid in Fabric (a
143
85
  // stray RCTRawText would paint). Angular's ɵɵtext only ever lands text inside a <Text>,
@@ -170,7 +112,7 @@ export class SymbioteRenderer implements Renderer2 {
170
112
  // ViewConfig). toPublicInstance grafts the imperative API (measure / setNativeProps /
171
113
  // focus) onto the raw node in place, returning the SAME identity the commit mirror keys on.
172
114
  const engineName = PRIMITIVE_SELECTOR_ALIAS[name] ?? name;
173
- if (ANCHOR_HOST_COMPONENTS.has(engineName.toLowerCase())) {
115
+ if (isAnchorHostComponent(engineName)) {
174
116
  const anchor = tagAnchorForDebug(createAnchor());
175
117
  dlog(`angular createElement ${name} -> anchor host ${describeHost(anchor)}`);
176
118
  return anchor;
@@ -14,7 +14,8 @@ import {
14
14
  registerStyles,
15
15
  } from '@symbiote-native/engine';
16
16
  import { installFabric } from '@symbiote-native/test-utils';
17
- import { registerComposedComponent, SymbioteRenderer, SymbioteRendererFactory } from './index';
17
+ import { SymbioteRenderer, SymbioteRendererFactory } from './index';
18
+ import { registerComposedComponent } from '../anchor-host-registry';
18
19
 
19
20
  const ROOT_TAG = 707;
20
21
  const PROBE_ID = 'probe';
@@ -1,7 +0,0 @@
1
- import type { Type } from '@angular/core';
2
- import { type IBootstrapHostOptions } from '@symbiote-native/components/bootstrap';
3
- export type { IBootstrapHostOptions } from '@symbiote-native/components/bootstrap';
4
- export type IBootstrapApplicationOptions = IBootstrapHostOptions & {
5
- appName: string;
6
- };
7
- export declare function bootstrapApplication(AppComponent: Type<unknown>, options: IBootstrapApplicationOptions): void;
@@ -1,14 +0,0 @@
1
- // Zero-config app entry, the Angular twin of adapters/react/src/bootstrap.ts. Lives OUTSIDE the
2
- // package's main barrel — see that file's header for why anything importing react-native must
3
- // stay there. No @Component/@Directive decorators here, so unlike the package's main "." entry
4
- // this needs no ngc/AOT build step and can stay a plain source reference.
5
- import { AppRegistry as RNAppRegistry } from 'react-native';
6
- import { bootstrapHost } from '@symbiote-native/components/bootstrap';
7
- import { AppRegistry, setHostRegistrar } from './modules/app-registry';
8
- // Mirrors real Angular's bootstrapApplication(RootComponent, config) idiom.
9
- export function bootstrapApplication(AppComponent, options) {
10
- const { appName, ...bootstrapOptions } = options;
11
- bootstrapHost(bootstrapOptions);
12
- setHostRegistrar(RNAppRegistry);
13
- AppRegistry.registerComponent(appName, () => AppComponent);
14
- }
@@ -1,9 +0,0 @@
1
- import { ActivityIndicatorBase } from './shared';
2
- export type { IActivityIndicatorProps } from './shared';
3
- export declare class ActivityIndicator extends ActivityIndicatorBase {
4
- protected readonly defaultColor: null;
5
- protected readonly nativeExtras: {
6
- styleAttr: string;
7
- indeterminate: boolean;
8
- };
9
- }
@@ -1,64 +0,0 @@
1
- var __esDecorate = (this && this.__esDecorate) || function (ctor, descriptorIn, decorators, contextIn, initializers, extraInitializers) {
2
- function accept(f) { if (f !== void 0 && typeof f !== "function") throw new TypeError("Function expected"); return f; }
3
- var kind = contextIn.kind, key = kind === "getter" ? "get" : kind === "setter" ? "set" : "value";
4
- var target = !descriptorIn && ctor ? contextIn["static"] ? ctor : ctor.prototype : null;
5
- var descriptor = descriptorIn || (target ? Object.getOwnPropertyDescriptor(target, contextIn.name) : {});
6
- var _, done = false;
7
- for (var i = decorators.length - 1; i >= 0; i--) {
8
- var context = {};
9
- for (var p in contextIn) context[p] = p === "access" ? {} : contextIn[p];
10
- for (var p in contextIn.access) context.access[p] = contextIn.access[p];
11
- context.addInitializer = function (f) { if (done) throw new TypeError("Cannot add initializers after decoration has completed"); extraInitializers.push(accept(f || null)); };
12
- var result = (0, decorators[i])(kind === "accessor" ? { get: descriptor.get, set: descriptor.set } : descriptor[key], context);
13
- if (kind === "accessor") {
14
- if (result === void 0) continue;
15
- if (result === null || typeof result !== "object") throw new TypeError("Object expected");
16
- if (_ = accept(result.get)) descriptor.get = _;
17
- if (_ = accept(result.set)) descriptor.set = _;
18
- if (_ = accept(result.init)) initializers.unshift(_);
19
- }
20
- else if (_ = accept(result)) {
21
- if (kind === "field") initializers.unshift(_);
22
- else descriptor[key] = _;
23
- }
24
- }
25
- if (target) Object.defineProperty(target, contextIn.name, descriptor);
26
- done = true;
27
- };
28
- var __runInitializers = (this && this.__runInitializers) || function (thisArg, initializers, value) {
29
- var useValue = arguments.length > 2;
30
- for (var i = 0; i < initializers.length; i++) {
31
- value = useValue ? initializers[i].call(thisArg, value) : initializers[i].call(thisArg);
32
- }
33
- return useValue ? value : void 0;
34
- };
35
- import { ChangeDetectionStrategy, Component } from '@angular/core';
36
- import { DescriptorOutlet } from '../../descriptor-to-angular';
37
- import { ActivityIndicatorBase } from './shared';
38
- let ActivityIndicator = (() => {
39
- let _classDecorators = [Component({
40
- selector: 'ActivityIndicator',
41
- standalone: true,
42
- imports: [DescriptorOutlet],
43
- changeDetection: ChangeDetectionStrategy.OnPush,
44
- template: `<symbiote-descriptor-outlet [node]="descriptor" />`,
45
- })];
46
- let _classDescriptor;
47
- let _classExtraInitializers = [];
48
- let _classThis;
49
- let _classSuper = ActivityIndicatorBase;
50
- var ActivityIndicator = class extends _classSuper {
51
- static { _classThis = this; }
52
- static {
53
- const _metadata = typeof Symbol === "function" && Symbol.metadata ? Object.create(_classSuper[Symbol.metadata] ?? null) : void 0;
54
- __esDecorate(null, _classDescriptor = { value: _classThis }, _classDecorators, { kind: "class", name: _classThis.name, metadata: _metadata }, null, _classExtraInitializers);
55
- ActivityIndicator = _classThis = _classDescriptor.value;
56
- if (_metadata) Object.defineProperty(_classThis, Symbol.metadata, { enumerable: true, configurable: true, writable: true, value: _metadata });
57
- __runInitializers(_classThis, _classExtraInitializers);
58
- }
59
- defaultColor = null;
60
- nativeExtras = { styleAttr: 'Normal', indeterminate: true };
61
- };
62
- return ActivityIndicator = _classThis;
63
- })();
64
- export { ActivityIndicator };
@@ -1 +0,0 @@
1
- export * from './index.ios';
@@ -1,5 +0,0 @@
1
- import { ActivityIndicatorBase } from './shared';
2
- export type { IActivityIndicatorProps } from './shared';
3
- export declare class ActivityIndicator extends ActivityIndicatorBase {
4
- protected readonly defaultColor = "#999999";
5
- }
@@ -1,64 +0,0 @@
1
- var __esDecorate = (this && this.__esDecorate) || function (ctor, descriptorIn, decorators, contextIn, initializers, extraInitializers) {
2
- function accept(f) { if (f !== void 0 && typeof f !== "function") throw new TypeError("Function expected"); return f; }
3
- var kind = contextIn.kind, key = kind === "getter" ? "get" : kind === "setter" ? "set" : "value";
4
- var target = !descriptorIn && ctor ? contextIn["static"] ? ctor : ctor.prototype : null;
5
- var descriptor = descriptorIn || (target ? Object.getOwnPropertyDescriptor(target, contextIn.name) : {});
6
- var _, done = false;
7
- for (var i = decorators.length - 1; i >= 0; i--) {
8
- var context = {};
9
- for (var p in contextIn) context[p] = p === "access" ? {} : contextIn[p];
10
- for (var p in contextIn.access) context.access[p] = contextIn.access[p];
11
- context.addInitializer = function (f) { if (done) throw new TypeError("Cannot add initializers after decoration has completed"); extraInitializers.push(accept(f || null)); };
12
- var result = (0, decorators[i])(kind === "accessor" ? { get: descriptor.get, set: descriptor.set } : descriptor[key], context);
13
- if (kind === "accessor") {
14
- if (result === void 0) continue;
15
- if (result === null || typeof result !== "object") throw new TypeError("Object expected");
16
- if (_ = accept(result.get)) descriptor.get = _;
17
- if (_ = accept(result.set)) descriptor.set = _;
18
- if (_ = accept(result.init)) initializers.unshift(_);
19
- }
20
- else if (_ = accept(result)) {
21
- if (kind === "field") initializers.unshift(_);
22
- else descriptor[key] = _;
23
- }
24
- }
25
- if (target) Object.defineProperty(target, contextIn.name, descriptor);
26
- done = true;
27
- };
28
- var __runInitializers = (this && this.__runInitializers) || function (thisArg, initializers, value) {
29
- var useValue = arguments.length > 2;
30
- for (var i = 0; i < initializers.length; i++) {
31
- value = useValue ? initializers[i].call(thisArg, value) : initializers[i].call(thisArg);
32
- }
33
- return useValue ? value : void 0;
34
- };
35
- import { ChangeDetectionStrategy, Component } from '@angular/core';
36
- import { DescriptorOutlet } from '../../descriptor-to-angular';
37
- import { ActivityIndicatorBase } from './shared';
38
- const IOS_DEFAULT_COLOR = '#999999';
39
- let ActivityIndicator = (() => {
40
- let _classDecorators = [Component({
41
- selector: 'ActivityIndicator',
42
- standalone: true,
43
- imports: [DescriptorOutlet],
44
- changeDetection: ChangeDetectionStrategy.OnPush,
45
- template: `<symbiote-descriptor-outlet [node]="descriptor" />`,
46
- })];
47
- let _classDescriptor;
48
- let _classExtraInitializers = [];
49
- let _classThis;
50
- let _classSuper = ActivityIndicatorBase;
51
- var ActivityIndicator = class extends _classSuper {
52
- static { _classThis = this; }
53
- static {
54
- const _metadata = typeof Symbol === "function" && Symbol.metadata ? Object.create(_classSuper[Symbol.metadata] ?? null) : void 0;
55
- __esDecorate(null, _classDescriptor = { value: _classThis }, _classDecorators, { kind: "class", name: _classThis.name, metadata: _metadata }, null, _classExtraInitializers);
56
- ActivityIndicator = _classThis = _classDescriptor.value;
57
- if (_metadata) Object.defineProperty(_classThis, Symbol.metadata, { enumerable: true, configurable: true, writable: true, value: _metadata });
58
- __runInitializers(_classThis, _classExtraInitializers);
59
- }
60
- defaultColor = IOS_DEFAULT_COLOR;
61
- };
62
- return ActivityIndicator = _classThis;
63
- })();
64
- export { ActivityIndicator };
@@ -1,3 +0,0 @@
1
- // Base/default ActivityIndicator. Re-exports the iOS build; Metro picks index.ios.ts /
2
- // index.android.ts in platform bundles.
3
- export * from './index.ios';
@@ -1,64 +0,0 @@
1
- import { EventEmitter } from '@angular/core';
2
- import { type IAccessibilityProps, type IAccessibilityStateValue, type IActivityIndicatorProps, type IActivityIndicatorSize, type IAriaProps } from '@symbiote-native/components';
3
- import type { ISymbioteEvent } from '@symbiote-native/engine';
4
- import type { IDescriptor } from '@symbiote-native/components';
5
- export type { IActivityIndicatorProps, IActivityIndicatorSize } from '@symbiote-native/components';
6
- export type IActivityIndicatorInputs = Omit<IActivityIndicatorProps, 'onLayout' | 'onAccessibilityAction' | 'onAccessibilityTap' | 'onMagicTap' | 'onAccessibilityEscape'>;
7
- export declare abstract class ActivityIndicatorBase implements IActivityIndicatorInputs {
8
- animating?: boolean;
9
- color?: string;
10
- hidesWhenStopped?: boolean;
11
- nativeID?: string;
12
- size?: IActivityIndicatorSize;
13
- style?: IActivityIndicatorProps['style'];
14
- testID?: string;
15
- readonly layout: EventEmitter<ISymbioteEvent>;
16
- accessible?: boolean;
17
- accessibilityLabel?: string;
18
- accessibilityHint?: string;
19
- accessibilityRole?: IAccessibilityProps['accessibilityRole'];
20
- accessibilityState?: IAccessibilityStateValue;
21
- accessibilityValue?: IAccessibilityProps['accessibilityValue'];
22
- accessibilityActions?: IAccessibilityProps['accessibilityActions'];
23
- accessibilityLabelledBy?: string | string[];
24
- importantForAccessibility?: IAccessibilityProps['importantForAccessibility'];
25
- accessibilityLiveRegion?: IAccessibilityProps['accessibilityLiveRegion'];
26
- screenReaderFocusable?: boolean;
27
- accessibilityViewIsModal?: boolean;
28
- accessibilityElementsHidden?: boolean;
29
- accessibilityIgnoresInvertColors?: boolean;
30
- accessibilityLanguage?: string;
31
- accessibilityRespondsToUserInteraction?: boolean;
32
- accessibilityShowsLargeContentViewer?: boolean;
33
- accessibilityLargeContentTitle?: string;
34
- readonly accessibilityAction: EventEmitter<ISymbioteEvent>;
35
- readonly accessibilityTap: EventEmitter<ISymbioteEvent>;
36
- readonly magicTap: EventEmitter<ISymbioteEvent>;
37
- readonly accessibilityEscape: EventEmitter<ISymbioteEvent>;
38
- role?: IAriaProps['role'];
39
- ariaLabel?: string;
40
- ariaLabelledBy?: string;
41
- ariaLive?: IAriaProps['aria-live'];
42
- ariaHidden?: boolean;
43
- ariaBusy?: boolean;
44
- ariaChecked?: boolean | 'mixed';
45
- ariaDisabled?: boolean;
46
- ariaExpanded?: boolean;
47
- ariaSelected?: boolean;
48
- ariaModal?: boolean;
49
- ariaValueMax?: number;
50
- ariaValueMin?: number;
51
- ariaValueNow?: number;
52
- ariaValueText?: string;
53
- protected abstract readonly defaultColor: string | null;
54
- protected readonly nativeExtras: Readonly<Record<string, unknown>>;
55
- private readonly elementRef;
56
- private readonly onLayoutHandler;
57
- private readonly onAccessibilityActionHandler;
58
- private readonly onAccessibilityTapHandler;
59
- private readonly onMagicTapHandler;
60
- private readonly onAccessibilityEscapeHandler;
61
- get descriptor(): IDescriptor;
62
- private get platform();
63
- private emitterHandler;
64
- }