catppuccin / palette

🎨 Soothing pastel theme to use within your projects!
https://www.npmjs.com/package/@catppuccin/palette
MIT License
457 stars 36 forks source link

Include flavour emojis as part of the `palette.json` #80

Closed sgoudham closed 6 months ago

sgoudham commented 7 months ago

The following emojis: 🌻, 🪴, 🌺 and 🌿 are tied to Latte, Frappé, Macchiato and Mocha. It'd be nice to ship them as part of the palette.json so we can pull them into the language libraries and whiskers.

Mostly raising this because I've seen the following whiskers v2 code in dark-reader and github-readme-stats:

{% for id, flavor in flavors %}
<details>
{%- if id == "latte" %}
<summary>🌻 Latte</summary>
{%- elif id == "frappe" %}
<summary>🪴 Frappé</summary>
{%- elif id == "macchiato" %}
<summary>🌺 Macchiato</summary>
{%- else %}
<summary>🌿 Mocha</summary>
{%- endif %}
...

And it'd be nice to reduce that into:

{% for id, flavor in flavors %}
<details>
<summary>{{flavor.emoji}} {{flavor.name}}</summary>
...
uncenter commented 6 months ago

The pattern you mentioned is also used in https://github.com/catppuccin/fzf. I'll make PRs at the three mentioned repositories if #81 gets merged and released :)