Updated clock, timer, weather tile backgrounds

This commit is contained in:
Logan Allen 2019-06-21 15:55:48 -07:00 committed by Isaac Visintainer
parent 006e97f0c9
commit 54b918f604
3 changed files with 45 additions and 33 deletions

View File

@ -2351,7 +2351,11 @@
renderWrapper(child) {
return (
react.createElement('div', { className: "pa2 bg-dark-gray" , style: { width: outerSize, height: outerSize }, __self: this, __source: {fileName: _jsxFileName, lineNumber: 152}}
react.createElement('div', { className: "pa2", style: {
width: outerSize,
height: outerSize,
background: '#1a1a1a'
}, __self: this, __source: {fileName: _jsxFileName, lineNumber: 152}}
, child
)
);
@ -2361,7 +2365,7 @@
let data = !!this.props.data ? this.props.data : {};
return this.renderWrapper((
react.createElement(Clock, {__self: this, __source: {fileName: _jsxFileName, lineNumber: 162}})
react.createElement(Clock, {__self: this, __source: {fileName: _jsxFileName, lineNumber: 166}})
));
}

View File

@ -2505,7 +2505,11 @@
renderWrapper(child) {
return (
react.createElement('div', { className: "bg-dark-gray", style: { width: outerSize, height: outerSize }, __self: this, __source: {fileName: _jsxFileName$2, lineNumber: 206}}
react.createElement('div', { style: {
width: outerSize,
height: outerSize,
background: '#1a1a1a'
}, __self: this, __source: {fileName: _jsxFileName$2, lineNumber: 206}}
, child
)
);
@ -2518,21 +2522,21 @@
var interaction;
var interactionStyle = "link underline black hover-white";
if(this.state.mode == "running") {
interaction = react.createElement('a', { className: interactionStyle, onClick: this.stopTimer, __self: this, __source: {fileName: _jsxFileName$2, lineNumber: 219}}, "Stop");
interaction = react.createElement('a', { className: interactionStyle, onClick: this.stopTimer, __self: this, __source: {fileName: _jsxFileName$2, lineNumber: 223}}, "Stop");
}
else if(this.state.mode == "alarm") {
interaction = react.createElement('a', { className: interactionStyle, onClick: this.stopTimer, __self: this, __source: {fileName: _jsxFileName$2, lineNumber: 222}}, "Shhh");
interaction = react.createElement('a', { className: interactionStyle, onClick: this.stopTimer, __self: this, __source: {fileName: _jsxFileName$2, lineNumber: 226}}, "Shhh");
}
else {
interaction = react.createElement('a', { className: interactionStyle, onClick: this.startTimer, __self: this, __source: {fileName: _jsxFileName$2, lineNumber: 225}}, "Start");
interaction = react.createElement('a', { className: interactionStyle, onClick: this.startTimer, __self: this, __source: {fileName: _jsxFileName$2, lineNumber: 229}}, "Start");
}
return this.renderWrapper((
react.createElement('div', { style: { position: "relative",
fontFamily: "-apple-system,BlinkMacSystemFont,avenir next,avenir,helvetica neue,helvetica,ubuntu,roboto,noto,segoe ui,arial,sans-serif"
}, __self: this, __source: {fileName: _jsxFileName$2, lineNumber: 230}}
, react.createElement('canvas', { id: "timer-canvas", width: outerSize, height: outerSize, __self: this, __source: {fileName: _jsxFileName$2, lineNumber: 233}})
}, __self: this, __source: {fileName: _jsxFileName$2, lineNumber: 234}}
, react.createElement('canvas', { id: "timer-canvas", width: outerSize, height: outerSize, __self: this, __source: {fileName: _jsxFileName$2, lineNumber: 237}})
, react.createElement('div', { id: "timer-display", style: {
width: "100%",
@ -2542,15 +2546,15 @@
left: "0px",
fontSize:"28px",
fontWeight:"300"
}, __self: this, __source: {fileName: _jsxFileName$2, lineNumber: 235}}
}, __self: this, __source: {fileName: _jsxFileName$2, lineNumber: 239}}
, this.state.mode == "running" ? this.formatTime(this.state.time) :
this.state.mode == "alarm" ?
react.createElement('div', {__self: this, __source: {fileName: _jsxFileName$2, lineNumber: 246}}
, react.createElement(Flashing, {__self: this, __source: {fileName: _jsxFileName$2, lineNumber: 247}}, "00:00")
react.createElement('div', {__self: this, __source: {fileName: _jsxFileName$2, lineNumber: 250}}
, react.createElement(Flashing, {__self: this, __source: {fileName: _jsxFileName$2, lineNumber: 251}}, "00:00")
,
this.state.playSound
?
react.createElement('audio', { src: "http://maxwellsfoley.com/ding.mp3", loop: true, autoPlay: true, __self: this, __source: {fileName: _jsxFileName$2, lineNumber: 251}})
react.createElement('audio', { src: "http://maxwellsfoley.com/ding.mp3", loop: true, autoPlay: true, __self: this, __source: {fileName: _jsxFileName$2, lineNumber: 255}})
:
null
@ -2565,15 +2569,15 @@
top: "170px",
left: "0px",
fontSize:"16px"
}, __self: this, __source: {fileName: _jsxFileName$2, lineNumber: 259}}
}, __self: this, __source: {fileName: _jsxFileName$2, lineNumber: 263}}
, interaction
)
, react.createElement('div', { id: "volume-container", style: {
position: "absolute",
top: "200px",
left: "5px"
}, __self: this, __source: {fileName: _jsxFileName$2, lineNumber: 269}}
, react.createElement(VolumeIcon, { parent: this, __self: this, __source: {fileName: _jsxFileName$2, lineNumber: 274}})
}, __self: this, __source: {fileName: _jsxFileName$2, lineNumber: 273}}
, react.createElement(VolumeIcon, { parent: this, __self: this, __source: {fileName: _jsxFileName$2, lineNumber: 278}})
)
)
));

