Skip to content

Commit

Permalink
Refactor ingredient link tools styles
Browse files Browse the repository at this point in the history
They need to be updated after we changed the icon_button
styles.
  • Loading branch information
tvdeyen committed Dec 21, 2023
1 parent 87ec207 commit 73b3d59
Showing 1 changed file with 37 additions and 39 deletions.
76 changes: 37 additions & 39 deletions app/assets/stylesheets/alchemy/elements.scss
Original file line number Diff line number Diff line change
Expand Up @@ -484,54 +484,52 @@ alchemy-publish-element-button {
right: 0;

.icon_button {
@include button-defaults(
$background-color: $medium-gray,
$hover-color: darken($medium-gray, 5%),
$border: 1px solid #c0c0c0,
$box-shadow: none,
$hover-border-color: #c0c0c0,
$line-height: 30px,
$padding: 0,
$margin: 0,
$border-radius: 0,
$focus-border-color: $focus-color,
$focus-box-shadow: 0 0 0 2px $focus-color
);
width: $form-field-addon-width;
height: $form-field-height;

&.disabled,
&.disabled:hover {
background-color: $form-field-disabled-bg-color;
}
&:not(.linked) {
background-color: $medium-gray;
border-color: $default-border-color;
border-width: $form-field-border-width;
border-style: $form-field-border-style;
box-shadow: none;
padding: 0;
margin: 0;
border-radius: 0;
width: $form-field-addon-width;
height: $form-field-height;

&.linked.link-ingredient {
@include linked-button(
$border-radius: 0,
$line-height: 30px,
$padding: 0
);
&:hover {
border-color: #c0c0c0;
}

&:focus {
border-radius: 0;
box-shadow: 0 0 0 2px $focus-color;
border-color: $focus-color;
}
}

&.linked.unlink-ingredient {
@include linked-button(
$border-radius: 0 $default-border-radius $default-border-radius 0,
$line-height: 30px,
$padding: 0
);
&[is="alchemy-unlink-button"] {
border-left-width: 0;
@extend .right-rounded-border;
}

&:focus {
border-radius: 0 $default-border-radius $default-border-radius 0;
&.disabled,
&.disabled:hover {
background-color: $form-field-disabled-bg-color;
}
}

&.unlink-ingredient {
border-left-width: 0;
@extend .right-rounded-border;
&.linked {
height: 31px;
padding: 0;
border-radius: 0;
border-color: rgba(187, 162, 102, 0.5);

&[is="alchemy-unlink-button"] {
border-radius: 0 $default-border-radius $default-border-radius 0;
border-left-width: 0;

&:focus {
border-radius: 0 $default-border-radius $default-border-radius 0;
}
}
}
}
}
Expand Down

0 comments on commit 73b3d59

Please sign in to comment.