@skyux/popovers 5.0.0 → 5.0.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 (36) hide show
  1. package/bundles/skyux-popovers-testing.umd.js +20 -32
  2. package/bundles/skyux-popovers-testing.umd.js.map +1 -1
  3. package/bundles/skyux-popovers.umd.js +137 -152
  4. package/bundles/skyux-popovers.umd.js.map +1 -1
  5. package/documentation.json +114 -109
  6. package/esm2015/modules/dropdown/dropdown-button.component.js +5 -5
  7. package/esm2015/modules/dropdown/dropdown-extensions.js +1 -1
  8. package/esm2015/modules/dropdown/dropdown-item.component.js +8 -8
  9. package/esm2015/modules/dropdown/dropdown-menu.component.js +14 -14
  10. package/esm2015/modules/dropdown/dropdown.component.js +14 -16
  11. package/esm2015/modules/dropdown/dropdown.module.js +10 -10
  12. package/esm2015/modules/dropdown/types/dropdown-horizontal-alignment.js +1 -1
  13. package/esm2015/modules/dropdown/types/dropdown-menu-change.js +1 -1
  14. package/esm2015/modules/dropdown/types/dropdown-message-type.js +1 -1
  15. package/esm2015/modules/dropdown/types/dropdown-message.js +1 -1
  16. package/esm2015/modules/popover/popover-adapter.service.js +6 -6
  17. package/esm2015/modules/popover/popover-animation.js +8 -14
  18. package/esm2015/modules/popover/popover-content.component.js +25 -30
  19. package/esm2015/modules/popover/popover-context.js +1 -1
  20. package/esm2015/modules/popover/popover-extensions.js +1 -1
  21. package/esm2015/modules/popover/popover.component.js +18 -22
  22. package/esm2015/modules/popover/popover.directive.js +6 -6
  23. package/esm2015/modules/popover/popover.module.js +10 -12
  24. package/esm2015/modules/popover/types/popover-adapter-elements.js +1 -1
  25. package/esm2015/modules/popover/types/popover-message-type.js +1 -1
  26. package/esm2015/modules/popover/types/popover-message.js +1 -1
  27. package/esm2015/modules/shared/sky-popovers-resources.module.js +18 -12
  28. package/esm2015/testing/dropdown/dropdown-fixture.js +4 -4
  29. package/esm2015/testing/dropdown/dropdown-testing.module.js +6 -8
  30. package/esm2015/testing/popover/popover-fixture.js +4 -8
  31. package/esm2015/testing/popover/popover-testing.module.js +7 -11
  32. package/fesm2015/skyux-popovers-testing.js +17 -27
  33. package/fesm2015/skyux-popovers-testing.js.map +1 -1
  34. package/fesm2015/skyux-popovers.js +120 -133
  35. package/fesm2015/skyux-popovers.js.map +1 -1
  36. package/package.json +8 -8
@@ -5,29 +5,25 @@ import { SkyThemeModule } from '@skyux/theme';
5
5
  import * as i0 from "@angular/core";
6
6
  export class SkyPopoverTestingModule {
7
7
  }
8
- SkyPopoverTestingModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.7", ngImport: i0, type: SkyPopoverTestingModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
9
- SkyPopoverTestingModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "12.2.7", ngImport: i0, type: SkyPopoverTestingModule, imports: [SkyThemeModule], exports: [SkyPopoverModule,
8
+ SkyPopoverTestingModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.13", ngImport: i0, type: SkyPopoverTestingModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
9
+ SkyPopoverTestingModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "12.2.13", ngImport: i0, type: SkyPopoverTestingModule, imports: [SkyThemeModule], exports: [SkyPopoverModule,
10
10
  // The noop animations module needs to be loaded last to avoid
11
11
  // subsequent modules adding animations and overriding this.
12
12
  NoopAnimationsModule] });
13
- SkyPopoverTestingModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "12.2.7", ngImport: i0, type: SkyPopoverTestingModule, imports: [[
14
- SkyThemeModule
15
- ], SkyPopoverModule,
13
+ SkyPopoverTestingModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "12.2.13", ngImport: i0, type: SkyPopoverTestingModule, imports: [[SkyThemeModule], SkyPopoverModule,
16
14
  // The noop animations module needs to be loaded last to avoid
17
15
  // subsequent modules adding animations and overriding this.
18
16
  NoopAnimationsModule] });
19
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.7", ngImport: i0, type: SkyPopoverTestingModule, decorators: [{
17
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.13", ngImport: i0, type: SkyPopoverTestingModule, decorators: [{
20
18
  type: NgModule,
