NetC.FontAwesomeFormComponent.Kentico.MVC
12.29.4
dotnet add package NetC.FontAwesomeFormComponent.Kentico.MVC --version 12.29.4
NuGet\Install-Package NetC.FontAwesomeFormComponent.Kentico.MVC -Version 12.29.4
<PackageReference Include="NetC.FontAwesomeFormComponent.Kentico.MVC" Version="12.29.4" />
paket add NetC.FontAwesomeFormComponent.Kentico.MVC --version 12.29.4
#r "nuget: NetC.FontAwesomeFormComponent.Kentico.MVC, 12.29.4"
// Install NetC.FontAwesomeFormComponent.Kentico.MVC as a Cake Addin #addin nuget:?package=NetC.FontAwesomeFormComponent.Kentico.MVC&version=12.29.4 // Install NetC.FontAwesomeFormComponent.Kentico.MVC as a Cake Tool #tool nuget:?package=NetC.FontAwesomeFormComponent.Kentico.MVC&version=12.29.4
Kentico 12 MVC Font Awesome Form Component
font-awesome-form-component for Kentico MVC, adds the ability for a content editor to select a Font Awesome 5.x icon from a modal popup.
Nuget Package
https://www.nuget.org/packages/NetC.FontAwesomeFormComponent.Kentico.MVC/
Example use
- Include a property within an MVC widget property class:
[EditingComponent(FontAwesomeIconSelectorComponent.IDENTIFIER, Label = "Icon")]
/// <summary>
/// Icon field input.
/// </summary>
public string Icon { get; set; }
- Complete setting up the MVC widget itself, passing the Icon field through to the widget view, e.g.:
<i class="@Model.Icon"></i>
- Ensure your MVC site's layout contains Font Awesome CSS/JS, e.g.:
<!DOCTYPE html>
<html>
<head id="head">
...
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.10.2/css/all.min.css" integrity="sha256-zmfNZmXoNWBMemUOo1XUGFfc0ihGGLYdgtJS3KCr/l0=" crossorigin="anonymous" />
<script type="text/javascript">
// Notice how this gets configured before we load Font Awesome
window.FontAwesomeConfig = { autoReplaceSvg: false }
</script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.10.2/js/all.min.js" integrity="sha256-iZGp5HAiwRmkbOKVYv5FUER4iXp5QbiEudkZOdwLrjw=" crossorigin="anonymous"></script>
</head>
Add the widget to an MVC page, and open the config window to see the new property available:
Clicking the 'Open dialog' button opens the icon selection modal popup:
⌨️ Contributions, 🐛 bug fixes and 📜 license
Feel free to Fork and submit pull requests to contribute.
You can submit bugs through the issue list and we will get to them as soon as we can, unless you want to fix it yourself and submit a pull request!
Check the LICENSE.txt for License information
Compatibility
Can be used on any Kentico 12 SP site (hotfix 29 or above).
Product | Versions Compatible and additional computed target framework versions. |
---|---|
.NET Framework | net472 is compatible. net48 was computed. net481 was computed. |
-
- AngleSharp (>= 0.9.9.2)
- Antlr (>= 3.5.0.2)
- Kentico.AspNet.Mvc (>= 12.0.29)
- Microsoft.CSharp (>= 4.4.1)
- Microsoft.Data.Edm (>= 5.8.4)
- Microsoft.Data.OData (>= 5.8.4)
- Microsoft.Data.Services.Client (>= 5.8.4)
- Microsoft.Owin.Security (>= 3.1.0)
- Microsoft.Owin.Security.Cookies (>= 3.1.0)
- Microsoft.Owin.Security.OAuth (>= 3.1.0)
- Microsoft.Web.Xdt (>= 2.1.1)
- Newtonsoft.Json (>= 11.0.2)
- System.Spatial (>= 5.8.4)
- System.ValueTuple (>= 4.5.0)
- WebGrease (>= 1.6.0)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
Changed back to only include free icons rather than including pro.