Vegan triple chocolate cupcakes (2024)

Home » Recipes » Desserts » Vegan triple chocolate cupcakes

Jump To Recipe 10 reviews posted Feb 11, 2019 by Jessica Hoffman

These Vegan Triple Chocolate Cupcakes are a chocolate lover’s dream come true! They start with a chocolate base, and get topped off with a chocolate buttercream, and chocolate chips!

Vegan triple chocolate cupcakes (2)

The best vegan cupcakes

In the spirit of chocolate, I bring you these vegan triple chocolate cupcakes. Light and fluffy chocolate cupcakes topped with vegan chocolate buttercream, chocolate sprinkles and chocolate chips. Because when it’s a holiday to celebrate chocolate I don’t kid around.

And seriously guys, these vegan cupcakes are the best!

The base for these cupcakes is similar to my red velvet cupcakes (also a great v-day option!) but these ones have more cocoa powder, and the addition of instant espresso (which brings out even MORE rich chocolatey flavour!)

Vegan triple chocolate cupcakes (3)

Why you’ll love this recipe

  • These vegan cupcakes are healthier than a traditional cupcake, made with Spelt flour and organic cane sugar.
  • They’re made with coconut oil and have no eggs in them, but are still super light and fluffy!
  • They’ll last 3-4 days after baking them, though you’ll probably finish them within a day 😉
  • You don’t need a stand mixer to make these cupcakes. You can make them directly in a bowl.

How to make vegan chocolate cupcakes

  1. Mix the dry ingredients together in a bowl.
  2. Mix the wet ingredients together in a bowl.
  3. Mix the wet and dry ingredients together until smooth. The batter will be a bit liquidy.
  4. Divide into a cupcake pan with liners and fill 3/4 of the way full.
  5. Bake at 350 degrees F for 17-19 minutes.
  6. To make the frosting, we mix together some icing sugar with vegan butter and more cocoa powder. (This part you’ll need a stand mixer for or hand beater.)
Vegan triple chocolate cupcakes (4)

Tips for making this recipe perfectly

  • Use high-quality cocoa powder for super delicious cupcakes.
  • Don’t skip out on the espresso and vanilla! These will enhance the flavour of the chocolate.
  • The batter will be quite liquidy. Don’t worry! The batter will set and turn into light and fluffy cupcakes in the oven.
  • Don’t overfill your cupcake mould. 3/4 of the way full is fine, otherwise you’re cupcakes may overflow.
  • You can also try topping these cupcakes with whipped coconut cream (recipe here) for a healthier alternative.
  • If you’d like to make these cupcakes gluten-free, substitute with a cup of 1-1 gluten-free flour blend. If you are using a different type of gluten-free flour blend, make sure to add in some xanthan gum so the cupcakes come out with a light and fluffy texture.
Vegan triple chocolate cupcakes (5)

More vegan desserts to try

  • Vegan Carrot Cake Cupcakes
  • Vegan Cake Batter Donuts
  • Raw Salted Caramel Slice

Print

Vegan triple chocolate cupcakes (6)

Vegan Triple Chocolate Cupcakes

5 Stars4 Stars3 Stars2 Stars1 Star4.9 from 10 reviews

  • Author: Jess
  • Prep Time: 30 minutes
  • Cook Time: 17 minutes
  • Total Time: 47 mins
  • Yield: 8 cupcakes 1x
  • Category: Dessert
  • Method: Bake
  • Cuisine: American
Print Recipe

Description

A delicious vegan cupcake recipe that features chocolate cupcake, chocolate frosting, and chocolate toppings!

Ingredients

Scale

Cupcakes

  • 3/4 cup almond milk
  • 1 tspapple cider vinegar
  • 1/3 cup coconut oil, melted
  • 1 tspvanilla extract
  • 1 cup spelt flour (can sub regular flour)
  • 2 tspinstant espresso (can sub 2 tbsp brewed espresso)
  • 3/4 cup organic cane sugar
  • 5 tbsp cocoa powder
  • 1/2 tspbaking powder
  • 3/4 tspbaking soda
  • 1/4 tsp salt

Chocolate frosting

  • 1 cup vegan butter
  • 1/2 cup cocoa powder
  • 4 cups powdered sugar
  • 1/4 cup almond milk
  • 1 tspvanilla extract
  • pinch of salt

Other

  • Sprinkles
  • Chocolate chips

Instructions

