{"version":3,"sources":["ucws_blocks/ucws_trio_cta/templates/js/ucws_trio_cta.js"],"names":["$","Drupal","behaviors","ucwsTrioCTAClickable","attach","context","settings","on","undefined","this","attr","window","location","href","trioCTAs","closest","addClass","removeClass","jQuery"],"mappings":"CAAA,SAAWA,EAAGC,GACZ,aAEAA,EAAOC,UAAUC,qBAAuB,CACtCC,OAAQ,SAAUC,EAASC,GAGzBN,EAAE,qCAAqCO,GAAG,SAAS,WACdC,MAA9BR,EAAE,IAAKS,MAAMC,KAAK,UACrBC,OAAOC,SAASC,KAAOb,EAAE,IAAKS,MAAMC,KAAK,YAK7C,MAAMI,EAAWd,EAAE,kCACnBc,EAASP,GAAG,SAAS,WACnBP,EAAES,MAAMM,QAAQ,eAAeC,SAAS,eAE1CF,EAASP,GAAG,QAAQ,WAClBP,EAAES,MAAMM,QAAQ,eAAeE,YAAY,iBAnBnD,CAuBGC,OAAQjB","file":"ucws_trio_cta.js","sourcesContent":["(function ($, Drupal) {\n 'use strict';\n\n Drupal.behaviors.ucwsTrioCTAClickable = {\n attach: function (context, settings) {\n\n // Make the complete card section clickable\n $('.block.trio-cta.card .rounded-box').on('click', function () {\n if (($('a', this).attr('href')) != undefined){\n window.location.href = $('a', this).attr('href');\n }\n });\n\n // When the CTA is focused, add a focus-like outline to the entire card.\n const trioCTAs = $('.block.trio-cta.card a.btn-cta');\n trioCTAs.on('focus', function () {\n $(this).closest('.cursor-cta').addClass('focus-on');\n });\n trioCTAs.on('blur', function () {\n $(this).closest('.cursor-cta').removeClass('focus-on');\n });\n }\n };\n})(jQuery, Drupal);\n"]}