Global Components¶
Global Components are provided by Mercury that are accessable on every page in your hub. Use the links in the navigation to learn more.
Most of these global components are accessed via the Mercury Top Bar.
Top Bar Configuration¶
Warning
This feature is currently under development. If you see this in your environment beware that some features may change in upcoming releases, and you may need to remove/re-add the Web Part after an upgrade.
Which components are visible can be set by modifying the JSON configuration file topbarconfig.json
in your Hub Site's SiteAssets
library.
When hiding components such as Announcements or Mailbox, the remaining space is occupied by the other components, evenly spaced across the width available (or the width configured).
Below is the default topbarconfig.json
deployed to your site when first installed.
{
"width": "100%",
"announcementsList": "Announcements",
"announcementsCategory": "",
"announcementsNewHours": 24,
"announcementsUpdateHours": 24,
"announcementsSite": "https://{tenantUrl}.sharepoint.com/sites/{MercuryHubSite}",
"serviceUpdatesSite": "https://{tenantUrl}.sharepoint.com/sites/{MercuryHubSite}",
"serviceUpdatesList": "Service Updates",
"serviceUpdateNewHours": 24,
"serviceUpdateUpdateHours": 24,
"singleStatusUpdate": false
}
This table describes the options that can be set:
Setting | Description |
---|---|
width |
Set to a string CSS width value to restrict the width of the entire Top Bar. |
announcementsNewHours |
Set the number of hours for how long the 'new' icon should be shown next to the announcement item. |
announcementsUpdateHours |
Set the number of hours for how long the 'update' icon should be shown next to the announcement item. |
serviceUpdateNewHours |
Set the number of hours for how long the 'new' icon should be shown next to the service update item. |
serviceUpdateUpdateHours |
Set the number of hours for how long the 'update' icon should be shown next to the service update item. |
singleStatusUpdate |
Set to true to show only one, the latest and highest Service Update on the top bar. |
Optional Configuration¶
There are other optional settings that can be set:
Setting | Description |
---|---|
announcementsList |
Specifies the name of the list to read Announcements from, for the Announcements ticker. If absent, the list will be named "Announcements" by default. |
announcementsCategory |
Specifies the Category of Announcements to be read. Other categories will be ignored. If absent, all Announcements of any category will be shown. |
announcementsSite |
Specifies the URL of the site where the Announcements list will be read from. If absent, the URL of the Hub Site will be used. |
announcementsButtonText |
Specifies the text to show in the button displayed at the bottom of the Announcements Panel. Button is only shown if the user has write access to the Announcements List, and text here is specified. |
serviceUpdatesSite |
Specifies the URL of the site where the Service Updates list will be read from. If absent, the URL of the Hub Site will be used. |
serviceUpdatesList |
Specifies the name of the list to read Service Updates from, for the Service Updates ticker. If absent, the list will be named "Service Updates" by default. |
favIcon |
Specifies the path of the Fav Icon to use for this site. This must be a .ico or a .png file located somewhere accessible by the user, such as the Site Assets library of the site. |
AppBarEditButtonText |
Specifies custom text applied to the 'Edit My Apps' button in the App Bar. Custom text will not be localized once set. |
AppBarEditPanelTitle |
Specifies a custom title in the App Bar 'Edit You Applications' Panel. Custom text will not be localized once set. |
worldClockData |
Sets the default configuration for the World Clock component. See the World Clock page for more info. |
commandBarItems |
Configures which items to show in the Command Bar. See the Command Bar page for more info. |
farsideCommandBarItems |
Configures which items to show in the far side of the Command Bar. |
disableAssociatedSitesPagesNavigation |
Disables the ability to show Pages from the Associated Sites panel. |
hideCommandBar |
Turns off the Command Bar. |
commandBarExtensions |
An array of custom extensions to load for the Command Bar. See the Mercury Developer Notes for more info. |
serviceUpdatesTickerOptions |
Ticker options for the Service Updates icon. See the Command Bar page for more info. |
announcementsTickerOptions |
Ticker options for the Announcements icon. See the Command Bar page for more info. |
connectedHubs |
An array of Hub IDs that this hub is connected to. |
associatedSitesSettings |
Display settings for Associated Sites. |
pinnedSites |
An Array of Pinned Site URLs to show in the Associated Sites panel. |
milestoneMessagesConfig |
A url and a list from where messages should be fetched. |