Skip to content

Commit

Permalink
Add icons
Browse files Browse the repository at this point in the history
  • Loading branch information
datlechin committed Jul 15, 2023
1 parent d51a643 commit 3b1e641
Show file tree
Hide file tree
Showing 608 changed files with 7,412 additions and 104 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,3 +4,4 @@ vendor/
composer.lock
phpunit.xml
package-lock.json
.DS_Store
2 changes: 1 addition & 1 deletion LICENSE.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
The MIT License (MIT)

Copyright (c) Blade Developer
Copyright (c) Ngo Quoc Dat <[email protected]>

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
Expand Down
50 changes: 20 additions & 30 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,26 +1,16 @@
# Blade Icons Template
# Blade Lineicons

<a href="https://github.com/blade-organization/blade-heroicons/actions?query=workflow%3ATests">
<img src="https://github.com/blade-ui-kit/blade-heroicons/workflows/Tests/badge.svg" alt="Tests">
<a href="https://github.com/datlechin/blade-lineicons/actions?query=workflow%3ATests">
<img src="https://github.com/datlechin/blade-lineicons/workflows/Tests/badge.svg" alt="Tests">
</a>
<a href="https://packagist.org/packages/blade-organization/blade-heroicons">
<img src="https://img.shields.io/packagist/v/blade-organization/blade-heroicons" alt="Latest Stable Version">
<a href="https://packagist.org/packages/datlechin/blade-lineicons">
<img src="https://img.shields.io/packagist/v/datlechin/blade-lineicons" alt="Latest Stable Version">
</a>
<a href="https://packagist.org/packages/blade-organization/blade-heroicons">
<img src="https://img.shields.io/packagist/dt/blade-organization/blade-heroicons" alt="Total Downloads">
<a href="https://packagist.org/packages/datlechin/blade-lineicons">
<img src="https://img.shields.io/packagist/dt/datlechin/blade-lineicons" alt="Total Downloads">
</a>

