aboutsummaryrefslogtreecommitdiff
path: root/src/client/views/presentationview
diff options
context:
space:
mode:
authoranika-ahluwalia <anika.ahluwalia@gmail.com>2020-08-06 19:25:26 -0500
committeranika-ahluwalia <anika.ahluwalia@gmail.com>2020-08-06 19:25:26 -0500
commit5ecece1bb09010a2e61b38f1804bd22775cd5ea4 (patch)
tree404c92d3387fd94c3346cd0e7d113ca430b54a80 /src/client/views/presentationview
parent915bb3796541116897dfc016a0ed3253c2f856cc (diff)
parent0910e7387fae485d7c11eb71b6abcce865403b13 (diff)
Merge branch 'presentation_updates' into menu_restructure
Diffstat (limited to 'src/client/views/presentationview')
-rw-r--r--src/client/views/presentationview/PresElementBox.scss12
-rw-r--r--src/client/views/presentationview/PresElementBox.tsx14
2 files changed, 12 insertions, 14 deletions
diff --git a/src/client/views/presentationview/PresElementBox.scss b/src/client/views/presentationview/PresElementBox.scss
index fa70b2a41..1e776384a 100644
--- a/src/client/views/presentationview/PresElementBox.scss
+++ b/src/client/views/presentationview/PresElementBox.scss
@@ -1,6 +1,10 @@
+$light-blue: #AEDDF8;
+$dark-blue: #5B9FDD;
+$light-background: #ececec;
+
.presElementBox-item {
display: grid;
- grid-template-columns: max-content max-content max-content;
+ grid-template-columns: max-content max-content max-content max-content;
background-color: #d5dce2;
font-family: Roboto;
letter-spacing: normal;
@@ -26,7 +30,7 @@
z-index: -1;
width: calc(100% + 200px);
height: calc(100% + 8px);
- background-color: #AEDDF8;
+ background-color: $light-blue;
}
.presElementBox-highlightTop {
@@ -69,7 +73,7 @@
.presElementBox-active {
color: black;
border-radius: 6px;
- border: solid 2px #5B9FDD;
+ border: solid 2px $dark-blue;
}
.presElementBox-buttons {
@@ -118,7 +122,7 @@
padding-left: 10px;
padding-right: 10px;
letter-spacing: normal;
- max-width: max-content;
+ width: max-content;
text-overflow: ellipsis;
overflow: hidden;
white-space: pre;
diff --git a/src/client/views/presentationview/PresElementBox.tsx b/src/client/views/presentationview/PresElementBox.tsx
index 11ffde9dd..a6dbb76ef 100644
--- a/src/client/views/presentationview/PresElementBox.tsx
+++ b/src/client/views/presentationview/PresElementBox.tsx
@@ -189,7 +189,7 @@ export class PresElementBox extends ViewBoxBaseComponent<FieldViewProps, PresDoc
DataDoc={this.targetDoc[DataSym] !== this.targetDoc && this.targetDoc[DataSym]}
LibraryPath={emptyPath}
fitToBox={true}
- backgroundColor={() => "darkgrey"}
+ backgroundColor={this.props.backgroundColor}
rootSelected={returnTrue}
addDocument={returnFalse}
removeDocument={returnFalse}
@@ -238,7 +238,6 @@ export class PresElementBox extends ViewBoxBaseComponent<FieldViewProps, PresDoc
e.stopPropagation();
e.preventDefault();
if (element) {
- console.log(element.className);
if (PresBox.Instance._eleArray.includes(element)) {
setupMoveUpEvents(this, e, this.startDrag, emptyFunction, emptyFunction);
}
@@ -254,11 +253,8 @@ export class PresElementBox extends ViewBoxBaseComponent<FieldViewProps, PresDoc
}
startDrag = (e: PointerEvent, down: number[], delta: number[]) => {
- // const ele: HTMLElement[] = PresBox.Instance._eleArray.map(doc => doc);
const activeItem = this.rootDoc;
const dragData = new DragManager.DocumentDragData(PresBox.Instance.sortArray().map(doc => doc));
- // let value = this.getValue(this._heading);
- // value = typeof value === "string" ? `"${value}"` : value;
const dragItem: HTMLElement[] = [];
PresBox.Instance._dragArray.map(ele => {
const drag = ele;
@@ -330,14 +326,14 @@ export class PresElementBox extends ViewBoxBaseComponent<FieldViewProps, PresDoc
<div className="presElementBox-number">
{`${this.indexInPres + 1}.`}
</div>
- <div ref={this._dragRef} className="presElementBox-name">
+ <div ref={this._dragRef} className="presElementBox-name" style={{ maxWidth: (PresBox.Instance.toolbarWidth - 70) }}>
{`${this.targetDoc?.title}`}
</div>
<Tooltip title={<><div className="dash-tooltip">{"Movement speed"}</div></>}><div className="presElementBox-time" style={{ display: PresBox.Instance.toolbarWidth > 300 ? "block" : "none" }}>{this.transition}</div></Tooltip>
<Tooltip title={<><div className="dash-tooltip">{"Duration"}</div></>}><div className="presElementBox-time" style={{ display: PresBox.Instance.toolbarWidth > 300 ? "block" : "none" }}>{this.duration}</div></Tooltip>
+ <Tooltip title={<><div className="dash-tooltip">{"Presentation pin view"}</div></>}><div className="presElementBox-time" style={{ fontWeight: 700, display: this.rootDoc.presPinView && PresBox.Instance.toolbarWidth > 300 ? "block" : "none" }}>V</div></Tooltip>
<Tooltip title={<><div className="dash-tooltip">{"Remove from presentation"}</div></>}><div
className="presElementBox-closeIcon"
- // onPointerDown={e => e.stopPropagation()}
onClick={e => {
this.props.removeDocument?.(this.rootDoc);
e.stopPropagation();
@@ -363,6 +359,4 @@ export class PresElementBox extends ViewBoxBaseComponent<FieldViewProps, PresDoc
</div>
);
}
-}
-
-// this.layoutDoc.title !== "pres element template" \ No newline at end of file
+} \ No newline at end of file