Skip to content

feat: Add watermark option#17

Merged
loicsapone merged 2 commits intoMezcalito:0.xfrom
LocService:feat/add-watermark-option
Feb 28, 2026
Merged

feat: Add watermark option#17
loicsapone merged 2 commits intoMezcalito:0.xfrom
LocService:feat/add-watermark-option

Conversation

@ls-gurvan
Copy link
Contributor

Add Watermark Option Support

This PR adds support for the watermark feature in imgproxy configuration.

Changes

  • Added watermark configuration node in Configuration.php
  • Added Watermark processing option class

Configuration Options

The watermark option accepts the following parameters:

  • opacity: Watermark opacity modifier (float between 0 and 1)
  • position: Watermark position - ce (center, default), no, so, ea, we, noea, nowe, soea, sowe, re (repeat)
  • x_offset, y_offset: Offset values (integers, default: 0)
  • scale: Size relative to the resulting image (float, default: 0 = no resize)

Usage Example

imgproxy:
    options:
        watermark:
            opacity: 0.5
            position: 'soea'
            x_offset: 10
            y_offset: 10
            scale: 0.2

@loicsapone loicsapone self-requested a review February 6, 2026 19:53
@loicsapone loicsapone merged commit 348a149 into Mezcalito:0.x Feb 28, 2026
7 checks passed
@loicsapone
Copy link
Member

Thank you @ls-gurvan!
Sorry for the delay

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants