| 1 |
import { Lang as LangShiki, Theme } from 'shiki'; |
| 2 |
|
| 3 |
export type Lang = LangShiki | 'ansi'; |
| 4 |
|
| 5 |
export type Attributes = { |
| 6 |
code: string; |
| 7 |
codeHTML: string; |
| 8 |
language: Lang; |
| 9 |
theme: Theme; |
| 10 |
align: 'wide' | 'full'; |
| 11 |
bgColor: string; |
| 12 |
textColor: string; |
| 13 |
fontSize: string; |
| 14 |
fontFamily: string; |
| 15 |
lineHeight: string; |
| 16 |
lineNumbers: boolean; |
| 17 |
clampFonts: boolean; |
| 18 |
editorHeight: string; |
| 19 |
headerType: string; |
| 20 |
headerString?: string; |
| 21 |
footerType: string; |
| 22 |
footerString?: string; |
| 23 |
footerLink?: string; |
| 24 |
enableMaxHeight?: boolean; |
| 25 |
seeMoreType?: string; |
| 26 |
seeMoreString?: string; |
| 27 |
seeMoreAfterLine?: string; |
| 28 |
seeMoreTransition?: boolean; |
| 29 |
footerLinkTarget?: boolean; |
| 30 |
disablePadding: boolean; |
| 31 |
startingLineNumber: string; |
| 32 |
lineNumbersWidth: number; |
| 33 |
enableHighlighting: boolean; |
| 34 |
lineHighlights: string; |
| 35 |
lineHighlightColor: string; |
| 36 |
enableBlurring: boolean; |
| 37 |
lineBlurs: string; |
| 38 |
removeBlurOnHover: boolean; |
| 39 |
frame: boolean; |
| 40 |
renderType: string; |
| 41 |
label: string; |
| 42 |
copyButton: boolean; |
| 43 |
}; |
| 44 |
export interface AttributesPropsAndSetter { |
| 45 |
attributes: Attributes; |
| 46 |
setAttributes: (attrs: Partial<Attributes>) => void; |
| 47 |
} |
| 48 |
|
| 49 |
declare global { |
| 50 |
interface Window { |
| 51 |
codeBlockPro: { |
| 52 |
pluginUrl: string; |
| 53 |
}; |
| 54 |
} |
| 55 |
} |
| 56 |
|