MagicMirror Forum
    • Recent
    • Tags
    • Unsolved
    • Solved
    • MagicMirror² Repository
    • Documentation
    • 3rd-Party-Modules
    • Donate
    • Discord
    • Register
    • Login
    1. Home
    2. Plati
    A New Chapter for MagicMirror: The Community Takes the Lead
    Read the statement by Michael Teeuw here.
    P
    Offline
    • Profile
    • Following 0
    • Followers 1
    • Topics 3
    • Posts 19
    • Groups 0

    Plati

    @Plati

    3
    Reputation
    1.0k
    Profile views
    19
    Posts
    1
    Followers
    0
    Following
    Joined
    Last Online

    Plati Unfollow Follow

    Best posts made by Plati

    • RE: Calendar modification

      How to get ICAL for a Facebook calendar:

      https://www.facebook.com/help/152652248136178/

      2 different ICAL for birthdays and upcoming events :)

      Useful config part: “maximumEntries: X”

      And holidays calendars for many countries: https://www.mozilla.org/en-US/projects/calendar/holidays/

      posted in Tutorials
      P
      Plati
    • RE: MMM-syslog

      @paviro i send a pull request with adding Font Awesome :)

      Thanks to @ianperrin

      0_1473753516591_syslog-icon-4.jpg

      posted in System
      P
      Plati
    • How to use Font Awesome?

      Hello, i want make a own module. Sadly i don’t know how add Font Awesome to project.

      getStyles: function() {
      	return ["font-awesome.css"];
      },
      

      and what next?

      e.g.

      <i class="fa fa-cog"></i>
      
      posted in Development
      P
      Plati

    Latest posts made by Plati

    • RE: ipwhitelist - a lot of issues... can't connect remotely ..

      @big11 said in ipwhitelist - a lot of issues... can't connect remotely ..:

      address: “localhost”,

      Try change address: “localhost” to “0.0.0.0”

      posted in Troubleshooting
      P
      Plati
    • RE: Default calender module - two calenders in one module

      I use several calendars, want it were all in one module, but that each could set maximumEntries and / or maximumNumberOfDays

      Now my config looks like this:

      	{
      		module: 'calendar',
      		header: 'Nadchodzące święta',
      		position: 'top_left',
      		config: {
      			maximumEntries: 2,
      			fadePoint: 0.25,
      			calendars: [
      				{
      				symbol: 'calendar-o ',
      				url: 'webcal://www.mozilla.org/media/caldata/PolishHolidays.ics'
      				}
      			]
      		}
      	},
      
      	{
      		module: 'calendar',
      		header: 'Google Calendar',
      		position: 'top_left',
      		config: {
      			maximumNumberOfDays: 7,
      			calendars: [
      				{
      				symbol: 'calendar-o',
      				url: 'https://calendar.google.com/calendar/ical/XXXXXXXXXXX/basic.ics'
      				}
      			]
      		}
      	},
      
      	{
      		module: 'calendar',
      		header: 'Facebook Calendar',
      		position: 'top_left',
      		config: {
      			maximumNumberOfDays: 2,
      			fadePoint: 0.75,
      			calendars: [
      				{
      				symbol: 'calendar-o',
      				url: 'webcal://www.facebook.com/ical/u.php?uid=XXXXXXXXX'
      				},
      				{
      				symbol: 'birthday-cake',
      				url: 'webcal://www.facebook.com/ical/b.php?uid=XXXXXXXXX'
      				}
      			]
      		}
      	},
      

      And i want:

      	{
      		module: 'calendar',
      		header: 'Kalendarz',
      		position: 'top_left',
      		config: {
      			maximumEntries: 10,
      			calendars: [
      				{
      				symbol: 'calendar-o ',
      				maximumEntries: 2,
      				maximumNumberOfDays: 21,
      				url: 'webcal://www.mozilla.org/media/caldata/PolishHolidays.ics'
      				},				
      				{
      				symbol: 'calendar-o',
      				maximumNumberOfDays: 7,
      				url: 'https://calendar.google.com/calendar/ical/XXXXXXXXXXX/basic.ics'
      				},
      				{
      				maximumNumberOfDays: 2,
      				symbol: 'calendar-o',
      				url: 'webcal://www.facebook.com/ical/u.php?uid=XXXXXXXXX'
      				},
      				{
      				maximumNumberOfDays: 2,
      				symbol: 'birthday-cake',
      				url: 'webcal://www.facebook.com/ical/b.php?uid=XXXXXXXXX'
      				}
      			]
      		}
      	},
      
      posted in Troubleshooting
      P
      Plati
    • RE: MMM-syslog

      @paviro change the photo on github. I don’t know how do it.

      posted in System
      P
      Plati
    • RE: MMM-syslog

      @paviro i send a pull request with adding Font Awesome :)

      Thanks to @ianperrin

      0_1473753516591_syslog-icon-4.jpg

      posted in System
      P
      Plati
    • RE: assign a symbol to a module

      @ianperrin you are wizard :) big thank you, now it works excellent

      @dominic try delete " * " from var temperatureRegExp = /Temperature = (.*?) *C/ig;
      try it:

      var temperatureRegExp = /Temperature = (.*?) C/ig;

      posted in Troubleshooting
      P
      Plati
    • RE: assign a symbol to a module

      @ianperrin nice! I still have a lot to learn. I’m just beginning to learn JS, etc.

      Now is almost perfect:

      0_1473713998347_syslog-icon-2.jpg

      Now only center the icons and reduce the spacing between the lines.

      posted in Troubleshooting
      P
      Plati
    • RE: assign a symbol to a module

      Hi @ianperrin

      | Icon | Message | Time | should be ok

      posted in Troubleshooting
      P
      Plati
    • RE: assign a symbol to a module

      @yawns

      I need add a symbol to text (before or behind).

      Code:

      getDom: function() {
      		
      		var header = document.createElement("header");
      		var wrapper = document.createElement("div");
      		if(this.config.title !== false){
      			var title = document.createElement("header");
      			title.innerHTML = this.config.title || this.name;
      			wrapper.appendChild(title);
      		}
      		var logs = document.createElement("table");
      
      		for (var i = this.messages.length - 1; i >= 0; i--) {
      			//Create callWrapper
      			var callWrapper = document.createElement("tr");
      			callWrapper.classList.add("normal");
      
      			
      			var icon =  document.createElement("td");
      			
      			if (this.messages[i].type === "INFO"){
      				icon.className = "fa fa-info";
      			}
      			else if (this.messages[i].type === "WARNING"){
      				icon.className = "fa fa-exclamation";
      			}
      			else if (this.messages[i].type === "ERROR"){
      				icon.className = "fa fa-exclamation-triangle";
      			}
      			else {
      				icon.className = "fa fa-question";
      			}
      			
      			
      			
      			//Set caller of row
      			var caller =  document.createElement("td");
      			caller.innerHTML = "[" + this.messages[i].type + "] " + this.messages[i].message + " " + wrapper.appendChild(icon);
      			caller.classList.add("title", "small", "align-left");
      			if(this.config.types.hasOwnProperty(this.messages[i].type)){
      				caller.classList.add(this.config.types[this.messages[i].type]);
      			}
      			callWrapper.appendChild(caller);
      
      			//Set time of row
      			var time =  document.createElement("td");
      			time.innerHTML = this.config.format ? moment(this.messages[i].timestamp).format(this.config.format) : moment(this.messages[i].timestamp).fromNow();
      			time.classList.add("time", "light", "xsmall");
      			callWrapper.appendChild(time);
      
      			//Add to logs
      			logs.appendChild(callWrapper);
      		}
      		wrapper.appendChild(logs);
      		return wrapper;
      

      This is effect:0_1473698703685_syslog-icon.jpg

      What is wrong?

      posted in Troubleshooting
      P
      Plati
    • How to use Font Awesome?

      Hello, i want make a own module. Sadly i don’t know how add Font Awesome to project.

      getStyles: function() {
      	return ["font-awesome.css"];
      },
      

      and what next?

      e.g.

      <i class="fa fa-cog"></i>
      
      posted in Development
      P
      Plati
    • RE: MMM-syslog

      @paviro Nice module, it is useful with ESP8266 etc :)
      What do you think about changing the type of notifications on icons instead descriptive?
      http://fontawesome.io/icon/info/
      http://fontawesome.io/icon/exclamation/
      http://fontawesome.io/icon/exclamation-triangle/

      And adding function clear
      If we send:

      syslog?type=CLEAR&message=something
      

      and we have notice “something” then is removed

      posted in System
      P
      Plati