Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Create separate css classes for breakfast and lunch to allow separate styling #10

Open
wants to merge 5 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion MMM-TitanSchoolMealMenu.css
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
font-weight: 700;
}

.MMM-TitanSchoolMealMenu .meal-description {
.MMM-TitanSchoolMealMenu .breakfast-description, .MMM-TitanSchoolMealMenu .lunch-description {
font-weight: 300;
}

Expand Down
4 changes: 2 additions & 2 deletions MMM-TitanSchoolMealMenu.js
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,7 @@ Module.register("MMM-TitanSchoolMealMenu", {
breakfastMenuRecipes.innerHTML = dayMenu.breakfast ?? "none";
breakfastMenuRecipes.className = "meal-recipes";

breakfastMenuList.className = "meal-description";
breakfastMenuList.className = "breakfast-description";
breakfastMenuList.appendChild(breakfastMenuItems);
breakfastMenuItems.appendChild(breakfastMenuTitle);
breakfastMenuItems.appendChild(breakfastMenuRecipes);
Expand All @@ -150,7 +150,7 @@ Module.register("MMM-TitanSchoolMealMenu", {
lunchMenuRecipes.innerHTML = dayMenu.lunch ?? "none";
lunchMenuRecipes.className = "meal-recipes";

lunchMenuList.className = "meal-description";
lunchMenuList.className = "lunch-description";
lunchMenuList.appendChild(lunchMenuItems);
lunchMenuItems.appendChild(lunchMenuTitle);
lunchMenuItems.appendChild(lunchMenuRecipes);
Expand Down
18 changes: 18 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,25 @@ A module for the MagicMirror framework that retrieves a school meal menu from th

![Screenshot](./docs/screenshot.png)

## Installation

```bash
cd ~/MagicMirror/modules
git clone https://github.com/evanhsu/MMM-TitanSchoolMealMenu.git
```

## Updating

```bash
cd ~/MagicMirror/modules/MMM-TitanSchoolMealMenu
git pull
```

## Usage

Add this to your MagicMirror `config.js`:

```js
{
module: "MMM-TitanSchoolMealMenu",
position: "top_left",
Expand All @@ -32,9 +47,11 @@ Add this to your MagicMirror `config.js`:
debug: false // Optional: boolean; Default: false; Setting this to true will output verbose logs
},
},
```

You can also track multiple school menus by listing the module multiple times in your `config.js` file (each config will probably have a different `buildingId`/`districtId`):

```js
{
module: "MMM-TitanSchoolMealMenu",
position: "top_right",
Expand All @@ -53,6 +70,7 @@ You can also track multiple school menus by listing the module multiple times in
districtId: "93f76ff0-2eb7-eb11-a2c4-e816644282bd",
}
},
```

![Multiple Schools](./docs/multiple-schools.png)

Expand Down