<?xml version="1.0" encoding="utf-8"?>
<feed xmlns="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:thr="http://purl.org/syndication/thread/1.0">
    <title>晴れ時々曇り: Calendar</title>
    <link rel="self" type="application/atom+xml" href="https://tarou.kazelog.jp/win/calendar/atom.xml" />
    <link rel="alternate" type="text/html" href="https://tarou.kazelog.jp/win/" />
    
    <id>tag:app.kazelog.jp,2003:weblog-14434</id>
    <updated>2030-12-31T15:42:00+09:00</updated>
    <subtitle>
</subtitle>
    <entry>
        <title>Calendar</title>
        <link rel="alternate" type="text/html" href="https://tarou.kazelog.jp/win/2030/12/post-9d72.html" />
        <link rel="replies" type="text/html" href="https://tarou.kazelog.jp/win/2030/12/post-9d72.html" thr:count="0" />
        <id>tag:app.kazelog.jp,2003:post-60085676</id>
        <published>2030-12-31T15:42:00+09:00</published>
        <updated>2026-09-29T15:49:48+09:00</updated>
        <summary></summary>
        <author>
            <name>tarou</name>
        </author>
        <category scheme="http://www.sixapart.com/ns/types#category" term="Calendar" />
        
        
<content type="html" xml:base="https://tarou.kazelog.jp/win/">
<![CDATA[
<div xmlns="http://www.w3.org/1999/xhtml"><!--webbot bot="HTMLMarkup" startspan --><center>
<div class="blog-force-horiz-calendar"><strong>
<script>// <![CDATA[
// 1. 訪問日・現在の日付の取得（元のロジックを維持）
now = new Date();
year = now.getYear(); if (year < 2000) year = year + 1900;
month = now.getMonth()+1;
day = now.getDate();

// &#x1F31F;先月・来月の月数を必ず「0付きの2桁（08、09など）」にしてURLを組み立て
// 先月の計算
var prevYear = year;
var prevMonth = month - 1;
if (prevMonth === 0) {
    prevMonth = 12;
    prevYear = year - 1;
}
var displayPrevMonth = (prevMonth < 10) ? "0" + prevMonth : prevMonth; // 必ず2桁にする

// 来月の計算
var nextYear = year;
var nextMonth = month + 1;
if (nextMonth === 13) {
    nextMonth = 1;
    nextYear = year + 1;
}
var displayNextMonth = (nextMonth < 10) ? "0" + nextMonth : nextMonth; // 必ず2桁にする

// &#x1F31F;ブログの正しい月別アーカイブURL形式に完全固定
var prevMonthUrl = "https://tarou.kazelog.jp/win/" + prevYear + "/" + displayPrevMonth + "/";
var nextMonthUrl = "https://tarou.kazelog.jp/win/" + nextYear + "/" + displayNextMonth + "/";

// 2. タイトル（年・月）の左右に << と >> のリンクを配置
document.write("<div class='cal-top-title'>");
document.write("  <a href='" + prevMonthUrl + "' class='cal-month-nav'>&lt;&lt;</a> "); // << リンク
document.write("  <span class='cal-month-current'>" + year + "年" + month + "月</span>");
document.write("  <a href='" + nextMonthUrl + "' class='cal-month-nav'>&gt;&gt;</a>"); // >> リンク
document.write("<div style='clear:both;'></div>");
document.write("</div>");

// 3. 今月末が何日まであるかを自動取得
lastDay = new Date(year, month, 0).getDate();

// 4. 曜日データの定義（カッコなし）
wk = new Array(
    "<font color=#FF0000>日</font>",
    "月",
    "火",
    "水",
    "木",
    "金",
    "<font color=#0000FF>土</font>"
);

// 1日〜31日までの「丸で囲まれた数字」の特殊文字リスト
var circleNumbers = [
    "", "①", "②", "③", "④", "⑤", "⑥", "⑦", "⑧", "⑨", "⑩",
    "⑪", "⑫", "⑬", "⑭", "⑮", "⑯", "⑰", "⑱", "⑲", "⑳",
    "㉑", "㉒", "㉓", "㉔", "㉕", "㉖", "㉗", "㉘", "㉙", "㉚", "㉛"
];

// 5. 【横並び固定】テーブル構造の開始を出力
document.write("<div class='cal-scroll-box'><table class='cal-table-rail'><tr>");

// 6. 1日から末日までループ処理してマスを作る
for (i = 1; i <= lastDay; i++) {
    // ループ中の日付の曜日番号(0〜6)を取得
    checkDate = new Date(year, now.getMonth(), i);
    wNum = checkDate.getDay();
    wStr = wk[wNum];

    // 曜日の色分け設定（日：赤、土：青、平日は通常）
    weekStyle = "";
    if (wNum === 0) weekStyle = " color: #FF0000;";
    if (wNum === 6) weekStyle = " color: #0000FF;";

    // 基本クラスを設定
    cellClass = "cal-normal-cell";

    // 今日（訪問日）のマスは、クラス名に「 is-today-active」を合体
    if (i === day) {
        cellClass = cellClass + " is-today-active";
    }

    // ──────────────────────────────────────────
    // 【記事のある日の設定】
    // ──────────────────────────────────────────
    var postFileName = ""; // 初期値（記事なし）

    // 2026年9月23日の個別記事ファイル名を指定
    if (year === 2026 && month === 9 && i === 23) {
        postFileName = "post-9d72.html";
    }
    // ──────────────────────────────────────────

    // 2桁の月を整形（個別記事URL用）
    var displayCurrentMonth = (month < 10) ? "0" + month : month;

    // テーブルの「横マス(td)」として1日分ずつ出力
    document.write("<td class='" + cellClass + "'>");
    
    if (postFileName !== "") {
        // ◆記事のある日：個別記事への正確な固定リンクURL
        var fullUrl = "https://tarou.kazelog.jp/win/" + year + "/" + displayCurrentMonth + "/" + postFileName;
        var dateText = circleNumbers[i]; // 「23」をきれいな「㉓」に変換
        
        document.write("  <a href='" + fullUrl + "' class='cal-cell-link'>");
        document.write("    <div class='c-txt' style='" + weekStyle + "'>" + wStr + "</div>"); // 上：曜日
        document.write("    <div class='c-num' style='color: #0055ff !important; font-size: 17px !important;'>" + dateText + "</div>"); // 下：丸囲み日付
        document.write("  </a>");
    } else {
        // ◆記事の無い日：通常の数字で表示
        document.write("  <div class='cal-cell-no-link'>");
        document.write("    <div class='c-txt' style='" + weekStyle + "'>" + wStr + "</div>"); // 上：曜日
        document.write("    <div class='c-num' style='" + weekStyle + "'>" + i + "</div>");    // 下：通常の数字日付
        document.write("  </div>");
    }
    
    document.write("</td>");
}

// 7. テーブルの終了を出力
document.write("</tr></table></div>");

// 8. ページを開いた瞬間に「今日」のマスまで自動スクロール
setTimeout(function() {
    var activeCell = document.querySelector(".is-today-active");
    var scrollBox = document.querySelector(".cal-scroll-box");
    if (activeCell && scrollBox) {
        scrollBox.scrollLeft = activeCell.offsetLeft - 30;
    }
}, 150);
// ]]&gt;</script>
</strong></div>
</center><!-- 見た目を制御する専用の設定（CSS） --></div>
]]>
</content>


    </entry>
 
</feed>
