Drupal is a registered trademark of Dries Buytaert
drupal 11.3.7 Update released for Drupal core (11.3.7)! drupal 11.2.11 Update released for Drupal core (11.2.11)! drupal 10.6.7 Update released for Drupal core (10.6.7)! drupal 10.5.9 Update released for Drupal core (10.5.9)! cms 2.1.1 Update released for Drupal core (2.1.1)! drupal 11.3.6 Update released for Drupal core (11.3.6)! drupal 10.6.6 Update released for Drupal core (10.6.6)! cms 2.1.0 Update released for Drupal core (2.1.0)! bootstrap 8.x-3.40 Minor update available for theme bootstrap (8.x-3.40). menu_link_attributes 8.x-1.7 Minor update available for module menu_link_attributes (8.x-1.7). eca 3.1.1 Minor update available for module eca (3.1.1). layout_paragraphs 2.1.3 Minor update available for module layout_paragraphs (2.1.3). ai 1.3.3 Minor update available for module ai (1.3.3). ai 1.2.14 Minor update available for module ai (1.2.14). node_revision_delete 2.0.3 Minor update available for module node_revision_delete (2.0.3). moderated_content_bulk_publish 2.0.52 Minor update available for module moderated_content_bulk_publish (2.0.52). klaro 3.0.10 Minor update available for module klaro (3.0.10). klaro 3.0.9 Minor update available for module klaro (3.0.9). layout_paragraphs 2.1.2 Minor update available for module layout_paragraphs (2.1.2). geofield_map 11.1.8 Minor update available for module geofield_map (11.1.8).

image_library_widget

27 sites Security covered
View on drupal.org

Provides an image widget that allows users to upload or choose an existing image from a library with a predefined set of images. Each widget can be configured to show images within a media type.

How it works?

The widget extends the core's image widget but adds also an "image browser". The "image browser" is actually a view that exposes image entries from the media type that was configured with that widget. The user can use the standard upload feature, or they can select a pre-uploaded image by clicking in the "image browser".

Dependencies

  • PHP >=7.1.0
  • Media (core)
  • Views (core)

Limitations

  • Currently, the module supports only image fields with a single value (cardinality 1). Support multi-value image fields to be implemented in #3103574.
  • It's not possible to configure the "image browser" (the view) with a pager but without Ajax being enabled as navigating to a different widget page should be done without reloading the page where the widget is rendered.

Configuration

  • Create one or more new media types by visiting `/admin/structure/media/add`. Set the "Media type" to "Image" and under "Media source configuration" set the "Field with source information" to "media.image_library_widget_image". Only media types configured in this way can be used as libraries in the widget.
  • Give the appropriate permissions to site admins so they can create media entries within those media types.
  • Create some media entries.
  • Configure the image field to use "Image Library Widget" as widget.
  • In the widget settings form chose the media type to be used as image library.

Customization

Because the "image browser" is a view, you can do whatever Views customization you want. You can decide what display format to use (e.g. Grid, HTML List, Unformatted list, etc), or the size of image thumbnails. If there are to many images pre-ulploaded in that media type, you can configure a pager but in this case you'll need to enable Ajax (see "Limitations").

Activity

Total releases
2
First release
Jun 2025
Latest release
7 months ago
Release cadence
87 days
Stability
0% stable

Releases

Version Type Release date
2.0.0-alpha4 Pre-release Sep 8, 2025
2.0.0-alpha3 Pre-release Jun 13, 2025