ember-native 1.3.0 → 2.0.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.
Files changed (96) hide show
  1. package/declarations/components/InspectorSupport.d.ts +0 -1
  2. package/declarations/components/ListView.d.ts +0 -1
  3. package/declarations/components/RadListView.d.ts +1 -1
  4. package/declarations/components/index.d.ts +0 -1
  5. package/declarations/dom/element-registry.d.ts +0 -1
  6. package/declarations/dom/native/FrameElement.d.ts +0 -1
  7. package/declarations/dom/native/NativeElementNode.d.ts +8 -1
  8. package/declarations/dom/native/PageElement.d.ts +0 -1
  9. package/declarations/dom/native-elements-tag-name-map.d.ts +31 -6
  10. package/declarations/dom/nodes/CommentNode.d.ts +0 -1
  11. package/declarations/dom/nodes/DocumentNode.d.ts +6 -3
  12. package/declarations/dom/nodes/ElementNode.d.ts +6 -2
  13. package/declarations/dom/nodes/PropertyNode.d.ts +2 -4
  14. package/declarations/dom/nodes/TextNode.d.ts +0 -1
  15. package/declarations/dom/nodes/ViewNode.d.ts +1 -1
  16. package/declarations/dom/setup-registry.d.ts +0 -1
  17. package/declarations/index.d.ts +1 -2
  18. package/declarations/instance-initializers/history.d.ts +0 -1
  19. package/declarations/instance-initializers/webpack-hot-reload.d.ts +0 -1
  20. package/declarations/services/history.d.ts +3 -1
  21. package/declarations/services/native-router.d.ts +0 -1
  22. package/declarations/services/webpack-hot-reload.d.ts +0 -1
  23. package/declarations/setup-inspector-support.d.ts +0 -1
  24. package/declarations/setup.d.ts +0 -1
  25. package/declarations/types/glint.d.ts +22 -2
  26. package/declarations/types/globals.d.ts +28 -31
  27. package/dist/{_rollupPluginBabelHelpers-DZQzmiRH.js → _rollupPluginBabelHelpers-apNPIsxw.js} +6 -6
  28. package/dist/_rollupPluginBabelHelpers-apNPIsxw.js.map +1 -0
  29. package/dist/components/InspectorSupport.js +1 -5
  30. package/dist/components/InspectorSupport.js.map +1 -1
  31. package/dist/components/ListView.js +4 -3
  32. package/dist/components/ListView.js.map +1 -1
  33. package/dist/components/RadListView.js +17 -3
  34. package/dist/components/RadListView.js.map +1 -1
  35. package/dist/dom/native/FrameElement.js +1 -1
  36. package/dist/dom/native/FrameElement.js.map +1 -1
  37. package/dist/dom/native/NativeElementNode.js +18 -3
  38. package/dist/dom/native/NativeElementNode.js.map +1 -1
  39. package/dist/dom/nodes/CommentNode.js +1 -1
  40. package/dist/dom/nodes/CommentNode.js.map +1 -1
  41. package/dist/dom/nodes/DocumentNode.js +18 -6
  42. package/dist/dom/nodes/DocumentNode.js.map +1 -1
  43. package/dist/dom/nodes/ElementNode.js +22 -6
  44. package/dist/dom/nodes/ElementNode.js.map +1 -1
  45. package/dist/dom/nodes/PropertyNode.js +7 -10
  46. package/dist/dom/nodes/PropertyNode.js.map +1 -1
  47. package/dist/dom/nodes/TextNode.js +1 -1
  48. package/dist/dom/nodes/TextNode.js.map +1 -1
  49. package/dist/dom/nodes/ViewNode.js +9 -2
  50. package/dist/dom/nodes/ViewNode.js.map +1 -1
  51. package/dist/dom/setup-registry.js +1 -2
  52. package/dist/dom/setup-registry.js.map +1 -1
  53. package/dist/services/history.js +9 -6
  54. package/dist/services/history.js.map +1 -1
  55. package/dist/services/native-router.js +1 -1
  56. package/dist/services/webpack-hot-reload.js +1 -1
  57. package/dist/setup-inspector-support.js +1 -1
  58. package/dist/setup-inspector-support.js.map +1 -1
  59. package/dist/setup.js +38 -0
  60. package/dist/setup.js.map +1 -1
  61. package/dist/utils/babel-plugin.js +14 -20
  62. package/dist/utils/babel-plugin.ts +0 -2
  63. package/dist/utils/content-tag-loader.js +1 -1
  64. package/dist/utils/ember-native.js +2 -0
  65. package/dist/utils/eslint/ember-native.js +2 -0
  66. package/dist/utils/tsconfig.json +3 -2
  67. package/dist/utils/webpack.config.js +0 -1
  68. package/package.json +46 -44
  69. package/declarations/components/InspectorSupport.d.ts.map +0 -1
  70. package/declarations/components/ListView.d.ts.map +0 -1
  71. package/declarations/components/RadListView.d.ts.map +0 -1
  72. package/declarations/components/index.d.ts.map +0 -1
  73. package/declarations/dom/element-registry.d.ts.map +0 -1
  74. package/declarations/dom/native/FrameElement.d.ts.map +0 -1
  75. package/declarations/dom/native/NativeElementNode.d.ts.map +0 -1
  76. package/declarations/dom/native/PageElement.d.ts.map +0 -1
  77. package/declarations/dom/native-elements-tag-name-map.d.ts.map +0 -1
  78. package/declarations/dom/nodes/CommentNode.d.ts.map +0 -1
  79. package/declarations/dom/nodes/DocumentNode.d.ts.map +0 -1
  80. package/declarations/dom/nodes/ElementNode.d.ts.map +0 -1
  81. package/declarations/dom/nodes/PropertyNode.d.ts.map +0 -1
  82. package/declarations/dom/nodes/TextNode.d.ts.map +0 -1
  83. package/declarations/dom/nodes/ViewNode.d.ts.map +0 -1
  84. package/declarations/dom/setup-registry.d.ts.map +0 -1
  85. package/declarations/index.d.ts.map +0 -1
  86. package/declarations/instance-initializers/history.d.ts.map +0 -1
  87. package/declarations/instance-initializers/webpack-hot-reload.d.ts.map +0 -1
  88. package/declarations/services/history.d.ts.map +0 -1
  89. package/declarations/services/native-router.d.ts.map +0 -1
  90. package/declarations/services/webpack-hot-reload.d.ts.map +0 -1
  91. package/declarations/setup-inspector-support.d.ts.map +0 -1
  92. package/declarations/setup.d.ts.map +0 -1
  93. package/declarations/types/glint.d.ts.map +0 -1
  94. package/declarations/types/globals.d.ts.map +0 -1
  95. package/dist/_rollupPluginBabelHelpers-DZQzmiRH.js.map +0 -1
  96. package/dist/utils/fix-glimmer-content-owner.js +0 -13
@@ -29,4 +29,3 @@ export default class InspectorSupport extends Component<InspectorSupportInterfac
29
29
  }>;
30
30
  }
31
31
  export {};
32
- //# sourceMappingURL=InspectorSupport.d.ts.map
@@ -28,4 +28,3 @@ export default class ListView<T> extends Component<ListViewInterface<T>> {
28
28
  }>;
29
29
  }
30
30
  export {};
