Telegram Web K with changes to work inside I2P https://web.telegram.i2p/
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 

59 lines
1.3 KiB

/*
* https://github.com/morethanwords/tweb
* Copyright (C) 2019-2021 Eduard Kuzmenko
* https://github.com/morethanwords/tweb/blob/master/LICENSE
*/
@mixin hover($color: null, $property: null, $use-transition: false) {
@if $color {
@if $color == filled-gray {
$color: var(--light-filled-secondary-text-color);
} @else if $color == gray {
$color: var(--light-secondary-text-color);
} @else if $color == blue or $color == primary {
$color: var(--light-primary-color);
} @else if $color == red {
$color: var(--light-danger-color);
}
}
html.no-touch &:hover,
html.no-touch &:active {
@if $property != null {
@if $use-transition {
transition: .2s #{$property};
}
#{$property}: $color;
}
@content;
}
}
@mixin hover-effect($color: gray, $use-transition: false) {
@include hover($color, color, $use-transition) {
@content;
}
}
@mixin hover-background-effect($color: gray, $use-transition: false) {
@include hover($color, background-color, $use-transition) {
@content;
}
}
@mixin btn-hoverable {
@include hover-background-effect();
&.primary,
&.blue,
&.active {
@include hover-background-effect(primary);
}
&.danger {
@include hover-background-effect(red);
}
}