Skip to content

Commit c1b9602

Browse files
committed
Remove the white borders unless the button is active
fixes #2212
1 parent c01ca21 commit c1b9602

File tree

4 files changed

+44
-67
lines changed

4 files changed

+44
-67
lines changed

app/assets/stylesheets/_dashboard.scss

Lines changed: 25 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -429,14 +429,6 @@
429429
gap: 1px;
430430

431431
.request-btn {
432-
/* Outline properties */
433-
outline-style: solid;
434-
outline-color: black;
435-
outline-width: 1px; /* Adjust outline thickness */
436-
437-
/* Space between button and outline */
438-
outline-offset: 2px; /* Adjust the offset as needed */
439-
440432
display: flex;
441433
padding: 0.5rem 1.25rem;
442434
align-items: flex-start;
@@ -451,17 +443,24 @@
451443
&:hover {
452444
background: $gray-60;
453445
}
446+
&:active {
447+
/* Outline properties */
448+
outline-style: solid;
449+
outline-color: black;
450+
outline-width: 1px; /* Adjust outline thickness */
451+
box-shadow: 0 0 0 0.2rem $white;
452+
453+
/* Space between button and outline */
454+
outline-offset: 2px; /* Adjust the offset as needed */
455+
}
456+
&:focus {
457+
border-width: 2px;
458+
box-shadow: 0 0 0 0.2rem $bright-blue;
459+
outline-color: $bright-blue;
460+
}
454461
}
455462

456463
.request-options {
457-
/* Outline properties */
458-
outline-style: solid;
459-
outline-color: black;
460-
outline-width: 1px; /* Adjust outline thickness */
461-
462-
/* Space between button and outline */
463-
outline-offset: 2px; /* Adjust the offset as needed */
464-
465464
display: flex;
466465
padding: 0.5rem 0.25rem;
467466
align-items: flex-start;
@@ -480,6 +479,16 @@
480479
&:hover {
481480
background: $gray-60;
482481
}
482+
&:active {
483+
/* Outline properties */
484+
outline-style: solid;
485+
outline-color: black;
486+
outline-width: 1px; /* Adjust outline thickness */
487+
box-shadow: 0 0 0 0.2rem $white;
488+
489+
/* Space between button and outline */
490+
outline-offset: 2px; /* Adjust the offset as needed */
491+
}
483492
}
484493

485494
.request-dropdown {

app/assets/stylesheets/application.scss

Lines changed: 18 additions & 46 deletions
Original file line numberDiff line numberDiff line change
@@ -141,16 +141,26 @@ h6 {
141141
align-items: center;
142142
gap: 0.25rem;
143143
border-radius: 0.25rem;
144-
}
145144

146-
.pul-button:focus {
147-
border-color: $princeton-orange !important;
148-
border-width: 2px;
149-
box-shadow: 0 0 0 0.2rem $bright-blue;
150-
}
145+
&:focus {
146+
border-width: 2px;
147+
box-shadow: 0 0 0 0.2rem $bright-blue;
148+
}
149+
&:active {
150+
border-color: $black;
151+
/* Outline properties */
152+
outline-style: solid;
153+
outline-color: black;
154+
outline-width: 1px; /* Adjust outline thickness */
155+
box-shadow: 0 0 0 0.2rem $white;
156+
157+
/* Space between button and outline */
158+
outline-offset: 2px; /* Adjust the offset as needed */
159+
}
151160

152-
.pul-button:hover {
153-
text-decoration: underline !important;
161+
&:hover {
162+
text-decoration: underline !important;
163+
}
154164
}
155165

156166
.pul-button-primary {
@@ -159,44 +169,6 @@ h6 {
159169
text-decoration: none;
160170
}
161171

162-
a.pul-button-primary {
163-
/* Outline properties */
164-
outline-style: solid;
165-
outline-color: black;
166-
outline-width: 1px; /* Adjust outline thickness */
167-
168-
/* Space between button and outline */
169-
outline-offset: 2px; /* Adjust the offset as needed */
170-
}
171-
input[type="submit"]:enabled.pul-button-primary {
172-
/* Outline properties */
173-
outline-style: solid;
174-
outline-color: black;
175-
outline-width: 1px; /* Adjust outline thickness */
176-
177-
/* Space between button and outline */
178-
outline-offset: 2px; /* Adjust the offset as needed */
179-
}
180-
181-
input[type="submit"]:enabled.pul-button-secondary {
182-
/* Outline properties */
183-
outline-style: solid;
184-
outline-color: black;
185-
outline-width: 1px; /* Adjust outline thickness */
186-
187-
/* Space between button and outline */
188-
outline-offset: 2px; /* Adjust the offset as needed */
189-
}
190-
input[type="button"]:enabled.pul-button-secondary {
191-
/* Outline properties */
192-
outline-style: solid;
193-
outline-color: black;
194-
outline-width: 1px; /* Adjust outline thickness */
195-
196-
/* Space between button and outline */
197-
outline-offset: 2px; /* Adjust the offset as needed */
198-
}
199-
200172
.pul-button-primary:hover {
201173
text-decoration-color: $white !important;
202174
color: $white;

app/assets/stylesheets/components/field_components.scss

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -35,10 +35,6 @@ input[type="text"]::placeholder {
3535
line-height: 1.5rem;
3636
}
3737

38-
input[type="text"]:focus {
39-
border-color: $princeton-orange !important;
40-
}
41-
4238
.required-field {
4339
border: 1px solid $gray-20;
4440
background: $white;

app/views/new_project_wizard/_form_user_roles_input.html.erb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@
6868
</div>
6969
</div>
7070
<div class="button-frame">
71-
<input type="button" popovertarget="user-role" popovertargetaction="hide" class="add-user-roles" value="Add Users"></input>
71+
<input type="button" popovertarget="user-role" popovertargetaction="hide" class="pul-button add-user-roles" value="Add Users"></input>
7272
</div>
7373
</div>
7474
</div>

0 commit comments

Comments
 (0)