Cupcakes

  1. Preheat the oven to 350 degrees F and line a cupcake pan with cupcake liners
  2. Mix the almond milk and apple cider vinegar andset aside for 5 minutes to turn to “buttermilk.”
  3. Next, add the coconut oil and vanilla extract.
  4. Mix all the dry ingredients together in a bowl.
  5. Pour the wet ingredients into the dry ingredients and mix together until smooth.
  6. Spoon the batter into your pan, filling 3/4 of the way full.
  7. Bake for 17-19 minutes, or until a toothpick comes out clean
  8. To make the frosting, cream together the butter and cocoa powder until combined. Add the icing sugar 1 cup at a time until incorporated. Then add the vanilla and salt and beat on high until light and fluffy.
  9. Use a piping bag to pipe icing onto the cupcakes.
  10. Top with sprinkles and chocolate chips

Notes

Use high-quality cocoa powder for best results.

Don’t skip out on the espresso and vanilla! These will enhance the flavour of the chocolate.

The batter will be quite liquidy. Don’t worry, the batter will set and turn into light and fluffy cupcakes in the oven.

Don’t overfill your cupcake mould. Only fill 3/4 of the way otherwise the cupcakes can overflow.

You can also try topping these cupcakes with whipped coconut cream (recipe here) for a healthier alternative.

If you’d like to make these cupcakes gluten-free, substitute with a cup of 1-1 gluten-free flour blend. If you are using a different type of gluten-free flour blend, make sure to add in some xanthan gum so the cupcakes come out with a light and fluffy texture.

Nutrition

  • Serving Size: 1 cupcake
  • Calories: 350
  • Sugar: 35g
  • Fat: 18g
  • Saturated Fat: 13g
  • Carbohydrates: 55g
  • Fiber: 3g
  • Protein: 3g

If you tried theseVegan Triple Chocolate Cupcakesor any other recipe on the blog let me know how you liked it by leaving a comment/rating below! Be sure to follow along onPinterest,InstagramandFacebookfor even more deliciousness!


This post contains affiliate links which means I will make a small commission if you purchase through those links. I only recommend products that I know, trust and love!

Desserts Fall Gluten Free Recipes Snacks Spring Summer Vegan Vegetarian Winter

posted by Jessica Hoffman on February 11, 2019 (updated July 16, 2020)

53 Comments Leave a Comment »

« Previous PostHow to organically grow your presence on Instagram

Next Post »Carrot Cake Energy Balls

Leave a comment and rating!

