/* global window document */ /* eslint-disable strict */ window.PatternLibrary = window.PatternLibrary || {}; (function(behaviors) { 'use strict'; const AGE_CHECK_EVENT = { VERIFIED: 'nds.agecheck.verified', LAUNCH: 'nds.agecheck.launch', ERROR: 'nds.agecheck.error' }; behaviors.ageCheck = { properties: { /** * Does this component need Age Gate */ ageCheck: { type: Boolean, value: false, reflectToAttribute: true }, /** * Has the user been verified for this age gate */ ageCheckVerified: { type: Boolean, value: false, reflectToAttribute: true }, /** * Has the user had an error for this age gate */ ageCheckError: { type: Boolean, value: false, reflectToAttribute: true } }, /** * Checks whether to build the Player based on Age Gate Status * * @param ageCheck * @param ageCheckVerified * @returns {boolean|*} */ isAgeGateCoverHidden(ageCheck, ageCheckVerified) { return !ageCheck || (ageCheck && ageCheckVerified); }, /** * Fires Event To Launch Age Gate Modal */ launchAgeGateEvent() { this.fire(AGE_CHECK_EVENT.LAUNCH); }, /** * Fires Event To notify successful Age Gate */ handleAgeGateSuccess() { this.fire(AGE_CHECK_EVENT.VERIFIED); }, /** * Fires Event To notify error Age Gate */ handleAgeGateError() { this.fire(AGE_CHECK_EVENT.ERROR); }, /** * Listens for Age Gate Events for any media that needs it */ ready() { document.body.addEventListener(AGE_CHECK_EVENT.VERIFIED, () => { this.ageCheckVerified = true; }); document.body.addEventListener(AGE_CHECK_EVENT.ERROR, () => { this.ageCheckError = true; }); } }; })(window.PatternLibrary.behaviors = window.PatternLibrary.behaviors || {});
[[ titleText ]]
[[ captionText ]]
[[ saleText ]] ![[[ title ]]]([[ logoUrl ]])
[[ disclaimerText]]
[[ tab.editionText ]][[ titleText ]]
[[ strikePriceText ]][[ priceText ]][[ platformText ]][[ releaseDatePrefixText ]] [[ releaseDateText ]]
[[_text]]
/ /
[[ errorText ]]
[[ helpText ]]
[[ detail.label ]]
[[ detail.text ]]
[[ labelText ]] {{ text }}
![[[ tooltip ]]]([[ media ]])
[[ username ]]
[[ eyebrowText ]][[ eyebrowSecondaryText ]]
[[ titleText ]]
/* global window */ /* eslint-disable strict */ window.PatternLibrary = window.PatternLibrary || {}; (function(behaviors) { 'use strict'; const emailReg = /^[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$/; // eslint-disable-line max-len const passWordReg = /^(?=.*\d)(?=.*[a-z])(?=.*[A-Z])[0-9a-zA-Z]{8,16}$/; behaviors.valueValidator = { /** * Checks if this element currently has a value * * @return {Boolean} */ hasValue() { return this.checked || this.value; }, /** * Checks if this element should be validated * * @return {Boolean} */ isValidatable() { if (this.required || !this.required && this.hasValue()) { return true; } return false; }, /** * validates a value based on supplied type * or custom RegExp Pattern * * @return {Boolean} */ validateValue() { let customReg; if (this.validPattern) { customReg = new RegExp(this.validPattern); return customReg.test(this.value); } switch (this.type) { case 'email': return this.value.match(emailReg); case 'password': return this.value.match(passWordReg); case 'date': return this._validateDateFieldValue(this.value); default: return true; } }, /** * Returns the valid state of this element * or custom RegExp Pattern * * @private * @return {Boolean} */ _validate() { if (this.isValidatable()) { return this.hasValue() && this.validateValue(); } return true; } }; })( window.PatternLibrary.behaviors = window.PatternLibrary.behaviors || {} ); /* global window */ /* eslint-disable strict */ window.PatternLibrary = window.PatternLibrary || {}; (function(behaviors) { 'use strict'; behaviors.formElement = { properties: { /** * Name * * @type {String} */ name: { type: String }, /** * Value * * @type {String} */ value: { type: String }, /** * Disabled */ disabled: { type: Boolean, value: false, reflectToAttribute: true }, /** * Error * * @type {Boolean} */ error: { type: Boolean, value: false, reflectToAttribute: true }, /** * Required * * @type {Boolean} */ required: { type: Boolean, value: false } }, /** * Sets the value of this elemement */ _setValue(value) { this.value = value; this._empty = false; }, /** * Custom element Lifecycle callback * registers this element with it's parent form * Event listener is in the parent form */ attached() { this.fire('ea-form-element-register', {}, {}); } }; })(window.PatternLibrary.behaviors = window.PatternLibrary.behaviors || {}); /* global window */ /* eslint-disable strict */ window.PatternLibrary = window.PatternLibrary || {}; (function(behaviors) { 'use strict'; behaviors.inputElementInteractions = { properties: { /** * Current * * @type {Boolean} */ current: { type: Boolean, value: false, reflectToAttribute: true }, /** * Empty * * @type {Boolean} */ _empty: { type: Boolean, value: true, reflectToAttribute: true }, /** * Background color * * Possible values: * - none * - dark * - light * * @type {String} */ backgroundColor: { type: String, reflectToAttribute: true }, /** * Error * * @type {Boolean} */ error: { type: Boolean, value: false, reflectToAttribute: true }, /** * Help active * * @type {Boolean} */ helpActive: { type: Boolean, value: false, reflectToAttribute: true } }, /** * Updates the state of the component to helpActive on mouseEnter */ _handleEnter() { this.helpActive = true; }, /** * Removes the helpActive state of the component on mouseLeave */ _handleLeave() { this.helpActive = false; }, /** * Listeners * * @type {Object} */ listeners: { mouseenter: '_handleEnter', mouseleave: '_handleLeave' } }; })(window.PatternLibrary.behaviors = window.PatternLibrary.behaviors || {});
[[ errorText ]]
[[ helpText ]]
[[ eyebrowText ]][[ eyebrowSecondaryText ]]
[[ bylineText ]]
[[ eyebrowText ]]

[[ titleText ]]
[[ subtitleText ]]
![[[ tooltip ]]]([[ _imageURL ]])
@[[ username ]]
/* global window document */ /* eslint-disable strict */ window.PatternLibrary = window.PatternLibrary || {}; (function(behaviors) { 'use strict'; behaviors.googleAnalytics = { properties: { /* * Name for the Google Analytics Event */ gaEventName: { type: String, value: null }, /* * Payload for the Google Analytics Event */ gaEventPayload: { type: Object, value: null } }, /** * Listeners * * @type {Object} */ listeners: { click: '_fireAnalytics' }, /** * Fires Google Analytics event */ _fireAnalytics() { if (this.gaEventName && this.gaEventPayload) { this.gaEvent(this.gaEventName, this.gaEventPayload); } }, /** * generic gaEvent wrapper * @param {String} the GA Event to trigger eg 'ga/newsletter' * @param {Object} the payload to pass to the event */ gaEvent(eventName, payload = {}) { if (window.tlm_ga && window.tlm_ga.isReady()) { this.fire(eventName, payload); } else { document.addEventListener('/ga/ready', () => { this.fire(eventName, payload); }, false); } } }; })(window.PatternLibrary.behaviors = window.PatternLibrary.behaviors || {});
[[ titleText ]]
![]()
[[ readMoreText ]] [[ readLessText ]] {{ text }}
{{ text }}[[ cookiePreferencesText ]][[ copyrightText ]]
![]()
[[ eyebrowText ]]
[[ titleText ]]

[[ user.name ]]
[[ user.email ]]
[[ titleText ]]
![[[ imageTooltip ]]]([[ backgroundImageSmallest ]])
[[ copiedText ]]{{ _currentUrl }}
[[ titleText ]]
[[ searchLabelText ]]
[[ eyebrowText ]]
[[ titleText ]]
[[ subtitleText ]]

[[ titleText ]]
[[ copyText ]]
[[ titleText ]]
[[ column.label ]][[ column.label ]]
[[ eyebrowText ]] [[ eyebrowSecondaryText ]]
[[ titleText ]]
[[ subtitleText ]]