1
0
Fork 0
fgdata/webgui/topics/Environment.js
Torsten Dreyer 4d94d42ff6 Phi: hash based single page navigation and Map tuning
with this patch, navigation with the browsers forward/backward buttons
is supported within topics and subtopics as well as deep linking into
topics using hashed urls like /gui/#Map or /gui/#Environment/Weather

Also, slightly rename map overlay layers
2015-03-04 12:16:17 +01:00

27 lines
811 B
JavaScript

define([
'knockout', 'text!./Environment.html', './SubtopicViewmodel'
], function(ko, htmlString, SubtopicViewmodel) {
ko.components.register('Environment/Date & Time', {
require : 'topics/Environment/DateTime'
});
ko.components.register('Environment/Weather', {
require : 'topics/Environment/Weather'
});
ko.components.register('Environment/Position', {
require : 'topics/Environment/Position'
});
// Return component definition
return {
viewModel : {
createViewModel : function(params, componentInfo) {
return new SubtopicViewmodel([
'Date & Time', 'Weather', 'Position',
], "Environment", params);
},
},
template : htmlString
};
});