Skip to content

Commit

Permalink
Fix layout issues
Browse files Browse the repository at this point in the history
  • Loading branch information
RoyEJohnson committed Oct 7, 2024
1 parent 4ebd25b commit d9697b1
Show file tree
Hide file tree
Showing 4 changed files with 32 additions and 21 deletions.
2 changes: 1 addition & 1 deletion src/app/pages/contact/embedded.scss
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
}
}

button {
button:not(.clear-file) {
@include button();

&.primary {
Expand Down
7 changes: 6 additions & 1 deletion src/app/pages/contact/form.scss
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
@import 'pattern-library/core/pattern-library/headers';
@import '../errata-form/form/FileUploader';

form {
textarea {
Expand All @@ -17,6 +18,11 @@ form {

}

.file-button {
@include file-button();
margin-bottom: $normal-margin;
}

.label-text {
@include set-font(h4);
margin-bottom: 0.5rem;
Expand All @@ -25,7 +31,6 @@ form {
.btn,
.btn[type="submit"] {
@include button();
margin-bottom: $normal-margin;
width: 12rem;
padding: 0;

Expand Down
22 changes: 22 additions & 0 deletions src/app/pages/errata-form/form/FileUploader.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
@mixin file-button() {
align-items: center;
display: grid;
grid-gap: 1rem;
grid-template-columns: repeat(3, auto) 1fr;

&.empty {
order: 1;

+ .file-button.empty {
display: none;
}
}

.clear-file {
appearance: none;
background-color: inherit;
color: inherit;
justify-self: left;

}
}
22 changes: 3 additions & 19 deletions src/app/pages/errata-form/form/form.scss
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
@import 'pattern-library/core/pattern-library/headers';
@import './FileUploader';

.banned-notice {
padding: $normal-margin;
Expand Down Expand Up @@ -87,8 +88,7 @@
}
}

.button-group,
.file-button {
.button-group {
align-items: center;
display: grid;
grid-gap: 1rem;
Expand All @@ -99,23 +99,7 @@
}

.file-button {
grid-template-columns: auto auto 1fr;

&.empty {
order: 1;

+ .file-button.empty {
display: none;
}
}
}

.clear-file {
appearance: none;
background-color: inherit;
color: inherit;
justify-self: left;

@include file-button();
}

.btn {
Expand Down

0 comments on commit d9697b1

Please sign in to comment.