31
- //# sourceMappingURL=ListView.d.ts.map
@@ -23,6 +23,7 @@ export default class RadListView<T = any> extends Component<RadListViewInterface
23
23
  private listView;
24
24
  private headerElement;
25
25
  private footerElement;
26
+ cleanup(listView: NativeElementNode<NativeRadListView>): void;
26
27
  get items(): {
27
28
  item: any;
28
29
  element: any;
@@ -38,4 +39,3 @@ export default class RadListView<T = any> extends Component<RadListViewInterface
38
39
  setupFooter: () => void;
39
40
  }
40
41
  export {};
41
- //# sourceMappingURL=RadListView.d.ts.map
@@ -1,4 +1,3 @@
1
1
  export { default as ListView } from "./ListView";
2
2
  export { default as RadListView } from "./RadListView";
3
3
  export { default as InspectorSupport } from "./InspectorSupport";
4
- //# sourceMappingURL=index.d.ts.map
@@ -13,4 +13,3 @@ export declare function getViewMeta(elementName: string): {
13
13
  };
14
14
  export declare function isKnownView(elementName: string): any;
15
15
  export declare function createElement<T extends keyof NativeElementsTagNameMap>(elementName: T): NativeElementsTagNameMap[T];
16
- //# sourceMappingURL=element-registry.d.ts.map
@@ -13,4 +13,3 @@ export default class FrameElement extends NativeElementNode {
13
13
  onInsertedChild(childNode: ViewNode): void;
14
14
  removeChild(childNode: NativeElementNode): void;
15
15
  }
16
- //# sourceMappingURL=FrameElement.d.ts.map
@@ -33,9 +33,16 @@ export default class NativeElementNode<T extends ViewBase | null = ViewBase> ext
33
33
  getBoundingClientRect(): {
34
34
  left: number;
35
35
  top: number;
36
+ right: number;
36
37
  bottom: number;
37
38
  width: number;
38
39
  height: number;
40
+ } | {
41
+ left: number;
42
+ top: number;
43
+ bottom: number;
44
+ width: number;
45
+ height: number;
46
+ right?: undefined;
39
47
  } | null;
40
48
  }
41
- //# sourceMappingURL=NativeElementNode.d.ts.map
@@ -3,4 +3,3 @@ import NativeElementNode from './NativeElementNode.ts';
3
3
  export default class PageElement extends NativeElementNode<Page> {
4
4
  constructor();
5
5
  }
6
- //# sourceMappingURL=PageElement.d.ts.map
@@ -1,10 +1,35 @@
1
1
  import type NativeElementNode from './native/NativeElementNode.ts';
2
- import type { ListView, StackLayout } from '@nativescript/core';
3
- import type PageElement from './native/PageElement.ts';
4
2
  export interface NativeElementsTagNameMap {
5
- 'list-view': NativeElementNode<ListView>;
6
- 'stack-layout': NativeElementNode<StackLayout>;
7
- page: PageElement;
3
+ property: NativeElementNode<null>;
8
4
  fragment: NativeElementNode<null>;
5
+ 'rad-list-view': NativeElementNode<import('nativescript-ui-listview').RadListView>;
6
+ 'list-view': NativeElementNode<import('@nativescript/core').ListView>;
7
+ 'html-view': NativeElementNode<import('@nativescript/core').HtmlView>;
8
+ 'scroll-view': NativeElementNode<import('@nativescript/core').ScrollView>;
9
+ 'text-field': NativeElementNode<import('@nativescript/core').TextField>;
10
+ 'text-view': NativeElementNode<import('@nativescript/core').TextView>;
11
+ 'web-view': NativeElementNode<import('@nativescript/core').WebView>;
12
+ 'content-view': NativeElementNode<import('@nativescript/core').ContentView>;
13
+ 'tab-view': NativeElementNode<import('@nativescript/core').TabView>;
14
+ 'tab-view-item': NativeElementNode<import('@nativescript/core').TabViewItem>;
15
+ switch: NativeElementNode<import('@nativescript/core').Switch>;
16
+ 'formatted-string': NativeElementNode<import('@nativescript/core').FormattedString>;
17
+ frame: import('../dom/native/FrameElement.ts').default;
18
+ page: import('../dom/native/PageElement.ts').default;
19
+ span: NativeElementNode<import('@nativescript/core').Span>;
20
+ 'action-bar': NativeElementNode<import('@nativescript/core').ActionBar>;
21
+ 'action-item': NativeElementNode<import('@nativescript/core').ActionItem>;
22
+ comment: NativeElementNode<import('@nativescript/core').Placeholder>;
23
+ button: NativeElementNode<import('@nativescript/core').Button>;
24
+ 'navigation-button': NativeElementNode<import('@nativescript/core').NavigationButton>;
25
+ image: NativeElementNode<import('@nativescript/core').Image>;
26
+ label: NativeElementNode<import('@nativescript/core').Label>;
27
+ 'list-picker': NativeElementNode<import('@nativescript/core').ListPicker>;
28
+ 'date-picker': NativeElementNode<import('@nativescript/core').DatePicker>;
29
+ 'dock-layout': NativeElementNode<import('@nativescript/core').DockLayout>;
30
+ 'wrap-layout': NativeElementNode<import('@nativescript/core').WrapLayout>;
31
+ 'stack-layout': NativeElementNode<import('@nativescript/core').StackLayout>;
32
+ 'grid-layout': NativeElementNode<import('@nativescript/core').GridLayout>;
33
+ 'flexbox-layout': NativeElementNode<import('@nativescript/core').FlexboxLayout>;
34
+ 'absolute-layout': NativeElementNode<import('@nativescript/core').AbsoluteLayout>;
9
35
  }
10
- //# sourceMappingURL=native-elements-tag-name-map.d.ts.map
@@ -4,4 +4,3 @@ export default class CommentNode extends ElementNode {
4
4
  text: any;
5
5
  constructor(text: any);
6
6
  }
7
- //# sourceMappingURL=CommentNode.d.ts.map
@@ -17,11 +17,15 @@ export default class DocumentNode extends ViewNode {
17
17
  };
18
18
  static getInstance(): DocumentNode;
19
19
  constructor();
20
+ createEvent(eventInterface: string): {
21
+ eventInterface: string;
22
+ initEvent(type: string, bubbles: boolean, cancelable: boolean): void;
23
+ };
20
24
  createComment(text: string): CommentNode;
21
- static createPropertyNode(tagName: string, propertyName: string): PropertyNode;
25
+ static createPropertyNode(tagName: string): PropertyNode;
22
26
  createElement(name: string): any;
23
27
  static createElement<T extends keyof NativeElementsTagNameMap>(tagName: T): NativeElementsTagNameMap[T];
