@html-css-to-image/client 0.0.3 → 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/types/internals.d.ts +21 -1
- package/dist/types/internals.js +20 -0
- package/dist/types/request.d.ts +1 -0
- package/package.json +1 -1
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ColorSchemeType } from "./request.js";
|
|
1
|
+
import { ColorSchemeType, MediaType } from "./request.js";
|
|
2
2
|
export declare abstract class BaseCreateRequestWithoutVariableOptions {
|
|
3
3
|
/**
|
|
4
4
|
* A CSS selector to target a specific element on the page.
|
|
@@ -50,6 +50,26 @@ export declare abstract class BaseCreateRequestWithoutVariableOptions {
|
|
|
50
50
|
* Sets the timezone for the browser instance. Use IANA timezone format (e.g. 'America/New_York').
|
|
51
51
|
*/
|
|
52
52
|
timezone?: string;
|
|
53
|
+
/**
|
|
54
|
+
Sets a value indicating whether the viewport should be rendered as if it's being viewed from a mobile device.
|
|
55
|
+
*/
|
|
56
|
+
viewport_mobile?: boolean;
|
|
57
|
+
/**
|
|
58
|
+
Sets a value indicating whether touch interactions are enabled within the viewport.
|
|
59
|
+
*/
|
|
60
|
+
viewport_touch?: boolean;
|
|
61
|
+
/**
|
|
62
|
+
* sets a value indicating whether the viewport should be in landscape orientation.
|
|
63
|
+
*/
|
|
64
|
+
viewport_landscape?: boolean;
|
|
65
|
+
/**
|
|
66
|
+
* Sets the media type to use for rendering, 'print' or 'screen'.
|
|
67
|
+
*/
|
|
68
|
+
media_type?: MediaType;
|
|
69
|
+
/**
|
|
70
|
+
* Sets which proxy_id for your organization to use when rendering.
|
|
71
|
+
*/
|
|
72
|
+
proxy_id?: string;
|
|
53
73
|
constructor(init?: Partial<BaseCreateRequestWithoutVariableOptions>);
|
|
54
74
|
}
|
|
55
75
|
export declare abstract class BasePDFOptions {
|
package/dist/types/internals.js
CHANGED
|
@@ -49,6 +49,26 @@ export class BaseCreateRequestWithoutVariableOptions {
|
|
|
49
49
|
* Sets the timezone for the browser instance. Use IANA timezone format (e.g. 'America/New_York').
|
|
50
50
|
*/
|
|
51
51
|
timezone;
|
|
52
|
+
/**
|
|
53
|
+
Sets a value indicating whether the viewport should be rendered as if it's being viewed from a mobile device.
|
|
54
|
+
*/
|
|
55
|
+
viewport_mobile;
|
|
56
|
+
/**
|
|
57
|
+
Sets a value indicating whether touch interactions are enabled within the viewport.
|
|
58
|
+
*/
|
|
59
|
+
viewport_touch;
|
|
60
|
+
/**
|
|
61
|
+
* sets a value indicating whether the viewport should be in landscape orientation.
|
|
62
|
+
*/
|
|
63
|
+
viewport_landscape;
|
|
64
|
+
/**
|
|
65
|
+
* Sets the media type to use for rendering, 'print' or 'screen'.
|
|
66
|
+
*/
|
|
67
|
+
media_type;
|
|
68
|
+
/**
|
|
69
|
+
* Sets which proxy_id for your organization to use when rendering.
|
|
70
|
+
*/
|
|
71
|
+
proxy_id;
|
|
52
72
|
constructor(init) {
|
|
53
73
|
Object.assign(this, init);
|
|
54
74
|
}
|
package/dist/types/request.d.ts
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { BaseCreateRequestWithoutVariableOptions, BasePDFOptions } from "./internals.js";
|
|
2
2
|
export type ColorSchemeType = 'light' | 'dark';
|
|
3
3
|
export type PdfUnit = 'px' | 'in' | 'cm' | 'mm';
|
|
4
|
+
export type MediaType = 'print' | 'screen';
|
|
4
5
|
export interface PdfValueWithUnits {
|
|
5
6
|
value: number;
|
|
6
7
|
unit: PdfUnit;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@html-css-to-image/client",
|
|
3
|
-
"version": "0.0
|
|
3
|
+
"version": "0.1.0",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "Lightweight TypeScript client for the HTML/CSS to Image API. Generate images from HTML/CSS, URLs, or templates in your TypeScript or JavaScript projects.",
|
|
6
6
|
"main": "dist/index.js",
|