dumi
Direct Upload Media Image (DUMI)
Add images to your pages without the multiple clicks usually required by the standard Media library.
Direct Upload Media Image (DUMI) provides a fast, streamlined way to upload images directly, creating the necessary Media entity behind the scenes.
It replaces the complex media selection process with a simple click-to-upload / tap-to-upload experience, making content creation quicker and more intuitive.
What solution does this module provide?
This module provides a simplified field widget for Entity Reference fields that target Media entities.
An alternative to using the standard media browser (which requires selecting or uploading a file, then confirming, then saving the media entity),
DUMI allows the user to upload an image file directly from their computer into the field slot. It automatically handles the background work: creating the file, creating the media entity, and setting the correct reference ID, all in one smooth step.
Features
Basic functionality
When editing a node or other entity, users see a simple upload slot (either with a default label or a custom image) where they can click to select an image file. Once the file is uploaded, a preview of the image appears,
along with a Remove button.
The file is uploaded and referenced in a single front-end interaction.
This project adds several unique features and configuration options:
Single-Step Upload:
Automatically creates the File and Media entities upon direct image upload.
Live Preview:
Shows an immediate preview of the uploaded image, styled by a configurable Image Style.
Per-Field Size Limit:
Allows site builders to set a file size limit (in MB) specific to the widget, overriding the global configuration.
Multi-Value Enhancements:
For fields with unlimited cardinality, it displays a configurable number of empty slots (default: 10).
It supports multi-file selection from the operating system.
The auto_expand_slots setting ensures that if a user selects multiple files, the widget automatically creates enough slots for all files to be uploaded simultaneously.
The hide_empty_slots setting hides all but the first slot until a file is selected, providing a clean UI.
Custom Upload Label:
Supports configuring a custom image to use as the upload button/label, which can be tailored per media Bundle.
When and why would someone use this module?
Someone would use this module whenever they want a very simple, fast, and un-distracting image upload experience.
Use Cases:
Content editor needs to add multiple images to a photo gallery field quickly.
Site administrator wants to simplify the image input form for less technical users.
Any scenario where the standard Media Library workflow (which involves a modal, file selection, and media entity creation form) is considered overkill or too slow.
Post-Installation
Once you install and enable the Direct Upload Media Image module:
Grant Permissions: You must grant the appropriate user roles the "upload dumi files" permission. Without this, the widget will not work and will display a 'You do not have permission...' message.
Field Configuration:
DUMI is a Field Widget, so you need to configure it on a field:
Go to Structure -> Content types (or any other entity type with a Media entity reference field).
Click "Manage form display" for the content type you want to modify.
Locate the Media entity reference field that targets an image media bundle (e.g., field_media_image).
Change the Widget from the default (like 'Media Library') to "Direct Upload Media Image".
Widget Settings (Optional): After selecting the widget, click the gear icon next to it to configure its specific settings, such as:
The preview image style to use for the image shown on the form.
The file size limit for that specific field.
Settings for hiding/auto-expanding empty slots for multi-value fields.
You should then see the new, simplified image upload interface when editing content of that type. There appears to be a separate dumi.settings configuration form (likely at /admin/config/media/dumi or similar) where global settings like the default file size limit and custom bundle labels can be set.
Additional Requirements
This project has the following required dependencies, as defined in dumi.info.yml:
Drupal Core:
The module requires Drupal core version ^11
Media:
The core Media module must be enabled, as DUMI works by creating and managing Media entities.
File:
The core File module must be enabled, as Media entities rely on File entities.
The widget also uses the Image module's functionality to generate image styles for previews, so while not strictly listed in dependencies, the Image module is required for the preview_image_style setting to function correctly.
Recommended modules/libraries
No specific modules or libraries are recommended in the code, but any project that simplifies or enhances Media or File management in Drupal would pair well with DUMI.
Similar projects
The main differentiator for DUMI is its focus on a single-step, direct-upload experience that completely bypasses the standard multi-step Media Library interface. Similar projects often focus on extending the Media Library or providing advanced drag-and-drop features within the existing Media framework. DUMI's goal is to provide a lighter, quicker alternative that acts more like a traditional file-upload field but correctly saves as a Media entity.
Part of Direct Upload Media Suite
This module is part of a collection of tools designed to quicken media upload flow:
DUMA
Upload audio files directly from content forms with a preview HTML5 audio player.
DUMD
A user-friendly document upload widget for Drupal Media with document preview on node edit forms and content display.
DUMVE: Remote video and embed video on node edit forms and content display.