aimanecouissi/module-hyva-remixicon
最新稳定版本:1.0.0
Composer 安装命令:
composer require aimanecouissi/module-hyva-remixicon
包简介
Add the Remixicon SVG icon set to Hyvä Themes
README 文档
README
Integrates the Remixicon SVG icon set into Hyvä Themes, exposing line and fill
styles as dedicated SvgIcons view models. Browse the included icons
in the SVG directory
or preview them at remixicon.com.
Installation
composer require aimanecouissi/module-hyva-remixicon bin/magento module:enable AimaneCouissi_HyvaSvgIcons AimaneCouissi_HyvaRemixicon bin/magento setup:upgrade bin/magento cache:flush
Usage
In Hyvä PHTML templates
Require the view models for the styles you need and call their helper methods to render icons:
<?php use AimaneCouissi\HyvaRemixicon\ViewModel\RemixiconFill; use AimaneCouissi\HyvaRemixicon\ViewModel\RemixiconLine; use Hyva\Theme\Model\ViewModelRegistry; /** @var ViewModelRegistry $viewModels */ $remixiconLine = $viewModels->require(RemixiconLine::class); $remixiconFill = $viewModels->require(RemixiconFill::class); ?>
<?= $remixiconLine->shoppingCartHtml('w-6 h-6', 24, 24, ['aria-label' => 'Cart']) ?> <?= $remixiconFill->starHtml('w-5 h-5 text-yellow-400', 20, 20, ['aria-hidden' => 'true']) ?>
Methods are generated from SVG filenames and fully documented via PHPDoc on each view model, so your IDE can
autocomplete them. Icons whose names start with a digit are prefixed with an underscore (e.g. _24HoursHtml,
_4kHtml).
In CMS content
The module registers two icon prefixes for Hyvä SvgIcons: remixicon-line and remixicon-fill. Icons can be used
directly in CMS pages, blocks, and widgets:
{{icon "remixicon-line/shopping-cart" classes="inline-block w-6 h-6" width=24 height=24}}
{{icon "remixicon-fill/star" classes="inline-block w-5 h-5 text-yellow-400" width=20 height=20}}
Uninstall
bin/magento module:disable AimaneCouissi_HyvaRemixicon composer remove aimanecouissi/module-hyva-remixicon bin/magento setup:upgrade bin/magento cache:flush
Changelog
See CHANGELOG for all recent changes, including icon set version updates.
License
The Remixicon SVG icons are created by Remix Design and licensed under Remix Icon License v1.0.
Warning
Individual brand icons may be subject to their own trademark and usage guidelines. Trademark usage is the responsibility of the end user. Please consult individual brand guidelines before displaying logos in commercial contexts.
This module's source code is separately licensed under MIT.
统计信息
- 总下载量: 0
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 1
- 点击次数: 6
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2026-03-27