API Reference
Class
HtmlResponsiveImageSelector
Selects one candidate from an HTML srcset and sizes pair without depending on a DOM provider.
Inheritance
- Object
- HtmlResponsiveImageSelector
Methods
public static HtmlResponsiveImageSelection Select(String srcSet, String sizes, String defaultSource, HtmlResponsiveImageSelectionOptions options = null) #Returns:
HtmlResponsiveImageSelectionSelects one source using deterministic density preference. Width descriptors are normalized by the first matching supported sizes entry; an omitted or unsupported list falls back to 100vw.
Parameters
- srcSet System.String
- Authored source-set value.
- sizes System.String
- Optional source-size list.
- defaultSource System.String
- Optional src fallback. It participates as 1x only for density sets without an authored 1x candidate.
- options OfficeIMO.Html.HtmlResponsiveImageSelectionOptions = null
- Selection environment.