mirror of
https://github.com/monkeytypegame/monkeytype.git
synced 2025-03-12 06:33:22 +08:00
important update
This commit is contained in:
parent
fa73e37670
commit
dcf56271e9
4 changed files with 26 additions and 0 deletions
|
@ -974,6 +974,14 @@ let commandsCaretStyle = {
|
|||
setCaretStyle("underline");
|
||||
},
|
||||
},
|
||||
{
|
||||
id: "setCaretStyleCarrot",
|
||||
display: "carrot",
|
||||
visible: false,
|
||||
exec: () => {
|
||||
setCaretStyle("carrot");
|
||||
},
|
||||
},
|
||||
],
|
||||
};
|
||||
|
||||
|
|
|
@ -607,6 +607,7 @@ function setCaretStyle(caretStyle, nosave) {
|
|||
$("#caret").removeClass("underline");
|
||||
$("#caret").removeClass("outline");
|
||||
$("#caret").removeClass("block");
|
||||
$("#caret").removeClass("carrot");
|
||||
|
||||
if (caretStyle == "off") {
|
||||
$("#caret").addClass("off");
|
||||
|
@ -618,6 +619,8 @@ function setCaretStyle(caretStyle, nosave) {
|
|||
$("#caret").addClass("outline");
|
||||
} else if (caretStyle == "underline") {
|
||||
$("#caret").addClass("underline");
|
||||
} else if (caretStyle == "carrot") {
|
||||
$("#caret").addClass("carrot");
|
||||
}
|
||||
if (!nosave) saveConfigToCookie();
|
||||
}
|
||||
|
|
|
@ -1145,6 +1145,21 @@ a:hover {
|
|||
width: 2px;
|
||||
}
|
||||
|
||||
&.carrot {
|
||||
background-color: transparent;
|
||||
background-image: url("../carrot.png");
|
||||
background-size: contain;
|
||||
background-position: center;
|
||||
background-repeat: no-repeat;
|
||||
width: 0.25rem;
|
||||
&.size2 {
|
||||
margin-left: -0.1rem;
|
||||
}
|
||||
&.size3 {
|
||||
margin-left: -0.2rem;
|
||||
}
|
||||
}
|
||||
|
||||
&.block {
|
||||
width: 0.7em;
|
||||
margin-left: 0.25em;
|
||||
|
|
BIN
static/carrot.png
Normal file
BIN
static/carrot.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 4.9 KiB |
Loading…
Reference in a new issue