24
- createElementNS(_namespace: any, tagName: keyof NativeElementsTagNameMap): PageElement | NativeElementNode<import("@nativescript/core").ListView> | NativeElementNode<import("@nativescript/core").StackLayout> | NativeElementNode<null>;
28
+ createElementNS(_namespace: any, tagName: keyof NativeElementsTagNameMap): PageElement | NativeElementNode<import("@nativescript/core").Placeholder> | NativeElementNode<null> | NativeElementNode<import("nativescript-ui-listview").RadListView> | NativeElementNode<import("@nativescript/core").ListView> | NativeElementNode<import("@nativescript/core").HtmlView> | NativeElementNode<import("@nativescript/core").ScrollView> | NativeElementNode<import("@nativescript/core").TextField> | NativeElementNode<import("@nativescript/core").TextView> | NativeElementNode<import("@nativescript/core").WebView> | NativeElementNode<import("@nativescript/core").ContentView> | NativeElementNode<import("@nativescript/core").TabView> | NativeElementNode<import("@nativescript/core").TabViewItem> | NativeElementNode<import("@nativescript/core").Switch> | NativeElementNode<import("@nativescript/core").FormattedString> | import("../native/FrameElement.ts").default | NativeElementNode<import("@nativescript/core").Span> | NativeElementNode<import("@nativescript/core").ActionBar> | NativeElementNode<import("@nativescript/core").ActionItem> | NativeElementNode<import("@nativescript/core").Button> | NativeElementNode<import("@nativescript/core").NavigationButton> | NativeElementNode<import("@nativescript/core").Image> | NativeElementNode<import("@nativescript/core").Label> | NativeElementNode<import("@nativescript/core").ListPicker> | NativeElementNode<import("@nativescript/core").DatePicker> | NativeElementNode<import("@nativescript/core").DockLayout> | NativeElementNode<import("@nativescript/core").WrapLayout> | NativeElementNode<import("@nativescript/core").StackLayout> | NativeElementNode<import("@nativescript/core").GridLayout> | NativeElementNode<import("@nativescript/core").FlexboxLayout> | NativeElementNode<import("@nativescript/core").AbsoluteLayout>;
25
29
  createTextNode(text: string): TextNode;
26
30
  addEventListener(event: string, callback: EventListener): void;
27
31
  removeEventListener(event: string, handler: EventListener): void;
@@ -44,4 +48,3 @@ export default class DocumentNode extends ViewNode {
44
48
  getAttribute(): string;
45
49
  } | undefined;
46
50
  }
47
- //# sourceMappingURL=DocumentNode.d.ts.map
@@ -7,12 +7,16 @@ export interface IClassList {
7
7
  }
8
8
  export default class ElementNode extends ViewNode {
9
9
  _classList: IClassList;
10
+ _id: string;
11
+ static ELEMENT_NODE: number;
12
+ static ATTRIBUTE_NODE: number;
13
+ static TEXT_NODE: number;
14
+ static DOCUMENT_NODE: number;
10
15
  constructor(tagName: string);
11
16
  get id(): string;
12
- set id(value: string);
17
+ set id(v: string);
13
18
  get classList(): IClassList;
14
19
  appendChild(childNode: ViewNode): void;
15
20
  insertBefore(childNode: ViewNode, referenceNode: ViewNode): void;
16
21
  removeChild(childNode: ViewNode): void;
17
22
  }
18
- //# sourceMappingURL=ElementNode.d.ts.map
@@ -1,13 +1,11 @@
1
1
  import ElementNode from './ElementNode.ts';
2
2
  import ViewNode from './ViewNode.ts';
3
3
  export default class PropertyNode extends ElementNode {
4
- propertyName: string;
5
- propertyTagName: string;
6
- constructor(tagName: string, propertyName: string);
4
+ constructor(tagName: string);
5
+ get propertyName(): string;
7
6
  onInsertedChild(): void;
8
7
  onRemovedChild(): void;
9
8
  toString(): string;
10
9
  setOnNode(parent: ViewNode | null): void;
11
10
  clearOnNode(parent: ViewNode): void;
12
11
  }
13
- //# sourceMappingURL=PropertyNode.d.ts.map
@@ -7,4 +7,3 @@ export default class TextNode extends ViewNode {
7
7
  get parentNode(): ViewNode | null;
8
8
  setText(text: string): void;
9
9
  }
10
- //# sourceMappingURL=TextNode.d.ts.map
@@ -12,6 +12,7 @@ export default class ViewNode {
12
12
  nextSibling: ViewNode | null;
13
13
  _ownerDocument: any;
14
14
  _meta: any;
15
+ get textContent(): string;
15
16
  getElementById(id: string): any;
16
17
  getElementByClass(klass: string): any;
17
18
  getElementByTagName(tagName: string): any;
@@ -46,4 +47,3 @@ export default class ViewNode {
46
47
  height: number;
47
48
  } | null;
48
49
  }
49
- //# sourceMappingURL=ViewNode.d.ts.map
@@ -2,4 +2,3 @@ import { View } from '@nativescript/core';
2
2
  import { type ComponentMeta } from './native/NativeElementNode.ts';
3
3
  export declare function registerNativeElement(elementName: string, resolver: () => typeof View, meta?: ComponentMeta | null): void;
4
4
  export declare function registerElements(): void;
5
- //# sourceMappingURL=setup-registry.d.ts.map
@@ -1,4 +1,3 @@
1
1
  export { setup } from './setup.ts';
2
2
  export { setupInspectorSupport } from './setup-inspector-support.ts';
3
- export * from './components/index.ts';
4
- //# sourceMappingURL=index.d.ts.map
3
+ export * from "./components/index";
@@ -5,4 +5,3 @@ declare const Initializer: {
5
5
  initialize(application: ApplicationInstance): void;
6
6
  };
7
7
  export default Initializer;
8
- //# sourceMappingURL=history.d.ts.map
@@ -4,4 +4,3 @@ declare const _default: {
4
4
  initialize: typeof initialize;
5
5
  };
6
6
  export default _default;
7
- //# sourceMappingURL=webpack-hot-reload.d.ts.map
@@ -7,6 +7,8 @@ export default class HistoryService extends Service {
7
7
  nativeRouter: NativeRouter;
8
8
  stack: Transition[];
9
9
  setup(): void;
10
+ activityBackPressed: (args: {
11
+ cancel: boolean;
12
+ }) => void;
10
13
  back: () => boolean;
11
14
  }
12
- //# sourceMappingURL=history.d.ts.map
@@ -12,4 +12,3 @@ export default class NativeRouter extends Service {
12
12
  animated: boolean;
13
13
  }): Transition;
14
14
  }
15
- //# sourceMappingURL=native-router.d.ts.map
@@ -11,4 +11,3 @@ declare module '@ember/service' {
11
11
  'hot-reload': WebpackHotReload;
12
12
  }
13
13
  }
14
- //# sourceMappingURL=webpack-hot-reload.d.ts.map
@@ -1,2 +1 @@
1
1
  export declare function setupInspectorSupport(config: any): void;
2
- //# sourceMappingURL=setup-inspector-support.d.ts.map
@@ -1,2 +1 @@
1
1
  export declare function setup(): void;
2
- //# sourceMappingURL=setup.d.ts.map
@@ -1,11 +1,12 @@
1
1
  import NativeElementNode from '../dom/native/NativeElementNode';
2
2
  import '@glint/environment-ember-template-imports/globals';
3
3
  import '@glint/template/-private/dsl/emit';
4
- import type { ComponentLike } from '@glint/template';
4
+ import type { ComponentLike, ModifierLike } from '@glint/template';
5
5
  import type { ViewBase } from '@nativescript/core';
6
6
  import 'ember-modifier';
7
7
  import type { EmptyObject, NamedArgs, PositionalArgs } from 'ember-modifier/-private/signature';
8
8
  import type { FunctionBasedModifier, Teardown } from 'ember-modifier/-private/function-based/modifier';
