@plusscommunities/pluss-circles-web-groups 1.5.6 → 1.5.7-beta.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.cjs.js +188 -41
- package/dist/index.esm.js +188 -41
- package/dist/index.umd.js +188 -41
- package/package.json +2 -2
- package/src/apis/circleActions.js +10 -0
- package/src/screens/Circle.js +9 -0
- package/src/screens/Circles.js +516 -376
package/dist/index.esm.js
CHANGED
|
@@ -333,6 +333,35 @@ var circleActions = {
|
|
|
333
333
|
}
|
|
334
334
|
|
|
335
335
|
return deleteMessage;
|
|
336
|
+
}(),
|
|
337
|
+
markAsRead: function () {
|
|
338
|
+
var _markAsRead = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee4(circleId, userId) {
|
|
339
|
+
return _regeneratorRuntime.wrap(function _callee4$(_context4) {
|
|
340
|
+
while (1) {
|
|
341
|
+
switch (_context4.prev = _context4.next) {
|
|
342
|
+
case 0:
|
|
343
|
+
return _context4.abrupt("return", Session$4.authedFunction({
|
|
344
|
+
method: 'post',
|
|
345
|
+
url: Helper$3.getUrl('notifications', 'resetunread'),
|
|
346
|
+
data: {
|
|
347
|
+
groupID: circleId,
|
|
348
|
+
userID: userId
|
|
349
|
+
}
|
|
350
|
+
}));
|
|
351
|
+
|
|
352
|
+
case 1:
|
|
353
|
+
case "end":
|
|
354
|
+
return _context4.stop();
|
|
355
|
+
}
|
|
356
|
+
}
|
|
357
|
+
}, _callee4);
|
|
358
|
+
}));
|
|
359
|
+
|
|
360
|
+
function markAsRead(_x9, _x10) {
|
|
361
|
+
return _markAsRead.apply(this, arguments);
|
|
362
|
+
}
|
|
363
|
+
|
|
364
|
+
return markAsRead;
|
|
336
365
|
}()
|
|
337
366
|
};
|
|
338
367
|
|
|
@@ -375,7 +404,7 @@ var Circles = /*#__PURE__*/function (_Component) {
|
|
|
375
404
|
|
|
376
405
|
case 3:
|
|
377
406
|
res = _context.sent;
|
|
378
|
-
console.log(
|
|
407
|
+
console.log("getData", res.data);
|
|
379
408
|
|
|
380
409
|
_this.props.circlesLoaded(res.data);
|
|
381
410
|
|
|
@@ -389,7 +418,7 @@ var Circles = /*#__PURE__*/function (_Component) {
|
|
|
389
418
|
case 9:
|
|
390
419
|
_context.prev = 9;
|
|
391
420
|
_context.t0 = _context["catch"](0);
|
|
392
|
-
console.error(
|
|
421
|
+
console.error("getData", _context.t0);
|
|
393
422
|
|
|
394
423
|
_this.setState({
|
|
395
424
|
loadingAll: false
|
|
@@ -404,6 +433,12 @@ var Circles = /*#__PURE__*/function (_Component) {
|
|
|
404
433
|
})));
|
|
405
434
|
});
|
|
406
435
|
|
|
436
|
+
_defineProperty(_assertThisInitialized(_this), "selectUnreadFilter", function (showUnreadOnly) {
|
|
437
|
+
_this.setState({
|
|
438
|
+
showUnreadOnly: showUnreadOnly
|
|
439
|
+
});
|
|
440
|
+
});
|
|
441
|
+
|
|
407
442
|
_defineProperty(_assertThisInitialized(_this), "canAddNew", function () {
|
|
408
443
|
var auth = _this.props.auth;
|
|
409
444
|
return Session$3.validateAccess(auth.site, values.permission, auth);
|
|
@@ -471,9 +506,15 @@ var Circles = /*#__PURE__*/function (_Component) {
|
|
|
471
506
|
});
|
|
472
507
|
});
|
|
473
508
|
|
|
509
|
+
_defineProperty(_assertThisInitialized(_this), "selectSort", function (sortType) {
|
|
510
|
+
_this.setState({
|
|
511
|
+
sortBy: sortType
|
|
512
|
+
});
|
|
513
|
+
});
|
|
514
|
+
|
|
474
515
|
_defineProperty(_assertThisInitialized(_this), "onHandleChange", function (event) {
|
|
475
516
|
var stateChange = {};
|
|
476
|
-
stateChange[event.target.getAttribute(
|
|
517
|
+
stateChange[event.target.getAttribute("id")] = event.target.value;
|
|
477
518
|
|
|
478
519
|
_this.setState(stateChange);
|
|
479
520
|
});
|
|
@@ -485,14 +526,14 @@ var Circles = /*#__PURE__*/function (_Component) {
|
|
|
485
526
|
circleActions.delete(circle.Id).then(function (res) {
|
|
486
527
|
_this.getData();
|
|
487
528
|
}).catch(function (res) {
|
|
488
|
-
alert(
|
|
529
|
+
alert("Something went wrong with the request. Please try again.");
|
|
489
530
|
});
|
|
490
531
|
}
|
|
491
532
|
});
|
|
492
533
|
|
|
493
534
|
_defineProperty(_assertThisInitialized(_this), "getTypeFilterText", function (type) {
|
|
494
|
-
if (type ===
|
|
495
|
-
return
|
|
535
|
+
if (type === "private") {
|
|
536
|
+
return "Private Message";
|
|
496
537
|
}
|
|
497
538
|
|
|
498
539
|
return _.capitalize(values.entityName);
|
|
@@ -502,14 +543,17 @@ var Circles = /*#__PURE__*/function (_Component) {
|
|
|
502
543
|
if (circle.IsPrivate) {
|
|
503
544
|
return "PM: ".concat(circle.Audience.map(function (user) {
|
|
504
545
|
return user.displayName;
|
|
505
|
-
}).join(
|
|
546
|
+
}).join(", "));
|
|
506
547
|
}
|
|
507
548
|
|
|
508
549
|
return circle.Title;
|
|
509
550
|
});
|
|
510
551
|
|
|
511
552
|
_this.state = {
|
|
512
|
-
userSearch:
|
|
553
|
+
userSearch: "",
|
|
554
|
+
sortBy: "newest",
|
|
555
|
+
showUnreadOnly: false,
|
|
556
|
+
pollingInterval: null
|
|
513
557
|
};
|
|
514
558
|
return _this;
|
|
515
559
|
}
|
|
@@ -517,27 +561,77 @@ var Circles = /*#__PURE__*/function (_Component) {
|
|
|
517
561
|
_createClass(Circles, [{
|
|
518
562
|
key: "componentDidMount",
|
|
519
563
|
value: function componentDidMount() {
|
|
520
|
-
this
|
|
564
|
+
var _this2 = this;
|
|
565
|
+
|
|
566
|
+
this.getData(); // Poll for updates every 10 seconds
|
|
567
|
+
|
|
568
|
+
this.pollingInterval = setInterval(function () {
|
|
569
|
+
_this2.getData();
|
|
570
|
+
}, 10000);
|
|
571
|
+
}
|
|
572
|
+
}, {
|
|
573
|
+
key: "componentWillUnmount",
|
|
574
|
+
value: function componentWillUnmount() {
|
|
575
|
+
if (this.pollingInterval) {
|
|
576
|
+
clearInterval(this.pollingInterval);
|
|
577
|
+
}
|
|
578
|
+
}
|
|
579
|
+
}, {
|
|
580
|
+
key: "isCircleUnread",
|
|
581
|
+
value: function isCircleUnread(circle) {
|
|
582
|
+
var userId = this.props.user.Id;
|
|
583
|
+
|
|
584
|
+
if (!circle.Unread || !circle.Unread[userId]) {
|
|
585
|
+
return false;
|
|
586
|
+
}
|
|
587
|
+
|
|
588
|
+
return circle.Unread[userId] > 0;
|
|
589
|
+
}
|
|
590
|
+
}, {
|
|
591
|
+
key: "getUnreadCount",
|
|
592
|
+
value: function getUnreadCount(circle) {
|
|
593
|
+
var userId = this.props.user.Id;
|
|
594
|
+
|
|
595
|
+
if (!circle.Unread || !circle.Unread[userId]) {
|
|
596
|
+
return 0;
|
|
597
|
+
}
|
|
598
|
+
|
|
599
|
+
return circle.Unread[userId];
|
|
521
600
|
}
|
|
522
601
|
}, {
|
|
523
602
|
key: "getCircles",
|
|
524
603
|
value: function getCircles() {
|
|
525
|
-
var
|
|
604
|
+
var _this3 = this;
|
|
526
605
|
|
|
527
606
|
var result = this.props.circles;
|
|
528
607
|
|
|
529
608
|
if (this.state.selectedTypeFilter) {
|
|
530
609
|
result = _.filter(result, function (circle) {
|
|
531
|
-
return
|
|
610
|
+
return _this3.state.selectedTypeFilter === "circle" ? !circle.IsPrivate : circle.IsPrivate;
|
|
532
611
|
});
|
|
533
612
|
}
|
|
534
613
|
|
|
535
614
|
if (this.state.selectedUserFilter) {
|
|
536
615
|
result = _.filter(result, function (circle) {
|
|
537
616
|
return _.some(circle.Audience, function (user) {
|
|
538
|
-
return user.userId ===
|
|
617
|
+
return user.userId === _this3.state.selectedUserFilter.userId;
|
|
539
618
|
});
|
|
540
619
|
});
|
|
620
|
+
} // Apply sorting
|
|
621
|
+
|
|
622
|
+
|
|
623
|
+
result = _.sortBy(result, function (circle) {
|
|
624
|
+
return moment(circle.Changed).valueOf();
|
|
625
|
+
});
|
|
626
|
+
|
|
627
|
+
if (this.state.sortBy === "newest") {
|
|
628
|
+
result.reverse();
|
|
629
|
+
|
|
630
|
+
if (this.state.showUnreadOnly) {
|
|
631
|
+
result = _.filter(result, function (circle) {
|
|
632
|
+
return _this3.isCircleUnread(circle);
|
|
633
|
+
});
|
|
634
|
+
}
|
|
541
635
|
}
|
|
542
636
|
|
|
543
637
|
return result;
|
|
@@ -545,7 +639,7 @@ var Circles = /*#__PURE__*/function (_Component) {
|
|
|
545
639
|
}, {
|
|
546
640
|
key: "getUsers",
|
|
547
641
|
value: function getUsers() {
|
|
548
|
-
var
|
|
642
|
+
var _this4 = this;
|
|
549
643
|
|
|
550
644
|
var users = [];
|
|
551
645
|
this.props.circles.forEach(function (circle) {
|
|
@@ -555,10 +649,10 @@ var Circles = /*#__PURE__*/function (_Component) {
|
|
|
555
649
|
});
|
|
556
650
|
users = _.sortBy(_.uniqBy(users, function (user) {
|
|
557
651
|
return user.userId;
|
|
558
|
-
}),
|
|
652
|
+
}), "displayName");
|
|
559
653
|
return _.filter(users, function (u) {
|
|
560
|
-
if (!_.isEmpty(
|
|
561
|
-
return (u.displayName ||
|
|
654
|
+
if (!_.isEmpty(_this4.state.userSearch)) {
|
|
655
|
+
return (u.displayName || "").toLowerCase().indexOf(_this4.state.userSearch.toLowerCase()) > -1;
|
|
562
656
|
}
|
|
563
657
|
|
|
564
658
|
return true;
|
|
@@ -567,7 +661,7 @@ var Circles = /*#__PURE__*/function (_Component) {
|
|
|
567
661
|
}, {
|
|
568
662
|
key: "validateCircleAdmin",
|
|
569
663
|
value: function validateCircleAdmin(circle, onlyCreator) {
|
|
570
|
-
var
|
|
664
|
+
var _this5 = this;
|
|
571
665
|
|
|
572
666
|
if (Session$3.validateAccess(this.props.auth.site, values.permission, this.props.auth)) {
|
|
573
667
|
return true;
|
|
@@ -578,13 +672,13 @@ var Circles = /*#__PURE__*/function (_Component) {
|
|
|
578
672
|
}
|
|
579
673
|
|
|
580
674
|
return _.some(circle.Audience, function (user) {
|
|
581
|
-
return user.userId ===
|
|
675
|
+
return user.userId === _this5.props.user.Id && user.isAdmin;
|
|
582
676
|
});
|
|
583
677
|
}
|
|
584
678
|
}, {
|
|
585
679
|
key: "renderRow",
|
|
586
680
|
value: function renderRow(circle) {
|
|
587
|
-
var
|
|
681
|
+
var _this6 = this;
|
|
588
682
|
|
|
589
683
|
return /*#__PURE__*/React.createElement("tr", {
|
|
590
684
|
key: circle.Id
|
|
@@ -592,7 +686,7 @@ var Circles = /*#__PURE__*/function (_Component) {
|
|
|
592
686
|
className: "table-TitleColumn"
|
|
593
687
|
}, /*#__PURE__*/React.createElement(Link, {
|
|
594
688
|
to: "/".concat(values.featureKey, "/").concat(values.entityKey, "/").concat(circle.Id)
|
|
595
|
-
}, this.getTitle(circle))), /*#__PURE__*/React.createElement("td", null, moment(circle.Changed).local().format(
|
|
689
|
+
}, this.getTitle(circle))), /*#__PURE__*/React.createElement("td", null, moment(circle.Changed).local().format("D MMM YYYY")), /*#__PURE__*/React.createElement("td", null, circle.Audience.map(function (user) {
|
|
596
690
|
return /*#__PURE__*/React.createElement(Components$4.ProfilePic, {
|
|
597
691
|
size: 30,
|
|
598
692
|
image: user.profilePic,
|
|
@@ -603,8 +697,8 @@ var Circles = /*#__PURE__*/function (_Component) {
|
|
|
603
697
|
className: "table-options"
|
|
604
698
|
}, /*#__PURE__*/React.createElement("div", {
|
|
605
699
|
style: {
|
|
606
|
-
display:
|
|
607
|
-
alignItems:
|
|
700
|
+
display: "flex",
|
|
701
|
+
alignItems: "center"
|
|
608
702
|
}
|
|
609
703
|
}, this.validateCircleAdmin(circle) && !circle.IsPrivate && /*#__PURE__*/React.createElement(Link, {
|
|
610
704
|
to: "/".concat(values.featureKey, "/edit/").concat(circle.Id)
|
|
@@ -613,19 +707,19 @@ var Circles = /*#__PURE__*/function (_Component) {
|
|
|
613
707
|
fontSize: 20,
|
|
614
708
|
padding: 5,
|
|
615
709
|
marginLeft: 12,
|
|
616
|
-
cursor:
|
|
710
|
+
cursor: "pointer"
|
|
617
711
|
},
|
|
618
712
|
name: "pencil"
|
|
619
713
|
})), this.validateCircleAdmin(circle, true) && !circle.IsPrivate && /*#__PURE__*/React.createElement("a", {
|
|
620
714
|
onClick: function onClick() {
|
|
621
|
-
|
|
715
|
+
_this6.removeCircle(circle);
|
|
622
716
|
}
|
|
623
717
|
}, /*#__PURE__*/React.createElement(FontAwesome, {
|
|
624
718
|
style: {
|
|
625
719
|
fontSize: 20,
|
|
626
720
|
padding: 5,
|
|
627
721
|
marginLeft: 12,
|
|
628
|
-
cursor:
|
|
722
|
+
cursor: "pointer"
|
|
629
723
|
},
|
|
630
724
|
name: "minus-circle"
|
|
631
725
|
})))));
|
|
@@ -633,11 +727,21 @@ var Circles = /*#__PURE__*/function (_Component) {
|
|
|
633
727
|
}, {
|
|
634
728
|
key: "renderFilters",
|
|
635
729
|
value: function renderFilters() {
|
|
730
|
+
var _this7 = this;
|
|
731
|
+
|
|
636
732
|
var userFilter = /*#__PURE__*/React.createElement(Components$4.Tag, {
|
|
637
733
|
className: "marginRight-10",
|
|
638
734
|
onClick: this.openUserFilter,
|
|
639
735
|
text: "User"
|
|
640
736
|
});
|
|
737
|
+
var unreadFilter = /*#__PURE__*/React.createElement(Components$4.Tag, {
|
|
738
|
+
className: "marginRight-10",
|
|
739
|
+
onClick: function onClick() {
|
|
740
|
+
return _this7.selectUnreadFilter(!_this7.state.showUnreadOnly);
|
|
741
|
+
},
|
|
742
|
+
leftIcon: this.state.showUnreadOnly ? "check" : null,
|
|
743
|
+
text: "Unread Only"
|
|
744
|
+
});
|
|
641
745
|
var typeFilter = /*#__PURE__*/React.createElement(Components$4.Tag, {
|
|
642
746
|
className: "marginRight-10",
|
|
643
747
|
onClick: this.openTypeFilter,
|
|
@@ -672,12 +776,28 @@ var Circles = /*#__PURE__*/function (_Component) {
|
|
|
672
776
|
}, /*#__PURE__*/React.createElement(Components$4.Text, {
|
|
673
777
|
type: "h5",
|
|
674
778
|
className: "marginRight-20"
|
|
675
|
-
}, "Filter by"), userFilter, typeFilter
|
|
779
|
+
}, "Filter by"), userFilter, unreadFilter, typeFilter, /*#__PURE__*/React.createElement(Components$4.Text, {
|
|
780
|
+
type: "h5",
|
|
781
|
+
className: "marginRight-20 marginLeft-20"
|
|
782
|
+
}, "Sort by:"), /*#__PURE__*/React.createElement(Components$4.Tag, {
|
|
783
|
+
className: "marginRight-10",
|
|
784
|
+
onClick: function onClick() {
|
|
785
|
+
return _this7.selectSort("newest");
|
|
786
|
+
},
|
|
787
|
+
leftIcon: this.state.sortBy === "newest" ? "check" : null,
|
|
788
|
+
text: "Newest first"
|
|
789
|
+
}), /*#__PURE__*/React.createElement(Components$4.Tag, {
|
|
790
|
+
onClick: function onClick() {
|
|
791
|
+
return _this7.selectSort("oldest");
|
|
792
|
+
},
|
|
793
|
+
leftIcon: this.state.sortBy === "oldest" ? "check" : null,
|
|
794
|
+
text: "Oldest first"
|
|
795
|
+
}));
|
|
676
796
|
}
|
|
677
797
|
}, {
|
|
678
798
|
key: "renderUserFilterPopup",
|
|
679
799
|
value: function renderUserFilterPopup() {
|
|
680
|
-
var
|
|
800
|
+
var _this8 = this;
|
|
681
801
|
|
|
682
802
|
if (!this.state.userFilterOpen) {
|
|
683
803
|
return null;
|
|
@@ -697,7 +817,7 @@ var Circles = /*#__PURE__*/function (_Component) {
|
|
|
697
817
|
placeholder: "Enter name",
|
|
698
818
|
value: this.state.userSearch,
|
|
699
819
|
onChange: function onChange(e) {
|
|
700
|
-
return
|
|
820
|
+
return _this8.onHandleChange(e);
|
|
701
821
|
},
|
|
702
822
|
alwaysShowLabel: true
|
|
703
823
|
}), this.getUsers().map(function (user) {
|
|
@@ -705,7 +825,7 @@ var Circles = /*#__PURE__*/function (_Component) {
|
|
|
705
825
|
key: user.userId,
|
|
706
826
|
user: user,
|
|
707
827
|
onClick: function onClick() {
|
|
708
|
-
|
|
828
|
+
_this8.selectUserFilter(user);
|
|
709
829
|
}
|
|
710
830
|
});
|
|
711
831
|
}));
|
|
@@ -713,7 +833,7 @@ var Circles = /*#__PURE__*/function (_Component) {
|
|
|
713
833
|
}, {
|
|
714
834
|
key: "renderTypeFilterPopup",
|
|
715
835
|
value: function renderTypeFilterPopup() {
|
|
716
|
-
var
|
|
836
|
+
var _this9 = this;
|
|
717
837
|
|
|
718
838
|
if (!this.state.typeFilterOpen) {
|
|
719
839
|
return null;
|
|
@@ -727,13 +847,13 @@ var Circles = /*#__PURE__*/function (_Component) {
|
|
|
727
847
|
onClose: this.closeTypeFilter
|
|
728
848
|
}, /*#__PURE__*/React.createElement(Components$4.Tag, {
|
|
729
849
|
onClick: function onClick() {
|
|
730
|
-
|
|
850
|
+
_this9.selectTypeFilter("circle");
|
|
731
851
|
},
|
|
732
852
|
text: _.capitalize(values.entityName),
|
|
733
853
|
className: "marginRight-10"
|
|
734
854
|
}), /*#__PURE__*/React.createElement(Components$4.Tag, {
|
|
735
855
|
onClick: function onClick() {
|
|
736
|
-
|
|
856
|
+
_this9.selectTypeFilter("private");
|
|
737
857
|
},
|
|
738
858
|
text: "Private Message"
|
|
739
859
|
}));
|
|
@@ -741,7 +861,7 @@ var Circles = /*#__PURE__*/function (_Component) {
|
|
|
741
861
|
}, {
|
|
742
862
|
key: "render",
|
|
743
863
|
value: function render() {
|
|
744
|
-
var
|
|
864
|
+
var _this10 = this;
|
|
745
865
|
|
|
746
866
|
return /*#__PURE__*/React.createElement("div", null, this.renderTypeFilterPopup(), this.renderUserFilterPopup(), /*#__PURE__*/React.createElement(Components$4.Header, null, this.canAddNew() && /*#__PURE__*/React.createElement(Components$4.AddButton, {
|
|
747
867
|
onClick: this.onAddNew,
|
|
@@ -758,14 +878,14 @@ var Circles = /*#__PURE__*/function (_Component) {
|
|
|
758
878
|
condensed: true,
|
|
759
879
|
hover: true,
|
|
760
880
|
style: {
|
|
761
|
-
minWidth:
|
|
881
|
+
minWidth: "100%"
|
|
762
882
|
}
|
|
763
883
|
}, /*#__PURE__*/React.createElement("thead", null, /*#__PURE__*/React.createElement("tr", null, /*#__PURE__*/React.createElement("th", null, "Title"), /*#__PURE__*/React.createElement("th", null, "Last updated"), /*#__PURE__*/React.createElement("th", null, "Members"), /*#__PURE__*/React.createElement("th", {
|
|
764
884
|
style: {
|
|
765
885
|
width: 50
|
|
766
886
|
}
|
|
767
887
|
}))), /*#__PURE__*/React.createElement("tbody", null, this.getCircles().map(function (circle) {
|
|
768
|
-
return
|
|
888
|
+
return _this10.renderRow(circle);
|
|
769
889
|
})))));
|
|
770
890
|
}
|
|
771
891
|
}]);
|
|
@@ -1729,6 +1849,32 @@ var Circle = /*#__PURE__*/function (_Component) {
|
|
|
1729
1849
|
});
|
|
1730
1850
|
});
|
|
1731
1851
|
|
|
1852
|
+
_defineProperty(_assertThisInitialized(_this), "markCircleAsRead", /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee5() {
|
|
1853
|
+
return _regeneratorRuntime.wrap(function _callee5$(_context5) {
|
|
1854
|
+
while (1) {
|
|
1855
|
+
switch (_context5.prev = _context5.next) {
|
|
1856
|
+
case 0:
|
|
1857
|
+
_context5.prev = 0;
|
|
1858
|
+
_context5.next = 3;
|
|
1859
|
+
return circleActions.markAsRead(_this.state.circleId, _this.props.user.Id);
|
|
1860
|
+
|
|
1861
|
+
case 3:
|
|
1862
|
+
_context5.next = 8;
|
|
1863
|
+
break;
|
|
1864
|
+
|
|
1865
|
+
case 5:
|
|
1866
|
+
_context5.prev = 5;
|
|
1867
|
+
_context5.t0 = _context5["catch"](0);
|
|
1868
|
+
console.error("Failed to mark circle as read:", _context5.t0);
|
|
1869
|
+
|
|
1870
|
+
case 8:
|
|
1871
|
+
case "end":
|
|
1872
|
+
return _context5.stop();
|
|
1873
|
+
}
|
|
1874
|
+
}
|
|
1875
|
+
}, _callee5, null, [[0, 5]]);
|
|
1876
|
+
})));
|
|
1877
|
+
|
|
1732
1878
|
_defineProperty(_assertThisInitialized(_this), "sendMessage", function () {
|
|
1733
1879
|
var message = {
|
|
1734
1880
|
_id: Helper.randomString(),
|
|
@@ -1813,6 +1959,7 @@ var Circle = /*#__PURE__*/function (_Component) {
|
|
|
1813
1959
|
_createClass(Circle, [{
|
|
1814
1960
|
key: "componentDidMount",
|
|
1815
1961
|
value: function componentDidMount() {
|
|
1962
|
+
this.markCircleAsRead();
|
|
1816
1963
|
this.checkGetData();
|
|
1817
1964
|
this.connect();
|
|
1818
1965
|
this.props.setNavData({
|
|
@@ -1949,8 +2096,8 @@ var Circle = /*#__PURE__*/function (_Component) {
|
|
|
1949
2096
|
display: this.state.imageInputShowing ? "block" : "none"
|
|
1950
2097
|
}
|
|
1951
2098
|
}, /*#__PURE__*/React.createElement(Components$2.ImageInput, {
|
|
1952
|
-
ref: function ref(
|
|
1953
|
-
_this5.imageInput =
|
|
2099
|
+
ref: function ref(_ref6) {
|
|
2100
|
+
_this5.imageInput = _ref6;
|
|
1954
2101
|
},
|
|
1955
2102
|
multiple: true,
|
|
1956
2103
|
limit: 10,
|
|
@@ -1964,8 +2111,8 @@ var Circle = /*#__PURE__*/function (_Component) {
|
|
|
1964
2111
|
display: this.state.fileInputShowing ? "block" : "none"
|
|
1965
2112
|
}
|
|
1966
2113
|
}, /*#__PURE__*/React.createElement(Components$2.FileInput, {
|
|
1967
|
-
ref: function ref(
|
|
1968
|
-
_this5.fileInput =
|
|
2114
|
+
ref: function ref(_ref7) {
|
|
2115
|
+
_this5.fileInput = _ref7;
|
|
1969
2116
|
},
|
|
1970
2117
|
multiple: true,
|
|
1971
2118
|
limit: 10,
|
|
@@ -2259,8 +2406,8 @@ var Circle = /*#__PURE__*/function (_Component) {
|
|
|
2259
2406
|
}, /*#__PURE__*/React.createElement("div", {
|
|
2260
2407
|
className: "chat_newMessage"
|
|
2261
2408
|
}, this.renderChatInput()), this.renderReplyTo(), /*#__PURE__*/React.createElement("div", {
|
|
2262
|
-
ref: function ref(
|
|
2263
|
-
return _this8.chat =
|
|
2409
|
+
ref: function ref(_ref8) {
|
|
2410
|
+
return _this8.chat = _ref8;
|
|
2264
2411
|
},
|
|
2265
2412
|
className: "chat_messages"
|
|
2266
2413
|
}, _.isEmpty(this.state.messages) && !_.isEmpty(this.state.messageDate) && this.renderEmptyDate(), this.state.messages.map(function (m) {
|