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
0ad6ce49
Commit
0ad6ce49
authored
Mar 30, 2023
by
Alejandro Celaya
Committed by
Alejandro Celaya
Mar 30, 2023
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add missing comments in selection-observer
parent
9f6e7cf1
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
6 additions
and
0 deletions
+6
-0
bucket-bar-client.ts
src/annotator/bucket-bar-client.ts
+5
-0
selection-observer.ts
src/annotator/selection-observer.ts
+1
-0
No files found.
src/annotator/bucket-bar-client.ts
View file @
0ad6ce49
...
@@ -10,7 +10,12 @@ import { computeAnchorPositions } from './util/buckets';
...
@@ -10,7 +10,12 @@ import { computeAnchorPositions } from './util/buckets';
type
HostRPC
=
PortRPC
<
HostToGuestEvent
,
GuestToHostEvent
>
;
type
HostRPC
=
PortRPC
<
HostToGuestEvent
,
GuestToHostEvent
>
;
export
type
BucketBarClientOptions
=
{
export
type
BucketBarClientOptions
=
{
/**
* The scrollable container element for the document content. All the highlights
* that the bucket bar's buckets point at should be contained within this element.
*/
contentContainer
:
Element
;
contentContainer
:
Element
;
hostRPC
:
HostRPC
;
hostRPC
:
HostRPC
;
};
};
...
...
src/annotator/selection-observer.ts
View file @
0ad6ce49
...
@@ -19,6 +19,7 @@ export function selectedRange(document: Document): Range | null {
...
@@ -19,6 +19,7 @@ export function selectedRange(document: Document): Range | null {
* An observer that watches for and buffers changes to the document's current selection.
* An observer that watches for and buffers changes to the document's current selection.
*/
*/
export
class
SelectionObserver
{
export
class
SelectionObserver
{
/** Tracks the timeout ID of the last scheduled callback */
private
_pendingCallback
:
number
|
null
;
private
_pendingCallback
:
number
|
null
;
private
_document
:
Document
;
private
_document
:
Document
;
private
_listeners
:
ListenerCollection
;
private
_listeners
:
ListenerCollection
;
...
...
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