Added tags, createdAt, updatedAt properties (#561)

* add new properties on submit theme

* New GitHub Action for updating `updatedAt`

* change rebuild_themes.py to update tags for color themes

* Adding GitHub Action for updating all theme.json files (temporary)

* Applying corrected themes.json file

* fix: forgot to commit changes

* Update theme.json metadata

* Deleting actions not needed for merge

---------

Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
This commit is contained in:
TheRealMG 2024-10-12 02:23:29 -05:00 committed by GitHub
parent 1d26f953a6
commit ab50f51b95
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
63 changed files with 1240 additions and 64 deletions

View file

@ -72,11 +72,16 @@ def main():
theme_colors_output = os.path.join(theme_folder, "chrome.css")
colors = write_colors(theme_colors_file, theme_colors_output)
if "isDarkMode" in colors:
theme_data["isDarkMode"] = colors["isDarkMode"]
if "tags" not in theme_data:
theme_data["tags"] = []
theme_data["isColorTheme"] = True
# Add 'color theme' tag if colors.json is present
theme_data["tags"].append("color theme")
# Add 'dark' tag if colors.json specifies dark mode
if "isDarkMode" in colors and colors["isDarkMode"]:
theme_data["tags"].append("dark")
themes_data[theme] = theme_data
with open(THEMES_DATA_FILE, "w") as f:
@ -106,4 +111,4 @@ def main():
if __name__ == "__main__":
main()
main()