{"version":3,"sources":["contentpages/family-trip-page.js"],"names":["$","generationsCount","length","$generations","i","$thisGeneration","eq","find","addClass","remove","show360Section","last","hide","click","is","show"],"mappings":"aAAAA,CAAC,CAAC,UAAW,IACLC,CAAAA,gBAAgB,CAAGD,CAAC,CAAC,qBAAqB,CAAC,CAACE,MAAM,CAAG,CAAC,CAD5DC,YAAW,CAAAH,CAAA,CAAA,qBAAA,CAAA,CAELG,cAAgB,CAAuB,CAAA,CAAtBH,CAAA,CAAA,uBAAsB,CAAA,CAAAE,MAAA,CAM9C,IAAAE,CAAKA,CAAC,CAAG,CAACA,CAAEA,EAACH,gBAAIA,CAAgBG,CAAEA,EAAC,CAAE,CAClC,GAAIC,CAAAA,eAAe,CAAGF,YAAaG,CAAAA,EAAGF,CAACA,CAAC,CAAA,CAGjC,CAAA,CAAAC,eAAA,CAAAE,IAAA,CAAA,6BAAA,CAAA,CAAAL,MAAA,CACTG,eACM,CAAAG,QAAA,CAAA,qBAAA,CAAA,CAENH,eACD,CAAAI,MAAA,CAAA,CAAA,CAIeC,cAAKT,EAEVG,CAAA,GAAAH,gBAAA,EACJD,CAAA,CAAA,sBAAA,CAAA,CAAAW,IAAA,CAAA,CAAA,CAAAH,QAAA,CAAA,wBAAA,CAIAR,CADCU,cAAc,EAKnBV,CAAA,CAAA,gBAAA,CAAA,CAAAY,IAAA,CAAA,CAAA,CACHZ,CAAC,CAAC,yBAI4B,CAAA,CAAAa,KAAA,CAAA,UAAA,CACtBb,CAAA,CAAA,yBAAA,CAAA,CAAAc,EAAA,CAAA,UAAA,CAAA,CACJd,CAAA,CAAA,YAAA,CAAA,CAAAY,IAAA,CAAA,CAAA,CAEHZ,CAAA,CAAA,YAAA,CAAA,CAAAe,IAAA,CAAA,CADD,CAAC,CACF,CAAC,CAAC","file":"family-trip-page.min.js","sourcesContent":["$(function() {\r\n var generationsCount = $('.js-trip-generation').length - 1;\r\n var $generations = $('.js-trip-generation');\r\n\r\n var show360Section = $('.trip-media-vr__video').length > 0;\r\n\r\n\r\n\t//find out if generation sections actually have content in them\r\n\tfor (i = 0; i <= generationsCount; i++) {\r\n\t var $thisGeneration = $generations.eq(i);\r\n\t \r\n\t\tif ($thisGeneration.find('[data-type=\"widget-zone\"]').length > 0) {\r\n //console.log(\"Generation \" + i + \" has content\")\r\n\t\t\t$thisGeneration.addClass('js-has-trip-content');\r\n\t\t} else {\r\n\t\t //console.log(\"Generation \" + i + \" has no content\");\r\n\t\t\t$thisGeneration.remove();\r\n\t\t}\r\n\r\n if (show360Section) {\r\n //put a special class on the last generation with content\r\n if (i === generationsCount) {\r\n $('.js-has-trip-content').last().addClass('trip-media--transition');\r\n }\r\n }\r\n }\r\n\r\n if (!show360Section) {\r\n $('.trip-media-vr').hide();\r\n }\r\n\r\n\r\n //Set the map interaction toggle for mobile.\r\n\t$(\"input[name=onoffswitch]\").click(function () {\r\n\t if ($(\"input[name=onoffswitch]\").is(\":checked\")) {\r\n\t $('#map-block').hide();\r\n\t } else {\r\n\t $('#map-block').show();\r\n\t //wdot.BingMaps.SinglePinMapWithInfoBox.ResetMapCenter();\r\n\t }\r\n\t});\r\n});"]}