@plusscommunities/pluss-circles-web 1.0.16-beta.0 → 1.0.17
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 +81 -20
- package/dist/index.esm.js +228 -167
- package/dist/index.umd.js +82 -21
- package/package.json +2 -2
- package/src/feature.config.js +1 -0
- package/src/screens/Circle.js +60 -0
package/dist/index.esm.js
CHANGED
|
@@ -7,7 +7,7 @@ import _inherits from '@babel/runtime/helpers/inherits';
|
|
|
7
7
|
import _possibleConstructorReturn from '@babel/runtime/helpers/possibleConstructorReturn';
|
|
8
8
|
import _getPrototypeOf from '@babel/runtime/helpers/getPrototypeOf';
|
|
9
9
|
import _regeneratorRuntime from '@babel/runtime/regenerator';
|
|
10
|
-
import React
|
|
10
|
+
import React, { Component } from 'react';
|
|
11
11
|
import { connect } from 'react-redux';
|
|
12
12
|
import _ from 'lodash';
|
|
13
13
|
import moment from 'moment';
|
|
@@ -552,29 +552,29 @@ var Circles = /*#__PURE__*/function (_Component) {
|
|
|
552
552
|
value: function renderRow(circle) {
|
|
553
553
|
var _this5 = this;
|
|
554
554
|
|
|
555
|
-
return /*#__PURE__*/React
|
|
555
|
+
return /*#__PURE__*/React.createElement("tr", {
|
|
556
556
|
key: circle.Id
|
|
557
|
-
}, /*#__PURE__*/React
|
|
557
|
+
}, /*#__PURE__*/React.createElement("td", {
|
|
558
558
|
className: "table-TitleColumn"
|
|
559
|
-
}, /*#__PURE__*/React
|
|
559
|
+
}, /*#__PURE__*/React.createElement(Link, {
|
|
560
560
|
to: "/".concat(values.featureKey, "/").concat(values.entityKey, "/").concat(circle.Id)
|
|
561
|
-
}, this.getTitle(circle))), /*#__PURE__*/React
|
|
562
|
-
return /*#__PURE__*/React
|
|
561
|
+
}, 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) {
|
|
562
|
+
return /*#__PURE__*/React.createElement(Components$3.ProfilePic, {
|
|
563
563
|
size: 30,
|
|
564
564
|
image: user.profilePic,
|
|
565
565
|
hoverText: user.displayName,
|
|
566
566
|
containerClass: "circleTableProfilePic"
|
|
567
567
|
});
|
|
568
|
-
})), /*#__PURE__*/React
|
|
568
|
+
})), /*#__PURE__*/React.createElement("td", {
|
|
569
569
|
className: "table-options"
|
|
570
|
-
}, /*#__PURE__*/React
|
|
570
|
+
}, /*#__PURE__*/React.createElement("div", {
|
|
571
571
|
style: {
|
|
572
572
|
display: 'flex',
|
|
573
573
|
alignItems: 'center'
|
|
574
574
|
}
|
|
575
|
-
}, this.validateCircleAdmin(circle) && !circle.IsPrivate && /*#__PURE__*/React
|
|
575
|
+
}, this.validateCircleAdmin(circle) && !circle.IsPrivate && /*#__PURE__*/React.createElement(Link, {
|
|
576
576
|
to: "/".concat(values.featureKey, "/edit/").concat(circle.Id)
|
|
577
|
-
}, /*#__PURE__*/React
|
|
577
|
+
}, /*#__PURE__*/React.createElement(FontAwesome, {
|
|
578
578
|
style: {
|
|
579
579
|
fontSize: 20,
|
|
580
580
|
padding: 5,
|
|
@@ -582,11 +582,11 @@ var Circles = /*#__PURE__*/function (_Component) {
|
|
|
582
582
|
cursor: 'pointer'
|
|
583
583
|
},
|
|
584
584
|
name: "pencil"
|
|
585
|
-
})), this.validateCircleAdmin(circle, true) && !circle.IsPrivate && /*#__PURE__*/React
|
|
585
|
+
})), this.validateCircleAdmin(circle, true) && !circle.IsPrivate && /*#__PURE__*/React.createElement("a", {
|
|
586
586
|
onClick: function onClick() {
|
|
587
587
|
_this5.removeCircle(circle);
|
|
588
588
|
}
|
|
589
|
-
}, /*#__PURE__*/React
|
|
589
|
+
}, /*#__PURE__*/React.createElement(FontAwesome, {
|
|
590
590
|
style: {
|
|
591
591
|
fontSize: 20,
|
|
592
592
|
padding: 5,
|
|
@@ -599,24 +599,24 @@ var Circles = /*#__PURE__*/function (_Component) {
|
|
|
599
599
|
}, {
|
|
600
600
|
key: "renderFilters",
|
|
601
601
|
value: function renderFilters() {
|
|
602
|
-
var userFilter = /*#__PURE__*/React
|
|
602
|
+
var userFilter = /*#__PURE__*/React.createElement(Components$3.Tag, {
|
|
603
603
|
className: "marginRight-10",
|
|
604
604
|
onClick: this.openUserFilter,
|
|
605
605
|
text: "User"
|
|
606
606
|
});
|
|
607
|
-
var typeFilter = /*#__PURE__*/React
|
|
607
|
+
var typeFilter = /*#__PURE__*/React.createElement(Components$3.Tag, {
|
|
608
608
|
className: "marginRight-10",
|
|
609
609
|
onClick: this.openTypeFilter,
|
|
610
610
|
text: "Type"
|
|
611
611
|
});
|
|
612
612
|
|
|
613
613
|
if (this.state.selectedUserFilter) {
|
|
614
|
-
userFilter = /*#__PURE__*/React
|
|
614
|
+
userFilter = /*#__PURE__*/React.createElement(Components$3.Tag, {
|
|
615
615
|
className: "marginRight-10",
|
|
616
616
|
onClick: this.openUserFilter,
|
|
617
617
|
rightIcon: "close",
|
|
618
618
|
rightClick: this.removeUserFilter
|
|
619
|
-
}, /*#__PURE__*/React
|
|
619
|
+
}, /*#__PURE__*/React.createElement(Components$3.UserListing, {
|
|
620
620
|
size: 15,
|
|
621
621
|
user: this.state.selectedUserFilter,
|
|
622
622
|
textClass: "tag_text"
|
|
@@ -624,7 +624,7 @@ var Circles = /*#__PURE__*/function (_Component) {
|
|
|
624
624
|
}
|
|
625
625
|
|
|
626
626
|
if (this.state.selectedTypeFilter) {
|
|
627
|
-
typeFilter = /*#__PURE__*/React
|
|
627
|
+
typeFilter = /*#__PURE__*/React.createElement(Components$3.Tag, {
|
|
628
628
|
className: "marginRight-10",
|
|
629
629
|
onClick: this.openTypeFilter,
|
|
630
630
|
rightIcon: "close",
|
|
@@ -633,9 +633,9 @@ var Circles = /*#__PURE__*/function (_Component) {
|
|
|
633
633
|
});
|
|
634
634
|
}
|
|
635
635
|
|
|
636
|
-
return /*#__PURE__*/React
|
|
636
|
+
return /*#__PURE__*/React.createElement("div", {
|
|
637
637
|
className: "flex flex-center marginTop-20"
|
|
638
|
-
}, /*#__PURE__*/React
|
|
638
|
+
}, /*#__PURE__*/React.createElement(Components$3.Text, {
|
|
639
639
|
type: "h5",
|
|
640
640
|
className: "marginRight-20"
|
|
641
641
|
}, "Filter by"), userFilter, typeFilter);
|
|
@@ -649,14 +649,14 @@ var Circles = /*#__PURE__*/function (_Component) {
|
|
|
649
649
|
return null;
|
|
650
650
|
}
|
|
651
651
|
|
|
652
|
-
return /*#__PURE__*/React
|
|
652
|
+
return /*#__PURE__*/React.createElement(Components$3.Popup, {
|
|
653
653
|
title: "Select User",
|
|
654
654
|
maxWidth: 600,
|
|
655
655
|
minWidth: 400,
|
|
656
656
|
minHeight: 400,
|
|
657
657
|
hasPadding: true,
|
|
658
658
|
onClose: this.closeUserFilter
|
|
659
|
-
}, /*#__PURE__*/React
|
|
659
|
+
}, /*#__PURE__*/React.createElement(Components$3.GenericInput, {
|
|
660
660
|
id: "userSearch",
|
|
661
661
|
type: "text",
|
|
662
662
|
label: "Search",
|
|
@@ -667,7 +667,7 @@ var Circles = /*#__PURE__*/function (_Component) {
|
|
|
667
667
|
},
|
|
668
668
|
alwaysShowLabel: true
|
|
669
669
|
}), this.getUsers().map(function (user) {
|
|
670
|
-
return /*#__PURE__*/React
|
|
670
|
+
return /*#__PURE__*/React.createElement(Components$3.UserListing, {
|
|
671
671
|
key: user.userId,
|
|
672
672
|
user: user,
|
|
673
673
|
onClick: function onClick() {
|
|
@@ -685,19 +685,19 @@ var Circles = /*#__PURE__*/function (_Component) {
|
|
|
685
685
|
return null;
|
|
686
686
|
}
|
|
687
687
|
|
|
688
|
-
return /*#__PURE__*/React
|
|
688
|
+
return /*#__PURE__*/React.createElement(Components$3.Popup, {
|
|
689
689
|
title: "Select Type",
|
|
690
690
|
maxWidth: 600,
|
|
691
691
|
minWidth: 400,
|
|
692
692
|
hasPadding: true,
|
|
693
693
|
onClose: this.closeTypeFilter
|
|
694
|
-
}, /*#__PURE__*/React
|
|
694
|
+
}, /*#__PURE__*/React.createElement(Components$3.Tag, {
|
|
695
695
|
onClick: function onClick() {
|
|
696
696
|
_this7.selectTypeFilter('circle');
|
|
697
697
|
},
|
|
698
698
|
text: _.capitalize(values.entityName),
|
|
699
699
|
className: "marginRight-10"
|
|
700
|
-
}), /*#__PURE__*/React
|
|
700
|
+
}), /*#__PURE__*/React.createElement(Components$3.Tag, {
|
|
701
701
|
onClick: function onClick() {
|
|
702
702
|
_this7.selectTypeFilter('private');
|
|
703
703
|
},
|
|
@@ -709,15 +709,15 @@ var Circles = /*#__PURE__*/function (_Component) {
|
|
|
709
709
|
value: function render() {
|
|
710
710
|
var _this8 = this;
|
|
711
711
|
|
|
712
|
-
return /*#__PURE__*/React
|
|
712
|
+
return /*#__PURE__*/React.createElement("div", null, this.renderTypeFilterPopup(), this.renderUserFilterPopup(), /*#__PURE__*/React.createElement(Components$3.Header, null, this.canAddNew() && /*#__PURE__*/React.createElement(Components$3.AddButton, {
|
|
713
713
|
onClick: this.onAddNew,
|
|
714
714
|
text: "NEW ".concat(_.upperCase(values.entityName))
|
|
715
|
-
})), /*#__PURE__*/React
|
|
715
|
+
})), /*#__PURE__*/React.createElement("div", {
|
|
716
716
|
className: "pageContainer paddingVertical-20 paddingHorizontal-40"
|
|
717
|
-
}, /*#__PURE__*/React
|
|
717
|
+
}, /*#__PURE__*/React.createElement(Components$3.Text, {
|
|
718
718
|
type: "h1",
|
|
719
719
|
className: ""
|
|
720
|
-
}, values.textFeatureTitle), this.renderFilters(), /*#__PURE__*/React
|
|
720
|
+
}, values.textFeatureTitle), this.renderFilters(), /*#__PURE__*/React.createElement(Table, {
|
|
721
721
|
className: "plussTable",
|
|
722
722
|
striped: true,
|
|
723
723
|
bordered: true,
|
|
@@ -726,13 +726,13 @@ var Circles = /*#__PURE__*/function (_Component) {
|
|
|
726
726
|
style: {
|
|
727
727
|
minWidth: '100%'
|
|
728
728
|
}
|
|
729
|
-
}, /*#__PURE__*/React
|
|
729
|
+
}, /*#__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", {
|
|
730
730
|
style: {
|
|
731
731
|
width: 50
|
|
732
732
|
}
|
|
733
|
-
}))), /*#__PURE__*/React
|
|
733
|
+
}))), /*#__PURE__*/React.createElement("tbody", null, this.getCircles().map(function (circle) {
|
|
734
734
|
return _this8.renderRow(circle);
|
|
735
|
-
}))), /*#__PURE__*/React
|
|
735
|
+
}))), /*#__PURE__*/React.createElement("div", {
|
|
736
736
|
className: "hub_tidioPadding"
|
|
737
737
|
})));
|
|
738
738
|
}
|
|
@@ -1083,7 +1083,7 @@ var AddCircle = /*#__PURE__*/function (_Component) {
|
|
|
1083
1083
|
key: "renderSuccess",
|
|
1084
1084
|
value: function renderSuccess() {
|
|
1085
1085
|
if (!this.state.success) return null;
|
|
1086
|
-
return /*#__PURE__*/React
|
|
1086
|
+
return /*#__PURE__*/React.createElement(Components$2.SuccessPopup, {
|
|
1087
1087
|
text: "".concat(_.capitalize(values.entityName), " has been ").concat(this.state.circleId == null ? 'added' : 'edited'),
|
|
1088
1088
|
buttons: [{
|
|
1089
1089
|
type: 'outlined',
|
|
@@ -1100,12 +1100,12 @@ var AddCircle = /*#__PURE__*/function (_Component) {
|
|
|
1100
1100
|
var _this4 = this;
|
|
1101
1101
|
|
|
1102
1102
|
if (this.state.updating) {
|
|
1103
|
-
return /*#__PURE__*/React
|
|
1103
|
+
return /*#__PURE__*/React.createElement(Components$2.Button, {
|
|
1104
1104
|
buttonType: "secondary"
|
|
1105
1105
|
}, "Saving...");
|
|
1106
1106
|
}
|
|
1107
1107
|
|
|
1108
|
-
return /*#__PURE__*/React
|
|
1108
|
+
return /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement(Components$2.Button, {
|
|
1109
1109
|
inline: true,
|
|
1110
1110
|
buttonType: "tertiary",
|
|
1111
1111
|
onClick: function onClick() {
|
|
@@ -1115,7 +1115,7 @@ var AddCircle = /*#__PURE__*/function (_Component) {
|
|
|
1115
1115
|
style: {
|
|
1116
1116
|
marginRight: 16
|
|
1117
1117
|
}
|
|
1118
|
-
}, "Cancel"), /*#__PURE__*/React
|
|
1118
|
+
}, "Cancel"), /*#__PURE__*/React.createElement(Components$2.Button, {
|
|
1119
1119
|
inline: true,
|
|
1120
1120
|
buttonType: "primary",
|
|
1121
1121
|
onClick: this.onSave,
|
|
@@ -1127,9 +1127,9 @@ var AddCircle = /*#__PURE__*/function (_Component) {
|
|
|
1127
1127
|
value: function renderVisibility() {
|
|
1128
1128
|
var _this5 = this;
|
|
1129
1129
|
|
|
1130
|
-
return /*#__PURE__*/React
|
|
1130
|
+
return /*#__PURE__*/React.createElement("div", {
|
|
1131
1131
|
className: "optionsContent_bottom"
|
|
1132
|
-
}, /*#__PURE__*/React
|
|
1132
|
+
}, /*#__PURE__*/React.createElement(Components$2.RadioButton, {
|
|
1133
1133
|
label: "Do you want to make this ".concat(values.entityName, " a public ").concat(values.entityName, "?"),
|
|
1134
1134
|
isActive: this.state.isPublic,
|
|
1135
1135
|
options: [{
|
|
@@ -1149,7 +1149,7 @@ var AddCircle = /*#__PURE__*/function (_Component) {
|
|
|
1149
1149
|
});
|
|
1150
1150
|
}
|
|
1151
1151
|
}]
|
|
1152
|
-
}), /*#__PURE__*/React
|
|
1152
|
+
}), /*#__PURE__*/React.createElement("div", {
|
|
1153
1153
|
className: "genericInput-help",
|
|
1154
1154
|
style: {
|
|
1155
1155
|
marginTop: 4
|
|
@@ -1159,7 +1159,7 @@ var AddCircle = /*#__PURE__*/function (_Component) {
|
|
|
1159
1159
|
}, {
|
|
1160
1160
|
key: "renderSelectedOption",
|
|
1161
1161
|
value: function renderSelectedOption() {
|
|
1162
|
-
return /*#__PURE__*/React
|
|
1162
|
+
return /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement("div", {
|
|
1163
1163
|
style: {
|
|
1164
1164
|
display: this.state.selectedOption === 'visibility' ? 'block' : 'none'
|
|
1165
1165
|
}
|
|
@@ -1184,7 +1184,7 @@ var AddCircle = /*#__PURE__*/function (_Component) {
|
|
|
1184
1184
|
return null;
|
|
1185
1185
|
}
|
|
1186
1186
|
|
|
1187
|
-
return /*#__PURE__*/React
|
|
1187
|
+
return /*#__PURE__*/React.createElement(Components$2.OptionsSection, {
|
|
1188
1188
|
options: options,
|
|
1189
1189
|
selected: this.state.selectedOption,
|
|
1190
1190
|
selectOption: this.selectOption
|
|
@@ -1195,14 +1195,14 @@ var AddCircle = /*#__PURE__*/function (_Component) {
|
|
|
1195
1195
|
value: function renderMain() {
|
|
1196
1196
|
var _this6 = this;
|
|
1197
1197
|
|
|
1198
|
-
return /*#__PURE__*/React
|
|
1198
|
+
return /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement("div", {
|
|
1199
1199
|
className: "padding-60 paddingVertical-40 bottomDivideBorder"
|
|
1200
|
-
}, /*#__PURE__*/React
|
|
1200
|
+
}, /*#__PURE__*/React.createElement(Components$2.Text, {
|
|
1201
1201
|
type: "formTitleLarge",
|
|
1202
1202
|
className: "marginBottom-24"
|
|
1203
|
-
}, this.state.circleId == null ? 'New' : 'Edit', " ", _.capitalize(values.entityName)), /*#__PURE__*/React
|
|
1203
|
+
}, this.state.circleId == null ? 'New' : 'Edit', " ", _.capitalize(values.entityName)), /*#__PURE__*/React.createElement("div", {
|
|
1204
1204
|
className: "flex flex-reverse"
|
|
1205
|
-
}, /*#__PURE__*/React
|
|
1205
|
+
}, /*#__PURE__*/React.createElement(Components$2.ImageInput, {
|
|
1206
1206
|
ref: function ref(_ref2) {
|
|
1207
1207
|
_this6.imageInput = _ref2;
|
|
1208
1208
|
},
|
|
@@ -1212,9 +1212,9 @@ var AddCircle = /*#__PURE__*/function (_Component) {
|
|
|
1212
1212
|
containerStyle: {
|
|
1213
1213
|
marginLeft: 40
|
|
1214
1214
|
}
|
|
1215
|
-
}), /*#__PURE__*/React
|
|
1215
|
+
}), /*#__PURE__*/React.createElement("div", {
|
|
1216
1216
|
className: "flex-1"
|
|
1217
|
-
}, /*#__PURE__*/React
|
|
1217
|
+
}, /*#__PURE__*/React.createElement(Components$2.GenericInput, {
|
|
1218
1218
|
id: "title",
|
|
1219
1219
|
type: "text",
|
|
1220
1220
|
label: "Title",
|
|
@@ -1231,18 +1231,18 @@ var AddCircle = /*#__PURE__*/function (_Component) {
|
|
|
1231
1231
|
showError: function showError() {
|
|
1232
1232
|
return _this6.state.showWarnings && _.isEmpty(_this6.state.title);
|
|
1233
1233
|
}
|
|
1234
|
-
})))), /*#__PURE__*/React
|
|
1234
|
+
})))), /*#__PURE__*/React.createElement("div", {
|
|
1235
1235
|
className: "padding-60 paddingVertical-40 bottomDivideBorder"
|
|
1236
|
-
}, /*#__PURE__*/React
|
|
1236
|
+
}, /*#__PURE__*/React.createElement(Components$2.Text, {
|
|
1237
1237
|
type: "formTitleMedium"
|
|
1238
|
-
}, "Members"), /*#__PURE__*/React
|
|
1238
|
+
}, "Members"), /*#__PURE__*/React.createElement("div", {
|
|
1239
1239
|
className: "flex marginTop-20"
|
|
1240
|
-
}, /*#__PURE__*/React
|
|
1240
|
+
}, /*#__PURE__*/React.createElement("div", {
|
|
1241
1241
|
className: "flex-1"
|
|
1242
|
-
}, /*#__PURE__*/React
|
|
1242
|
+
}, /*#__PURE__*/React.createElement(Components$2.Text, {
|
|
1243
1243
|
type: "formTitleSmall",
|
|
1244
1244
|
className: "marginBottom-10"
|
|
1245
|
-
}, "Select Users"), /*#__PURE__*/React
|
|
1245
|
+
}, "Select Users"), /*#__PURE__*/React.createElement(Components$2.GenericInput, {
|
|
1246
1246
|
id: "userSearch",
|
|
1247
1247
|
type: "text",
|
|
1248
1248
|
label: "Search",
|
|
@@ -1253,32 +1253,32 @@ var AddCircle = /*#__PURE__*/function (_Component) {
|
|
|
1253
1253
|
},
|
|
1254
1254
|
alwaysShowLabel: true
|
|
1255
1255
|
}), this.getShownUsers().map(function (user) {
|
|
1256
|
-
return /*#__PURE__*/React
|
|
1256
|
+
return /*#__PURE__*/React.createElement(Components$2.UserListing, {
|
|
1257
1257
|
key: user.userId,
|
|
1258
1258
|
user: user,
|
|
1259
1259
|
onClick: function onClick() {
|
|
1260
1260
|
_this6.onSelectUser(user);
|
|
1261
1261
|
}
|
|
1262
1262
|
});
|
|
1263
|
-
})), /*#__PURE__*/React
|
|
1263
|
+
})), /*#__PURE__*/React.createElement("div", {
|
|
1264
1264
|
className: "flex-1"
|
|
1265
|
-
}, /*#__PURE__*/React
|
|
1265
|
+
}, /*#__PURE__*/React.createElement(Components$2.Text, {
|
|
1266
1266
|
type: "formTitleSmall",
|
|
1267
1267
|
className: "marginBottom-10"
|
|
1268
1268
|
}, "Selected"), this.state.selectedUsers.map(function (user) {
|
|
1269
|
-
return /*#__PURE__*/React
|
|
1269
|
+
return /*#__PURE__*/React.createElement(Components$2.UserListing, {
|
|
1270
1270
|
key: user.userId,
|
|
1271
1271
|
user: user,
|
|
1272
|
-
rightContent: /*#__PURE__*/React
|
|
1272
|
+
rightContent: /*#__PURE__*/React.createElement("div", {
|
|
1273
1273
|
className: "flex flex-reverse flex-center"
|
|
1274
|
-
}, /*#__PURE__*/React
|
|
1274
|
+
}, /*#__PURE__*/React.createElement(Components$2.SVGIcon, {
|
|
1275
1275
|
className: "removeIcon marginLeft-8",
|
|
1276
1276
|
icon: "close",
|
|
1277
1277
|
colour: Colours$2.COLOUR_DUSK,
|
|
1278
1278
|
onClick: function onClick() {
|
|
1279
1279
|
_this6.onSelectUser(user);
|
|
1280
1280
|
}
|
|
1281
|
-
}), /*#__PURE__*/React
|
|
1281
|
+
}), /*#__PURE__*/React.createElement(Components$2.StatusButton, {
|
|
1282
1282
|
isActive: user.isAdmin,
|
|
1283
1283
|
activate: function activate() {
|
|
1284
1284
|
_this6.addAdmin(user);
|
|
@@ -1298,11 +1298,11 @@ var AddCircle = /*#__PURE__*/function (_Component) {
|
|
|
1298
1298
|
key: "render",
|
|
1299
1299
|
value: function render() {
|
|
1300
1300
|
var success = this.state.success;
|
|
1301
|
-
return /*#__PURE__*/React
|
|
1301
|
+
return /*#__PURE__*/React.createElement(Components$2.OverlayPage, null, /*#__PURE__*/React.createElement(Components$2.OverlayPageContents, {
|
|
1302
1302
|
noBottomButtons: success
|
|
1303
|
-
}, /*#__PURE__*/React
|
|
1303
|
+
}, /*#__PURE__*/React.createElement(Components$2.OverlayPageSection, {
|
|
1304
1304
|
className: "pageSectionWrapper--newPopup"
|
|
1305
|
-
}, /*#__PURE__*/React
|
|
1305
|
+
}, /*#__PURE__*/React.createElement("div", null, this.renderSuccess(), !success && this.renderMain()))), /*#__PURE__*/React.createElement(Components$2.OverlayPageBottomButtons, null, this.renderSubmit()));
|
|
1306
1306
|
}
|
|
1307
1307
|
}]);
|
|
1308
1308
|
|
|
@@ -1536,6 +1536,17 @@ var Circle = /*#__PURE__*/function (_Component) {
|
|
|
1536
1536
|
});
|
|
1537
1537
|
});
|
|
1538
1538
|
|
|
1539
|
+
_defineProperty(_assertThisInitialized(_this), "onReply", function (m) {
|
|
1540
|
+
_this.setState({
|
|
1541
|
+
replyingTo: m
|
|
1542
|
+
});
|
|
1543
|
+
|
|
1544
|
+
if (m) {
|
|
1545
|
+
var input = document.getElementById('messageInput');
|
|
1546
|
+
if (input) input.focus();
|
|
1547
|
+
}
|
|
1548
|
+
});
|
|
1549
|
+
|
|
1539
1550
|
_defineProperty(_assertThisInitialized(_this), "handleMessageDateChange", function (date) {
|
|
1540
1551
|
_this.setState({
|
|
1541
1552
|
messageDate: date,
|
|
@@ -1607,6 +1618,10 @@ var Circle = /*#__PURE__*/function (_Component) {
|
|
|
1607
1618
|
return;
|
|
1608
1619
|
}
|
|
1609
1620
|
|
|
1621
|
+
if (_this.state.replyingTo) {
|
|
1622
|
+
message.replyingTo = _this.state.replyingTo;
|
|
1623
|
+
}
|
|
1624
|
+
|
|
1610
1625
|
var clonedMessage = _.cloneDeep(message);
|
|
1611
1626
|
|
|
1612
1627
|
clonedMessage.uploading = true;
|
|
@@ -1629,6 +1644,8 @@ var Circle = /*#__PURE__*/function (_Component) {
|
|
|
1629
1644
|
});
|
|
1630
1645
|
|
|
1631
1646
|
setTimeout(function () {
|
|
1647
|
+
_this.onReply(null);
|
|
1648
|
+
|
|
1632
1649
|
_this.scrollToBottom();
|
|
1633
1650
|
|
|
1634
1651
|
_this.imageInput && _this.imageInput.getWrappedInstance().setValue(null);
|
|
@@ -1646,7 +1663,8 @@ var Circle = /*#__PURE__*/function (_Component) {
|
|
|
1646
1663
|
messages: [],
|
|
1647
1664
|
images: [],
|
|
1648
1665
|
files: [],
|
|
1649
|
-
membersExpanded: true
|
|
1666
|
+
membersExpanded: true,
|
|
1667
|
+
replyingTo: null
|
|
1650
1668
|
};
|
|
1651
1669
|
return _this;
|
|
1652
1670
|
}
|
|
@@ -1748,21 +1766,21 @@ var Circle = /*#__PURE__*/function (_Component) {
|
|
|
1748
1766
|
var _this5 = this;
|
|
1749
1767
|
|
|
1750
1768
|
if (!this.isMember()) {
|
|
1751
|
-
return /*#__PURE__*/React
|
|
1769
|
+
return /*#__PURE__*/React.createElement(Components$1.Text, {
|
|
1752
1770
|
type: "highlightedHelp",
|
|
1753
1771
|
className: "chat_noMessage"
|
|
1754
1772
|
}, "You can't send a message to this ", _.capitalize(values.entityName), " as you are not a member.");
|
|
1755
1773
|
}
|
|
1756
1774
|
|
|
1757
|
-
return /*#__PURE__*/React
|
|
1775
|
+
return /*#__PURE__*/React.createElement("div", {
|
|
1758
1776
|
className: "chat_inputFlex"
|
|
1759
|
-
}, /*#__PURE__*/React
|
|
1777
|
+
}, /*#__PURE__*/React.createElement(FontAwesome, {
|
|
1760
1778
|
className: "chat_send",
|
|
1761
1779
|
name: "paper-plane",
|
|
1762
1780
|
onClick: this.sendMessage
|
|
1763
|
-
}), /*#__PURE__*/React
|
|
1781
|
+
}), /*#__PURE__*/React.createElement("div", {
|
|
1764
1782
|
className: "chat_inputContainer"
|
|
1765
|
-
}, /*#__PURE__*/React
|
|
1783
|
+
}, /*#__PURE__*/React.createElement(Components$1.GenericInput, {
|
|
1766
1784
|
id: "messageInput",
|
|
1767
1785
|
type: "textarea",
|
|
1768
1786
|
className: "chat_input",
|
|
@@ -1776,20 +1794,20 @@ var Circle = /*#__PURE__*/function (_Component) {
|
|
|
1776
1794
|
minHeight: 50
|
|
1777
1795
|
},
|
|
1778
1796
|
onKeyDown: this.onKeyDown
|
|
1779
|
-
}), /*#__PURE__*/React
|
|
1797
|
+
}), /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement(FontAwesome, {
|
|
1780
1798
|
className: "chat_imageIcon".concat(this.state.imageInputShowing ? ' chat_imageIcon-selected' : ''),
|
|
1781
1799
|
name: "camera",
|
|
1782
1800
|
onClick: this.showImageInput
|
|
1783
|
-
}), /*#__PURE__*/React
|
|
1801
|
+
}), /*#__PURE__*/React.createElement(FontAwesome, {
|
|
1784
1802
|
className: "chat_imageIcon".concat(this.state.fileInputShowing ? ' chat_imageIcon-selected' : ''),
|
|
1785
1803
|
name: "paperclip",
|
|
1786
1804
|
onClick: this.showFileInput
|
|
1787
|
-
})), /*#__PURE__*/React
|
|
1805
|
+
})), /*#__PURE__*/React.createElement("div", {
|
|
1788
1806
|
className: "overflow-x",
|
|
1789
1807
|
style: {
|
|
1790
1808
|
display: this.state.imageInputShowing ? 'block' : 'none'
|
|
1791
1809
|
}
|
|
1792
|
-
}, /*#__PURE__*/React
|
|
1810
|
+
}, /*#__PURE__*/React.createElement(Components$1.ImageInput, {
|
|
1793
1811
|
ref: function ref(_ref4) {
|
|
1794
1812
|
_this5.imageInput = _ref4;
|
|
1795
1813
|
},
|
|
@@ -1799,12 +1817,12 @@ var Circle = /*#__PURE__*/function (_Component) {
|
|
|
1799
1817
|
noMenu: true,
|
|
1800
1818
|
noCompress: true,
|
|
1801
1819
|
noDownload: true
|
|
1802
|
-
})), /*#__PURE__*/React
|
|
1820
|
+
})), /*#__PURE__*/React.createElement("div", {
|
|
1803
1821
|
className: "overflow-x",
|
|
1804
1822
|
style: {
|
|
1805
1823
|
display: this.state.fileInputShowing ? 'block' : 'none'
|
|
1806
1824
|
}
|
|
1807
|
-
}, /*#__PURE__*/React
|
|
1825
|
+
}, /*#__PURE__*/React.createElement(Components$1.FileInput, {
|
|
1808
1826
|
ref: function ref(_ref5) {
|
|
1809
1827
|
_this5.fileInput = _ref5;
|
|
1810
1828
|
},
|
|
@@ -1819,71 +1837,85 @@ var Circle = /*#__PURE__*/function (_Component) {
|
|
|
1819
1837
|
}, {
|
|
1820
1838
|
key: "renderMessage",
|
|
1821
1839
|
value: function renderMessage(m) {
|
|
1840
|
+
var _this6 = this;
|
|
1841
|
+
|
|
1822
1842
|
if (m.system) {
|
|
1823
|
-
return /*#__PURE__*/React
|
|
1843
|
+
return /*#__PURE__*/React.createElement("div", {
|
|
1824
1844
|
key: m._id,
|
|
1825
1845
|
className: "message"
|
|
1826
|
-
}, /*#__PURE__*/React
|
|
1846
|
+
}, /*#__PURE__*/React.createElement(Components$1.Text, {
|
|
1827
1847
|
type: "h5",
|
|
1828
1848
|
className: "message_system"
|
|
1829
1849
|
}, m.text));
|
|
1830
1850
|
}
|
|
1831
1851
|
|
|
1832
1852
|
var isSelf = m.user._id === this.props.user.Id;
|
|
1833
|
-
return /*#__PURE__*/React
|
|
1853
|
+
return /*#__PURE__*/React.createElement("div", {
|
|
1834
1854
|
key: m._id,
|
|
1835
1855
|
className: "message".concat(isSelf ? ' message-self' : '').concat(m.uploading ? ' message-uploading' : '')
|
|
1836
|
-
}, /*#__PURE__*/React
|
|
1856
|
+
}, /*#__PURE__*/React.createElement(Components$1.Text, {
|
|
1837
1857
|
type: "h5-noUpper",
|
|
1838
1858
|
className: "message_time"
|
|
1839
|
-
}, moment.utc(m.createdAt).local().format('D MMM YYYY • h:mma')), /*#__PURE__*/React
|
|
1859
|
+
}, moment.utc(m.createdAt).local().format('D MMM YYYY • h:mma')), /*#__PURE__*/React.createElement("div", {
|
|
1840
1860
|
className: "message_inner"
|
|
1841
|
-
}, /*#__PURE__*/React
|
|
1861
|
+
}, /*#__PURE__*/React.createElement(Components$1.ProfilePic, {
|
|
1842
1862
|
size: 40,
|
|
1843
1863
|
image: m.user.avatar,
|
|
1844
1864
|
className: "message_profilePic"
|
|
1845
|
-
}), /*#__PURE__*/React
|
|
1865
|
+
}), /*#__PURE__*/React.createElement("div", {
|
|
1846
1866
|
className: "message_bubbleContainer"
|
|
1847
|
-
}, /*#__PURE__*/React
|
|
1867
|
+
}, /*#__PURE__*/React.createElement(Components$1.Text, {
|
|
1848
1868
|
type: "body",
|
|
1849
1869
|
className: "message_name"
|
|
1850
|
-
}, m.user.name), /*#__PURE__*/React
|
|
1870
|
+
}, m.user.name, m.replyingTo ? " replied to ".concat(m.replyingTo.user.name) : ''), m.replyingTo && /*#__PURE__*/React.createElement("div", {
|
|
1871
|
+
className: "message_replyBubble"
|
|
1872
|
+
}, /*#__PURE__*/React.createElement(Components$1.Text, {
|
|
1873
|
+
type: "body",
|
|
1874
|
+
className: "message_text"
|
|
1875
|
+
}, Helper.toParagraphed((m.replyingTo.text || '').substr(0, 100)))), /*#__PURE__*/React.createElement("div", {
|
|
1851
1876
|
className: "message_bubble"
|
|
1852
|
-
}, /*#__PURE__*/React
|
|
1877
|
+
}, /*#__PURE__*/React.createElement(Components$1.Text, {
|
|
1853
1878
|
type: "body",
|
|
1854
1879
|
className: "message_text"
|
|
1855
|
-
}, Helper.toParagraphed(m.text)), /*#__PURE__*/React
|
|
1856
|
-
return /*#__PURE__*/React
|
|
1880
|
+
}, Helper.toParagraphed(m.text)), /*#__PURE__*/React.createElement("div", null, (m.image || []).map(function (url, i) {
|
|
1881
|
+
return /*#__PURE__*/React.createElement("a", {
|
|
1857
1882
|
href: url,
|
|
1858
1883
|
target: "_blank",
|
|
1859
1884
|
key: i
|
|
1860
|
-
}, /*#__PURE__*/React
|
|
1885
|
+
}, /*#__PURE__*/React.createElement("img", {
|
|
1861
1886
|
className: "message_image",
|
|
1862
1887
|
src: url,
|
|
1863
1888
|
alt: Helper.getFileName(url)
|
|
1864
1889
|
}));
|
|
1865
|
-
})), /*#__PURE__*/React
|
|
1866
|
-
return /*#__PURE__*/React
|
|
1890
|
+
})), /*#__PURE__*/React.createElement("div", null, (m.attachments || []).map(function (url, i) {
|
|
1891
|
+
return /*#__PURE__*/React.createElement(Components$1.Attachment, {
|
|
1867
1892
|
source: url,
|
|
1868
1893
|
key: i,
|
|
1869
1894
|
white: isSelf
|
|
1870
1895
|
});
|
|
1871
|
-
})))
|
|
1896
|
+
}))), /*#__PURE__*/React.createElement("div", {
|
|
1897
|
+
className: "message_reply"
|
|
1898
|
+
}, /*#__PURE__*/React.createElement(Components$1.Text, {
|
|
1899
|
+
type: "button",
|
|
1900
|
+
onClick: function onClick() {
|
|
1901
|
+
_this6.onReply(m);
|
|
1902
|
+
}
|
|
1903
|
+
}, "Reply")))));
|
|
1872
1904
|
}
|
|
1873
1905
|
}, {
|
|
1874
1906
|
key: "renderHeaderRight",
|
|
1875
1907
|
value: function renderHeaderRight() {
|
|
1876
1908
|
if (!this.validateCircleAdmin() || this.getCircle().IsPrivate) {
|
|
1877
|
-
return /*#__PURE__*/React
|
|
1909
|
+
return /*#__PURE__*/React.createElement("div", {
|
|
1878
1910
|
className: "flex flex-center"
|
|
1879
1911
|
});
|
|
1880
1912
|
}
|
|
1881
1913
|
|
|
1882
|
-
return /*#__PURE__*/React
|
|
1914
|
+
return /*#__PURE__*/React.createElement("div", {
|
|
1883
1915
|
className: "flex flex-center"
|
|
1884
|
-
}, /*#__PURE__*/React
|
|
1916
|
+
}, /*#__PURE__*/React.createElement(Link, {
|
|
1885
1917
|
to: "/".concat(values.featureKey, "/edit/").concat(this.state.circleId)
|
|
1886
|
-
}, /*#__PURE__*/React
|
|
1918
|
+
}, /*#__PURE__*/React.createElement(FontAwesome, {
|
|
1887
1919
|
className: "header_back",
|
|
1888
1920
|
name: "cog"
|
|
1889
1921
|
})));
|
|
@@ -1900,135 +1932,164 @@ var Circle = /*#__PURE__*/function (_Component) {
|
|
|
1900
1932
|
key: "renderSideBar",
|
|
1901
1933
|
value: function renderSideBar() {
|
|
1902
1934
|
var members = this.getCircle().Audience || [];
|
|
1903
|
-
return /*#__PURE__*/React
|
|
1935
|
+
return /*#__PURE__*/React.createElement("div", {
|
|
1904
1936
|
className: "chat_sideBar"
|
|
1905
|
-
}, /*#__PURE__*/React
|
|
1937
|
+
}, /*#__PURE__*/React.createElement("div", {
|
|
1906
1938
|
className: "chat_section"
|
|
1907
|
-
}, /*#__PURE__*/React
|
|
1939
|
+
}, /*#__PURE__*/React.createElement("div", {
|
|
1908
1940
|
className: "chat_section_titleSection"
|
|
1909
|
-
}, /*#__PURE__*/React
|
|
1941
|
+
}, /*#__PURE__*/React.createElement(FontAwesome, {
|
|
1910
1942
|
className: "chat_section_titleSection_caret",
|
|
1911
1943
|
name: "chevron-".concat(this.state.membersExpanded ? 'up' : 'down'),
|
|
1912
1944
|
onClick: this.toggleMembers
|
|
1913
|
-
}), /*#__PURE__*/React
|
|
1945
|
+
}), /*#__PURE__*/React.createElement("div", {
|
|
1914
1946
|
className: "flex-1"
|
|
1915
|
-
}, /*#__PURE__*/React
|
|
1947
|
+
}, /*#__PURE__*/React.createElement(Components$1.Text, {
|
|
1916
1948
|
type: "formTitleMedium"
|
|
1917
|
-
}, "Member", Helper.getPluralS(members.length), " (", members.length, ")"))), this.state.membersExpanded && /*#__PURE__*/React
|
|
1949
|
+
}, "Member", Helper.getPluralS(members.length), " (", members.length, ")"))), this.state.membersExpanded && /*#__PURE__*/React.createElement("div", {
|
|
1918
1950
|
className: "paddingTop-8"
|
|
1919
1951
|
}, members.map(function (user) {
|
|
1920
|
-
return /*#__PURE__*/React
|
|
1952
|
+
return /*#__PURE__*/React.createElement(Components$1.UserListing, {
|
|
1921
1953
|
user: user
|
|
1922
1954
|
});
|
|
1923
|
-
}))), /*#__PURE__*/React
|
|
1955
|
+
}))), /*#__PURE__*/React.createElement("div", {
|
|
1924
1956
|
className: "chat_section"
|
|
1925
|
-
}, /*#__PURE__*/React
|
|
1957
|
+
}, /*#__PURE__*/React.createElement("div", {
|
|
1926
1958
|
className: "chat_section_titleSection"
|
|
1927
|
-
}, /*#__PURE__*/React
|
|
1959
|
+
}, /*#__PURE__*/React.createElement(FontAwesome, {
|
|
1928
1960
|
className: "chat_section_titleSection_caret",
|
|
1929
1961
|
name: "chevron-".concat(this.state.imagesExpanded ? 'up' : 'down'),
|
|
1930
1962
|
onClick: this.toggleImages
|
|
1931
|
-
}), /*#__PURE__*/React
|
|
1963
|
+
}), /*#__PURE__*/React.createElement("div", {
|
|
1932
1964
|
className: "flex-1"
|
|
1933
|
-
}, /*#__PURE__*/React
|
|
1965
|
+
}, /*#__PURE__*/React.createElement(Components$1.Text, {
|
|
1934
1966
|
type: "formTitleMedium"
|
|
1935
|
-
}, "Image", Helper.getPluralS(this.state.images.length), " (", this.state.images.length, ")"))), this.state.imagesExpanded && /*#__PURE__*/React
|
|
1967
|
+
}, "Image", Helper.getPluralS(this.state.images.length), " (", this.state.images.length, ")"))), this.state.imagesExpanded && /*#__PURE__*/React.createElement("div", {
|
|
1936
1968
|
className: "paddingTop-8"
|
|
1937
1969
|
}, this.state.images.map(function (image, i) {
|
|
1938
|
-
return /*#__PURE__*/React
|
|
1970
|
+
return /*#__PURE__*/React.createElement("a", {
|
|
1939
1971
|
href: image.Url,
|
|
1940
1972
|
target: "_blank"
|
|
1941
|
-
}, /*#__PURE__*/React
|
|
1973
|
+
}, /*#__PURE__*/React.createElement("img", {
|
|
1942
1974
|
src: image.Url,
|
|
1943
1975
|
className: "chat_section_image",
|
|
1944
1976
|
alt: Helper.getFileName(image.Url)
|
|
1945
1977
|
}));
|
|
1946
|
-
}))), /*#__PURE__*/React
|
|
1978
|
+
}))), /*#__PURE__*/React.createElement("div", {
|
|
1947
1979
|
className: "chat_section"
|
|
1948
|
-
}, /*#__PURE__*/React
|
|
1980
|
+
}, /*#__PURE__*/React.createElement("div", {
|
|
1949
1981
|
className: "chat_section_titleSection"
|
|
1950
|
-
}, /*#__PURE__*/React
|
|
1982
|
+
}, /*#__PURE__*/React.createElement(FontAwesome, {
|
|
1951
1983
|
className: "chat_section_titleSection_caret",
|
|
1952
1984
|
name: "chevron-".concat(this.state.filesExpanded ? 'up' : 'down'),
|
|
1953
1985
|
onClick: this.toggleFiles
|
|
1954
|
-
}), /*#__PURE__*/React
|
|
1986
|
+
}), /*#__PURE__*/React.createElement("div", {
|
|
1955
1987
|
className: "flex-1"
|
|
1956
|
-
}, /*#__PURE__*/React
|
|
1988
|
+
}, /*#__PURE__*/React.createElement(Components$1.Text, {
|
|
1957
1989
|
type: "formTitleMedium"
|
|
1958
|
-
}, "File", Helper.getPluralS(this.state.files.length), " (", this.state.files.length, ")"))), this.state.filesExpanded && /*#__PURE__*/React
|
|
1990
|
+
}, "File", Helper.getPluralS(this.state.files.length), " (", this.state.files.length, ")"))), this.state.filesExpanded && /*#__PURE__*/React.createElement("div", {
|
|
1959
1991
|
className: "paddingTop-8"
|
|
1960
1992
|
}, this.state.files.map(function (file, i) {
|
|
1961
|
-
return /*#__PURE__*/React
|
|
1993
|
+
return /*#__PURE__*/React.createElement(Components$1.Attachment, {
|
|
1962
1994
|
source: file.Url,
|
|
1963
1995
|
key: i
|
|
1964
1996
|
});
|
|
1965
1997
|
}))));
|
|
1966
1998
|
}
|
|
1999
|
+
}, {
|
|
2000
|
+
key: "renderReplyTo",
|
|
2001
|
+
value: function renderReplyTo() {
|
|
2002
|
+
var _this7 = this;
|
|
2003
|
+
|
|
2004
|
+
if (!this.state.replyingTo) {
|
|
2005
|
+
return null;
|
|
2006
|
+
}
|
|
2007
|
+
|
|
2008
|
+
var m = this.state.replyingTo;
|
|
2009
|
+
return /*#__PURE__*/React.createElement("div", {
|
|
2010
|
+
className: "chat_replyTo"
|
|
2011
|
+
}, /*#__PURE__*/React.createElement("div", {
|
|
2012
|
+
className: "chat_replyTo_container"
|
|
2013
|
+
}, /*#__PURE__*/React.createElement(Components$1.Text, {
|
|
2014
|
+
type: "h5"
|
|
2015
|
+
}, "Replying to ", m && m.user && !_.isEmpty(m.user.displayName) ? m.user.displayName : ''), m && !_.isEmpty(m.text) && /*#__PURE__*/React.createElement(Components$1.Text, {
|
|
2016
|
+
type: "body"
|
|
2017
|
+
}, m.text.substr(0, 50))), /*#__PURE__*/React.createElement("div", {
|
|
2018
|
+
className: "chat_replyTo_remove"
|
|
2019
|
+
}, /*#__PURE__*/React.createElement(Components$1.SVGIcon, {
|
|
2020
|
+
className: "removeIcon",
|
|
2021
|
+
icon: "close",
|
|
2022
|
+
onClick: function onClick() {
|
|
2023
|
+
_this7.onReply(null);
|
|
2024
|
+
},
|
|
2025
|
+
colour: Colours$1.COLOUR_DUSK
|
|
2026
|
+
})));
|
|
2027
|
+
}
|
|
1967
2028
|
}, {
|
|
1968
2029
|
key: "render",
|
|
1969
2030
|
value: function render() {
|
|
1970
|
-
var
|
|
2031
|
+
var _this8 = this;
|
|
1971
2032
|
|
|
1972
|
-
return /*#__PURE__*/React
|
|
2033
|
+
return /*#__PURE__*/React.createElement(Components$1.OverlayPage, {
|
|
1973
2034
|
fullPage: true,
|
|
1974
2035
|
fullPageStyle: {
|
|
1975
2036
|
display: 'flex',
|
|
1976
2037
|
flexDirection: 'column'
|
|
1977
2038
|
}
|
|
1978
|
-
}, /*#__PURE__*/React
|
|
2039
|
+
}, /*#__PURE__*/React.createElement(Components$1.Header, {
|
|
1979
2040
|
rightContent: this.renderHeaderRight()
|
|
1980
|
-
}, /*#__PURE__*/React
|
|
2041
|
+
}, /*#__PURE__*/React.createElement(FontAwesome, {
|
|
1981
2042
|
className: "header_back",
|
|
1982
2043
|
name: "angle-left",
|
|
1983
2044
|
onClick: function onClick() {
|
|
1984
2045
|
window.history.back();
|
|
1985
2046
|
}
|
|
1986
|
-
}), /*#__PURE__*/React
|
|
2047
|
+
}), /*#__PURE__*/React.createElement(Components$1.Text, {
|
|
1987
2048
|
type: "formTitleLarge",
|
|
1988
2049
|
className: "header_title"
|
|
1989
|
-
}, this.getTitle())), /*#__PURE__*/React
|
|
2050
|
+
}, this.getTitle())), /*#__PURE__*/React.createElement("div", {
|
|
1990
2051
|
className: "flex flex-1 flex-reverse overflow-hidden"
|
|
1991
|
-
}, this.renderSideBar(), /*#__PURE__*/React
|
|
2052
|
+
}, this.renderSideBar(), /*#__PURE__*/React.createElement("div", {
|
|
1992
2053
|
className: "flex-1 flex flex-column overflow-hidden"
|
|
1993
|
-
}, /*#__PURE__*/React
|
|
2054
|
+
}, /*#__PURE__*/React.createElement(Components$1.Header, {
|
|
1994
2055
|
onlyContainer: true
|
|
1995
|
-
}, /*#__PURE__*/React
|
|
2056
|
+
}, /*#__PURE__*/React.createElement("div", {
|
|
1996
2057
|
className: "flex flex-center flex-1 paddingHorizontal-16"
|
|
1997
|
-
}, /*#__PURE__*/React
|
|
2058
|
+
}, /*#__PURE__*/React.createElement(Components$1.Text, {
|
|
1998
2059
|
type: "h5",
|
|
1999
2060
|
className: "marginRight-20"
|
|
2000
|
-
}, "Filter by"), /*#__PURE__*/React
|
|
2061
|
+
}, "Filter by"), /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement(Components$1.GenericInput, {
|
|
2001
2062
|
id: "messageDate",
|
|
2002
2063
|
label: "Date",
|
|
2003
2064
|
alwaysShowLabel: true,
|
|
2004
2065
|
value: this.state.messageDateText,
|
|
2005
2066
|
readOnly: true,
|
|
2006
2067
|
onClick: function onClick() {
|
|
2007
|
-
return
|
|
2008
|
-
showMessageDate: !
|
|
2068
|
+
return _this8.setState({
|
|
2069
|
+
showMessageDate: !_this8.state.showMessageDate
|
|
2009
2070
|
});
|
|
2010
2071
|
},
|
|
2011
|
-
rightContent: !_.isEmpty(this.state.messageDate) && /*#__PURE__*/React
|
|
2072
|
+
rightContent: !_.isEmpty(this.state.messageDate) && /*#__PURE__*/React.createElement(Components$1.SVGIcon, {
|
|
2012
2073
|
colour: Colours$1.COLOUR_DUSK_LIGHT,
|
|
2013
2074
|
icon: "close",
|
|
2014
2075
|
className: "timepicker_clear",
|
|
2015
2076
|
onClick: this.onClearDate
|
|
2016
2077
|
})
|
|
2017
|
-
}), this.state.showMessageDate && /*#__PURE__*/React
|
|
2078
|
+
}), this.state.showMessageDate && /*#__PURE__*/React.createElement(Components$1.DatePicker, {
|
|
2018
2079
|
hideTop: true,
|
|
2019
2080
|
selectedDate: this.state.messageDate,
|
|
2020
2081
|
selectDate: this.handleMessageDateChange
|
|
2021
|
-
})))), /*#__PURE__*/React
|
|
2082
|
+
})))), /*#__PURE__*/React.createElement("div", {
|
|
2022
2083
|
className: "chat"
|
|
2023
|
-
}, /*#__PURE__*/React
|
|
2084
|
+
}, /*#__PURE__*/React.createElement("div", {
|
|
2024
2085
|
className: "chat_newMessage"
|
|
2025
|
-
}, this.renderChatInput()), /*#__PURE__*/React
|
|
2086
|
+
}, this.renderChatInput()), this.renderReplyTo(), /*#__PURE__*/React.createElement("div", {
|
|
2026
2087
|
ref: function ref(_ref6) {
|
|
2027
|
-
return
|
|
2088
|
+
return _this8.chat = _ref6;
|
|
2028
2089
|
},
|
|
2029
2090
|
className: "chat_messages"
|
|
2030
2091
|
}, _.isEmpty(this.state.messages) && !_.isEmpty(this.state.messageDate) && this.renderEmptyDate(), this.state.messages.map(function (m) {
|
|
2031
|
-
return
|
|
2092
|
+
return _this8.renderMessage(m);
|
|
2032
2093
|
}))))));
|
|
2033
2094
|
}
|
|
2034
2095
|
}]);
|
|
@@ -2106,7 +2167,7 @@ var ViewWidget = /*#__PURE__*/function (_Component) {
|
|
|
2106
2167
|
_createClass(ViewWidget, [{
|
|
2107
2168
|
key: "render",
|
|
2108
2169
|
value: function render() {
|
|
2109
|
-
return /*#__PURE__*/React
|
|
2170
|
+
return /*#__PURE__*/React.createElement("img", {
|
|
2110
2171
|
style: styles$3.image,
|
|
2111
2172
|
src: img$3,
|
|
2112
2173
|
alt: "widget"
|
|
@@ -2143,7 +2204,7 @@ var ViewFull = /*#__PURE__*/function (_Component) {
|
|
|
2143
2204
|
_createClass(ViewFull, [{
|
|
2144
2205
|
key: "render",
|
|
2145
2206
|
value: function render() {
|
|
2146
|
-
return /*#__PURE__*/React
|
|
2207
|
+
return /*#__PURE__*/React.createElement("img", {
|
|
2147
2208
|
style: styles$2.image,
|
|
2148
2209
|
src: img$2,
|
|
2149
2210
|
alt: "full"
|
|
@@ -2190,15 +2251,15 @@ var PreviewWidget = /*#__PURE__*/function (_Component) {
|
|
|
2190
2251
|
backgroundColor = _this$props.backgroundColor,
|
|
2191
2252
|
widgetTitle = _this$props.widgetTitle,
|
|
2192
2253
|
titleClassName = _this$props.titleClassName;
|
|
2193
|
-
return /*#__PURE__*/React
|
|
2254
|
+
return /*#__PURE__*/React.createElement("div", {
|
|
2194
2255
|
style: styles$1.container
|
|
2195
|
-
}, /*#__PURE__*/React
|
|
2256
|
+
}, /*#__PURE__*/React.createElement("img", {
|
|
2196
2257
|
style: _objectSpread$1(_objectSpread$1({}, styles$1.image), {}, {
|
|
2197
2258
|
backgroundColor: backgroundColor
|
|
2198
2259
|
}),
|
|
2199
2260
|
src: img$1,
|
|
2200
2261
|
alt: "previewWidget"
|
|
2201
|
-
}), /*#__PURE__*/React
|
|
2262
|
+
}), /*#__PURE__*/React.createElement("p", {
|
|
2202
2263
|
className: titleClassName,
|
|
2203
2264
|
style: styles$1.title
|
|
2204
2265
|
}, widgetTitle));
|
|
@@ -2245,11 +2306,11 @@ var PreviewFull = /*#__PURE__*/function (_Component) {
|
|
|
2245
2306
|
backgroundColor = _this$props.backgroundColor,
|
|
2246
2307
|
widgetTitle = _this$props.widgetTitle,
|
|
2247
2308
|
titleClassName = _this$props.titleClassName;
|
|
2248
|
-
return /*#__PURE__*/React
|
|
2309
|
+
return /*#__PURE__*/React.createElement("div", {
|
|
2249
2310
|
style: styles.container
|
|
2250
|
-
}, /*#__PURE__*/React
|
|
2311
|
+
}, /*#__PURE__*/React.createElement("p", {
|
|
2251
2312
|
className: titleClassName
|
|
2252
|
-
}, widgetTitle), /*#__PURE__*/React
|
|
2313
|
+
}, widgetTitle), /*#__PURE__*/React.createElement("img", {
|
|
2253
2314
|
style: _objectSpread(_objectSpread({}, styles.image), {}, {
|
|
2254
2315
|
backgroundColor: backgroundColor
|
|
2255
2316
|
}),
|
|
@@ -2291,10 +2352,10 @@ var PreviewGrid = /*#__PURE__*/function (_Component) {
|
|
|
2291
2352
|
value: function render() {
|
|
2292
2353
|
var colour = this.props.colour;
|
|
2293
2354
|
var path = 'M12.1875 0.9375C11.1548 0.9375 9.67896 1.25977 8.7616 1.87866C7.0166 1.94275 5.82275 3.16772 5.62683 5.11047C5.50781 6.30981 5.61768 7.16858 5.68909 7.73621C5.71472 7.93396 5.74219 8.15735 5.73303 8.22327C5.71838 8.31116 5.70374 8.39905 5.69092 8.48694C5.61401 8.4906 5.54626 8.50159 5.48584 8.51807C4.71313 8.72498 4.38904 9.85474 4.73511 11.1456C4.98596 12.0813 5.51147 12.7844 6.08643 13.0005C6.38306 13.9087 6.81885 14.8114 7.36084 15.6244L3.03955 18.1274C1.16455 19.2114 0 21.2329 0 23.399V26.7188C0 27.4933 0.631714 28.125 1.40625 28.125H19.519C20.6287 29.2786 22.1832 30 23.9062 30C27.2662 30 30 27.2662 30 23.9062C30 21.2402 28.2751 18.9734 25.8856 18.1494L21.8115 15.5127C22.4158 14.7931 22.9193 13.8977 23.2397 12.9419C23.6847 12.7478 24.0765 12.2168 24.267 11.4972C24.3823 11.0669 24.4061 10.6329 24.3311 10.274C24.2377 9.80896 23.9777 9.48669 23.6224 9.39148C23.5986 9.38416 23.573 9.37866 23.5455 9.375C23.4979 9.06738 23.4174 8.76709 23.2892 8.39905C23.3734 8.42102 23.465 8.45032 23.5437 8.48145C23.703 8.54919 23.8898 8.52173 24.0234 8.4082C24.1589 8.29651 24.2194 8.1189 24.1827 7.94861C23.606 5.31006 21.6467 3.73535 18.9441 3.73535H18.5962C18.5248 3.73535 18.446 3.74084 18.371 3.74634C17.1332 1.9519 15.1355 0.9375 12.6562 0.9375H12.1875ZM12.1875 1.875H12.6562C15.5017 1.875 17.5562 3.32886 18.3984 5.89783C18.0743 5.86121 17.7393 5.90149 17.5104 6.12305C17.3309 6.29333 17.1625 6.62109 17.3749 7.19971C17.6642 7.98523 17.7667 8.45032 17.7979 9.1095C17.8052 9.27795 17.9041 9.4281 18.0524 9.505C18.2007 9.58008 18.3801 9.57092 18.5211 9.47937C18.598 9.42993 18.6383 9.42444 18.6475 9.42444C18.761 9.46289 18.9661 10.0342 18.7335 10.9039C18.5028 11.7664 18.0597 12.1307 17.9224 12.1307C17.7136 12.1252 17.5323 12.2681 17.4738 12.4658C16.6827 15.1227 14.6155 17.8125 12.1875 17.8125C9.75952 17.8125 7.69226 15.1227 6.90125 12.4658C6.84265 12.2681 6.66138 12.1307 6.45264 12.1307C6.31531 12.1307 5.87219 11.7664 5.64148 10.9039C5.4071 10.0269 5.61768 9.45374 5.72571 9.42444C5.72754 9.42444 5.76782 9.42444 5.85205 9.47937C5.99487 9.57092 6.17432 9.58008 6.32263 9.505C6.47278 9.4281 6.56799 9.27795 6.57715 9.1095C6.58813 8.86414 6.61377 8.62061 6.65588 8.38623C6.69067 8.18481 6.66321 7.95959 6.61926 7.61719C6.55151 7.09167 6.45081 6.297 6.56067 5.20386C6.70898 3.70789 7.58606 2.8125 8.91357 2.8125C9.01611 2.8125 9.11316 2.77954 9.19556 2.71912C9.83826 2.23755 11.1237 1.875 12.1875 1.875ZM18.913 4.67285H18.9459C20.9491 4.67285 22.4121 5.66528 23.0566 7.42676C22.8461 7.43042 22.6392 7.48352 22.4835 7.63367C22.3224 7.78564 22.1704 8.07312 22.3535 8.56384C22.5641 9.13879 22.6392 9.47571 22.6611 9.95361C22.6685 10.1221 22.7655 10.2722 22.9156 10.3491C23.0621 10.4224 23.2361 10.415 23.3752 10.329C23.4338 10.4608 23.4851 10.7977 23.3624 11.2555C23.2178 11.792 22.9486 12.0612 22.8735 12.0831H22.8717C22.6648 12.0831 22.4817 12.2186 22.4231 12.4182C22.0312 13.7366 21.2512 14.9469 20.3394 15.6537C20.1343 15.813 20.0958 16.1078 20.2551 16.311C20.3467 16.4319 20.4858 16.4941 20.625 16.4941C20.7257 16.4941 20.8264 16.463 20.9125 16.3971C20.9912 16.3348 21.0681 16.2653 21.145 16.1993L23.6591 17.8253C22.9193 17.8546 22.2144 18.0103 21.5643 18.2812C21.4856 18.2318 21.416 18.1732 21.3354 18.1274L17.0142 15.6244C17.5562 14.8114 17.9901 13.9087 18.2886 13.0005C18.8617 12.7844 19.389 12.0831 19.6381 11.1456C19.9841 9.85474 19.6619 8.72498 18.8892 8.51807C18.8306 8.50342 18.761 8.4906 18.6841 8.48694C18.62 7.98523 18.4918 7.51648 18.2538 6.87561C18.2483 6.8573 18.2428 6.84082 18.2373 6.82617C18.4021 6.83899 18.6676 6.90674 18.8837 6.99463C19.0466 7.06238 19.2316 7.03491 19.3652 6.92139C19.4989 6.80969 19.5593 6.63208 19.5209 6.46179C19.3799 5.81543 19.1748 5.21667 18.913 4.67285ZM9.62219 4.74609C9.28711 4.7168 8.9502 4.86877 8.75793 5.16357L8.00537 6.30432C7.86255 6.52039 7.92297 6.81152 8.13904 6.95435C8.2196 7.00745 8.3075 7.03125 8.39539 7.03125C8.54919 7.03125 8.69751 6.95801 8.78906 6.82068L9.53979 5.67993L10.2722 6.03699C11.6071 6.68701 13.0994 7.03125 14.5844 7.03125H15.7819C16.04 7.03125 16.2506 6.82068 16.2506 6.5625C16.2506 6.30432 16.04 6.09375 15.7819 6.09375H14.5844C13.2404 6.09375 11.8909 5.78247 10.6842 5.19287L9.95178 4.83582C9.84558 4.78455 9.73389 4.75525 9.62219 4.74609ZM7.9248 16.3788C9.06555 17.7704 10.5487 18.75 12.1875 18.75C13.8263 18.75 15.3094 17.7722 16.4502 16.3806L20.6104 18.7885C18.9294 19.8761 17.8125 21.7621 17.8125 23.9062C17.8125 25.1147 18.1696 26.239 18.7793 27.1875H1.40625C1.14807 27.1875 0.9375 26.9769 0.9375 26.7188V23.399C0.9375 21.5662 1.92261 19.856 3.51013 18.9368L7.9248 16.3788ZM23.9062 18.75C26.7499 18.75 29.0625 21.0626 29.0625 23.9062C29.0625 26.7499 26.7499 29.0625 23.9062 29.0625C21.0626 29.0625 18.75 26.7499 18.75 23.9062C18.75 21.0626 21.0626 18.75 23.9062 18.75ZM8.4668 18.75C8.28369 18.739 8.10425 18.8361 8.01819 19.0082C7.90283 19.2407 7.99622 19.5227 8.22693 19.6381L11.9769 21.5131C12.0447 21.546 12.1161 21.5625 12.1875 21.5625C12.2589 21.5625 12.3322 21.546 12.3981 21.5131L16.1481 19.6381C16.3788 19.5227 16.4722 19.2407 16.3568 19.0082C16.2415 18.7775 15.9595 18.6841 15.7269 18.7994L12.1875 20.5701L8.64807 18.7994C8.58948 18.7701 8.52722 18.7555 8.4668 18.75ZM23.9062 20.625C23.6481 20.625 23.4375 20.8356 23.4375 21.0938V23.4375H21.0938C20.8356 23.4375 20.625 23.6481 20.625 23.9062C20.625 24.1644 20.8356 24.375 21.0938 24.375H23.4375V26.7188C23.4375 26.9769 23.6481 27.1875 23.9062 27.1875C24.1644 27.1875 24.375 26.9769 24.375 26.7188V24.375H26.7188C26.9769 24.375 27.1875 24.1644 27.1875 23.9062C27.1875 23.6481 26.9769 23.4375 26.7188 23.4375H24.375V21.0938C24.375 20.8356 24.1644 20.625 23.9062 20.625ZM2.8125 24.375C2.55432 24.375 2.34375 24.5856 2.34375 24.8438V25.7812C2.34375 26.0394 2.55432 26.25 2.8125 26.25C3.07068 26.25 3.28125 26.0394 3.28125 25.7812V24.8438C3.28125 24.5856 3.07068 24.375 2.8125 24.375ZM5.15625 24.375C4.89807 24.375 4.6875 24.5856 4.6875 24.8438V25.7812C4.6875 26.0394 4.89807 26.25 5.15625 26.25C5.41443 26.25 5.625 26.0394 5.625 25.7812V24.8438C5.625 24.5856 5.41443 24.375 5.15625 24.375ZM7.5 24.375C7.24182 24.375 7.03125 24.5856 7.03125 24.8438V25.7812C7.03125 26.0394 7.24182 26.25 7.5 26.25C7.75818 26.25 7.96875 26.0394 7.96875 25.7812V24.8438C7.96875 24.5856 7.75818 24.375 7.5 24.375ZM9.84375 24.375C9.58557 24.375 9.375 24.5856 9.375 24.8438V25.7812C9.375 26.0394 9.58557 26.25 9.84375 26.25C10.1019 26.25 10.3125 26.0394 10.3125 25.7812V24.8438C10.3125 24.5856 10.1019 24.375 9.84375 24.375ZM12.1875 24.375C11.9293 24.375 11.7188 24.5856 11.7188 24.8438V25.7812C11.7188 26.0394 11.9293 26.25 12.1875 26.25C12.4457 26.25 12.6562 26.0394 12.6562 25.7812V24.8438C12.6562 24.5856 12.4457 24.375 12.1875 24.375ZM14.5312 24.375C14.2731 24.375 14.0625 24.5856 14.0625 24.8438V25.7812C14.0625 26.0394 14.2731 26.25 14.5312 26.25C14.7894 26.25 15 26.0394 15 25.7812V24.8438C15 24.5856 14.7894 24.375 14.5312 24.375ZM16.875 24.375C16.6168 24.375 16.4062 24.5856 16.4062 24.8438V25.7812C16.4062 26.0394 16.6168 26.25 16.875 26.25C17.1332 26.25 17.3438 26.0394 17.3438 25.7812V24.8438C17.3438 24.5856 17.1332 24.375 16.875 24.375Z';
|
|
2294
|
-
return /*#__PURE__*/React
|
|
2355
|
+
return /*#__PURE__*/React.createElement("svg", {
|
|
2295
2356
|
xmlns: "http://www.w3.org/2000/svg",
|
|
2296
2357
|
viewBox: '0 0 30 30'
|
|
2297
|
-
}, /*#__PURE__*/React
|
|
2358
|
+
}, /*#__PURE__*/React.createElement("path", {
|
|
2298
2359
|
key: path.substring(0, 20),
|
|
2299
2360
|
d: path,
|
|
2300
2361
|
fill: colour
|
|
@@ -2308,46 +2369,46 @@ var PreviewGrid = /*#__PURE__*/function (_Component) {
|
|
|
2308
2369
|
var Components = PlussCore.Components,
|
|
2309
2370
|
Colours = PlussCore.Colours;
|
|
2310
2371
|
var FeaturePickerContent = (function () {
|
|
2311
|
-
return /*#__PURE__*/React
|
|
2372
|
+
return /*#__PURE__*/React.createElement("div", {
|
|
2312
2373
|
className: "fp2_widget_content fp2_widget_content-circles"
|
|
2313
|
-
}, /*#__PURE__*/React
|
|
2374
|
+
}, /*#__PURE__*/React.createElement("div", {
|
|
2314
2375
|
className: "fp2_widget_content_vListing"
|
|
2315
|
-
}, /*#__PURE__*/React
|
|
2376
|
+
}, /*#__PURE__*/React.createElement("div", {
|
|
2316
2377
|
className: "fp2_widget_silhouette fp2_widget_silhouette-circle"
|
|
2317
|
-
}, /*#__PURE__*/React
|
|
2378
|
+
}, /*#__PURE__*/React.createElement(Components.SVGIcon, {
|
|
2318
2379
|
icon: 'groups3',
|
|
2319
2380
|
colour: Colours.hexToRGBAstring(Colours.COLOUR_BRANDING_MAIN, 0.5)
|
|
2320
|
-
})), /*#__PURE__*/React
|
|
2381
|
+
})), /*#__PURE__*/React.createElement("div", {
|
|
2321
2382
|
className: "flex-1"
|
|
2322
|
-
}, /*#__PURE__*/React
|
|
2383
|
+
}, /*#__PURE__*/React.createElement("div", {
|
|
2323
2384
|
className: "fp2_widget_silhouette fp2_widget_silhouette-textLine"
|
|
2324
|
-
}), /*#__PURE__*/React
|
|
2385
|
+
}), /*#__PURE__*/React.createElement("div", {
|
|
2325
2386
|
className: "fp2_widget_silhouette fp2_widget_silhouette-textLineFull"
|
|
2326
|
-
}))), /*#__PURE__*/React
|
|
2387
|
+
}))), /*#__PURE__*/React.createElement("div", {
|
|
2327
2388
|
className: "fp2_widget_content_vListing"
|
|
2328
|
-
}, /*#__PURE__*/React
|
|
2389
|
+
}, /*#__PURE__*/React.createElement("div", {
|
|
2329
2390
|
className: "fp2_widget_silhouette fp2_widget_silhouette-circle"
|
|
2330
|
-
}, /*#__PURE__*/React
|
|
2391
|
+
}, /*#__PURE__*/React.createElement(Components.SVGIcon, {
|
|
2331
2392
|
icon: 'groups3',
|
|
2332
2393
|
colour: Colours.hexToRGBAstring(Colours.COLOUR_BRANDING_MAIN, 0.5)
|
|
2333
|
-
})), /*#__PURE__*/React
|
|
2394
|
+
})), /*#__PURE__*/React.createElement("div", {
|
|
2334
2395
|
className: "flex-1"
|
|
2335
|
-
}, /*#__PURE__*/React
|
|
2396
|
+
}, /*#__PURE__*/React.createElement("div", {
|
|
2336
2397
|
className: "fp2_widget_silhouette fp2_widget_silhouette-textLine"
|
|
2337
|
-
}), /*#__PURE__*/React
|
|
2398
|
+
}), /*#__PURE__*/React.createElement("div", {
|
|
2338
2399
|
className: "fp2_widget_silhouette fp2_widget_silhouette-textLineFull"
|
|
2339
|
-
}))), /*#__PURE__*/React
|
|
2400
|
+
}))), /*#__PURE__*/React.createElement("div", {
|
|
2340
2401
|
className: "fp2_widget_content_vListing"
|
|
2341
|
-
}, /*#__PURE__*/React
|
|
2402
|
+
}, /*#__PURE__*/React.createElement("div", {
|
|
2342
2403
|
className: "fp2_widget_silhouette fp2_widget_silhouette-circle"
|
|
2343
|
-
}, /*#__PURE__*/React
|
|
2404
|
+
}, /*#__PURE__*/React.createElement(Components.SVGIcon, {
|
|
2344
2405
|
icon: 'groups3',
|
|
2345
2406
|
colour: Colours.hexToRGBAstring(Colours.COLOUR_BRANDING_MAIN, 0.5)
|
|
2346
|
-
})), /*#__PURE__*/React
|
|
2407
|
+
})), /*#__PURE__*/React.createElement("div", {
|
|
2347
2408
|
className: "flex-1"
|
|
2348
|
-
}, /*#__PURE__*/React
|
|
2409
|
+
}, /*#__PURE__*/React.createElement("div", {
|
|
2349
2410
|
className: "fp2_widget_silhouette fp2_widget_silhouette-textLine"
|
|
2350
|
-
}), /*#__PURE__*/React
|
|
2411
|
+
}), /*#__PURE__*/React.createElement("div", {
|
|
2351
2412
|
className: "fp2_widget_silhouette fp2_widget_silhouette-textLineFull"
|
|
2352
2413
|
}))));
|
|
2353
2414
|
});
|