Skip to content

Commit

Permalink
Merge pull request #26 from KTH/fix/small-missing-bits
Browse files Browse the repository at this point in the history
Put back styles for buttons
  • Loading branch information
exacs authored Apr 10, 2024
2 parents 2c9d1a6 + 564e2c7 commit d391184
Show file tree
Hide file tree
Showing 2 changed files with 103 additions and 0 deletions.
102 changes: 102 additions & 0 deletions public/sass/bootstrap-overrides/_buttons.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,102 @@
// Button style
%icon-general-style {
content: '';
height: 1.2em;
width: 1.5em;
display: inline-block;
}

%table-info-icon-for-popup {
height: 1.2em;
width: 1.2em;
border: solid 0.8px $white;
filter: grayscale(1) brightness(88%) contrast(2);
&:focus,
&:hover {
border: solid 0.8px $white;
outline: 0;
filter: grayscale(1) brightness(90%) contrast(2);
}
}

@layer kth-style.old {
.external-link::after {
@extend %icon-general-style;
height: 1.25rem;
width: 1.3rem;
background: $data-open-window-blue-svg no-repeat;
background-size: 1.25rem 1.25rem;
margin: 0 0 -4px 10px;
}

.pdf-link {
margin: 0;
@media (min-width: 768px) {
margin: 0 1.5em 0 1em;
}
&:before {
@extend %icon-general-style;
background: $data-pdf-blue-svg no-repeat;
height: 1.25rem;
margin: 0 0.625rem 0.3rem 0;
width: 1rem;
vertical-align: middle;
}
}

.pdf-post-link {
margin: 0;

&:after {
@extend %icon-general-style;
background: $data-pdf-blue-svg no-repeat;
height: 1.25rem;
width: 1rem;
margin: 0 0 0.3rem 0.625em;
vertical-align: middle;
}
}

.btn-info-modal {
//change secondary to primary
background: $data-open-modal-blue-svg no-repeat;
background-color: transparent;
background-size: contain;
border: transparent;
border-radius: 0.8em;
margin-left: 1em;
width: 1.3em;
height: 1.3em;
padding: 0;
vertical-align: baseline;
}

th > button.btn-info-modal,
td > button.btn-info-modal,
td > span > button.btn-info-modal {
@extend %table-info-icon-for-popup;
margin-left: 0;
vertical-align: middle;
}

.btn-upload-file {
//FileInput in kth-style-react-components
display: flex;
flex-direction: column;
input[type='file'] {
filter: alpha(opacity=0);
opacity: 0;
border: 0;
}
span {
margin: 0;
&::after {
@extend %icon-general-style;
vertical-align: bottom;
background: $data-upload-blue-svg no-repeat;
background-size: 1em;
float: right;
}
}
}
}
1 change: 1 addition & 0 deletions public/sass/kth-bootstrap.scss
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,7 @@
@import 'bootstrap-overrides/modals';
@import 'bootstrap-overrides/popover';
@import 'bootstrap-overrides/nav';
@import 'bootstrap-overrides/buttons';
@import 'bootstrap-overrides/tables';
@import 'bootstrap-overrides/forms';

Expand Down

0 comments on commit d391184

Please sign in to comment.