This guide will cover the basic for customising aspects of the Maps UI.
...
Expand |
---|
|
MapThe maps section is the largest view, this is where the floor plan graphic will be rendered, this section allows for users to pan up, down, left and right, as well as zoom in and out.  Select the image to view a larger version. Below is a list of the IDs and classes that can be used to modify this section #map .today/.future_day (contains map & view controls, class dependant on day selected) .leaflet-control-container .floor-button-layer .closed/.open (class depends if #panel is open or closed) #panel .closed/.open (class depends if #panel is open or closed)
|
Expand |
---|
|
BannerThe banner is found across the top of the map, this displays information such as the location displayed, the current time and date as well as any filters that are being applied.  Select the image to view a larger version. Below is a list of the IDs and classes that can be used to modify this section |
Expand |
---|
|
The menu is the leftside slide-out element, this contains the location navigation options as well as filter options. #menu .open/.closed #container-country .location-list #container-city .location-list #container-site .location-list #container-building .location-list .spacer (separater line for menu sections) #date .list-item (date header section) .selected-date (date display & picker button) #filter .list-item (filter header section) .filter #free .list-item .adv-list-action #In_progress .list-item .adv-list-action #checkin .list-item .adv-list-action #checkout .list-item .adv-list-action #rooms .list-item .adv-list-action #desks .list-item .adv-list-action #parking .list-item .adv-list-action
#container-tags .tags-list #container-equipment .equipment-list
|
Note |
---|
All Map CSS modifications need to be placed under the line /** LINE REQUIRED - CSS BELOW **/ |
...
Expand |
---|
|
Custom Marker iconsIn this example, you’ll be shown how to modify the Maps Stylesheet to achieve customised marker icon. The full CSS can be found at the bottom of this section if you would rather copy and paste this full customisation.  Default markers |  Custom markers |
Firstly, we will modify the .marker .pin element, this is controlling the drop shape of the marker.  Code Block |
---|
| .marker .pin {
border-radius: 50% 50% 50% 50%; /* sets border to complete circle */
} |
Next, we will need to adjust the position of the marker, as we no longer have the point, we’ll move the marker down slightly, this will need to be adjusted for both the current day view as well as future if being used. Code Block |
---|
| .today .marker { /* markers displayed on current day view */
margin-left: -13px !important; /* adjusts position along the x axis */
margin-top: -24px !important; /* adjusts position along the y axis */
}
.future_day .marker { /* markers displayed on future day view */
margin-left: -19px !important; /* adjusts position along the x axis */
margin-top: -30px !important; /* adjusts position along the y axis */
} |
The next step is to remove the white background in the centre and to change the icon colour to allow it to be seen against the colour background.  Code Block |
---|
| .marker .pin .dot { /* white inner section of marker */
color: #fff !important; /* sets font/icon colour to white */
background: none !important; /* removes the background white colour */
} |
The final step is to adjust the position of the text popup that appears above the marker icon.  Code Block |
---|
| .today .leaflet-popup {
margin-bottom: 0 !important; /* removes additional spacers */
bottom: 38px !important; /* sets position of popup from bottom of marker */
left: -33px !important; /* sets position on the x axis relative to marker */
} |
Below is the full CSS for customising the marker icons, this can be copied into the existing Maps Stylesheet. Code Block |
---|
| /* -- custom marker drops -- */
.marker .pin {
border-radius: 50% 50% 50% 50%;
}
.today .marker {
margin-left: -13px !important;
margin-top: -24px !important;
}
.future_day .marker {
margin-left: -22.5px !important;
margin-top: -22.5px !important;
}
.marker .pin .dot {
color: #fff !important;
background: none !important;
}
.today .leaflet-popup {
margin-bottom: 0 !important;
bottom: 38px !important;
left: -33px !important;
} |
|
...
Expand |
---|
|
Custom Text ChangesWith Maps some of the text values can be changed using the Stylesheet. These changes will require modifying the default values in the Stylesheet found above this line. /** LINE REQUIRED - CSS BELOW **/ Below is an example of the default value found in the Stylesheet. Code Block |
---|
| {
"nobookings" : "There are currently no bookings",
"allow_future": true,
"buttons" : {
"bookings" : "Bookings",
"info" : "Info",
"book" : "Book",
"extend" : "Extend",
"checkin" : "Check-in",
"checkout" : "Check-out"
},
"book" : {
"where": "Where",
"title" : "Title",
"date": "Date",
"quickbook": "Quickbook",
"start": "Start",
"end": "End"
},
"alerts" : {
"book" : {
"title" : "Creating booking",
"fail_title" : "Booking failed!",
"success_title" : "Booking created"
},
"extend" : {
"title" : "Extending booking",
"fail_title" : "Extend failed!",
"success_title" : "Extend successful"
}
}
}
/** LINE REQUIRED - CSS BELOW **/ |
Note |
---|
This section is written in JSON, this requires the correct syntaxing to work correctly. Ensure text values are written in quotes and each line ends with a common, except for the last in a section. |
In this example we will modify the Booking screen text values, as shown below. Image AddedDefault Text Values | Image AddedCustom Text Values |
The section that we’ll need to modify is “book” this controls the values for the booking popup screen. Code Block |
---|
| "book" : {
"where": "Where",
"title" : "Title",
"date": "Date",
"quickbook": "Quickbook",
"start": "Start",
"end": "End"
}, |
Below is the modified JSON, this section can be copied and pasted in replacement of the existing “book” values, if this section does not currently exist in the Stylesheet it can be added. Code Block |
---|
| "book" : {
"where": "Location",
"title" : "Subject",
"date": "Booking Date",
"quickbook": "Book Now",
"start": "Booking start time",
"end": "Booking end time"
}, |
Info |
---|
If adding as a new section ensure that the correct JSON syntax rules are followed, this section needs to be nested only one level down, this means it needs to be placed between the very first ‘{' and the very last '}’, also, if placed at the end of the nexted section remove the final comma ' , '. |
|
...