> This is a template repository for new icon packages for [Blade Icons](https://github.com/blade-ui-kit/blade-icons). Start a new repo with this and replace the relevant things below:
>
> 1. `blade-organization` with your GitHub organization
> 2. `blade-heroicons` with your repository name
> 3. `Blade Heroicons` & `Blade Icons Template` with your icon set name
> 4. Any other reference to `Heroicons` with your icon set name
> 5. `Blade Developer` with your name
>
> Then, make sure [the implementation](./src) is correct, that you set up [icon generation](https://github.com/blade-ui-kit/blade-icons#generating-icons) and that [your tests](./tests) pass. And remove this quote block from your readme. When you've published your package on Packagist, make sure to send it in to [the Blade Icons package list](https://github.com/blade-ui-kit/blade-icons#icon-packages).
A package to easily make use of [Heroicons](https://github.com/refactoringui/heroicons) in your Laravel Blade views.
A package to easily make use of [Lineicons](https://lineicons.com) in your Laravel Blade views.

For a full list of available icons see [the SVG directory](resources/svg) or preview them at [heroicons.com](https://heroicons.com/).

Expand All @@ -32,7 +22,7 @@ For a full list of available icons see [the SVG directory](resources/svg) or pre
## Installation

```bash
composer require blade-organization/blade-heroicons
composer require datlechin/blade-lineicons
```

## Updating
Expand All @@ -41,54 +31,54 @@ Please refer to [`the upgrade guide`](UPGRADE.md) when updating the library.

## Blade Icons

Blade Heroicons uses Blade Icons under the hood. Please refer to [the Blade Icons readme](https://github.com/blade-ui-kit/blade-icons) for additional functionality. We also recommend to [enable icon caching](https://github.com/blade-ui-kit/blade-icons#caching) with this library.
Blade Lineicons uses Blade Icons under the hood. Please refer to [the Blade Icons readme](https://github.com/blade-ui-kit/blade-icons) for additional functionality. We also recommend to [enable icon caching](https://github.com/blade-ui-kit/blade-icons#caching) with this library.

## Configuration

Blade Heroicons 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-heroicons.php` config file:
Blade Lineicons 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-lineicons.php` config file:

```bash
php artisan vendor:publish --tag=blade-heroicons-config
php artisan vendor:publish --tag=blade-lineicons-config
```

## Usage

Icons can be used as self-closing Blade components which will be compiled to SVG icons:

```blade
<x-heroicon-o-adjustments/>
<x-lineicons-capsule />
```

You can also pass classes to your icon components:

```blade
<x-heroicon-o-adjustments class="w-6 h-6 text-gray-500"/>
<x-lineicons-capsule class="w-6 h-6 text-gray-500" />
```

And even use inline styles:

```blade
<x-heroicon-o-adjustments style="color: #555"/>
<x-lineicons-capsule style="color: #555" />
```

The solid icons can be referenced like this:

```blade
<x-heroicon-s-adjustments/>
<x-lineicons-capsule />
```

### Raw SVG Icons

If you want to use the raw SVG icons as assets, you can publish them using:

```bash
php artisan vendor:publish --tag=blade-heroicons --force
php artisan vendor:publish --tag=blade-lineicons --force
```

Then use them in your views like:

```blade
<img src="{{ asset('vendor/blade-heroicons/o-adjustments.svg') }}" width="10" height="10"/>
<img src="{{ asset('vendor/blade-lineicons/capsule.svg') }}" width="10" height="10"/>
```

## Changelog
Expand All @@ -97,8 +87,8 @@ Check out the [CHANGELOG](CHANGELOG.md) in this repository for all the recent ch

## Maintainers

Blade Heroicons is developed and maintained by Blade Developer.
Blade Lineicons is developed and maintained by [Ngo Quoc Dat](https://ngoquocdat.dev).

## License

Blade Heroicons is open-sourced software licensed under [the MIT license](LICENSE.md).
Blade Lineicons is open-sourced software licensed under [the MIT license](LICENSE.md).
16 changes: 9 additions & 7 deletions composer.json
Original file line number Diff line number Diff line change
@@ -1,12 +1,14 @@
{
"name": "blade-organization/blade-heroicons",
"description": "A package to easily make use of Heroicons in your Laravel Blade views.",
"keywords": ["Blade", "Heroicons", "Laravel"],
"homepage": "https://github.com/blade-organization/blade-heroicons",
"name": "datlechin/blade-lineicons",
"description": "A package to easily make use of Lineicons in your Laravel Blade views.",
"keywords": ["Blade", "Lineicons", "Laravel"],
"homepage": "https://github.com/datlechin/blade-lineicons",
"license": "MIT",
"authors": [
{
"name": "Blade Developer"
"name": "Ngo Quoc Dat",
"email": "[email protected]",
"homepage": "https://ngoquocdat.dev"
}
],
"require": {
Expand All @@ -20,7 +22,7 @@
},
"autoload": {
"psr-4": {
"BladeUI\\Heroicons\\": "src"
"Datlechin\\Lineicons\\": "src"
}
},
"autoload-dev": {
Expand All @@ -31,7 +33,7 @@
"extra": {
"laravel": {
"providers": [
"BladeUI\\Heroicons\\BladeHeroiconsServiceProvider"
"Datlechin\\Lineicons\\BladeLineiconsServiceProvider"
]
}
},
Expand Down
2 changes: 1 addition & 1 deletion config/blade-heroicons.php → config/blade-lineicons.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
|
*/

'prefix' => 'heroicon',
'prefix' => 'lineicons',

/*
|-----------------------------------------------------------------
Expand Down
4 changes: 2 additions & 2 deletions config/generation.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

return [
[
'source' => __DIR__.'/../node_modules/heroicons',
'destination' => __DIR__.'/../resources/svg',
'source' => __DIR__ . '/../node_modules/heroicons',
'destination' => __DIR__ . '/../resources/svg',
],
];
6 changes: 0 additions & 6 deletions package.json

This file was deleted.

Empty file removed resources/svg/.gitkeep
Empty file.
27 changes: 27 additions & 0 deletions resources/svg/500px.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
12 changes: 12 additions & 0 deletions resources/svg/add-files.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
6 changes: 6 additions & 0 deletions resources/svg/adobe.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
9 changes: 9 additions & 0 deletions resources/svg/agenda.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
11 changes: 11 additions & 0 deletions resources/svg/airbnb.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
3 changes: 3 additions & 0 deletions resources/svg/airtable.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
15 changes: 15 additions & 0 deletions resources/svg/alarm-clock.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
10 changes: 10 additions & 0 deletions resources/svg/alarm.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
16 changes: 16 additions & 0 deletions resources/svg/amazon-original.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading

0 comments on commit 3b1e641

Please sign in to comment.