PageSourceSearch

https://mysite-ai.jp/wp/wp-content/themes/kodensha_202602/js/features/seo-fadein.js?ver=2026.02.23.1006

js mysite-ai.jp collected 2026-10-04 08:58:45 UTC 1,534 bytes, 59 lines download raw bytes

1/**
2 * Scroll-triggered fade-in for features page
3 * - SEO panel: fade up
4 * - Core features: media first, then content (via CSS delay)
5 */
6(function () {
7  var panel = document.querySelector('.features-for-seo__panel');
8  var featureItems = document.querySelectorAll('.features-item');
9  if (!panel && !featureItems.length) return;
10
11  var revealPanel = function () {
12    if (panel) panel.classList.add('is-visible');
13  };
14
15  var revealAllItems = function () {
16    featureItems.forEach(function (item) {
17      item.classList.add('is-visible');
18    });
19  };
20
21  if (!('IntersectionObserver' in window)) {
22    revealPanel();
23    revealAllItems();
24    return;
25  }
26
27  if (panel) {
28    var panelObserver = new IntersectionObserver(
29      function (entries) {
30        entries.forEach(function (entry) {
31          if (!entry.isIntersecting) return;
32          revealPanel();
33          panelObserver.unobserve(entry.target);
34        });
35      },
36      { threshold: 0.45 }
37    );
38
39    panelObserver.observe(panel);
40  }
41
42  if (featureItems.length) {
43    var itemObserver = new IntersectionObserver(
44      function (entries) {
45        entries.forEach(function (entry) {
46          if (!entry.isIntersecting) return;
47          entry.target.classList.add('is-visible');
48          itemObserver.unobserve(entry.target);
49        });
50      },
51      { threshold: 0.45 }
52    );
53
54    featureItems.forEach(function (item, index) {
55      if (index === 0) return; // Feature01 は初期表示のため除外
56      itemObserver.observe(item);
57    });
58  }
59})();

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.