21
19
  args: [{
22
20
  exports: [
23
21
  SkyPopoverModule,
24
22
  // The noop animations module needs to be loaded last to avoid
25
23
  // subsequent modules adding animations and overriding this.
26
- NoopAnimationsModule
24
+ NoopAnimationsModule,
27
25
  ],
28
- imports: [
29
- SkyThemeModule
30
- ]
26
+ imports: [SkyThemeModule],
31
27
  }]
32
28
  }] });
33
- //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicG9wb3Zlci10ZXN0aW5nLm1vZHVsZS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uLy4uL3Byb2plY3RzL3BvcG92ZXJzL3Rlc3Rpbmcvc3JjL3BvcG92ZXIvcG9wb3Zlci10ZXN0aW5nLm1vZHVsZS50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQSxPQUFPLEVBQ0wsUUFBUSxFQUNULE1BQU0sZUFBZSxDQUFDO0FBRXZCLE9BQU8sRUFDTCxvQkFBb0IsRUFDckIsTUFBTSxzQ0FBc0MsQ0FBQztBQUU5QyxPQUFPLEVBQ0wsZ0JBQWdCLEVBQ2pCLE1BQU0saUJBQWlCLENBQUM7QUFFekIsT0FBTyxFQUNMLGNBQWMsRUFDZixNQUFNLGNBQWMsQ0FBQzs7QUFjdEIsTUFBTSxPQUFPLHVCQUF1Qjs7b0hBQXZCLHVCQUF1QjtxSEFBdkIsdUJBQXVCLFlBSGhDLGNBQWMsYUFQZCxnQkFBZ0I7UUFFaEIsOERBQThEO1FBQz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HsgTmdNb2R1bGUgfSBmcm9tICdAYW5ndWxhci9jb3JlJztcblxuaW1wb3J0IHsgTm9vcEFuaW1hdGlvbnNNb2R1bGUgfSBmcm9tICdAYW5ndWxhci9wbGF0Zm9ybS1icm93c2VyL2FuaW1hdGlvbnMnO1xuXG5pbXBvcnQgeyBTa3lQb3BvdmVyTW9kdWxlIH0gZnJvbSAnQHNreXV4L3BvcG92ZXJzJztcblxuaW1wb3J0IHsgU2t5VGhlbWVNb2R1bGUgfSBmcm9tICdAc2t5dXgvdGhlbWUnO1xuXG5ATmdNb2R1bGUoe1xuICBleHBvcnRzOiBbXG4gICAgU2t5UG9wb3Zlck1vZHVsZSxcblxuICAgIC8vIFRoZSBub29wIGFuaW1hdGlvbnMgbW9kdWxlIG5lZWRzIHRvIGJlIGxvYWRlZCBsYXN0IHRvIGF2b2lkXG4gICAgLy8gc3Vic2VxdWVudCBtb2R1bGVzIGFkZGluZyBhbmltYXRpb25zIGFuZCBvdmVycmlkaW5nIHRoaXMuXG4gICAgTm9vcEFuaW1hdGlvbnNNb2R1bGUsXG4gIF0sXG4gIGltcG9ydHM6IFtTa3lUaGVtZU1vZHVsZV0sXG59KVxuZXhwb3J0IGNsYXNzIFNreVBvcG92ZXJUZXN0aW5nTW9kdWxlIHt9XG4iXX0=
@@ -9,15 +9,13 @@ import { SkyThemeModule } from '@skyux/theme';
9
9
 
10
10
  class SkyDropdownTestingModule {
11
11
  }
12
- SkyDropdownTestingModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.7", ngImport: i0, type: SkyDropdownTestingModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
13
- SkyDropdownTestingModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "12.2.7", ngImport: i0, type: SkyDropdownTestingModule, exports: [SkyDropdownModule] });
14
- SkyDropdownTestingModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "12.2.7", ngImport: i0, type: SkyDropdownTestingModule, imports: [SkyDropdownModule] });
15
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.7", ngImport: i0, type: SkyDropdownTestingModule, decorators: [{
12
+ SkyDropdownTestingModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.13", ngImport: i0, type: SkyDropdownTestingModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
13
+ SkyDropdownTestingModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "12.2.13", ngImport: i0, type: SkyDropdownTestingModule, exports: [SkyDropdownModule] });
14
+ SkyDropdownTestingModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "12.2.13", ngImport: i0, type: SkyDropdownTestingModule, imports: [SkyDropdownModule] });
15
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.13", ngImport: i0, type: SkyDropdownTestingModule, decorators: [{
16
16
  type: NgModule,
17
17
  args: [{
18
- exports: [
19
- SkyDropdownModule
20
- ]
18
+ exports: [SkyDropdownModule],
21
19
  }]
22
20
  }] });
23
21
 
