codeat3 / blade-carbon-icons
A package to easily make use of Carbon Icons in your Laravel Blade views.
Fund package maintenance!
swapnilsarwe
Installs: 157 358
Dependents: 4
Suggesters: 1
Security: 0
Stars: 4
Watchers: 3
Forks: 4
Open Issues: 5
Requires
- php: ^7.4|^8.0
- blade-ui-kit/blade-icons: ^1.1
- illuminate/support: ^8.0|^9.0|^10.0|^11.0
Requires (Dev)
- codeat3/blade-icon-generation-helpers: ^0.8
- codeat3/phpcs-styles: ^1.0
- orchestra/testbench: ^6.0|^7.0|^8.0|^9.0
- phpunit/phpunit: ^9.0|^10.5|^11.0
- dev-main
- 2.30.0
- 2.29.0
- 2.28.0
- 2.27.0
- 2.26.0
- 2.25.0
- 2.24.0
- 2.23.0
- 2.22.0
- 2.21.0
- 2.20.0
- 2.19.0
- 2.18.2
- 2.17.2
- 2.16.2
- 2.15.2
- 2.14.2
- 2.13.2
- 2.12.2
- 2.12.1
- 2.12.0
- 2.11.0
- 2.10.0
- 2.9.0
- 2.8.0
- 2.7.0
- 2.6.0
- 2.5.0
- 2.4.0
- 2.3.0
- 2.2.0
- 2.1.0
- 2.0.0
- 1.0.0
- dev-feature/update-69720978a1fbef2e2afce4143c6b073f9c6d62b4
- dev-feature/update-1a48fe30543de51ee1e280e98cdde5c9375ba2d8
- dev-feature/update-c300d451e97f16ebbc9df35744173430b2318740
- dev-feature/update-f4f3dfe031937c743336176ad3f7598eb528a110
- dev-feature/update-c1c8a8b4690d6a52d3fa939e6885021d0f9e4127
This package is auto-updated.
Last update: 2024-11-18 12:34:08 UTC
README
Blade Carbon Icons
A package to easily make use of Blade Carbon Icons in your Laravel Blade views.
For a full list of available icons see the SVG directory.
Requirements
- PHP 7.4 or higher
- Laravel 8.0 or higher
Installation
composer require codeat3/blade-carbon-icons
Updating
Please refer to the upgrade guide
when updating the library.
Blade Icons
Blade Carbon Icons uses Blade Icons under the hood. Please refer to the Blade Icons readme for additional functionality. We also recommend to enable icon caching with this library.
Configuration
Blade Carbon Icons also offers the ability to use features from Blade Icons like default classes, default attributes, etc. If you'd like to configure these, publish the blade-carbon-icons.php
config file:
php artisan vendor:publish --tag=blade-carbon-icons-config
Usage
Icons can be used as self-closing Blade components which will be compiled to SVG icons:
<x-carbon-sigma/>
You can also pass classes to your icon components:
<x-carbon-sigma class="w-6 h-6 text-gray-500"/>
And even use inline styles:
<x-carbon-sigma style="color: #555"/>
Raw SVG Icons
If you want to use the raw SVG icons as assets, you can publish them using:
php artisan vendor:publish --tag=blade-carbon-icons --force
Then use them in your views like:
<img src="{{ asset('vendor/blade-carbon-icons/sigma.svg') }}" width="10" height="10"/>
Changelog
Check out the CHANGELOG in this repository for all the recent changes.
Maintainers
Blade Carbon Icons is developed and maintained by Swapnil Sarwe.
License
Blade Carbon Icons is open-sourced software licensed under the MIT license.