Skip to content

Commit

Permalink
feat(input): move pointer-events value into variable
Browse files Browse the repository at this point in the history
This PR allows to change the pointer-events value for disabled input/form fields.
  • Loading branch information
lubber-de authored Nov 2, 2022
1 parent 894f183 commit d459c42
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/definitions/collections/form.less
Original file line number Diff line number Diff line change
Expand Up @@ -760,7 +760,7 @@
.ui.form .disabled.fields .field,
.ui.form .disabled.field,
.ui.form .field :disabled {
pointer-events: none;
pointer-events: @disabledPointerEvents;
opacity: @disabledOpacity;
}
.ui.form .field.disabled > label,
Expand Down
2 changes: 1 addition & 1 deletion src/definitions/elements/input.less
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@

.ui.disabled.input > input,
.ui.input:not(.disabled) input[disabled] {
pointer-events: none;
pointer-events: @disabledPointerEvents;
}
}

Expand Down
1 change: 1 addition & 0 deletions src/themes/default/globals/site.variables
Original file line number Diff line number Diff line change
Expand Up @@ -1086,6 +1086,7 @@
--------------------*/

@disabledOpacity: 0.45;
@disabledPointerEvents: none;
@disabledTextColor: rgba(40, 40, 40, 0.3);
@invertedDisabledTextColor: rgba(225, 225, 225, 0.3);

Expand Down

0 comments on commit d459c42

Please sign in to comment.