From 5ff0f3364fef13b1d6b0dd921bbef7c99904d59f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Deniz=20G=C3=B6k=C3=A7in?= Date: Wed, 4 Sep 2024 10:51:01 +0200 Subject: [PATCH] feat: add "start date" event type with emoji and color --- Code.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Code.js b/Code.js index 4278053..3cd3892 100644 --- a/Code.js +++ b/Code.js @@ -23,6 +23,7 @@ const emojiMap = { 'tamir': '🛠️', 'repair': '🛠️', 'payment': '💸', + 'start date': '🏁', 'gas and electricity': '🔌', }; @@ -95,6 +96,7 @@ function ColorEvents() { "paris 2024": /\bparis 2024\b/i, "randevu": /\brandevu\b/i, "appointment": /\bappointment\b/i, + "start date": /\bstart date\b/i, "gas and electricity": /\bgas and electricity\b/i, "tamir": /\btamir\b/i, "repair": /\brepair\b/i, @@ -123,7 +125,7 @@ function ColorEvents() { } else if (regexMap["paris 2024"].test(lowerTitle)) { color = CalendarApp.EventColor.BLUE; Logger.log("Title: " + title + " - Color to print: BLUE"); - } else if (regexMap["randevu"].test(lowerTitle) || regexMap["appointment"].test(lowerTitle) || regexMap["gas and electricity"].test(lowerTitle)) { + } else if (regexMap["randevu"].test(lowerTitle) || regexMap["appointment"].test(lowerTitle) || regexMap["gas and electricity"].test(lowerTitle) || regexMap["start date"].test(lowerTitle)) { color = CalendarApp.EventColor.GRAY; Logger.log("Title: " + title + " - Color to print: GRAY"); } else if (regexMap["tamir"].test(lowerTitle) || regexMap["repair"].test(lowerTitle)) {