@hashicorp/react-subnav
Version:
Displays a navigation bar, with links and a call-to-action.
37 lines (30 loc) • 673 B
CSS
/**
* Copyright (c) HashiCorp, Inc.
* SPDX-License-Identifier: MPL-2.0
*/
.root {
align-items: center;
display: flex;
justify-content: flex-end;
white-space: nowrap;
& > * + * {
/* Spaces consecutive buttons horizontally on desktop */
margin-left: 16px;
}
&.isInDropdown {
/* Allows consecutive buttons to wrap */
flex-wrap: wrap;
white-space: wrap;
& > * {
/* Forces full width so we have 1 button per line */
display: block;
width: 100%;
/* Spaces consecutive buttons vertically */
margin-left: 0;
margin-top: 16px;
&:last-of-type {
margin-bottom: 24px;
}
}
}
}