2017-03-18 11:05:11 +00:00
|
|
|
import uuid from './uuid';
|
2017-02-18 07:37:22 +00:00
|
|
|
|
|
|
|
const home = {
|
|
|
|
left: [
|
|
|
|
'profile',
|
|
|
|
'calendar',
|
|
|
|
'rss-reader',
|
2017-03-18 15:24:43 +00:00
|
|
|
'photo-stream',
|
|
|
|
'version'
|
2017-02-18 07:37:22 +00:00
|
|
|
],
|
|
|
|
right: [
|
|
|
|
'broadcast',
|
|
|
|
'notifications',
|
|
|
|
'user-recommendation',
|
|
|
|
'donation',
|
|
|
|
'nav',
|
|
|
|
'tips'
|
|
|
|
]
|
|
|
|
};
|
|
|
|
|
2017-03-18 11:05:11 +00:00
|
|
|
export default () => {
|
2017-02-18 07:37:22 +00:00
|
|
|
const homeData = [];
|
|
|
|
|
|
|
|
home.left.forEach(widget => {
|
|
|
|
homeData.push({
|
|
|
|
name: widget,
|
|
|
|
id: uuid(),
|
|
|
|
place: 'left'
|
|
|
|
});
|
|
|
|
});
|
|
|
|
|
|
|
|
home.right.forEach(widget => {
|
|
|
|
homeData.push({
|
|
|
|
name: widget,
|
|
|
|
id: uuid(),
|
|
|
|
place: 'right'
|
|
|
|
});
|
|
|
|
});
|
|
|
|
|
|
|
|
const data = {
|
|
|
|
cache: true,
|
|
|
|
home: homeData
|
|
|
|
};
|
|
|
|
|
|
|
|
return data;
|
|
|
|
};
|