9
+ import type { NativeElementsTagNameMap } from '../dom/native-elements-tag-name-map.ts';
9
10
  declare module 'ember-modifier' {
10
11
  type ViewNode<T extends ViewBase> = import('../dom/native/NativeElementNode').default<T>;
11
12
  function modifier<E extends ViewNode<T>, P extends unknown[] = [], N = EmptyObject, T extends ViewBase = ViewBase>(fn: (element: E, positional: P, named: N) => void | Teardown): FunctionBasedModifier<{
@@ -41,7 +42,26 @@ declare module '@glint/environment-ember-template-imports/globals' {
41
42
  }
42
43
  }
43
44
  declare module '@glint/template/-private/dsl/emit' {
45
+ function emitElement<Name extends string>(name: Name): {
46
+ element: Name extends keyof NativeElementsTagNameMap ? NativeElementsTagNameMap[Name] : NativeElementNode<null>;
47
+ };
48
+ function applySplattributes<SourceElement extends NativeElementNode<any>, TargetElement extends SourceElement>(source: SourceElement, target: TargetElement): void;
44
49
  function applyAttributes<T extends ViewBase>(element: NativeElementNode<T>, attrs: Record<string, any>): void;
45
50
  function applySplattributes<T extends ViewBase, SourceElement extends NativeElementNode<T>, TargetElement extends SourceElement>(source: SourceElement, target: TargetElement): void;
46
51
  }
47
- //# sourceMappingURL=glint.d.ts.map
52
+ declare module '@ember/modifier' {
53
+ interface OnModifierArgs {
54
+ capture?: boolean;
55
+ once?: boolean;
56
+ passive?: boolean;
57
+ }
58
+ type OnModifierType = abstract new <Name extends string>() => InstanceType<ModifierLike<{
59
+ Element: NativeElementNode<ViewBase>;
60
+ Args: {
61
+ Named: OnModifierArgs;
62
+ Positional: [name: Name, callback: (event: any) => void];
63
+ };
64
+ }>>;
65
+ interface OnModifier extends OnModifierType {
66
+ }
67
+ }
@@ -22,38 +22,35 @@ declare module 'loader.js' {
22
22
  const require: AnyFunction;
23
23
  const define: AnyFunction;
24
24
  }
25
- type ViewBase = import('@nativescript/core').ViewBase;
26
- type NativeElementNode<T extends ViewBase> = import('../dom/native/NativeElementNode').default<T>;
27
25
  interface HTMLElementTagNameMap {
28
- 'rad-list-view': NativeElementNode<import('nativescript-ui-listview').RadListView>;
29
- 'list-view': NativeElementNode<import('@nativescript/core').ListView>;
30
- 'html-view': NativeElementNode<import('@nativescript/core').HtmlView>;
31
- 'scroll-view': NativeElementNode<import('@nativescript/core').ScrollView>;
32
- 'text-field': NativeElementNode<import('@nativescript/core').TextField>;
33
- 'text-view': NativeElementNode<import('@nativescript/core').TextView>;
34
- 'web-view': NativeElementNode<import('@nativescript/core').WebView>;
35
- 'content-view': NativeElementNode<import('@nativescript/core').ContentView>;
36
- 'tab-view': NativeElementNode<import('@nativescript/core').TabView>;
37
- 'tab-view-item': NativeElementNode<import('@nativescript/core').TabViewItem>;
38
- switch: NativeElementNode<import('@nativescript/core').Switch>;
39
- 'formatted-string': NativeElementNode<import('@nativescript/core').FormattedString>;
26
+ 'rad-list-view': import('../dom/native/NativeElementNode').default<import('nativescript-ui-listview').RadListView>;
27
+ 'list-view': import('../dom/native/NativeElementNode').default<import('@nativescript/core').ListView>;
28
+ 'html-view': import('../dom/native/NativeElementNode').default<import('@nativescript/core').HtmlView>;
29
+ 'scroll-view': import('../dom/native/NativeElementNode').default<import('@nativescript/core').ScrollView>;
30
+ 'text-field': import('../dom/native/NativeElementNode').default<import('@nativescript/core').TextField>;
31
+ 'text-view': import('../dom/native/NativeElementNode').default<import('@nativescript/core').TextView>;
32
+ 'web-view': import('../dom/native/NativeElementNode').default<import('@nativescript/core').WebView>;
33
+ 'content-view': import('../dom/native/NativeElementNode').default<import('@nativescript/core').ContentView>;
34
+ 'tab-view': import('../dom/native/NativeElementNode').default<import('@nativescript/core').TabView>;
35
+ 'tab-view-item': import('../dom/native/NativeElementNode').default<import('@nativescript/core').TabViewItem>;
36
+ switch: import('../dom/native/NativeElementNode').default<import('@nativescript/core').Switch>;
37
+ 'formatted-string': import('../dom/native/NativeElementNode').default<import('@nativescript/core').FormattedString>;
40
38
  frame: import('../dom/native/FrameElement.ts').default;
41
39
  page: import('../dom/native/PageElement.ts').default;
42
- span: NativeElementNode<import('@nativescript/core').Span>;
43
- 'action-bar': NativeElementNode<import('@nativescript/core').ActionBar>;
44
- 'action-item': NativeElementNode<import('@nativescript/core').ActionItem>;
45
- comment: NativeElementNode<import('@nativescript/core').Placeholder>;
46
- button: NativeElementNode<import('@nativescript/core').Button>;
47
- 'navigation-button': NativeElementNode<import('@nativescript/core').NavigationButton>;
48
- image: NativeElementNode<import('@nativescript/core').Image>;
49
- label: NativeElementNode<import('@nativescript/core').Label>;
50
- 'list-picker': NativeElementNode<import('@nativescript/core').ListPicker>;
51
- 'date-picker': NativeElementNode<import('@nativescript/core').DatePicker>;
52
- 'dock-layout': NativeElementNode<import('@nativescript/core').DockLayout>;
53
- 'wrap-layout': NativeElementNode<import('@nativescript/core').WrapLayout>;
54
- 'stack-layout': NativeElementNode<import('@nativescript/core').StackLayout>;
55
- 'grid-layout': NativeElementNode<import('@nativescript/core').GridLayout>;
56
- 'flexbox-layout': NativeElementNode<import('@nativescript/core').FlexboxLayout>;
57
- 'absolute-layout': NativeElementNode<import('@nativescript/core').AbsoluteLayout>;
40
+ span: import('../dom/native/NativeElementNode').default<import('@nativescript/core').Span>;
41
+ 'action-bar': import('../dom/native/NativeElementNode').default<import('@nativescript/core').ActionBar>;
42
+ 'action-item': import('../dom/native/NativeElementNode').default<import('@nativescript/core').ActionItem>;
43
+ comment: import('../dom/native/NativeElementNode').default<import('@nativescript/core').Placeholder>;
44
+ button: import('../dom/native/NativeElementNode').default<import('@nativescript/core').Button>;
45
+ 'navigation-button': import('../dom/native/NativeElementNode').default<import('@nativescript/core').NavigationButton>;
46
+ image: import('../dom/native/NativeElementNode').default<import('@nativescript/core').Image>;
47
+ label: import('../dom/native/NativeElementNode').default<import('@nativescript/core').Label>;
48
+ 'list-picker': import('../dom/native/NativeElementNode').default<import('@nativescript/core').ListPicker>;
49
+ 'date-picker': import('../dom/native/NativeElementNode').default<import('@nativescript/core').DatePicker>;
50
+ 'dock-layout': import('../dom/native/NativeElementNode').default<import('@nativescript/core').DockLayout>;
51
+ 'wrap-layout': import('../dom/native/NativeElementNode').default<import('@nativescript/core').WrapLayout>;
52
+ 'stack-layout': import('../dom/native/NativeElementNode').default<import('@nativescript/core').StackLayout>;
53
+ 'grid-layout': import('../dom/native/NativeElementNode').default<import('@nativescript/core').GridLayout>;
54
+ 'flexbox-layout': import('../dom/native/NativeElementNode').default<import('@nativescript/core').FlexboxLayout>;
55
+ 'absolute-layout': import('../dom/native/NativeElementNode').default<import('@nativescript/core').AbsoluteLayout>;
58
56
  }
59
- //# sourceMappingURL=globals.d.ts.map
@@ -2,16 +2,16 @@ function _applyDecoratedDescriptor(i, e, r, n, l) {
2
2
  var a = {};
3
3
  return Object.keys(n).forEach(function (i) {
4
4
  a[i] = n[i];
5
- }), a.enumerable = !!a.enumerable, a.configurable = !!a.configurable, ("value" in a || a.initializer) && (a.writable = !0), a = r.slice().reverse().reduce(function (r, n) {
5
+ }), a.enumerable = !!a.enumerable, a.configurable = !!a.configurable, ("value" in a || a.initializer) && (a.writable = true), a = r.slice().reverse().reduce(function (r, n) {
6
6
  return n(i, e, r) || r;
7
7
  }, a), void 0 === a.initializer ? (Object.defineProperty(i, e, a), null) : a;
8
8
  }
9
9
  function _defineProperty(e, r, t) {
10
10
  return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, {
11
11
  value: t,
12
- enumerable: !0,
13
- configurable: !0,
14
- writable: !0
12
+ enumerable: true,
13
+ configurable: true,
14
+ writable: true
15
15
  }) : e[r] = t, e;
16
16
  }
