mirror of
https://github.com/yu-i-i/overleaf-cep.git
synced 2026-11-14 06:03:45 +01:00
Add text formatting commands to the LaTeX grammar (#19607)
GitOrigin-RevId: f69cd323992c80de3f0a458a637fa8f160017076
This commit is contained in:
@@ -1,5 +1,4 @@
|
||||
import { FlatOutlineItem } from '../../utils/tree-query'
|
||||
import { enterNode } from '../../utils/tree-operations/outline'
|
||||
import { enterNode, FlatOutlineItem } from '../../utils/tree-operations/outline'
|
||||
import { makeProjectionStateField } from '../../utils/projection-state-field'
|
||||
|
||||
export const documentOutline =
|
||||
|
||||
@@ -52,6 +52,19 @@ const typeMap: Record<string, string[]> = {
|
||||
Input: ['$CommandTooltipCommand'],
|
||||
Ref: ['$CommandTooltipCommand'],
|
||||
UrlCommand: ['$CommandTooltipCommand'],
|
||||
// text formatting commands that can be toggled via the toolbar
|
||||
TextBoldCommand: ['$ToggleTextFormattingCommand'],
|
||||
TextItalicCommand: ['$ToggleTextFormattingCommand'],
|
||||
// text formatting commands that cannot be toggled via the toolbar
|
||||
TextSmallCapsCommand: ['$OtherTextFormattingCommand'],
|
||||
TextTeletypeCommand: ['$OtherTextFormattingCommand'],
|
||||
TextMediumCommand: ['$OtherTextFormattingCommand'],
|
||||
TextSansSerifCommand: ['$OtherTextFormattingCommand'],
|
||||
TextSuperscriptCommand: ['$OtherTextFormattingCommand'],
|
||||
TextSubscriptCommand: ['$OtherTextFormattingCommand'],
|
||||
StrikeOutCommand: ['$OtherTextFormattingCommand'],
|
||||
EmphasisCommand: ['$OtherTextFormattingCommand'],
|
||||
UnderlineCommand: ['$OtherTextFormattingCommand'],
|
||||
}
|
||||
|
||||
export const LaTeXLanguage = LRLanguage.define({
|
||||
|
||||
Reference in New Issue
Block a user