aboutsummaryrefslogtreecommitdiff
path: root/src/client/views/DocumentDecorations.tsx
diff options
context:
space:
mode:
authorJude <julie_wang1@brown.edu>2019-03-09 17:14:42 -0500
committerJude <julie_wang1@brown.edu>2019-03-09 17:14:42 -0500
commitc6a3faf616e68ede2d67580344e4337c3f0cfdc5 (patch)
treefa09d4c17b083f4656ebd912c35b212cc801459d /src/client/views/DocumentDecorations.tsx
parent695a91d86df0aa7d3e6a4a63414286fbdaf86d80 (diff)
added some flair to freeform views
Diffstat (limited to 'src/client/views/DocumentDecorations.tsx')
-rw-r--r--src/client/views/DocumentDecorations.tsx9
1 files changed, 5 insertions, 4 deletions
diff --git a/src/client/views/DocumentDecorations.tsx b/src/client/views/DocumentDecorations.tsx
index 36395ed0d..406d6a234 100644
--- a/src/client/views/DocumentDecorations.tsx
+++ b/src/client/views/DocumentDecorations.tsx
@@ -11,6 +11,7 @@ export class DocumentDecorations extends React.Component {
static Instance: DocumentDecorations
private _resizer = ""
private _isPointerDown = false;
+ private _resizeBorderWidth = 16;
@observable private _hidden = false;
constructor(props: Readonly<{}>) {
@@ -149,10 +150,10 @@ export class DocumentDecorations extends React.Component {
}
return (
<div id="documentDecorations-container" style={{
- width: (bounds.r - bounds.x + 20) + "px",
- height: (bounds.b - bounds.y + 20) + "px",
- left: bounds.x - 10,
- top: bounds.y - 10,
+ width: (bounds.r - bounds.x + this._resizeBorderWidth) + "px",
+ height: (bounds.b - bounds.y + this._resizeBorderWidth) + "px",
+ left: bounds.x - this._resizeBorderWidth / 2,
+ top: bounds.y - this._resizeBorderWidth / 2,
}}>
<div id="documentDecorations-topLeftResizer" className="documentDecorations-resizer" onPointerDown={this.onPointerDown} onContextMenu={(e) => e.preventDefault()}></div>
<div id="documentDecorations-topResizer" className="documentDecorations-resizer" onPointerDown={this.onPointerDown} onContextMenu={(e) => e.preventDefault()}></div>