feat(chromium): allow to specify device scale ratio for screenshots (#1543)

This commit is contained in:
Heorhii Ovcharenko
2026-05-04 22:16:04 +03:00
committed by GitHub
parent fe1b0020b8
commit c1cdcbdaab
8 changed files with 43 additions and 23 deletions
@@ -72,6 +72,15 @@ Feature: /forms/chromium/screenshot/html
Then the response status code should be 200
Then the response header "Content-Type" should be "image/png"
Scenario: POST /forms/chromium/screenshot/html (Device Scale Factor)
Given I have a default Gotenberg container
When I make a "POST" request to Gotenberg at the "/forms/chromium/screenshot/html" endpoint with the following form data and header(s):
| files | testdata/page-1-html/index.html | file |
| deviceScaleFactor | 1.0 | field |
| Gotenberg-Output-Filename | foo | header |
Then the response status code should be 200
Then the response header "Content-Type" should be "image/png"
Scenario: POST /forms/chromium/screenshot/html (Omit Background)
Given I have a default Gotenberg container
When I make a "POST" request to Gotenberg at the "/forms/chromium/screenshot/html" endpoint with the following form data and header(s):