Read the statement by Michael Teeuw here.
MMM-Gas
-
Is there any way to remove the Distance column? I live in a small town and dont really need the distances on the display. I hunted around the files a little bit and didnt see anything that I could maybe edit or delete that would remove it.
Rob
-
@rob73 I haven’t tried this to see how it looks, but you may just be able to comment out a few of the lines in
MMM-Gas.js
Try commenting out the last 2 lines of this code in the getDom() function.var td5 = document.createElement("td"); td5.innerHTML = dist; TDrow.appendChild(td5); weatherTable.appendChild(TDrow);It should look like this when you’re done.
var td5 = document.createElement("td"); td5.innerHTML = dist; //TDrow.appendChild(td5); //weatherTable.appendChild(TDrow);You should also comment out this part as well.
var bjumpy = document.createElement("th"); bjumpy.setAttribute("style", "text-align:center"); bjumpy.classList.add("xsmall"); bjumpy.innerHTML = "Distance"; //xFCRow.appendChild(bjumpy); //weatherTable.appendChild(xFCRow); -
@mochman … Awesome… I followed your instructions and it worked! Thank you! I would have never figured that out on my own…
Thanks again!
Rob
-
New config option to hide or show distance column.
example config:
{ disabled: false, module: "MMM-Gas", position: "top_left", config: { zip: "14904", items: 10, typeGas: "", //premium, mid-grade, diesel, or blank for regular sortBy: "price", //distance, price distance: false //default is true, so using true just don't use distance in your config } },DO a git pull in the MagicMirror/modules/MMM-Gas dir to update!
AND a HUGE Thanks to @mochman for all the help!!!
-
Thanks. I really like this module alot. Very nice options and I love the mouse overs. Fantastic work! :thumbsup:

-
Awesome!
-
Is this still working?? It was working flawlessly for me before but i turned the MM off for like 3 months when i was doing some work around the house and when i turned it back on i do not see anything on my list of gas stations.
It just says updated at this time and date but nothing listed.
I did a git pull thinking that something might have been updated in those 3 months but nothing changed.Anyone else experiencing difficulties ???
D
-
@richland007 said in MMM-Gas:
Anyone else experiencing difficulties ???
I just did a git pull on my current installation and everything seems to be working just fine.
Have you made any modifications? Are there any errors being reported in the terminal or dev console?

-
@richland007 Do a git pull as things did change and I updated it a month ago or so.
-
I did a git pull and than an npm install insde the module but still no luck only updated on today’s date and time.
No list of gas stations nothing just that.Do we have to change anything in the module settings on the config.js file for the update??
Denis
-
This should be your config entry. Have you tried another zip code? See if this one works.
{ disabled: false, module: "MMM-Gas", position: "top center", config: { zip: "10306" } }, -
@Mykle1 Nothing solved it but a complete rm -rf and than a reinstall now it works fine
thank you
D -
:thumbsup:
-
How do you change the size of the font in the module?
-
@DDE12 custom.css, like always
look to see if it has a css file which would tell u the class names used,
then use custom.css to override those settings
-
@sdetweil There are two of them: MMM-Gas.css and MMM-Gas1.css. MMM-Gas did not seem to do anything and I was able to make some changes with MMM-Gas1 but not to the font size. Both css files have:
.MMM-Gas .xxsmall{ font-size: 12px;Changing it has no effect.
In dev mode, changing.xsmall { font-size: var(--font-size-xsmall); }from main.css does change the font size. I assume that this will affect any other module that uses the xsmall font.
Is there a way through my css to set the font size for this module only? -
@DDE12 yes, prefix the class with the module name
..modulename .xsmall { ... }this is the documented way to use custom.css
-
@sdetweil That fixed it! Thank you! Looking back, I see that the module css has .xxsmall and the font size is determined by .xsmall. My brain glossed over that extra ‘x’. Maybe’s it’s a typo in the css because changing it does not seem to affect anything?
-
@DDE12 sorry, don’t know the module…
-
I recently noticed that the MMM-Gas module is not showing/working. All of my other modules are working. I removed all the modules except MMM-Gas from config.js and disabled the default modules and am just getting a black screen. There is no Loading or Undefined message. I deleted the module and reinstalled but got the same results. MM is installed on a Raspberry Pi. Please let me know what further info I can provide or steps to take to troubleshoot further. Thank you!
Hello! It looks like you're interested in this conversation, but you don't have an account yet.
Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.
With your input, this post could be even better 💗
Register Login
