@skyux/lookup 5.2.2 → 5.5.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 (206) hide show
  1. package/README.md +6 -4
  2. package/documentation.json +409 -23
  3. package/esm2015/index.js +32 -0
  4. package/esm2015/index.js.map +1 -0
  5. package/esm2015/lib/modules/autocomplete/autocomplete-adapter.service.js +62 -0
  6. package/esm2015/lib/modules/autocomplete/autocomplete-adapter.service.js.map +1 -0
  7. package/esm2015/lib/modules/autocomplete/autocomplete-default-search-function.js +39 -0
  8. package/esm2015/lib/modules/autocomplete/autocomplete-default-search-function.js.map +1 -0
  9. package/esm2015/lib/modules/autocomplete/autocomplete-input.directive.js +220 -0
  10. package/esm2015/lib/modules/autocomplete/autocomplete-input.directive.js.map +1 -0
  11. package/esm2015/lib/modules/autocomplete/autocomplete-search-async-disabled.pipe.js +19 -0
  12. package/esm2015/lib/modules/autocomplete/autocomplete-search-async-disabled.pipe.js.map +1 -0
  13. package/esm2015/lib/modules/autocomplete/autocomplete.component.js +732 -0
  14. package/esm2015/lib/modules/autocomplete/autocomplete.component.js.map +1 -0
  15. package/esm2015/lib/modules/autocomplete/autocomplete.module.js +65 -0
  16. package/esm2015/lib/modules/autocomplete/autocomplete.module.js.map +1 -0
  17. package/esm2015/lib/modules/autocomplete/types/autocomplete-default-search-function-options.js +2 -0
  18. package/esm2015/lib/modules/autocomplete/types/autocomplete-default-search-function-options.js.map +1 -0
  19. package/esm2015/lib/modules/autocomplete/types/autocomplete-input-text-change.js +2 -0
  20. package/esm2015/lib/modules/autocomplete/types/autocomplete-input-text-change.js.map +1 -0
  21. package/esm2015/lib/modules/autocomplete/types/autocomplete-message-type.js +15 -0
  22. package/esm2015/lib/modules/autocomplete/types/autocomplete-message-type.js.map +1 -0
  23. package/esm2015/lib/modules/autocomplete/types/autocomplete-message.js +2 -0
  24. package/esm2015/lib/modules/autocomplete/types/autocomplete-message.js.map +1 -0
  25. package/esm2015/lib/modules/autocomplete/types/autocomplete-search-async-args.js +2 -0
  26. package/esm2015/lib/modules/autocomplete/types/autocomplete-search-async-args.js.map +1 -0
  27. package/esm2015/lib/modules/autocomplete/types/autocomplete-search-async-function.js +2 -0
  28. package/esm2015/lib/modules/autocomplete/types/autocomplete-search-async-function.js.map +1 -0
  29. package/esm2015/lib/modules/autocomplete/types/autocomplete-search-async-result-display-type.js +2 -0
  30. package/esm2015/lib/modules/autocomplete/types/autocomplete-search-async-result-display-type.js.map +1 -0
  31. package/esm2015/lib/modules/autocomplete/types/autocomplete-search-async-result.js +2 -0
  32. package/esm2015/lib/modules/autocomplete/types/autocomplete-search-async-result.js.map +1 -0
  33. package/esm2015/lib/modules/autocomplete/types/autocomplete-search-function-filter.js +2 -0
  34. package/esm2015/lib/modules/autocomplete/types/autocomplete-search-function-filter.js.map +1 -0
  35. package/esm2015/lib/modules/autocomplete/types/autocomplete-search-function-response.js +2 -0
  36. package/esm2015/lib/modules/autocomplete/types/autocomplete-search-function-response.js.map +1 -0
  37. package/esm2015/lib/modules/autocomplete/types/autocomplete-search-function.js +2 -0
  38. package/esm2015/lib/modules/autocomplete/types/autocomplete-search-function.js.map +1 -0
  39. package/esm2015/lib/modules/autocomplete/types/autocomplete-selection-change.js +2 -0
  40. package/esm2015/lib/modules/autocomplete/types/autocomplete-selection-change.js.map +1 -0
  41. package/esm2015/lib/modules/autocomplete/types/autocomplete-show-more-args.js +2 -0
  42. package/esm2015/lib/modules/autocomplete/types/autocomplete-show-more-args.js.map +1 -0
  43. package/esm2015/{modules → lib/modules}/country-field/country-field.component.js +5 -2
  44. package/esm2015/lib/modules/country-field/country-field.component.js.map +1 -0
  45. package/esm2015/lib/modules/country-field/country-field.module.js +49 -0
  46. package/esm2015/lib/modules/country-field/country-field.module.js.map +1 -0
  47. package/esm2015/lib/modules/country-field/types/country.js +2 -0
  48. package/esm2015/lib/modules/country-field/types/country.js.map +1 -0
  49. package/esm2015/lib/modules/lookup/lookup-adapter.service.js +21 -0
  50. package/esm2015/lib/modules/lookup/lookup-adapter.service.js.map +1 -0
  51. package/esm2015/lib/modules/lookup/lookup-autocomplete-adapter.js +72 -0
  52. package/esm2015/lib/modules/lookup/lookup-autocomplete-adapter.js.map +1 -0
  53. package/esm2015/lib/modules/lookup/lookup-item-selected.pipe.js +16 -0
  54. package/esm2015/lib/modules/lookup/lookup-item-selected.pipe.js.map +1 -0
  55. package/esm2015/lib/modules/lookup/lookup-show-more-async-modal.component.js +186 -0
  56. package/esm2015/lib/modules/lookup/lookup-show-more-async-modal.component.js.map +1 -0
  57. package/esm2015/lib/modules/lookup/lookup-show-more-modal.component.js +258 -0
  58. package/esm2015/lib/modules/lookup/lookup-show-more-modal.component.js.map +1 -0
  59. package/esm2015/lib/modules/lookup/lookup.component.js +608 -0
  60. package/esm2015/lib/modules/lookup/lookup.component.js.map +1 -0
  61. package/esm2015/lib/modules/lookup/lookup.module.js +94 -0
  62. package/esm2015/lib/modules/lookup/lookup.module.js.map +1 -0
  63. package/esm2015/lib/modules/lookup/types/lookup-add-click-callback-args.js +2 -0
  64. package/esm2015/lib/modules/lookup/types/lookup-add-click-callback-args.js.map +1 -0
  65. package/esm2015/lib/modules/lookup/types/lookup-add-click-event-args.js +2 -0
  66. package/esm2015/lib/modules/lookup/types/lookup-add-click-event-args.js.map +1 -0
  67. package/esm2015/lib/modules/lookup/types/lookup-select-mode-type.js +2 -0
  68. package/esm2015/lib/modules/lookup/types/lookup-select-mode-type.js.map +1 -0
  69. package/esm2015/lib/modules/lookup/types/lookup-select-mode.js +16 -0
  70. package/esm2015/lib/modules/lookup/types/lookup-select-mode.js.map +1 -0
  71. package/esm2015/lib/modules/lookup/types/lookup-show-more-config.js +2 -0
  72. package/esm2015/lib/modules/lookup/types/lookup-show-more-config.js.map +1 -0
  73. package/esm2015/lib/modules/lookup/types/lookup-show-more-custom-picker-context.js +7 -0
  74. package/esm2015/lib/modules/lookup/types/lookup-show-more-custom-picker-context.js.map +1 -0
  75. package/esm2015/lib/modules/lookup/types/lookup-show-more-custom-picker.js +2 -0
  76. package/esm2015/lib/modules/lookup/types/lookup-show-more-custom-picker.js.map +1 -0
  77. package/esm2015/lib/modules/lookup/types/lookup-show-more-native-picker-async-context.js +7 -0
  78. package/esm2015/lib/modules/lookup/types/lookup-show-more-native-picker-async-context.js.map +1 -0
  79. package/esm2015/lib/modules/lookup/types/lookup-show-more-native-picker-config.js +2 -0
  80. package/esm2015/lib/modules/lookup/types/lookup-show-more-native-picker-config.js.map +1 -0
  81. package/esm2015/lib/modules/lookup/types/lookup-show-more-native-picker-context.js +7 -0
  82. package/esm2015/lib/modules/lookup/types/lookup-show-more-native-picker-context.js.map +1 -0
  83. package/esm2015/lib/modules/search/search-adapter.service.js +45 -0
  84. package/esm2015/lib/modules/search/search-adapter.service.js.map +1 -0
  85. package/esm2015/lib/modules/search/search.component.js +260 -0
  86. package/esm2015/lib/modules/search/search.component.js.map +1 -0
  87. package/esm2015/lib/modules/search/search.module.js +46 -0
  88. package/esm2015/lib/modules/search/search.module.js.map +1 -0
  89. package/esm2015/lib/modules/shared/sky-lookup-resources.module.js +72 -0
  90. package/esm2015/lib/modules/shared/sky-lookup-resources.module.js.map +1 -0
  91. package/esm2015/lib/modules/shared/sky-lookup-string-utils.js +8 -0
  92. package/esm2015/lib/modules/shared/sky-lookup-string-utils.js.map +1 -0
  93. package/esm2015/lib/polyfills.js +30 -0
  94. package/esm2015/lib/polyfills.js.map +1 -0
  95. package/esm2015/skyux-lookup.js +2 -2
  96. package/esm2015/skyux-lookup.js.map +1 -0
  97. package/esm2015/testing/country-field/country-field-fixture.js +1 -1
  98. package/esm2015/testing/country-field/country-field-fixture.js.map +1 -0
  99. package/esm2015/testing/country-field/country-field-testing.module.js +1 -1
  100. package/esm2015/testing/country-field/country-field-testing.module.js.map +1 -0
  101. package/esm2015/testing/public-api.js +1 -1
  102. package/esm2015/testing/public-api.js.map +1 -0
  103. package/esm2015/testing/search/search-fixture.js +1 -1
  104. package/esm2015/testing/search/search-fixture.js.map +1 -0
  105. package/esm2015/testing/search/search-testing.module.js +1 -1
  106. package/esm2015/testing/search/search-testing.module.js.map +1 -0
  107. package/esm2015/testing/skyux-lookup-testing.js +1 -1
  108. package/esm2015/testing/skyux-lookup-testing.js.map +1 -0
  109. package/fesm2015/skyux-lookup-testing.js.map +1 -1
  110. package/fesm2015/skyux-lookup.js +2 -2
  111. package/fesm2015/skyux-lookup.js.map +1 -1
  112. package/index.d.ts +27 -0
  113. package/{modules → lib/modules}/autocomplete/autocomplete-adapter.service.d.ts +0 -0
  114. package/{modules → lib/modules}/autocomplete/autocomplete-default-search-function.d.ts +0 -0
  115. package/{modules → lib/modules}/autocomplete/autocomplete-input.directive.d.ts +0 -0
  116. package/{modules → lib/modules}/autocomplete/autocomplete-search-async-disabled.pipe.d.ts +0 -0
  117. package/{modules → lib/modules}/autocomplete/autocomplete.component.d.ts +0 -0
  118. package/{modules → lib/modules}/autocomplete/autocomplete.module.d.ts +0 -0
  119. package/{modules → lib/modules}/autocomplete/types/autocomplete-default-search-function-options.d.ts +0 -0
  120. package/{modules → lib/modules}/autocomplete/types/autocomplete-input-text-change.d.ts +0 -0
  121. package/{modules → lib/modules}/autocomplete/types/autocomplete-message-type.d.ts +0 -0
  122. package/{modules → lib/modules}/autocomplete/types/autocomplete-message.d.ts +0 -0
  123. package/{modules → lib/modules}/autocomplete/types/autocomplete-search-async-args.d.ts +0 -0
  124. package/{modules → lib/modules}/autocomplete/types/autocomplete-search-async-function.d.ts +0 -0
  125. package/{modules → lib/modules}/autocomplete/types/autocomplete-search-async-result-display-type.d.ts +0 -0
  126. package/{modules → lib/modules}/autocomplete/types/autocomplete-search-async-result.d.ts +0 -0
  127. package/{modules → lib/modules}/autocomplete/types/autocomplete-search-function-filter.d.ts +0 -0
  128. package/{modules → lib/modules}/autocomplete/types/autocomplete-search-function-response.d.ts +0 -0
  129. package/{modules → lib/modules}/autocomplete/types/autocomplete-search-function.d.ts +0 -0
  130. package/{modules → lib/modules}/autocomplete/types/autocomplete-selection-change.d.ts +0 -0
  131. package/{modules → lib/modules}/autocomplete/types/autocomplete-show-more-args.d.ts +0 -0
  132. package/{modules → lib/modules}/country-field/country-field.component.d.ts +0 -0
  133. package/{modules → lib/modules}/country-field/country-field.module.d.ts +0 -0
  134. package/{modules → lib/modules}/country-field/types/country.d.ts +0 -0
  135. package/{modules → lib/modules}/lookup/lookup-adapter.service.d.ts +0 -0
  136. package/{modules → lib/modules}/lookup/lookup-autocomplete-adapter.d.ts +0 -0
  137. package/{modules → lib/modules}/lookup/lookup-item-selected.pipe.d.ts +0 -0
  138. package/{modules → lib/modules}/lookup/lookup-show-more-async-modal.component.d.ts +0 -0
  139. package/{modules → lib/modules}/lookup/lookup-show-more-modal.component.d.ts +0 -0
  140. package/{modules → lib/modules}/lookup/lookup.component.d.ts +0 -0
  141. package/{modules → lib/modules}/lookup/lookup.module.d.ts +0 -0
  142. package/{modules → lib/modules}/lookup/types/lookup-add-click-callback-args.d.ts +0 -0
  143. package/{modules → lib/modules}/lookup/types/lookup-add-click-event-args.d.ts +0 -0
  144. package/{modules → lib/modules}/lookup/types/lookup-select-mode-type.d.ts +0 -0
  145. package/{modules → lib/modules}/lookup/types/lookup-select-mode.d.ts +0 -0
  146. package/{modules → lib/modules}/lookup/types/lookup-show-more-config.d.ts +0 -0
  147. package/{modules → lib/modules}/lookup/types/lookup-show-more-custom-picker-context.d.ts +0 -0
  148. package/{modules → lib/modules}/lookup/types/lookup-show-more-custom-picker.d.ts +0 -0
  149. package/{modules → lib/modules}/lookup/types/lookup-show-more-native-picker-async-context.d.ts +0 -0
  150. package/{modules → lib/modules}/lookup/types/lookup-show-more-native-picker-config.d.ts +0 -0
  151. package/{modules → lib/modules}/lookup/types/lookup-show-more-native-picker-context.d.ts +0 -0
  152. package/{modules → lib/modules}/search/search-adapter.service.d.ts +0 -0
  153. package/{modules → lib/modules}/search/search.component.d.ts +0 -0
  154. package/{modules → lib/modules}/search/search.module.d.ts +0 -0
  155. package/{modules → lib/modules}/shared/sky-lookup-resources.module.d.ts +0 -0
  156. package/{modules → lib/modules}/shared/sky-lookup-string-utils.d.ts +0 -0
  157. package/{polyfills.d.ts → lib/polyfills.d.ts} +0 -0
  158. package/package.json +23 -9
  159. package/skyux-lookup.d.ts +1 -1
  160. package/LICENSE +0 -21
  161. package/esm2015/modules/autocomplete/autocomplete-adapter.service.js +0 -61
  162. package/esm2015/modules/autocomplete/autocomplete-default-search-function.js +0 -39
  163. package/esm2015/modules/autocomplete/autocomplete-input.directive.js +0 -220
  164. package/esm2015/modules/autocomplete/autocomplete-search-async-disabled.pipe.js +0 -19
  165. package/esm2015/modules/autocomplete/autocomplete.component.js +0 -731
  166. package/esm2015/modules/autocomplete/autocomplete.module.js +0 -65
  167. package/esm2015/modules/autocomplete/types/autocomplete-default-search-function-options.js +0 -2
  168. package/esm2015/modules/autocomplete/types/autocomplete-input-text-change.js +0 -2
  169. package/esm2015/modules/autocomplete/types/autocomplete-message-type.js +0 -15
  170. package/esm2015/modules/autocomplete/types/autocomplete-message.js +0 -2
  171. package/esm2015/modules/autocomplete/types/autocomplete-search-async-args.js +0 -2
  172. package/esm2015/modules/autocomplete/types/autocomplete-search-async-function.js +0 -2
  173. package/esm2015/modules/autocomplete/types/autocomplete-search-async-result-display-type.js +0 -2
  174. package/esm2015/modules/autocomplete/types/autocomplete-search-async-result.js +0 -2
  175. package/esm2015/modules/autocomplete/types/autocomplete-search-function-filter.js +0 -2
  176. package/esm2015/modules/autocomplete/types/autocomplete-search-function-response.js +0 -2
  177. package/esm2015/modules/autocomplete/types/autocomplete-search-function.js +0 -2
  178. package/esm2015/modules/autocomplete/types/autocomplete-selection-change.js +0 -2
  179. package/esm2015/modules/autocomplete/types/autocomplete-show-more-args.js +0 -2
  180. package/esm2015/modules/country-field/country-field.module.js +0 -49
  181. package/esm2015/modules/country-field/types/country.js +0 -2
  182. package/esm2015/modules/lookup/lookup-adapter.service.js +0 -21
  183. package/esm2015/modules/lookup/lookup-autocomplete-adapter.js +0 -72
  184. package/esm2015/modules/lookup/lookup-item-selected.pipe.js +0 -16
  185. package/esm2015/modules/lookup/lookup-show-more-async-modal.component.js +0 -184
  186. package/esm2015/modules/lookup/lookup-show-more-modal.component.js +0 -256
  187. package/esm2015/modules/lookup/lookup.component.js +0 -602
  188. package/esm2015/modules/lookup/lookup.module.js +0 -94
  189. package/esm2015/modules/lookup/types/lookup-add-click-callback-args.js +0 -2
  190. package/esm2015/modules/lookup/types/lookup-add-click-event-args.js +0 -2
  191. package/esm2015/modules/lookup/types/lookup-select-mode-type.js +0 -2
  192. package/esm2015/modules/lookup/types/lookup-select-mode.js +0 -16
  193. package/esm2015/modules/lookup/types/lookup-show-more-config.js +0 -2
  194. package/esm2015/modules/lookup/types/lookup-show-more-custom-picker-context.js +0 -7
  195. package/esm2015/modules/lookup/types/lookup-show-more-custom-picker.js +0 -2
  196. package/esm2015/modules/lookup/types/lookup-show-more-native-picker-async-context.js +0 -7
  197. package/esm2015/modules/lookup/types/lookup-show-more-native-picker-config.js +0 -2
  198. package/esm2015/modules/lookup/types/lookup-show-more-native-picker-context.js +0 -7
  199. package/esm2015/modules/search/search-adapter.service.js +0 -45
  200. package/esm2015/modules/search/search.component.js +0 -260
  201. package/esm2015/modules/search/search.module.js +0 -46
  202. package/esm2015/modules/shared/sky-lookup-resources.module.js +0 -72
  203. package/esm2015/modules/shared/sky-lookup-string-utils.js +0 -8
  204. package/esm2015/polyfills.js +0 -30
  205. package/esm2015/public-api.js +0 -32
  206. package/public-api.d.ts +0 -27
