]> git.ipfire.org Git - thirdparty/foundation/foundation-sites.git/commitdiff
Include tabs in mutation triggers
authorCorey Snyder <corey@tangerineindustries.com>
Thu, 18 Aug 2016 19:05:47 +0000 (15:05 -0400)
committerCorey Snyder <corey@tangerineindustries.com>
Thu, 18 Aug 2016 19:05:47 +0000 (15:05 -0400)
Tabs itself has no need to listen for mutation events, but it’s content
might. Trigger a mutation event to it’s listening children after the
tabs change.

js/foundation.tabs.js

index 9794796314bb90056f774ad095133c71211c7bbc..e7926a16bb0412e128e0e0ced6a57cab9f9f13cf 100644 (file)
@@ -207,6 +207,9 @@ class Tabs {
      * @event Tabs#change
      */
     this.$element.trigger('change.zf.tabs', [$target]);
+       
+       //fire to children a mutation event
+       $targetContent.find("[data-mutate]").trigger("mutateme.zf.trigger");
   }
 
   /**