beem-component 1.1.2 → 1.1.6
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/assets/css/sidebar.css +20 -0
- package/dist/components/ChatBody/chatBody.js +6 -2
- package/dist/components/ChatComponents/ColorPicker/colorPicker.js +20 -0
- package/dist/components/ChatComponents/FormAccordion/FormAccordion.js +22 -0
- package/dist/components/ChatComponents/LabelAccordion/LabelAccordion.js +19 -0
- package/dist/components/ChatComponents/NoteAccordion/NoteAccordion.js +23 -0
- package/dist/components/ChatHeader/chatHeader.js +1 -1
- package/dist/components/Modals/modal.js +1 -1
- package/dist/components/index.js +32 -0
- package/package.json +1 -1
- package/src/App.js +24 -2
- package/src/Chat.js +26 -20
- package/src/ChatHeader.js +5 -2
- package/src/InfoAccordion.js +24 -0
- package/src/lib/assets/css/sidebar.css +20 -0
- package/src/lib/components/ChatBody/chatBody.js +6 -7
- package/src/lib/components/ChatComponents/ColorPicker/colorPicker.js +11 -0
- package/src/lib/components/ChatComponents/FormAccordion/FormAccordion.js +44 -0
- package/src/lib/components/ChatComponents/LabelAccordion/LabelAccordion.js +18 -0
- package/src/lib/components/ChatComponents/NoteAccordion/NoteAccordion.js +46 -0
- package/src/lib/components/ChatHeader/chatHeader.js +1 -4
- package/src/lib/components/Modals/modal.js +9 -0
- package/src/lib/components/index.js +11 -0
|
@@ -77,4 +77,24 @@
|
|
|
77
77
|
overflow: auto;
|
|
78
78
|
width: 25%;
|
|
79
79
|
border: 1px solid #E2E2E2;
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
.chat-header-buttons {
|
|
83
|
+
display: flex;
|
|
84
|
+
flex-direction: row;
|
|
85
|
+
margin-left: auto;
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
.chat-header-buttons>*:not(:last-child) {
|
|
89
|
+
margin-right: 0.5rem;
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
.chat-footer {
|
|
93
|
+
display: flex;
|
|
94
|
+
flex-direction: row;
|
|
95
|
+
align-items: center;
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
.chat-footer>*:not(:last-child) {
|
|
99
|
+
margin-right: 0.5rem;
|
|
80
100
|
}
|
|
@@ -133,8 +133,12 @@ BmChat.Details = function (_ref6) {
|
|
|
133
133
|
}));
|
|
134
134
|
};
|
|
135
135
|
|
|
136
|
-
BmChat.Footer = _styledComponents.default.div(_templateObject7 || (_templateObject7 = _taggedTemplateLiteral(["\n display: flex;\n flex-direction:
|
|
137
|
-
/*
|
|
136
|
+
BmChat.Footer = _styledComponents.default.div(_templateObject7 || (_templateObject7 = _taggedTemplateLiteral(["\n display: flex;\n flex-direction: column;\n ", "\n padding: 0.5rem 0.5rem;\n ", "\n ", "\n > *:not(:last-child) {\n margin-bottom: 0.5rem;\n }\n"])), ''
|
|
137
|
+
/* border-top: 0.071rem solid ${BmGrey200}; */
|
|
138
|
+
, ''
|
|
139
|
+
/* align-items: center; */
|
|
140
|
+
, ''
|
|
141
|
+
/* justify-content: center; */
|
|
138
142
|
);
|
|
139
143
|
var _default = BmChat;
|
|
140
144
|
exports.default = _default;
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.BmColorPicker = void 0;
|
|
7
|
+
|
|
8
|
+
var _styledComponents = _interopRequireDefault(require("styled-components"));
|
|
9
|
+
|
|
10
|
+
var _templateObject;
|
|
11
|
+
|
|
12
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
13
|
+
|
|
14
|
+
function _taggedTemplateLiteral(strings, raw) { if (!raw) { raw = strings.slice(0); } return Object.freeze(Object.defineProperties(strings, { raw: { value: Object.freeze(raw) } })); }
|
|
15
|
+
|
|
16
|
+
var BmColorPicker = _styledComponents.default.div(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n width: 1.429rem;\n height: 1.429rem;\n border-radius: 50%;\n background: ", ";\n > *:not(:last-child) {\n margin-right: 0.5rem;\n }\n"])), function (props) {
|
|
17
|
+
return props.color ? props.color : 'green';
|
|
18
|
+
});
|
|
19
|
+
|
|
20
|
+
exports.BmColorPicker = BmColorPicker;
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.default = void 0;
|
|
7
|
+
|
|
8
|
+
var _styledComponents = _interopRequireDefault(require("styled-components"));
|
|
9
|
+
|
|
10
|
+
var _templateObject, _templateObject2, _templateObject3, _templateObject4;
|
|
11
|
+
|
|
12
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
13
|
+
|
|
14
|
+
function _taggedTemplateLiteral(strings, raw) { if (!raw) { raw = strings.slice(0); } return Object.freeze(Object.defineProperties(strings, { raw: { value: Object.freeze(raw) } })); }
|
|
15
|
+
|
|
16
|
+
var BmChatForm = _styledComponents.default.div(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n display: flex;\n flex-direction: column;\n padding: 0rem 0.5rem;\n justify-content: space-between;\n > *:not(:last-child) {\n margin-bottom: 0.5rem;\n }\n"])));
|
|
17
|
+
|
|
18
|
+
BmChatForm.Group = _styledComponents.default.div(_templateObject2 || (_templateObject2 = _taggedTemplateLiteral(["\n display: flex;\n flex-direction: row;\n align-items: center;\n justify-content: space-between;\n"])));
|
|
19
|
+
BmChatForm.Label = _styledComponents.default.div(_templateObject3 || (_templateObject3 = _taggedTemplateLiteral(["\n margin: 0rem;\n text-align: left;\n width: 50%;\n overflow: hidden;\n text-overflow: ellipsis;\n"])));
|
|
20
|
+
BmChatForm.Input = _styledComponents.default.input(_templateObject4 || (_templateObject4 = _taggedTemplateLiteral(["\n text-align: right;\n width: 50%;\n overflow: hidden;\n text-overflow: ellipsis;\n border: none;\n &:visited,\n &:active,\n &:hover,\n &:focus {\n outline: none !important;\n text-decoration: none;\n }\n background: transparent;\n"])));
|
|
21
|
+
var _default = BmChatForm;
|
|
22
|
+
exports.default = _default;
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.default = void 0;
|
|
7
|
+
|
|
8
|
+
var _styledComponents = _interopRequireDefault(require("styled-components"));
|
|
9
|
+
|
|
10
|
+
var _templateObject;
|
|
11
|
+
|
|
12
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
13
|
+
|
|
14
|
+
function _taggedTemplateLiteral(strings, raw) { if (!raw) { raw = strings.slice(0); } return Object.freeze(Object.defineProperties(strings, { raw: { value: Object.freeze(raw) } })); }
|
|
15
|
+
|
|
16
|
+
var BmChatLabels = _styledComponents.default.div(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n display: flex;\n flex-direction: column;\n padding: 0rem 0.5rem;\n > *:not(:last-child) {\n margin-bottom: 1rem;\n }\n > * {\n display: flex;\n flex-direction: row;\n justify-content: space-between;\n width: 100%;\n }\n"])));
|
|
17
|
+
|
|
18
|
+
var _default = BmChatLabels;
|
|
19
|
+
exports.default = _default;
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.default = void 0;
|
|
7
|
+
|
|
8
|
+
var _styledComponents = _interopRequireDefault(require("styled-components"));
|
|
9
|
+
|
|
10
|
+
var _colors = require("../../colors");
|
|
11
|
+
|
|
12
|
+
var _templateObject, _templateObject2, _templateObject3;
|
|
13
|
+
|
|
14
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
15
|
+
|
|
16
|
+
function _taggedTemplateLiteral(strings, raw) { if (!raw) { raw = strings.slice(0); } return Object.freeze(Object.defineProperties(strings, { raw: { value: Object.freeze(raw) } })); }
|
|
17
|
+
|
|
18
|
+
var BmChatNotes = _styledComponents.default.div(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n display: flex;\n flex-direction: column;\n padding: 0rem 0.5rem;\n > *:not(:last-child) {\n margin-bottom: 0.5rem;\n }\n"])));
|
|
19
|
+
|
|
20
|
+
BmChatNotes.Input = _styledComponents.default.input(_templateObject2 || (_templateObject2 = _taggedTemplateLiteral(["\n padding: 1rem 1.5rem;\n display: flex;\n flex-grow: 1;\n background: ", ";\n border: none !important;\n &:visited,\n &:active,\n &:hover,\n &:focus {\n outline: none !important;\n text-decoration: none !important;\n }\n width: 100%;\n"])), _colors.BmGrey100);
|
|
21
|
+
BmChatNotes.Details = _styledComponents.default.div(_templateObject3 || (_templateObject3 = _taggedTemplateLiteral(["\n display: flex;\n flex-direction: column;\n padding: 0.5rem 1rem;\n border: 1px solid ", ";\n border-radius: 0.25rem;\n > *:not(:last-child) {\n margin-bottom: 0.5rem;\n }\n\n > * {\n display: flex;\n flex-direction: row;\n justify-content: space-between;\n }\n"])), _colors.BmGrey200);
|
|
22
|
+
var _default = BmChatNotes;
|
|
23
|
+
exports.default = _default;
|
|
@@ -14,7 +14,7 @@ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { de
|
|
|
14
14
|
function _taggedTemplateLiteral(strings, raw) { if (!raw) { raw = strings.slice(0); } return Object.freeze(Object.defineProperties(strings, { raw: { value: Object.freeze(raw) } })); }
|
|
15
15
|
|
|
16
16
|
// import { BmGrey400 } from "../colors";
|
|
17
|
-
var BmChatHeader = _styledComponents.default.div(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n display: flex;\n flex-direction: row;\n align-items: center;\n ", "\n padding: 1rem;\n > *:not(:last-child) {\n margin-right: 0.5rem;\n }\n
|
|
17
|
+
var BmChatHeader = _styledComponents.default.div(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n display: flex;\n flex-direction: row;\n align-items: center;\n ", "\n padding: 1rem;\n > *:not(:last-child) {\n margin-right: 0.5rem;\n }\n"])), ""
|
|
18
18
|
/* border: 0.071rem solid ${BmGrey400}; */
|
|
19
19
|
);
|
|
20
20
|
|
|
@@ -153,7 +153,7 @@ BmModal.Header = function (_ref4) {
|
|
|
153
153
|
});
|
|
154
154
|
};
|
|
155
155
|
|
|
156
|
-
BmModal.Body = _styledComponents.default.div(_templateObject5 || (_templateObject5 = _taggedTemplateLiteral(["\n display: flex;\n flex-direction: column;\n justify-content: space-between;\n"])));
|
|
156
|
+
BmModal.Body = _styledComponents.default.div(_templateObject5 || (_templateObject5 = _taggedTemplateLiteral(["\n display: flex;\n flex-direction: column;\n justify-content: space-between;\n > *:not(:last-child) {\n margin-bottom: 0.5rem;\n }\n > * {\n display: flex;\n flex-direction: row;\n justify-content: space-between;\n width: 100%;\n }\n"])));
|
|
157
157
|
BmModal.Footer = _styledComponents.default.div(_templateObject6 || (_templateObject6 = _taggedTemplateLiteral(["\n display: flex;\n justify-content: space-between;\n"])));
|
|
158
158
|
BmModal.propTypes = {
|
|
159
159
|
size: _propTypes.default.string,
|
package/dist/components/index.js
CHANGED
|
@@ -59,12 +59,30 @@ Object.defineProperty(exports, "BmChat", {
|
|
|
59
59
|
return _chatBody.default;
|
|
60
60
|
}
|
|
61
61
|
});
|
|
62
|
+
Object.defineProperty(exports, "BmChatForm", {
|
|
63
|
+
enumerable: true,
|
|
64
|
+
get: function get() {
|
|
65
|
+
return _FormAccordion.default;
|
|
66
|
+
}
|
|
67
|
+
});
|
|
62
68
|
Object.defineProperty(exports, "BmChatHeader", {
|
|
63
69
|
enumerable: true,
|
|
64
70
|
get: function get() {
|
|
65
71
|
return _chatHeader.BmChatHeader;
|
|
66
72
|
}
|
|
67
73
|
});
|
|
74
|
+
Object.defineProperty(exports, "BmChatLabels", {
|
|
75
|
+
enumerable: true,
|
|
76
|
+
get: function get() {
|
|
77
|
+
return _LabelAccordion.default;
|
|
78
|
+
}
|
|
79
|
+
});
|
|
80
|
+
Object.defineProperty(exports, "BmChatNotes", {
|
|
81
|
+
enumerable: true,
|
|
82
|
+
get: function get() {
|
|
83
|
+
return _NoteAccordion.default;
|
|
84
|
+
}
|
|
85
|
+
});
|
|
68
86
|
Object.defineProperty(exports, "BmChatbotIcon", {
|
|
69
87
|
enumerable: true,
|
|
70
88
|
get: function get() {
|
|
@@ -77,6 +95,12 @@ Object.defineProperty(exports, "BmCheckbox", {
|
|
|
77
95
|
return _checkbox.BmCheckbox;
|
|
78
96
|
}
|
|
79
97
|
});
|
|
98
|
+
Object.defineProperty(exports, "BmColorPicker", {
|
|
99
|
+
enumerable: true,
|
|
100
|
+
get: function get() {
|
|
101
|
+
return _colorPicker.BmColorPicker;
|
|
102
|
+
}
|
|
103
|
+
});
|
|
80
104
|
exports.BmColors = void 0;
|
|
81
105
|
Object.defineProperty(exports, "BmContactCard", {
|
|
82
106
|
enumerable: true,
|
|
@@ -341,6 +365,14 @@ var _infoTab = _interopRequireDefault(require("./InfoTab/infoTab"));
|
|
|
341
365
|
|
|
342
366
|
var _messageCounter = _interopRequireDefault(require("./MessageCounter/messageCounter"));
|
|
343
367
|
|
|
368
|
+
var _FormAccordion = _interopRequireDefault(require("./ChatComponents/FormAccordion/FormAccordion"));
|
|
369
|
+
|
|
370
|
+
var _LabelAccordion = _interopRequireDefault(require("./ChatComponents/LabelAccordion/LabelAccordion"));
|
|
371
|
+
|
|
372
|
+
var _NoteAccordion = _interopRequireDefault(require("./ChatComponents/NoteAccordion/NoteAccordion"));
|
|
373
|
+
|
|
374
|
+
var _colorPicker = require("./ChatComponents/ColorPicker/colorPicker");
|
|
375
|
+
|
|
344
376
|
var _index = require("./SuperFluid/Content/index");
|
|
345
377
|
|
|
346
378
|
var _index2 = require("./SuperFluid/ContentTitle.js/index.js");
|
package/package.json
CHANGED
package/src/App.js
CHANGED
|
@@ -9,14 +9,35 @@ import Chat from "./Chat";
|
|
|
9
9
|
import CustomerInfo from "./CustomerInfo";
|
|
10
10
|
import { BmTag } from "./lib/components/Tags/tags";
|
|
11
11
|
import { Home } from "@material-ui/icons";
|
|
12
|
+
import InfoAccordion from "./InfoAccordion";
|
|
13
|
+
import BmForm from "./lib/components/ChatComponents/FormAccordion/FormAccordion";
|
|
14
|
+
import { BmColorPicker } from "./lib/components/ChatComponents/ColorPicker/colorPicker";
|
|
12
15
|
|
|
13
16
|
export const App = () => {
|
|
14
17
|
return (
|
|
15
18
|
<>
|
|
16
19
|
<GlobalStyle />
|
|
17
20
|
<MainWrapper>
|
|
18
|
-
|
|
19
|
-
|
|
21
|
+
{["#33b1ba", "#000000", "#F62E48", "#8CC63F"].map((color) => (
|
|
22
|
+
<BmColorPicker key={color} color={color} />
|
|
23
|
+
))}
|
|
24
|
+
<BmTag leadingIcon={<Home />} trailingIcon={<Home />}>
|
|
25
|
+
<p>Hello</p>
|
|
26
|
+
</BmTag>
|
|
27
|
+
<BmForm>
|
|
28
|
+
<BmForm.Group>
|
|
29
|
+
<BmForm.Label>
|
|
30
|
+
<h4>Hello</h4>
|
|
31
|
+
</BmForm.Label>
|
|
32
|
+
<BmForm.Input placeholder="Hello" />
|
|
33
|
+
</BmForm.Group>
|
|
34
|
+
<BmForm.Group>
|
|
35
|
+
<BmForm.Label>
|
|
36
|
+
<h4>Hello</h4>
|
|
37
|
+
</BmForm.Label>
|
|
38
|
+
<BmForm.Input placeholder="Hello" />
|
|
39
|
+
</BmForm.Group>
|
|
40
|
+
</BmForm>
|
|
20
41
|
<div className="main-chat-container">
|
|
21
42
|
<div className="sidebar">
|
|
22
43
|
<SideBar />
|
|
@@ -29,6 +50,7 @@ export const App = () => {
|
|
|
29
50
|
</div>
|
|
30
51
|
<div className="chat-contact-info">
|
|
31
52
|
<CustomerInfo />
|
|
53
|
+
<InfoAccordion />
|
|
32
54
|
</div>
|
|
33
55
|
</div>
|
|
34
56
|
</div>
|
package/src/Chat.js
CHANGED
|
@@ -1,14 +1,15 @@
|
|
|
1
|
-
import React from
|
|
2
|
-
import { AttachFile } from
|
|
3
|
-
import EmojiEmotionsIcon from
|
|
4
|
-
import QuickreplyIcon from
|
|
5
|
-
import SendIcon from
|
|
6
|
-
import { BmChat, BmIcons, BmInput } from
|
|
1
|
+
import React from "react";
|
|
2
|
+
import { AttachFile } from "@material-ui/icons";
|
|
3
|
+
import EmojiEmotionsIcon from "@material-ui/icons/EmojiEmotions";
|
|
4
|
+
import QuickreplyIcon from "@mui/icons-material/Quickreply";
|
|
5
|
+
import SendIcon from "@mui/icons-material/Send";
|
|
6
|
+
import { BmChat, BmIcons, BmInput } from "./lib/components";
|
|
7
|
+
import "../src/lib/assets/css/sidebar.css";
|
|
7
8
|
|
|
8
9
|
const Chat = () => {
|
|
9
10
|
return (
|
|
10
11
|
<BmChat>
|
|
11
|
-
<BmChat.Body
|
|
12
|
+
<BmChat.Body>
|
|
12
13
|
<BmChat.Details
|
|
13
14
|
state="inbound"
|
|
14
15
|
session="bot"
|
|
@@ -48,7 +49,7 @@ const Chat = () => {
|
|
|
48
49
|
status="failed"
|
|
49
50
|
>
|
|
50
51
|
<p>Outbound</p>
|
|
51
|
-
</BmChat.Details>{
|
|
52
|
+
</BmChat.Details>{" "}
|
|
52
53
|
<BmChat.Details
|
|
53
54
|
state="outbound"
|
|
54
55
|
session="live"
|
|
@@ -56,7 +57,7 @@ const Chat = () => {
|
|
|
56
57
|
status="failed"
|
|
57
58
|
>
|
|
58
59
|
<p>Outbound</p>
|
|
59
|
-
</BmChat.Details>{
|
|
60
|
+
</BmChat.Details>{" "}
|
|
60
61
|
<BmChat.Details
|
|
61
62
|
state="outbound"
|
|
62
63
|
session="live"
|
|
@@ -64,7 +65,7 @@ const Chat = () => {
|
|
|
64
65
|
status="failed"
|
|
65
66
|
>
|
|
66
67
|
<p>Outbound</p>
|
|
67
|
-
</BmChat.Details>{
|
|
68
|
+
</BmChat.Details>{" "}
|
|
68
69
|
<BmChat.Details
|
|
69
70
|
state="outbound"
|
|
70
71
|
session="live"
|
|
@@ -72,7 +73,7 @@ const Chat = () => {
|
|
|
72
73
|
status="failed"
|
|
73
74
|
>
|
|
74
75
|
<p>Outbound</p>
|
|
75
|
-
</BmChat.Details>{
|
|
76
|
+
</BmChat.Details>{" "}
|
|
76
77
|
<BmChat.Details
|
|
77
78
|
state="outbound"
|
|
78
79
|
session="live"
|
|
@@ -80,7 +81,7 @@ const Chat = () => {
|
|
|
80
81
|
status="failed"
|
|
81
82
|
>
|
|
82
83
|
<p>Outbound</p>
|
|
83
|
-
</BmChat.Details>{
|
|
84
|
+
</BmChat.Details>{" "}
|
|
84
85
|
<BmChat.Details
|
|
85
86
|
state="outbound"
|
|
86
87
|
session="live"
|
|
@@ -88,7 +89,7 @@ const Chat = () => {
|
|
|
88
89
|
status="failed"
|
|
89
90
|
>
|
|
90
91
|
<p>Outbound</p>
|
|
91
|
-
</BmChat.Details>{
|
|
92
|
+
</BmChat.Details>{" "}
|
|
92
93
|
<BmChat.Details
|
|
93
94
|
state="outbound"
|
|
94
95
|
session="live"
|
|
@@ -96,7 +97,7 @@ const Chat = () => {
|
|
|
96
97
|
status="failed"
|
|
97
98
|
>
|
|
98
99
|
<p>Outbound</p>
|
|
99
|
-
</BmChat.Details>{
|
|
100
|
+
</BmChat.Details>{" "}
|
|
100
101
|
<BmChat.Details
|
|
101
102
|
state="outbound"
|
|
102
103
|
session="live"
|
|
@@ -106,12 +107,17 @@ const Chat = () => {
|
|
|
106
107
|
<p>Outbound</p>
|
|
107
108
|
</BmChat.Details>
|
|
108
109
|
</BmChat.Body>
|
|
109
|
-
<BmChat.Footer>
|
|
110
|
-
<
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
<
|
|
114
|
-
|
|
110
|
+
<BmChat.Footer style={{ justifyContent: "flex-start" }}>
|
|
111
|
+
<div class="chat-footer">
|
|
112
|
+
<BmIcons icon={<EmojiEmotionsIcon />} size="xlarge" />
|
|
113
|
+
</div>
|
|
114
|
+
<div class="chat-footer">
|
|
115
|
+
<BmIcons icon={<EmojiEmotionsIcon />} size="xlarge" />
|
|
116
|
+
<BmIcons icon={<AttachFile />} size="xlarge" />
|
|
117
|
+
<BmIcons icon={<QuickreplyIcon />} size="xlarge" />
|
|
118
|
+
<BmInput placeholder="Enter Message" style={{ flex: 1 }} />
|
|
119
|
+
<BmIcons icon={<SendIcon />} size="xlarge" />
|
|
120
|
+
</div>
|
|
115
121
|
</BmChat.Footer>
|
|
116
122
|
</BmChat>
|
|
117
123
|
);
|
package/src/ChatHeader.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import React from "react";
|
|
2
2
|
import { BmChatHeader, BmButton } from "../src/lib/components/";
|
|
3
|
-
import
|
|
3
|
+
import "../src/lib/assets/css/sidebar.css";
|
|
4
4
|
|
|
5
5
|
export const ChatHeader = () => {
|
|
6
6
|
return (
|
|
@@ -9,7 +9,10 @@ export const ChatHeader = () => {
|
|
|
9
9
|
<BmChatHeader>
|
|
10
10
|
<h2>Contact Name</h2>
|
|
11
11
|
<p>Last seen: 00:00</p>
|
|
12
|
-
<
|
|
12
|
+
<div className="chat-header-buttons">
|
|
13
|
+
<BmButton size="medium">End Session</BmButton>
|
|
14
|
+
<BmButton size="medium">End Session</BmButton>
|
|
15
|
+
</div>
|
|
13
16
|
</BmChatHeader>
|
|
14
17
|
</div>
|
|
15
18
|
</>
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
/* eslint-disable react/prop-types */
|
|
2
|
+
import React from "react";
|
|
3
|
+
import { BmAccordion } from "./lib/components";
|
|
4
|
+
import BmForm from "./lib/components/ChatComponents/FormAccordion/FormAccordion";
|
|
5
|
+
|
|
6
|
+
const InfoAccordion = () => {
|
|
7
|
+
return (
|
|
8
|
+
<>
|
|
9
|
+
<BmAccordion>
|
|
10
|
+
<BmAccordion.Title>
|
|
11
|
+
<h3>Notes</h3>
|
|
12
|
+
</BmAccordion.Title>
|
|
13
|
+
<BmAccordion.Body>
|
|
14
|
+
<BmForm>
|
|
15
|
+
<BmForm.Label><h4>Hello</h4></BmForm.Label>
|
|
16
|
+
<BmForm.Input placeholder="Hello" />
|
|
17
|
+
</BmForm>
|
|
18
|
+
</BmAccordion.Body>
|
|
19
|
+
</BmAccordion>
|
|
20
|
+
</>
|
|
21
|
+
);
|
|
22
|
+
};
|
|
23
|
+
|
|
24
|
+
export default InfoAccordion;
|
|
@@ -77,4 +77,24 @@
|
|
|
77
77
|
overflow: auto;
|
|
78
78
|
width: 25%;
|
|
79
79
|
border: 1px solid #E2E2E2;
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
.chat-header-buttons {
|
|
83
|
+
display: flex;
|
|
84
|
+
flex-direction: row;
|
|
85
|
+
margin-left: auto;
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
.chat-header-buttons>*:not(:last-child) {
|
|
89
|
+
margin-right: 0.5rem;
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
.chat-footer {
|
|
93
|
+
display: flex;
|
|
94
|
+
flex-direction: row;
|
|
95
|
+
align-items: center;
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
.chat-footer>*:not(:last-child) {
|
|
99
|
+
margin-right: 0.5rem;
|
|
80
100
|
}
|
|
@@ -134,14 +134,13 @@ BmChat.Details = ({
|
|
|
134
134
|
|
|
135
135
|
BmChat.Footer = styled.div`
|
|
136
136
|
display: flex;
|
|
137
|
-
flex-direction:
|
|
138
|
-
border-top: 0.071rem solid ${
|
|
139
|
-
padding: 0.5rem
|
|
140
|
-
align-items: center;
|
|
141
|
-
justify-content: center;
|
|
142
|
-
${'' /* background: ${BmGrey50}; */}
|
|
137
|
+
flex-direction: column;
|
|
138
|
+
${'' /* border-top: 0.071rem solid ${BmGrey200}; */}
|
|
139
|
+
padding: 0.5rem 0.5rem;
|
|
140
|
+
${'' /* align-items: center; */}
|
|
141
|
+
${'' /* justify-content: center; */}
|
|
143
142
|
> *:not(:last-child) {
|
|
144
|
-
margin-
|
|
143
|
+
margin-bottom: 0.5rem;
|
|
145
144
|
}
|
|
146
145
|
`;
|
|
147
146
|
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import styled from "styled-components";
|
|
2
|
+
|
|
3
|
+
export const BmColorPicker = styled.div`
|
|
4
|
+
width: 1.429rem;
|
|
5
|
+
height: 1.429rem;
|
|
6
|
+
border-radius: 50%;
|
|
7
|
+
background: ${(props) => (props.color ? props.color : 'green')};
|
|
8
|
+
> *:not(:last-child) {
|
|
9
|
+
margin-right: 0.5rem;
|
|
10
|
+
}
|
|
11
|
+
`;
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
import styled from "styled-components";
|
|
2
|
+
|
|
3
|
+
const BmChatForm = styled.div`
|
|
4
|
+
display: flex;
|
|
5
|
+
flex-direction: column;
|
|
6
|
+
padding: 0rem 0.5rem;
|
|
7
|
+
justify-content: space-between;
|
|
8
|
+
> *:not(:last-child) {
|
|
9
|
+
margin-bottom: 0.5rem;
|
|
10
|
+
}
|
|
11
|
+
`;
|
|
12
|
+
|
|
13
|
+
BmChatForm.Group = styled.div`
|
|
14
|
+
display: flex;
|
|
15
|
+
flex-direction: row;
|
|
16
|
+
align-items: center;
|
|
17
|
+
justify-content: space-between;
|
|
18
|
+
`;
|
|
19
|
+
|
|
20
|
+
BmChatForm.Label = styled.div`
|
|
21
|
+
margin: 0rem;
|
|
22
|
+
text-align: left;
|
|
23
|
+
width: 50%;
|
|
24
|
+
overflow: hidden;
|
|
25
|
+
text-overflow: ellipsis;
|
|
26
|
+
`
|
|
27
|
+
|
|
28
|
+
BmChatForm.Input = styled.input`
|
|
29
|
+
text-align: right;
|
|
30
|
+
width: 50%;
|
|
31
|
+
overflow: hidden;
|
|
32
|
+
text-overflow: ellipsis;
|
|
33
|
+
border: none;
|
|
34
|
+
&:visited,
|
|
35
|
+
&:active,
|
|
36
|
+
&:hover,
|
|
37
|
+
&:focus {
|
|
38
|
+
outline: none !important;
|
|
39
|
+
text-decoration: none;
|
|
40
|
+
}
|
|
41
|
+
background: transparent;
|
|
42
|
+
`
|
|
43
|
+
|
|
44
|
+
export default BmChatForm;
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import styled from 'styled-components';
|
|
2
|
+
|
|
3
|
+
const BmChatLabels = styled.div`
|
|
4
|
+
display: flex;
|
|
5
|
+
flex-direction: column;
|
|
6
|
+
padding: 0rem 0.5rem;
|
|
7
|
+
> *:not(:last-child) {
|
|
8
|
+
margin-bottom: 1rem;
|
|
9
|
+
}
|
|
10
|
+
> * {
|
|
11
|
+
display: flex;
|
|
12
|
+
flex-direction: row;
|
|
13
|
+
justify-content: space-between;
|
|
14
|
+
width: 100%;
|
|
15
|
+
}
|
|
16
|
+
`;
|
|
17
|
+
|
|
18
|
+
export default BmChatLabels;
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
import styled from "styled-components";
|
|
2
|
+
import { BmGrey100, BmGrey200 } from "../../colors";
|
|
3
|
+
|
|
4
|
+
const BmChatNotes = styled.div`
|
|
5
|
+
display: flex;
|
|
6
|
+
flex-direction: column;
|
|
7
|
+
padding: 0rem 0.5rem;
|
|
8
|
+
> *:not(:last-child) {
|
|
9
|
+
margin-bottom: 0.5rem;
|
|
10
|
+
}
|
|
11
|
+
`;
|
|
12
|
+
|
|
13
|
+
BmChatNotes.Input = styled.input`
|
|
14
|
+
padding: 1rem 1.5rem;
|
|
15
|
+
display: flex;
|
|
16
|
+
flex-grow: 1;
|
|
17
|
+
background: ${BmGrey100};
|
|
18
|
+
border: none !important;
|
|
19
|
+
&:visited,
|
|
20
|
+
&:active,
|
|
21
|
+
&:hover,
|
|
22
|
+
&:focus {
|
|
23
|
+
outline: none !important;
|
|
24
|
+
text-decoration: none !important;
|
|
25
|
+
}
|
|
26
|
+
width: 100%;
|
|
27
|
+
`;
|
|
28
|
+
|
|
29
|
+
BmChatNotes.Details = styled.div`
|
|
30
|
+
display: flex;
|
|
31
|
+
flex-direction: column;
|
|
32
|
+
padding: 0.5rem 1rem;
|
|
33
|
+
border: 1px solid ${BmGrey200};
|
|
34
|
+
border-radius: 0.25rem;
|
|
35
|
+
> *:not(:last-child) {
|
|
36
|
+
margin-bottom: 0.5rem;
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
> * {
|
|
40
|
+
display: flex;
|
|
41
|
+
flex-direction: row;
|
|
42
|
+
justify-content: space-between;
|
|
43
|
+
}
|
|
44
|
+
`;
|
|
45
|
+
|
|
46
|
+
export default BmChatNotes;
|
|
@@ -5,12 +5,9 @@ export const BmChatHeader = styled.div`
|
|
|
5
5
|
display: flex;
|
|
6
6
|
flex-direction: row;
|
|
7
7
|
align-items: center;
|
|
8
|
-
${
|
|
8
|
+
${"" /* border: 0.071rem solid ${BmGrey400}; */}
|
|
9
9
|
padding: 1rem;
|
|
10
10
|
> *:not(:last-child) {
|
|
11
11
|
margin-right: 0.5rem;
|
|
12
12
|
}
|
|
13
|
-
button {
|
|
14
|
-
margin-left: auto;
|
|
15
|
-
}
|
|
16
13
|
`;
|
|
@@ -135,6 +135,15 @@ BmModal.Body = styled.div`
|
|
|
135
135
|
display: flex;
|
|
136
136
|
flex-direction: column;
|
|
137
137
|
justify-content: space-between;
|
|
138
|
+
> *:not(:last-child) {
|
|
139
|
+
margin-bottom: 0.5rem;
|
|
140
|
+
}
|
|
141
|
+
> * {
|
|
142
|
+
display: flex;
|
|
143
|
+
flex-direction: row;
|
|
144
|
+
justify-content: space-between;
|
|
145
|
+
width: 100%;
|
|
146
|
+
}
|
|
138
147
|
`;
|
|
139
148
|
|
|
140
149
|
BmModal.Footer = styled.div`
|
|
@@ -37,6 +37,11 @@ import { BmChatHeader } from "./ChatHeader/chatHeader";
|
|
|
37
37
|
import BmContactCard from "./ContactCards/contactCards";
|
|
38
38
|
import BmInfoTab from "./InfoTab/infoTab";
|
|
39
39
|
import BmCounter from "./MessageCounter/messageCounter";
|
|
40
|
+
//Chat Accordion components
|
|
41
|
+
import BmChatForm from "./ChatComponents/FormAccordion/FormAccordion";
|
|
42
|
+
import BmChatLabels from "./ChatComponents/LabelAccordion/LabelAccordion";
|
|
43
|
+
import BmChatNotes from "./ChatComponents/NoteAccordion/NoteAccordion";
|
|
44
|
+
import { BmColorPicker } from "./ChatComponents/ColorPicker/colorPicker";
|
|
40
45
|
|
|
41
46
|
//SuperFluid Components
|
|
42
47
|
import { BmContent } from "./SuperFluid/Content/index";
|
|
@@ -67,6 +72,7 @@ export {
|
|
|
67
72
|
BmListBox,
|
|
68
73
|
BmListHeader,
|
|
69
74
|
BmRowLabel,
|
|
75
|
+
// Fix height and if there is dropdown option inside the modal body
|
|
70
76
|
BmModal,
|
|
71
77
|
BmNoteBar,
|
|
72
78
|
BmProgressBar,
|
|
@@ -108,4 +114,9 @@ export {
|
|
|
108
114
|
BmInfoTab,
|
|
109
115
|
BmContactCard,
|
|
110
116
|
BmCounter,
|
|
117
|
+
//Chat Accordion Components
|
|
118
|
+
BmChatForm,
|
|
119
|
+
BmChatLabels,
|
|
120
|
+
BmChatNotes,
|
|
121
|
+
BmColorPicker,
|
|
111
122
|
};
|