Commit 2882b7d0 authored by RawKStar77's avatar RawKStar77

Fix bugs by getting rid of a bad idea. Tighten up styles.

parent 1e1a1dfd
# This directive controls both the rendering and display of markdown in annotations, as well as
# This directive controls both the rendering and display of markdown in annotations, as well as
# the markdown editor interface.
markdown = ['$filter', '$timeout', ($filter, $timeout) ->
......@@ -11,14 +11,11 @@ markdown = ['$filter', '$timeout', ($filter, $timeout) ->
scope.returnSelection = ->
# Maybe get selections from other parts of the text? Such as the quote or a reply?
ourIframeSelection = window.getSelection().toString()
parentDocumentSelection = parent.window.getSelection().toString()
if input[0].selectionStart != undefined
startPos = input[0].selectionStart
endPos = input[0].selectionEnd
if ourIframeSelection
selectedText = ourIframeSelection
else if parentDocumentSelection
selectedText = parentDocumentSelection
else
selectedText = input[0].value.substring(startPos, endPos)
textBefore = input[0].value.substring(0, (startPos))
......
......@@ -43,7 +43,12 @@
}
// Markdown Controls ////////////////////////
// Markdown Editor Controls ////////////////////////
privacy {
position: relative;
top: 2px;
}
.markdown {
.preview {
overflow: auto;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment