Skip to content
Permalink
Branch: master
Find file Copy path
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
112 lines (110 sloc) 3.2 KB
#
# Copyright 2016 The AMP HTML Authors. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS-IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the license.
#
tags: { # amp-audio
html_format: AMP
html_format: AMP4ADS
tag_name: "SCRIPT"
extension_spec: {
name: "amp-audio"
version: "0.1"
version: "latest"
deprecated_allow_duplicates: true
requires_usage: GRANDFATHERED
}
attr_lists: "common-extension-attrs"
}
attr_lists: { # amp-audio attributes that are common to both AMP and A4A format.
name: "amp-audio-common"
attrs: { name: "album" }
attrs: { name: "artist" }
attrs: { name: "artwork" }
attrs: { name: "controls" }
attrs: { name: "controlslist" }
attrs: { name: "loop" value: "" }
attrs: { name: "muted" value: "" }
attrs: {
name: "src"
value_url: {
protocol: "https"
allow_relative: true # Will be set to false at a future date.
}
blacklisted_value_regex: "__amp_source_origin"
}
}
tags: { # <amp-audio> for AMP (autoplay attribute allowed)
html_format: AMP
tag_name: "AMP-AUDIO"
# There is an alternate spec for amp-video in amp-story.
disallowed_ancestor: "AMP-STORY"
requires_extension: "amp-audio"
attrs: {
name: "autoplay"
value: ""
}
attrs: {
name: "preload"
value_casei: "auto"
value_casei: "metadata"
value_casei: "none"
}
attr_lists: "amp-audio-common"
attr_lists: "extended-amp-global"
spec_url: "https://amp.dev/documentation/components/amp-audio"
amp_layout {
defines_default_height: true
# TODO(johannes): in the longer run, defines_default_width should
# be false, to make it a fixed height layout per default, rather
# than a fixed one.
defines_default_width: true
supported_layouts: FIXED
supported_layouts: FIXED_HEIGHT
supported_layouts: NODISPLAY
}
}
tags: { # <amp-audio> for AMP, amp-story (autoplay attribute mandatory)
html_format: AMP
tag_name: "AMP-AUDIO"
spec_name: "amp-story >> amp-audio"
mandatory_ancestor: "AMP-STORY"
requires_extension: "amp-audio"
attrs: {
name: "autoplay"
value: ""
mandatory: true
}
attr_lists: "amp-audio-common"
attr_lists: "extended-amp-global"
spec_url: "https://amp.dev/documentation/components/amp-audio"
amp_layout {
supported_layouts: NODISPLAY
}
}
tags: { # <amp-audio> for A4A (autoplay attribute disallowed)
html_format: AMP4ADS
tag_name: "AMP-AUDIO"
spec_name: "amp-audio (A4A)"
requires_extension: "amp-audio"
attr_lists: "amp-audio-common"
attr_lists: "extended-amp-global"
spec_url: "https://amp.dev/documentation/components/amp-audio"
amp_layout {
defines_default_height: true
defines_default_width: true
supported_layouts: FIXED
supported_layouts: FIXED_HEIGHT
supported_layouts: NODISPLAY
}
}
You can’t perform that action at this time.