@@ -44,7 +42,7 @@ class SkyDropdownFixture {
44
42
  buttonType: this.getButtonType(button.classes),
45
43
  disabled: button.nativeElement.disabled,
46
44
  label: button.nativeElement.getAttribute('aria-label'),
47
- title: button.nativeElement.getAttribute('title')
45
+ title: button.nativeElement.getAttribute('title'),
48
46
  };
49
47
  }
50
48
  /**
@@ -63,7 +61,7 @@ class SkyDropdownFixture {
63
61
  }
64
62
  return {
65
63
  ariaLabelledBy: menu.getAttribute('aria-labelledby'),
66
- ariaRole: menu.getAttribute('role')
64
+ ariaRole: menu.getAttribute('role'),
67
65
  };
68
66
  }
69
67
  /**
@@ -112,7 +110,7 @@ class SkyDropdownFixture {
112
110
  return;
113
111
  }
114
112
  return {
115
- ariaRole: item.getAttribute('role')
113
+ ariaRole: item.getAttribute('role'),
116
114
  };
117
115
  }
118
116
  /**
@@ -158,29 +156,25 @@ class SkyDropdownFixture {
158
156
 
159
157
  class SkyPopoverTestingModule {
160
158
  }
161
- SkyPopoverTestingModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.7", ngImport: i0, type: SkyPopoverTestingModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
162
- SkyPopoverTestingModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "12.2.7", ngImport: i0, type: SkyPopoverTestingModule, imports: [SkyThemeModule], exports: [SkyPopoverModule,
159
+ SkyPopoverTestingModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.13", ngImport: i0, type: SkyPopoverTestingModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
160
+ SkyPopoverTestingModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "12.2.13", ngImport: i0, type: SkyPopoverTestingModule, imports: [SkyThemeModule], exports: [SkyPopoverModule,
163
161
  // The noop animations module needs to be loaded last to avoid
164
162
  // subsequent modules adding animations and overriding this.
165
163
  NoopAnimationsModule] });
166
- SkyPopoverTestingModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "12.2.7", ngImport: i0, type: SkyPopoverTestingModule, imports: [[
167
- SkyThemeModule
168
- ], SkyPopoverModule,
164
+ SkyPopoverTestingModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "12.2.13", ngImport: i0, type: SkyPopoverTestingModule, imports: [[SkyThemeModule], SkyPopoverModule,
169
165
  // The noop animations module needs to be loaded last to avoid
170
166
  // subsequent modules adding animations and overriding this.
171
167
  NoopAnimationsModule] });
172
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.7", ngImport: i0, type: SkyPopoverTestingModule, decorators: [{
168
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.13", ngImport: i0, type: SkyPopoverTestingModule, decorators: [{
173
169
  type: NgModule,
174
170
  args: [{
175
171
  exports: [
176
172
  SkyPopoverModule,
177
173
  // The noop animations module needs to be loaded last to avoid
178
174
  // subsequent modules adding animations and overriding this.
179
- NoopAnimationsModule
175
+ NoopAnimationsModule,
180
176
  ],
181
- imports: [
182
- SkyThemeModule
183
- ]
177
+ imports: [SkyThemeModule],
184
178
  }]
185
179
  }] });
186
180
 
@@ -250,9 +244,7 @@ class SkyPopoverFixture {
250
244
  }
251
245
  queryOverlay(query) {
252
246
  const overlay = this.getOverlay();
253
- return !overlay
254
- ? undefined
255
- : overlay.querySelector(query);
247
+ return !overlay ? undefined : overlay.querySelector(query);
256
248
  }
257
249
  /**
258
250
  * Searches the element's class names for a class which matches a given prefix.
@@ -266,10 +258,8 @@ class SkyPopoverFixture {
266
258
  */
267
259
  getClassSuffixByClassPrefix(element, prefix) {
268
260
  let containerClasses = element === null || element === void 0 ? void 0 : element.className.split(' ');
269
- let prefixedClass = containerClasses === null || containerClasses === void 0 ? void 0 : containerClasses.find(x => x.startsWith(prefix));
270
- return !prefixedClass
271
- ? undefined
272
- : prefixedClass.slice(prefix.length);
261
+ let prefixedClass = containerClasses === null || containerClasses === void 0 ? void 0 : containerClasses.find((x) => x.startsWith(prefix));
262
+ return !prefixedClass ? undefined : prefixedClass.slice(prefix.length);
273
263
  }
274
264
  }
275
265
 
