Skip to content

Commit

Permalink
feat: deprecate isBackgroundVideo, remove from demos, add todos whe…
Browse files Browse the repository at this point in the history
…re prop is used
  • Loading branch information
Daniel Morse committed Aug 8, 2019
1 parent 40cf8bc commit ce9a25d
Show file tree
Hide file tree
Showing 6 changed files with 15 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,9 @@
} only %}
</div>

{# @todo: `isBackgroundVideo` will be removed with Bolt v3.0. Hide this demo page for now and remove it entirely with v3.0. #}
{# Background Video #}
{% set content_video %}
{# {% set content_video %}
{% include "@bolt-components-headline/headline.twig" with {
size: "xxxlarge",
text: "This Band Has a Backround Video",
Expand Down Expand Up @@ -71,4 +72,4 @@
]
},
content: content_video
} only %}
} only %} #}
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
{# @todo: `isBackgroundVideo` will be removed with Bolt v3.0. Hide this demo page for now and remove it entirely with v3.0. #}

{% embed "@bolt-components-band/band.twig" with {
theme: "dark",
size: "medium",
Expand Down
1 change: 1 addition & 0 deletions packages/components/bolt-band/src/band.js
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,7 @@ class BoltBand extends withLitHtml() {
}

playHandler(event) {
// @todo: `isBackgroundVideo` will be removed with Bolt v3.0
if (event.detail.isBackgroundVideo && this.expanded === false) {
this.expand();

Expand Down
1 change: 1 addition & 0 deletions packages/components/bolt-video/src/_video-tag.twig
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,7 @@

{% set attributes = attributes.setAttribute("share-description", share_description|default('Share This Video'|t)) %}

{# @todo: `isBackgroundVideo` will be removed with Bolt v3.0 #}
{% if isBackgroundVideo %}
{% set attributes = attributes.setAttribute("is-background-video", isBackgroundVideo) %}
{% else %}
Expand Down
2 changes: 1 addition & 1 deletion packages/components/bolt-video/src/video.standalone.js
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ class BoltVideo extends withPreact() {
accountId: props.string,
playerId: props.string,
poster: props.object,
isBackgroundVideo: props.boolean,
isBackgroundVideo: props.boolean, // @todo: `isBackgroundVideo` will be removed with Bolt v3.0
onInit: props.string,
showMeta: props.boolean,
showMetaTitle: props.boolean,
Expand Down
11 changes: 7 additions & 4 deletions packages/components/bolt-video/video.schema.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
$schema: http://json-schema.org/draft-04/schema#
title: Video
type: object
not:
anyOf:
- required:
- isBackgroundVideo
properties:
attributes:
type: object
Expand Down Expand Up @@ -47,10 +51,6 @@ properties:
type: boolean
description: Should the video loop.
default: false
isBackgroundVideo:
type: boolean
description: Set to true if the video is a background.
default: false
on_init:
type: string
description: 'The `on_init` config allows for an external Javascript function inlined on the page to add any 3rd party scripts or video plugins to a `<bolt-video>` player instance when initializing. Please see the new recommended `enabled_plugins` and `disabled_plugins` options below.'
Expand All @@ -77,3 +77,6 @@ properties:
disabled_plugins:
type: string
description: 'Space-separated list of any built-in `<bolt-video>` plugins for Brightcove to disable. Used to opt-out of any video plugins that are enabled by default (ex. the `playback` plugin). For example: `<bolt-video disabled-plugins="playback">`.'
isBackgroundVideo:
title: DEPRECATED
description: Background video feature will be removed with Bolt v3.0

0 comments on commit ce9a25d

Please sign in to comment.