Im looking at nesting @each loops but for the nested version i want to take a value form the parent @each, See below
$team-rooms-color: (
lightBlue: #29B0CE,
red: #D13B3B,
purple: #A365C9,
darkBlue: #3B77D1,
orange: #F19B00,
yellow: #E2CE17,
green: #86C61E,
turquoise: #12D2BB
);
$team-rooms-color--lightBlue: (
1: #29B0CE,
2: #D13B3B,
3: #A365C9,
4: #3B77D1,
5: #F19B00,
6: #E2CE17,
7: #86C61E,
8: #12D2BB,
9: #ff00ff,
10: #323232
);
@each $name, $value in $team-rooms-color {
// CSS Goes HERE
@each $name, $value in $team-rooms-color--#{$name} {
&--highlighted-#{$name} {
background-color: $value;
}
}
}
So what I want to do is loop through "team-rooms-color" and within there use the name to then loops through "team-rooms-color--lightBlue"
The line im looking at that doesnt seem to be working is @each $name, $value in $team-rooms-color--#{$name}