1
0
mirror of https://github.com/bitwarden/browser.git synced 2024-10-09 05:57:40 +02:00
bitwarden-browser/apps/web/src/scss/buttons.scss
Oscar Hinton 38d8fbdb5a
Vertical Vault Navigation (#6957)
* WIP admin console layout

* Update icons

* Migrate more things

* Migrate the last pages

* Move header to web

* Fix story not working

* Convert header component to standalone

* Migrate org layout to standalone

* Enable org switcher

* Add AC to product switcher

* Migrate provider portal to vertical nav

* Migrate PM

* Prettier fixes

* Change AC and PP to use secondary variant layout & update logos

* Remove full width setting

* Remove commented code

* Add header to report pages

* Add provider portal banner

* Fix banner for billing pages

* Move vault title to header

* Prevent scrollbar jumping

* Move send button to header

* Replace search input with bit-search

* Remove unused files and css

* Add banner

* Tweak storage option

* Fix duplicate nav item after merge

* Migrate banner state to state provider framework

* [AC-2078] Fix device approvals header

* [PM-5861] Hide AC from product switcher for users that do not have access

* [PM-5860] Fix Vault and Send page headers

* [AC-2075] Fix missing link on reporting nav group

* [AC-2079] Hide Payment Method and Billing History pages for self-hosted instances

* [AC-2090] Hide reports/event log nav items for users that do not have permission

* [AC-2092] Fix missing provider portal option in product switcher on page load

* Add null check for organization in org layout component

* [AC-2094] Fix missing page header for new client orgs page

* [AC-2093] Update New client button styling

* Fix failing test after merge

* [PM-2087] Use disk-local for web layout banner

* [PM-6041] Update banner copy to read "web app"

* [PM-6094] Update banner link to marketing URL

* [PM-6114] add CL container component to VVR pages (#7802)

* create bit-container component

* add container to all page components

* Fix linting errors after merge with main

* Fix product switcher stories

* Fix web-header stories

* mock org state properly in product switcher stories (#7956)

* refactor: move web layout migration banner logic into a service (#7958)

* make CL codeowner of web header files

* move migration banner logic to service; update stories

* [PM-5862] Ensure a sync has run before hiding navigation links

* Remove leftover banner global state

* Re-add dropped selfHosted ngIf

* Add rel noreferrer

* Remove comment

---------

Co-authored-by: Shane Melton <smelton@bitwarden.com>
Co-authored-by: Will Martin <contact@willmartian.com>
2024-02-23 09:22:45 -08:00

202 lines
4.4 KiB
SCSS

.btn-primary {
@include themify($themes) {
background-color: themed("btnPrimary");
border-color: themed("btnPrimary");
color: themed("btnPrimaryText");
}
&:hover:not(:disabled),
&:active:not(:disabled) {
@include themify($themes) {
background-color: themed("btnPrimaryHover");
border-color: themed("btnPrimaryBorderHover");
color: themed("btnPrimaryText");
}
}
&:disabled {
opacity: 0.65;
}
}
.btn-outline-primary {
@include themify($themes) {
background-color: themed("btnOutlinePrimaryBackground");
border-color: themed("btnOutlinePrimaryBorder");
color: themed("btnOutlinePrimaryText");
}
&:hover:not(:disabled),
&:active {
@include themify($themes) {
background-color: themed("btnOutlinePrimaryBackgroundHover");
border-color: themed("btnOutlinePrimaryBorderHover");
color: themed("btnOutlinePrimaryTextHover");
}
}
}
.btn-secondary {
@include themify($themes) {
background-color: themed("btnSecondary");
border-color: themed("btnSecondaryBorder");
color: themed("btnSecondaryText");
}
&:hover:not(:disabled),
&:active:not(:disabled) {
@include themify($themes) {
background-color: themed("btnSecondaryHover");
border-color: themed("btnSecondaryBorderHover");
color: themed("btnSecondaryTextHover");
}
}
&:disabled {
opacity: 0.65;
}
&:focus,
&.focus {
@include themify($themes) {
box-shadow: 0 0 0 $btn-focus-width
rgba(mix(color-yiq(themed("primary")), themed("primary"), 15%), 0.5);
}
}
}
.btn-outline-secondary {
@include themify($themes) {
background-color: themed("btnOutlineSecondaryBackground");
border-color: themed("btnOutlineSecondaryBorder");
color: themed("btnOutlineSecondaryText");
}
&:hover:not(:disabled),
&:active {
@include themify($themes) {
background-color: themed("btnOutlineSecondaryBackgroundHover");
border-color: themed("btnOutlineSecondaryBorderHover");
color: themed("btnOutlineSecondaryTextHover");
}
}
}
.show > .btn-outline-secondary {
&.dropdown-toggle,
&:focus {
@include themify($themes) {
background-color: themed("btnOutlineSecondaryBackground");
border-color: themed("btnOutlineSecondaryBorder");
color: themed("btnOutlineSecondaryText");
}
}
&:hover {
@include themify($themes) {
background-color: themed("btnOutlineSecondaryBackgroundHover");
border-color: themed("btnOutlineSecondaryBorderHover");
color: themed("btnOutlineSecondaryTextHover");
}
}
}
.btn-danger {
@include themify($themes) {
background-color: themed("btnDanger");
border-color: themed("btnDanger");
color: themed("btnDangerText");
}
&:hover:not(:disabled),
&:active:not(:disabled) {
@include themify($themes) {
background-color: themed("btnDangerHover");
border-color: themed("btnDangerHover");
color: themed("btnDangerText");
}
}
}
.btn-outline-danger {
@include themify($themes) {
background-color: themed("btnOutlineDangerBackground");
border-color: themed("btnOutlineDangerBorder");
color: themed("btnOutlineDangerText");
}
&:hover:not(:disabled),
&:active {
@include themify($themes) {
background-color: themed("btnOutlineDangerBackgroundHover");
border-color: themed("btnOutlineDangerBorderHover");
color: themed("btnOutlineDangerTextHover");
}
}
}
.btn-link {
&:focus,
&.focus {
outline-color: -webkit-focus-ring-color;
outline-offset: 1px;
outline-style: auto;
outline-width: 1px;
}
&:not(.text-danger):not(.cursor-move) {
@include themify($themes) {
color: themed("btnLinkText");
}
}
&:hover:not(.text-danger):not(.cursor-move) {
@include themify($themes) {
color: themed("btnLinkTextHover");
}
}
}
.btn-submit {
position: relative;
.bwi-spinner {
align-items: center;
bottom: 0;
display: none;
justify-content: center;
left: 0;
position: absolute;
right: 0;
top: 0;
}
&:disabled:not(.manual),
&[aria-disabled="true"]:not(.manual),
&.loading {
.bwi-spinner {
display: flex;
}
span {
visibility: hidden;
}
}
}
button.no-btn {
background: transparent;
border: none;
padding: 0;
color: inherit;
overflow: hidden;
text-overflow: ellipsis;
&:hover,
&:focus {
background: transparent;
box-shadow: none;
color: inherit;
}
}