mirror of
https://github.com/talwrii/plugin-repl.git
synced 2026-07-22 11:40:27 +00:00
feat(popup) display newlines
This commit is contained in:
parent
94fa4e3b68
commit
eb2bb0b0bd
1 changed files with 6 additions and 1 deletions
7
main.ts
7
main.ts
|
|
@ -435,7 +435,12 @@ function popup(app: App, editor: Editor, message: string): Promise<void> {
|
|||
export class Popup extends Modal {
|
||||
constructor(app: App, msg: string, resolve: () => void) {
|
||||
super(app);
|
||||
this.setContent(msg)
|
||||
|
||||
let el = new DocumentFragment()
|
||||
let pre = el.createEl("pre")
|
||||
pre.appendText(msg)
|
||||
|
||||
this.setContent(el)
|
||||
new Setting(this.contentEl).addButton((btn) => {
|
||||
btn.setButtonText("OK")
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue