# Moon phase icons

**URL:** https://discourse.nodered.org/t/moon-phase-icons/25802
**Category:** General
**Created:** [30 April 2020 09:20 UTC](https://discourse.nodered.org/t/moon-phase-icons/25802 "2020-04-30T09:20:25Z")
**Posts on this page:** 20
**Page:** 1

<div class="post-metadata">

### Author: ![Paul-Reed](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/paul-reed/32/66906_2.png) [@Paul-Reed](https://discourse.nodered.org/u/Paul-Reed)
#### Post date: [30 April 2020 09:20 UTC](https://discourse.nodered.org/t/moon-phase-icons/25802/1 "2020-04-30T09:20:25Z")

</div>

If you have been [following this thread](https://discourse.nodered.org/t/simple-moon-phase-picture-for-dashboard/25695), you may be aware that I'm in the process of adding moon phase icons to `weather-icons-lite`, which would make them available as part of the dashboard core.  
However, I've hit a dilemma, because the icons portray different perceptions when the dashboard theme is changed.

This first image is with the [CSS written as PlanA](https://github.com/Paul-Reed/weather-icons-lite/blob/master/css/weather-icons-lite.css), and shows how they look in first the Light Theme, and just below, in the Dark Theme.

 ![planA](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/4/d/4d9f0bf5c31f2e6525cdb85e8bb071e9d236d483.jpeg)

However, changing the CSS to PlanB, again this is how they look, again, Light Theme first and the Dark Theme below.

 ![planB](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/4/2/421c36b6eba7c24134e771d8a40ea563da452b78.jpeg)

---

<div class="post-metadata">

### Author: ![hotNipi](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/hotnipi/32/383_2.png) [@hotNipi](https://discourse.nodered.org/u/hotNipi)
#### Post date: [30 April 2020 09:33 UTC](https://discourse.nodered.org/t/moon-phase-icons/25802/2 "2020-04-30T09:33:42Z")

</div>

In the real world the shadow is always dark.

---

<div class="post-metadata">

### Author: ![dceejay](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/dceejay/32/38_2.png) [@dceejay](https://discourse.nodered.org/u/dceejay)
#### Post date: [30 April 2020 09:35 UTC](https://discourse.nodered.org/t/moon-phase-icons/25802/3 "2020-04-30T09:35:25Z")

</div>

Yes - as this is representing a real physical thing then it shouldn't really change colour. (imho)

---

<div class="post-metadata">

### Author: ![Paul-Reed](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/paul-reed/32/66906_2.png) [@Paul-Reed](https://discourse.nodered.org/u/Paul-Reed)
#### Post date: [30 April 2020 11:11 UTC](https://discourse.nodered.org/t/moon-phase-icons/25802/4 "2020-04-30T11:11:23Z")

</div>

So we need PlanB CSS for the light theme, and PlanA CSS for the dark theme!!

We could have both CSS entries and select them by;  
`<i class="wi wi-moon-lt-wax-cres"></i>` and  
`<i class="wi wi-moon-dk-wax-cres"></i>`  
?

---

<div class="post-metadata">

### Author: ![hotNipi](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/hotnipi/32/383_2.png) [@hotNipi](https://discourse.nodered.org/u/hotNipi)
#### Post date: [30 April 2020 11:17 UTC](https://discourse.nodered.org/t/moon-phase-icons/25802/5 "2020-04-30T11:17:38Z")

</div>

May be `wi-moon-wax-cres` for light as default and `wi-moon-wax-cres-dark` for dark theme.  
Will be easier to handle if creating some dynamic stuff..

---

<div class="post-metadata">

### Author: ![Paul-Reed](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/paul-reed/32/66906_2.png) [@Paul-Reed](https://discourse.nodered.org/u/Paul-Reed)
#### Post date: [30 April 2020 11:45 UTC](https://discourse.nodered.org/t/moon-phase-icons/25802/6 "2020-04-30T11:45:12Z")

</div>

Maybe even lose the leading `wi` from wi-moon-wax-cres  
`<i class="wi moon-wax-cres-dark"></i>`  
It really serves no purpose.

---

<div class="post-metadata">

### Author: ![hotNipi](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/hotnipi/32/383_2.png) [@hotNipi](https://discourse.nodered.org/u/hotNipi)
#### Post date: [30 April 2020 11:56 UTC](https://discourse.nodered.org/t/moon-phase-icons/25802/7 "2020-04-30T11:56:13Z")

</div>

Well but all other icons from this set will still have it? Makes them somehow lonely 🌚

---

<div class="post-metadata">

### Author: ![Paul-Reed](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/paul-reed/32/66906_2.png) [@Paul-Reed](https://discourse.nodered.org/u/Paul-Reed)
#### Post date: [30 April 2020 14:34 UTC](https://discourse.nodered.org/t/moon-phase-icons/25802/8 "2020-04-30T14:34:52Z")

</div>

> [@hotNipi](#):
>
> May be `wi-moon-wax-cres` for light as default and `wi-moon-wax-cres-dark` for dark theme.

This is how they look having separate CSS entries for the dark theme;

 ![planC](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/9/2/923183bd2f55fcf94f1ca0e02641ad4bd2ebe216.jpeg)

---

<div class="post-metadata">

### Author: ![hotNipi](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/hotnipi/32/383_2.png) [@hotNipi](https://discourse.nodered.org/u/hotNipi)
#### Post date: [30 April 2020 15:28 UTC](https://discourse.nodered.org/t/moon-phase-icons/25802/9 "2020-04-30T15:28:03Z")

</div>

For me it looks correct.  
Confusing is to look them in parallel, brain is somehow trained to read monochrome graphics with some tweaking always applied and in this case it fails in weird way.

---

<div class="post-metadata">

### Author: ![Paul-Reed](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/paul-reed/32/66906_2.png) [@Paul-Reed](https://discourse.nodered.org/u/Paul-Reed)
#### Post date: [30 April 2020 18:42 UTC](https://discourse.nodered.org/t/moon-phase-icons/25802/10 "2020-04-30T18:42:43Z")

</div>

Version 1.3.1 has just been published to npm.

---

<div class="post-metadata">

### Author: ![Paul-Reed](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/paul-reed/32/66906_2.png) [@Paul-Reed](https://discourse.nodered.org/u/Paul-Reed)
#### Post date: [8 May 2020 19:58 UTC](https://discourse.nodered.org/t/moon-phase-icons/25802/11 "2020-05-08T19:58:55Z")

</div>

The moon phase icons have now been added to `node-red-dashboard` v2.22.1 and the [css mappings are listed here](https://github.com/Paul-Reed/weather-icons-lite/blob/master/css_mappings.md), and used exactly the same as the other `weather-icons-lite` icons.

---

<div class="post-metadata">

### Author: ![Dyce](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/dyce/32/19592_2.png) [@Dyce](https://discourse.nodered.org/u/Dyce)
#### Post date: [14 May 2020 07:25 UTC](https://discourse.nodered.org/t/moon-phase-icons/25802/12 "2020-05-14T07:25:46Z")

</div>

Hello,  
I'm trying to use the new icons, but they will not show up. I'm running dashboard v2.22.1. This is my code inside ui\_template node

```auto
 <span><i class="wi wi-moon-new-dark"></i></span>

```

It does not work with the default theme either (without -dark suffix). Other weather icons are working correctly. Is there something that I'm missing?

---

<div class="post-metadata">

### Author: ![hotNipi](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/hotnipi/32/383_2.png) [@hotNipi](https://discourse.nodered.org/u/hotNipi)
#### Post date: [14 May 2020 07:29 UTC](https://discourse.nodered.org/t/moon-phase-icons/25802/13 "2020-05-14T07:29:03Z")

</div>

Have you tried to clear browser cache?

---

<div class="post-metadata">

### Author: ![Dyce](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/dyce/32/19592_2.png) [@Dyce](https://discourse.nodered.org/u/Dyce)
#### Post date: [14 May 2020 08:10 UTC](https://discourse.nodered.org/t/moon-phase-icons/25802/14 "2020-05-14T08:10:49Z")

</div>

I feel ashamed I did not think of that. Thank you !

---

<div class="post-metadata">

### Author: ![parasaurolophus](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/parasaurolophus/32/18729_2.png) [@parasaurolophus](https://discourse.nodered.org/u/parasaurolophus)
#### Post date: [3 September 2020 16:26 UTC](https://discourse.nodered.org/t/moon-phase-icons/25802/15 "2020-09-03T16:26:24Z")

</div>

Moon phase icons are not working for me in Node-RED 1.1.3 with node-red-dashboard 2.23.2 running on Raspbian OS buster using NodeJS 12.18.3, viewied using Chrome running on various version of Linux and Windows.

Using a ui\_template node with the following contents I would expect to see three icons. I actually see only two, the WU and Darksky ones. (The commented-out line is what I would like to get working. The three hard-coded values are for testing.)

```auto
<div>
    <!--<i class="wi {{msg.payload}}"></i>-->
    <i class="wi wi-moon-wan-gibb"></i>
    <i class="wi wi-darksky-clear-night"></i>
    <i class="wi wi-wu-clear"></i>
</div>

```

It does not make any difference if I try the dark or light themed versions of the moon icons. I.e. I only see two icons if I use wi-moon-wan-gibb-dark in the preceding, as well.

I have tried clearing my browser cache, switching the theme back and forth between dark and light, and choosing different icon names from [https://github.com/Paul-Reed/weather-icons-lite/blob/master/css\_mappings.md](https://github.com/Paul-Reed/weather-icons-lite/blob/master/css_mappings.md). I have never seen any moon icons rendered but do see weather related ones.

---

<div class="post-metadata">

### Author: ![Paul-Reed](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/paul-reed/32/66906_2.png) [@Paul-Reed](https://discourse.nodered.org/u/Paul-Reed)
#### Post date: [3 September 2020 19:33 UTC](https://discourse.nodered.org/t/moon-phase-icons/25802/16 "2020-09-03T19:33:54Z")

</div>

Thanks for reporting @parasaurolophus  
Same issue here using latest dashboard version.  
Checking the [node-red-dashboard's css](https://github.com/node-red/node-red-dashboard/blob/master/dist/css/app.min.css#L28437&L28836) I can see that the dashboard has been built for some reason with an old version of my repo.

@dceejay the css for the moon phases is missing from your latest dashboard version.  
Does it need rebuilding?

---

<div class="post-metadata">

### Author: ![dceejay](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/dceejay/32/38_2.png) [@dceejay](https://discourse.nodered.org/u/dceejay)
#### Post date: [3 September 2020 20:38 UTC](https://discourse.nodered.org/t/moon-phase-icons/25802/17 "2020-09-03T20:38:22Z")

</div>

odd- should be pulling in v1.3.1  
but yes will need rebuild if not.

---

<div class="post-metadata">

### Author: ![dceejay](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/dceejay/32/38_2.png) [@dceejay](https://discourse.nodered.org/u/dceejay)
#### Post date: [3 September 2020 20:50 UTC](https://discourse.nodered.org/t/moon-phase-icons/25802/18 "2020-09-03T20:50:55Z")

</div>

Pushed build to master if someone wants to check (not yet on npm)

---

<div class="post-metadata">

### Author: ![Paul-Reed](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/paul-reed/32/66906_2.png) [@Paul-Reed](https://discourse.nodered.org/u/Paul-Reed)
#### Post date: [3 September 2020 21:16 UTC](https://discourse.nodered.org/t/moon-phase-icons/25802/19 "2020-09-03T21:16:09Z")

</div>

> [@dceejay](#):
>
> if someone wants to check

Yes, all good now  
Thanks

---

<div class="post-metadata">

### Author: ![Paul-Reed](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/paul-reed/32/66906_2.png) [@Paul-Reed](https://discourse.nodered.org/u/Paul-Reed)
#### Post date: [4 September 2020 09:54 UTC](https://discourse.nodered.org/t/moon-phase-icons/25802/20 "2020-09-04T09:54:53Z")

</div>

Now fixed in node-red-dashboard.  
Fixed version npm released this morning 😊
