<?xml version="1.0" encoding="UTF-8" ?>
<rss version="2.0">
    <channel>
        <title>  Пермакультура   - Р2</title>
        <link>http://gs-permakultura-v-ukran.mozello.com/r2/</link>
        <description>  Пермакультура   - Р2</description>
                    <item>
                <title>Перша новина</title>
                <link>http://gs-permakultura-v-ukran.mozello.com/r2/params/post/5010349/persha-novina</link>
                <pubDate>Tue, 03 Jun 2025 14:56:00 +0000</pubDate>
                <description>&lt;p&gt;Це демо-текст, щоб продемонструвати як буде виглядати повідомлення в блозі. Видаліть цей пост і додайте свої власні повідомлення.&lt;/p&gt;&lt;hr class=&quot;moze-more-divider&quot;&gt;&lt;p&gt;&lt;/p&gt;&lt;p&gt;Lorem ipsum&amp;nbsp;&lt;/p&gt;&lt;p&gt;&lt;br&gt;&lt;/p&gt;



  &lt;meta charset=&quot;UTF-8&quot;&gt;
  &lt;title&gt;Pomodoro Розпорядок&lt;/title&gt;
  &lt;style&gt;
    body {
      font-family: sans-serif;
      padding: 20px;
      background: #f7f7f7;
    }
    textarea {
      width: 100%;
      height: 100px;
      margin-bottom: 10px;
      padding: 10px;
      font-size: 16px;
    }
    button {
      padding: 10px 20px;
      font-size: 16px;
      cursor: pointer;
      background-color: #4CAF50;
      color: white;
      border: none;
      border-radius: 5px;
    }
    button:hover {
      background-color: #45a049;
    }
    .schedule {
      margin-top: 20px;
      background: #fff;
      padding: 15px;
      border-radius: 8px;
      box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
    }
    .block {
      margin-bottom: 10px;
      font-weight: bold;
    }
  &lt;/style&gt;



  &lt;h1&gt;Мій розпорядок дня (Pomodoro)&lt;/h1&gt;
  &lt;p&gt;Введи список справ (по одному на рядок):&lt;/p&gt;
  &lt;textarea id=&quot;tasks&quot;&gt;&lt;/textarea&gt;
  &lt;br&gt;
  &lt;button onclick=&quot;generateSchedule()&quot;&gt;Створити розпорядок&lt;/button&gt;

  &lt;div class=&quot;schedule&quot; id=&quot;schedule&quot;&gt;&lt;/div&gt;

  &lt;script&gt;
    function generateSchedule() {
      const input = document.getElementById(&#039;tasks&#039;).value;
      const tasks = input.split(&#039;\n&#039;).filter(t =&gt; t.trim() !== &#039;&#039;);
      const scheduleDiv = document.getElementById(&#039;schedule&#039;);
      scheduleDiv.innerHTML = &#039;&#039;;

      const now = new Date();
      let time = now.getHours() * 60 + now.getMinutes(); // Поточний час у хвилинах

      const startTimeLabel = `${now.getHours().toString().padStart(2, &#039;0&#039;)}:${now.getMinutes().toString().padStart(2, &#039;0&#039;)}`;
      const pomodoroCount = document.createElement(&#039;div&#039;);
      pomodoroCount.className = &#039;block&#039;;
      pomodoroCount.textContent = `Початок: ${startTimeLabel}`;
      scheduleDiv.appendChild(pomodoroCount);

      tasks.forEach((task, index) =&gt; {
        // Завдання
        const hours = Math.floor(time / 60).toString().padStart(2, &#039;0&#039;);
        const minutes = (time % 60).toString().padStart(2, &#039;0&#039;);
        const timeLabel = `${hours}:${minutes}`;

        const block = document.createElement(&#039;div&#039;);
        block.className = &#039;block&#039;;
        block.textContent = `${timeLabel} — ${task} (25 хв)`;
        scheduleDiv.appendChild(block);

        time += 25;

        // Перерва
        if (index &lt; tasks.length - 1) {
          const breakLength = (index + 1) % 4 === 0 ? 15 : 5;
          const breakHours = Math.floor(time / 60).toString().padStart(2, &#039;0&#039;);
          const breakMinutes = (time % 60).toString().padStart(2, &#039;0&#039;);
          const breakLabel = `${breakHours}:${breakMinutes}`;

          const breakBlock = document.createElement(&#039;div&#039;);
          breakBlock.className = &#039;block&#039;;
          breakBlock.textContent = `${breakLabel} — перерва (${breakLength} хв)`;
          scheduleDiv.appendChild(breakBlock);

          time += breakLength;
        }
      });

      // Завершення
      const endHour = Math.floor(time / 60).toString().padStart(2, &#039;0&#039;);
      const endMin = (time % 60).toString().padStart(2, &#039;0&#039;);

      const summary = document.createElement(&#039;div&#039;);
      summary.className = &#039;block&#039;;
      summary.innerHTML = `&lt;hr&gt;Завершення о: &lt;strong&gt;${endHour}:${endMin}&lt;/strong&gt;`;
      scheduleDiv.appendChild(summary);
    }
  &lt;/script&gt;</description>
            </item>
            </channel>
</rss>