2

我正在写一个 amp 故事;但如果不使用 amp-story-consent 默认 UI,似乎无法获得 amp-consent 模式。我想使用 amp-iframe,或者只是一个普通的 html 模式,但都不会呈现。

有人对此有任何运气吗?

框架:

<amp-consent layout="nodisplay" id="gdpr-consent-element">
        <script type="application/json">
            {
                "consents": {
                    "cbsiampconsent": {
                        "promptIfUnknownForGeoGroup": "eea",
                        "promptUI": "consentDialog"
                    }
                }
            }
        </script>
        <div id="consentDialog" style="position: absolute; widht: 500px; height: 500px;">
            <amp-iframe width="200" height="100"
                        sandbox="allow-scripts allow-same-origin"
                        layout="responsive"
                        frameborder="0"
                        src="https://www.google.com/maps/embed/v1/place?key=AIzaSyDG9YXIhKBhqclZizcSzJ0ROiE0qgVfwzI&q=iceland">
            </amp-iframe>
        </div>
    </amp-consent>
4

1 回答 1

2

这是不可能的; 唯一受支持的同意 UI 是您提到的默认 UI。

有关更多详细信息,请参阅amp-story-consent 文档示例

于 2018-11-12T21:37:57.000 回答