Skip to main content
drupalreleases

Use direct release data with your AI assistant.

Learn more

Fontawesome Field Formatter(for int)

Security covered Under active development 181 sites

This module provides a field formatter for select list fields containing integer values. It allows you to display the selected integer as an icon from libraries like Font Awesome or custom icon sets. This is useful for creating visual representations like star ratings without requiring custom field types.

This is a field formatter for a selectlist with int values. Its use is to make some kind of ratingdisplay avaliable but without any processing! It just outputs an int select field as icons. You can use Fontawesome or any other iconservice using the same schema. The rating image can be ANY fontawesome icon. Apples, stars, circles you name it.

You can also use other icon libs. I for example use a custom one i generated with iconmoon because i dont want 4MB FA files to be loaded in the background.

How to use?

  1. Create a field list(int)
  2. Add selectable values like 1 2 3 4 5 6
  3. Chose the field formatter in the field settings to output and add your icon code
  4. Chose an icon from https://fontawesome.com/icons?d=gallery
  5. For example:
  6. Your selection is outputted with the icon!

I used it to rate books for my project about - EXAMPLE Audiobooks(Hörbücher) and output these ratings with stars.

Scroll down and you see some stars and dots: Example. In the backend that is just an in select field and i used views with my formatter to display it as icons. Do not be confused about interactive the rating at the top of the page. That is something different and can be done with the Rate or Fivestars Module

Why

I have already worked on Starrating in the D7 Version, but the D8 version has a dedicated own fieldttype. I see no use in creating a custom fielddtype so i used a core type that already exists.

Drupal 8–11

Ask your assistant about Fontawesome Field Formatter(for int)

Check compatibility with your Drupal and PHP version, maintenance and security coverage, from current release data. How it works

Depends on

Dependencies of the latest stable release

No dependencies recorded for this project.

Required by

Tracked projects that depend on this one

No tracked projects depend on this one yet.

Activity

Tracked releases
3
Tracked since
Sep 2023
Latest release
2 years ago
Releases (12 mo)
0
Maintenance
Dormant

Release Timeline

Releases

Version Type Core PHP Release date
2.0.3 Stable 8–11 Apr 26, 2024
2.0.2 Stable 8–11 Apr 24, 2024
2.0.1 Stable 8–10 Sep 12, 2023