~launchpad-pqm/launchpad/devel

« back to all changes in this revision

Viewing changes to lib/lp/soyuz/templates/archive-index.pt

  • Committer: Julian Edwards
  • Date: 2011-07-15 14:28:21 UTC
  • mfrom: (13444 devel)
  • mto: This revision was merged to the branch mainline in revision 13459.
  • Revision ID: julian.edwards@canonical.com-20110715142821-c1vwbppkh7szv6yk
merge devel

Show diffs side-by-side

added added

removed removed

Lines of Context:
95
95
              target="help">Read about installing</a>)
96
96
        </p>
97
97
 
98
 
        <div id="ppa-install-slide-trigger">
99
 
          <div class="widget-header">
100
 
            Technical details about this PPA
101
 
          </div>
 
98
        <div class="widget-header">
 
99
          Technical details about this PPA
102
100
        </div>
103
101
 
104
102
        <div class="widget-body">
148
146
            >Celso Providelo</a>.</p>
149
147
 
150
148
        <script type="text/javascript">
151
 
    LPS.use('node', 'event', 'lazr.effects', function(Y) {
152
 
 
153
 
    // Hide the widget body contents.
154
 
    Y.one('#ppa-install .widget-body').addClass('lazr-closed');
155
 
 
156
 
    // Ensure that the widget header uses the correct sprite icon
157
 
    // and gets the styling for javascript actions applied.
158
 
    var widget_header = Y.one('#ppa-install .widget-header');
159
 
    widget_header.addClass('sprite');
160
 
    widget_header.addClass('treeCollapsed');
161
 
    widget_header.addClass('js-action');
162
 
 
163
 
    var slide;
164
 
    function toggle_body_visibility(e) {
165
 
        if (!slide) {
166
 
            slide = Y.lazr.effects.slide_out('#ppa-install .widget-body');
167
 
            widget_header.replaceClass('treeCollapsed', 'treeExpanded');
168
 
        } else {
169
 
            slide.set('reverse', !slide.get('reverse'));
170
 
            widget_header.toggleClass('treeExpanded');
171
 
            widget_header.toggleClass('treeCollapsed');
172
 
        }
173
 
        slide.stop();
174
 
        slide.run();
175
 
    }
176
 
    Y.on('click', toggle_body_visibility,
177
 
         '#ppa-install-slide-trigger');
178
 
});
 
149
          LPS.use('lp.app.widgets.expander', function(Y) {
 
150
              var widget_header = Y.one('#ppa-install .widget-header');
 
151
              var content = Y.one('.widget-body');
 
152
              var expander = new Y.lp.app.widgets.expander.Expander(
 
153
                  widget_header, content);
 
154
              expander.setUp(true);
 
155
          });
179
156
        </script>
180
157
      </tal:is-active>
181
158