Skip to content

Commit

Permalink
Update files/zh-cn/mozilla/add-ons/webextensions/api/extensiontypes/i…
Browse files Browse the repository at this point in the history
…magedetails/index.md

Co-authored-by: A1lo <[email protected]>
  • Loading branch information
PassionPenguin and yin1999 committed Sep 21, 2024
1 parent 385d1e7 commit 5c9a530
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ l10n:
- `format` {{optional_inline}}
- : {{WebExtAPIRef('extensionTypes.ImageFormat')}}。结果图片的格式,默认为 `"png"`
- `quality` {{optional_inline}}
- : `integer`。当格式是 `"jpeg"` 时,这将决定结果图片的质量。这应是 0—100 之间的数字,并将被转换为 0—1 之间的取值作为 [`HTMLCanvasElement.toDataURL()`](/zh-CN/docs/Web/API/HTMLCanvasElement/toDataURL) 方法的 `encoderOptions` 参数传递给函数。在属性被忽略时将采用 92 作为默认取值。随着质量的降低,结果图片将有更多视觉伪影,存储所需的字节数也将减少。当图片格式设置为 PNG 时,该属性将被忽略
- : `integer`。当格式是 `"jpeg"` 时,这将决定结果图片的质量。这应是 0—100 之间的数字,并将被转换为 0—1 之间的取值作为 [`HTMLCanvasElement.toDataURL()`](/zh-CN/docs/Web/API/HTMLCanvasElement/toDataURL) 方法的 `encoderOptions` 参数传递给函数。在属性被忽略时将采用 92 作为默认取值。随着质量的降低,结果图片将有更多视觉伪影,存储所需的字节数也将减少。当图片格式设置为 PNG 时,该值将被忽略
- `rect` {{optional_inline}}

- : `object`,指定要捕获的文档区域,单位为 CSS 像素,相对于页面。所有属性默认为 `0`。这些属性是:
Expand Down

0 comments on commit 5c9a530

Please sign in to comment.