17
17
  function _initializerDefineProperty(e, i, r, l) {
@@ -26,7 +26,7 @@ function _toPrimitive(t, r) {
26
26
  if ("object" != typeof t || !t) return t;
27
27
  var e = t[Symbol.toPrimitive];
28
28
  if (void 0 !== e) {
29
- var i = e.call(t, r || "default");
29
+ var i = e.call(t, r);
30
30
  if ("object" != typeof i) return i;
31
31
  throw new TypeError("@@toPrimitive must return a primitive value.");
32
32
  }
@@ -38,4 +38,4 @@ function _toPropertyKey(t) {
38
38
  }
39
39
 
40
40
  export { _defineProperty as _, _applyDecoratedDescriptor as a, _initializerDefineProperty as b };
41
- //# sourceMappingURL=_rollupPluginBabelHelpers-DZQzmiRH.js.map
41
+ //# sourceMappingURL=_rollupPluginBabelHelpers-apNPIsxw.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"_rollupPluginBabelHelpers-apNPIsxw.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -1,4 +1,4 @@
1
- import { _ as _defineProperty } from '../_rollupPluginBabelHelpers-DZQzmiRH.js';
1
+ import { _ as _defineProperty } from '../_rollupPluginBabelHelpers-apNPIsxw.js';
2
2
  import Component from '@glimmer/component';
3
3
  import { modifier } from 'ember-modifier';
4
4
  import { precompileTemplate } from '@ember/template-compilation';
@@ -12,10 +12,6 @@ const ref = modifier(function setRef(element, [context, key]) {
12
12
  class InspectorSupport extends Component {
13
13
  constructor(...args) {
14
14
  super(...args);
15
- _defineProperty(this, "highlight", void 0);
16
- _defineProperty(this, "tooltip", void 0);
17
- _defineProperty(this, "page", void 0);
18
- _defineProperty(this, "ownerDocument", void 0);
19
15
  _defineProperty(this, "setupInspector", () => {
20
16
  let i = setInterval(() => {
21
17
  const viewInspection = globalThis.EmberInspector?.viewDebug?.viewInspection;
@@ -1 +1 @@
1
- {"version":3,"file":"InspectorSupport.js","sources":["../../src/components/InspectorSupport.gts"],"sourcesContent":["import Component from '@glimmer/component';\nimport { modifier } from 'ember-modifier';\nimport ViewNode from '../dom/nodes/ViewNode.ts';\nimport NativeElementNode from '../dom/native/NativeElementNode.ts';\nimport DocumentNode from '../dom/nodes/DocumentNode.ts';\nimport type PageElement from '../dom/native/PageElement.ts';\n\nconst ref = modifier(function setRef(element: any, [context, key]: any) {\n // console.log('ref', element, context, key);\n context[key] = element;\n});\n\ninterface InspectorSupportInterface {\n Blocks: {\n default: [];\n };\n}\n\nexport default class InspectorSupport extends Component<InspectorSupportInterface> {\n declare highlight: NativeElementNode;\n declare tooltip: NativeElementNode;\n declare page: PageElement;\n declare ownerDocument: DocumentNode;\n setupInspector = () => {\n let i = setInterval(() => {\n const viewInspection =\n globalThis.EmberInspector?.viewDebug?.viewInspection;\n if (viewInspection && this.tooltip) {\n this.tooltip.querySelector = () => {\n return {\n style: {},\n };\n };\n viewInspection._showTooltip = () => {};\n const _showHighlight = viewInspection._showHighlight;\n viewInspection._hideHighlight = () => {\n this.highlight.setAttribute('visibility', 'collapse');\n };\n viewInspection._showHighlight = (node: ViewNode, rect: any) => {\n _showHighlight.call(this, node, rect);\n this.highlight.setAttribute('visibility', 'visible');\n const style = this.highlight.style as any;\n style.width = (style.width as any).value;\n style.height = (style.height as any).value;\n const pos = this.page.nativeView.getLocationInWindow() || {\n x: 0,\n y: 0,\n };\n this.highlight.setAttribute(\n 'left',\n Number(style.left!.replace('px', '')) - pos.x,\n );\n this.highlight.setAttribute(\n 'top',\n Number(style.top!.replace('px', '')) - pos.y,\n );\n };\n viewInspection.highlight = this.highlight;\n viewInspection.tooltip = this.tooltip;\n const id = viewInspection.id;\n\n viewInspection.highlight.id = `ember-inspector-highlight-${id}`;\n viewInspection.tooltip.id = `ember-inspector-tooltip-${id}`;\n clearInterval(i);\n }\n }, 1000);\n };\n\n setupHighlight = modifier(\n function setupHighlight(\n this: InspectorSupport,\n element: NativeElementNode,\n ) {\n this.highlight = element;\n this.highlight.setAttribute('visibility', 'collapse');\n this.ownerDocument = element.ownerDocument!;\n }.bind(this),\n );\n setupTooltip = modifier(\n function setupTooltip(this: InspectorSupport, element: NativeElementNode) {\n this.tooltip = element;\n this.tooltip.setAttribute('visibility', 'collapse');\n }.bind(this),\n );\n <template>\n <absolute-layout {{ref this 'page'}}>\n <html-view {{this.setupHighlight}} />\n <html-view {{this.setupTooltip}} zIndex='99' />\n {{(this.setupInspector)}}\n <content-view left='0' top='0' width='100%' height='100%'>\n <frame>\n {{yield}}\n </frame>\n </content-view>\n </absolute-layout>\n </template>\n}\n"],"names":["ref","modifier","setRef","element","context","key","InspectorSupport","Component","constructor","args","_defineProperty","setupInspector","i","setInterval","viewInspection","globalThis","EmberInspector","viewDebug","tooltip","querySelector","style","_showTooltip","_showHighlight","_hideHighlight","highlight","setAttribute","node","rect","call","width","value","height","pos","page","nativeView","getLocationInWindow","x","y","Number","left","replace","top","id","clearInterval","setupHighlight","ownerDocument","bind","setupTooltip","_InspectorSupport","template_ab6b6176510c455d9eced5d85a79c850","strictMode","scope"],"mappings":";;;;;;;AAOA,MAAMA,GAAA,GAAMC,QAAS,CAAA,SAASC,MAAOA,CAAAC,OAAY,EAAE,CAACC,OAAS,EAAAC,GAAA,CAAS,EAAA;AACpE;AACAD,EAAAA,OAAO,CA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AA,CAAQ0C,aAAa;AAC5C,KAAE,CAAAC,IAAI,CAAC,IAAI,CACX,CAAA,CAAA;AAAApC,IAAAA,eAAA,uBACaT,SACb,SAAS8C,YAAAA,CAAqC5C,OAA0B,EAAA;MACtE,IAAI,CAACe,OAAO,GAAGf,OAAA;MACf,IAAI,CAACe,OAAO,CAACO,YAAY,CAAC,YAAc,EAAA,UAAA,CAAA;AAC1C,KAAE,CAAAqB,IAAI,CAAC,IAAI,CACX,CAAA,CAAA;AAAA;AAaJ;AAAAE,iBAAA,GA9EqB1C;AAkEnB2C,oBAAAA,CAAAA,kBAAAA,CAWA,2WAAA,EAAA;EAAAC,UAAA,EAAA,IAAA;AAAAC,EAAAA,KAAA,EAAAA,OAAA;AAAAnD,IAAAA;AAAA,GAAA;AAAU,CAAA,CAAA,EAAAgD,iBAAA,CAAA;;;;"}
1
+ {"version":3,"file":"InspectorSupport.js","sources":["../../src/components/InspectorSupport.gts"],"sourcesContent":["import Component from '@glimmer/component';\nimport { modifier } from 'ember-modifier';\nimport ViewNode from '../dom/nodes/ViewNode.ts';\nimport NativeElementNode from '../dom/native/NativeElementNode.ts';\nimport DocumentNode from '../dom/nodes/DocumentNode.ts';\nimport type PageElement from '../dom/native/PageElement.ts';\n\nconst ref = modifier(function setRef(element: any, [context, key]: any) {\n // console.log('ref', element, context, key);\n context[key] = element;\n});\n\ninterface InspectorSupportInterface {\n Blocks: {\n default: [];\n };\n}\n\nexport default class InspectorSupport extends Component<InspectorSupportInterface> {\n declare highlight: NativeElementNode;\n declare tooltip: NativeElementNode;\n declare page: PageElement;\n declare ownerDocument: DocumentNode;\n setupInspector = () => {\n let i = setInterval(() => {\n const viewInspection =\n globalThis.EmberInspector?.viewDebug?.viewInspection;\n if (viewInspection && this.tooltip) {\n this.tooltip.querySelector = () => {\n return {\n style: {},\n };\n };\n viewInspection._showTooltip = () => {};\n const _showHighlight = viewInspection._showHighlight;\n viewInspection._hideHighlight = () => {\n this.highlight.setAttribute('visibility', 'collapse');\n };\n viewInspection._showHighlight = (node: ViewNode, rect: any) => {\n _showHighlight.call(this, node, rect);\n this.highlight.setAttribute('visibility', 'visible');\n const style = this.highlight.style as any;\n style.width = (style.width as any).value;\n style.height = (style.height as any).value;\n const pos = this.page.nativeView.getLocationInWindow() || {\n x: 0,\n y: 0,\n };\n this.highlight.setAttribute(\n 'left',\n Number(style.left!.replace('px', '')) - pos.x,\n );\n this.highlight.setAttribute(\n 'top',\n Number(style.top!.replace('px', '')) - pos.y,\n );\n };\n viewInspection.highlight = this.highlight;\n viewInspection.tooltip = this.tooltip;\n const id = viewInspection.id;\n\n viewInspection.highlight.id = `ember-inspector-highlight-${id}`;\n viewInspection.tooltip.id = `ember-inspector-tooltip-${id}`;\n clearInterval(i);\n }\n }, 1000);\n };\n\n setupHighlight = modifier(\n function setupHighlight(\n this: InspectorSupport,\n element: NativeElementNode,\n ) {\n this.highlight = element;\n this.highlight.setAttribute('visibility', 'collapse');\n this.ownerDocument = element.ownerDocument!;\n }.bind(this),\n );\n setupTooltip = modifier(\n function setupTooltip(this: InspectorSupport, element: NativeElementNode) {\n this.tooltip = element;\n this.tooltip.setAttribute('visibility', 'collapse');\n }.bind(this),\n );\n <template>\n <absolute-layout {{ref this 'page'}}>\n <html-view {{this.setupHighlight}} />\n <html-view {{this.setupTooltip}} zIndex='99' />\n {{(this.setupInspector)}}\n <content-view left='0' top='0' width='100%' height='100%'>\n <frame>\n {{yield}}\n </frame>\n </content-view>\n </absolute-layout>\n </template>\n}\n"],"names":["ref","modifier","setRef","element","context","key","InspectorSupport","Component","constructor","args","_defineProperty","setupInspector","i","setInterval","viewInspection","globalThis","EmberInspector","viewDebug","tooltip","querySelector","style","_showTooltip","_showHighlight","_hideHighlight","highlight","setAttribute","node","rect","call","width","value","height","pos","page","nativeView","getLocationInWindow","x","y","Number","left","replace","top","id","clearInterval","setupHighlight","ownerDocument","bind","setupTooltip","_InspectorSupport","template_fd9b2463e5f141cfb5666b64daa1f11a","strictMode","scope"],"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BACaT,SACb,SAAS8C,YAAAA,CAAqC5C,OAA0B,EAAA;MACtE,IAAI,CAACe,OAAO,GAAGf,OAAA;MACf,IAAI,CAACe,OAAO,CAACO,YAAY,CAAC,YAAc,EAAA,UAAA,CAAA;AAC1C,KAAE,CAAAqB,IAAI,CAAC,IAAI,CACX,CAAA,CAAA;AAAA;AAaJ;AAAAE,iBAAA,GA9EqB1C;AAkEnB2C,oBAAAA,CAAAA,kBAAAA,CAWA,2WAAA,EAAA;EAAAC,UAAA,EAAA,IAAA;AAAAC,EAAAA,KAAA,EAAAA,OAAA;AAAAnD,IAAAA;AAAA,GAAA;AAAU,CAAA,CAAA,EAAAgD,iBAAA,CAAA;;;;"}
@@ -1,4 +1,4 @@
1
- import { a as _applyDecoratedDescriptor, b as _initializerDefineProperty, _ as _defineProperty } from '../_rollupPluginBabelHelpers-DZQzmiRH.js';
1
+ import { _ as _defineProperty, a as _applyDecoratedDescriptor, b as _initializerDefineProperty } from '../_rollupPluginBabelHelpers-apNPIsxw.js';
2
2
  import Component from '@glimmer/component';
3
3
  import { modifier } from 'ember-modifier';
4
4
  import { tracked } from '@glimmer/tracking';
@@ -16,6 +16,7 @@ let ListView = (_class = (_ListView = class ListView extends Component {
16
16
  function _getDefaultItemContent(index) {
17
17
  listViewComponent.cleanup(listView);
18
18
  const sl = DocumentNode.createElement('stack-layout');
19
+ listView.appendChild(sl);
19
20
  listViewComponent.elementRefs.push({
20
21
  element: sl,
21
22
  item: null,
@@ -33,7 +34,7 @@ let ListView = (_class = (_ListView = class ListView extends Component {
33
34
  }.bind(this)));
34
35
  }
35
36
  get items() {
36
- return this.elementRefs.map(({
37
+ return this.elementRefs.filter(x => x.index < this.args.items.length).map(({
37
38
  element,
38
39
  index
39
40
  }) => {
@@ -48,7 +49,7 @@ let ListView = (_class = (_ListView = class ListView extends Component {
48
49
  for (const elementRef of this.elementRefs) {
49
50
  const n = elementRef.element.nativeView.nativeViewProtected;
50
51
  if (!n || !n.getWindowToken()) {
51
- elementRef.element.parentNode.removeChild(elementRef.element);
52
+ elementRef.element.parentNode?.removeChild(elementRef.element);
52
53
  listView.nativeView._realizedItems.delete(elementRef.element.nativeView);
53
54
  }
54
55
  }
@@ -1 +1 @@
1
- {"version":3,"file":"ListView.js","sources":["../../src/components/ListView.gts"],"sourcesContent":["import Component from '@glimmer/component';\nimport { modifier } from 'ember-modifier';\nimport type {\n ListView as NativeListView,\n StackLayout,\n} from '@nativescript/core';\nimport { tracked } from '@glimmer/tracking';\nimport NativeElementNode from '../dom/native/NativeElementNode.ts';\nimport DocumentNode from '../dom/nodes/DocumentNode.ts';\n\ninterface ListViewInterface<T> {\n Element: NativeElementNode<NativeListView>;\n Args: {\n items: T[];\n };\n Blocks: {\n item: [T | null];\n };\n}\n\ntype Ref<T> = {\n index: number;\n item: T | null;\n element: NativeElementNode<any>;\n};\n\nexport default class ListView<T> extends Component<ListViewInterface<T>> {\n @tracked elementRefs: Ref<T>[] = [];\n\n get items(): Ref<T>[] {\n return this.elementRefs.map(({ element, index }) => {\n return {\n index,\n item: this.args.items[index] || null,\n element,\n };\n });\n }\n\n cleanup(listView: NativeElementNode<NativeListView>) {\n for (const elementRef of this.elementRefs) {\n const n = elementRef.element.nativeView.nativeViewProtected;\n if (!n || !n.getWindowToken()) {\n elementRef.element.parentNode!.removeChild(elementRef.element);\n ((listView.nativeView as any)._realizedItems as any).delete(\n elementRef.element.nativeView,\n );\n }\n }\n this.elementRefs = this.elementRefs.filter(\n (e) => !!e.element.nativeView.nativeViewProtected?.getWindowToken(),\n ) as Ref<T>[];\n }\n\n setupListView = modifier(\n function setupListView(\n this: ListView<T>,\n listView: NativeElementNode<NativeListView>,\n ) {\n const listViewComponent = this;\n function _getDefaultItemContent(index: number) {\n listViewComponent.cleanup(listView);\n const sl = DocumentNode.createElement('stack-layout');\n listViewComponent.elementRefs.push({\n element: sl,\n item: null,\n index,\n });\n listViewComponent.elementRefs = [...listViewComponent.elementRefs];\n return sl.nativeView;\n }\n (listView.nativeView as any)._getDefaultItemContent =\n _getDefaultItemContent;\n (listView.nativeView as any)._prepareItem = (\n stackLayout: StackLayout,\n index: number,\n ) => {\n const ref = listViewComponent.elementRefs.find(\n (e) => e.element.nativeView === stackLayout,\n )!;\n ref.index = index;\n listViewComponent.elementRefs = [...listViewComponent.elementRefs];\n };\n }.bind(this),\n );\n\n <template>\n <list-view {{this.setupListView}} items={{@items}} ...attributes />\n {{#each this.items as |item|}}\n {{#in-element item.element}}\n {{yield item.item to='item'}}\n {{/in-element}}\n {{/each}}\n </template>\n}\n"],"names":["ListView","_class","_ListView","Component","constructor","args","_initializerDefineProperty","_descriptor","_defineProperty","modifier","setupListView","listView","listViewComponent","_getDefaultItemContent","index","cleanup","sl","DocumentNode","createElement","elementRefs","push","element","item","nativeView","_prepareItem","stackLayout","ref","find","e","bind","items","map","elementRef","n","nativeViewProtected","getWindowToken","parentNode","removeChild","_realizedItems","delete","filter","setComponentTemplate","template_0a1c6e65ab754f1d9f3326942a14b273","strictMode","_applyDecoratedDescriptor","prototype","tracked"],"mappings":";;;;;;;;;AA0BqBA,IAAAA,QAAA,IAAAC,MAAA,IAAAC,SAAA,GAAN,MAAMF,QAAA,SAAoBG,SAAA,CAA4B;AAAAC,EAAAA,WAAAA,CAAA,GAAAC,IAAA,EAAA;AAAA,IAAA,KAAA,CAAA,GAAAA,IAAA,CAAA;AAAAC,IAAAA,0BAAA,sBAAAC,WAAA,EAAA,IAAA,CAAA;AAAAC,IAAAA,eAAA,wBA4BnDC,QAAA,CACd,SAASC,aACPA,CACAC,QAA2C,EAAA;MAE3C,MAAMC,oBAAoB,IAAI;MAC9B,SAASC,sBAAAA,CAAuBC,KAAa,EAAA;AAC3CF,QAAAA,iBAAA,CAAkBG,OAAO,CAACJ,QAAA,CAAA;AAC1B,QAAA,MAAMK,EAAA,GAAKC,YAAa,CAAAC,aAAa,CAAC,cAAA,CAAA;AACtCN,QAAAA,iBAAkB,CAAAO,WAAW,CAACC,IAAI,CAAC;AACjCC,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;AAC3DV,QAAAA,QAAA,CAASY,UAAU,CAASe,cAAc,CAASC,MAAM,CACzDP,UAAW,CAAAX,OAAO,CAACE,UAAU,CAAA;AAEjC;AACF;IACA,IAAI,CAACJ,WAAW,GAAG,IAAI,CAACA,WAAW,CAACqB,MAAM,CACvCZ,KAAM,CAAC,CAACA,EAAEP,OAAO,CAACE,UAAU,CAACW,mBAAmB,EAAEC,cAAA,EAAA,CAC5C;AACX;AA0CF,CAAA,EAAAM,oBAAA,CAREC,kBAAAA,CAOA,sOAAA,EAAA;EAAAC,UAAA,EAAA;AAAU,CAAA,CAAA,EAAAzC,SAAA,CAAA,EAAAA,SAAA,CAAAK,EAAAA,WAAA,GAAAqC,yBAAA,CAAA3C,MAAA,CAAA4C,SAAA,kBAlETC,OAAAA,CAAAA,EAAAA;EAAAA,YAAAA,EAAAA,IAAAA;EAAAA,UAAAA,EAAAA,IAAAA;EAAAA,QAAAA,EAAAA,IAAAA;AAAAA,EAAAA,WAAAA,cAAAA;AAAAA,IAAAA,OAAgC,EAAE;AAAA;AAAA,CAAA,CAAA,EAAA7C,MAAA;;;;"}
1
+ {"version":3,"file":"ListView.js","sources":["../../src/components/ListView.gts"],"sourcesContent":["import Component from '@glimmer/component';\nimport { modifier } from 'ember-modifier';\nimport type {\n ListView as NativeListView,\n StackLayout,\n} from '@nativescript/core';\nimport { tracked } from '@glimmer/tracking';\nimport NativeElementNode from '../dom/native/NativeElementNode.ts';\nimport DocumentNode from '../dom/nodes/DocumentNode.ts';\n\ninterface ListViewInterface<T> {\n Element: NativeElementNode<NativeListView>;\n Args: {\n items: T[];\n };\n Blocks: {\n item: [T | null];\n };\n}\n\ntype Ref<T> = {\n index: number;\n item: T | null;\n element: NativeElementNode<any>;\n};\n\nexport default class ListView<T> extends Component<ListViewInterface<T>> {\n @tracked elementRefs: Ref<T>[] = [];\n\n get items(): Ref<T>[] {\n return this.elementRefs\n .filter((x) => x.index < this.args.items.length)\n .map(({ element, index }) => {\n return {\n index,\n item: this.args.items[index] || null,\n element,\n };\n });\n }\n\n cleanup(listView: NativeElementNode<NativeListView>) {\n for (const elementRef of this.elementRefs) {\n const n = elementRef.element.nativeView.nativeViewProtected;\n if (!n || !n.getWindowToken()) {\n elementRef.element.parentNode?.removeChild(elementRef.element);\n ((listView.nativeView as any)._realizedItems as any).delete(\n elementRef.element.nativeView,\n );\n }\n }\n this.elementRefs = this.elementRefs.filter(\n (e) => !!e.element.nativeView.nativeViewProtected?.getWindowToken(),\n ) as Ref<T>[];\n }\n\n setupListView = modifier(\n function setupListView(\n this: ListView<T>,\n listView: NativeElementNode<NativeListView>,\n ) {\n const listViewComponent = this;\n function _getDefaultItemContent(index: number) {\n listViewComponent.cleanup(listView);\n const sl = DocumentNode.createElement('stack-layout');\n listView.appendChild(sl);\n listViewComponent.elementRefs.push({\n element: sl,\n item: null,\n index,\n });\n listViewComponent.elementRefs = [...listViewComponent.elementRefs];\n return sl.nativeView;\n }\n (listView.nativeView as any)._getDefaultItemContent =\n _getDefaultItemContent;\n (listView.nativeView as any)._prepareItem = (\n stackLayout: StackLayout,\n index: number,\n ) => {\n const ref = listViewComponent.elementRefs.find(\n (e) => e.element.nativeView === stackLayout,\n )!;\n ref.index = index;\n listViewComponent.elementRefs = [...listViewComponent.elementRefs];\n };\n }.bind(this),\n );\n\n <template>\n <list-view {{this.setupListView}} items={{@items}} ...attributes />\n {{#each this.items as |item|}}\n {{#in-element item.element}}\n {{yield item.item to='item'}}\n {{/in-element}}\n {{/each}}\n </template>\n}\n"],"names":["ListView","_class","_ListView","Component","constructor","args","_initializerDefineProperty","_descriptor","_defineProperty","modifier","setupListView","listView","listViewComponent","_getDefaultItemContent","index","cleanup","sl","DocumentNode","createElement","appendChild","elementRefs","push","element","item","nativeView","_prepareItem","stackLayout","ref","find","e","bind","items","filter","x","length","map","elementRef","n","nativeViewProtected","getWindowToken","parentNode","removeChild","_realizedItems","delete","setComponentTemplate","template_fd9b2463e5f141cfb5666b64daa1f11a","strictMode","_applyDec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AA,CAAA+C,SAAA,kBArETC,OAAAA,CAAAA,EAAAA;EAAAA,YAAAA,EAAAA,IAAAA;EAAAA,UAAAA,EAAAA,IAAAA;EAAAA,QAAAA,EAAAA,IAAAA;AAAAA,EAAAA,WAAAA,cAAAA;AAAAA,IAAAA,OAAgC,EAAE;AAAA;AAAA,CAAA,CAAA,EAAAhD,MAAA;;;;"}
@@ -1,4 +1,4 @@
1
- import { a as _applyDecoratedDescriptor, b as _initializerDefineProperty, _ as _defineProperty } from '../_rollupPluginBabelHelpers-DZQzmiRH.js';
1
+ import { a as _applyDecoratedDescriptor, _ as _defineProperty, b as _initializerDefineProperty } from '../_rollupPluginBabelHelpers-apNPIsxw.js';
2
2
  import Component from '@glimmer/component';
3
3
  import { modifier } from 'ember-modifier';
4
4
  import { tracked } from '@glimmer/tracking';
@@ -39,13 +39,15 @@ let RadListView = (_class2 = (_RadListView = class RadListView extends Component
39
39
  super(...args);
40
40
  _defineProperty(this, "elementRefs", new TrackedMap());
41
41
  _initializerDefineProperty(this, "listView", _descriptor2, this);
42
- _defineProperty(this, "headerElement", void 0);
43
- _defineProperty(this, "footerElement", void 0);
44
42
  _defineProperty(this, "setupListView", modifier(function setupListView(listView) {
45
43
  this.listView = listView;
44
+ listView.nativeView.on('itemRecyclingInternal', () => {
45
+ this.cleanup(listView);
46
+ });
46
47
  const listViewComponent = this;
47
48
  function _getDefaultItemContent() {
48
49
  const sl = DocumentNode.createElement('stack-layout');
50
+ listView.appendChild(sl);
49
51
  Object.defineProperty(sl.nativeView, 'parent', {
50
52
  get() {
51
53
  return this._parent;
@@ -83,6 +85,18 @@ let RadListView = (_class2 = (_RadListView = class RadListView extends Component
83
85
  this.footerElement = DocumentNode.createElement('stack-layout');
84
86
  });
85
87
  }
88
+ cleanup(listView) {
89
+ for (const [element] of [...this.elementRefs.entries()]) {
90
+ const n = element.nativeView.nativeViewProtected;
91
+ if (!n || !n.getWindowToken()) {
92
+ this.elementRefs.delete(element);
93
+ const idx = listView.childNodes.findIndex(c => c === element);
94
+ if (idx >= 0) {
95
+ listView.childNodes.splice(idx, 1);
96
+ }
97
+ }
98
+ }
99
+ }
86
100
  get items() {
87
101
  return [...this.elementRefs.entries()].map(([element, item]) => {
88
102
  return {