Teaches the widget to disappear when the window changes from wide to
narrow, and reappear when it changes from narrow to wide.
};
+// Utility function for all widgets that want to hide in narrow windows
+widget.hideWhenNarrow = function(widget) {
+ widget.team.queue("resize-narrow").subscribe(function(n) {
+ $(widget.node).hide();
+ });
+ widget.team.queue("resize-wide").subscribe(function(n) {
+ $(widget.node).show();
+ });
+};
+
+