@skyux/icon 10.31.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 (35) hide show
  1. package/README.md +3 -0
  2. package/documentation.json +467 -0
  3. package/esm2022/index.mjs +4 -0
  4. package/esm2022/lib/icon/icon-class-list.pipe.mjs +35 -0
  5. package/esm2022/lib/icon/icon-resolver.service.mjs +79 -0
  6. package/esm2022/lib/icon/icon-stack-item.mjs +2 -0
  7. package/esm2022/lib/icon/icon-stack.component.mjs +26 -0
  8. package/esm2022/lib/icon/icon.component.mjs +27 -0
  9. package/esm2022/lib/icon/icon.module.mjs +20 -0
  10. package/esm2022/lib/icon/types/icon-resolved.mjs +2 -0
  11. package/esm2022/lib/icon/types/icon-type.mjs +2 -0
  12. package/esm2022/lib/icon/types/icon-variant-type.mjs +2 -0
  13. package/esm2022/skyux-icon.mjs +5 -0
  14. package/esm2022/testing/icon/icon-harness-filters.mjs +2 -0
  15. package/esm2022/testing/icon/icon-harness.mjs +87 -0
  16. package/esm2022/testing/index.mjs +2 -0
  17. package/esm2022/testing/skyux-icon-testing.mjs +5 -0
  18. package/fesm2022/skyux-icon-testing.mjs +94 -0
  19. package/fesm2022/skyux-icon-testing.mjs.map +1 -0
  20. package/fesm2022/skyux-icon.mjs +177 -0
  21. package/fesm2022/skyux-icon.mjs.map +1 -0
  22. package/index.d.ts +6 -0
  23. package/lib/icon/icon-class-list.pipe.d.ts +13 -0
  24. package/lib/icon/icon-resolver.service.d.ts +14 -0
  25. package/lib/icon/icon-stack-item.d.ts +20 -0
  26. package/lib/icon/icon-stack.component.d.ts +24 -0
  27. package/lib/icon/icon.component.d.ts +41 -0
  28. package/lib/icon/icon.module.d.ts +10 -0
  29. package/lib/icon/types/icon-resolved.d.ts +7 -0
  30. package/lib/icon/types/icon-type.d.ts +4 -0
  31. package/lib/icon/types/icon-variant-type.d.ts +1 -0
  32. package/package.json +51 -0
  33. package/testing/icon/icon-harness-filters.d.ts +6 -0
  34. package/testing/icon/icon-harness.d.ts +39 -0
  35. package/testing/index.d.ts +2 -0
@@ -0,0 +1,41 @@
1
+ import { SkyThemeService } from '@skyux/theme';
2
+ import { SkyIconType } from './types/icon-type';
3
+ import { SkyIconVariantType } from './types/icon-variant-type';
4
+ import * as i0 from "@angular/core";
5
+ export declare class SkyIconComponent {
6
+ /**
7
+ * The name of
8
+ * [the Font Awesome 4.7 icon](https://fontawesome.com/v4.7/icons/) or the SKY UX icon to
9
+ * display. When specifying a Font Awesome icon, do not prefix the name with `fa-`.
10
+ * @required
11
+ */
12
+ icon: string | undefined;
13
+ /**
14
+ * The type of icon to display. Specifying `"fa"` displays a Font Awesome icon,
15
+ * while specifying `"skyux"` displays an icon from the custom SKY UX icon font. Note that
16
+ * the custom SKY UX icon font is currently in beta.
17
+ * @default "fa"
18
+ * @deprecated The icon component now automatically infers which type of icon to use based on the current theme. This input will be removed in a future version.
19
+ */
20
+ iconType: SkyIconType | undefined;
21
+ /**
22
+ * The size of the icon using
23
+ * [Font Awesome sizes](https://fontawesome.com/v4/examples/). Do not prefix the size with `fa-`.
24
+ */
25
+ size: string | undefined;
26
+ /**
27
+ * Whether to enforce a fixed width based on icon size. By default, icons of a specified size share a
28
+ * consistent height, but their widths vary and can throw off vertical alignment. Use a fixed width when
29
+ * you stack icons vertically, such as in lists.
30
+ * @default false
31
+ */
32
+ fixedWidth: boolean | undefined;
33
+ /**
34
+ * The icon variant. If the variant doesn't exist for the
35
+ * specified icon, the normal icon is displayed. This property only applies when using SKY UX icons.
36
+ */
37
+ variant: SkyIconVariantType | undefined;
38
+ protected themeSvc: SkyThemeService | null;
39
+ static ɵfac: i0.ɵɵFactoryDeclaration<SkyIconComponent, never>;
40
+ static ɵcmp: i0.ɵɵComponentDeclaration<SkyIconComponent, "sky-icon", never, { "icon": { "alias": "icon"; "required": false; }; "iconType": { "alias": "iconType"; "required": false; }; "size": { "alias": "size"; "required": false; }; "fixedWidth": { "alias": "fixedWidth"; "required": false; }; "variant": { "alias": "variant"; "required": false; }; }, {}, never, never, false, never>;
41
+ }
@@ -0,0 +1,10 @@
1
+ import * as i0 from "@angular/core";
2
+ import * as i1 from "./icon-class-list.pipe";
3
+ import * as i2 from "./icon.component";
4
+ import * as i3 from "./icon-stack.component";
5
+ import * as i4 from "@angular/common";
6
+ export declare class SkyIconModule {
7
+ static ɵfac: i0.ɵɵFactoryDeclaration<SkyIconModule, never>;
8
+ static ɵmod: i0.ɵɵNgModuleDeclaration<SkyIconModule, [typeof i1.SkyIconClassListPipe, typeof i2.SkyIconComponent, typeof i3.SkyIconStackComponent], [typeof i4.CommonModule], [typeof i2.SkyIconComponent, typeof i3.SkyIconStackComponent]>;
9
+ static ɵinj: i0.ɵɵInjectorDeclaration<SkyIconModule>;
10
+ }
@@ -0,0 +1,7 @@
1
+ /**
2
+ * @internal
3
+ */
4
+ export interface SkyIconResolved {
5
+ icon: string;
6
+ iconType: string;
7
+ }
@@ -0,0 +1,4 @@
1
+ /**
2
+ * @deprecated
3
+ */
4
+ export type SkyIconType = 'fa' | 'skyux';
@@ -0,0 +1 @@
1
+ export type SkyIconVariantType = 'line' | 'solid';
package/package.json ADDED
@@ -0,0 +1,51 @@
1
+ {
2
+ "name": "@skyux/icon",
3
+ "version": "10.31.0",
4
+ "author": "Blackbaud, Inc.",
5
+ "keywords": [
6
+ "blackbaud",
7
+ "skyux"
8
+ ],
9
+ "license": "MIT",
10
+ "repository": {
11
+ "type": "git",
12
+ "url": "git+https://github.com/blackbaud/skyux.git"
13
+ },
14
+ "bugs": {
15
+ "url": "https://github.com/blackbaud/skyux/issues"
16
+ },
17
+ "homepage": "https://github.com/blackbaud/skyux#readme",
18
+ "exports": {
19
+ "./package.json": {
20
+ "default": "./package.json"
21
+ },
22
+ ".": {
23
+ "types": "./index.d.ts",
24
+ "esm2022": "./esm2022/skyux-icon.mjs",
25
+ "esm": "./esm2022/skyux-icon.mjs",
26
+ "default": "./fesm2022/skyux-icon.mjs"
27
+ },
28
+ "./testing": {
29
+ "types": "./testing/index.d.ts",
30
+ "esm2022": "./esm2022/testing/skyux-icon-testing.mjs",
31
+ "esm": "./esm2022/testing/skyux-icon-testing.mjs",
32
+ "default": "./fesm2022/skyux-icon-testing.mjs"
33
+ },
34
+ "./documentation.json": {
35
+ "default": "./documentation.json"
36
+ }
37
+ },
38
+ "peerDependencies": {
39
+ "@angular/cdk": "^17.3.4",
40
+ "@angular/common": "^17.3.4",
41
+ "@angular/core": "^17.3.4",
42
+ "@skyux/core": "10.31.0",
43
+ "@skyux/theme": "10.31.0"
44
+ },
45
+ "dependencies": {
46
+ "tslib": "^2.6.2"
47
+ },
48
+ "sideEffects": false,
49
+ "module": "fesm2022/skyux-icon.mjs",
50
+ "typings": "index.d.ts"
51
+ }
@@ -0,0 +1,6 @@
1
+ import { SkyHarnessFilters } from '@skyux/core/testing';
2
+ /**
3
+ * A set of criteria that can be used to filter a list of SkyIconHarness instances.
4
+ */
5
+ export interface SkyIconHarnessFilters extends SkyHarnessFilters {
6
+ }
@@ -0,0 +1,39 @@
1
+ import { HarnessPredicate } from '@angular/cdk/testing';
2
+ import { SkyComponentHarness } from '@skyux/core/testing';
3
+ import { SkyIconHarnessFilters } from './icon-harness-filters';
4
+ /**
5
+ * Harness for interacting with an icon component in tests.
6
+ */
7
+ export declare class SkyIconHarness extends SkyComponentHarness {
8
+ #private;
9
+ /**
10
+ * @internal
11
+ */
12
+ static hostSelector: string;
13
+ /**
14
+ * Gets a `HarnessPredicate` that can be used to search for a
15
+ * `SkyIconHarness` that meets certain criteria.
16
+ */
17
+ static with(filters: SkyIconHarnessFilters): HarnessPredicate<SkyIconHarness>;
18
+ /**
19
+ * Gets the icon name.
20
+ */
21
+ getIconName(): Promise<string | undefined>;
22
+ /**
23
+ * Gets the icon size.
24
+ */
25
+ getIconSize(): Promise<string | undefined>;
26
+ /**
27
+ * Gets the icon type.
28
+ * @deprecated The `iconType` input is no longer used. This method will be removed in a future version.
29
+ */
30
+ getIconType(): Promise<string>;
31
+ /**
32
+ * Gets if the icon is a variant.
33
+ */
34
+ getVariant(): Promise<string | undefined>;
35
+ /**
36
+ * Whether the icon has fixed width.
37
+ */
38
+ isFixedWidth(): Promise<boolean>;
39
+ }
@@ -0,0 +1,2 @@
1
+ export { SkyIconHarness } from './icon/icon-harness';
2
+ export { SkyIconHarnessFilters } from './icon/icon-harness-filters';