mirror of
https://github.com/sxyazi/yazi.git
synced 2024-12-18 22:31:35 +03:00
feat: add new reversed
modifier
This commit is contained in:
parent
e12ebd38e0
commit
85b4892d40
@ -134,6 +134,7 @@ rules = [
|
|||||||
{ mime = "application/x-rar", fg = "magenta" },
|
{ mime = "application/x-rar", fg = "magenta" },
|
||||||
|
|
||||||
# Fallback
|
# Fallback
|
||||||
|
{ name = "*", blink = true },
|
||||||
{ name = "*/", fg = "blue" }
|
{ name = "*/", fg = "blue" }
|
||||||
]
|
]
|
||||||
|
|
||||||
|
@ -52,6 +52,8 @@ impl Filetype {
|
|||||||
#[serde(default)]
|
#[serde(default)]
|
||||||
blink_rapid: bool,
|
blink_rapid: bool,
|
||||||
#[serde(default)]
|
#[serde(default)]
|
||||||
|
reversed: bool,
|
||||||
|
#[serde(default)]
|
||||||
hidden: bool,
|
hidden: bool,
|
||||||
#[serde(default)]
|
#[serde(default)]
|
||||||
crossed: bool,
|
crossed: bool,
|
||||||
@ -73,6 +75,7 @@ impl Filetype {
|
|||||||
underline: r.underline,
|
underline: r.underline,
|
||||||
blink: r.blink,
|
blink: r.blink,
|
||||||
blink_rapid: r.blink_rapid,
|
blink_rapid: r.blink_rapid,
|
||||||
|
reversed: r.reversed,
|
||||||
hidden: r.hidden,
|
hidden: r.hidden,
|
||||||
crossed: r.crossed,
|
crossed: r.crossed,
|
||||||
}
|
}
|
||||||
|
@ -55,6 +55,8 @@ pub(super) struct StyleShadow {
|
|||||||
#[serde(default)]
|
#[serde(default)]
|
||||||
pub(super) blink_rapid: bool,
|
pub(super) blink_rapid: bool,
|
||||||
#[serde(default)]
|
#[serde(default)]
|
||||||
|
pub(super) reversed: bool,
|
||||||
|
#[serde(default)]
|
||||||
pub(super) hidden: bool,
|
pub(super) hidden: bool,
|
||||||
#[serde(default)]
|
#[serde(default)]
|
||||||
pub(super) crossed: bool,
|
pub(super) crossed: bool,
|
||||||
@ -81,6 +83,9 @@ impl From<StyleShadow> for Style {
|
|||||||
if value.blink_rapid {
|
if value.blink_rapid {
|
||||||
modifier |= Modifier::RAPID_BLINK;
|
modifier |= Modifier::RAPID_BLINK;
|
||||||
}
|
}
|
||||||
|
if value.reversed {
|
||||||
|
modifier |= Modifier::REVERSED;
|
||||||
|
}
|
||||||
if value.hidden {
|
if value.hidden {
|
||||||
modifier |= Modifier::HIDDEN;
|
modifier |= Modifier::HIDDEN;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user