@@ -0,0 +1,32 @@
1
+ export * from './lib/modules/autocomplete/types/autocomplete-default-search-function-options';
2
+ export * from './lib/modules/autocomplete/types/autocomplete-input-text-change';
3
+ export * from './lib/modules/autocomplete/types/autocomplete-search-async-args';
4
+ export * from './lib/modules/autocomplete/types/autocomplete-search-async-result';
5
+ export * from './lib/modules/autocomplete/types/autocomplete-search-async-result-display-type';
6
+ export * from './lib/modules/autocomplete/types/autocomplete-search-function';
7
+ export * from './lib/modules/autocomplete/types/autocomplete-search-function-filter';
8
+ export * from './lib/modules/autocomplete/types/autocomplete-search-function-response';
9
+ export * from './lib/modules/autocomplete/types/autocomplete-selection-change';
10
+ export * from './lib/modules/autocomplete/autocomplete.module';
11
+ export * from './lib/modules/country-field/country-field.module';
12
+ export * from './lib/modules/country-field/types/country';
13
+ export * from './lib/modules/lookup/lookup.module';
14
+ export * from './lib/modules/lookup/types/lookup-add-click-callback-args';
15
+ export * from './lib/modules/lookup/types/lookup-add-click-event-args';
16
+ export * from './lib/modules/lookup/types/lookup-select-mode';
17
+ export * from './lib/modules/lookup/types/lookup-select-mode-type';
18
+ export * from './lib/modules/lookup/types/lookup-show-more-config';
19
+ export * from './lib/modules/lookup/types/lookup-show-more-custom-picker';
20
+ export * from './lib/modules/lookup/types/lookup-show-more-custom-picker-context';
21
+ export * from './lib/modules/lookup/types/lookup-show-more-native-picker-config';
22
+ export * from './lib/modules/search/search.module';
23
+ // The following exports are needed internally by @skyux/list-builder.
24
+ // TODO: Find a way to remove them in the next major version release.
25
+ export * from './lib/modules/search/search.component';
26
+ // Components and directives must be exported to support Angular's "partial" Ivy compiler.
27
+ // Obscure names are used to indicate types are not part of the public API.
28
+ export { SkyAutocompleteInputDirective as λ1 } from './lib/modules/autocomplete/autocomplete-input.directive';
29
+ export { SkyAutocompleteComponent as λ2 } from './lib/modules/autocomplete/autocomplete.component';
30
+ export { SkyCountryFieldComponent as λ3 } from './lib/modules/country-field/country-field.component';
31
+ export { SkyLookupComponent as λ4 } from './lib/modules/lookup/lookup.component';
32
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../libs/components/lookup/src/index.ts"],"names":[],"mappings":"AAAA,cAAc,+EAA+E,CAAC;AAC9F,cAAc,iEAAiE,CAAC;AAChF,cAAc,iEAAiE,CAAC;AAChF,cAAc,mEAAmE,CAAC;AAClF,cAAc,gFAAgF,CAAC;AAC/F,cAAc,+DAA+D,CAAC;AAC9E,cAAc,sEAAsE,CAAC;AACrF,cAAc,wEAAwE,CAAC;AACvF,cAAc,gEAAgE,CAAC;AAC/E,cAAc,gDAAgD,CAAC;AAE/D,cAAc,kDAAkD,CAAC;AACjE,cAAc,2CAA2C,CAAC;AAE1D,cAAc,oCAAoC,CAAC;AACnD,cAAc,2DAA2D,CAAC;AAC1E,cAAc,wDAAwD,CAAC;AACvE,cAAc,+CAA+C,CAAC;AAC9D,cAAc,oDAAoD,CAAC;AACnE,cAAc,oDAAoD,CAAC;AACnE,cAAc,2DAA2D,CAAC;AAC1E,cAAc,mEAAmE,CAAC;AAClF,cAAc,kEAAkE,CAAC;AAEjF,cAAc,oCAAoC,CAAC;AAEnD,sEAAsE;AACtE,qEAAqE;AACrE,cAAc,uCAAuC,CAAC;AAEtD,0FAA0F;AAC1F,2EAA2E;AAC3E,OAAO,EAAE,6BAA6B,IAAI,EAAE,EAAE,MAAM,yDAAyD,CAAC;AAC9G,OAAO,EAAE,wBAAwB,IAAI,EAAE,EAAE,MAAM,mDAAmD,CAAC;AACnG,OAAO,EAAE,wBAAwB,IAAI,EAAE,EAAE,MAAM,qDAAqD,CAAC;AACrG,OAAO,EAAE,kBAAkB,IAAI,EAAE,EAAE,MAAM,uCAAuC,CAAC","sourcesContent":["export * from './lib/modules/autocomplete/types/autocomplete-default-search-function-options';\nexport * from './lib/modules/autocomplete/types/autocomplete-input-text-change';\nexport * from './lib/modules/autocomplete/types/autocomplete-search-async-args';\nexport * from './lib/modules/autocomplete/types/autocomplete-search-async-result';\nexport * from './lib/modules/autocomplete/types/autocomplete-search-async-result-display-type';\nexport * from './lib/modules/autocomplete/types/autocomplete-search-function';\nexport * from './lib/modules/autocomplete/types/autocomplete-search-function-filter';\nexport * from './lib/modules/autocomplete/types/autocomplete-search-function-response';\nexport * from './lib/modules/autocomplete/types/autocomplete-selection-change';\nexport * from './lib/modules/autocomplete/autocomplete.module';\n\nexport * from './lib/modules/country-field/country-field.module';\nexport * from './lib/modules/country-field/types/country';\n\nexport * from './lib/modules/lookup/lookup.module';\nexport * from './lib/modules/lookup/types/lookup-add-click-callback-args';\nexport * from './lib/modules/lookup/types/lookup-add-click-event-args';\nexport * from './lib/modules/lookup/types/lookup-select-mode';\nexport * from './lib/modules/lookup/types/lookup-select-mode-type';\nexport * from './lib/modules/lookup/types/lookup-show-more-config';\nexport * from './lib/modules/lookup/types/lookup-show-more-custom-picker';\nexport * from './lib/modules/lookup/types/lookup-show-more-custom-picker-context';\nexport * from './lib/modules/lookup/types/lookup-show-more-native-picker-config';\n\nexport * from './lib/modules/search/search.module';\n\n// The following exports are needed internally by @skyux/list-builder.\n// TODO: Find a way to remove them in the next major version release.\nexport * from './lib/modules/search/search.component';\n\n// Components and directives must be exported to support Angular's \"partial\" Ivy compiler.\n// Obscure names are used to indicate types are not part of the public API.\nexport { SkyAutocompleteInputDirective as λ1 } from './lib/modules/autocomplete/autocomplete-input.directive';\nexport { SkyAutocompleteComponent as λ2 } from './lib/modules/autocomplete/autocomplete.component';\nexport { SkyCountryFieldComponent as λ3 } from './lib/modules/country-field/country-field.component';\nexport { SkyLookupComponent as λ4 } from './lib/modules/lookup/lookup.component';\n"]}
@@ -0,0 +1,62 @@
1
+ import { Injectable, RendererFactory2, } from '@angular/core';
2
+ import { SkyCoreAdapterService } from '@skyux/core';
3
+ import '../../polyfills';
4
+ import * as i0 from "@angular/core";
5
+ import * as i1 from "@skyux/core";
6
+ /**
7
+ * @internal
8
+ */
9
+ export class SkyAutocompleteAdapterService {
10
+ constructor(coreAdapterService, rendererFactory) {
11
+ this.coreAdapterService = coreAdapterService;
12
+ this.rendererFactory = rendererFactory;
13
+ this.renderer = this.rendererFactory.createRenderer(undefined, undefined);
14
+ }
15
+ /**
16
+ * Adds the className for the provided element.
17
+ */
18
+ addCSSClass(element, className) {
19
+ /* Sanity check */
20
+ /* istanbul ignore else */
21
+ if (element) {
22
+ this.renderer.addClass(element, className);
23
+ }
24
+ }
25
+ getOverlayFocusableElements(overlay) {
26
+ return this.coreAdapterService.getFocusableChildren(
27
+ /* Sanity check - calling function also has null check */
28
+ /* istanbul ignore next */
29
+ overlay === null || overlay === void 0 ? void 0 : overlay.componentRef.location.nativeElement, { ignoreTabIndex: true });
30
+ }
31
+ /**
32
+ * Removes the className for the provided element.
33
+ */
34
+ removeCSSClass(element, className) {
35
+ /* Sanity check */
36
+ /* istanbul ignore else */
37
+ if (element) {
38
+ this.renderer.removeClass(element, className);
39
+ }
40
+ }
41
+ setDropdownWidth(elementRef, dropdownRef, isInputBox) {
42
+ const parentElement = isInputBox
43
+ ? elementRef.nativeElement.closest('.sky-input-box')
44
+ : elementRef.nativeElement;
45
+ if (parentElement) {
46
+ const width = parentElement.getBoundingClientRect().width;
47
+ this.renderer.setStyle(dropdownRef.nativeElement, 'width', `${width}px`);
48
+ }
49
+ }
50
+ /**
51
+ * Sets the `tabIndex` of the `element` to the provided `tabIndex`.
52
+ */
53
+ setTabIndex(element, tabIndex) {
54
+ element.tabIndex = tabIndex;
55
+ }
56
+ }
57
+ SkyAutocompleteAdapterService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: SkyAutocompleteAdapterService, deps: [{ token: i1.SkyCoreAdapterService }, { token: i0.RendererFactory2 }], target: i0.ɵɵFactoryTarget.Injectable });
58
+ SkyAutocompleteAdapterService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: SkyAutocompleteAdapterService });
59
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: SkyAutocompleteAdapterService, decorators: [{
60
+ type: Injectable
61
+ }], ctorParameters: function () { return [{ type: i1.SkyCoreAdapterService }, { type: i0.RendererFactory2 }]; } });
62
+ //# sourceMappingURL=autocomplete-adapter.service.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"autocomplete-adapter.service.js","sourceRoot":"","s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C,OAAO,CAAC,gBAAgB,CAAC;YACpD,CAAC,CAAC,UAAU,CAAC,aAAa,CAAC;QAC7B,IAAI,aAAa,EAAE;YACjB,MAAM,KAAK,GAAG,aAAa,CAAC,qBAAqB,EAAE,CAAC,KAAK,CAAC;YAC1D,IAAI,CAAC,QAAQ,CAAC,QAAQ,CAAC,WAAW,CAAC,aAAa,EAAE,OAAO,EAAE,GAAG,KAAK,IAAI,CAAC,CAAC;SAC1E;IACH,CAAC;IAED;;OAEG;IACI,WAAW,CAAC,OAAoB,EAAE,QAAgB;QACvD,OAAO,CAAC,QAAQ,GAAG,QAAQ,CAAC;IAC9B,CAAC;;2HA9DU,6BAA6B;+HAA7B,6BAA6B;4FAA7B,6BAA6B;kBADzC,UAAU","sourcesContent":["import {\n ElementRef,\n Injectable,\n Renderer2,\n RendererFactory2,\n} from '@angular/core';\n\nimport { SkyCoreAdapterService, SkyOverlayInstance } from '@skyux/core';\n\nimport '../../polyfills';\n\n/**\n * @internal\n */\n@Injectable()\nexport class SkyAutocompleteAdapterService {\n private renderer: Renderer2;\n\n constructor(\n private coreAdapterService: SkyCoreAdapterService,\n private rendererFactory: RendererFactory2\n ) {\n this.renderer = this.rendererFactory.createRenderer(undefined, undefined);\n }\n\n /**\n * Adds the className for the provided element.\n */\n public addCSSClass(element: HTMLElement, className: string): void {\n /* Sanity check */\n /* istanbul ignore else */\n if (element) {\n this.renderer.addClass(element, className);\n }\n }\n\n public getOverlayFocusableElements(\n overlay: SkyOverlayInstance\n ): HTMLElement[] {\n return this.coreAdapterService.getFocusableChildren(\n /* Sanity check - calling function also has null check */\n /* istanbul ignore next */\n overlay?.componentRef.location.nativeElement,\n { ignoreTabIndex: true }\n );\n }\n\n /**\n * Removes the className for the provided element.\n */\n public removeCSSClass(element: HTMLElement, className: string): void {\n /* Sanity check */\n /* istanbul ignore else */\n if (element) {\n this.renderer.removeClass(element, className);\n }\n }\n\n public setDropdownWidth(\n elementRef: ElementRef,\n dropdownRef: ElementRef,\n isInputBox: boolean\n ): void {\n const parentElement = isInputBox\n ? elementRef.nativeElement.closest('.sky-input-box')\n : elementRef.nativeElement;\n if (parentElement) {\n const width = parentElement.getBoundingClientRect().width;\n this.renderer.setStyle(dropdownRef.nativeElement, 'width', `${width}px`);\n }\n }\n\n /**\n * Sets the `tabIndex` of the `element` to the provided `tabIndex`.\n */\n public setTabIndex(element: HTMLElement, tabIndex: number): void {\n element.tabIndex = tabIndex;\n }\n}\n"]}
@@ -0,0 +1,39 @@
1
+ import { normalizeDiacritics } from '../shared/sky-lookup-string-utils';
2
+ export function skyAutocompleteDefaultSearchFunction(options) {
3
+ const filterData = function (searchText, data) {
4
+ return data.filter((item) => {
5
+ if (!options.searchFilters || !options.searchFilters.length) {
6
+ return true;
7
+ }
8
+ // Find the first failing filter (we can skip the others if one fails).
9
+ const failedFilter = options.searchFilters.find((filter) => {
10
+ return !filter.call({}, searchText, item);
11
+ });
12
+ return failedFilter === undefined;
13
+ });
14
+ };
15
+ const search = function (searchText, data) {
16
+ const results = [];
17
+ /* Sanity check - autocomplete will not call search with empty search text */
18
+ /* istanbul ignore if */
19
+ if (!searchText) {
20
+ return results;
21
+ }
22
+ const searchTextNormalized = normalizeDiacritics(searchText).toUpperCase();
23
+ const filteredData = filterData(searchText, data);
24
+ for (let i = 0, n = filteredData.length; i < n; i++) {
25
+ const result = filteredData[i];
26
+ const isMatch = options.propertiesToSearch.find((property) => {
27
+ let value = (result[property] || '').toString();
28
+ value = normalizeDiacritics(value).toUpperCase();
29
+ return value.indexOf(searchTextNormalized) > -1;
30
+ });
31
+ if (isMatch) {
32
+ results.push(result);
33
+ }
34
+ }
35
+ return results;
36
+ };
37
+ return search;
38
+ }
39
+ //# sourceMappingURL=autocomplete-default-search-function.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"autocomplete-default-search-function.js","sourceRoot":"","sources":["../../../../../../../../libs/components/lookup/src/lib/modules/autocomplete/autocomplete-default-search-function.ts"],"names":[],"mappings":"AAOA,OAA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AAC,IAAI,EAAE,CAAC,CAAC,QAAQ,EAAE,CAAC;gBAChD,KAAK,GAAG,mBAAmB,CAAC,KAAK,CAAC,CAAC,WAAW,EAAE,CAAC;gBACjD,OAAO,KAAK,CAAC,OAAO,CAAC,oBAAoB,CAAC,GAAG,CAAC,CAAC,CAAC;YAClD,CAAC,CAAC,CAAC;YAEH,IAAI,OAAO,EAAE;gBACX,OAAO,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC;aACtB;SACF;QAED,OAAO,OAAO,CAAC;IACjB,CAAC,CAAC;IAEF,OAAO,MAAM,CAAC;AAChB,CAAC","sourcesContent":["import { SkyAutocompleteSearchFunction } from './types/autocomplete-search-function';\n\nimport { SkyAutocompleteSearchFunctionFilter } from './types/autocomplete-search-function-filter';\n\nimport { SkyAutocompleteSearchFunctionResponse } from './types/autocomplete-search-function-response';\n\nimport { SkyAutocompleteDefaultSearchFunctionOptions } from './types/autocomplete-default-search-function-options';\nimport { normalizeDiacritics } from '../shared/sky-lookup-string-utils';\n\nexport function skyAutocompleteDefaultSearchFunction(\n options: SkyAutocompleteDefaultSearchFunctionOptions\n): SkyAutocompleteSearchFunction {\n const filterData = function (searchText: string, data: any[]): any[] {\n return data.filter((item: any) => {\n if (!options.searchFilters || !options.searchFilters.length) {\n return true;\n }\n\n // Find the first failing filter (we can skip the others if one fails).\n const failedFilter = options.searchFilters.find(\n (filter: SkyAutocompleteSearchFunctionFilter) => {\n return !filter.call({}, searchText, item);\n }\n );\n\n return failedFilter === undefined;\n });\n };\n\n const search = function (\n searchText: string,\n data: any[]\n ): SkyAutocompleteSearchFunctionResponse {\n const results = [];\n\n /* Sanity check - autocomplete will not call search with empty search text */\n /* istanbul ignore if */\n if (!searchText) {\n return results;\n }\n\n const searchTextNormalized = normalizeDiacritics(searchText).toUpperCase();\n\n const filteredData = filterData(searchText, data);\n\n for (let i = 0, n = filteredData.length; i < n; i++) {\n const result = filteredData[i];\n const isMatch = options.propertiesToSearch.find((property: string) => {\n let value = (result[property] || '').toString();\n value = normalizeDiacritics(value).toUpperCase();\n return value.indexOf(searchTextNormalized) > -1;\n });\n\n if (isMatch) {\n results.push(result);\n }\n }\n\n return results;\n };\n\n return search;\n}\n"]}
@@ -0,0 +1,220 @@
1
+ import { Directive, ElementRef, forwardRef, Input, Renderer2, } from '@angular/core';
2
+ import { NG_VALIDATORS, NG_VALUE_ACCESSOR, } from '@angular/forms';
3
+ import { fromEvent as observableFromEvent, Subject } from 'rxjs';
4
+ import { takeUntil } from 'rxjs/operators';
5
+ import * as i0 from "@angular/core";
6
+ // tslint:disable:no-forward-ref no-use-before-declare
7
+ const SKY_AUTOCOMPLETE_VALUE_ACCESSOR = {
8
+ provide: NG_VALUE_ACCESSOR,
9
+ useExisting: forwardRef(() => SkyAutocompleteInputDirective),
10
+ multi: true,
11
+ };
12
+ const SKY_AUTOCOMPLETE_VALIDATOR = {
13
+ provide: NG_VALIDATORS,
14
+ useExisting: forwardRef(() => SkyAutocompleteInputDirective),
15
+ multi: true,
16
+ };
17
+ // tslint:enable
18
+ export class SkyAutocompleteInputDirective {
19
+ constructor(elementRef, renderer) {
20
+ this.elementRef = elementRef;
21
+ this.renderer = renderer;
22
+ this.isFirstChange = true;
23
+ this.ngUnsubscribe = new Subject();
24
+ this._blur = new Subject();
25
+ this._disabled = false;
26
+ this._focus = new Subject();
27
+ this._textChanges = new Subject();
28
+ /* istanbul ignore next */
29
+ this.onValidatorChange = () => { };
30
+ }
31
+ /**
32
+ * Specifies the value for the `autocomplete` attribute on the form input.
33
+ * @default "off"
34
+ */
35
+ set autocompleteAttribute(value) {
36
+ if (!value) {
37
+ this._autocompleteAttribute = 'off';
38
+ }
39
+ else {
40
+ this._autocompleteAttribute = value;
41
+ }
42
+ this.renderer.setAttribute(this.elementRef.nativeElement, 'autocomplete', this.autocompleteAttribute);
43
+ }
44
+ get autocompleteAttribute() {
45
+ return this._autocompleteAttribute || 'off';
46
+ }
47
+ /**
48
+ * Indicates whether to disable the autocomplete field.
49
+ * @default false
50
+ */
51
+ set disabled(value) {
52
+ this._disabled = value;
53
+ this.renderer.setProperty(this.elementRef.nativeElement, 'disabled', value);
54
+ }
55
+ get disabled() {
56
+ return this._disabled;
57
+ }
58
+ get blur() {
59
+ return this._blur.asObservable();
60
+ }
61
+ get displayWith() {
62
+ return this._displayWith;
63
+ }
64
+ set displayWith(value) {
65
+ this._displayWith = value;
66
+ this.inputTextValue = this.getValueByKey();
67
+ }
68
+ /**
69
+ * @internal
70
+ */
71
+ get inputElement() {
72
+ return this.elementRef.nativeElement;
73
+ }
74
+ get focus() {
75
+ return this._focus.asObservable();
76
+ }
77
+ get inputTextValue() {
78
+ return this.elementRef.nativeElement.value;
79
+ }
80
+ set inputTextValue(value) {
81
+ this.elementRef.nativeElement.value = value || '';
82
+ }
83
+ get textChanges() {
84
+ return this._textChanges.asObservable();
85
+ }
86
+ get value() {
87
+ return this._value;
88
+ }
89
+ set value(value) {
90
+ const isNewValue = value !== this._value;
91
+ /* istanbul ignore else */
92
+ if (isNewValue) {
93
+ this._value = value;
94
+ this.inputTextValue = this.getValueByKey();
95
+ this.onChange(this._value);
96
+ // Do not mark the field as "dirty"
97
+ // if the field has been initialized with a value.
98
+ if (this.isFirstChange && this.control) {
99
+ this.control.markAsPristine();
100
+ }
101
+ if (this.isFirstChange && this._value) {
102
+ this.isFirstChange = false;
103
+ }
104
+ }
105
+ }
106
+ ngOnInit() {
107
+ const element = this.elementRef.nativeElement;
108
+ this.setAttributes(element);
109
+ observableFromEvent(element, 'input')
110
+ .pipe(takeUntil(this.ngUnsubscribe))
111
+ .subscribe(() => {
112
+ /** Sanity check */
113
+ if (!this.disabled) {
114
+ this._textChanges.next({
115
+ value: this.elementRef.nativeElement.value,
116
+ });
117
+ }
118
+ });
119
+ observableFromEvent(element, 'blur')
120
+ .pipe(takeUntil(this.ngUnsubscribe))
121
+ .subscribe(() => {
122
+ /** Sanity check */
123
+ if (!this.disabled) {
124
+ this._blur.next();
125
+ }
126
+ });
127
+ observableFromEvent(element, 'focus')
128
+ .pipe(takeUntil(this.ngUnsubscribe))
129
+ .subscribe(() => {
130
+ /** Sanity check */
131
+ if (!this.disabled) {
132
+ this._focus.next();
133
+ }
134
+ });
135
+ observableFromEvent(element, 'change')
136
+ .pipe(takeUntil(this.ngUnsubscribe))
137
+ .subscribe(() => {
138
+ /** Sanity check */
139
+ /* istanbul ignore else */
140
+ if (!this.disabled) {
141
+ this.isFirstChange = false;
142
+ }
143
+ });
144
+ }
145
+ ngOnDestroy() {
146
+ this._blur.complete();
147
+ this._textChanges.complete();
148
+ this.ngUnsubscribe.next();
149
+ this.ngUnsubscribe.complete();
150
+ this._blur = this._textChanges = this.ngUnsubscribe = undefined;
151
+ }
152
+ writeValue(value) {
153
+ this.value = value;
154
+ }
155
+ registerOnChange(fn) {
156
+ this.onChange = fn;
157
+ }
158
+ registerOnTouched(fn) {
159
+ this.onTouched = fn;
160
+ }
161
+ registerOnValidatorChange(fn) {
162
+ this.onValidatorChange = fn;
163
+ }
164
+ restoreInputTextValueToPreviousState() {
165
+ const modelValue = this.getValueByKey();
166
+ // If the search field contains text, make sure that the value
167
+ // matches the selected descriptor key.
168
+ if (this.inputTextValue !== modelValue) {
169
+ this.inputTextValue = modelValue;
170
+ }
171
+ this.onTouched();
172
+ }
173
+ setDisabledState(disabled) {
174
+ this.disabled = disabled;
175
+ }
176
+ validate(control) {
177
+ if (!this.control) {
178
+ this.control = control;
179
+ }
180
+ return;
181
+ }
182
+ // See: https://www.w3.org/TR/wai-aria-practices/#kbd_focus_activedescendant
183
+ setActiveDescendant(descendantId) {
184
+ if (descendantId) {
185
+ this.renderer.setAttribute(this.elementRef.nativeElement, 'aria-activedescendant', descendantId);
186
+ }
187
+ else {
188
+ this.renderer.removeAttribute(this.elementRef.nativeElement, 'aria-activedescendant');
189
+ }
190
+ }
191
+ // Angular automatically constructs these methods.
192
+ /* istanbul ignore next */
193
+ onChange(value) { }
194
+ /* istanbul ignore next */
195
+ onTouched() { }
196
+ setAttributes(element) {
197
+ this.renderer.setAttribute(element, 'autocomplete', this.autocompleteAttribute);
198
+ this.renderer.setAttribute(element, 'autocapitalize', 'none');
199
+ this.renderer.setAttribute(element, 'autocorrect', 'off');
200
+ this.renderer.setAttribute(element, 'spellcheck', 'false');
201
+ this.renderer.addClass(element, 'sky-form-control');
202
+ }
203
+ getValueByKey() {
204
+ return this.value ? this.value[this.displayWith] : undefined;
205
+ }
206
+ }
207
+ SkyAutocompleteInputDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: SkyAutocompleteInputDirective, deps: [{ token: i0.ElementRef }, { token: i0.Renderer2 }], target: i0.ɵɵFactoryTarget.Directive });
208
+ SkyAutocompleteInputDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "12.2.16", type: SkyAutocompleteInputDirective, selector: "input[skyAutocomplete], textarea[skyAutocomplete]", inputs: { autocompleteAttribute: "autocompleteAttribute", disabled: "disabled" }, providers: [SKY_AUTOCOMPLETE_VALUE_ACCESSOR, SKY_AUTOCOMPLETE_VALIDATOR], ngImport: i0 });
209
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: SkyAutocompleteInputDirective, decorators: [{
210
+ type: Directive,
211
+ args: [{
212
+ selector: 'input[skyAutocomplete], textarea[skyAutocomplete]',
213
+ providers: [SKY_AUTOCOMPLETE_VALUE_ACCESSOR, SKY_AUTOCOMPLETE_VALIDATOR],
214
+ }]
215
+ }], ctorParameters: function () { return [{ type: i0.ElementRef }, { type: i0.Renderer2 }]; }, propDecorators: { autocompleteAttribute: [{
216
+ type: Input
217
+ }], disabled: [{
218
+ type: Input
219
+ }] } });
220
+ //# sourceMappingURL=autocomplete-input.directive.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"autocomplete-input.directive.js","sourceRoot":"","sources":["../../../../../../../../libs/components/lookup/src/lib/modules/autocomplete/autocomplete-input.directive.ts"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AAM,CAAC,CAAC;QAC9D,IAAI,CAAC,QAAQ,CAAC,YAAY,CAAC,OAAO,EAAE,aAAa,EAAE,KAAK,CAAC,CAAC;QAC1D,IAAI,CAAC,QAAQ,CAAC,YAAY,CAAC,OAAO,EAAE,YAAY,EAAE,OAAO,CAAC,CAAC;QAC3D,IAAI,CAAC,QAAQ,CAAC,QAAQ,CAAC,OAAO,EAAE,kBAAkB,CAAC,CAAC;IACtD,CAAC;IAEO,aAAa;QACnB,OAAO,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,WAAW,CAAC,CAAC,CAAC,CAAC,SAAS,CAAC;IAC/D,CAAC;;2HA/PU,6BAA6B;+GAA7B,6BAA6B,8JAF7B,CAAC,+BAA+B,EAAE,0BAA0B,CAAC;4FAE7D,6BAA6B;kBAJzC,SAAS;mBAAC;oBACT,QAAQ,EAAE,mDAAmD;oBAC7D,SAAS,EAAE,CAAC,+BAA+B,EAAE,0BAA0B,CAAC;iBACzE;yHASY,qBAAqB;sBAD/B,KAAK;gBAwBK,QAAQ;sBADlB,KAAK","sourcesContent":["import {\n Directive,\n ElementRef,\n forwardRef,\n Input,\n OnDestroy,\n OnInit,\n Renderer2,\n} from '@angular/core';\n\nimport {\n AbstractControl,\n ControlValueAccessor,\n NG_VALIDATORS,\n NG_VALUE_ACCESSOR,\n ValidationErrors,\n Validator,\n} from '@angular/forms';\n\nimport { fromEvent as observableFromEvent, Observable, Subject } from 'rxjs';\n\nimport { takeUntil } from 'rxjs/operators';\n\nimport { SkyAutocompleteInputTextChange } from './types/autocomplete-input-text-change';\n\n// tslint:disable:no-forward-ref no-use-before-declare\nconst SKY_AUTOCOMPLETE_VALUE_ACCESSOR = {\n provide: NG_VALUE_ACCESSOR,\n useExisting: forwardRef(() => SkyAutocompleteInputDirective),\n multi: true,\n};\n\nconst SKY_AUTOCOMPLETE_VALIDATOR = {\n provide: NG_VALIDATORS,\n useExisting: forwardRef(() => SkyAutocompleteInputDirective),\n multi: true,\n};\n// tslint:enable\n\n@Directive({\n selector: 'input[skyAutocomplete], textarea[skyAutocomplete]',\n providers: [SKY_AUTOCOMPLETE_VALUE_ACCESSOR, SKY_AUTOCOMPLETE_VALIDATOR],\n})\nexport class SkyAutocompleteInputDirective\n implements OnInit, OnDestroy, ControlValueAccessor, Validator\n{\n /**\n * Specifies the value for the `autocomplete` attribute on the form input.\n * @default \"off\"\n */\n @Input()\n public set autocompleteAttribute(value: string) {\n if (!value) {\n this._autocompleteAttribute = 'off';\n } else {\n this._autocompleteAttribute = value;\n }\n\n this.renderer.setAttribute(\n this.elementRef.nativeElement,\n 'autocomplete',\n this.autocompleteAttribute\n );\n }\n\n public get autocompleteAttribute(): string {\n return this._autocompleteAttribute || 'off';\n }\n\n /**\n * Indicates whether to disable the autocomplete field.\n * @default false\n */\n @Input()\n public set disabled(value: boolean) {\n this._disabled = value;\n this.renderer.setProperty(this.elementRef.nativeElement, 'disabled', value);\n }\n\n public get disabled(): boolean {\n return this._disabled;\n }\n\n public get blur(): Observable<void> {\n return this._blur.asObservable();\n }\n\n public get displayWith(): string {\n return this._displayWith;\n }\n\n public set displayWith(value: string) {\n this._displayWith = value;\n this.inputTextValue = this.getValueByKey();\n }\n\n /**\n * @internal\n */\n public get inputElement(): any {\n return this.elementRef.nativeElement;\n }\n\n public get focus(): Observable<void> {\n return this._focus.asObservable();\n }\n\n public get inputTextValue(): string {\n return this.elementRef.nativeElement.value;\n }\n\n public set inputTextValue(value: string) {\n this.elementRef.nativeElement.value = value || '';\n }\n\n public get textChanges(): Observable<SkyAutocompleteInputTextChange> {\n return this._textChanges.asObservable();\n }\n\n public get value(): any {\n return this._value;\n }\n\n public set value(value: any) {\n const isNewValue = value !== this._value;\n\n /* istanbul ignore else */\n if (isNewValue) {\n this._value = value;\n this.inputTextValue = this.getValueByKey();\n this.onChange(this._value);\n\n // Do not mark the field as \"dirty\"\n // if the field has been initialized with a value.\n if (this.isFirstChange && this.control) {\n this.control.markAsPristine();\n }\n\n if (this.isFirstChange && this._value) {\n this.isFirstChange = false;\n }\n }\n }\n\n private control: AbstractControl;\n\n private isFirstChange: boolean = true;\n\n private ngUnsubscribe = new Subject<void>();\n\n private _autocompleteAttribute: string;\n\n private _blur = new Subject<void>();\n\n private _disabled = false;\n\n private _displayWith: string;\n\n private _focus = new Subject<void>();\n\n private _textChanges = new Subject<SkyAutocompleteInputTextChange>();\n\n private _value: any;\n\n constructor(private elementRef: ElementRef, private renderer: Renderer2) {}\n\n public ngOnInit() {\n const element = this.elementRef.nativeElement;\n\n this.setAttributes(element);\n\n observableFromEvent(element, 'input')\n .pipe(takeUntil(this.ngUnsubscribe))\n .subscribe(() => {\n /** Sanity check */\n if (!this.disabled) {\n this._textChanges.next({\n value: this.elementRef.nativeElement.value,\n });\n }\n });\n\n observableFromEvent(element, 'blur')\n .pipe(takeUntil(this.ngUnsubscribe))\n .subscribe(() => {\n /** Sanity check */\n if (!this.disabled) {\n this._blur.next();\n }\n });\n\n observableFromEvent(element, 'focus')\n .pipe(takeUntil(this.ngUnsubscribe))\n .subscribe(() => {\n /** Sanity check */\n if (!this.disabled) {\n this._focus.next();\n }\n });\n\n observableFromEvent(element, 'change')\n .pipe(takeUntil(this.ngUnsubscribe))\n .subscribe(() => {\n /** Sanity check */\n /* istanbul ignore else */\n if (!this.disabled) {\n this.isFirstChange = false;\n }\n });\n }\n\n public ngOnDestroy(): void {\n this._blur.complete();\n this._textChanges.complete();\n\n this.ngUnsubscribe.next();\n this.ngUnsubscribe.complete();\n\n this._blur = this._textChanges = this.ngUnsubscribe = undefined;\n }\n\n public writeValue(value: any): void {\n this.value = value;\n }\n\n public registerOnChange(fn: (value: any) => void): void {\n this.onChange = fn;\n }\n\n public registerOnTouched(fn: () => void): void {\n this.onTouched = fn;\n }\n\n public registerOnValidatorChange(fn: () => void): void {\n this.onValidatorChange = fn;\n }\n\n public restoreInputTextValueToPreviousState(): void {\n const modelValue = this.getValueByKey();\n\n // If the search field contains text, make sure that the value\n // matches the selected descriptor key.\n if (this.inputTextValue !== modelValue) {\n this.inputTextValue = modelValue;\n }\n\n this.onTouched();\n }\n\n public setDisabledState(disabled: boolean): void {\n this.disabled = disabled;\n }\n\n public validate(control: AbstractControl): ValidationErrors {\n if (!this.control) {\n this.control = control;\n }\n return;\n }\n\n // See: https://www.w3.org/TR/wai-aria-practices/#kbd_focus_activedescendant\n public setActiveDescendant(descendantId: string | null): void {\n if (descendantId) {\n this.renderer.setAttribute(\n this.elementRef.nativeElement,\n 'aria-activedescendant',\n descendantId\n );\n } else {\n this.renderer.removeAttribute(\n this.elementRef.nativeElement,\n 'aria-activedescendant'\n );\n }\n }\n\n // Angular automatically constructs these methods.\n /* istanbul ignore next */\n public onChange(value: any): void {}\n /* istanbul ignore next */\n public onTouched(): void {}\n /* istanbul ignore next */\n public onValidatorChange = () => {};\n\n private setAttributes(element: any): void {\n this.renderer.setAttribute(\n element,\n 'autocomplete',\n this.autocompleteAttribute\n );\n this.renderer.setAttribute(element, 'autocapitalize', 'none');\n this.renderer.setAttribute(element, 'autocorrect', 'off');\n this.renderer.setAttribute(element, 'spellcheck', 'false');\n this.renderer.addClass(element, 'sky-form-control');\n }\n\n private getValueByKey(): string {\n return this.value ? this.value[this.displayWith] : undefined;\n }\n}\n"]}
@@ -0,0 +1,19 @@
1
+ import { Pipe } from '@angular/core';
2
+ import * as i0 from "@angular/core";
3
+ /**
4
+ * @internal
5
+ */
6
+ export class SkyAutcompleteSearchAsyncDisabledPipe {
7
+ transform(searchAsync, searchAsyncDisabled) {
8
+ return searchAsyncDisabled || searchAsync.observers.length === 0;
9
+ }
10
+ }
11
+ SkyAutcompleteSearchAsyncDisabledPipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: SkyAutcompleteSearchAsyncDisabledPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe });
12
+ SkyAutcompleteSearchAsyncDisabledPipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: SkyAutcompleteSearchAsyncDisabledPipe, name: "skyAutocompleteSearchAsyncDisabled" });
13
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: SkyAutcompleteSearchAsyncDisabledPipe, decorators: [{
14
+ type: Pipe,
15
+ args: [{
16
+ name: 'skyAutocompleteSearchAsyncDisabled',
17
+ }]
18
+ }] });
19
+ //# sourceMappingURL=autocomplete-search-async-disabled.pipe.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"autocomplete-search-async-disabled.pipe.js","sourceRoot":"","sources":["../../../../../../../../libs/components/lookup/src/lib/modules/autocomplete/autocomplete-search-async-disabled.pipe.ts"],"names":[],"mappings":"AAAA,OAAO,EAAgB,IAAI,EAAiB,MAAM,eAAe,CAAC;;AAGlE;;GAEG;AAIH,MAAM,OAAO,qCAAqC;IACzC,SAAS,CACd,WAAyD,EACzD,mBAA4B;QAE5B,OAAO,mBAAmB,IAAI,WAAW,CAAC,SAAS,CAAC,MAAM,KAAK,CAAC,CAAC;IACnE,CAAC;;mIANU,qCAAqC;iIAArC,qCAAqC;4FAArC,qCAAqC;kBAHjD,IAAI;mBAAC;oBACJ,IAAI,EAAE,oCAAoC;iBAC3C","sourcesContent":["import { EventEmitter, Pipe, PipeTransform } from '@angular/core';\nimport { SkyAutocompleteSearchAsyncArgs } from './types/autocomplete-search-async-args';\n\n/**\n * @internal\n */\n@Pipe({\n name: 'skyAutocompleteSearchAsyncDisabled',\n})\nexport class SkyAutcompleteSearchAsyncDisabledPipe implements PipeTransform {\n public transform(\n searchAsync: EventEmitter<SkyAutocompleteSearchAsyncArgs>,\n searchAsyncDisabled: boolean\n ): boolean {\n return searchAsyncDisabled || searchAsync.observers.length === 0;\n }\n}\n"]}