@messenger-box/platform-browser 0.0.1-alpha.42 → 0.0.1-alpha.420
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/CHANGELOG.md +540 -27
- package/jest.config.js +23 -7
- package/lib/components/InboxMessage/InboxDetails/index.d.ts +2 -0
- package/lib/components/InboxMessage/InboxDetails/style.d.ts +1 -0
- package/lib/components/InboxMessage/InboxSidebar/index.d.ts +11 -0
- package/lib/components/InboxMessage/InboxSidebar/styles.d.ts +1 -0
- package/lib/components/InboxMessage/Messages/index.d.ts +2 -0
- package/lib/components/InboxMessage/Messages/styles.d.ts +80 -0
- package/lib/components/InboxMessage/MessagesList/index.d.ts +2 -0
- package/lib/components/InboxMessage/Popover/index.d.ts +2 -0
- package/lib/components/InboxMessage/Popover/style.d.ts +27 -0
- package/lib/components/InboxMessage/UserModalContent/index.d.ts +2 -0
- package/lib/components/InboxMessage/UserModalContent/style.d.ts +1 -0
- package/lib/components/InboxMessage/index.d.ts +2 -0
- package/lib/components/InboxMessage/mock.d.ts +19 -0
- package/lib/components/InboxMessage/style.d.ts +1 -0
- package/lib/components/channel_view/DirectChannelView.d.ts +3 -0
- package/lib/components/channel_view/PublicChannelView.d.ts +3 -0
- package/lib/components/dashboard/menu_header.d.ts +5 -0
- package/lib/components/dashboard/modals/direct_modal.d.ts +9 -0
- package/lib/components/dashboard/modals.d.ts +8 -0
- package/lib/components/messenger/index.d.ts +6 -1
- package/lib/components/messenger/messagesList/index.d.ts +6 -4
- package/lib/components/messenger/messagesList/style.d.ts +1 -221
- package/lib/components/messenger/more_action/index.d.ts +11 -0
- package/lib/components/messenger/more_action/style.d.ts +1 -0
- package/lib/components/overlay_trigger.d.ts +3 -3
- package/lib/components/post/channel_intro_message/channel_intro_message.d.ts +2 -1
- package/lib/components/post/channel_layout/channel_identifier_router/channel_identifier_router.d.ts +2 -1
- package/lib/components/post/channel_view/channel_view.d.ts +2 -1
- package/lib/components/post/create_post/create_post.d.ts +2 -1
- package/lib/components/post/failed_post_options/failed_post_options.d.ts +2 -1
- package/lib/components/post/index.d.ts +5 -1
- package/lib/components/post/markdown/markdown.d.ts +2 -1
- package/lib/components/post/post/post.d.ts +2 -1
- package/lib/components/post/post_aria_label_div.d.ts +3 -2
- package/lib/components/post/post_body/post_body.d.ts +2 -1
- package/lib/components/post/post_header/post_header.d.ts +2 -1
- package/lib/components/post/post_header/post_header_custom_status.d.ts +2 -1
- package/lib/components/post/post_header/style.d.ts +1 -40
- package/lib/components/post/post_info/post_info.d.ts +2 -1
- package/lib/components/post/post_list/index.d.ts +2 -1
- package/lib/components/post/post_list/post_list.d.ts +2 -1
- package/lib/components/post/post_list_row/post_list_row.d.ts +2 -1
- package/lib/components/post/post_list_virtualized/latest_post_reader.d.ts +2 -1
- package/lib/components/post/post_list_virtualized/post_list_virtualized.d.ts +2 -1
- package/lib/components/post/post_markdown/post_markdown.d.ts +2 -1
- package/lib/components/post/post_message_view/post_message_view.d.ts +2 -1
- package/lib/components/post/post_pre_header/post_pre_header.d.ts +3 -2
- package/lib/components/post/post_profile_picture/post_profile_picture.d.ts +2 -1
- package/lib/components/post/post_view.d.ts +2 -1
- package/lib/components/post/profile_picture/profile_picture.d.ts +2 -1
- package/lib/components/post/show_more/show_more.d.ts +2 -1
- package/lib/components/post/style.d.ts +1 -93
- package/lib/components/post/threading/channel_threads/thread_footer/thread_footer.d.ts +2 -1
- package/lib/components/post/threading/common/button/button.d.ts +3 -3
- package/lib/components/post/threading/common/follow_button/follow_button.d.ts +2 -2
- package/lib/components/post/tutorial/tutorial_tip/tutorial_tip.d.ts +3 -3
- package/lib/components/post/user_profile/user_profile.d.ts +1 -1
- package/lib/components/status_icon.d.ts +2 -1
- package/lib/components/status_icon_new.d.ts +2 -2
- package/lib/compute.d.ts +8 -2
- package/lib/containers/Inbox.d.ts +3 -0
- package/lib/containers/Messenger.d.ts +5 -1
- package/lib/index.js +3864 -581
- package/lib/index.js.map +1 -1
- package/lib/packages/types/emojis.d.ts +5 -5
- package/lib/packages/types/files.d.ts +5 -5
- package/lib/packages/types/posts.d.ts +13 -13
- package/lib/packages/types/reactions.d.ts +1 -1
- package/lib/packages/types/utilities.d.ts +13 -13
- package/lib/style.d.ts +1 -37
- package/lib/utils/index.d.ts +2 -0
- package/lib/widgets/badges/badge.d.ts +3 -3
- package/lib/widgets/badges/bot_badge.d.ts +1 -1
- package/lib/widgets/badges/guest_badge.d.ts +1 -1
- package/lib/widgets/badges/style.d.ts +1 -23
- package/lib/widgets/icons/emoji_icon.d.ts +1 -1
- package/lib/widgets/icons/flag_icon_filled.d.ts +1 -1
- package/lib/widgets/icons/mattermost_logo.d.ts +1 -1
- package/lib/widgets/icons/status_away_avatar_icon.d.ts +1 -1
- package/lib/widgets/icons/status_away_icon.d.ts +1 -1
- package/lib/widgets/icons/status_dnd_avatar_icon.d.ts +1 -1
- package/lib/widgets/icons/status_dnd_icon.d.ts +1 -1
- package/lib/widgets/icons/status_offline_avatar_icon.d.ts +1 -1
- package/lib/widgets/icons/status_offline_icon.d.ts +1 -1
- package/lib/widgets/icons/status_online_avatar_icon.d.ts +1 -1
- package/lib/widgets/icons/status_online_icon.d.ts +1 -1
- package/lib/widgets/overlay_trigger.d.ts +3 -3
- package/lib/widgets/shared_user_indicator.d.ts +1 -1
- package/lib/widgets/simple_tooltip/simple_tooltip.d.ts +3 -3
- package/lib/widgets/users/avatar/avatar.d.ts +4 -4
- package/lib/widgets/users/avatar/style.d.ts +1 -75
- package/lib/widgets/users/avatars/avatars.d.ts +2 -2
- package/package.json +61 -67
- package/src/components/InboxMessage/InboxDetails/index.tsx +23 -0
- package/src/components/InboxMessage/InboxDetails/style.ts +27 -0
- package/src/components/InboxMessage/InboxSidebar/index.tsx +86 -0
- package/src/components/InboxMessage/InboxSidebar/styles.ts +57 -0
- package/src/components/InboxMessage/Messages/index.tsx +159 -0
- package/src/components/InboxMessage/Messages/styles.ts +85 -0
- package/src/components/InboxMessage/MessagesList/index.tsx +93 -0
- package/src/components/InboxMessage/Popover/index.tsx +57 -0
- package/src/components/InboxMessage/Popover/style.ts +27 -0
- package/src/components/InboxMessage/UserModalContent/index.tsx +60 -0
- package/src/components/InboxMessage/UserModalContent/style.ts +98 -0
- package/src/components/InboxMessage/index.tsx +286 -0
- package/src/components/InboxMessage/mock.ts +53 -0
- package/src/components/InboxMessage/style.ts +189 -0
- package/src/components/channel_view/DirectChannelView.tsx +25 -0
- package/src/components/channel_view/PublicChannelView.tsx +24 -0
- package/src/components/dashboard/menu_header.tsx +49 -0
- package/src/components/dashboard/modals/direct_modal.tsx +46 -0
- package/src/components/dashboard/modals.tsx +93 -0
- package/src/components/messenger/avatar/index.tsx +2 -4
- package/src/components/messenger/avatar/style.ts +3 -3
- package/src/components/messenger/index.tsx +258 -94
- package/src/components/messenger/messagesList/index.tsx +673 -249
- package/src/components/messenger/messagesList/messageBox.tsx +2 -1
- package/src/components/messenger/messagesList/style.ts +240 -14
- package/src/components/messenger/more_action/index.tsx +68 -0
- package/src/components/messenger/more_action/style.ts +45 -0
- package/src/components/messenger/postMessage/postMessage.tsx +2 -3
- package/src/components/messenger/postMessage/style.ts +3 -3
- package/src/components/messenger/sidebarThreadList/index.tsx +11 -10
- package/src/components/messenger/style.ts +16 -16
- package/src/components/messenger/threadSidebar/index.tsx +5 -5
- package/src/components/messenger/threadSidebar/style.ts +7 -7
- package/src/components/messenger/types/message.ts +1 -0
- package/src/components/post/channel_intro_message/channel_intro_message.tsx +0 -1
- package/src/components/post/index.tsx +102 -25
- package/src/components/post/post/post.tsx +8 -1
- package/src/components/post/post_header/post_header_custom_status.tsx +1 -2
- package/src/components/post/post_header/style.ts +3 -6
- package/src/components/post/style.ts +22 -8
- package/src/components/post/tutorial/tutorial_tip/tutorial_tip.tsx +1 -0
- package/src/components/post/user_profile/user_profile.tsx +1 -0
- package/src/compute.tsx +58 -37
- package/src/containers/Dashboard.tsx +488 -1
- package/src/containers/Inbox.tsx +13 -0
- package/src/containers/Loading.tsx +1 -1
- package/src/containers/Messenger.tsx +9 -4
- package/src/module.ts +10 -7
- package/src/style.ts +382 -19
- package/src/utils/index.ts +22 -0
- package/src/widgets/badges/badge.tsx +1 -2
- package/src/widgets/badges/style.ts +3 -3
- package/src/widgets/icons/accordion_toggle_icon.tsx +1 -1
- package/src/widgets/icons/add_reaction_icon.tsx +1 -1
- package/src/widgets/icons/admin_eye_icon.tsx +1 -1
- package/src/widgets/icons/alert_icon.tsx +1 -1
- package/src/widgets/icons/archive_icon.tsx +1 -1
- package/src/widgets/icons/arrow_right_icon.tsx +1 -1
- package/src/widgets/icons/at_icon.tsx +1 -1
- package/src/widgets/icons/attachment_icon.tsx +1 -1
- package/src/widgets/icons/back_icon.tsx +1 -1
- package/src/widgets/icons/bot_icon.tsx +1 -1
- package/src/widgets/icons/camera_icon.tsx +1 -1
- package/src/widgets/icons/checkbox_checked_icon.tsx +1 -1
- package/src/widgets/icons/checkbox_partial_icon.tsx +1 -1
- package/src/widgets/icons/close_circle_icon.tsx +1 -1
- package/src/widgets/icons/close_circle_solid_icon.tsx +1 -1
- package/src/widgets/icons/close_icon.tsx +1 -1
- package/src/widgets/icons/dots_horizontal.tsx +1 -1
- package/src/widgets/icons/download_icon.tsx +1 -1
- package/src/widgets/icons/draft_icon.tsx +1 -1
- package/src/widgets/icons/ellipsis_h_icon.tsx +1 -1
- package/src/widgets/icons/email_icon.tsx +1 -1
- package/src/widgets/icons/fa_add_icon.tsx +1 -1
- package/src/widgets/icons/fa_back_icon.tsx +1 -1
- package/src/widgets/icons/fa_dropdown_icon.tsx +1 -1
- package/src/widgets/icons/fa_edit_icon.tsx +1 -1
- package/src/widgets/icons/fa_logout_icon.tsx +1 -1
- package/src/widgets/icons/fa_next_icon.tsx +1 -1
- package/src/widgets/icons/fa_previous_icon.tsx +1 -1
- package/src/widgets/icons/fa_reload_icon.tsx +1 -1
- package/src/widgets/icons/fa_remove_icon.tsx +1 -1
- package/src/widgets/icons/fa_search_icon.tsx +1 -1
- package/src/widgets/icons/fa_select_icon.tsx +1 -1
- package/src/widgets/icons/fa_success_icon.tsx +1 -1
- package/src/widgets/icons/fa_warning_icon.tsx +1 -1
- package/src/widgets/icons/flag_icon.tsx +1 -1
- package/src/widgets/icons/gfycat_icon.tsx +1 -1
- package/src/widgets/icons/gif_reactions_icon.tsx +1 -1
- package/src/widgets/icons/gif_search_clear_icon.tsx +1 -1
- package/src/widgets/icons/gif_search_icon.tsx +1 -1
- package/src/widgets/icons/gif_trending_icon.tsx +1 -1
- package/src/widgets/icons/globe_icon.tsx +1 -1
- package/src/widgets/icons/icons.stories.js +1 -1
- package/src/widgets/icons/info_icon.tsx +1 -1
- package/src/widgets/icons/info_small_icon.tsx +1 -1
- package/src/widgets/icons/invite_icon.tsx +1 -1
- package/src/widgets/icons/invite_members_icon.tsx +1 -1
- package/src/widgets/icons/link_icon.tsx +1 -1
- package/src/widgets/icons/lock_icon.tsx +1 -1
- package/src/widgets/icons/mail_icon.tsx +1 -1
- package/src/widgets/icons/mail_plus_icon.tsx +1 -1
- package/src/widgets/icons/member_icon.tsx +1 -1
- package/src/widgets/icons/mentions_icon.tsx +1 -1
- package/src/widgets/icons/menu_icon.tsx +1 -1
- package/src/widgets/icons/message_icon.tsx +1 -1
- package/src/widgets/icons/pin_icon.tsx +1 -1
- package/src/widgets/icons/plugin_channel_header_icon.tsx +1 -1
- package/src/widgets/icons/plugin_icon.tsx +1 -1
- package/src/widgets/icons/reply_icon.tsx +1 -1
- package/src/widgets/icons/scroll_to_bottom_icon.tsx +1 -1
- package/src/widgets/icons/search_icon.tsx +1 -1
- package/src/widgets/icons/shield_outline_icon.tsx +1 -1
- package/src/widgets/icons/unarchive_icon.tsx +1 -1
- package/src/widgets/icons/unread_below_icon.tsx +1 -1
- package/src/widgets/icons/user_guide_icon.tsx +1 -1
- package/src/widgets/shared_user_indicator.tsx +1 -0
- package/src/widgets/simple_tooltip/simple_tooltip.tsx +1 -0
- package/src/widgets/users/avatar/avatar.tsx +1 -2
- package/src/widgets/users/avatar/style.ts +3 -3
- package/src/widgets/users/avatars/avatars.tsx +1 -0
- package/tsconfig.json +2 -1
- package/webpack.config.js +1 -1
- package/lib/components/messenger/mock.d.ts +0 -50
- package/lib/components/messenger/postMessage/postMessage.d.ts +0 -1
- package/lib/components/messenger/postMessage/style.d.ts +0 -22
- package/lib/components/messenger/sidebarThreadList/index.d.ts +0 -7
- package/lib/components/messenger/threadSidebar/index.d.ts +0 -1
- package/lib/components/messenger/threadSidebar/style.d.ts +0 -62
- package/lib/components/messenger/types/message.d.ts +0 -14
- package/src/api.ts +0 -35
- package/src/components/Counter.tsx +0 -52
- package/src/containers/Clock.tsx +0 -0
- package/src/containers/Counter.tsx +0 -42
- package/src/containers/PersonList.tsx +0 -20
- package/src/containers/ServerCounter.tsx +0 -140
- package/src/graphql/index.ts +0 -3
- package/src/graphql/mutations/addCount.graphql +0 -5
- package/src/graphql/mutations/addPerson.graphql +0 -6
- package/src/graphql/mutations/index.ts +0 -2
- package/src/graphql/queries/count.graphql +0 -5
- package/src/graphql/queries/index.ts +0 -3
- package/src/graphql/queries/person.graphql +0 -22
- package/src/graphql/queries/persons.graphql +0 -6
- package/src/graphql/subscriptions/count.graphql +0 -5
- package/src/graphql/subscriptions/index.ts +0 -1
- package/src/redux/__mocks__/api.ts +0 -4
- package/src/redux/actions/__tests__/sampleActions.test.ts +0 -159
- package/src/redux/actions/index.ts +0 -1
- package/src/redux/actions/sampleActions.ts +0 -91
- package/src/redux/index.ts +0 -2
- package/src/redux/reducers/Store.ts +0 -10
- package/src/redux/reducers/__tests__/sampleReducers.test.ts +0 -39
- package/src/redux/reducers/index.ts +0 -7
- package/src/redux/reducers/sampleReducers.ts +0 -71
- /package/src/components/post/channel_layout/{channel_controller.test.jsx → channel_controller.test.tsx} +0 -0
- /package/src/components/post/channel_layout/{channel_controller.jsx → channel_controller.tsx} +0 -0
|
@@ -0,0 +1,189 @@
|
|
|
1
|
+
export const stylesheet = {
|
|
2
|
+
inboxStyles:{
|
|
3
|
+
display: 'flex',
|
|
4
|
+
width: '100%',
|
|
5
|
+
height: '75vh',
|
|
6
|
+
background: '#ffff',
|
|
7
|
+
'& .conversations': {
|
|
8
|
+
width: '100%',
|
|
9
|
+
},
|
|
10
|
+
'& .inbox-sidebar': {
|
|
11
|
+
borderRight: '1px solid #eaeaea',
|
|
12
|
+
width: '25%',
|
|
13
|
+
height: '100%',
|
|
14
|
+
display: 'flex',
|
|
15
|
+
flexDirection: 'column',
|
|
16
|
+
justifyContent: 'space-between',
|
|
17
|
+
'& .add-conversations': {
|
|
18
|
+
padding: '20px',
|
|
19
|
+
width: '100%',
|
|
20
|
+
borderTop: '1px solid #eaeaea',
|
|
21
|
+
'& .conversation-btn': {
|
|
22
|
+
width: '100%',
|
|
23
|
+
},
|
|
24
|
+
},
|
|
25
|
+
},
|
|
26
|
+
'& .inbox-sidebar-active': {
|
|
27
|
+
borderRight: '1px solid #eaeaea',
|
|
28
|
+
width: '20%',
|
|
29
|
+
height: '100%',
|
|
30
|
+
display: 'flex',
|
|
31
|
+
flexDirection: 'column',
|
|
32
|
+
justifyContent: 'space-between',
|
|
33
|
+
'& .add-conversations': {
|
|
34
|
+
padding: '20px',
|
|
35
|
+
width: '100%',
|
|
36
|
+
borderTop: '1px solid #eaeaea',
|
|
37
|
+
'& .conversation-btn': {
|
|
38
|
+
width: '100%',
|
|
39
|
+
},
|
|
40
|
+
},
|
|
41
|
+
},
|
|
42
|
+
'& .allmessage-header': {
|
|
43
|
+
display: 'flex',
|
|
44
|
+
alignItems: 'center',
|
|
45
|
+
justifyContent: 'space-between',
|
|
46
|
+
padding: '10px',
|
|
47
|
+
'& h3': {
|
|
48
|
+
marginLeft: '15px',
|
|
49
|
+
marginTop: '15px',
|
|
50
|
+
color: 'black',
|
|
51
|
+
fontWeight: 'bold',
|
|
52
|
+
fontSize: '1em !important',
|
|
53
|
+
},
|
|
54
|
+
'& .ant-btn': {
|
|
55
|
+
padding: '4px',
|
|
56
|
+
},
|
|
57
|
+
'& .ant-btn:hover': {
|
|
58
|
+
background: '#eaeaea',
|
|
59
|
+
},
|
|
60
|
+
},
|
|
61
|
+
'& .header-section': {
|
|
62
|
+
marginBottom: '20px',
|
|
63
|
+
paddingBottom: '7px',
|
|
64
|
+
borderBottom: '1px solid #eaeaea',
|
|
65
|
+
height: '55px',
|
|
66
|
+
},
|
|
67
|
+
'& .ant-btn-circle': {
|
|
68
|
+
marginTop: '17px',
|
|
69
|
+
marginRight: '5px',
|
|
70
|
+
textAlign: 'center',
|
|
71
|
+
'& .ant-btn-circle:hover': {
|
|
72
|
+
backgroundColor: '#eaeaea',
|
|
73
|
+
},
|
|
74
|
+
},
|
|
75
|
+
'& .ant-popover-inner-content': {
|
|
76
|
+
padding: '0',
|
|
77
|
+
},
|
|
78
|
+
'& .border': {
|
|
79
|
+
height: '55px',
|
|
80
|
+
width: '115%',
|
|
81
|
+
borderBottom: '1px solid #eaeaea',
|
|
82
|
+
},
|
|
83
|
+
'& .msg-container': {
|
|
84
|
+
width: '80%',
|
|
85
|
+
},
|
|
86
|
+
'& .msg-container-active': {
|
|
87
|
+
width: '60%',
|
|
88
|
+
'& .border': {
|
|
89
|
+
width: '100%',
|
|
90
|
+
},
|
|
91
|
+
},
|
|
92
|
+
'& .inbox-details': {
|
|
93
|
+
width: '20%',
|
|
94
|
+
borderLeft: '1px solid #eaeaea',
|
|
95
|
+
transition: '500ms',
|
|
96
|
+
},
|
|
97
|
+
'& .inbox-details-active': {
|
|
98
|
+
width: '0',
|
|
99
|
+
transition: '500ms',
|
|
100
|
+
opacity: '0',
|
|
101
|
+
border: 'none',
|
|
102
|
+
overflow: 'hidden',
|
|
103
|
+
},
|
|
104
|
+
},
|
|
105
|
+
modelStyle: {
|
|
106
|
+
display: 'flex',
|
|
107
|
+
flexDirection: 'column',
|
|
108
|
+
height: 'calc(90vh - 120px)',
|
|
109
|
+
width: '100%',
|
|
110
|
+
overflowX: 'hidden',
|
|
111
|
+
padding: '10px 0 15px',
|
|
112
|
+
maxHeight: 'calc(90vh - 80px)',
|
|
113
|
+
overflow: 'auto',
|
|
114
|
+
'& .ant-comment-content-author-name': {
|
|
115
|
+
fontWeight: '600',
|
|
116
|
+
lineHeight: '18px',
|
|
117
|
+
color: '#3d3c40',
|
|
118
|
+
fontSize: '.9em',
|
|
119
|
+
},
|
|
120
|
+
'& .ant-comment-content-detail': {
|
|
121
|
+
fontWeight: '600',
|
|
122
|
+
lineHeight: '18px',
|
|
123
|
+
color: '#9a9a9c',
|
|
124
|
+
fontSize: '.9em',
|
|
125
|
+
},
|
|
126
|
+
'& .root_modal': {
|
|
127
|
+
display: 'flex',
|
|
128
|
+
flexDirection: 'column',
|
|
129
|
+
height: 'calc(90vh - 120px)',
|
|
130
|
+
width: '100%',
|
|
131
|
+
'& .root_first': {
|
|
132
|
+
margin: '5px 0 10px',
|
|
133
|
+
width: '100%',
|
|
134
|
+
},
|
|
135
|
+
'& .root_sec': {
|
|
136
|
+
display: 'flex',
|
|
137
|
+
flexDirection: 'column',
|
|
138
|
+
flexGrow: '500',
|
|
139
|
+
height: '1px',
|
|
140
|
+
flex: '1 1 auto',
|
|
141
|
+
'& .nest_root_sec': {
|
|
142
|
+
display: 'flex',
|
|
143
|
+
flexDirection: 'column',
|
|
144
|
+
height: '1px',
|
|
145
|
+
flexGrow: '500',
|
|
146
|
+
'& .nest_loop': {
|
|
147
|
+
minHeight: '100%',
|
|
148
|
+
overflow: 'auto',
|
|
149
|
+
},
|
|
150
|
+
},
|
|
151
|
+
},
|
|
152
|
+
},
|
|
153
|
+
'& .search_box': {
|
|
154
|
+
display: 'flex',
|
|
155
|
+
'> input': {
|
|
156
|
+
borderRadius: '4px',
|
|
157
|
+
borderStyle: 'solid',
|
|
158
|
+
borderWidth: '1px',
|
|
159
|
+
width: '100%',
|
|
160
|
+
height: '36px',
|
|
161
|
+
borderColor: '#3d3c4033',
|
|
162
|
+
padding: '0px 15px',
|
|
163
|
+
fontSize: '14px',
|
|
164
|
+
},
|
|
165
|
+
'> button': {
|
|
166
|
+
maxWidth: '70px',
|
|
167
|
+
width: '100%',
|
|
168
|
+
marginLeft: '15px',
|
|
169
|
+
background: 'rgb(22, 109, 224)',
|
|
170
|
+
border: 'none',
|
|
171
|
+
color: 'white',
|
|
172
|
+
},
|
|
173
|
+
'& .temp': {
|
|
174
|
+
width: '100%',
|
|
175
|
+
},
|
|
176
|
+
},
|
|
177
|
+
'& .mid_line': {
|
|
178
|
+
'> p': {
|
|
179
|
+
display: 'flex',
|
|
180
|
+
justifyContent: 'space-between',
|
|
181
|
+
width: '100%',
|
|
182
|
+
padding: '10px 0px 0',
|
|
183
|
+
color: '#3d3c40',
|
|
184
|
+
opacity: '.6',
|
|
185
|
+
fontSize: '14px',
|
|
186
|
+
},
|
|
187
|
+
},
|
|
188
|
+
},
|
|
189
|
+
}as any;
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
import {PostViewPage} from "../post";
|
|
3
|
+
import {IntlProvider} from "react-intl";
|
|
4
|
+
import {useHistory} from "react-router-dom";
|
|
5
|
+
import Messenger from "../../containers/Messenger";
|
|
6
|
+
|
|
7
|
+
const DirectChannelView = () => {
|
|
8
|
+
const his: any = useHistory()
|
|
9
|
+
console.log('-=-=-=-=-=', his)
|
|
10
|
+
return (
|
|
11
|
+
<div className="main_wraper">
|
|
12
|
+
<IntlProvider locale="en">
|
|
13
|
+
{/*<h1>Direct Chall Working</h1>*/}
|
|
14
|
+
<div className='chat_head_mid'>
|
|
15
|
+
<PostViewPage channel={his.location.state.channel}
|
|
16
|
+
currentUsrId={his.location.state.currentUser.id}/>
|
|
17
|
+
</div>
|
|
18
|
+
<Messenger channel={his.location.state.channel}
|
|
19
|
+
currentUsrId={his.location.state.currentUser.id}/>
|
|
20
|
+
</IntlProvider>
|
|
21
|
+
</div>
|
|
22
|
+
)
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
export default DirectChannelView
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
import {PostViewPage} from "../post";
|
|
3
|
+
import {IntlProvider} from "react-intl";
|
|
4
|
+
import {useHistory} from "react-router-dom";
|
|
5
|
+
import Messenger from "../../containers/Messenger";
|
|
6
|
+
|
|
7
|
+
const PublicChannelView = () => {
|
|
8
|
+
const his: any = useHistory()
|
|
9
|
+
return (
|
|
10
|
+
<div className="main_wraper">
|
|
11
|
+
<IntlProvider locale="en">
|
|
12
|
+
{/*<h1>Public Channel Working</h1>*/}
|
|
13
|
+
<div className='chat_head_mid'>
|
|
14
|
+
<PostViewPage channel={his.location.state.channel}
|
|
15
|
+
currentUsrId={his.location.state.currentUser.id}/>
|
|
16
|
+
</div>
|
|
17
|
+
<Messenger channel={his.location.state.channel}
|
|
18
|
+
currentUsrId={his.location.state.currentUser.id}/>
|
|
19
|
+
</IntlProvider>
|
|
20
|
+
</div>
|
|
21
|
+
)
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
export default PublicChannelView
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
import { styleSheet } from "../../style";
|
|
3
|
+
import { css } from "@emotion/css"
|
|
4
|
+
import { FiSearch } from "react-icons/fi";
|
|
5
|
+
import { VscMenu } from "react-icons/vsc";
|
|
6
|
+
|
|
7
|
+
export const MenuHeader = ({ clickedChannel, handleClass }) => {
|
|
8
|
+
return (
|
|
9
|
+
<div className={css(styleSheet.customStyle as any)}>
|
|
10
|
+
<div className="navbar_header">
|
|
11
|
+
<button type="button" className="navbar_toggle" onClick={handleClass}>
|
|
12
|
+
<span className="sr-only"><span>Toggle sidebar</span></span>
|
|
13
|
+
<span className="style--none icon icon__menu icon--sidebarHeaderTextColor">
|
|
14
|
+
<VscMenu />
|
|
15
|
+
</span>
|
|
16
|
+
</button>
|
|
17
|
+
<div className="navbar_brand">
|
|
18
|
+
<div className="menu_wrapper ">
|
|
19
|
+
{clickedChannel.id ?
|
|
20
|
+
<a>
|
|
21
|
+
<span className="heading">
|
|
22
|
+
<span className="status "></span>
|
|
23
|
+
<span>
|
|
24
|
+
{clickedChannel.type === 'DIRECT' ?
|
|
25
|
+
clickedChannel.displayName :
|
|
26
|
+
clickedChannel.title
|
|
27
|
+
}
|
|
28
|
+
</span>
|
|
29
|
+
</span>
|
|
30
|
+
<span className="fa fa-angle-down header-dropdown__icon"
|
|
31
|
+
title="Dropdown Icon"></span>
|
|
32
|
+
</a> : ''
|
|
33
|
+
}
|
|
34
|
+
</div>
|
|
35
|
+
</div>
|
|
36
|
+
<button type="button" className="navbar-toggle navbar-right__icon navbar-search pull-right"
|
|
37
|
+
aria-label="Search">
|
|
38
|
+
<span className="icon icon__search" aria-hidden="true">
|
|
39
|
+
<FiSearch />
|
|
40
|
+
</span>
|
|
41
|
+
</button>
|
|
42
|
+
<button type="button" className="navbar-toggle navbar-right__icon menu-toggle pull-right"
|
|
43
|
+
data-toggle="collapse" data-target="#sidebar-nav">
|
|
44
|
+
<span><VscMenu /></span>
|
|
45
|
+
</button>
|
|
46
|
+
</div>
|
|
47
|
+
</div>
|
|
48
|
+
)
|
|
49
|
+
}
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
import { Modal } from "react-bootstrap";
|
|
3
|
+
import { VscChromeClose } from "react-icons/vsc";
|
|
4
|
+
import Select from "react-select";
|
|
5
|
+
import { css } from "@emotion/css"
|
|
6
|
+
import { styleSheet } from "../../../style";
|
|
7
|
+
|
|
8
|
+
export const DirectModal = ({ showDirectChl, handleClose, selectedValues, handleSelect, options, handleGo }) => {
|
|
9
|
+
|
|
10
|
+
return (
|
|
11
|
+
<div className={css(styleSheet.customStyle as any)}>
|
|
12
|
+
<Modal show={showDirectChl} onHide={() => handleClose('directChannel')}>
|
|
13
|
+
<Modal.Header
|
|
14
|
+
style={{ backgroundColor: '#2b5ebf', color: 'white', display: 'flex', alignItems: 'center' }}>
|
|
15
|
+
<Modal.Title>Direct Messages</Modal.Title>
|
|
16
|
+
<VscChromeClose onClick={() => handleClose('directChannel')} fontSize='16px'
|
|
17
|
+
style={{ marginLeft: 'auto', cursor: 'pointer' }} />
|
|
18
|
+
</Modal.Header>
|
|
19
|
+
<Modal.Body>
|
|
20
|
+
<div className={css(styleSheet.modelStyle as any)}>
|
|
21
|
+
<div className="root_modal">
|
|
22
|
+
<div className="root_first">
|
|
23
|
+
<div className="search_box">
|
|
24
|
+
<Select
|
|
25
|
+
className="temp"
|
|
26
|
+
value={selectedValues.value}
|
|
27
|
+
onChange={handleSelect}
|
|
28
|
+
components={{ DropdownIndicator: () => null, IndicatorSeparator: () => null }}
|
|
29
|
+
autoFocus={true}
|
|
30
|
+
options={options}
|
|
31
|
+
isMulti={true}
|
|
32
|
+
menuIsOpen={true}
|
|
33
|
+
/>
|
|
34
|
+
<button onClick={handleGo}>Go</button>
|
|
35
|
+
</div>
|
|
36
|
+
<div className="mid_line">
|
|
37
|
+
<p>Use ↑↓ to browse, ↵ to select.<span> </span></p>
|
|
38
|
+
</div>
|
|
39
|
+
</div>
|
|
40
|
+
</div>
|
|
41
|
+
</div>
|
|
42
|
+
</Modal.Body>
|
|
43
|
+
</Modal>
|
|
44
|
+
</div>
|
|
45
|
+
)
|
|
46
|
+
}
|
|
@@ -0,0 +1,93 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
import { Button, Modal } from "react-bootstrap";
|
|
3
|
+
import { VscChromeClose } from "react-icons/vsc";
|
|
4
|
+
import Select from "react-select";
|
|
5
|
+
import { css } from "@emotion/css";
|
|
6
|
+
import { styleSheet } from "../../style";
|
|
7
|
+
|
|
8
|
+
export const Modals = ({ directMoreModal, publicChlModal, handleClose, handleChange, handleCreate }) => {
|
|
9
|
+
return (
|
|
10
|
+
<div className={css(styleSheet.customStyle as any)}>
|
|
11
|
+
<Modal show={directMoreModal.showDirectMore} onHide={() => handleClose('publicMore')}>
|
|
12
|
+
<Modal.Header
|
|
13
|
+
style={{ backgroundColor: '#2b5ebf', color: 'white', display: 'flex', alignItems: 'center' }}>
|
|
14
|
+
<Modal.Title>Direct Messages</Modal.Title>
|
|
15
|
+
<div className={css(styleSheet.directMoreStyle as any)}>
|
|
16
|
+
<button onClick={() => directMoreModal.handleShow('publicChannel', 'Public Channel')}>Create Channel
|
|
17
|
+
</button>
|
|
18
|
+
<VscChromeClose onClick={() => handleClose('publicMore')} fontSize='16px'
|
|
19
|
+
style={{ marginLeft: 'auto', cursor: 'pointer' }} />
|
|
20
|
+
</div>
|
|
21
|
+
</Modal.Header>
|
|
22
|
+
<Modal.Body className={css(styleSheet.directMoreStyle as any)}>
|
|
23
|
+
<div className='public_more_body'>
|
|
24
|
+
<input placeholder='Search Channels' />
|
|
25
|
+
{directMoreModal.modalPublicChannels.length > 0 ?
|
|
26
|
+
<div className='loop_style'>
|
|
27
|
+
{directMoreModal.modalPublicChannels.map((chl, index) => {
|
|
28
|
+
return (
|
|
29
|
+
<div className='loop_div'>
|
|
30
|
+
<h5 onClick={() => directMoreModal.handleJoin(chl.id)}>{chl.title}</h5>
|
|
31
|
+
<button onClick={() => directMoreModal.handleJoin(chl.id)}>join</button>
|
|
32
|
+
</div>
|
|
33
|
+
)
|
|
34
|
+
})}
|
|
35
|
+
</div>
|
|
36
|
+
:
|
|
37
|
+
<div className="no_channel_message">
|
|
38
|
+
<p className="primary_message">
|
|
39
|
+
<span>No more channels to join</span>
|
|
40
|
+
</p>
|
|
41
|
+
<p className="secondary_message">
|
|
42
|
+
<span>Click 'Create New Channel' to make a new one</span>
|
|
43
|
+
</p>
|
|
44
|
+
</div>
|
|
45
|
+
}
|
|
46
|
+
</div>
|
|
47
|
+
</Modal.Body>
|
|
48
|
+
</Modal>
|
|
49
|
+
<Modal show={publicChlModal.show} onHide={() => handleClose("publicChannel")}>
|
|
50
|
+
<Modal.Header
|
|
51
|
+
style={{ backgroundColor: '#2b5ebf', color: 'white', display: 'flex', alignItems: 'center' }}>
|
|
52
|
+
<Modal.Title>Create Public Channel</Modal.Title>
|
|
53
|
+
<VscChromeClose onClick={() => handleClose('publicChannel')} fontSize='16px'
|
|
54
|
+
style={{ marginLeft: 'auto', cursor: 'pointer' }} />
|
|
55
|
+
</Modal.Header>
|
|
56
|
+
<Modal.Body>
|
|
57
|
+
<div className="modal_div" style={{ textAlign: 'center' }}>
|
|
58
|
+
<label style={{
|
|
59
|
+
width: '20%',
|
|
60
|
+
fontSize: '15px',
|
|
61
|
+
fontWeight: 500,
|
|
62
|
+
marginRight: '5px'
|
|
63
|
+
}}>Channel Name</label>
|
|
64
|
+
<input type="text" name='name' style={{
|
|
65
|
+
width: '62%',
|
|
66
|
+
height: '35px',
|
|
67
|
+
border: '1px solid gray'
|
|
68
|
+
}} onChange={e => handleChange(e)} />
|
|
69
|
+
<label style={{
|
|
70
|
+
width: '20%',
|
|
71
|
+
fontSize: '15px',
|
|
72
|
+
fontWeight: 500,
|
|
73
|
+
marginRight: '5px'
|
|
74
|
+
}}>Channel Description</label>
|
|
75
|
+
<input type="text" name='description' style={{
|
|
76
|
+
width: '62%',
|
|
77
|
+
height: '35px',
|
|
78
|
+
border: '1px solid gray'
|
|
79
|
+
}} onChange={e => handleChange(e)} />
|
|
80
|
+
</div>
|
|
81
|
+
</Modal.Body>
|
|
82
|
+
<Modal.Footer>
|
|
83
|
+
<Button onClick={() => handleClose("publicChannel")}>
|
|
84
|
+
Close
|
|
85
|
+
</Button>
|
|
86
|
+
<Button onClick={handleCreate} style={{ backgroundColor: '#2b5ebf', color: 'white' }}>
|
|
87
|
+
Create Channel
|
|
88
|
+
</Button>
|
|
89
|
+
</Modal.Footer>
|
|
90
|
+
</Modal>
|
|
91
|
+
</div>
|
|
92
|
+
)
|
|
93
|
+
}
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
2
|
import classNames from 'classnames';
|
|
3
|
-
|
|
4
|
-
import { useFela } from 'react-fela';
|
|
3
|
+
import { css } from '@emotion/css';
|
|
5
4
|
import { styleSheet } from './style';
|
|
6
5
|
|
|
7
6
|
type IAvatarSize = 'xxs' | 'xs' | 'sm' | 'md' | 'lg' | 'xl' | 'xxl';
|
|
@@ -15,12 +14,11 @@ type IProps = {
|
|
|
15
14
|
};
|
|
16
15
|
|
|
17
16
|
export const Avatar = ({ url, size = 'md', text, username, time }: IProps) => {
|
|
18
|
-
const { css } = useFela();
|
|
19
17
|
const classes = classNames(`Avatar Avatar-${size}`);
|
|
20
18
|
|
|
21
19
|
if (text) {
|
|
22
20
|
return (
|
|
23
|
-
<div className={css(styleSheet.avatarStyles
|
|
21
|
+
<div className={css(styleSheet.avatarStyles)}>
|
|
24
22
|
<div className={classes + ` Avatar-plain`} data-content={text} />
|
|
25
23
|
</div>
|
|
26
24
|
);
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
export const styleSheet = {
|
|
2
2
|
// eslint-disable-next-line @typescript-eslint/explicit-module-boundary-types
|
|
3
|
-
avatarStyles:
|
|
3
|
+
avatarStyles: {
|
|
4
4
|
display: 'flex',
|
|
5
5
|
alignItems: 'center',
|
|
6
6
|
'& .Avatar': {
|
|
@@ -82,5 +82,5 @@ export const styleSheet = {
|
|
|
82
82
|
marginTop: '8px',
|
|
83
83
|
marginLeft: '10px',
|
|
84
84
|
},
|
|
85
|
-
}
|
|
86
|
-
};
|
|
85
|
+
},
|
|
86
|
+
} as any;
|