@memberjunction/ng-explorer-core 6.1.4 → 6.2.0-edge.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 (184) hide show
  1. package/dist/app-routing.module.d.ts +23 -1
  2. package/dist/app-routing.module.d.ts.map +1 -1
  3. package/dist/app-routing.module.js +73 -17
  4. package/dist/app-routing.module.js.map +1 -1
  5. package/dist/generated/lazy-feature-config.d.ts +1 -1
  6. package/dist/generated/lazy-feature-config.d.ts.map +1 -1
  7. package/dist/generated/lazy-feature-config.js +1 -8
  8. package/dist/generated/lazy-feature-config.js.map +1 -1
  9. package/dist/lib/command-palette/command-palette.component.d.ts +7 -1
  10. package/dist/lib/command-palette/command-palette.component.d.ts.map +1 -1
  11. package/dist/lib/command-palette/command-palette.component.js +28 -14
  12. package/dist/lib/command-palette/command-palette.component.js.map +1 -1
  13. package/dist/lib/conversation-feedback/conversation-feedback.d.ts +103 -13
  14. package/dist/lib/conversation-feedback/conversation-feedback.d.ts.map +1 -1
  15. package/dist/lib/conversation-feedback/conversation-feedback.js +219 -67
  16. package/dist/lib/conversation-feedback/conversation-feedback.js.map +1 -1
  17. package/dist/lib/dashboard-preferences-dialog/dashboard-preferences-dialog.component.d.ts +64 -10
  18. package/dist/lib/dashboard-preferences-dialog/dashboard-preferences-dialog.component.d.ts.map +1 -1
  19. package/dist/lib/dashboard-preferences-dialog/dashboard-preferences-dialog.component.js +172 -66
  20. package/dist/lib/dashboard-preferences-dialog/dashboard-preferences-dialog.component.js.map +1 -1
  21. package/dist/lib/generic/resource-container-component.d.ts +19 -5
  22. package/dist/lib/generic/resource-container-component.d.ts.map +1 -1
  23. package/dist/lib/generic/resource-container-component.js +43 -13
  24. package/dist/lib/generic/resource-container-component.js.map +1 -1
  25. package/dist/lib/guards/entities.guard.d.ts +4 -0
  26. package/dist/lib/guards/entities.guard.d.ts.map +1 -1
  27. package/dist/lib/guards/entities.guard.js +10 -2
  28. package/dist/lib/guards/entities.guard.js.map +1 -1
  29. package/dist/lib/identity-claims/claim-redeem.component.d.ts +4 -0
  30. package/dist/lib/identity-claims/claim-redeem.component.d.ts.map +1 -1
  31. package/dist/lib/identity-claims/claim-redeem.component.js +10 -2
  32. package/dist/lib/identity-claims/claim-redeem.component.js.map +1 -1
  33. package/dist/lib/oauth/oauth-callback.component.d.ts +4 -0
  34. package/dist/lib/oauth/oauth-callback.component.d.ts.map +1 -1
  35. package/dist/lib/oauth/oauth-callback.component.js +10 -2
  36. package/dist/lib/oauth/oauth-callback.component.js.map +1 -1
  37. package/dist/lib/profile/profile-dialog.component.d.ts.map +1 -1
  38. package/dist/lib/profile/profile-dialog.component.js +194 -191
  39. package/dist/lib/profile/profile-dialog.component.js.map +1 -1
  40. package/dist/lib/resource-wrappers/artifact-resource.component.d.ts +20 -2
  41. package/dist/lib/resource-wrappers/artifact-resource.component.d.ts.map +1 -1
  42. package/dist/lib/resource-wrappers/artifact-resource.component.js +33 -9
  43. package/dist/lib/resource-wrappers/artifact-resource.component.js.map +1 -1
  44. package/dist/lib/resource-wrappers/chat-collections-resource.component.d.ts +80 -10
  45. package/dist/lib/resource-wrappers/chat-collections-resource.component.d.ts.map +1 -1
  46. package/dist/lib/resource-wrappers/chat-collections-resource.component.js +168 -56
  47. package/dist/lib/resource-wrappers/chat-collections-resource.component.js.map +1 -1
  48. package/dist/lib/resource-wrappers/chat-conversations-resource.component.d.ts +186 -23
  49. package/dist/lib/resource-wrappers/chat-conversations-resource.component.d.ts.map +1 -1
  50. package/dist/lib/resource-wrappers/chat-conversations-resource.component.js +500 -177
  51. package/dist/lib/resource-wrappers/chat-conversations-resource.component.js.map +1 -1
  52. package/dist/lib/resource-wrappers/chat-deeplink-params.d.ts +2 -0
  53. package/dist/lib/resource-wrappers/chat-deeplink-params.d.ts.map +1 -1
  54. package/dist/lib/resource-wrappers/chat-deeplink-params.js +5 -1
  55. package/dist/lib/resource-wrappers/chat-deeplink-params.js.map +1 -1
  56. package/dist/lib/resource-wrappers/chat-search-routing.d.ts +25 -0
  57. package/dist/lib/resource-wrappers/chat-search-routing.d.ts.map +1 -0
  58. package/dist/lib/resource-wrappers/chat-search-routing.js +24 -0
  59. package/dist/lib/resource-wrappers/chat-search-routing.js.map +1 -0
  60. package/dist/lib/resource-wrappers/chat-tasks-resource.component.d.ts +14 -2
  61. package/dist/lib/resource-wrappers/chat-tasks-resource.component.d.ts.map +1 -1
  62. package/dist/lib/resource-wrappers/chat-tasks-resource.component.js +32 -8
  63. package/dist/lib/resource-wrappers/chat-tasks-resource.component.js.map +1 -1
  64. package/dist/lib/resource-wrappers/dashboard-resource.component.d.ts +54 -8
  65. package/dist/lib/resource-wrappers/dashboard-resource.component.d.ts.map +1 -1
  66. package/dist/lib/resource-wrappers/dashboard-resource.component.js +138 -46
  67. package/dist/lib/resource-wrappers/dashboard-resource.component.js.map +1 -1
  68. package/dist/lib/resource-wrappers/livekit-room-resource.component.d.ts +223 -30
  69. package/dist/lib/resource-wrappers/livekit-room-resource.component.d.ts.map +1 -1
  70. package/dist/lib/resource-wrappers/livekit-room-resource.component.js +438 -118
  71. package/dist/lib/resource-wrappers/livekit-room-resource.component.js.map +1 -1
  72. package/dist/lib/resource-wrappers/search-results-resource.component.d.ts +7 -3
  73. package/dist/lib/resource-wrappers/search-results-resource.component.d.ts.map +1 -1
  74. package/dist/lib/resource-wrappers/search-results-resource.component.js +23 -15
  75. package/dist/lib/resource-wrappers/search-results-resource.component.js.map +1 -1
  76. package/dist/lib/resource-wrappers/view-resource.component.d.ts +68 -10
  77. package/dist/lib/resource-wrappers/view-resource.component.d.ts.map +1 -1
  78. package/dist/lib/resource-wrappers/view-resource.component.js +178 -62
  79. package/dist/lib/resource-wrappers/view-resource.component.js.map +1 -1
  80. package/dist/lib/services/startup-validation.service.d.ts +4 -0
  81. package/dist/lib/services/startup-validation.service.d.ts.map +1 -1
  82. package/dist/lib/services/startup-validation.service.js +10 -2
  83. package/dist/lib/services/startup-validation.service.js.map +1 -1
  84. package/dist/lib/services/system-validation.service.d.ts +13 -1
  85. package/dist/lib/services/system-validation.service.d.ts.map +1 -1
  86. package/dist/lib/services/system-validation.service.js +29 -5
  87. package/dist/lib/services/system-validation.service.js.map +1 -1
  88. package/dist/lib/shell/components/dialogs/app-access-dialog.component.d.ts +54 -4
  89. package/dist/lib/shell/components/dialogs/app-access-dialog.component.d.ts.map +1 -1
  90. package/dist/lib/shell/components/dialogs/app-access-dialog.component.js +130 -40
  91. package/dist/lib/shell/components/dialogs/app-access-dialog.component.js.map +1 -1
  92. package/dist/lib/shell/components/header/app-nav.component.d.ts +29 -1
  93. package/dist/lib/shell/components/header/app-nav.component.d.ts.map +1 -1
  94. package/dist/lib/shell/components/header/app-nav.component.js +56 -12
  95. package/dist/lib/shell/components/header/app-nav.component.js.map +1 -1
  96. package/dist/lib/shell/components/header/app-switcher.component.d.ts +33 -5
  97. package/dist/lib/shell/components/header/app-switcher.component.d.ts.map +1 -1
  98. package/dist/lib/shell/components/header/app-switcher.component.js +85 -29
  99. package/dist/lib/shell/components/header/app-switcher.component.js.map +1 -1
  100. package/dist/lib/shell/components/record-open/record-origin-crumb.component.d.ts +7 -1
  101. package/dist/lib/shell/components/record-open/record-origin-crumb.component.d.ts.map +1 -1
  102. package/dist/lib/shell/components/record-open/record-origin-crumb.component.js +63 -9
  103. package/dist/lib/shell/components/record-open/record-origin-crumb.component.js.map +1 -1
  104. package/dist/lib/shell/components/tabs/component-cache-manager.d.ts +30 -1
  105. package/dist/lib/shell/components/tabs/component-cache-manager.d.ts.map +1 -1
  106. package/dist/lib/shell/components/tabs/component-cache-manager.js +63 -15
  107. package/dist/lib/shell/components/tabs/component-cache-manager.js.map +1 -1
  108. package/dist/lib/shell/components/tabs/tab-container.component.d.ts +99 -9
  109. package/dist/lib/shell/components/tabs/tab-container.component.d.ts.map +1 -1
  110. package/dist/lib/shell/components/tabs/tab-container.component.js +310 -110
  111. package/dist/lib/shell/components/tabs/tab-container.component.js.map +1 -1
  112. package/dist/lib/shell/loading-themes.d.ts +16 -12
  113. package/dist/lib/shell/loading-themes.d.ts.map +1 -1
  114. package/dist/lib/shell/loading-themes.js +145 -137
  115. package/dist/lib/shell/loading-themes.js.map +1 -1
  116. package/dist/lib/shell/readiness-beacon.d.ts +24 -0
  117. package/dist/lib/shell/readiness-beacon.d.ts.map +1 -0
  118. package/dist/lib/shell/readiness-beacon.js +40 -0
  119. package/dist/lib/shell/readiness-beacon.js.map +1 -0
  120. package/dist/lib/shell/services/about-dialog.service.d.ts +6 -0
  121. package/dist/lib/shell/services/about-dialog.service.d.ts.map +1 -1
  122. package/dist/lib/shell/services/about-dialog.service.js +16 -4
  123. package/dist/lib/shell/services/about-dialog.service.js.map +1 -1
  124. package/dist/lib/shell/services/profile-dialog.service.d.ts +6 -0
  125. package/dist/lib/shell/services/profile-dialog.service.d.ts.map +1 -1
  126. package/dist/lib/shell/services/profile-dialog.service.js +16 -4
  127. package/dist/lib/shell/services/profile-dialog.service.js.map +1 -1
  128. package/dist/lib/shell/services/user-sharing-center-dialog.service.d.ts +6 -0
  129. package/dist/lib/shell/services/user-sharing-center-dialog.service.d.ts.map +1 -1
  130. package/dist/lib/shell/services/user-sharing-center-dialog.service.js +15 -3
  131. package/dist/lib/shell/services/user-sharing-center-dialog.service.js.map +1 -1
  132. package/dist/lib/shell/shell.component.d.ts +275 -40
  133. package/dist/lib/shell/shell.component.d.ts.map +1 -1
  134. package/dist/lib/shell/shell.component.js +704 -290
  135. package/dist/lib/shell/shell.component.js.map +1 -1
  136. package/dist/lib/single-dashboard/Components/add-item/add-item.component.d.ts +64 -8
  137. package/dist/lib/single-dashboard/Components/add-item/add-item.component.d.ts.map +1 -1
  138. package/dist/lib/single-dashboard/Components/add-item/add-item.component.js +129 -37
  139. package/dist/lib/single-dashboard/Components/add-item/add-item.component.js.map +1 -1
  140. package/dist/lib/single-dashboard/Components/delete-item/delete-item.component.d.ts +26 -2
  141. package/dist/lib/single-dashboard/Components/delete-item/delete-item.component.d.ts.map +1 -1
  142. package/dist/lib/single-dashboard/Components/delete-item/delete-item.component.js +48 -10
  143. package/dist/lib/single-dashboard/Components/delete-item/delete-item.component.js.map +1 -1
  144. package/dist/lib/single-dashboard/Components/edit-dashboard/edit-dashboard.component.d.ts +84 -6
  145. package/dist/lib/single-dashboard/Components/edit-dashboard/edit-dashboard.component.d.ts.map +1 -1
  146. package/dist/lib/single-dashboard/Components/edit-dashboard/edit-dashboard.component.js +133 -29
  147. package/dist/lib/single-dashboard/Components/edit-dashboard/edit-dashboard.component.js.map +1 -1
  148. package/dist/lib/single-dashboard/single-dashboard.component.d.ts +173 -23
  149. package/dist/lib/single-dashboard/single-dashboard.component.d.ts.map +1 -1
  150. package/dist/lib/single-dashboard/single-dashboard.component.js +383 -109
  151. package/dist/lib/single-dashboard/single-dashboard.component.js.map +1 -1
  152. package/dist/lib/single-list-detail/single-list-detail.component.d.ts +383 -55
  153. package/dist/lib/single-list-detail/single-list-detail.component.d.ts.map +1 -1
  154. package/dist/lib/single-list-detail/single-list-detail.component.js +962 -326
  155. package/dist/lib/single-list-detail/single-list-detail.component.js.map +1 -1
  156. package/dist/lib/single-query/single-query.component.d.ts +22 -2
  157. package/dist/lib/single-query/single-query.component.d.ts.map +1 -1
  158. package/dist/lib/single-query/single-query.component.js +40 -10
  159. package/dist/lib/single-query/single-query.component.js.map +1 -1
  160. package/dist/lib/single-record/single-record.component.d.ts +41 -3
  161. package/dist/lib/single-record/single-record.component.d.ts.map +1 -1
  162. package/dist/lib/single-record/single-record.component.js +71 -11
  163. package/dist/lib/single-record/single-record.component.js.map +1 -1
  164. package/dist/lib/single-search-result/single-search-result.component.d.ts +23 -3
  165. package/dist/lib/single-search-result/single-search-result.component.d.ts.map +1 -1
  166. package/dist/lib/single-search-result/single-search-result.component.js +42 -12
  167. package/dist/lib/single-search-result/single-search-result.component.js.map +1 -1
  168. package/dist/lib/system-validation/system-validation-banner.component.d.ts +12 -2
  169. package/dist/lib/system-validation/system-validation-banner.component.d.ts.map +1 -1
  170. package/dist/lib/system-validation/system-validation-banner.component.js +25 -5
  171. package/dist/lib/system-validation/system-validation-banner.component.js.map +1 -1
  172. package/dist/lib/user-menu/user-menu.types.d.ts +4 -0
  173. package/dist/lib/user-menu/user-menu.types.d.ts.map +1 -1
  174. package/dist/lib/user-menu/user-menu.types.js +10 -2
  175. package/dist/lib/user-menu/user-menu.types.js.map +1 -1
  176. package/dist/lib/user-notifications/user-notifications.component.d.ts +59 -7
  177. package/dist/lib/user-notifications/user-notifications.component.d.ts.map +1 -1
  178. package/dist/lib/user-notifications/user-notifications.component.js +151 -47
  179. package/dist/lib/user-notifications/user-notifications.component.js.map +1 -1
  180. package/dist/lib/user-profile/user-profile.component.d.ts +3 -2
  181. package/dist/lib/user-profile/user-profile.component.d.ts.map +1 -1
  182. package/dist/lib/user-profile/user-profile.component.js +5 -4
  183. package/dist/lib/user-profile/user-profile.component.js.map +1 -1
  184. package/package.json +52 -52
