{"id":282,"date":"2025-05-21T10:51:49","date_gmt":"2025-05-21T00:51:49","guid":{"rendered":"https:\/\/quantifyapp.com\/?page_id=282"},"modified":"2025-05-21T16:55:57","modified_gmt":"2025-05-21T06:55:57","slug":"templates","status":"publish","type":"page","link":"https:\/\/quantifyapp.com\/index.php\/templates\/","title":{"rendered":"Tap a focus habit below to get started"},"content":{"rendered":"\n<p>Tap to add it to your Habits app.<\/p>\n\n\n\n<div id=\"habits-container\">\n  <!-- Gewohnheiten werden hier dynamisch eingef\u00fcgt -->\n<\/div>\n<script>\n   const habitData = [\n    { emoji: \"\ud83d\udcd3\", name: \"Journal+10min\", situation: \"After+dinner\", reward: \"Talk+to+my+partner\" },{ emoji: \"\ud83d\udcda\", name: \"Study\", situation: \"After+breakfast\", reward: \"Have+a+treat\" },{ emoji: \"\ud83d\ude46\ud83c\udffb\u200d\u2640\ufe0f\", name: \"Stretching\", situation: \"After+waking+up\", reward: \"Have+breakfast\" },{ emoji: \"\ud83c\udf1d\", name: \"Wake+up+early\", situation: \"With+alarm\", reward: \"Have+a+nice+thought\" },{ emoji: \"\ud83d\udca6\", name: \"Skincare\", situation: \"Before+bed\", reward: \"Feel+good\" },{ emoji: \"\ud83d\udebf\", name: \"Shower\", situation: \"Before+breakfast\", reward: \"Like+that+smell\" },{ emoji: \"\ud83e\uddfc\", name: \"Face+care\", situation: \"Before+bed\", reward: \"Smile\" },{ emoji: \"\ud83e\udd6c\", name: \"Eat+Healthy\", situation: \"When+hungry\", reward: \"Feel+good\" },{ emoji: \"\ud83e\udd63\", name: \"Fast\", situation: \"The+whole+day\", reward: \"Feel+better\" },{ emoji: \"\ud83e\uddb7\", name: \"Floss\", situation: \"Before+bed\", reward: \"Feel+clean\" },{ emoji: \"\ud83d\udcaa\", name: \"Pushups\", situation: \"Before+breakfast\", reward: \"Feel+my+arms\" },{ emoji: \"\ud83d\udeb5\u200d\u2640\ufe0f\", name: \"Cardio\", situation: \"After+work\", reward: \"Feel+better\" },{ emoji: \"\ud83d\udd8b\", name: \"Write\", situation: \"After+breakfast\", reward: \"Have+a+tea\" },{ emoji: \"\ud83d\ude4f\ud83c\udffb\", name: \"Gratitude\", situation: \"Before+bedtime\", reward: \"Smile\" },{ emoji: \"\ud83e\udd51\", name: \"No+Junk+Food\", situation: \"After+5\", reward: \"Feel+better\" },{ emoji: \"\ud83d\ude80\", name: \"Situps\", situation: \"Before+dinner\", reward: \"Be+puffed\" },{ emoji: \"\ud83d\udc84\", name: \"Remove+Makeup\", situation: \"Before+bed\", reward: \"Feel+clean\" },{ emoji: \"\ud83c\udf2c\", name: \"Breathing\", situation: \"After+waking+up\", reward: \"Be+relaxed\" },{ emoji: \"\ud83e\udd84\", name: \"No+Social+Media\", situation: \"After+8\", reward: \"Be+focused\" },{ emoji: \"\ud83e\udd52\", name: \"Clean+Eating\", situation: \"All+day\", reward: \"Feel+super+healthy\" },{ emoji: \"\ud83d\udcaa\ud83c\udffd\", name: \"Crunches\", situation: \"In+lunch+break\", reward: \"Eat+favorite+lunch\" },{ emoji: \"\ud83c\udf0a\", name: \"Swim\", situation: \"Before+work\", reward: \"Eat+favorite+breakfast\" },{ emoji: \"\ud83c\udf3c\", name: \"Pray\", situation: \"Before+bed\", reward: \"Feel+graterful\" },{ emoji: \"\ud83d\udc50\", name: \"Wash+Hands\", situation: \"After+I+touched++surface\", reward: \"Feel+clean+and+safe\" }\n    ];\n  \/\/ Funktion zur Generierung eines URL-freundlichen Slugs aus dem Gewohnheitsnamen\n  function generateSlug(name, situation, reward) {\n    var string = `name=${name}&situation=${situation}&reward=${reward}`\n    return string;\n  }\n  \/\/ Funktion zur Generierung einer URL f\u00fcr eine Gewohnheit\n  function generateHabitUrl(habit) {\n    const slug = generateSlug(habit.name, habit.situation, habit.reward);\n    return `https:\/\/applinks.quantifyapp.com\/focus\/new-habit?${slug}`;\n  }\n  \/\/ Funktion zum Erstellen von HTML f\u00fcr jede Gewohnheit\n  function createHabitHtml(habit) {\n    const url = generateHabitUrl(habit);\n    return `\n      <div class=\"habit\">\n        <h2>${habit.emoji} <a href=\"${url}\">${habit.name.replace(\/\\+\/g, ' ')}<\/a><\/h2>\n        <p>${habit.name} ${habit.situation}, dann ${habit.reward.replace(\/\\+\/g, ' ')}.<br>\n        <a href=\"${url}\">In App \u00f6ffnen: ${habit.name.replace(\/\\+\/g, ' ')}<\/a><\/p>\n      <\/div>\n    `;\n  }\n  \/\/ Funktion zum Rendern aller Gewohnheiten\n  function renderHabits() {\n    const habitsContainer = document.getElementById('habits-container');\n    let habitsHtml = '';\n    \n    habitData.forEach(habit => {\n      habitsHtml += createHabitHtml(habit);\n    });\n    \n    habitsContainer.innerHTML = habitsHtml;\n  }\n  \/\/ Initialisiere die Seite\n  document.addEventListener('DOMContentLoaded', renderHabits);\n<\/script>\n\n\n\n<p><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Tap to add it to your Habits app.<\/p>\n","protected":false},"author":1,"featured_media":0,"parent":0,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"_monsterinsights_skip_tracking":false,"_monsterinsights_sitenote_active":false,"_monsterinsights_sitenote_note":"","_monsterinsights_sitenote_category":0,"footnotes":""},"_links":{"self":[{"href":"https:\/\/quantifyapp.com\/index.php\/wp-json\/wp\/v2\/pages\/282"}],"collection":[{"href":"https:\/\/quantifyapp.com\/index.php\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/quantifyapp.com\/index.php\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/quantifyapp.com\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/quantifyapp.com\/index.php\/wp-json\/wp\/v2\/comments?post=282"}],"version-history":[{"count":26,"href":"https:\/\/quantifyapp.com\/index.php\/wp-json\/wp\/v2\/pages\/282\/revisions"}],"predecessor-version":[{"id":330,"href":"https:\/\/quantifyapp.com\/index.php\/wp-json\/wp\/v2\/pages\/282\/revisions\/330"}],"wp:attachment":[{"href":"https:\/\/quantifyapp.com\/index.php\/wp-json\/wp\/v2\/media?parent=282"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}