AdvertisementAutoPlacement
The object for defining the automatic placement of advertisements.
Declaration
object AdvertisementAutoPlacementProperties
| Name | Type | Description |
|---|---|---|
bannerType | string | A specific banner type that should be automatically inserted based on the |
conditional | (ConditionalAutoPlacement | [ConditionalAutoPlacement]) | An instance or array of automatic placement properties that can be applied conditionally, and the conditions that cause them to take effect. |
distanceFromMedia | (SupportedUnits | number) | The minimum required distance between automatically inserted advertisement components and media, such as Video and Photo. Advertisements will show next to media if |
enabled | boolean | A Boolean that defines whether placement of advertisements is enabled. |
frequency | integer | A number from Setting this value to Setting this value to Increasing the frequency value increases the frequency of dynamic advertisements below the first screen bounds. Setting this value to |
layout | AutoPlacementLayout | The layout properties for automatically inserted components. |
Mentioned in
Discussion
Use the AdvertisementAutoPlacement object to insert dynamic advertisements between Body, Chapter, Section, or Container components in an article.
Example
{
"version": "1.9",
"identifier": "SampleArticle",
"language": "en",
"title": "Apple News",
"layout": {
"columns": 20,
"width": 1024,
"margin": 60,
"gutter": 20
},
"autoplacement": {
"advertisement": {
"enabled": true,
"bannerType": "any",
"distanceFromMedia": "10vh",
"frequency": 10,
"layout": {
"margin": 10
}
}
},
…
}