View File

@ -6852,7 +6852,11 @@
renderWrapper(child) {
return (
react.createElement('div', { className: "pa2 bg-dark-gray" , style: { width: 234, height: 234 }, __self: this, __source: {fileName: _jsxFileName, lineNumber: 48}}
react.createElement('div', { className: "pa2", style: {
width: 234,
height: 234,
background: '#1a1a1a'
}, __self: this, __source: {fileName: _jsxFileName, lineNumber: 48}}
, child
)
);
@ -6860,9 +6864,9 @@
renderNoData() {
return this.renderWrapper((
react.createElement('div', {__self: this, __source: {fileName: _jsxFileName, lineNumber: 56}}
, react.createElement('p', { className: "white sans-serif" , __self: this, __source: {fileName: _jsxFileName, lineNumber: 57}}, "Weather")
, react.createElement('button', { onClick: this.locationSubmit.bind(this), __self: this, __source: {fileName: _jsxFileName, lineNumber: 58}}, "Set location" )
react.createElement('div', {__self: this, __source: {fileName: _jsxFileName, lineNumber: 60}}
, react.createElement('p', { className: "white sans-serif" , __self: this, __source: {fileName: _jsxFileName, lineNumber: 61}}, "Weather")
, react.createElement('button', { onClick: this.locationSubmit.bind(this), __self: this, __source: {fileName: _jsxFileName, lineNumber: 62}}, "Set location" )
)
));
}
@ -6874,45 +6878,45 @@
let da = moment.unix(d.sunsetTime).format('h:mm a') || '';
return this.renderWrapper((
react.createElement('div', {__self: this, __source: {fileName: _jsxFileName, lineNumber: 70}}
, react.createElement('p', { className: "white", __self: this, __source: {fileName: _jsxFileName, lineNumber: 71}}, "Weather")
, react.createElement('div', { className: "w-100 mb2 mt2" , __self: this, __source: {fileName: _jsxFileName, lineNumber: 72}}
react.createElement('div', {__self: this, __source: {fileName: _jsxFileName, lineNumber: 74}}
, react.createElement('p', { className: "white", __self: this, __source: {fileName: _jsxFileName, lineNumber: 75}}, "Weather")
, react.createElement('div', { className: "w-100 mb2 mt2" , __self: this, __source: {fileName: _jsxFileName, lineNumber: 76}}
, react.createElement('img', {
src: '/~weather/img/' + c.icon + '.png',
width: 64,
height: 64,
className: "dib", __self: this, __source: {fileName: _jsxFileName, lineNumber: 73}} )
className: "dib", __self: this, __source: {fileName: _jsxFileName, lineNumber: 77}} )
, react.createElement('h2', {
className: "dib ml2 white" ,
style: {
fontSize: 72,
lineHeight: '64px',
fontWeight: 400
}, __self: this, __source: {fileName: _jsxFileName, lineNumber: 78}}
}, __self: this, __source: {fileName: _jsxFileName, lineNumber: 82}}
, Math.round(c.temperature), "°")
)
, react.createElement('div', { className: "w-100 cf" , __self: this, __source: {fileName: _jsxFileName, lineNumber: 87}}
, react.createElement('div', { className: "fl w-50" , __self: this, __source: {fileName: _jsxFileName, lineNumber: 88}}
, react.createElement('div', { className: "w-100 cf" , __self: this, __source: {fileName: _jsxFileName, lineNumber: 91}}
, react.createElement('div', { className: "fl w-50" , __self: this, __source: {fileName: _jsxFileName, lineNumber: 92}}
, react.createElement(IconWithData, {
icon: "winddirection",
text: c.windBearing + '°', __self: this, __source: {fileName: _jsxFileName, lineNumber: 89}} )
text: c.windBearing + '°', __self: this, __source: {fileName: _jsxFileName, lineNumber: 93}} )
, react.createElement(IconWithData, {
icon: "chancerain",
text: c.precipProbability + '%', __self: this, __source: {fileName: _jsxFileName, lineNumber: 92}} )
text: c.precipProbability + '%', __self: this, __source: {fileName: _jsxFileName, lineNumber: 96}} )
, react.createElement(IconWithData, {
icon: "windspeed",
text: Math.round(c.windSpeed) + ' mph', __self: this, __source: {fileName: _jsxFileName, lineNumber: 95}} )
text: Math.round(c.windSpeed) + ' mph', __self: this, __source: {fileName: _jsxFileName, lineNumber: 99}} )
)
, react.createElement('div', { className: "fr w-50" , __self: this, __source: {fileName: _jsxFileName, lineNumber: 99}}
, react.createElement('div', { className: "fr w-50" , __self: this, __source: {fileName: _jsxFileName, lineNumber: 103}}
, react.createElement(IconWithData, {
icon: "sunset",
text: da, __self: this, __source: {fileName: _jsxFileName, lineNumber: 100}} )
text: da, __self: this, __source: {fileName: _jsxFileName, lineNumber: 104}} )
, react.createElement(IconWithData, {
icon: "low",
text: Math.round(d.temperatureLow) + '°', __self: this, __source: {fileName: _jsxFileName, lineNumber: 103}} )
text: Math.round(d.temperatureLow) + '°', __self: this, __source: {fileName: _jsxFileName, lineNumber: 107}} )
, react.createElement(IconWithData, {
icon: "high",
text: Math.round(d.temperatureHigh) + '°', __self: this, __source: {fileName: _jsxFileName, lineNumber: 106}} )
text: Math.round(d.temperatureHigh) + '°', __self: this, __source: {fileName: _jsxFileName, lineNumber: 110}} )
)
)
)