5.0.4 • Published 5 days ago

@coreui/icons-angular v5.0.4

Weekly downloads
699
License
MIT
Repository
github
Last release
5 days ago

CoreUI Icons Angular

angular NPM npm-coreui-angular-next
Downloads License

cIcon directive

Angular directive for CoreUI Icons SVG set.

Features

  • Load icons:
    • stored in Angular root service,
    • directly passed SVG content,
  • Reduce icons bundle size when imported as single icons,
  • Full functionality of <svg> tag,
  • Clean API

For directive description visit https://coreui.io/angular/docs/

Installation

npm install @coreui/icons@3
npm install @coreui/icons-angular@5

Usage

// app NgModule

import { IconModule, IconSetService } from '@coreui/icons-angular';

@NgModule({
  imports: [
    IconModule,
...
  providers: [IconSetService],
...
// app component

import { cilEnvelopeOpen, flagSet } from '@coreui/icons';
import { IconSetService } from '@coreui/icons-angular';

@Component({
  ...
})
export class AppComponent implements OnInit {
  constructor(public iconSet: IconSetService) {
    // iconSet singleton
    iconSet.icons = { cilEnvelopeOpen, ...flagSet };
  }
...
<svg cIcon name="cil-envelope-open" size="lg"></svg>
<svg cIcon name="cifAu"></svg>

API

Icon directive

Use one of name or content prop as it defines the way of icon import

Inputs
proprertytypedefaultdescription
namestringundefinedname of SVG icon stored in IconSetService
contentstring, string[]undefinedSVG content
sizecustom, custom-size, sm, lg, xl, xxl, 3xl, 4xl, 5xl, 6xl, 7xl, 8xl, 9xl''Size of icon
titlestringundefined
customClassesstringundefinedOverwrites default .icon classes
viewBoxstringundefinedSVG viewbox
widthstringundefinedSVG width
heightstringundefinedSVG height

IconSet service

Props
proprertytypedefaultdescription
getIcon()(string): any[]returns an icon
iconsIIconSetundefinedIconSet object
iconNames[key: string]: stringundefinedreturns icon name from key

Support CoreUI Development

CoreUI is an MIT-licensed open source project and is completely free to use. However, the amount of effort needed to maintain and develop new features for the project is not sustainable without proper financial backing. You can support development by buying the CoreUI PRO or by becoming a sponsor via Open Collective.

Platinum Sponsors

Support this project by becoming a Platinum Sponsor. A large company logo will be added here with a link to your website.

Gold Sponsors

Support this project by becoming a Gold Sponsor. A big company logo will be added here with a link to your website.

Silver Sponsors

Support this project by becoming a Silver Sponsor. A medium company logo will be added here with a link to your website.

Bronze Sponsors

Support this project by becoming a Bronze Sponsor. The company avatar will show up here with a link to your OpenCollective Profile.

Backers

Thanks to all the backers and sponsors! Support this project by becoming a backer.

Copyright and license

Copyright 2024 creativeLabs Łukasz Holeczek. Code released under the MIT License. Docs released under Creative Commons.

5.0.4

5 days ago

5.0.3

17 days ago

4.7.19

20 days ago

5.0.2

20 days ago

5.0.1

1 month ago

4.7.18

1 month ago

5.0.0

1 month ago

5.0.0-rc.1

1 month ago

4.7.17

2 months ago

5.0.0-rc.0

2 months ago

4.7.16

2 months ago

5.0.0-next.23

2 months ago

5.0.0-next.22

3 months ago

4.7.14

3 months ago

4.7.13

3 months ago

4.7.12

3 months ago

5.0.0-next.18

3 months ago

5.0.0-next.16

3 months ago

5.0.0-alpha.15

3 months ago

5.0.0-alpha.12

4 months ago

5.0.0-alpha.10

4 months ago

5.0.0-alpha.0

4 months ago

4.7.8

4 months ago

4.7.7

4 months ago

4.7.6

5 months ago

4.7.3

5 months ago

4.7.1

5 months ago

4.5.28

5 months ago

4.7.0

5 months ago

4.5.10

10 months ago

4.5.11

9 months ago

4.5.15

8 months ago

4.5.13

9 months ago

4.5.16

8 months ago

4.5.17

8 months ago

4.5.25

7 months ago

4.5.27

7 months ago

4.5.8

10 months ago

4.4.7

1 year ago

4.5.0-next.0

11 months ago

4.5.0

11 months ago

4.5.2

11 months ago

4.4.0-next.1

1 year ago

4.3.17

1 year ago

4.4.1

1 year ago

4.4.0

1 year ago

4.2.35

1 year ago

4.3.16

1 year ago

4.3.9

1 year ago

4.4.0-next.0

1 year ago

4.3.7

1 year ago

4.3.0-next.0

1 year ago

4.3.0

1 year ago

4.2.14

1 year ago

4.2.15

1 year ago

4.2.4

2 years ago

4.2.0

2 years ago

4.1.1

2 years ago

3.1.1

2 years ago

3.1.0

2 years ago

4.1.0

2 years ago

3.0.0

2 years ago

3.0.0-alpha.1

2 years ago

3.0.0-alpha.3

2 years ago

3.0.0-alpha.2

2 years ago

3.0.0-alpha.4

2 years ago

3.0.0-alpha.0

3 years ago

2.0.0-alpha.0

3 years ago

2.0.0-alpha.1

3 years ago

1.0.0-alpha.4

3 years ago

1.0.0-alpha.3

3 years ago

1.0.0-alpha.2

3 years ago

1.0.0-alpha.1

4 years ago

1.0.0-alpha.0

4 years ago