mirror of
https://github.com/flynx/pWiki.git
synced 2025-10-29 01:50:07 +00:00
...
Signed-off-by: Alex A. Naanou <alex.nanou@gmail.com>
This commit is contained in:
parent
f6fea34821
commit
9ecbf4e060
@ -1057,6 +1057,7 @@ var Outline = {
|
||||
var stack = this.__crop_stack ??= []
|
||||
stack.push([this.json(), this.path()])
|
||||
this.load(this.data())
|
||||
this.dom.classList.add('crop')
|
||||
return this },
|
||||
// XXX use JSON API...
|
||||
uncrop: function(){
|
||||
@ -1064,7 +1065,8 @@ var Outline = {
|
||||
return this}
|
||||
var [state, path] = this.__crop_stack.pop()
|
||||
if(this.__crop_stack.length == 0){
|
||||
this.__crop_stack = undefined }
|
||||
this.__crop_stack = undefined
|
||||
this.dom.classList.remove('crop') }
|
||||
// update state...
|
||||
path
|
||||
.slice(0, -1)
|
||||
|
||||
@ -76,6 +76,8 @@ HTMLTextAreaElement.prototype.getTextGeometry = function(){
|
||||
span.append(
|
||||
text.slice(0, offset),
|
||||
carret,
|
||||
// NOTE: wee need the rest of the text for the carret to be typeset
|
||||
// to the correct line...
|
||||
text.slice(offset))
|
||||
|
||||
document.body.append(span)
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user