53 comments on “Vegan triple chocolate cupcakes”

  1. Vegan triple chocolate cupcakes (7)

    Cher Reply

    These were the best cupcakes ever. I made them for my husband’s birthday and he was so pleased. They were easy to make and so delicious. We are chocolate lovers in my house and these did not disappoint. Thank you for a great recipe.

    • Vegan triple chocolate cupcakes (8)

      Jessica Hoffman Reply

      So happy you both loved them Cher! 🙂

  2. Vegan triple chocolate cupcakes (9)

    Julia Reply

    I love this recipe but I want to make it for my nephews fourth birthday, but I’m worried about the 2 tbsp of espresso. Will it have a big coffee taste? Do I have to add it? Could I substitute it for something else?

    • Vegan triple chocolate cupcakes (10)

      Jessica Hoffman Reply

      Hi Julia, these cupcakes don’t taste at all like coffee. But you can simply leave it out

  3. Vegan triple chocolate cupcakes (11)

    Kallie Owens Reply

    Hi! Have you made it as a cake or just cupcakes? If so, do there need to be any modifications and does it hold well?

    • Vegan triple chocolate cupcakes (12)

      Jessica Hoffman Reply

      Hi Kallie, I haven’t tested this out as a cake so I can’t say!

  4. Vegan triple chocolate cupcakes (13)

    Lauren Reply

    This is a really lovely recipe. I did modify it a bit and added coffee into the frosting instead of almond milk and added crushed peppermint on top, making peppermint mocha. It was very good and not overwhelmingly sweet. definitely will be making this again!

    • Vegan triple chocolate cupcakes (14)

      Jessica Hoffman Reply

      Thanks Luaren! Sounds delicious with some mocha frosting added 🙂

  5. Vegan triple chocolate cupcakes (15)

    Cordelia Reply

    Hi, my recipe wasn’t liquid at all and I made sure I used all the ingredients correct. Do you know what could be happening?

    • Vegan triple chocolate cupcakes (16)

      Jessica Hoffman Reply

      Hi Cordelia, If you followed the directions the batter should be rather thin. I can’t see your batter so I can’t say the texture! It’s possible that you measured the flour and added too much if your batter is thick.

  6. Vegan triple chocolate cupcakes (17)

    Melanie Pokos Reply

    Hi 🙂

    Thank you for this great recipe. I am from Austria asking myself how many grams is 1 cup? I read different online pages and it´s supposed to be between 200 and 250 grams… so now I´m confused how much I should use? I´m looking forward to your answer 🙂
    Greets and hugs from Austria

    • Vegan triple chocolate cupcakes (18)

      Jessica Hoffman Reply

      Hi Melanie, I unfortuantely cannot say since in North America we use cup measurements. I’d recommend looking up a recipe converter online to get an accurate measurement!

  7. Vegan triple chocolate cupcakes (19)

    Kait Reply

    Do you think I could add in chocolate chips?

    • Vegan triple chocolate cupcakes (20)

      Jessica Hoffman Reply

      Hi Kait, absolutely!

  8. Vegan triple chocolate cupcakes (21)

    Taylor Zadrozny Reply

    Excited to try! Can I use coconut flour or almond flour instead?

    • Vegan triple chocolate cupcakes (22)

      Jessica Hoffman Reply

      Hi Taylor, unfortunately, coconut flour and almond flour cannot be used at direct substitute to grain flours. If you like you can substitute 1/4 of the flour in the recipe for almond flour. Coconut flour is extremely absorbent and if you use it as a substitute you may end up with dry cupcakes!

  9. Vegan triple chocolate cupcakes (23)

    Gina Reply

    I almost prefer these to non-Vegan chocolate cupcakes. There’s something about the taste and how moist they are. So yummy!

    • Vegan triple chocolate cupcakes (24)

      Anna Oppermann Reply

      Music to my ears – thanks so much, Gina! I’m happy you enjoyed!

  10. Vegan triple chocolate cupcakes (25)

    Jazz Reply

    Ok disregard I forgot an ingredient sorry lol my family still loved the wrong and corrected ones lol

    • Vegan triple chocolate cupcakes (26)

      Anna Oppermann Reply

      Haha, I’m glad you figured it out! And I’m glad they enjoyed 🙂

  11. Vegan triple chocolate cupcakes (27)

    Jazz Reply

    Hi I loved the cupcakes although my batter was not runny instead it was thick. I Believe I did the ingredients just as you stated and 2x I was left with thick batter.

  12. Vegan triple chocolate cupcakes (28)

    Lisa Reply

    Hi there,
    Everyone loved these cupcakes!!! They are fantastic!

    I want to make them into a two tier cake, with vanilla icing, so I can do a unicorn theme.

    Could you tell me how long to cook the cakes? Do you have a vanilla icing recipe? (I’m about to check on your blog, but thought I would ask just in case you don’t).
    Thank you!!!

    • Vegan triple chocolate cupcakes (29)

      Jessica Hoffman Reply

      Thanks so much Lisa! So happy everyone enjoyed. I haven’t tested these cupcakes out as a cake before so I couldn’t say what the cooking time would be!

  13. Vegan triple chocolate cupcakes (30)

    Raisa Reply

    Can I get an Oh. M. G!? Wow! Yesterday was my birthday and I decided to bake these cupcakes. Honestly, when I find a blogger whom I love, I tend to stick to it. I stumbled on your blog yesterday and decided to try this recipe out for a change (after going back and forth between this and some of my favorite bloggers). I must say, I’m so glad I decided to make these because like I said: Oh. M. G! These are amazing. I brought them to my birthday dinner and my sister asked for another one. My colleagues at work today loved them too, hence why i decides to try one (i had a massive shake yesterday hence why I didn’t try it sooner haha). But had to today and I will safely and happily say that I’ll use it more often. So rich and moist (drooool)!!! I will definitely check out your other recipes. Sorry for the long review, but these cupcakes are my new favorite thing. And so easy to make.

    • Vegan triple chocolate cupcakes (31)

      Jessica Hoffman Reply

      Thank you so much Raisa, I appreciate your comment and am so glad to hear you enjoyed this recipe! 🙂

  14. Vegan triple chocolate cupcakes (32)

    Mary Reply

    These were amazing, surprisingly rich and moist. I used raw sugar but I think I need to either add more or use perhaps coconut or brown sugar next time as they weren’t sweet enough with the raw sugar. Frosting made up for it though. Also used Canola oil and Gluten free flour. Thank you.

    • Vegan triple chocolate cupcakes (33)

      Jessica Hoffman Reply

      Thanks Mary! Glad you enjoyed this recipe 🙂

  15. Vegan triple chocolate cupcakes (34)

    Se Reply

    Can you use regular flour? Is so, how much?

    • Vegan triple chocolate cupcakes (35)

      Jess Reply

      Hi there! Yes you can, the measurements would be the same amount!

  16. Vegan triple chocolate cupcakes (36)

    Vriddhi Reply

    Hi. The recipe looks very nice. I do not have apple cider vinegar with me. Can I have a substitute and without using it the cakes should be fine?

    • Vegan triple chocolate cupcakes (37)

      Jess Reply

      Hi there, you will need to use some sort of vinegar in order for the proper texture in the cupcakes. you can use white vinegar or white wine vinegar or any neutral tasting vinegar. (not balsamic vinegar.)

  17. Vegan triple chocolate cupcakes (38)

    Alyssa Winters Reply

    Hello there, chocolate cupcakes are my all time favorite and I am always looking forward to try new recipe for chocolate cupcakes, I like the recipe you shared in your blog. Thanks and keep on writing!

    • Vegan triple chocolate cupcakes (39)

      Jess Reply

      Hi Alyssa, thank you so much! So glad to hear you enjoyed the recipe 🙂

  18. Vegan triple chocolate cupcakes (40)

    Alex Reply

    This recipe looks great! However, I can’t have coconut. Could I substitute vegetable oil? Thanks!

    • Vegan triple chocolate cupcakes (41)

      Jess Reply

      Hi Alex, absolutely! Any neutral tasting oil will work just fine 🙂

  19. Vegan triple chocolate cupcakes (42)

    Jessica Reply

    I would love to try this recipe! How do you think they would they turn out if I didn’t add the espresso? I don’t handle caffeine well.

    • Vegan triple chocolate cupcakes (43)

      Jess Reply

      Hi Jessica, absolutely! You can just leave out that ingredient 🙂

  20. Vegan triple chocolate cupcakes (44)

    Ben Reply

    Best vegan cupcakes! so good!

    • Vegan triple chocolate cupcakes (45)

      Jess Reply

      Thanks for the review Ben!

  21. Vegan triple chocolate cupcakes (46)

    Rita Reply

    Looks great! Making it for my family tomorrow! Quick question: I am allergic to cane sugar, which I didn’t know was even a thing until I got tested for food allergies. Would coconut sugar be a good substitute?

    Thank you for your help,

    Rita

    • Vegan triple chocolate cupcakes (47)

      Jess Reply

      Hi Rita, hope you enjoy the recipe. I think coconut sugar should work ok 🙂

    • Vegan triple chocolate cupcakes (48)

      Anelie Reply

      This recipe is delicious. Rita I use normal white sugar and it works great x

      • Vegan triple chocolate cupcakes (49)

        Jessica Hoffman Reply

        Thanks Anelie!

  22. Vegan triple chocolate cupcakes (50)

    Sarah | Well and Full Reply

    That vegan buttercream looks AMAZING Jess. These cupcakes are the perfect sweet treat!

    • Vegan triple chocolate cupcakes (51)

      Jess Reply

      Thanks so much Sarah! 🙂

  23. Vegan triple chocolate cupcakes (52)

    Sarah @ Making Thyme for Health Reply

    Valentine’s Day is definitely the BEST excuse to eat as much chocolate as we want. After seeing these beauties, I want to eat a whole lot of chocolate. Hubba hubba! 🙂

    • Vegan triple chocolate cupcakes (53)

      Jess Reply

      Right! Thanks Sarah 🙂

  24. Vegan triple chocolate cupcakes (54)

    Cassie Autumn Tran Reply

    Triple the chocolate, triple the love! Chocolate has got to be one of my favorite flavors of desserts–really anything! I love myself a delicious chocolate cupcake or a slice of cake. Personally, I love cake more, but sometimes if I just want something more convenient and cute, then cupcakes are the way to go! These vegan chocolate cupcakes would probably not last very long in my kitchen. I’d have two or even three every single day!

    • Vegan triple chocolate cupcakes (55)

      Jess Reply

      thanks Cassie! Chocolate really is the best!

  25. Vegan triple chocolate cupcakes (56)

    Luna Reply

    Would these be fine with regular flour or another gluten free flour?

    • Vegan triple chocolate cupcakes (57)

      Jess Reply

      These would work perfectly fine with regular flour!

  26. Vegan triple chocolate cupcakes (58)

    Ela Reply

    Your cupcakes look amazing, Jess! There is nothing better than chocolate for Valentine’s Day!

    • Vegan triple chocolate cupcakes (59)

      Jess Reply

      Thanks so much Ela! 🙂

