new WidgetFace(clock)
Class responsible for managing widget face updating.
Parameters:
Name | Type | Description |
---|---|---|
clock |
Clock | World Clock API. |
- Source:
Throws:
-
if any menu component is missing in the DOM.
- Type
- WorldClockError
Members
clock
Returns World Clock API.
- Source:
Methods
(private) _updateFontSizes()
Updates font size of timezone, date and time HTML components in the DOM.
Font size is relevant to the parent container of the widget.
- Source:
setDate(dateString)
Updates date HTML component in the DOM with the provided date text.
Parameters:
Name | Type | Description |
---|---|---|
dateString |
String | formatted date text. |
- Source:
setTime(timeString)
Updates time HTML component in the DOM with the provided time text.
Parameters:
Name | Type | Description |
---|---|---|
timeString |
String | formatted time text. |
- Source:
setTimezone(timezoneString)
Updates timezone HTML component in the DOM with the provided timezone text.
Parameters:
Name | Type | Description |
---|---|---|
timezoneString |
String | timezone text. |
- Source: