Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
C
coopwire-hypothesis
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
孙灵跃 Leon Sun
coopwire-hypothesis
Commits
7bea1bd8
Commit
7bea1bd8
authored
Apr 01, 2014
by
csillag
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Update annotator to 3aca4b72c (introduce-focus branch)
parent
1d588521
Changes
6
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
41 additions
and
6 deletions
+41
-6
highlights.coffee
h/lib/_annotator_mapsrc/src/highlights.coffee
+13
-0
texthighlights.coffee
h/lib/_annotator_mapsrc/src/plugin/texthighlights.coffee
+7
-0
annotator.js
h/lib/annotator.js
+9
-2
annotator.map
h/lib/annotator.map
+1
-1
annotator.texthighlights.js
h/lib/annotator.texthighlights.js
+10
-2
annotator.texthighlights.map
h/lib/annotator.texthighlights.map
+1
-1
No files found.
h/lib/_annotator_mapsrc/src/highlights.coffee
View file @
7bea1bd8
...
...
@@ -26,6 +26,19 @@ class Highlight
setActive
:
(
value
,
batch
=
false
)
->
throw
"Operation not implemented."
# Mark/unmark this hl as focused
#
# Value specifies whether it should be focused or not
#
# The 'batch' field specifies whether this call is only one of
# many subsequent calls, which should be executed together.
#
# In this case, a "finalizeHighlights" event will be published
# when all the flags have been set, and the changes should be
# executed.
setFocused
:
(
value
,
batch
=
false
)
->
throw
"Operation not implemented."
# React to changes in the underlying annotation
annotationUpdated
:
->
#console.log "In HL", this, "annotation has been updated."
...
...
h/lib/_annotator_mapsrc/src/plugin/texthighlights.coffee
View file @
7bea1bd8
...
...
@@ -115,6 +115,13 @@ class TextHighlight extends Annotator.Highlight
else
@
$
(
@
_highlights
).
removeClass
(
'annotator-hl-active'
)
# Mark/unmark this hl as focused
setFocused
:
(
value
)
->
if
value
@
$
(
@
_highlights
).
addClass
(
'annotator-hl-focused'
)
else
@
$
(
@
_highlights
).
removeClass
(
'annotator-hl-focused'
)
# Remove all traces of this hl from the document
removeFromDocument
:
->
for
hl
in
@
_highlights
...
...
h/lib/annotator.js
View file @
7bea1bd8
// Generated by CoffeeScript 1.6.3
/*
** Annotator 1.2.6-dev-
04d1465
** Annotator 1.2.6-dev-
816c71f
** https://github.com/okfn/annotator/
**
** Copyright 2012 Aron Carroll, Rufus Pollock, and Nick Stenning.
** Dual licensed under the MIT and GPLv3 licenses.
** https://github.com/okfn/annotator/blob/master/LICENSE
**
** Built at: 2014-0
3-31 18:03:10
Z
** Built at: 2014-0
4-01 08:46:09
Z
*/
...
...
@@ -906,6 +906,13 @@
throw
"Operation not implemented."
;
};
Highlight
.
prototype
.
setFocused
=
function
(
value
,
batch
)
{
if
(
batch
==
null
)
{
batch
=
false
;
}
throw
"Operation not implemented."
;
};
Highlight
.
prototype
.
annotationUpdated
=
function
()
{};
Highlight
.
prototype
.
removeFromDocument
=
function
()
{
...
...
h/lib/annotator.map
View file @
7bea1bd8
This diff is collapsed.
Click to expand it.
h/lib/annotator.texthighlights.js
View file @
7bea1bd8
// Generated by CoffeeScript 1.6.3
/*
** Annotator 1.2.6-dev-8
b9bc0e
** Annotator 1.2.6-dev-8
16c71f
** https://github.com/okfn/annotator/
**
** Copyright 2012 Aron Carroll, Rufus Pollock, and Nick Stenning.
** Dual licensed under the MIT and GPLv3 licenses.
** https://github.com/okfn/annotator/blob/master/LICENSE
**
** Built at: 2014-0
3-31 22:37:06
Z
** Built at: 2014-0
4-01 08:47:02
Z
*/
...
...
@@ -132,6 +132,14 @@
}
};
TextHighlight
.
prototype
.
setFocused
=
function
(
value
)
{
if
(
value
)
{
return
this
.
$
(
this
.
_highlights
).
addClass
(
'annotator-hl-focused'
);
}
else
{
return
this
.
$
(
this
.
_highlights
).
removeClass
(
'annotator-hl-focused'
);
}
};
TextHighlight
.
prototype
.
removeFromDocument
=
function
()
{
var
child
,
event
,
hl
,
_i
,
_len
,
_ref
,
_results
;
_ref
=
this
.
_highlights
;
...
...
h/lib/annotator.texthighlights.map
View file @
7bea1bd8
{"version":3,"file":"annotator.texthighlights.js","sources":["_preamble.coffee","_annotator_mapsrc/src/plugin/texthighlights.coffee"],"names":[],"mappings":";AAAA;;;;;;;;;;CAAA;CAAA;;;;;;;ACGA;CAAA,KAAA,aAAA;KAAA;;0JAAA;;CAAA,CAAM;CAIJ;;CAAA,EAAa,CAAb,KAAA,IAAC;;CAAD,EACK,CAAL,KAAc,IAAb;;CADD,EAEiB,CAAjB,SAAC,EAFD;;CAAA,EAKa,CAAb,GAAa,EAAC,CAAd,GAAC;CAA0B,GAAA,GAAD,CAAA,KAAA,CAAA;CAL1B,IAKa;;CALb,EAQuB,CAAvB,GAAuB,EAAC,IAAvB,OAAD;CACG,GAAA,GAAD,MAAA,gBAAA;CATF,IAQuB;;CARvB,CAAA,CAYU,CAAV,GAAA,MAAC;;CAZD,EAeiB,CAAjB,CAAiB,IAAC,IAAjB,CAAD;CACgB,EAAd,EAAqB,CAArB,CAAA,EAGQ,IAHR,EAAA;CAGyB,GAAd,QAAA,CAAa,EAAb;CAHX,MAGQ;CAnBV,IAeiB;;CAfjB,EAuBQ,CAAR,CAAA,IAAS,IAAR;CACC,SAAA,EAAA;CAAA,CAAU,EAAA,EAAV,CAAU,EAAA,MAAa;CAAvB,aAAA;QAAA;CAAA,CAE4C,CACzC,CADH,CACG,CADH,CAAiB,CAAjB,CAAS,EAAT,IAAA;CACwB,IAAV,IAAS,MAAT,EAAA;CADd,MACG;CAHH,CAK4C,CACzC,CADH,CACG,CADH,CAAiB,CAAjB,CAAS,CAAT,KAAA;CACwB,IAAV,IAA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e,CAAd,EAAD,KAAA,IAAe;CAPf,CAQoC,EAAnC,EAAD,IAAA,CAAA,CAAA;CAxFF,IA+Ea;;CA/Eb,EA6Fa,MAAA,EAAb;CAAiB,GAAA,SAAD;CA7FhB,IA6Fa;;CA7Fb,EAgGc,EAAA,IAAC,GAAf;CACE,EAAc,CAAb,CAAD,CAAA,IAAA;CACA,GAAG,CAAH,CAAA;CACG,GAAA,IAAD,GAAA,IAAA,SAAA;MADF,EAAA;CAGG,GAAA,OAAD,IAAA,SAAA;QALU;CAhGd,IAgGc;;CAhGd,EAwGW,EAAA,IAAX;CACE,GAAG,CAAH,CAAA;CACG,GAAA,IAAD,GAAA,IAAA,MAAA;MADF,EAAA;CAGG,GAAA,OAAD,IAAA,MAAA;QAJO;CAxGX,IAwGW;;CAxGX,EA+GoB,MAAA,SAApB;CACE,SAAA,gCAAA;CAAA;CAAA;YAAA,+BAAA;uBAAA;CAEE,GAAG,IAAH,CAAgC,GAAV,WAAnB;CAED,CAAU,CAAF,EAAR,KAAA;CAAA,CACA,EAAC,MAAD,CAAA;CADA,EAGQ,EAAR,GAAgB,EAAhB,CAAQ;CAHR,CAI+B,EAA/B,CAAK,CAAL,IAAA,CAAA;CAJA,EAKe,EAAV,CAAL,IAAA,2BALA;CAAA,IAMK,KAAW,GAAhB;MARF,IAAA;CAAA;UAFF;CAAA;uBADkB;CA/GpB,IA+GoB;;CA/GpB,EA6HiB,MAAA,MAAjB;CAAqB,GAAA,SAAD;CA7HpB,IA6HiB;;CA7HjB;;CAJ0B,QAAS;;CAArC,CAmIM,IAAgB,GAAP;CAGb;;;;;CAAA;;CAAA,EAAY,MAAA,CAAZ;CAEY,EAAgB,MAAjB,IAAT;CAFF,IAAY;;CAAZ;;CAH4C,QAAS;CAnIvD"}
\ No newline at end of file
{"version":3,"file":"annotator.texthighlights.js","sources":["_preamble.coffee","_annotator_mapsrc/src/plugin/texthighlights.coffee"],"names":[],"mappings":";AAAA;;;;;;;;;;CAAA;CAAA;;;;;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ACG,GAAA,IAAD,GAAA,IAAA,MAAA;MADF,EAAA;CAGG,GAAA,OAAD,IAAA,MAAA;QAJO;CAxGX,IAwGW;;CAxGX,EA+GY,EAAA,IAAC,CAAb;CACE,GAAG,CAAH,CAAA;CACG,GAAA,IAAD,GAAA,IAAA,OAAA;MADF,EAAA;CAGG,GAAA,OAAD,IAAA,OAAA;QAJQ;CA/GZ,IA+GY;;CA/GZ,EAsHoB,MAAA,SAApB;CACE,SAAA,gCAAA;CAAA;CAAA;YAAA,+BAAA;uBAAA;CAEE,GAAG,IAAH,CAAgC,GAAV,WAAnB;CAED,CAAU,CAAF,EAAR,KAAA;CAAA,CACA,EAAC,MAAD,CAAA;CADA,EAGQ,EAAR,GAAgB,EAAhB,CAAQ;CAHR,CAI+B,EAA/B,CAAK,CAAL,IAAA,CAAA;CAJA,EAKe,EAAV,CAAL,IAAA,2BALA;CAAA,IAMK,KAAW,GAAhB;MARF,IAAA;CAAA;UAFF;CAAA;uBADkB;CAtHpB,IAsHoB;;CAtHpB,EAoIiB,MAAA,MAAjB;CAAqB,GAAA,SAAD;CApIpB,IAoIiB;;CApIjB;;CAJ0B,QAAS;;CAArC,CA0IM,IAAgB,GAAP;CAGb;;;;;CAAA;;CAAA,EAAY,MAAA,CAAZ;CAEY,EAAgB,MAAjB,IAAT;CAFF,IAAY;;CAAZ;;CAH4C,QAAS;CA1IvD"}
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment