Skip to content
This repository was archived by the owner on Nov 6, 2024. It is now read-only.

Line wrapping support #3

Merged
merged 2 commits into from
Sep 12, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 7 additions & 3 deletions source/CodeMirror.mint
Original file line number Diff line number Diff line change
Expand Up @@ -12,16 +12,19 @@ component CodeMirror {
/* The content to display until the editor is loaded. */
property loadingContent : Html = <></>

/* Whether or not show line numbers. */
/* Whether or not to show the line numbers. */
property lineNumbers : Bool = true

/* Whether or not to wrap the lines. */
property lineWrapping : Bool = false

/* Whether or not the content is editable. */
property readOnly : Bool = false

/* The number of spaces userd for indentation. */
/* The number of spaces used for indentation. */
property tabSize : Number = 2

/* When provided this value will be in the editor.s */
/* When provided this value will be in the editor. */
property value : String = ""

/* The theme of the editor. */
Expand Down Expand Up @@ -49,6 +52,7 @@ component CodeMirror {

this.editor = CodeMirror.fromTextArea(#{element}._0, {
lineNumbers: #{lineNumbers},
lineWrapping: #{lineWrapping},
readOnly: #{readOnly},
tabSize: #{tabSize},
theme: #{theme},
Expand Down