@@ -2,14 +2,34 @@ import { EventEmitter, OnInit } from '@angular/core';
2
2
  import { RunQueryResult } from '@memberjunction/core';
3
3
  import * as i0 from "@angular/core";
4
4
  export declare class SingleQueryComponent implements OnInit {
5
- queryId: string;
5
+ QueryId: string;
6
+ /** @deprecated Use {@link QueryId}. */
7
+ set queryId(value: string);
8
+ /** @deprecated Use {@link QueryId}. */
9
+ get queryId(): string;
10
+ LoadComplete: EventEmitter<void>;
11
+ /**
12
+ * @deprecated Use {@link LoadComplete}.
13
+ *
14
+ * The same emitter under the old binding name, so a template still binding
15
+ * (loadComplete) keeps working. Must stay AFTER LoadComplete: class fields
16
+ * initialise in order, and the other way round this captures undefined.
17
+ */
6
18
  loadComplete: EventEmitter<void>;
19
+ LoadStarted: EventEmitter<void>;
20
+ /**
21
+ * @deprecated Use {@link LoadStarted}.
22
+ *
23
+ * The same emitter under the old binding name, so a template still binding
24
+ * (loadStarted) keeps working. Must stay AFTER LoadStarted: class fields
25
+ * initialise in order, and the other way round this captures undefined.
26
+ */
7
27
  loadStarted: EventEmitter<void>;
8
28
  CleanQueryId: string;
9
29
  ngOnInit(): void;
10
30
  OnQueryStart(): void;
11
31
  OnQueryComplete(_result: RunQueryResult): void;
12
32
  static ɵfac: i0.ɵɵFactoryDeclaration<SingleQueryComponent, never>;
13
- static ɵcmp: i0.ɵɵComponentDeclaration<SingleQueryComponent, "mj-single-query", never, { "queryId": { "alias": "queryId"; "required": false; }; }, { "loadComplete": "loadComplete"; "loadStarted": "loadStarted"; }, never, never, false, never>;
33
+ static ɵcmp: i0.ɵɵComponentDeclaration<SingleQueryComponent, "mj-single-query", never, { "QueryId": { "alias": "QueryId"; "required": false; }; "queryId": { "alias": "queryId"; "required": false; }; }, { "LoadComplete": "LoadComplete"; "loadComplete": "loadComplete"; "LoadStarted": "LoadStarted"; "loadStarted": "loadStarted"; }, never, never, false, never>;
14
34
  }
15
35
  //# sourceMappingURL=single-query.component.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"single-query.component.d.ts","sourceRoot":"","sources":["../../../src/lib/single-query/single-query.component.ts"],"names":[],"mappings":"AAAA,OAAO,EAAa,YAAY,EAAS,MAAM,EAAU,MAAM,eAAe,CAAC;AAC/E,OAAO,EAAE,cAAc,EAAE,MAAM,sBAAsB,CAAC;;AAEtD,qBAMa,oBAAqB,YAAW,MAAM;IACxC,OAAO,EAAG,MAAM,CAAC;IACT,YAAY,qBAA4B;IACxC,WAAW,qBAA4B;IAEjD,YAAY,EAAE,MAAM,CAAM;IAEjC,QAAQ,IAAI,IAAI;IAOhB,YAAY,IAAI,IAAI;IAIpB,eAAe,CAAC,OAAO,EAAE,cAAc,GAAG,IAAI;yCAlBnC,oBAAoB;2CAApB,oBAAoB;CAqBhC"}
1
+ {"version":3,"file":"single-query.component.d.ts","sourceRoot":"","sources":["../../../src/lib/single-query/single-query.component.ts"],"names":[],"mappings":"AAAA,OAAO,EAAa,YAAY,EAAS,MAAM,EAAU,MAAM,eAAe,CAAC;AAC/E,OAAO,EAAE,cAAc,EAAE,MAAM,sBAAsB,CAAC;;AAEtD,qBAMa,oBAAqB,YAAW,MAAM;IACxC,OAAO,EAAG,MAAM,CAAC;IAE1B,uCAAuC;IACvC,IAAa,OAAO,CAAC,KAAK,EAAE,MAAM,EAEjC;IACD,uCAAuC;IACvC,IAAI,OAAO,IAAI,MAAM,CAEpB;IACgB,YAAY,qBAA4B;IAEzD;;;;;;OAMG;IACc,YAAY,qBAAqB;IACjC,WAAW,qBAA4B;IAExD;;;;;;OAMG;IACc,WAAW,qBAAoB;IAEzC,YAAY,EAAE,MAAM,CAAM;IAEjC,QAAQ,IAAI,IAAI;IAOhB,YAAY,IAAI,IAAI;IAIpB,eAAe,CAAC,OAAO,EAAE,cAAc,GAAG,IAAI;yCA7CnC,oBAAoB;2CAApB,oBAAoB;CAgDhC"}
@@ -2,24 +2,48 @@ import { Component, EventEmitter, Input, Output } from '@angular/core';
2
2
  import * as i0 from "@angular/core";
3
3
  import * as i1 from "@memberjunction/ng-query-viewer";
4
4
  export class SingleQueryComponent {
5
- queryId;
6
- loadComplete = new EventEmitter();
7
- loadStarted = new EventEmitter();
5
+ QueryId;
6
+ /** @deprecated Use {@link QueryId}. */
7
+ set queryId(value) {
8
+ this.QueryId = value;
9
+ }
10
+ /** @deprecated Use {@link QueryId}. */
11
+ get queryId() {
12
+ return this.QueryId;
13
+ }
14
+ LoadComplete = new EventEmitter();
15
+ /**
16
+ * @deprecated Use {@link LoadComplete}.
17
+ *
18
+ * The same emitter under the old binding name, so a template still binding
19
+ * (loadComplete) keeps working. Must stay AFTER LoadComplete: class fields
20
+ * initialise in order, and the other way round this captures undefined.
21
+ */
22
+ loadComplete = this.LoadComplete;
23
+ LoadStarted = new EventEmitter();
24
+ /**
25
+ * @deprecated Use {@link LoadStarted}.
26
+ *
27
+ * The same emitter under the old binding name, so a template still binding
28
+ * (loadStarted) keeps working. Must stay AFTER LoadStarted: class fields
29
+ * initialise in order, and the other way round this captures undefined.
30
+ */
31
+ loadStarted = this.LoadStarted;
8
32
  CleanQueryId = '';
9
33
  ngOnInit() {
10
34
  // Clean any quotes that might have been added upstream
11
- this.CleanQueryId = (this.queryId && typeof this.queryId === 'string')
12
- ? this.queryId.replace(/^['"]|['"]$/g, '')
13
- : this.queryId;
35
+ this.CleanQueryId = (this.QueryId && typeof this.QueryId === 'string')
36
+ ? this.QueryId.replace(/^['"]|['"]$/g, '')
37
+ : this.QueryId;
14
38
  }
15
39
  OnQueryStart() {
16
- this.loadStarted.emit();
40
+ this.LoadStarted.emit();
17
41
  }
18
42
  OnQueryComplete(_result) {
19
- this.loadComplete.emit();
43
+ this.LoadComplete.emit();
20
44
  }
21
45
  static ɵfac = function SingleQueryComponent_Factory(__ngFactoryType__) { return new (__ngFactoryType__ || SingleQueryComponent)(); };
22
- static ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: SingleQueryComponent, selectors: [["mj-single-query"]], inputs: { queryId: "queryId" }, outputs: { loadComplete: "loadComplete", loadStarted: "loadStarted" }, standalone: false, decls: 1, vars: 2, consts: [[3, "QueryStart", "QueryComplete", "QueryId", "AutoRun"]], template: function SingleQueryComponent_Template(rf, ctx) { if (rf & 1) {
46
+ static ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: SingleQueryComponent, selectors: [["mj-single-query"]], inputs: { QueryId: "QueryId", queryId: "queryId" }, outputs: { LoadComplete: "LoadComplete", loadComplete: "loadComplete", LoadStarted: "LoadStarted", loadStarted: "loadStarted" }, standalone: false, decls: 1, vars: 2, consts: [[3, "QueryStart", "QueryComplete", "QueryId", "AutoRun"]], template: function SingleQueryComponent_Template(rf, ctx) { if (rf & 1) {
23
47
  i0.ɵɵelementStart(0, "mj-query-viewer", 0);
24
48
  i0.ɵɵlistener("QueryStart", function SingleQueryComponent_Template_mj_query_viewer_QueryStart_0_listener() { return ctx.OnQueryStart(); })("QueryComplete", function SingleQueryComponent_Template_mj_query_viewer_QueryComplete_0_listener($event) { return ctx.OnQueryComplete($event); });
25
49
  i0.ɵɵelementEnd();
@@ -30,10 +54,16 @@ export class SingleQueryComponent {
30
54
  (() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(SingleQueryComponent, [{
31
55
  type: Component,
32
56
  args: [{ standalone: false, selector: 'mj-single-query', template: "<mj-query-viewer\n [QueryId]=\"CleanQueryId\"\n [AutoRun]=\"true\"\n (QueryStart)=\"OnQueryStart()\"\n (QueryComplete)=\"OnQueryComplete($any($event))\">\n</mj-query-viewer>" }]
33
- }], null, { queryId: [{
57
+ }], null, { QueryId: [{
58
+ type: Input
59
+ }], queryId: [{
34
60
  type: Input
61
+ }], LoadComplete: [{
62
+ type: Output
35
63
  }], loadComplete: [{
36
64
  type: Output
65
+ }], LoadStarted: [{
66
+ type: Output
37
67
  }], loadStarted: [{
38
68
  type: Output
39
69
  }] }); })();
@@ -1 +1 @@
1
- {"version":3,"file":"single-query.component.js","sourceRoot":"","sources":["../../../src/lib/single-query/single-query.component.ts","../../../src/lib/single-query/single-query.component.html"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,YAAY,EAAE,KAAK,EAAU,MAAM,EAAE,MAAM,eAAe,CAAC;;;AAS/E,MAAM,OAAO,oBAAoB;IACtB,OAAO,CAAU;IACT,YAAY,GAAG,IAAI,YAAY,EAAQ,CAAC;IACxC,WAAW,GAAG,IAAI,YAAY,EAAQ,CAAC;IAEjD,YAAY,GAAW,EAAE,CAAC;IAEjC,QAAQ;QACN,uDAAuD;QACvD,IAAI,CAAC,YAAY,GAAG,CAAC,IAAI,CAAC,OAAO,IAAI,OAAO,IAAI,CAAC,OAAO,KAAK,QAAQ,CAAC;YACpE,CAAC,CAAC,IAAI,CAAC,OAAO,CAAC,OAAO,CAAC,cAAc,EAAE,EAAE,CAAC;YAC1C,CAAC,CAAC,IAAI,CAAC,OAAO,CAAC;IACnB,CAAC;IAED,YAAY;QACV,IAAI,CAAC,WAAW,CAAC,IAAI,EAAE,CAAC;IAC1B,CAAC;IAED,eAAe,CAAC,OAAuB;QACrC,IAAI,CAAC,YAAY,CAAC,IAAI,EAAE,CAAC;IAC3B,CAAC;8GApBU,oBAAoB;6DAApB,oBAAoB;YCTjC,0CAIkD;YAAhD,AADA,oHAAc,kBAAc,IAAC,mHACZ,2BAA6B,IAAC;YACjD,iBAAkB;;YAHhB,AADA,0CAAwB,iBACR;;;iFDOL,oBAAoB;cANhC,SAAS;6BACI,KAAK,YACP,iBAAiB;;kBAK1B,KAAK;;kBACL,MAAM;;kBACN,MAAM;;kFAHI,oBAAoB","sourcesContent":["import { Component, EventEmitter, Input, OnInit, Output } from '@angular/core';\nimport { RunQueryResult } from '@memberjunction/core';\n\n@Component({\n standalone: false,\n selector: 'mj-single-query',\n templateUrl: './single-query.component.html',\n styleUrls: ['./single-query.component.css']\n})\nexport class SingleQueryComponent implements OnInit {\n @Input() queryId!: string;\n @Output() public loadComplete = new EventEmitter<void>();\n @Output() public loadStarted = new EventEmitter<void>();\n\n public CleanQueryId: string = '';\n\n ngOnInit(): void {\n // Clean any quotes that might have been added upstream\n this.CleanQueryId = (this.queryId && typeof this.queryId === 'string')\n ? this.queryId.replace(/^['\"]|['\"]$/g, '')\n : this.queryId;\n }\n\n OnQueryStart(): void {\n this.loadStarted.emit();\n }\n\n OnQueryComplete(_result: RunQueryResult): void {\n this.loadComplete.emit();\n }\n}\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n","<mj-query-viewer\n [QueryId]=\"CleanQueryId\"\n [AutoRun]=\"true\"\n (QueryStart)=\"OnQueryStart()\"\n (QueryComplete)=\"OnQueryComplete($any($event))\">\n</mj-query-viewer>"]}
1
+ {"version":3,"file":"single-query.component.js","sourceRoot":"","sources":["../../../src/lib/single-query/single-query.component.ts","../../../src/lib/single-query/single-query.component.html"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,YAAY,EAAE,KAAK,EAAU,MAAM,EAAE,MAAM,eAAe,CAAC;;;AAS/E,MAA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Result } from '@memberjunction/core';\n\n@Component({\n standalone: false,\n selector: 'mj-single-query',\n templateUrl: './single-query.component.html',\n styleUrls: ['./single-query.component.css']\n})\nexport class SingleQueryComponent implements OnInit {\n @Input() QueryId!: string;\n\n /** @deprecated Use {@link QueryId}. */\n @Input() set queryId(value: string) {\n this.QueryId = value;\n }\n /** @deprecated Use {@link QueryId}. */\n get queryId(): string {\n return this.QueryId;\n }\n @Output() public LoadComplete = new EventEmitter<void>();\n\n /**\n * @deprecated Use {@link LoadComplete}.\n *\n * The same emitter under the old binding name, so a template still binding\n * (loadComplete) keeps working. Must stay AFTER LoadComplete: class fields\n * initialise in order, and the other way round this captures undefined.\n */\n @Output() public loadComplete = this.LoadComplete;\n @Output() public LoadStarted = new EventEmitter<void>();\n\n /**\n * @deprecated Use {@link LoadStarted}.\n *\n * The same emitter under the old binding name, so a template still binding\n * (loadStarted) keeps working. Must stay AFTER LoadStarted: class fields\n * initialise in order, and the other way round this captures undefined.\n */\n @Output() public loadStarted = this.LoadStarted;\n\n public CleanQueryId: string = '';\n\n ngOnInit(): void {\n // Clean any quotes that might have been added upstream\n this.CleanQueryId = (this.QueryId && typeof this.QueryId === 'string')\n ? this.QueryId.replace(/^['\"]|['\"]$/g, '')\n : this.QueryId;\n }\n\n OnQueryStart(): void {\n this.LoadStarted.emit();\n }\n\n OnQueryComplete(_result: RunQueryResult): void {\n this.LoadComplete.emit();\n }\n}\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n","<mj-query-viewer\n [QueryId]=\"CleanQueryId\"\n [AutoRun]=\"true\"\n (QueryStart)=\"OnQueryStart()\"\n (QueryComplete)=\"OnQueryComplete($any($event))\">\n</mj-query-viewer>"]}
@@ -20,10 +20,38 @@ import * as i0 from "@angular/core";
20
20
  export declare class SingleRecordComponent extends BaseAngularComponent {
21
21
  PrimaryKey: CompositeKey;
22
22
  entityName: string | null;
23
- newRecordValues: string | Record<string, unknown> | null;
23
+ NewRecordValues: string | Record<string, unknown> | null;
24
+ /** @deprecated Use {@link NewRecordValues}. */
25
+ set newRecordValues(value: string | Record<string, unknown> | null);
26
+ /** @deprecated Use {@link NewRecordValues}. */
27
+ get newRecordValues(): string | Record<string, unknown> | null;
28
+ LoadComplete: EventEmitter<void>;
29
+ /**
30
+ * @deprecated Use {@link LoadComplete}.
31
+ *
32
+ * The same emitter under the old binding name, so a template still binding
33
+ * (loadComplete) keeps working. Must stay AFTER LoadComplete: class fields
34
+ * initialise in order, and the other way round this captures undefined.
35
+ */
24
36
  loadComplete: EventEmitter<void>;
25
- recordSaved: EventEmitter<BaseEntity>;
37
+ RecordSaved: EventEmitter<BaseEntity>;
38
+ /**
39
+ * @deprecated Use {@link RecordSaved}.
40
+ *
41
+ * The same emitter under the old binding name, so a template still binding
42
+ * (recordSaved) keeps working. Must stay AFTER RecordSaved: class fields
43
+ * initialise in order, and the other way round this captures undefined.
44
+ */
45
+ recordSaved: EventEmitter<BaseEntity<unknown>>;
26
46
  /** Emitted when the hosted form asks to be dismissed (e.g. Discard on a new record). */
47
+ RecordDismissed: EventEmitter<void>;
48
+ /**
49
+ * @deprecated Use {@link RecordDismissed}.
50
+ *
51
+ * The same emitter under the old binding name, so a template still binding
52
+ * (recordDismissed) keeps working. Must stay AFTER RecordDismissed: class fields
53
+ * initialise in order, and the other way round this captures undefined.
54
+ */
27
55
  recordDismissed: EventEmitter<void>;
28
56
  private formHost?;
29
57
  /**
@@ -40,14 +68,24 @@ export declare class SingleRecordComponent extends BaseAngularComponent {
40
68
  private formPresenter;
41
69
  private recentAccessService;
42
70
  /** Unblock the shell's first-resource-load gate (success or error). */
71
+ OnLoadComplete(): void;
72
+ /** @deprecated Use {@link OnLoadComplete}. */
43
73
  onLoadComplete(): void;
44
74
  /** Log access for existing records once the form's record is ready. */
75
+ OnRecordReady(record: BaseEntity): void;
76
+ /** @deprecated Use {@link OnRecordReady}. */
45
77
  onRecordReady(record: BaseEntity): void;
78
+ OnSaved(record: BaseEntity): void;
79
+ /** @deprecated Use {@link OnSaved}. */
46
80
  onSaved(record: BaseEntity): void;
81
+ OnNotification(event: FormNotificationEvent): void;
82
+ /** @deprecated Use {@link OnNotification}. */
47
83
  onNotification(event: FormNotificationEvent): void;
48
84
  /** Map the form's navigation requests onto Explorer's NavigationService. */
85
+ HandleNavigation(event: FormNavigationEvent): void;
86
+ /** @deprecated Use {@link HandleNavigation}. */
49
87
  handleNavigation(event: FormNavigationEvent): void;
50
88
  static ɵfac: i0.ɵɵFactoryDeclaration<SingleRecordComponent, never>;
51
- static ɵcmp: i0.ɵɵComponentDeclaration<SingleRecordComponent, "mj-single-record", never, { "PrimaryKey": { "alias": "PrimaryKey"; "required": false; }; "entityName": { "alias": "entityName"; "required": false; }; "newRecordValues": { "alias": "newRecordValues"; "required": false; }; }, { "loadComplete": "loadComplete"; "recordSaved": "recordSaved"; "recordDismissed": "recordDismissed"; }, never, never, false, never>;
89
+ static ɵcmp: i0.ɵɵComponentDeclaration<SingleRecordComponent, "mj-single-record", never, { "PrimaryKey": { "alias": "PrimaryKey"; "required": false; }; "entityName": { "alias": "entityName"; "required": false; }; "NewRecordValues": { "alias": "NewRecordValues"; "required": false; }; "newRecordValues": { "alias": "newRecordValues"; "required": false; }; }, { "LoadComplete": "LoadComplete"; "loadComplete": "loadComplete"; "RecordSaved": "RecordSaved"; "recordSaved": "recordSaved"; "RecordDismissed": "RecordDismissed"; "recordDismissed": "recordDismissed"; }, never, never, false, never>;
52
90
  }
53
91
  //# sourceMappingURL=single-record.component.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"single-record.component.d.ts","sourceRoot":"","sources":["../../../src/lib/single-record/single-record.component.ts"],"names":[],"mappings":"AAAA,OAAO,EAAa,YAAY,EAAoC,MAAM,eAAe,CAAC;AAC1F,OAAO,EAAE,YAAY,EAAE,UAAU,EAAE,MAAM,sBAAsB,CAAC;AAChE,OAAO,EAAE,mBAAmB,EAAE,qBAAqB,EAAqD,MAAM,+BAA+B,CAAC;AAE9I,OAAO,EAAE,oBAAoB,EAAE,MAAM,+BAA+B,CAAC;;AAErE;;;;;;;;;;;;;GAaG;AACH,qBAMa,qBAAsB,SAAQ,oBAAoB;IAC7C,UAAU,EAAE,YAAY,CAAsB;IAC9C,UAAU,EAAE,MAAM,GAAG,IAAI,CAAM;IAC/B,eAAe,EAAE,MAAM,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,IAAI,CAAM;IAE7D,YAAY,EAAE,YAAY,CAAC,IAAI,CAAC,CAA4B;IAC5D,WAAW,EAAE,YAAY,CAAC,UAAU,CAAC,CAAkC;IACxF,wFAAwF;IACvE,eAAe,EAAE,YAAY,CAAC,IAAI,CAAC,CAA4B;IAE1C,OAAO,CAAC,QAAQ,CAAC,CAA4B;IAEnF;;;;;;;OAOG;IACI,SAAS,IAAI,OAAO;IAI3B,OAAO,CAAC,iBAAiB,CAA6B;IACtD,OAAO,CAAC,aAAa,CAAyB;IAC9C,OAAO,CAAC,aAAa,CAAkC;IACvD,OAAO,CAAC,mBAAmB,CAA6B;IAExD,uEAAuE;IACvE,cAAc,IAAI,IAAI;IAItB,uEAAuE;IACvE,aAAa,CAAC,MAAM,EAAE,UAAU,GAAG,IAAI;IAMvC,OAAO,CAAC,MAAM,EAAE,UAAU,GAAG,IAAI;IAIjC,cAAc,CAAC,KAAK,EAAE,qBAAqB,GAAG,IAAI;IAIlD,4EAA4E;IAC5E,gBAAgB,CAAC,KAAK,EAAE,mBAAmB,GAAG,IAAI;yCAlDvC,qBAAqB;2CAArB,qBAAqB;CA0FjC"}
1
+ {"version":3,"file":"single-record.component.d.ts","sourceRoot":"","sources":["../../../src/lib/single-record/single-record.component.ts"],"names":[],"mappings":"AAAA,OAAO,EAAa,YAAY,EAAoC,MAAM,eAAe,CAAC;AAC1F,OAAO,EAAE,YAAY,EAAE,UAAU,EAAE,MAAM,sBAAsB,CAAC;AAChE,OAAO,EAAE,mBAAmB,EAAE,qBAAqB,EAAqD,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OAAO,CAAC,MAAM,EAAE,UAAU,GAAG,IAAI;IAIjC,uCAAuC;IACvC,OAAO,CAAC,MAAM,EAAE,UAAU,GAAG,IAAI;IAIjC,cAAc,CAAC,KAAK,EAAE,qBAAqB,GAAG,IAAI;IAIlD,8CAA8C;IAC9C,cAAc,CAAC,KAAK,EAAE,qBAAqB,GAAG,IAAI;IAIlD,4EAA4E;IAC5E,gBAAgB,CAAC,KAAK,EAAE,mBAAmB,GAAG,IAAI;IAyClD,gDAAgD;IAChD,gBAAgB,CAAC,KAAK,EAAE,mBAAmB,GAAG,IAAI;yCApJvC,qBAAqB;2CAArB,qBAAqB;CAuJjC"}
@@ -22,11 +22,43 @@ import * as i1 from "@memberjunction/ng-base-forms";
22
22
  export class SingleRecordComponent extends BaseAngularComponent {
23
23
  PrimaryKey = new CompositeKey();
24
24
  entityName = '';
25
- newRecordValues = '';
26
- loadComplete = new EventEmitter();
27
- recordSaved = new EventEmitter();
25
+ NewRecordValues = '';
26
+ /** @deprecated Use {@link NewRecordValues}. */
27
+ set newRecordValues(value) {
28
+ this.NewRecordValues = value;
29
+ }
30
+ /** @deprecated Use {@link NewRecordValues}. */
31
+ get newRecordValues() {
32
+ return this.NewRecordValues;
33
+ }
34
+ LoadComplete = new EventEmitter();
35
+ /**
36
+ * @deprecated Use {@link LoadComplete}.
37
+ *
38
+ * The same emitter under the old binding name, so a template still binding
39
+ * (loadComplete) keeps working. Must stay AFTER LoadComplete: class fields
40
+ * initialise in order, and the other way round this captures undefined.
41
+ */
42
+ loadComplete = this.LoadComplete;
43
+ RecordSaved = new EventEmitter();
44
+ /**
45
+ * @deprecated Use {@link RecordSaved}.
46
+ *
47
+ * The same emitter under the old binding name, so a template still binding
48
+ * (recordSaved) keeps working. Must stay AFTER RecordSaved: class fields
49
+ * initialise in order, and the other way round this captures undefined.
50
+ */
51
+ recordSaved = this.RecordSaved;
28
52
  /** Emitted when the hosted form asks to be dismissed (e.g. Discard on a new record). */
29
- recordDismissed = new EventEmitter();
53
+ RecordDismissed = new EventEmitter();
54
+ /**
55
+ * @deprecated Use {@link RecordDismissed}.
56
+ *
57
+ * The same emitter under the old binding name, so a template still binding
58
+ * (recordDismissed) keeps working. Must stay AFTER RecordDismissed: class fields
59
+ * initialise in order, and the other way round this captures undefined.
60
+ */
61
+ recordDismissed = this.RecordDismissed;
30
62
  formHost;
31
63
  /**
32
64
  * True while the hosted form is in edit mode. The host already exposes the
@@ -44,23 +76,39 @@ export class SingleRecordComponent extends BaseAngularComponent {
44
76
  formPresenter = inject(MJFormPresenterService);
45
77
  recentAccessService = new RecentAccessService();
46
78
  /** Unblock the shell's first-resource-load gate (success or error). */
79
+ OnLoadComplete() {
80
+ this.LoadComplete.emit();
81
+ }
82
+ /** @deprecated Use {@link OnLoadComplete}. */
47
83
  onLoadComplete() {
48
- this.loadComplete.emit();
84
+ return this.OnLoadComplete();
49
85
  }
50
86
  /** Log access for existing records once the form's record is ready. */
51
- onRecordReady(record) {
87
+ OnRecordReady(record) {
52
88
  if (record?.IsSaved) {
53
89
  this.recentAccessService.logAccess(record.EntityInfo.Name, record.PrimaryKey, 'record');
54
90
  }
55
91
  }
92
+ /** @deprecated Use {@link OnRecordReady}. */
93
+ onRecordReady(record) {
94
+ return this.OnRecordReady(record);
95
+ }
96
+ OnSaved(record) {
97
+ this.RecordSaved.emit(record);
98
+ }
99
+ /** @deprecated Use {@link OnSaved}. */
56
100
  onSaved(record) {
57
- this.recordSaved.emit(record);
101
+ return this.OnSaved(record);
58
102
  }
59
- onNotification(event) {
103
+ OnNotification(event) {
60
104
  this.sharedService.CreateSimpleNotification(event.Message, event.Type, event.Duration);
61
105
  }
106
+ /** @deprecated Use {@link OnNotification}. */
107
+ onNotification(event) {
108
+ return this.OnNotification(event);
109
+ }
62
110
  /** Map the form's navigation requests onto Explorer's NavigationService. */
63
- handleNavigation(event) {
111
+ HandleNavigation(event) {
64
112
  switch (event.Kind) {
65
113
  case 'record':
66
114
  this.navigationService.OpenEntityRecord(event.EntityName, event.PrimaryKey, { forceNewTab: event.OpenInNewTab });
@@ -83,7 +131,7 @@ export class SingleRecordComponent extends BaseAngularComponent {
83
131
  window.open(`mailto:${event.EmailAddress}`, '_self');
84
132
  break;
85
133
  case 'dismiss':
86
- this.recordDismissed.emit();
134
+ this.RecordDismissed.emit();
87
135
  break;
88
136
  case 'create-related': {
89
137
  // A FK field wants a new related record created. Open the related entity's form
@@ -100,13 +148,17 @@ export class SingleRecordComponent extends BaseAngularComponent {
100
148
  }
101
149
  }
102
150
  }
151
+ /** @deprecated Use {@link HandleNavigation}. */
152
+ handleNavigation(event) {
153
+ return this.HandleNavigation(event);
154
+ }
103
155
  static ɵfac = /*@__PURE__*/ (() => { let ɵSingleRecordComponent_BaseFactory; return function SingleRecordComponent_Factory(__ngFactoryType__) { return (ɵSingleRecordComponent_BaseFactory || (ɵSingleRecordComponent_BaseFactory = i0.ɵɵgetInheritedFactory(SingleRecordComponent)))(__ngFactoryType__ || SingleRecordComponent); }; })();
104
156
  static ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: SingleRecordComponent, selectors: [["mj-single-record"]], viewQuery: function SingleRecordComponent_Query(rf, ctx) { if (rf & 1) {
105
157
  i0.ɵɵviewQuery(MjEntityFormHostComponent, 5);
106
158
  } if (rf & 2) {
107
159
  let _t;
108
160
  i0.ɵɵqueryRefresh(_t = i0.ɵɵloadQuery()) && (ctx.formHost = _t.first);
109
- } }, inputs: { PrimaryKey: "PrimaryKey", entityName: "entityName", newRecordValues: "newRecordValues" }, outputs: { loadComplete: "loadComplete", recordSaved: "recordSaved", recordDismissed: "recordDismissed" }, standalone: false, features: [i0.ɵɵInheritDefinitionFeature], decls: 1, vars: 4, consts: [[3, "LoadComplete", "LoadError", "RecordReady", "Saved", "Navigate", "Notification", "Dismissed", "EntityName", "PrimaryKey", "NewRecordValues", "Provider"]], template: function SingleRecordComponent_Template(rf, ctx) { if (rf & 1) {
161
+ } }, inputs: { PrimaryKey: "PrimaryKey", entityName: "entityName", NewRecordValues: "NewRecordValues", newRecordValues: "newRecordValues" }, outputs: { LoadComplete: "LoadComplete", loadComplete: "loadComplete", RecordSaved: "RecordSaved", recordSaved: "recordSaved", RecordDismissed: "RecordDismissed", recordDismissed: "recordDismissed" }, standalone: false, features: [i0.ɵɵInheritDefinitionFeature], decls: 1, vars: 4, consts: [[3, "LoadComplete", "LoadError", "RecordReady", "Saved", "Navigate", "Notification", "Dismissed", "EntityName", "PrimaryKey", "NewRecordValues", "Provider"]], template: function SingleRecordComponent_Template(rf, ctx) { if (rf & 1) {
110
162
  i0.ɵɵelementStart(0, "mj-entity-form-host", 0);
111
163
  i0.ɵɵlistener("LoadComplete", function SingleRecordComponent_Template_mj_entity_form_host_LoadComplete_0_listener() { return ctx.onLoadComplete(); })("LoadError", function SingleRecordComponent_Template_mj_entity_form_host_LoadError_0_listener() { return ctx.onLoadComplete(); })("RecordReady", function SingleRecordComponent_Template_mj_entity_form_host_RecordReady_0_listener($event) { return ctx.onRecordReady($event); })("Saved", function SingleRecordComponent_Template_mj_entity_form_host_Saved_0_listener($event) { return ctx.onSaved($event); })("Navigate", function SingleRecordComponent_Template_mj_entity_form_host_Navigate_0_listener($event) { return ctx.handleNavigation($event); })("Notification", function SingleRecordComponent_Template_mj_entity_form_host_Notification_0_listener($event) { return ctx.onNotification($event); })("Dismissed", function SingleRecordComponent_Template_mj_entity_form_host_Dismissed_0_listener() { return ctx.recordDismissed.emit(); });
112
164
  i0.ɵɵelementEnd();
@@ -121,12 +173,20 @@ export class SingleRecordComponent extends BaseAngularComponent {
121
173
  type: Input
122
174
  }], entityName: [{
123
175
  type: Input
176
+ }], NewRecordValues: [{
177
+ type: Input
124
178
  }], newRecordValues: [{
125
179
  type: Input
180
+ }], LoadComplete: [{
181
+ type: Output
126
182
  }], loadComplete: [{
127
183
  type: Output
184
+ }], RecordSaved: [{
185
+ type: Output
128
186
  }], recordSaved: [{
129
187
  type: Output
188
+ }], RecordDismissed: [{
189
+ type: Output
130
190
  }], recordDismissed: [{
131
191
  type: Output
132
192
  }], formHost: [{
@@ -1 +1 @@
1
- {"version":3,"file":"single-record.component.js","sourceRoot":"","sources":["../../../src/lib/single-record/single-record.component.ts","../../../src/lib/single-record/single-record.component.html"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,YAAY,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,EAAE,SAAS,EAAE,MAAM,eAAe,CAAC;AAC1F,OAAO,EAAE,YAAY,EAAc,MAAM,sBAAsB,CAAC;AAChE,OAAO,EAA8C,sBAAsB,EAAE,yBAAyB,EAAE,MAAM,+BAA+B,CAAC;AAC9I,OAAO,EAAE,iBAAiB,EAAE,mBAAmB,EAAE,aAAa,EAAE,MAAM,2BAA2B,CAAC;AAClG,OAAO,EAAE,oBAAoB,EAAE,MAAM,+BAA+B,CAAC;;;AAErE;;;;;;;;;;;;;GAaG;AAOH,MAAM,OAAO,qBAAsB,SAAQ,oBAAoB;IAC7C,UAAU,GAAiB,IAAI,YAAY,EAAE,CAAC;IAC9C,UAAU,GAAkB,EAAE,CAAC;IAC/B,eAAe,GAA4C,EAAE,CAAC;IAE7D,YAAY,GAAuB,IAAI,YAAY,EAAQ,CAAC;IAC5D,WAAW,GAA6B,IAAI,YAAY,EAAc,CAAC;IACxF,wFAAwF;IACvE,eAAe,GAAuB,IAAI,YAAY,EAAQ,CAAC;IAElC,QAAQ,CAA6B;IAEnF;;;;;;;OAOG;IACI,SAAS;QACd,OAAO,IAAI,CAAC,QAAQ,EAAE,IAAI,EAAE,QAAQ,KAAK,IAAI,CAAC;IAChD,CAAC;IAEO,iBAAiB,GAAG,MAAM,CAAC,iBAAiB,CAAC,CAAC;IAC9C,aAAa,GAAG,MAAM,CAAC,aAAa,CAAC,CAAC;IACtC,aAAa,GAAG,MAAM,CAAC,sBAAsB,CAAC,CAAC;IAC/C,mBAAmB,GAAG,IAAI,mBAAmB,EAAE,CAAC;IAExD,uEAAuE;IACvE,cAAc;QACZ,IAAI,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AVzB,qBAAqB","sourcesContent":["import { Component, EventEmitter, inject, Input, Output, ViewChild } from '@angular/core';\nimport { CompositeKey, BaseEntity } from '@memberjunction/core';\nimport { FormNavigationEvent, FormNotificationEvent, MJFormPresenterService, MjEntityFormHostComponent } from '@memberjunction/ng-base-forms';\nimport { NavigationService, RecentAccessService, SharedService } from '@memberjunction/ng-shared';\nimport { BaseAngularComponent } from '@memberjunction/ng-base-types';\n\n/**\n * Explorer-side host for a single entity record in the main tab area.\n *\n * This is now a **thin wrapper** around the Generic `<mj-entity-form-host>`\n * (in `@memberjunction/ng-base-forms`), which owns all the mechanics: resolving\n * the form (class / custom / interactive override + variants), loading the\n * record, dynamically creating the form, binding it, and tearing it down.\n *\n * SingleRecordComponent's only remaining job is the **Explorer mapping**:\n * translating the host's framework-agnostic events into Explorer services —\n * `Navigate` → {@link NavigationService}, `Notification` → {@link SharedService},\n * record loads → {@link RecentAccessService} — none of which belong in a Generic\n * component.\n */\n@Component({\n standalone: false,\n selector: 'mj-single-record',\n templateUrl: './single-record.component.html',\n styleUrls: ['./single-record.component.css']\n})\nexport class SingleRecordComponent extends BaseAngularComponent {\n @Input() public PrimaryKey: CompositeKey = new CompositeKey();\n @Input() public entityName: string | null = '';\n @Input() public newRecordValues: string | Record<string, unknown> | null = '';\n\n @Output() public loadComplete: EventEmitter<void> = new EventEmitter<void>();\n @Output() public recordSaved: EventEmitter<BaseEntity> = new EventEmitter<BaseEntity>();\n /** Emitted when the hosted form asks to be dismissed (e.g. Discard on a new record). */\n @Output() public recordDismissed: EventEmitter<void> = new EventEmitter<void>();\n\n @ViewChild(MjEntityFormHostComponent) private formHost?: MjEntityFormHostComponent;\n\n /**\n * True while the hosted form is in edit mode. The host already exposes the\n * live form instance, so this is a read, not a new event pipeline.\n *\n * MJ forms are read-only until the user explicitly clicks Edit, so edit mode\n * is a deliberate gesture and a sound proxy for \"there is work in here worth\n * protecting\" — which is all the preview-tab replacement guard needs.\n */\n public IsEditing(): boolean {\n return this.formHost?.Form?.EditMode === true;\n }\n\n private navigationService = inject(NavigationService);\n private sharedService = inject(SharedService);\n private formPresenter = inject(MJFormPresenterService);\n private recentAccessService = new RecentAccessService();\n\n /** Unblock the shell's first-resource-load gate (success or error). */\n onLoadComplete(): void {\n this.loadComplete.emit();\n }\n\n /** Log access for existing records once the form's record is ready. */\n onRecordReady(record: BaseEntity): void {\n if (record?.IsSaved) {\n this.recentAccessService.logAccess(record.EntityInfo.Name, record.PrimaryKey, 'record');\n }\n }\n\n onSaved(record: BaseEntity): void {\n this.recordSaved.emit(record);\n }\n\n onNotification(event: FormNotificationEvent): void {\n this.sharedService.CreateSimpleNotification(event.Message, event.Type, event.Duration);\n }\n\n /** Map the form's navigation requests onto Explorer's NavigationService. */\n handleNavigation(event: FormNavigationEvent): void {\n switch (event.Kind) {\n case 'record':\n this.navigationService.OpenEntityRecord(event.EntityName, event.PrimaryKey, { forceNewTab: event.OpenInNewTab });\n break;\n case 'new-record':\n // Creating a related record from inside an open form: force a new tab so the\n // parent record stays intact in single-resource mode.\n this.navigationService.OpenNewEntityRecord(event.EntityName, {\n newRecordValues: event.DefaultValues,\n forceNewTab: true,\n });\n break;\n case 'entity-hierarchy':\n this.navigationService.OpenEntityRecord(event.EntityName, event.PrimaryKey);\n break;\n case 'external-link':\n window.open(event.Url, '_blank');\n break;\n case 'email':\n window.open(`mailto:${event.EmailAddress}`, '_self');\n break;\n case 'dismiss':\n this.recordDismissed.emit();\n break;\n case 'create-related': {\n // A FK field wants a new related record created. Open the related entity's form\n // as a dialog/slide-in (prefilled), then hand the saved record back so the field\n // can select it.\n const ref = this.formPresenter.Open({\n EntityName: event.EntityName,\n Presentation: event.Presentation ?? 'dialog',\n NewRecordValues: event.NewRecordValues,\n Provider: event.Provider,\n });\n ref.AfterSaved().then(created => event.Complete(created));\n break;\n }\n }\n }\n}\n","<mj-entity-form-host\n [EntityName]=\"entityName\"\n [PrimaryKey]=\"PrimaryKey\"\n [NewRecordValues]=\"newRecordValues\"\n [Provider]=\"Provider\"\n (LoadComplete)=\"onLoadComplete()\"\n (LoadError)=\"onLoadComplete()\"\n (RecordReady)=\"onRecordReady($event)\"\n (Saved)=\"onSaved($event)\"\n (Navigate)=\"handleNavigation($event)\"\n (Notification)=\"onNotification($event)\"\n (Dismissed)=\"recordDismissed.emit()\">\n</mj-entity-form-host>\n"]}
1
+ {"version":3,"file":"single-record.component.js","sourceRoot":"","sources":["../../../src/lib/single-record/single-record.component.ts","../../../src/lib/single-record/single-record.component.html"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,YAAY,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,EAAE,SAAS,EAAE,MAAM,eAAe,CAAC;AAC1F,OAAO,EAAE,YAAY,EAAc,MAAM,sBAAsB,CAAC;AAChE,OAAO,EAA8C,sBAAsB,EAAE,yBAAyB,EAAE,MAAM,+BAA+B,CAAC;AAC9I,OAAO,EAAE,iBAAiB,EAAE,mBAAmB,EAAE,aAAa,EAAE,MAAM,2BAA2B,CAAC;AAClG,OAAO,EAAE,oBAAoB,EAAE,MAAM,+BAA+B,CAAC;;;AAErE;;;;;;;;;;;;;GAaG;AAOH,MAAM,OAAO,qBAAsB,SAAQ,oBAAoB;IAC7C,UAAU,GAAiB,IAAI,YAAY,EAAE,CAAC;IAC9C,UAAU,GAAkB,EAAE,CAAC;IAC/B,eAAe,GAA4C,EAAE,CAAC;IAE9E,+CAA+C;IAC/C,IAAoB,eAAe,CAAC,KAA8C;QAChF,IAAI,CAAC,eAAe,GAAG,KAAK,CAAC;IAC/B,CAAC;IACD,+CAA+C;IAC/C,IAAW,eAAe;QACxB,OAAO,IAAI,CAAC,eAAe,CAAC;IAC9B,CAAC;IAEgB,YAAY,GAAuB,IAAI,YAAY,EAAQ,CAAC;IAE7E;;;;;;OAMG;IACc,YAAY,GAAG,IAAI,CAAC,YAAY,CAAC;IACjC,WAAW,GAA6B,IAAI,YAAY,EAAc,CAAC;IAExF;;;;;;OAMG;IACc,WAAW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;gBACjB,MAAM,GAAG,GAAG,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC;oBAClC,UAAU,EAAE,KAAK,CAAC,UAAU;oBAC5B,YAAY,EAAE,KAAK,CAAC,YAAY,IAAI,QAAQ;oBAC5C,eAAe,EAAE,KAAK,CAAC,eAAe;oBACtC,QAAQ,EAAE,KAAK,CAAC,QAAQ;iBACzB,CAAC,CAAC;gBACH,GAAG,CAAC,UAAU,EAAE,CAAC,IAAI,CAAC,OAAO,CAAC,EAAE,CAAC,KAAK,CAAC,QAAQ,CAAC,OAAO,CAAC,CAAC,CAAC;gBAC1D,MAAM;YACR,CAAC;QACH,CAAC;IACH,CAAC;IAED,gDAAgD;IAChD,gBAAgB,CAAC,KAA0B;QACzC,OAAO,IAAI,CAAC,gBAAgB,CAAC,KAAK,CAAC,CAAC;IACtC,CAAC;iQAtJU,qBAAqB,yBAArB,qBAAqB;6DAArB,qBAAqB;2BA8CrB,yBAAyB;;;;;YCxEtC,8CAWuC;YAArC,AADA,AADA,AADA,AADA,AADA,AADA,6HAAgB,oBAAgB,IAAC,0GACpB,oBAAgB,IAAC,oHACf,yBAAqB,IAAC,wGAC5B,mBAAe,IAAC,8GACb,4BAAwB,IAAC,sHACrB,0BAAsB,IAAC,0GAC1B,0BAAsB,IAAC;YACtC,iBAAsB;;YARpB,AADA,AADA,AADA,2CAAyB,8BACA,wCACU,0BACd;;;iFDsBV,qBAAqB;cANjC,SAAS;6BACI,KAAK,YACP,kBAAkB;;kBAK3B,KAAK;;kBACL,KAAK;;kBACL,KAAK;;kBAGL,KAAK;;kBAQL,MAAM;;kBASN,MAAM;;kBACN,MAAM;;kBASN,MAAM;;kBAEN,MAAM;;kBASN,MAAM;;kBAEN,SAAS;mBAAC,yBAAyB;;kFA9CzB,qBAAqB","sourcesContent":["import { Component, EventEmitter, inject, Input, Output, ViewChild } from '@angular/core';\nimport { CompositeKey, BaseEntity } from '@memberjunction/core';\nimport { FormNavigationEvent, FormNotificationEvent, MJFormPresenterService, MjEntityFormHostComponent } from '@memberjunction/ng-base-forms';\nimport { NavigationService, RecentAccessService, SharedService } from '@memberjunction/ng-shared';\nimport { BaseAngularComponent } from '@memberjunction/ng-base-types';\n\n/**\n * Explorer-side host for a single entity record in the main tab area.\n *\n * This is now a **thin wrapper** around the Generic `<mj-entity-form-host>`\n * (in `@memberjunction/ng-base-forms`), which owns all the mechanics: resolving\n * the form (class / custom / interactive override + variants), loading the\n * record, dynamically creating the form, binding it, and tearing it down.\n *\n * SingleRecordComponent's only remaining job is the **Explorer mapping**:\n * translating the host's framework-agnostic events into Explorer services —\n * `Navigate` → {@link NavigationService}, `Notification` → {@link SharedService},\n * record loads → {@link RecentAccessService} — none of which belong in a Generic\n * component.\n */\n@Component({\n standalone: false,\n selector: 'mj-single-record',\n templateUrl: './single-record.component.html',\n styleUrls: ['./single-record.component.css']\n})\nexport class SingleRecordComponent extends BaseAngularComponent {\n @Input() public PrimaryKey: CompositeKey = new CompositeKey();\n @Input() public entityName: string | null = '';\n @Input() public NewRecordValues: string | Record<string, unknown> | null = '';\n\n /** @deprecated Use {@link NewRecordValues}. */\n @Input() public set newRecordValues(value: string | Record<string, unknown> | null) {\n this.NewRecordValues = value;\n }\n /** @deprecated Use {@link NewRecordValues}. */\n public get newRecordValues(): string | Record<string, unknown> | null {\n return this.NewRecordValues;\n }\n\n @Output() public LoadComplete: EventEmitter<void> = new EventEmitter<void>();\n\n /**\n * @deprecated Use {@link LoadComplete}.\n *\n * The same emitter under the old binding name, so a template still binding\n * (loadComplete) keeps working. Must stay AFTER LoadComplete: class fields\n * initialise in order, and the other way round this captures undefined.\n */\n @Output() public loadComplete = this.LoadComplete;\n @Output() public RecordSaved: EventEmitter<BaseEntity> = new EventEmitter<BaseEntity>();\n\n /**\n * @deprecated Use {@link RecordSaved}.\n *\n * The same emitter under the old binding name, so a template still binding\n * (recordSaved) keeps working. Must stay AFTER RecordSaved: class fields\n * initialise in order, and the other way round this captures undefined.\n */\n @Output() public recordSaved = this.RecordSaved;\n /** Emitted when the hosted form asks to be dismissed (e.g. Discard on a new record). */\n @Output() public RecordDismissed: EventEmitter<void> = new EventEmitter<void>();\n\n /**\n * @deprecated Use {@link RecordDismissed}.\n *\n * The same emitter under the old binding name, so a template still binding\n * (recordDismissed) keeps working. Must stay AFTER RecordDismissed: class fields\n * initialise in order, and the other way round this captures undefined.\n */\n @Output() public recordDismissed = this.RecordDismissed;\n\n @ViewChild(MjEntityFormHostComponent) private formHost?: MjEntityFormHostComponent;\n\n /**\n * True while the hosted form is in edit mode. The host already exposes the\n * live form instance, so this is a read, not a new event pipeline.\n *\n * MJ forms are read-only until the user explicitly clicks Edit, so edit mode\n * is a deliberate gesture and a sound proxy for \"there is work in here worth\n * protecting\" — which is all the preview-tab replacement guard needs.\n */\n public IsEditing(): boolean {\n return this.formHost?.Form?.EditMode === true;\n }\n\n private navigationService = inject(NavigationService);\n private sharedService = inject(SharedService);\n private formPresenter = inject(MJFormPresenterService);\n private recentAccessService = new RecentAccessService();\n\n /** Unblock the shell's first-resource-load gate (success or error). */\n OnLoadComplete(): void {\n this.LoadComplete.emit();\n }\n\n /** @deprecated Use {@link OnLoadComplete}. */\n onLoadComplete(): void {\n return this.OnLoadComplete();\n }\n\n /** Log access for existing records once the form's record is ready. */\n OnRecordReady(record: BaseEntity): void {\n if (record?.IsSaved) {\n this.recentAccessService.logAccess(record.EntityInfo.Name, record.PrimaryKey, 'record');\n }\n }\n\n /** @deprecated Use {@link OnRecordReady}. */\n onRecordReady(record: BaseEntity): void {\n return this.OnRecordReady(record);\n }\n\n OnSaved(record: BaseEntity): void {\n this.RecordSaved.emit(record);\n }\n\n /** @deprecated Use {@link OnSaved}. */\n onSaved(record: BaseEntity): void {\n return this.OnSaved(record);\n }\n\n OnNotification(event: FormNotificationEvent): void {\n this.sharedService.CreateSimpleNotification(event.Message, event.Type, event.Duration);\n }\n\n /** @deprecated Use {@link OnNotification}. */\n onNotification(event: FormNotificationEvent): void {\n return this.OnNotification(event);\n }\n\n /** Map the form's navigation requests onto Explorer's NavigationService. */\n HandleNavigation(event: FormNavigationEvent): void {\n switch (event.Kind) {\n case 'record':\n this.navigationService.OpenEntityRecord(event.EntityName, event.PrimaryKey, { forceNewTab: event.OpenInNewTab });\n break;\n case 'new-record':\n // Creating a related record from inside an open form: force a new tab so the\n // parent record stays intact in single-resource mode.\n this.navigationService.OpenNewEntityRecord(event.EntityName, {\n newRecordValues: event.DefaultValues,\n forceNewTab: true,\n });\n break;\n case 'entity-hierarchy':\n this.navigationService.OpenEntityRecord(event.EntityName, event.PrimaryKey);\n break;\n case 'external-link':\n window.open(event.Url, '_blank');\n break;\n case 'email':\n window.open(`mailto:${event.EmailAddress}`, '_self');\n break;\n case 'dismiss':\n this.RecordDismissed.emit();\n break;\n case 'create-related': {\n // A FK field wants a new related record created. Open the related entity's form\n // as a dialog/slide-in (prefilled), then hand the saved record back so the field\n // can select it.\n const ref = this.formPresenter.Open({\n EntityName: event.EntityName,\n Presentation: event.Presentation ?? 'dialog',\n NewRecordValues: event.NewRecordValues,\n Provider: event.Provider,\n });\n ref.AfterSaved().then(created => event.Complete(created));\n break;\n }\n }\n }\n\n /** @deprecated Use {@link HandleNavigation}. */\n handleNavigation(event: FormNavigationEvent): void {\n return this.HandleNavigation(event);\n }\n}\n","<mj-entity-form-host\n [EntityName]=\"entityName\"\n [PrimaryKey]=\"PrimaryKey\"\n [NewRecordValues]=\"newRecordValues\"\n [Provider]=\"Provider\"\n (LoadComplete)=\"onLoadComplete()\"\n (LoadError)=\"onLoadComplete()\"\n (RecordReady)=\"onRecordReady($event)\"\n (Saved)=\"onSaved($event)\"\n (Navigate)=\"handleNavigation($event)\"\n (Notification)=\"onNotification($event)\"\n (Dismissed)=\"recordDismissed.emit()\">\n</mj-entity-form-host>\n"]}
@@ -9,8 +9,28 @@ export declare class SingleSearchResultComponent extends BaseAngularComponent im
9
9
  private navigationService;
10
10
  private cdr;
11
11
  entity: string;
12
- searchInput: string;
12
+ SearchInput: string;
13
+ /** @deprecated Use {@link SearchInput}. */
14
+ set searchInput(value: string);
15
+ /** @deprecated Use {@link SearchInput}. */
16
+ get searchInput(): string;
17
+ LoadComplete: EventEmitter<boolean>;
18
+ /**
19
+ * @deprecated Use {@link LoadComplete}.
20
+ *
21
+ * The same emitter under the old binding name, so a template still binding
22
+ * (loadComplete) keeps working. Must stay AFTER LoadComplete: class fields
23
+ * initialise in order, and the other way round this captures undefined.
24
+ */
13
25
  loadComplete: EventEmitter<boolean>;
26
+ LoadStarted: EventEmitter<boolean>;
27
+ /**
28
+ * @deprecated Use {@link LoadStarted}.
29
+ *
30
+ * The same emitter under the old binding name, so a template still binding
31
+ * (loadStarted) keeps working. Must stay AFTER LoadStarted: class fields
32
+ * initialise in order, and the other way round this captures undefined.
33
+ */
14
34
  loadStarted: EventEmitter<boolean>;
15
35
  SearchState: SearchState;
16
36
  ResultCount: number;
@@ -25,7 +45,7 @@ export declare class SingleSearchResultComponent extends BaseAngularComponent im
25
45
  * Runs a lightweight pre-query (MaxRows: 2, PK fields only) to determine result count,
26
46
  * then routes to the appropriate state: no-results, single-result auto-nav, or viewer.
27
47
  */
28
- private ExecuteSearch;
48
+ private executeSearch;
29
49
  private findEntityInfo;
30
50
  private runPreQuery;
31
51
  private setNoResults;
@@ -38,7 +58,7 @@ export declare class SingleSearchResultComponent extends BaseAngularComponent im
38
58
  /** Format entity icon to ensure proper Font Awesome class format */
39
59
  private formatEntityIcon;
40
60
  static ɵfac: i0.ɵɵFactoryDeclaration<SingleSearchResultComponent, never>;
41
- static ɵcmp: i0.ɵɵComponentDeclaration<SingleSearchResultComponent, "mj-single-search-result", never, { "entity": { "alias": "entity"; "required": false; }; "searchInput": { "alias": "searchInput"; "required": false; }; }, { "loadComplete": "loadComplete"; "loadStarted": "loadStarted"; }, never, never, false, never>;
61
+ static ɵcmp: i0.ɵɵComponentDeclaration<SingleSearchResultComponent, "mj-single-search-result", never, { "entity": { "alias": "entity"; "required": false; }; "SearchInput": { "alias": "SearchInput"; "required": false; }; "searchInput": { "alias": "searchInput"; "required": false; }; }, { "LoadComplete": "LoadComplete"; "loadComplete": "loadComplete"; "LoadStarted": "LoadStarted"; "loadStarted": "loadStarted"; }, never, never, false, never>;
42
62
  }
43
63
  export {};
44
64
  //# sourceMappingURL=single-search-result.component.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"single-search-result.component.d.ts","sourceRoot":"","sources":["../../../src/lib/single-search-result/single-search-result.component.ts"],"names":[],"mappings":"AAAA,OAAO,EAAa,YAAY,EAAiB,iBAAiB,EAAE,SAAS,EAAE,aAAa,EAAE,MAAM,eAAe,CAAC;AACpH,OAAO,EAAyB,UAAU,EAAE,MAAM,sBAAsB,CAAC;AACzE,OAAO,EAAE,iBAAiB,EAAE,MAAM,2BAA2B,CAAC;AAC9D,OAAO,EAAE,eAAe,EAAE,iBAAiB,EAAE,kBAAkB,EAAE,2BAA2B,EAAE,MAAM,kCAAkC,CAAC;AAEvI,OAAO,EAAE,oBAAoB,EAAE,MAAM,+BAA+B,CAAC;;AACrE,KAAK,WAAW,GAAG,SAAS,GAAG,YAAY,GAAG,eAAe,GAAG,QAAQ,CAAC;AAEzE,qBAMa,2BAA4B,SAAQ,oBAAqB,YAAW,SAAS;IA8BtF,OAAO,CAAC,iBAAiB;IACzB,OAAO,CAAC,GAAG;IA9BG,MAAM,EAAE,MAAM,CAAM;IACpB,WAAW,EAAE,MAAM,CAAM;IACxB,YAAY,wBAA+B;IAC3C,WAAW,wBAA+B;IAEpD,WAAW,EAAE,WAAW,CAAa;IACrC,WAAW,SAAK;IAChB,UAAU,EAAE,UAAU,GAAG,IAAI,CAAQ;IAE5C,0EAA0E;IAC1E,IAAW,UAAU,IAAI,MAAM,CAK9B;IAED,8EAA8E;IACvE,YAAY,EAAE,OAAO,CAAC,kBAAkB,CAAC,CAQ9C;gBAGQ,iBAAiB,EAAE,iBAAiB,EACpC,GAAG,EAAE,iBAAiB;IAIhC,WAAW,CAAC,OAAO,EAAE,aAAa,GAAG,IAAI;IAMzC;;;OAGG;YACW,aAAa;IA+B3B,OAAO,CAAC,cAAc;YAOR,WAAW;IAazB,OAAO,CAAC,YAAY;IAOpB,OAAO,CAAC,sBAAsB;IAavB,iBAAiB,IAAI,IAAI;IAQzB,YAAY,CAAC,KAAK,EAAE,eAAe,GAAG,IAAI;IAM1C,cAAc,CAAC,KAAK,EAAE,iBAAiB,GAAG,IAAI;IAIrD,yGAAyG;IAClG,mBAAmB,CAAC,GAAG,EAAE,2BAA2B,GAAG,IAAI;IASlE,oEAAoE;IACpE,OAAO,CAAC,gBAAgB;yCAjJb,2BAA2B;2CAA3B,2BAA2B;CA+JvC"}
1
+ {"version":3,"file":"single-search-result.component.d.ts","sourceRoot":"","sources":["../../../src/lib/single-search-result/single-search-result.component.ts"],"names":[],"mappings":"AAAA,OAAO,EAAa,YAAY,EAAiB,iBAAiB,EAAE,SAAS,EAAE,aAAa,EAAE,MAAM,eAAe,CAAC;AACpH,OAAO,EAAyB,UAAU,EAAE,MAAM,sBAAsB,CAAC;AACzE,OAAO,EAAE,iBAAiB,EAAE,MAAM,2BAA2B,CAAC;AAC9D,OAAO,EAAE,eAAe,EAAE,iBAAiB,EAAE,kBAAkB,EAAE,2BAA2B,EAAE,MAAM,kCAAkC,CAAC;AAEvI,OAAO,EAAE,oBAAoB,EAAE,MAAM,+BAA+B,CAAC;;AACrE,KAAK,WAAW,GAAG,SAAS,GAAG,YAAY,GAAG,eAAe,GAAG,QAAQ,CAAC;AAEzE,qBAMa,2BAA4B,SAAQ,oBAAqB,YAAW,SAAS;IAyDtF,OAAO,CAAC,iBAAiB;IACzB,OAAO,CAAC,GAAG;IAzDG,MAAM,EAAE,MAAM,CAAM;IACpB,WAAW,EAAE,MAAM,CAAM;IAEzC,2CAA2C;IAC3C,IAAoB,WAAW,CAAC,KAAK,EAAE,MAAM,EAE5C;IACD,2CAA2C;IAC3C,IAAW,WAAW,IAAI,MAAM,CAE/B;IACgB,YAAY,wBAA+B;IAE5D;;;;;;OAMG;IACc,YAAY,wBAAqB;IACjC,WAAW,wBAA+B;IAE3D;;;;;;OAMG;IACc,WAAW,wBAAoB;IAEzC,WAAW,EAAE,WAAW,CAAa;IACrC,WAAW,SAAK;IAChB,UAAU,EAAE,UAAU,GAAG,IAAI,CAAQ;IAE5C,0EAA0E;IAC1E,IAAW,UAAU,IAAI,MAAM,CAK9B;IAED,8EAA8E;IACvE,YAAY,EAAE,OAAO,CAAC,kBAAkB,CAAC,CAQ9C;gBAGQ,iBAAiB,EAAE,iBAAiB,EACpC,GAAG,EAAE,iBAAiB;IAIhC,WAAW,CAAC,OAAO,EAAE,aAAa,GAAG,IAAI;IAMzC;;;OAGG;YACW,aAAa;IA+B3B,OAAO,CAAC,cAAc;YAOR,WAAW;IAazB,OAAO,CAAC,YAAY;IAOpB,OAAO,CAAC,sBAAsB;IAavB,iBAAiB,IAAI,IAAI;IAQzB,YAAY,CAAC,KAAK,EAAE,eAAe,GAAG,IAAI;IAM1C,cAAc,CAAC,KAAK,EAAE,iBAAiB,GAAG,IAAI;IAIrD,yGAAyG;IAClG,mBAAmB,CAAC,GAAG,EAAE,2BAA2B,GAAG,IAAI;IASlE,oEAAoE;IACpE,OAAO,CAAC,gBAAgB;yCA5Kb,2BAA2B;2CAA3B,2BAA2B;CA0LvC"}
@@ -82,9 +82,33 @@ export class SingleSearchResultComponent extends BaseAngularComponent {
82
82
  navigationService;
83
83
  cdr;
84
84
  entity = '';
85
- searchInput = '';
86
- loadComplete = new EventEmitter();
87
- loadStarted = new EventEmitter();
85
+ SearchInput = '';
86
+ /** @deprecated Use {@link SearchInput}. */
87
+ set searchInput(value) {
88
+ this.SearchInput = value;
89
+ }
90
+ /** @deprecated Use {@link SearchInput}. */
91
+ get searchInput() {
92
+ return this.SearchInput;
93
+ }
94
+ LoadComplete = new EventEmitter();
95
+ /**
96
+ * @deprecated Use {@link LoadComplete}.
97
+ *
98
+ * The same emitter under the old binding name, so a template still binding
99
+ * (loadComplete) keeps working. Must stay AFTER LoadComplete: class fields
100
+ * initialise in order, and the other way round this captures undefined.
101
+ */
102
+ loadComplete = this.LoadComplete;
103
+ LoadStarted = new EventEmitter();
104
+ /**
105
+ * @deprecated Use {@link LoadStarted}.
106
+ *
107
+ * The same emitter under the old binding name, so a template still binding
108
+ * (loadStarted) keeps working. Must stay AFTER LoadStarted: class fields
109
+ * initialise in order, and the other way round this captures undefined.
110
+ */
111
+ loadStarted = this.LoadStarted;
88
112
  SearchState = 'loading';
89
113
  ResultCount = 0;
90
114
  EntityInfo = null;
@@ -111,18 +135,18 @@ export class SingleSearchResultComponent extends BaseAngularComponent {
111
135
  this.cdr = cdr;
112
136
  }
113
137
  ngOnChanges(changes) {
114
- if ((changes['entity'] || changes['searchInput']) && this.entity && this.searchInput) {
115
- this.ExecuteSearch();
138
+ if ((changes['entity'] || changes['searchInput']) && this.entity && this.SearchInput) {
139
+ this.executeSearch();
116
140
  }
117
141
  }
118
142
  /**
119
143
  * Runs a lightweight pre-query (MaxRows: 2, PK fields only) to determine result count,
120
144
  * then routes to the appropriate state: no-results, single-result auto-nav, or viewer.
121
145
  */
122
- async ExecuteSearch() {
146
+ async executeSearch() {
123
147
  this.SearchState = 'loading';
124
148
  this.ResultCount = 0;
125
- this.loadStarted.emit(true);
149
+ this.LoadStarted.emit(true);
126
150
  // Resolve EntityInfo early so the header can show icon + display name during loading
127
151
  const entityInfo = this.findEntityInfo();
128
152
  this.EntityInfo = entityInfo ?? null;
@@ -154,7 +178,7 @@ export class SingleSearchResultComponent extends BaseAngularComponent {
154
178
  return rv.RunView({
155
179
  EntityName: this.entity,
156
180
  ExtraFilter: 'ID IS NOT NULL',
157
- UserSearchString: this.searchInput,
181
+ UserSearchString: this.SearchInput,
158
182
  Fields: pkFields,
159
183
  ResultType: 'simple',
160
184
  MaxRows: 2,
@@ -163,7 +187,7 @@ export class SingleSearchResultComponent extends BaseAngularComponent {
163
187
  setNoResults() {
164
188
  this.SearchState = 'no-results';
165
189
  this.ResultCount = 0;
166
- this.loadComplete.emit(true);
190
+ this.LoadComplete.emit(true);
167
191
  this.cdr.detectChanges();
168
192
  }
169
193
  navigateToSingleResult(entityInfo, record) {
@@ -173,7 +197,7 @@ export class SingleSearchResultComponent extends BaseAngularComponent {
173
197
  const compositeKey = new CompositeKey();
174
198
  compositeKey.LoadFromEntityInfoAndRecord(entityInfo, record);
175
199
  this.navigationService.OpenEntityRecord(entityInfo.Name, compositeKey);
176
- this.loadComplete.emit(true);
200
+ this.LoadComplete.emit(true);
177
201
  }
178
202
  // ── Header action handlers ──
179
203
  OnCreateNewRecord() {
@@ -184,7 +208,7 @@ export class SingleSearchResultComponent extends BaseAngularComponent {
184
208
  // ── Entity-viewer event handlers ──
185
209
  OnDataLoaded(event) {
186
210
  this.ResultCount = event.totalRowCount;
187
- this.loadComplete.emit(true);
211
+ this.LoadComplete.emit(true);
188
212
  this.cdr.detectChanges();
189
213
  }
190
214
  OnRecordOpened(event) {
@@ -215,7 +239,7 @@ export class SingleSearchResultComponent extends BaseAngularComponent {
215
239
  return `fa-solid fa-${icon}`;
216
240
  }
217
241
  static ɵfac = function SingleSearchResultComponent_Factory(__ngFactoryType__) { return new (__ngFactoryType__ || SingleSearchResultComponent)(i0.ɵɵdirectiveInject(i1.NavigationService), i0.ɵɵdirectiveInject(i0.ChangeDetectorRef)); };
218
- static ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: SingleSearchResultComponent, selectors: [["mj-single-search-result"]], inputs: { entity: "entity", searchInput: "searchInput" }, outputs: { loadComplete: "loadComplete", loadStarted: "loadStarted" }, standalone: false, features: [i0.ɵɵInheritDefinitionFeature, i0.ɵɵNgOnChangesFeature], decls: 14, vars: 9, consts: [[1, "search-result-container"], [1, "content-header"], [1, "header-left"], [1, "entity-icon"], [1, "entity-title"], [1, "record-count"], [1, "header-right"], [1, "loading-container"], ["Variant", "no-results", "Icon", "fa-solid fa-magnifying-glass"], ["Icon", "fa-solid fa-arrow-right", "Title", "Found 1 result \u2014 opening record..."], [1, "viewer-container"], ["title", "New Record", 1, "header-action-btn", 3, "click"], [1, "fa-solid", "fa-plus"], ["text", "Searching..."], [1, "search-result-empty-message"], [1, "empty-hint"], [3, "DataLoaded", "RecordOpened", "OpenRelatedRecordRequested", "CreateRecordRequested", "Entity", "Provider", "FilterText", "Config"]], template: function SingleSearchResultComponent_Template(rf, ctx) { if (rf & 1) {
242
+ static ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: SingleSearchResultComponent, selectors: [["mj-single-search-result"]], inputs: { entity: "entity", SearchInput: "SearchInput", searchInput: "searchInput" }, outputs: { LoadComplete: "LoadComplete", loadComplete: "loadComplete", LoadStarted: "LoadStarted", loadStarted: "loadStarted" }, standalone: false, features: [i0.ɵɵInheritDefinitionFeature, i0.ɵɵNgOnChangesFeature], decls: 14, vars: 9, consts: [[1, "search-result-container"], [1, "content-header"], [1, "header-left"], [1, "entity-icon"], [1, "entity-title"], [1, "record-count"], [1, "header-right"], [1, "loading-container"], ["Variant", "no-results", "Icon", "fa-solid fa-magnifying-glass"], ["Icon", "fa-solid fa-arrow-right", "Title", "Found 1 result \u2014 opening record..."], [1, "viewer-container"], ["title", "New Record", 1, "header-action-btn", 3, "click"], [1, "fa-solid", "fa-plus"], ["text", "Searching..."], [1, "search-result-empty-message"], [1, "empty-hint"], [3, "DataLoaded", "RecordOpened", "OpenRelatedRecordRequested", "CreateRecordRequested", "Entity", "Provider", "FilterText", "Config"]], template: function SingleSearchResultComponent_Template(rf, ctx) { if (rf & 1) {
219
243
  i0.ɵɵelementStart(0, "div", 0)(1, "div", 1)(2, "div", 2);
220
244
  i0.ɵɵelement(3, "i", 3);
221
245
  i0.ɵɵelementStart(4, "h2", 4);
@@ -254,10 +278,16 @@ export class SingleSearchResultComponent extends BaseAngularComponent {
254
278
  args: [{ standalone: false, selector: 'mj-single-search-result', template: "<div class=\"search-result-container\">\n <!-- Content Header \u2014 matches Data Explorer layout -->\n <div class=\"content-header\">\n <div class=\"header-left\">\n <i [class]=\"EntityIcon\" class=\"entity-icon\"></i>\n <h2 class=\"entity-title\">{{ EntityInfo?.DisplayNameOrName || entity }}</h2>\n @if (SearchState === 'loading') {\n <span class=\"record-count\">Searching for \"{{ searchInput }}\"...</span>\n } @else if (SearchState === 'no-results') {\n <span class=\"record-count\">No results for \"{{ searchInput }}\"</span>\n } @else if (ResultCount > 0) {\n <span class=\"record-count\">{{ ResultCount | number }} {{ ResultCount === 1 ? 'result' : 'results' }} for \"{{ searchInput }}\"</span>\n }\n </div>\n\n @if (SearchState === 'viewer' && EntityInfo) {\n <div class=\"header-right\">\n <!-- New Record -->\n <button\n class=\"header-action-btn\"\n (click)=\"OnCreateNewRecord()\"\n title=\"New Record\">\n <i class=\"fa-solid fa-plus\"></i>\n </button>\n </div>\n }\n </div>\n\n <!-- Loading state -->\n @if (SearchState === 'loading') {\n <div class=\"loading-container\">\n <mj-loading text=\"Searching...\"></mj-loading>\n </div>\n }\n\n <!-- No results -->\n @if (SearchState === 'no-results') {\n <mj-empty-state\n Variant=\"no-results\"\n Icon=\"fa-solid fa-magnifying-glass\">\n <p class=\"search-result-empty-message\">No results found for \"<strong>{{ searchInput }}</strong>\" in {{ entity }}</p>\n <p class=\"empty-hint\">Try a different search term or entity</p>\n </mj-empty-state>\n }\n\n <!-- Single result \u2014 auto-navigating to entity form -->\n @if (SearchState === 'single-result') {\n <mj-empty-state\n Icon=\"fa-solid fa-arrow-right\"\n Title=\"Found 1 result \u2014 opening record...\" />\n }\n\n <!-- Entity Viewer (2+ results) -->\n @if (SearchState === 'viewer' && EntityInfo) {\n <div class=\"viewer-container\">\n <mj-entity-viewer\n [Entity]=\"EntityInfo\"\n [Provider]=\"Provider\"\n [FilterText]=\"searchInput\"\n [Config]=\"ViewerConfig\"\n (DataLoaded)=\"OnDataLoaded($event)\"\n (RecordOpened)=\"OnRecordOpened($event)\"\n (OpenRelatedRecordRequested)=\"OnOpenRelatedRecord($event)\"\n (CreateRecordRequested)=\"OnCreateNewRecord()\">\n </mj-entity-viewer>\n </div>\n }\n</div>\n", styles: [".search-result-container {\n display: flex;\n flex-direction: column;\n height: 100%;\n}\n\n/* ============================================\n CONTENT HEADER \u2014 matches Data Explorer layout\n ============================================ */\n\n.content-header {\n display: flex;\n align-items: center;\n justify-content: space-between;\n padding: 16px 24px;\n background: var(--mj-bg-surface);\n border-bottom: 1px solid var(--mj-border-default);\n flex-shrink: 0;\n gap: 24px;\n box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);\n}\n\n.header-left {\n display: flex;\n align-items: center;\n gap: 12px;\n flex-shrink: 0;\n flex-wrap: wrap;\n}\n\n.entity-icon {\n font-size: 20px;\n color: var(--mj-brand-primary);\n}\n\n.entity-title {\n margin: 0;\n font-size: 20px;\n font-weight: 600;\n color: var(--mj-text-primary);\n}\n\n.record-count {\n font-size: 13px;\n color: var(--mj-text-secondary);\n font-weight: 500;\n}\n\n/* ============================================\n HEADER RIGHT \u2014 action buttons, view mode toggle\n ============================================ */\n\n.header-right {\n display: flex;\n align-items: center;\n gap: 16px;\n flex-shrink: 0;\n}\n\n/* Action Button (New Record, Export, etc.) */\n.header-action-btn {\n position: relative;\n width: 36px;\n height: 36px;\n border: 1px solid var(--mj-border-default);\n background: var(--mj-bg-surface);\n border-radius: 8px;\n cursor: pointer;\n display: flex;\n align-items: center;\n justify-content: center;\n color: var(--mj-text-secondary);\n transition: all 0.15s ease;\n}\n.header-action-btn:hover {\n border-color: var(--mj-brand-primary);\n color: var(--mj-brand-primary);\n background: color-mix(in srgb, var(--mj-brand-primary) 5%, var(--mj-bg-surface));\n}\n.header-action-btn i {\n font-size: 14px;\n}\n\n/* View Mode Toggle */\n.view-mode-toggle {\n display: flex;\n background: var(--mj-bg-surface-sunken);\n border-radius: 8px;\n padding: 3px;\n}\n\n.toggle-btn {\n width: 36px;\n height: 32px;\n border: none;\n background: transparent;\n border-radius: 6px;\n cursor: pointer;\n display: flex;\n align-items: center;\n justify-content: center;\n color: var(--mj-text-secondary);\n transition: all 0.15s ease;\n}\n.toggle-btn:hover {\n color: var(--mj-text-primary);\n}\n.toggle-btn.active {\n background: var(--mj-bg-surface);\n color: var(--mj-brand-primary);\n box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);\n}\n\n/* ============================================\n LOADING STATE\n ============================================ */\n\n.loading-container {\n display: flex;\n justify-content: center;\n align-items: center;\n padding: 48px 0;\n}\n\n/* ============================================\n EMPTY STATE\n ============================================ */\n\n.search-result-empty-message {\n margin: 4px 0;\n font-size: 15px;\n}\n\n.empty-hint {\n color: var(--mj-text-disabled);\n font-size: 13px;\n}\n\n/* ============================================\n VIEWER CONTAINER\n ============================================ */\n\n.viewer-container {\n flex: 1;\n min-height: 0;\n}\n"] }]
255
279
  }], () => [{ type: i1.NavigationService }, { type: i0.ChangeDetectorRef }], { entity: [{
256
280
  type: Input
281
+ }], SearchInput: [{
282
+ type: Input
257
283
  }], searchInput: [{
258
284
  type: Input
285
+ }], LoadComplete: [{
286
+ type: Output
259
287
  }], loadComplete: [{
260
288
  type: Output
289
+ }], LoadStarted: [{
290
+ type: Output
261
291
  }], loadStarted: [{
262
292
  type: Output
263
293
  }] }); })();