in src/helper/config.ts [88:122]
private constructor (config?: Partial<ConfigModel>) {
this.config = {
...configDefaults,
...config,
texts: {
...configDefaults.texts,
...config?.texts
},
componentClasses: {
...configDefaults.componentClasses,
...config?.componentOverrides
}
};
this.config.codeBlockActions = {
...(this.config.codeCopyToClipboardEnabled !== false
? {
copy: {
id: 'copy',
label: this.config.texts.copy,
icon: MynahIcons.COPY
}
}
: {}),
...(this.config.codeInsertToCursorEnabled !== false
? {
'insert-to-cursor': {
id: 'insert-to-cursor',
label: this.config.texts.insertAtCursorLabel,
icon: MynahIcons.CURSOR_INSERT
}
}
: {}),
...config?.codeBlockActions
};
}