Skip to content

Commit

Permalink
refactor: move position of masonry not to be default
Browse files Browse the repository at this point in the history
  • Loading branch information
dmijatovic committed Jan 14, 2025
1 parent 4389131 commit 7b75b24
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 9 deletions.
10 changes: 5 additions & 5 deletions frontend/components/software/overview/search/ViewToggleGroup.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// SPDX-FileCopyrightText: 2023 Dusan Mijatovic (Netherlands eScience Center)
// SPDX-FileCopyrightText: 2023 - 2025 Dusan Mijatovic (Netherlands eScience Center)
// SPDX-FileCopyrightText: 2023 - 2025 Netherlands eScience Center
// SPDX-FileCopyrightText: 2023 Dusan Mijatovic (dv4all)
// SPDX-FileCopyrightText: 2023 Netherlands eScience Center
// SPDX-FileCopyrightText: 2023 dv4all
//
// SPDX-License-Identifier: Apache-2.0
Expand Down Expand Up @@ -31,15 +31,15 @@ export default function ViewToggleGroup({layout,onSetView}:ViewToggleGroupProps)
backgroundColor: 'background.paper',
}}
>
<ToggleButton value="masonry" aria-label="masonry">
<ViewQuiltIcon />
</ToggleButton>
<ToggleButton value="grid" aria-label="grid">
<ViewModuleIcon />
</ToggleButton>
<ToggleButton value="list" aria-label="list">
<ViewListIcon />
</ToggleButton>
<ToggleButton value="masonry" aria-label="masonry">
<ViewQuiltIcon />
</ToggleButton>
</ToggleButtonGroup>
)
}
8 changes: 4 additions & 4 deletions frontend/pages/software/index.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
// SPDX-FileCopyrightText: 2023 - 2024 Dusan Mijatovic (Netherlands eScience Center)
// SPDX-FileCopyrightText: 2023 - 2024 Netherlands eScience Center
// SPDX-FileCopyrightText: 2023 - 2025 Dusan Mijatovic (Netherlands eScience Center)
// SPDX-FileCopyrightText: 2023 - 2025 Netherlands eScience Center
// SPDX-FileCopyrightText: 2023 Dusan Mijatovic (dv4all)
// SPDX-FileCopyrightText: 2023 dv4all
// SPDX-FileCopyrightText: 2024 Christian Meeßen (GFZ) <[email protected]>
Expand Down Expand Up @@ -90,8 +90,8 @@ export default function SoftwareOverviewPage({
const {createUrl} = useSoftwareOverviewParams()
const {setPageLayout} = useUserSettings()
const [modal,setModal] = useState(false)
// if no layout - default is masonry
const initView = layout ?? 'masonry'
// if no layout - default is grid
const initView = layout ?? 'grid'
const [view, setView] = useState<LayoutType>(initView)
const numPages = Math.ceil(count / rows)
const filterCnt = getFilterCount()
Expand Down

0 comments on commit 7b75b24

Please sign in to comment.