less nesting

This commit is contained in:
end-4
2024-01-29 12:06:44 +07:00
parent 1a06184ec8
commit dc5aa31732
@@ -236,8 +236,7 @@ const arr = (s, n) => {
return array;
};
const OverviewRow = ({ startWorkspace, workspaces, windowName = 'overview' }) => {
return Widget.Box({
const OverviewRow = ({ startWorkspace, workspaces, windowName = 'overview' }) => Widget.Box({
children: arr(startWorkspace, workspaces).map(Workspace),
attribute: {
update: box => {
@@ -267,12 +266,10 @@ const OverviewRow = ({ startWorkspace, workspaces, windowName = 'overview' }) =>
if (name == 'overview' && visible) box.attribute.update(box);
})
,
});
}
});
export default () => {
const overviewRevealer = Widget.Revealer({
export default () => Widget.Revealer({
revealChild: true,
transition: 'slide_down',
transitionDuration: 200,
@@ -286,6 +283,4 @@ export default () => {
})
)
}),
});
return overviewRevealer;
};
});