PageSourceSearch

https://www.ntv.co.jp/drama/js/genre_drama.js

js ntv.co.jp collected 2026-09-24 08:25:55 UTC 918 bytes, 40 lines download raw bytes

1'use strict';
2
3$(function () {
4
5  function selectPickup () {
6
7    // pickupが一件もない場合、pickupエリア非表示
8    if(!$('#pickup .genre-pickup').length) {
9      return;
10    }
11
12    var pickupArray = []; // ランダム表示用配列
13    var displayPickupIndex = 1; // 表示させるpickupのindes
14
15    $('#pickup .genre-pickup').each(function(index, element){
16      var rate = $(this).data('rate') || 1; // data-rateがなければ「1」
17      for(var i = 0; i < rate; i++) {
18        pickupArray.push(index);
19      }
20    });
21
22    var randomIndex = pickupArray[ Math.floor(Math.random() * pickupArray.length) ];
23
24    // 表示
25    $('#pickup').show();
26    $('#pickup .genre-pickup').hide();
27    $('#pickup .genre-pickup').eq(randomIndex).show();
28
29  }
30
31
32  function init () {
33
34    $('#pickup-main').load('./parts/pickup.html .genre-pickup', function(){
35      selectPickup();
36    });
37  }
38
39  init();
40});

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.