@@ -1 +1 @@
1
- {"version":3,"file":"skyux-popovers-testing.js","sources":["../../../projects/popovers/testing/src/dropdown/dropdown-testing.module.ts","../../../projects/popovers/testing/src/dropdown/dropdown-fixture.ts","../../../projects/popovers/testing/src/popover/popover-testing.module.ts","../../../projects/popovers/testing/src/popover/popover-fixture.ts","../../../projects/popovers/testing/src/skyux-popovers-testing.ts"],"sourcesContent":["import {\n NgModule\n} from '@angular/core';\n\nimport {\n SkyDropdownModule\n} from '@skyux/popovers';\n\n@NgModule({\n exports: [\n SkyDropdownModule\n ]\n})\nexport class SkyDropdownTestingModule { }\n","import {\n DebugElement\n} from '@angular/core';\n\nimport {\n ComponentFixture\n} from '@angular/core/testing';\n\nimport {\n By\n} from '@angular/platform-browser';\n\nimport {\n SkyAppTestUtility\n} from '@skyux-sdk/testing';\n\nimport {\n SkyPopoversFixtureDropdown\n} from './popovers-fixture-dropdown';\n\nimport {\n SkyPopoversFixtureDropdownItem\n} from './popovers-fixture-dropdown-item';\n\nimport {\n SkyPopoversFixtureDropdownMenu\n} from './popovers-fixture-dropdown-menu';\n\n/**\n * Provides information for and interaction with a SKY UX dropdown component.\n * By using the fixture API, a test insulates itself against updates to the internals\n * of a component, such as changing its DOM structure.\n */\nexport class SkyDropdownFixture {\n\n /**\n * Returns information about the dropdown component.\n */\n public get dropdown(): SkyPopoversFixtureDropdown {\n const button = this.buttonDebugElement;\n\n if (!button) {\n return;\n }\n\n return {\n buttonStyle: this.getButtonStyle(button.classes),\n buttonType: this.getButtonType(button.classes),\n disabled: button.nativeElement.disabled,\n label: button.nativeElement.getAttribute('aria-label'),\n title: button.nativeElement.getAttribute('title')\n };\n }\n\n /**\n * Returns the dropdown button's text.\n */\n public get dropdownButtonText(): string {\n return SkyAppTestUtility.getText(this.buttonDebugElement.nativeElement);\n }\n\n /**\n * Returns information about the dropdown menu component.\n */\n public get dropdownMenu(): SkyPopoversFixtureDropdownMenu {\n const menu = this.getDropdownMenuContent();\n if (!menu) {\n return;\n }\n\n return {\n ariaLabelledBy: menu.getAttribute('aria-labelledby'),\n ariaRole: menu.getAttribute('role')\n };\n }\n\n /**\n * Indicates if the dropdown menu is open and visible.\n */\n public get dropdownMenuIsVisible(): boolean {\n return this.getDropdownMenuContent() !== undefined;\n }\n\n private get buttonDebugElement(): DebugElement {\n return this.debugEl.query(\n By.css('.sky-dropdown-button')\n );\n }\n\n private debugEl: DebugElement;\n\n constructor(\n private fixture: ComponentFixture<any>,\n skyTestId: string\n ) {\n this.debugEl = SkyAppTestUtility.getDebugElementByTestId(fixture, skyTestId, 'sky-dropdown');\n }\n\n /**\n * Click the dropdown button to open or close the dropdown menu.\n */\n public async clickDropdownButton(): Promise<any> {\n this.buttonDebugElement.nativeElement.click();\n this.fixture.detectChanges();\n return this.fixture.whenStable();\n }\n\n /**\n * Click the dropdown item at the provided index.\n */\n public async clickDropdownItem(index: number): Promise<any> {\n const itemEls = this.getDropdownItemEls();\n if (index >= itemEls.length) {\n throw new Error(`There is no dropdown item at index ${index}.`);\n }\n\n itemEls[index].querySelector('button,a').click();\n\n this.fixture.detectChanges();\n return this.fixture.whenStable();\n }\n\n /**\n * Returns information about the dropdown item at the provided index.\n */\n public getDropdownItem(index: number): SkyPopoversFixtureDropdownItem {\n const itemEls = this.getDropdownItemEls();\n if (index >= itemEls.length) {\n throw new Error(`There is no dropdown item at index ${index}.`);\n }\n\n const item = itemEls[index];\n if (!item) {\n return;\n }\n\n return {\n ariaRole: item.getAttribute('role')\n };\n }\n\n /**\n * Returns the contents of the dropdown menu.\n */\n public getDropdownMenuContent(): any {\n const overlay = this.getOverlay();\n if (!overlay) {\n return;\n }\n\n return overlay.querySelector('.sky-dropdown-menu');\n }\n\n private getDropdownItemEls(): NodeListOf<any> {\n const overlay = this.getOverlay();\n\n if (!overlay) {\n return;\n }\n\n return overlay.querySelectorAll('.sky-dropdown-item');\n }\n\n private getOverlay(): HTMLElement {\n return document.querySelector('sky-overlay');\n }\n\n private getButtonStyle(classNames: { [key: string]: boolean }): string {\n if (classNames['sky-btn-primary']) {\n return 'primary';\n }\n if (classNames['sky-btn-default']) {\n return 'default';\n }\n }\n\n private getButtonType(classNames: { [key: string]: boolean }): string {\n const prefix = 'sky-dropdown-button-type-';\n\n for (let i in classNames) {\n if (classNames[i]) {\n if (i.indexOf(prefix) > -1) {\n return i.replace(prefix, '');\n }\n }\n }\n\n return undefined;\n }\n}\n","import {\n NgModule\n} from '@angular/core';\n\nimport {\n NoopAnimationsModule\n} from '@angular/platform-browser/animations';\n\nimport {\n SkyPopoverModule\n} from '@skyux/popovers';\n\nimport {\n SkyThemeModule\n} from '@skyux/theme';\n\n@NgModule({\n exports: [\n SkyPopoverModule,\n\n // The noop animations module needs to be loaded last to avoid\n // subsequent modules adding animations and overriding this.\n NoopAnimationsModule\n ],\n imports: [\n SkyThemeModule\n ]\n})\nexport class SkyPopoverTestingModule { }\n","import {\n ComponentFixture\n} from '@angular/core/testing';\n\nimport {\n SkyAppTestUtility\n} from '@skyux-sdk/testing';\n\n/**\n * Provides information for and interaction with a SKY UX popover component.\n * By using the fixture API, a test insulates itself against updates to the internals\n * of a component, such as changing its DOM structure.\n */\nexport class SkyPopoverFixture {\n\n /**\n * Returns the popover alignment if the popover is open, otherwise undefined.\n */\n public get alignment(): string {\n return this.getClassSuffixByClassPrefix(this.containerElement, 'sky-popover-alignment-');\n }\n\n /**\n * Returns the popover body element if the popover is open, otherwise undefined.\n */\n public get body(): HTMLElement {\n return this.bodyElement;\n }\n\n /**\n * Returns the popover position if the popover is open, otherwise undefined.\n */\n public get placement(): string {\n return this.getClassSuffixByClassPrefix(this.containerElement, 'sky-popover-placement-');\n }\n\n /**\n * Returns the popover title text if the popover is open, otherwise undefined.\n */\n public get popoverTitle(): string {\n return SkyAppTestUtility.getText(this.titleElement);\n }\n\n /**\n * Indicates if the popover is open and visible.\n */\n public get popoverIsVisible(): boolean {\n return this.contentElement !== undefined;\n }\n\n constructor(\n private fixture: ComponentFixture<any>\n ) { }\n\n /**\n * Triggers the blur event for the popover.\n */\n public blur(): Promise<any> {\n // close the popover by changing focus to the body element\n SkyAppTestUtility.fireDomEvent(window.document.body, 'click');\n\n this.fixture.detectChanges();\n return this.fixture.whenStable();\n }\n\n //#region helpers\n private get contentElement(): HTMLElement {\n return this.queryOverlay('sky-popover-content');\n }\n\n private get containerElement(): HTMLElement {\n return this.queryOverlay('.sky-popover-container');\n }\n\n private get titleElement(): HTMLElement {\n return this.queryOverlay('.sky-popover-title');\n }\n\n private get bodyElement(): HTMLElement {\n return this.queryOverlay('.sky-popover-body');\n }\n\n private getOverlay(): HTMLElement {\n return document.querySelector('sky-overlay');\n }\n\n private queryOverlay(query: string): HTMLElement {\n const overlay = this.getOverlay();\n\n return !overlay\n ? undefined\n : overlay.querySelector(query);\n }\n\n /**\n * Searches the element's class names for a class which matches a given prefix.\n * If a match is found, the prefix is trimmed from the class name and the suffix is returned.\n * If no class matching the prefix is found, undefined is returned.\n *\n * Example:\n * For a class 'sky-popover-placement-right', passing the prefix 'sky-popover-placement-'\n * should return the value 'right'.\n * @param prefix\n */\n private getClassSuffixByClassPrefix(element: HTMLElement, prefix: string): string {\n let containerClasses = element?.className.split(' ');\n let prefixedClass = containerClasses?.find(x => x.startsWith(prefix));\n\n return !prefixedClass\n ? undefined\n : prefixedClass.slice(prefix.length);\n }\n //#endregion\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;;;;MAaa,wBAAwB;;qHAAxB,wBAAwB;sHAAxB,wBAAwB,YAHjC,iBAAiB;sHAGR,wBAAwB,YAHjC,iBAAiB;2FAGR,wBAAwB;kBALpC,QAAQ;mBAAC;oBACR,OAAO,EAAE;wBACP,iBAAiB;qBAClB;iBACF;;;ACgBD;;;;;MAKa,kBAAkB;IA0D7B,YACU,OAA8B,EACtC,SAAiB;QADT,YAAO,GAAP,OAAO,CAAuB;QAGtC,IAAI,CAAC,OAAO,GAAG,iBAAiB,CAAC,uBAAuB,CAAC,OAAO,EAAE,SAAS,EAAE,cAAc,CAAC,CAAC;KAC9F;;;;IA1DD,IAAW,QAAQ;QACjB,MAAM,MAAM,GAAG,IAAI,CAAC,kBAAkB,CAAC;QAEvC,IAAI,CAAC,MAAM,EAAE;YACX,OAAO;SACR;QAED,OAAO;YACL,WAAW,EAAE,IAAI,CAAC,cAAc,CAAC,MAAM,CAAC,OAAO,CAAC;YAChD,UAAU,EAAE,IAAI,CAAC,aAAa,CAAC,MAAM,CAAC,OAAO,CAAC;YAC9C,QAAQ,EAAE,MAAM,CAAC,aAAa,CAAC,QAAQ;YACvC,KAAK,EAAE,MAAM,CAAC,aAAa,C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CAAC,UAAU,EAAE,CAAC;KAClC;;IAGD,IAAY,cAAc;QACxB,OAAO,IAAI,CAAC,YAAY,CAAC,qBAAqB,CAAC,CAAC;KACjD;IAED,IAAY,gBAAgB;QAC1B,OAAO,IAAI,CAAC,YAAY,CAAC,wBAAwB,CAAC,CAAC;KACpD;IAED,IAAY,YAAY;QACtB,OAAO,IAAI,CAAC,YAAY,CAAC,oBAAoB,CAAC,CAAC;KAChD;IAED,IAAY,WAAW;QACrB,OAAO,IAAI,CAAC,YAAY,CAAC,mBAAmB,CAAC,CAAC;KAC/C;IAEO,UAAU;QAChB,OAAO,QAAQ,CAAC,aAAa,CAAC,aAAa,CAAC,CAAC;KAC9C;IAEO,YAAY,CAAC,KAAa;QAChC,MAAM,OAAO,GAAG,IAAI,CAAC,UAAU,EAAE,CAAC;QAElC,OAAO,CAAC,OAAO;cACX,SAAS;cACT,OAAO,CAAC,aAAa,CAAC,KAAK,CAAC,CAAC;KAClC;;;;;;;;;;;IAYO,2BAA2B,CAAC,OAAoB,EAAE,MAAc;QACtE,IAAI,gBAAgB,GAAG,OAAO,aAAP,OAAO,uBAAP,OAAO,CAAE,SAAS,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC;QACrD,IAAI,aAAa,GAAG,gBAAgB,aAAhB,gBAAgB,uBAAhB,gBAAgB,CAAE,IAAI,CAAC,CAAC,IAAI,CAAC,CAAC,UAAU,CAAC,MAAM,CAAC,CAAC,CAAC;QAEtE,OAAO,CAAC,aAAa;cACjB,SAAS;cACT,aAAa,CAAC,KAAK,CAAC,MAAM,CAAC,MAAM,CAAC,CAAC;KACxC;;;AC/GH;;;;;;"}
1
+ {"version":3,"file":"skyux-popovers-testing.js","sources":["../../../projects/popovers/testing/src/dropdown/dropdown-testing.module.ts","../../../projects/popovers/testing/src/dropdown/dropdown-fixture.ts","../../../projects/popovers/testing/src/popover/popover-testing.module.ts","../../../projects/popovers/testing/src/popover/popover-fixture.ts","../../../projects/popovers/testing/src/skyux-popovers-testing.ts"],"sourcesContent":["import { NgModule } from '@angular/core';\n\nimport { SkyDropdownModule } from '@skyux/popovers';\n\n@NgModule({\n exports: [SkyDropdownModule],\n})\nexport class SkyDropdownTestingModule {}\n","import { DebugElement } from '@angular/core';\n\nimport { ComponentFixture } from '@angular/core/testing';\n\nimport { By } from '@angular/platform-browser';\n\nimport { SkyAppTestUtility } from '@skyux-sdk/testing';\n\nimport { SkyPopoversFixtureDropdown } from './popovers-fixture-dropdown';\n\nimport { SkyPopoversFixtureDropdownItem } from './popovers-fixture-dropdown-item';\n\nimport { SkyPopoversFixtureDropdownMenu } from './popovers-fixture-dropdown-menu';\n\n/**\n * Provides information for and interaction with a SKY UX dropdown component.\n * By using the fixture API, a test insulates itself against updates to the internals\n * of a component, such as changing its DOM structure.\n */\nexport class SkyDropdownFixture {\n /**\n * Returns information about the dropdown component.\n */\n public get dropdown(): SkyPopoversFixtureDropdown {\n const button = this.buttonDebugElement;\n\n if (!button) {\n return;\n }\n\n return {\n buttonStyle: this.getButtonStyle(button.classes),\n buttonType: this.getButtonType(button.classes),\n disabled: button.nativeElement.disabled,\n label: button.nativeElement.getAttribute('aria-label'),\n title: button.nativeElement.getAttribute('title'),\n };\n }\n\n /**\n * Returns the dropdown button's text.\n */\n public get dropdownButtonText(): string {\n return SkyAppTestUtility.getText(this.buttonDebugElement.nativeElement);\n }\n\n /**\n * Returns information about the dropdown menu component.\n */\n public get dropdownMenu(): SkyPopoversFixtureDropdownMenu {\n const menu = this.getDropdownMenuContent();\n if (!menu) {\n return;\n }\n\n return {\n ariaLabelledBy: menu.getAttribute('aria-labelledby'),\n ariaRole: menu.getAttribute('role'),\n };\n }\n\n /**\n * Indicates if the dropdown menu is open and visible.\n */\n public get dropdownMenuIsVisible(): boolean {\n return this.getDropdownMenuContent() !== undefined;\n }\n\n private get buttonDebugElement(): DebugElement {\n return this.debugEl.query(By.css('.sky-dropdown-button'));\n }\n\n private debugEl: DebugElement;\n\n constructor(private fixture: ComponentFixture<any>, skyTestId: string) {\n this.debugEl = SkyAppTestUtility.getDebugElementByTestId(\n fixture,\n skyTestId,\n 'sky-dropdown'\n );\n }\n\n /**\n * Click the dropdown button to open or close the dropdown menu.\n */\n public async clickDropdownButton(): Promise<any> {\n this.buttonDebugElement.nativeElement.click();\n this.fixture.detectChanges();\n return this.fixture.whenStable();\n }\n\n /**\n * Click the dropdown item at the provided index.\n */\n public async clickDropdownItem(index: number): Promise<any> {\n const itemEls = this.getDropdownItemEls();\n if (index >= itemEls.length) {\n throw new Error(`There is no dropdown item at index ${index}.`);\n }\n\n itemEls[index].querySelector('button,a').click();\n\n this.fixture.detectChanges();\n return this.fixture.whenStable();\n }\n\n /**\n * Returns information about the dropdown item at the provided index.\n */\n public getDropdownItem(index: number): SkyPopoversFixtureDropdownItem {\n const itemEls = this.getDropdownItemEls();\n if (index >= itemEls.length) {\n throw new Error(`There is no dropdown item at index ${index}.`);\n }\n\n const item = itemEls[index];\n if (!item) {\n return;\n }\n\n return {\n ariaRole: item.getAttribute('role'),\n };\n }\n\n /**\n * Returns the contents of the dropdown menu.\n */\n public getDropdownMenuContent(): any {\n const overlay = this.getOverlay();\n if (!overlay) {\n return;\n }\n\n return overlay.querySelector('.sky-dropdown-menu');\n }\n\n private getDropdownItemEls(): NodeListOf<any> {\n const overlay = this.getOverlay();\n\n if (!overlay) {\n return;\n }\n\n return overlay.querySelectorAll('.sky-dropdown-item');\n }\n\n private getOverlay(): HTMLElement {\n return document.querySelector('sky-overlay');\n }\n\n private getButtonStyle(classNames: { [key: string]: boolean }): string {\n if (classNames['sky-btn-primary']) {\n return 'primary';\n }\n if (classNames['sky-btn-default']) {\n return 'default';\n }\n }\n\n private getButtonType(classNames: { [key: string]: boolean }): string {\n const prefix = 'sky-dropdown-button-type-';\n\n for (let i in classNames) {\n if (classNames[i]) {\n if (i.indexOf(prefix) > -1) {\n return i.replace(prefix, '');\n }\n }\n }\n\n return undefined;\n }\n}\n","import { NgModule } from '@angular/core';\n\nimport { NoopAnimationsModule } from '@angular/platform-browser/animations';\n\nimport { SkyPopoverModule } from '@skyux/popovers';\n\nimport { SkyThemeModule } from '@skyux/theme';\n\n@NgModule({\n exports: [\n SkyPopoverModule,\n\n // The noop animations module needs to be loaded last to avoid\n // subsequent modules adding animations and overriding this.\n NoopAnimationsModule,\n ],\n imports: [SkyThemeModule],\n})\nexport class SkyPopoverTestingModule {}\n","import { ComponentFixture } from '@angular/core/testing';\n\nimport { SkyAppTestUtility } from '@skyux-sdk/testing';\n\n/**\n * Provides information for and interaction with a SKY UX popover component.\n * By using the fixture API, a test insulates itself against updates to the internals\n * of a component, such as changing its DOM structure.\n */\nexport class SkyPopoverFixture {\n /**\n * Returns the popover alignment if the popover is open, otherwise undefined.\n */\n public get alignment(): string {\n return this.getClassSuffixByClassPrefix(\n this.containerElement,\n 'sky-popover-alignment-'\n );\n }\n\n /**\n * Returns the popover body element if the popover is open, otherwise undefined.\n */\n public get body(): HTMLElement {\n return this.bodyElement;\n }\n\n /**\n * Returns the popover position if the popover is open, otherwise undefined.\n */\n public get placement(): string {\n return this.getClassSuffixByClassPrefix(\n this.containerElement,\n 'sky-popover-placement-'\n );\n }\n\n /**\n * Returns the popover title text if the popover is open, otherwise undefined.\n */\n public get popoverTitle(): string {\n return SkyAppTestUtility.getText(this.titleElement);\n }\n\n /**\n * Indicates if the popover is open and visible.\n */\n public get popoverIsVisible(): boolean {\n return this.contentElement !== undefined;\n }\n\n constructor(private fixture: ComponentFixture<any>) {}\n\n /**\n * Triggers the blur event for the popover.\n */\n public blur(): Promise<any> {\n // close the popover by changing focus to the body element\n SkyAppTestUtility.fireDomEvent(window.document.body, 'click');\n\n this.fixture.detectChanges();\n return this.fixture.whenStable();\n }\n\n //#region helpers\n private get contentElement(): HTMLElement {\n return this.queryOverlay('sky-popover-content');\n }\n\n private get containerElement(): HTMLElement {\n return this.queryOverlay('.sky-popover-container');\n }\n\n private get titleElement(): HTMLElement {\n return this.queryOverlay('.sky-popover-title');\n }\n\n private get bodyElement(): HTMLElement {\n return this.queryOverlay('.sky-popover-body');\n }\n\n private getOverlay(): HTMLElement {\n return document.querySelector('sky-overlay');\n }\n\n private queryOverlay(query: string): HTMLElement {\n const overlay = this.getOverlay();\n\n return !overlay ? undefined : overlay.querySelector(query);\n }\n\n /**\n * Searches the element's class names for a class which matches a given prefix.\n * If a match is found, the prefix is trimmed from the class name and the suffix is returned.\n * If no class matching the prefix is found, undefined is returned.\n *\n * Example:\n * For a class 'sky-popover-placement-right', passing the prefix 'sky-popover-placement-'\n * should return the value 'right'.\n * @param prefix\n */\n private getClassSuffixByClassPrefix(\n element: HTMLElement,\n prefix: string\n ): string {\n let containerClasses = element?.className.split(' ');\n let prefixedClass = containerClasses?.find((x) => x.startsWith(prefix));\n\n return !prefixedClass ? undefined : prefixedClass.slice(prefix.length);\n }\n //#endregion\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;;;;MAOa,wBAAwB;;sHAAxB,wBAAwB;uHAAxB,wBAAwB,YAFzB,iBAAiB;uHAEhB,wBAAwB,YAFzB,iBAAiB;4FAEhB,wBAAwB;kBAHpC,QAAQ;mBAAC;oBACR,OAAO,EAAE,CAAC,iBAAiB,CAAC;iBAC7B;;;ACQD;;;;;MAKa,kBAAkB;IAuD7B,YAAoB,OAA8B,EAAE,SAAiB;QAAjD,YAAO,GAAP,OAAO,CAAuB;QAChD,IAAI,CAAC,OAAO,GAAG,iBAAiB,CAAC,uBAAuB,CACtD,OAAO,EACP,SAAS,EACT,cAAc,CACf,CAAC;KACH;;;;IAzDD,IAAW,QAAQ;QACjB,MAAM,MAAM,GAAG,IAAI,CAAC,kBAAkB,CAAC;QAEvC,IAAI,CAAC,MAAM,EAAE;YACX,OAAO;SACR;QAED,OAAO;YACL,WAAW,EAAE,IAAI,CAAC,cAAc,CAAC,MAAM,CAAC,OAAO,CAAC;YAChD,UAAU,EAAE,IAAI,CAAC,aAAa,CAAC,MAAM,CAAC,OAAO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