PageSourceSearch

https://www.iisd.org/themes/iisd-shared/iisd_base/assets/js/responsive-table.js?v=1

js iisd.org collected 2026-09-24 08:27:53 UTC 590 bytes, 21 lines download raw bytes

1/**
2 * Auto wrap tables in for horizontal scroll on mobile.
3 */
4(function ($, Drupal) {
5  'use strict';
6  Drupal.behaviors.responsiveTables = {
7    attach: function (context, settings) {
8      function handleTableWidths() {
9        $('.o-content-from-editor table').each(function () {
10          if (!$(this).hasClass('c-responsive-table__table')) {
11            $(this).addClass('c-responsive-table__table');
12            $(this).wrap('<div class="c-responsive-table"></div>');
13          }
14        });
15      }
16
17      // On page load.
18      handleTableWidths();
19    }
20  };
21})(jQuery, Drupal);

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.