From 3a42ce954527b2da2827dded822f8f2970288894 Mon Sep 17 00:00:00 2001 From: Valentin Gagarin Date: Thu, 16 Feb 2023 10:18:09 +0100 Subject: [PATCH] move programs to the top of the metadata display (#620) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * move programs to the top of the metadata display rename to "programs provided", since where they are provided is an implementation detail irrelevant to users of `nix-shell -p`. * Fix CSS --------- Co-authored-by: Naïm Favier --- frontend/src/Page/Packages.elm | 4 ++-- frontend/src/index.scss | 6 +++++- 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/frontend/src/Page/Packages.elm b/frontend/src/Page/Packages.elm index dad3325..6163da7 100644 --- a/frontend/src/Page/Packages.elm +++ b/frontend/src/Page/Packages.elm @@ -504,7 +504,7 @@ viewResultItem nixosChannels channel showInstallDetails show item = programs = div [] - [ h4 [] [ text "Programs in ", code [] [ text "/bin" ] ] + [ h4 [] [ text "Programs provided" ] , if List.isEmpty item.source.programs then p [] [ text "This package provides no programs." ] @@ -733,8 +733,8 @@ viewResultItem nixosChannels channel showInstallDetails show item = <| Maybe.map Tuple.first item.source.flakeUrl ] - :: maintainersAndPlatforms :: programs + :: maintainersAndPlatforms :: [] ) ] diff --git a/frontend/src/index.scss b/frontend/src/index.scss index 7580235..bff1996 100644 --- a/frontend/src/index.scss +++ b/frontend/src/index.scss @@ -423,8 +423,12 @@ header .navbar.navbar-static-top { } - // maintainers and platforms + // programs & > :nth-child(3) { + } + + // maintainers and platforms + & > :nth-child(4) { margin-top: 1em; display: grid; grid-template-columns: auto auto;