Welcome! Hi, I’m Jess!

Choosing Chia is a blog all about healthy vegetarian recipes that are easy to follow, taste delicious and focus on wholesome ingredients. I started the blog after a spontaneous trip to India where I studied the practice of yoga and wellness.

More About Me

Search

Don’t miss a recipe.

Don’t miss a recipe.

Sign up for the newsletter and get new recipes delivered to your inbox, plus my top 10 recipes ebook absolutely free!

Featured In…

Vegan triple chocolate cupcakes (61)

Info

  • Home
  • About Me
  • Contact
  • Press

Browse

  • Recipes
  • Lifestyle
    • Travel
  • Shop

Reader Favorites

©2024 Choosing Chia.

  • Privacy Policy
  • Terms of Service

Design by Purr.

'),b.insertAdjacentHTML(d,e));return document.getElementById(a)};c.prototype._repeatDynamicAds=function(b){var a=[],d=this._removeRecipeCapExperiment.result&&"Recipe"===b.location?99:this.locationMaxLazySequence.get(b.location),e=b.lazy?u(d,0):0;d=b.max;var f=b.lazyMax;e=Math.max(d,0===e&&b.lazy?d+f:Math.min(Math.max(e-b.sequence+1,0),d+f));for(f=0;f

=d;a.push(y(y({},b),{sequence:g,lazy:h}))}return a};c.prototype._locationEnabled=function(b){b=this._clsOptions.enabledLocations.includes(b.location);var a=this._clsOptions.disableAds&&this._clsOptions.disableAds.all||document.body.classList.contains("adthrive-disable-all"),d=!document.body.classList.contains("adthrive-disable-content")&&!this._clsOptions.disableAds.reasons.has("content_plugin");return b&&!a&&d};return c}(),Za=function(c){function b(a,d){var e=c.call(this,a,"ClsVideoInsertion")||this;e._videoConfig=a;e._clsOptions=d;e._IN_POST_SELECTOR=".adthrive-video-player";e._WRAPPER_BAR_HEIGHT=36;e._playersAddedFromPlugin=[];d.removeVideoTitleWrapper&&(e._WRAPPER_BAR_HEIGHT=0);return e}v(b,c);b.prototype.init=function(){this._initializePlayers()};b.prototype._wrapJWPlayerWithCLS=function(a,d,e){void 0===e&&(e=0);return a.parentNode?(d=this._createGenericCLSWrapper(.5625*a.offsetWidth,d,e),a.parentNode.insertBefore(d,a),d.appendChild(a),d):null};b.prototype._createGenericCLSWrapper=function(a,d,e){var f=document.createElement("div");f.id="cls-video-container-".concat(d);f.className="adthrive";f.style.minHeight="".concat(a+e,"px");return f};b.prototype._getTitleHeight=function(a){a.innerText="Title";a.style.visibility="hidden";document.body.appendChild(a);var d=window.getComputedStyle(a),e=parseInt(d.height,10),f=parseInt(d.marginTop,10);d=parseInt(d.marginBottom,10);document.body.removeChild(a);return Math.min(e+d+f,50)};b.prototype._initializePlayers=function(){var a=document.querySelectorAll(this._IN_POST_SELECTOR);a.length&&this._initializeRelatedPlayers(a);this._shouldRunAutoplayPlayers()&&this._determineAutoplayPlayers()};b.prototype._createStationaryRelatedPlayer=function(a,d,e){var f="mobile"===this._device?[400,225]:[640,360],g=G.Video_In_Post_ClicktoPlay_SoundOn;d&&a.mediaId&&(e="".concat(a.mediaId,"_").concat(e),d=this._wrapJWPlayerWithCLS(d,e),this._playersAddedFromPlugin.push(a.mediaId),d&&this._clsOptions.setInjectedVideoSlots({playerId:a.playerId,playerName:g,playerSize:f,element:d,type:"stationaryRelated"}))};b.prototype._createStickyRelatedPlayer=function(a,d){var e="mobile"===this._device?[400,225]:[640,360],f=G.Video_Individual_Autoplay_SOff;this._stickyRelatedOnPage=!0;this._videoConfig.mobileStickyPlayerOnPage="mobile"===this._device;if(d&&a.position&&a.mediaId){var g=document.createElement("div");d.insertAdjacentElement(a.position,g);d=document.createElement("h3");d.style.margin="10px 0";d=this._getTitleHeight(d);d=this._wrapJWPlayerWithCLS(g,a.mediaId,this._WRAPPER_BAR_HEIGHT+d);this._playersAddedFromPlugin.push(a.mediaId);d&&this._clsOptions.setInjectedVideoSlots({playlistId:a.playlistId,playerId:a.playerId,playerSize:e,playerName:f,element:g,type:"stickyRelated"})}};b.prototype._createPlaylistPlayer=function(a,d){var e=a.playlistId,f="mobile"===this._device?G.Video_Coll_SOff_Smartphone:G.Video_Collapse_Autoplay_SoundOff,g="mobile"===this._device?[400,225]:[640,360];this._videoConfig.mobileStickyPlayerOnPage=!0;var h=document.createElement("div");d.insertAdjacentElement(a.position,h);d=this._wrapJWPlayerWithCLS(h,e,this._WRAPPER_BAR_HEIGHT);this._playersAddedFromPlugin.push("playlist-".concat(e));d&&this._clsOptions.setInjectedVideoSlots({playlistId:a.playlistId,playerId:a.playerId,playerSize:g,playerName:f,element:h,type:"stickyPlaylist"})};b.prototype._isVideoAllowedOnPage=function(){var a=this._clsOptions.disableAds;if(a&&a.video){var d="";a.reasons.has("video_tag")?d="video tag":a.reasons.has("video_plugin")?d="video plugin":a.reasons.has("video_page")&&(d="command queue");q.error(d?"ClsVideoInsertionMigrated":"ClsVideoInsertion","isVideoAllowedOnPage",Error("DBP: Disabled by publisher via ".concat(d||"other")));return!1}return this._clsOptions.videoDisabledFromPlugin?!1:!0};return b}(function(c){function b(a,d){var e=c.call(this)||this;e._videoConfig=a;e._component=d;e._stickyRelatedOnPage=!1;e._relatedMediaIds=[];a=void 0;void 0===a&&(a=navigator.userAgent);a=/Windows NT|Macintosh/i.test(a);e._device=a?"desktop":"mobile";e._potentialPlayerMap=e.setPotentialPlayersMap();return e}v(b,c);b.prototype.setPotentialPlayersMap=function(){var a=this._videoConfig.players||[],d=this._filterPlayerMap();a=a.filter(function(e){return"stationaryRelated"===e.type&&e.enabled});d.stationaryRelated=a;return this._potentialPlayerMap=d};b.prototype._filterPlayerMap=function(){var a=this,d=this._videoConfig.players,e={stickyRelated:[],stickyPlaylist:[],stationaryRelated:[]};return d&&d.length?d.filter(function(f){var g;return null===(g=f.devices)||void 0===g?void 0:g.includes(a._device)}).reduce(function(f,g){f[g.type]||(q.event(a._component,"constructor","Unknown Video Player Type detected",g.type),f[g.type]=[]);g.enabled&&f[g.type].push(g);return f},e):e};b.prototype._checkPlayerSelectorOnPage=function(a){var d=this;a=this._potentialPlayerMap[a].map(function(e){return{player:e,playerElement:d._getPlacementElement(e)}});return a.length?a[0]:{player:null,playerElement:null}};b.prototype._getOverrideElement=function(a,d,e){a&&d?(e=document.createElement("div"),d.insertAdjacentElement(a.position,e)):(d=this._checkPlayerSelectorOnPage("stickyPlaylist"),a=d.player,d=d.playerElement,a&&d&&(e=document.createElement("div"),d.insertAdjacentElement(a.position,e)));return e};b.prototype._shouldOverrideElement=function(a){a=a.getAttribute("override-embed");return"true"===a||"false"===a?"true"===a:this._videoConfig.relatedSettings?this._videoConfig.relatedSettings.overrideEmbedLocation:!1};b.prototype._checkPageSelector=function(a,d,e){void 0===e&&(e=[]);return a&&d&&0===e.length?("/"!==window.location.pathname&&q.event("VideoUtils","getPlacementElement",Error("PSNF: ".concat(a," does not exist on the page"))),!1):!0};b.prototype._getElementSelector=function(a,d,e){if(d&&d.length>e)return d[e];q.event("VideoUtils","getPlacementElement",Error("ESNF: ".concat(a," does not exist on the page")));return null};b.prototype._getPlacementElement=function(a){var d=a.pageSelector,e=a.elementSelector;a=a.skip;var f=da(d),g=f.valid,h=f.elements;f=S(f,["valid","elements"]);var k=ca(e),l=k.valid,p=k.elements;k=S(k,["valid","elements"]);return""===d||g?l?this._checkPageSelector(d,g,h)?this._getElementSelector(e,p,a)||null:null:(q.error("VideoUtils","getPlacementElement",Error("".concat(e," is not a valid selector")),k),null):(q.error("VideoUtils","getPlacementElement",Error("".concat(d," is not a valid selector")),f),null)};b.prototype._getEmbeddedPlayerType=function(a){(a=a.getAttribute("data-player-type"))&&"default"!==a||(a=this._videoConfig.relatedSettings?this._videoConfig.relatedSettings.defaultPlayerType:"static");this._stickyRelatedOnPage&&(a="static");return a};b.prototype._getMediaId=function(a){return(a=a.getAttribute("data-video-id"))?(this._relatedMediaIds.push(a),a):!1};b.prototype._createRelatedPlayer=function(a,d,e,f){"collapse"===d?this._createCollapsePlayer(a,e):"static"===d&&this._createStaticPlayer(a,e,f)};b.prototype._createCollapsePlayer=function(a,d){var e=this._checkPlayerSelectorOnPage("stickyRelated"),f=e.player;e=e.playerElement;var g=f?f:this._potentialPlayerMap.stationaryRelated[0];g&&g.playerId?(this._shouldOverrideElement(d)&&(d=this._getOverrideElement(f,e,d)),d=document.querySelector("#cls-video-container-".concat(a," > div"))||d,this._createStickyRelatedPlayer(y(y({},g),{mediaId:a}),d)):q.error(this._component,"_createCollapsePlayer","No video player found")};b.prototype._createStaticPlayer=function(a,d,e){this._potentialPlayerMap.stationaryRelated.length&&this._potentialPlayerMap.stationaryRelated[0].playerId?this._createStationaryRelatedPlayer(y(y({},this._potentialPlayerMap.stationaryRelated[0]),{mediaId:a}),d,e):q.error(this._component,"_createStaticPlayer","No video player found")};b.prototype._shouldRunAutoplayPlayers=function(){return this._isVideoAllowedOnPage()&&(this._potentialPlayerMap.stickyRelated.length||this._potentialPlayerMap.stickyPlaylist.length)?!0:!1};b.prototype._determineAutoplayPlayers=function(){var a=this._component,d="VideoManagerComponent"===a,e=this._config;if(this._stickyRelatedOnPage)q.event(a,"stickyRelatedOnPage",d&&{device:e&&e.context.device,isDesktop:this._device}||{});else{var f=this._checkPlayerSelectorOnPage("stickyPlaylist"),g=f.player;f=f.playerElement;g&&g.playerId&&g.playlistId&&f?this._createPlaylistPlayer(g,f):q.event(a,"noStickyPlaylist",d&&{vendor:"none",device:e&&e.context.device,isDesktop:this._device}||{})}};b.prototype._initializeRelatedPlayers=function(a){for(var d=new Map,e=0;e
Vegan triple chocolate cupcakes (2024)
Top Articles
Latest Posts
Article information

Author: Maia Crooks Jr

Last Updated:

Views: 6450

Rating: 4.2 / 5 (43 voted)

Reviews: 90% of readers found this page helpful

Author information

Name: Maia Crooks Jr

Birthday: 1997-09-21

Address: 93119 Joseph Street, Peggyfurt, NC 11582

Phone: +2983088926881

Job: Principal Design Liaison

Hobby: Web surfing, Skiing, role-playing games, Sketching, Polo, Sewing, Genealogy

Introduction: My name is Maia Crooks Jr, I am a homely, joyous, shiny, successful, hilarious, thoughtful, joyous person who loves writing and wants to share my knowledge and understanding with you.