mirror of
https://github.com/TriliumNext/Notes.git
synced 2025-08-10 18:39:22 +08:00
style(editor): group some formatting options for floating toolbar
This commit is contained in:
parent
bec7a526ad
commit
87d28c8c2f
@ -2,6 +2,11 @@ import { ALLOWED_PROTOCOLS } from "../../../services/link.js";
|
|||||||
import options from "../../../services/options.js";
|
import options from "../../../services/options.js";
|
||||||
import utils from "../../../services/utils.js";
|
import utils from "../../../services/utils.js";
|
||||||
|
|
||||||
|
const TEXT_FORMATTING_GROUP = {
|
||||||
|
label: "Text formatting",
|
||||||
|
icon: "text"
|
||||||
|
};
|
||||||
|
|
||||||
export function buildConfig() {
|
export function buildConfig() {
|
||||||
return {
|
return {
|
||||||
image: {
|
image: {
|
||||||
@ -116,8 +121,7 @@ function buildClassicToolbar(multilineToolbar: boolean) {
|
|||||||
"bold",
|
"bold",
|
||||||
"italic",
|
"italic",
|
||||||
{
|
{
|
||||||
label: "Text formatting",
|
...TEXT_FORMATTING_GROUP,
|
||||||
icon: "text",
|
|
||||||
items: ["underline", "strikethrough", "superscript", "subscript", "code", "kbd"]
|
items: ["underline", "strikethrough", "superscript", "subscript", "code", "kbd"]
|
||||||
},
|
},
|
||||||
"|",
|
"|",
|
||||||
@ -159,10 +163,10 @@ function buildFloatingToolbar() {
|
|||||||
"bold",
|
"bold",
|
||||||
"italic",
|
"italic",
|
||||||
"underline",
|
"underline",
|
||||||
"strikethrough",
|
{
|
||||||
"superscript",
|
...TEXT_FORMATTING_GROUP,
|
||||||
"subscript",
|
items: [ "strikethrough", "kbd", "superscript", "subscript" ]
|
||||||
"kbd",
|
},
|
||||||
"fontColor",
|
"fontColor",
|
||||||
"fontBackgroundColor",
|
"fontBackgroundColor",
|
||||||
"code",
|
"code",
|
||||||
|
Loading…
x
Reference in New Issue
Block a user