@mohamed-karawia/library 0.1.22 → 0.1.23
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/index.js +27 -27
- package/dist/stories/Community/Community.js +27 -29
- package/dist/stories/Forms/AddPhoto/AddPhoto.js +8 -7
- package/dist/stories/Forms/CreateEvent/CreateEvent.js +115 -0
- package/dist/stories/Forms/CreateFolder/CreateFolder.js +87 -0
- package/dist/stories/Forms/CreateSong/CreateSong.js +98 -0
- package/dist/stories/Modals/AddPhotoAlbum/AddPhotoAlbum.js +38 -0
- package/dist/stories/Modals/AddPhotoModal/AddPhotoModal.js +40 -0
- package/dist/stories/Modals/AddSongModal/AddSongModal.js +41 -0
- package/dist/stories/Modals/AddVideoAlbumModal/AddVideoAlbumModal.js +41 -0
- package/dist/stories/Modals/AddVideoModal/AddVideoModal.js +39 -0
- package/dist/stories/Modals/ChatConfigModal/ChatContifgModal.js +93 -0
- package/dist/stories/Modals/CreateEventModal/CreateEventModal.js +42 -0
- package/dist/stories/Modals/CreateFolderModal/CreateFolderModal.js +36 -0
- package/dist/stories/Modals/CreateMusicAlbumModal/CreateMusicAlbumModal.js +41 -0
- package/dist/stories/Modals/CreateNoteModal/CreateNoteModal.js +42 -0
- package/dist/stories/Modals/EventConfigModal/EventConfigModal.js +99 -0
- package/dist/stories/Modals/EventsConfigModal/EventsConfigModal.js +87 -0
- package/dist/stories/Modals/FoldersConfigModal/FoldersConfigModal.js +87 -0
- package/dist/stories/Modals/MusicAlbumConfigModal/MusicAlbumConfigModal.js +88 -0
- package/dist/stories/Modals/MusicAlbumsConfigModal/MusicAlbumsConfigModal.js +87 -0
- package/dist/stories/Modals/NotesConfigModal/NotesConfigModal.js +87 -0
- package/dist/stories/Modals/PhotoAlbumConfigModal/PhotoAlbumConfigModal.js +88 -0
- package/dist/stories/Modals/PhotoAlbumsConfigModal/PhotoAlbumsConfigModal.js +88 -0
- package/dist/stories/Modals/ShowImgModal/ShowImgModal.js +62 -0
- package/dist/stories/Modals/VideoAlbumConfigModal/VideoAlbumConfigModal.js +88 -0
- package/dist/stories/Modals/VideoAlbumsConfigModal/VideoAlbumsConfigModal.js +89 -0
- package/dist/stories/Modals/VideoConfigModal/VideoConfigModal.js +99 -0
- package/dist/stories/Pages/Chat/Chat.js +1 -1
- package/dist/stories/Pages/Events/Event/Event.js +1 -1
- package/dist/stories/Pages/Events/Events/Events.js +1 -1
- package/dist/stories/Pages/Library/Folders/Library.js +2 -2
- package/dist/stories/Pages/Library/Notes/Notes.js +2 -2
- package/dist/stories/Pages/Music/MusicAlbum/Music.js +2 -2
- package/dist/stories/Pages/Music/MusicAlbums/MusicAlbums.js +2 -2
- package/dist/stories/Pages/Photos/Album/Album.js +2 -2
- package/dist/stories/Pages/Photos/Albums/Albums.js +2 -2
- package/dist/stories/Pages/Video/DetailedVideo/DetailedVideo.js +2 -2
- package/dist/stories/Pages/Video/VideoAlbum/Video.js +2 -2
- package/dist/stories/PreviewComponents/ChatPreview/ChatPreview.js +6 -4
- package/dist/stories/PreviewComponents/EventPreview/EventPreview.js +6 -4
- package/dist/stories/PreviewComponents/EventsPreview/EventsPreview.js +6 -4
- package/dist/stories/PreviewComponents/FoldersPreview/FoldersPreview.js +6 -4
- package/dist/stories/PreviewComponents/MusicAlbumPreview/MusicAlbumPreview.js +6 -4
- package/dist/stories/PreviewComponents/MusicAlbumsPreview/MusicAlbumsPreview.js +7 -6
- package/dist/stories/PreviewComponents/MusicPlayerPreview/MusicPlayerPreview.js +6 -4
- package/dist/stories/PreviewComponents/NavbarPreview/NavbarPreview.js +6 -4
- package/dist/stories/PreviewComponents/NotesPreview/NotesPreview.js +6 -4
- package/dist/stories/PreviewComponents/PhotoAlbumPreview/PhotoAlbumPreview.js +6 -4
- package/dist/stories/PreviewComponents/PhotoAlbumsPreview/PhotoAlbumsPreview.js +6 -4
- package/dist/stories/PreviewComponents/SpacesListPreview/SpacesListPreview.js +6 -4
- package/dist/stories/PreviewComponents/VideoAlbumPreview/VideoAlbumPreview.js +6 -4
- package/dist/stories/PreviewComponents/VideoAlbumsPreview/VideoAlbumsPreview.js +6 -4
- package/dist/stories/PreviewComponents/VideoPreview/VideoPreview.js +6 -4
- package/dist/stories/Reusable Components/Comments/Comments.js +58 -0
- package/dist/stories/Reusable Components/Sections/Sections.js +67 -0
- package/dist/stories/Spaces/Chat/Chat.js +103 -0
- package/dist/stories/Spaces/EventsList/EventsList.js +140 -0
- package/dist/stories/Spaces/NotesList/NotesList.js +144 -0
- package/dist/stories/Spaces/ViewDetailedPhoto/ViewDetailedPhoto.js +24 -0
- package/dist/stories/Spaces/ViewEvent/Event.js +146 -0
- package/dist/stories/Spaces/ViewFolders/ViewFolders.js +136 -0
- package/dist/stories/Spaces/ViewMusicAlbumList/ViewMusicAlbumList.js +136 -0
- package/dist/stories/Spaces/ViewMusicAlbums/ViewMusicAlbums.js +130 -0
- package/dist/stories/Spaces/ViewNote/ViewNote.js +27 -0
- package/dist/stories/Spaces/ViewPhotoAlbumList/ViewPhotoAlbumList.js +231 -0
- package/dist/stories/Spaces/ViewPhotoAlbums/ViewPhotoAlbums.js +131 -0
- package/dist/stories/Spaces/ViewVideo/ViewVideo.js +169 -0
- package/dist/stories/Spaces/ViewVideoAlbumList/ViewVideoAlbumList.js +157 -0
- package/dist/stories/Spaces/ViewVideoAlbums/ViewVideoAlbums.js +164 -0
- package/dist/stories/Widgets/VideoPlayer/VideoPlayer.js +235 -0
- package/dist/stories/helpers/util.js +24 -24
- package/dist/stories/store/actions/actions.js +16 -0
- package/dist/stories/store/community.js +941 -0
- package/dist/stories/store/store.js +9 -4
- package/package.json +1 -1
- package/src/index.js +16 -16
- package/src/stories/Community/Community.jsx +19 -19
- package/src/stories/Forms/AddPhoto/AddPhoto.jsx +72 -72
- package/src/stories/{Events → Forms}/CreateEvent/CreateEvent.jsx +5 -1
- package/src/stories/{Library → Forms}/CreateFolder/CreateFolder.jsx +0 -0
- package/src/stories/Forms/{AddSong/AddSong.jsx → CreateSong/CreateSong.jsx} +0 -0
- package/src/stories/Modals/AddPhotoAlbum/AddPhotoAlbum.jsx +27 -0
- package/src/stories/Modals/AddPhotoModal/AddPhotoModal.jsx +29 -0
- package/src/stories/Modals/AddSongModal/AddSongModal.jsx +37 -0
- package/src/stories/Modals/AddVideoAlbumModal/AddVideoAlbumModal.jsx +38 -0
- package/src/stories/Modals/AddVideoModal/AddVideoModal.jsx +35 -0
- package/src/stories/Modals/ChatConfigModal/ChatContifgModal.jsx +77 -0
- package/src/stories/Modals/CreateEventModal/CreateEventModal.jsx +30 -0
- package/src/stories/Modals/CreateFolderModal/CreateFolderModal.jsx +39 -0
- package/src/stories/Modals/CreateMusicAlbumModal/CreateMusicAlbumModal.jsx +37 -0
- package/src/stories/Modals/CreateNoteModal/CreateNoteModal.jsx +43 -0
- package/src/stories/Modals/EventConfigModal/EventConfigModal.jsx +74 -0
- package/src/stories/Modals/EventsConfigModal/EventsConfigModal.jsx +67 -0
- package/src/stories/Modals/FoldersConfigModal/FoldersConfigModal.jsx +66 -0
- package/src/stories/Modals/MusicAlbumConfigModal/MusicAlbumConfigModal.jsx +69 -0
- package/src/stories/Modals/MusicAlbumsConfigModal/MusicAlbumsConfigModal.jsx +73 -0
- package/src/stories/Modals/NotesConfigModal/NotesConfigModal.jsx +65 -0
- package/src/stories/Modals/PhotoAlbumConfigModal/PhotoAlbumConfigModal.jsx +71 -0
- package/src/stories/Modals/PhotoAlbumsConfigModal/PhotoAlbumsConfigModal.jsx +69 -0
- package/src/stories/Modals/ShowImgModal/ShowImgModal.jsx +87 -0
- package/src/stories/Modals/VideoAlbumConfigModal/VideoAlbumConfigModal.jsx +67 -0
- package/src/stories/Modals/VideoAlbumsConfigModal/VideoAlbumsConfigModal.jsx +67 -0
- package/src/stories/Modals/VideoConfigModal/VideoConfigModal.jsx +78 -0
- package/src/stories/Pages/Chat/Chat.jsx +1 -1
- package/src/stories/Pages/Events/Event/Event.jsx +1 -1
- package/src/stories/Pages/Events/Events/Events.jsx +1 -1
- package/src/stories/Pages/Library/Folders/Library.jsx +1 -1
- package/src/stories/Pages/Library/Notes/Notes.jsx +1 -1
- package/src/stories/Pages/Music/MusicAlbum/Music.jsx +1 -1
- package/src/stories/Pages/Music/MusicAlbums/MusicAlbums.jsx +1 -1
- package/src/stories/Pages/Photos/Album/Album.jsx +1 -1
- package/src/stories/Pages/Photos/Albums/Albums.jsx +1 -1
- package/src/stories/Pages/Video/DetailedVideo/DetailedVideo.jsx +1 -1
- package/src/stories/Pages/Video/VideoAlbum/Video.jsx +1 -1
- package/src/stories/PreviewComponents/ChatPreview/ChatPreview.jsx +106 -104
- package/src/stories/PreviewComponents/EventPreview/EventPreview.jsx +6 -4
- package/src/stories/PreviewComponents/EventsPreview/EventsPreview.jsx +106 -104
- package/src/stories/PreviewComponents/FoldersPreview/FoldersPreview.jsx +7 -5
- package/src/stories/PreviewComponents/MusicAlbumPreview/MusicAlbumPreview.jsx +6 -4
- package/src/stories/PreviewComponents/MusicAlbumsPreview/MusicAlbumsPreview.jsx +13 -11
- package/src/stories/PreviewComponents/MusicPlayerPreview/MusicPlayerPreview.jsx +35 -33
- package/src/stories/PreviewComponents/NavbarPreview/NavbarPreview.jsx +17 -15
- package/src/stories/PreviewComponents/NotesPreview/NotesPreview.jsx +6 -4
- package/src/stories/PreviewComponents/PhotoAlbumPreview/PhotoAlbumPreview.jsx +105 -103
- package/src/stories/PreviewComponents/PhotoAlbumsPreview/PhotoAlbumsPreview.jsx +7 -5
- package/src/stories/PreviewComponents/SpacesListPreview/SpacesListPreview.jsx +9 -7
- package/src/stories/PreviewComponents/VideoAlbumPreview/VideoAlbumPreview.jsx +6 -4
- package/src/stories/PreviewComponents/VideoAlbumsPreview/VideoAlbumsPreview.jsx +6 -4
- package/src/stories/PreviewComponents/VideoPreview/VideoPreview.jsx +6 -4
- package/src/stories/{VideoAlbum → Reusable Components}/Comments/Comments.jsx +0 -0
- package/src/stories/{Sections/Sections.jsx → Reusable Components/Sections/Sections.jsx } +1 -1
- package/src/stories/Spaces/Chat/Chat.jsx +77 -0
- package/src/stories/Spaces/EventsList/EventsList.jsx +118 -0
- package/src/stories/{Library/Notes/Notes.jsx → Spaces/NotesList/NotesList.jsx} +20 -66
- package/src/stories/{Photo Album/DetailedPhoto/DetailedPhoto.jsx → Spaces/ViewDetailedPhoto/ViewDetailedPhoto.jsx} +1 -1
- package/src/stories/{Events/Event → Spaces/ViewEvent}/Event.jsx +10 -74
- package/src/stories/Spaces/ViewFolders/ViewFolders.jsx +122 -0
- package/src/stories/Spaces/ViewMusicAlbumList/ViewMusicAlbumList.jsx +118 -0
- package/src/stories/Spaces/ViewMusicAlbums/ViewMusicAlbums.jsx +108 -0
- package/src/stories/{Library → Spaces}/ViewNote/ViewNote.jsx +0 -0
- package/src/stories/{Photo Album/ViewAlbum/ViewAlbum.jsx → Spaces/ViewPhotoAlbumList/ViewPhotoAlbumList.jsx} +42 -137
- package/src/stories/{Photo Album/ViewAlbums/ViewAlbums.jsx → Spaces/ViewPhotoAlbums/ViewPhotoAlbums.jsx} +16 -55
- package/src/stories/{VideoAlbum/VideoSpace/VideoSpace.jsx → Spaces/ViewVideo/ViewVideo.jsx} +15 -48
- package/src/stories/{VideoAlbum/ViewAlbum/ViewAlbum.jsx → Spaces/ViewVideoAlbumList/ViewVideoAlbumList.jsx} +14 -57
- package/src/stories/{VideoAlbum/AlbumsGallery/AlbumsGallery.jsx → Spaces/ViewVideoAlbums/ViewVideoAlbums.jsx} +14 -52
- package/src/stories/{VideoAlbum → Widgets}/VideoPlayer/VideoPlayer.jsx +0 -0
- package/src/stories/helpers/util.js +13 -13
- package/src/stories/store/actions/actions.js +7 -0
- package/src/stories/store/{communities.js → community.js} +0 -0
- package/src/stories/store/store.js +3 -4
- package/src/stories/Chat/Chat.jsx +0 -154
- package/src/stories/Events/EventsList/EventsList.jsx +0 -187
- package/src/stories/Library/Folders/Folders.jsx +0 -196
- package/src/stories/Music Album/ViewAlbum/ViewAlbum.jsx +0 -172
- package/src/stories/Music Album/ViewAlbums/ViewAlbums.jsx +0 -166
@@ -0,0 +1,87 @@
|
|
1
|
+
import React from 'react';
|
2
|
+
import PropTypes from 'prop-types';
|
3
|
+
import styled from 'styled-components';
|
4
|
+
|
5
|
+
import { AiOutlineArrowLeft, AiOutlineArrowRight, AiOutlineClose } from "react-icons/ai";
|
6
|
+
import Modal from '../../Reusable Components/ReactModal/ReactModal';
|
7
|
+
import DetailedPhoto from '../../Spaces/ViewDetailedPhoto/ViewDetailedPhoto';
|
8
|
+
|
9
|
+
const ShowImgModal = ({
|
10
|
+
showImgModal,
|
11
|
+
closeModal,
|
12
|
+
prevPhoto,
|
13
|
+
nextPhoto,
|
14
|
+
openedImg,
|
15
|
+
...props
|
16
|
+
}) => {
|
17
|
+
return (
|
18
|
+
<Modal
|
19
|
+
modalIsOpen={showImgModal}
|
20
|
+
closeModal={closeModal}
|
21
|
+
exitModalButton={(e) => (
|
22
|
+
<div></div>
|
23
|
+
)}
|
24
|
+
width="70vw"
|
25
|
+
height="90vh">
|
26
|
+
<CloseIconContainer onClick={closeModal}>
|
27
|
+
<AiOutlineClose />
|
28
|
+
</CloseIconContainer>
|
29
|
+
<LeftIconContainer onClick={prevPhoto}>
|
30
|
+
<AiOutlineArrowLeft />
|
31
|
+
</LeftIconContainer>
|
32
|
+
<DetailedPhoto cardClicked={nextPhoto} img={openedImg} />
|
33
|
+
<RightIconContainer onClick={nextPhoto}>
|
34
|
+
<AiOutlineArrowRight />
|
35
|
+
</RightIconContainer>
|
36
|
+
</Modal>
|
37
|
+
)
|
38
|
+
}
|
39
|
+
|
40
|
+
const IconContainer = styled.div`
|
41
|
+
width: 30px;
|
42
|
+
height: 30px;
|
43
|
+
background-color: #757575;
|
44
|
+
position: absolute;
|
45
|
+
transform: translateY(-50%);
|
46
|
+
top: 50%;
|
47
|
+
display: flex;
|
48
|
+
justify-content: center;
|
49
|
+
align-items: center;
|
50
|
+
border-radius: 50rem;
|
51
|
+
z-index: 999;
|
52
|
+
cursor: pointer;
|
53
|
+
opacity: .4;
|
54
|
+
transition: all .2s;
|
55
|
+
|
56
|
+
&:hover{
|
57
|
+
opacity: 1;
|
58
|
+
transform: scale(1.1) translateY(-50%);
|
59
|
+
}
|
60
|
+
|
61
|
+
svg{
|
62
|
+
color: white;
|
63
|
+
}
|
64
|
+
|
65
|
+
`
|
66
|
+
|
67
|
+
const CloseIconContainer = styled.div`
|
68
|
+
position: absolute;
|
69
|
+
z-index: 999;
|
70
|
+
right: 10px;
|
71
|
+
top: 10px;
|
72
|
+
cursor: pointer;
|
73
|
+
|
74
|
+
svg{
|
75
|
+
color: white;
|
76
|
+
}
|
77
|
+
`
|
78
|
+
|
79
|
+
const LeftIconContainer = styled(IconContainer)`
|
80
|
+
left: 10px;
|
81
|
+
`
|
82
|
+
|
83
|
+
const RightIconContainer = styled(IconContainer)`
|
84
|
+
right: 10px;
|
85
|
+
`
|
86
|
+
|
87
|
+
export default ShowImgModal
|
@@ -0,0 +1,67 @@
|
|
1
|
+
import React, { useState } from 'react';
|
2
|
+
import PropTypes from 'prop-types';
|
3
|
+
|
4
|
+
import ViewAlbum from '../../Spaces/ViewVideoAlbumList/ViewVideoAlbumList';
|
5
|
+
import Modal from '../../Reusable Components/ReactModal/ReactModal';
|
6
|
+
import Tabs from '../../Reusable Components/Tabs/Tabs';
|
7
|
+
import VideoAlbumPreview from '../../PreviewComponents/VideoAlbumPreview/VideoAlbumPreview';
|
8
|
+
import Community from '../../Reusable Components/Community/Community';
|
9
|
+
|
10
|
+
const VideoAlbumConfig = ({
|
11
|
+
showConfigModal,
|
12
|
+
cancelConfig,
|
13
|
+
album,
|
14
|
+
community,
|
15
|
+
...props
|
16
|
+
}) => {
|
17
|
+
const [centerContext, setCenterContext] = useState(<ViewAlbum preview={true} album={album} />)
|
18
|
+
|
19
|
+
const formChanged = (values) => {
|
20
|
+
console.log('context changed')
|
21
|
+
setCenterContext(<ViewAlbum preview={true} album={album} {...values} />)
|
22
|
+
}
|
23
|
+
|
24
|
+
let tabs = [
|
25
|
+
{
|
26
|
+
title: 'New', id: 'preview'
|
27
|
+
},
|
28
|
+
{
|
29
|
+
title: 'Context', id: 'community'
|
30
|
+
}
|
31
|
+
]
|
32
|
+
|
33
|
+
return (
|
34
|
+
<Modal
|
35
|
+
modalIsOpen={showConfigModal}
|
36
|
+
closeModal={cancelConfig}
|
37
|
+
exitModalButton={(e) => (
|
38
|
+
<div></div>
|
39
|
+
)}>
|
40
|
+
<Tabs
|
41
|
+
title="Video Album Config"
|
42
|
+
tabs={tabs}
|
43
|
+
id='styling'
|
44
|
+
>
|
45
|
+
<VideoAlbumPreview
|
46
|
+
componentProps={{ album, preview: true }}
|
47
|
+
formChanged={formChanged}
|
48
|
+
id="preview" />
|
49
|
+
<Community
|
50
|
+
center={centerContext}
|
51
|
+
community={community}
|
52
|
+
id="community" />
|
53
|
+
</Tabs>
|
54
|
+
</Modal>
|
55
|
+
)
|
56
|
+
}
|
57
|
+
|
58
|
+
VideoAlbumConfig.defaultProps = {};
|
59
|
+
|
60
|
+
VideoAlbumConfig.propTypes = {
|
61
|
+
showConfigModal: PropTypes.bool,
|
62
|
+
cancelConfig: PropTypes.func,
|
63
|
+
album: PropTypes.array,
|
64
|
+
community: PropTypes.object,
|
65
|
+
}
|
66
|
+
|
67
|
+
export default VideoAlbumConfig
|
@@ -0,0 +1,67 @@
|
|
1
|
+
import React, { useState } from 'react';
|
2
|
+
import PropTypes from 'prop-types';
|
3
|
+
|
4
|
+
import AlbumsGallery from '../../Spaces/ViewVideoAlbums/ViewVideoAlbums';
|
5
|
+
import Modal from '../../Reusable Components/ReactModal/ReactModal';
|
6
|
+
import Tabs from '../../Reusable Components/Tabs/Tabs';
|
7
|
+
import Sections from '../../Reusable Components/Sections/Sections'
|
8
|
+
import VideoAlbumsPreview from '../../PreviewComponents/VideoAlbumsPreview/VideoAlbumsPreview';
|
9
|
+
import Community from '../../Reusable Components/Community/Community';
|
10
|
+
|
11
|
+
const VideoAlbumsConfigModal = ({
|
12
|
+
showConfigModal,
|
13
|
+
cancelConfig,
|
14
|
+
videoAlbums,
|
15
|
+
community,
|
16
|
+
...props
|
17
|
+
}) => {
|
18
|
+
const [centerContext, setCenterContext] = useState(<AlbumsGallery preview={true} videoAlbums={videoAlbums} />)
|
19
|
+
|
20
|
+
const formChanged = (values) => {
|
21
|
+
setCenterContext(<AlbumsGallery preview={true} videoAlbums={videoAlbums} {...values} />)
|
22
|
+
}
|
23
|
+
|
24
|
+
let tabs = [
|
25
|
+
{
|
26
|
+
title: 'New', id: 'preview'
|
27
|
+
},
|
28
|
+
{
|
29
|
+
title: 'Context', id: 'community'
|
30
|
+
}
|
31
|
+
]
|
32
|
+
|
33
|
+
return (
|
34
|
+
<Modal
|
35
|
+
modalIsOpen={showConfigModal}
|
36
|
+
closeModal={cancelConfig}
|
37
|
+
exitModalButton={(e) => (
|
38
|
+
<div></div>
|
39
|
+
)}>
|
40
|
+
<Tabs
|
41
|
+
title="Video Gallery Config"
|
42
|
+
tabs={tabs}
|
43
|
+
id='styling'
|
44
|
+
>
|
45
|
+
<VideoAlbumsPreview
|
46
|
+
componentProps={{ videoAlbums, preview: true }}
|
47
|
+
formChanged={formChanged}
|
48
|
+
id="preview" />
|
49
|
+
<Community
|
50
|
+
center={centerContext}
|
51
|
+
community={community}
|
52
|
+
id="community" />
|
53
|
+
</Tabs>
|
54
|
+
</Modal>
|
55
|
+
)
|
56
|
+
}
|
57
|
+
|
58
|
+
VideoAlbumsConfigModal.defaultProps = {};
|
59
|
+
|
60
|
+
VideoAlbumsConfigModal.propTypes = {
|
61
|
+
showConfigModal: PropTypes.func,
|
62
|
+
cancelConfig: PropTypes.func,
|
63
|
+
videoAlbums: PropTypes.array,
|
64
|
+
community: PropTypes.object,
|
65
|
+
}
|
66
|
+
|
67
|
+
export default VideoAlbumsConfigModal
|
@@ -0,0 +1,78 @@
|
|
1
|
+
import React, { useState } from 'react';
|
2
|
+
import PropTypes from 'prop-types';
|
3
|
+
|
4
|
+
import VideoSpace from '../../Spaces/ViewVideo/ViewVideo';
|
5
|
+
import Modal from '../../Reusable Components/ReactModal/ReactModal';
|
6
|
+
import VideoPreview from '../../PreviewComponents/VideoPreview/VideoPreview';
|
7
|
+
import Community from '../../Reusable Components/Community/Community';
|
8
|
+
import Tabs from '../../Reusable Components/Tabs/Tabs';
|
9
|
+
|
10
|
+
const VideoConfigModal = ({
|
11
|
+
showConfigModal,
|
12
|
+
cancelConfig,
|
13
|
+
community,
|
14
|
+
videoSrc,
|
15
|
+
title,
|
16
|
+
discription,
|
17
|
+
date,
|
18
|
+
users,
|
19
|
+
comments,
|
20
|
+
...props
|
21
|
+
}) => {
|
22
|
+
const [centerContext, setCenterContext] = useState(<VideoSpace users={users} preview={true} videoSrc={videoSrc} comments={comments} />)
|
23
|
+
|
24
|
+
const formChanged = (values) => {
|
25
|
+
setCenterContext(<VideoSpace users={users} preview={true} videoSrc={videoSrc} comments={comments} {...values} />)
|
26
|
+
}
|
27
|
+
|
28
|
+
let tabs = [
|
29
|
+
{
|
30
|
+
title: 'New', id: 'preview'
|
31
|
+
},
|
32
|
+
{
|
33
|
+
title: 'Context', id: 'community'
|
34
|
+
}
|
35
|
+
]
|
36
|
+
|
37
|
+
return (
|
38
|
+
<Modal
|
39
|
+
modalIsOpen={showConfigModal}
|
40
|
+
closeModal={cancelConfig}
|
41
|
+
exitModalButton={(e) => (
|
42
|
+
<div></div>
|
43
|
+
)}
|
44
|
+
>
|
45
|
+
<Tabs
|
46
|
+
title="Video Space Config"
|
47
|
+
tabs={tabs}
|
48
|
+
id='styling'
|
49
|
+
>
|
50
|
+
<VideoPreview
|
51
|
+
componentProps={{ title, discription, comments, date, preview: true }}
|
52
|
+
formChanged={formChanged}
|
53
|
+
id="preview" />
|
54
|
+
|
55
|
+
<Community
|
56
|
+
center={centerContext}
|
57
|
+
community={community}
|
58
|
+
id="community" />
|
59
|
+
</Tabs>
|
60
|
+
</Modal>
|
61
|
+
)
|
62
|
+
}
|
63
|
+
|
64
|
+
VideoConfigModal.defaultProps = {};
|
65
|
+
|
66
|
+
VideoConfigModal.propTypes = {
|
67
|
+
showConfigModal: PropTypes.bool,
|
68
|
+
cancelConfig: PropTypes.func,
|
69
|
+
community: PropTypes.object,
|
70
|
+
videoSrc: PropTypes.string,
|
71
|
+
title: PropTypes.string,
|
72
|
+
discription: PropTypes.string,
|
73
|
+
date: PropTypes.string,
|
74
|
+
users: PropTypes.array,
|
75
|
+
comments: PropTypes.array,
|
76
|
+
}
|
77
|
+
|
78
|
+
export default VideoConfigModal
|
@@ -14,7 +14,7 @@ import WidgetContainer from "../../Reusable Components/WidgetContainer/WidgetCon
|
|
14
14
|
import worldStyles from '../ViewWorld/styles.json';
|
15
15
|
|
16
16
|
import { SPACES } from '../ViewWorld/constatnts';
|
17
|
-
import ChatSpace from '../../Chat/Chat';
|
17
|
+
import ChatSpace from '../../Spaces/Chat/Chat';
|
18
18
|
|
19
19
|
|
20
20
|
const Chat = ({
|
@@ -10,7 +10,7 @@ import Navbar from '../../../Navbar/Navbar';
|
|
10
10
|
import BaseMaterial from '../../../Containers/BaseMaterial';
|
11
11
|
import SpaceContainer from "../../../Reusable Components/SpaceContainer/SpaceContainer";
|
12
12
|
import WidgetContainer from "../../../Reusable Components/WidgetContainer/WidgetContainer";
|
13
|
-
import DetailedEvent from '../../../
|
13
|
+
import DetailedEvent from '../../../Spaces/ViewEvent/Event';
|
14
14
|
|
15
15
|
import worldStyles from '../../ViewWorld/styles.json';
|
16
16
|
|
@@ -10,7 +10,7 @@ import Navbar from '../../../Navbar/Navbar';
|
|
10
10
|
import BaseMaterial from '../../../Containers/BaseMaterial';
|
11
11
|
import SpaceContainer from "../../../Reusable Components/SpaceContainer/SpaceContainer";
|
12
12
|
import WidgetContainer from "../../../Reusable Components/WidgetContainer/WidgetContainer";
|
13
|
-
import EventsList from '../../../
|
13
|
+
import EventsList from '../../../Spaces/EventsList/EventsList';
|
14
14
|
import { addObjectToArray, deleteFromArrayByIndex } from '../../../helpers/util';
|
15
15
|
|
16
16
|
import worldStyles from '../../ViewWorld/styles.json';
|
@@ -10,7 +10,7 @@ import Navbar from '../../../Navbar/Navbar';
|
|
10
10
|
import BaseMaterial from '../../../Containers/BaseMaterial';
|
11
11
|
import SpaceContainer from "../../../Reusable Components/SpaceContainer/SpaceContainer";
|
12
12
|
import WidgetContainer from "../../../Reusable Components/WidgetContainer/WidgetContainer";
|
13
|
-
import Folders from '../../../
|
13
|
+
import Folders from '../../../Spaces/ViewFolders/ViewFolders';
|
14
14
|
import { addObjectToArray, deleteFromArrayByIndex } from '../../../helpers/util';
|
15
15
|
|
16
16
|
import worldStyles from '../../ViewWorld/styles.json';
|
@@ -10,7 +10,7 @@ import Navbar from '../../../Navbar/Navbar';
|
|
10
10
|
import BaseMaterial from '../../../Containers/BaseMaterial';
|
11
11
|
import SpaceContainer from "../../../Reusable Components/SpaceContainer/SpaceContainer";
|
12
12
|
import WidgetContainer from "../../../Reusable Components/WidgetContainer/WidgetContainer";
|
13
|
-
import ViewNotes from '../../../
|
13
|
+
import ViewNotes from '../../../Spaces/NotesList/NotesList';
|
14
14
|
import { addObjectToArray, deleteFromArrayByIndex } from '../../../helpers/util';
|
15
15
|
|
16
16
|
import worldStyles from '../../ViewWorld/styles.json';
|
@@ -6,7 +6,7 @@ import Center from '../../../Layout/Center/Center';
|
|
6
6
|
import Right from '../../../Layout/Right/Right';
|
7
7
|
|
8
8
|
import Navbar from '../../../Navbar/Navbar';
|
9
|
-
import MusicAlbum from '../../../
|
9
|
+
import MusicAlbum from '../../../Spaces/ViewMusicAlbumList/ViewMusicAlbumList';
|
10
10
|
|
11
11
|
import BaseMaterial from '../../../Containers/BaseMaterial';
|
12
12
|
import SpaceContainer from "../../../Reusable Components/SpaceContainer/SpaceContainer";
|
@@ -6,7 +6,7 @@ import Center from '../../../Layout/Center/Center';
|
|
6
6
|
import Right from '../../../Layout/Right/Right';
|
7
7
|
|
8
8
|
import Navbar from '../../../Navbar/Navbar';
|
9
|
-
import ViewAlbums from '../../../
|
9
|
+
import ViewAlbums from '../../../Spaces/ViewMusicAlbums/ViewMusicAlbums';
|
10
10
|
|
11
11
|
import BaseMaterial from '../../../Containers/BaseMaterial';
|
12
12
|
import SpaceContainer from "../../../Reusable Components/SpaceContainer/SpaceContainer";
|
@@ -6,7 +6,7 @@ import Center from '../../../Layout/Center/Center';
|
|
6
6
|
import Right from '../../../Layout/Right/Right';
|
7
7
|
|
8
8
|
import Navbar from '../../../Navbar/Navbar';
|
9
|
-
import ViewAlbum from '../../../
|
9
|
+
import ViewAlbum from '../../../Spaces/ViewPhotoAlbums/ViewPhotoAlbums';
|
10
10
|
|
11
11
|
import BaseMaterial from '../../../Containers/BaseMaterial';
|
12
12
|
import SpaceContainer from "../../../Reusable Components/SpaceContainer/SpaceContainer";
|
@@ -6,7 +6,7 @@ import Center from '../../../Layout/Center/Center';
|
|
6
6
|
import Right from '../../../Layout/Right/Right';
|
7
7
|
|
8
8
|
import Navbar from '../../../Navbar/Navbar';
|
9
|
-
import ViewAlbums from '../../../
|
9
|
+
import ViewAlbums from '../../../Spaces/ViewPhotoAlbums/ViewPhotoAlbums';
|
10
10
|
|
11
11
|
import BaseMaterial from '../../../Containers/BaseMaterial';
|
12
12
|
import SpaceContainer from "../../../Reusable Components/SpaceContainer/SpaceContainer";
|
@@ -13,7 +13,7 @@ import WidgetContainer from "../../../Reusable Components/WidgetContainer/Widget
|
|
13
13
|
|
14
14
|
import worldStyles from '../../ViewWorld/styles.json';
|
15
15
|
|
16
|
-
import VideoSpace from '../../../
|
16
|
+
import VideoSpace from '../../../Spaces/ViewVideo/ViewVideo';
|
17
17
|
import { SPACES } from '../../ViewWorld/constatnts';
|
18
18
|
|
19
19
|
const DetailedVideo = (props) => {
|
@@ -13,7 +13,7 @@ import WidgetContainer from "../../../Reusable Components/WidgetContainer/Widget
|
|
13
13
|
|
14
14
|
import worldStyles from '../../ViewWorld/styles.json';
|
15
15
|
|
16
|
-
import ViewAlbum from '../../../
|
16
|
+
import ViewAlbum from '../../../Spaces/ViewVideoAlbumList/ViewVideoAlbumList'
|
17
17
|
import { SPACES } from '../../ViewWorld/constatnts';
|
18
18
|
|
19
19
|
import { addObjectToArray, deleteFromArrayByIndex } from '../../../helpers/util';
|
@@ -9,117 +9,119 @@ import TextField from '../../Common Inputs/TextField/TextField';
|
|
9
9
|
|
10
10
|
|
11
11
|
const ChatPreview = (props) => {
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
}
|
24
|
-
},
|
25
|
-
customCardStyles: {
|
26
|
-
cardBackgroundColor: '',
|
27
|
-
onHoverBackgroundColor: '',
|
28
|
-
cardRadius: '',
|
29
|
-
cardTitleFontSize: '',
|
30
|
-
cardTitleFontWeight: '',
|
31
|
-
cardTitleColor: '',
|
32
|
-
cardImageRadius: '',
|
33
|
-
cardDescriptionFontSize: '',
|
34
|
-
cardDescriptionColor: '',
|
35
|
-
cardPadding: 0,
|
36
|
-
imgSize: 0,
|
37
|
-
cardBorderSize: 0,
|
38
|
-
cardBorderColor: 'purple',
|
39
|
-
dateColor: ''
|
40
|
-
}
|
12
|
+
const [chatStyles, setChatStyles] = useState({});
|
13
|
+
const initialValues = JSON.parse(localStorage.getItem('formStyles')) || {
|
14
|
+
headerStyles: {
|
15
|
+
headerBackground: '',
|
16
|
+
padding: 0,
|
17
|
+
titleColor: '',
|
18
|
+
titleFontSize: '',
|
19
|
+
titleFontWeight: '',
|
20
|
+
controlsStyles: {
|
21
|
+
iconSize: '',
|
22
|
+
iconColor: ''
|
41
23
|
}
|
24
|
+
},
|
25
|
+
customCardStyles: {
|
26
|
+
cardBackgroundColor: '',
|
27
|
+
onHoverBackgroundColor: '',
|
28
|
+
cardRadius: '',
|
29
|
+
cardTitleFontSize: '',
|
30
|
+
cardTitleFontWeight: '',
|
31
|
+
cardTitleColor: '',
|
32
|
+
cardImageRadius: '',
|
33
|
+
cardDescriptionFontSize: '',
|
34
|
+
cardDescriptionColor: '',
|
35
|
+
cardPadding: 0,
|
36
|
+
imgSize: 0,
|
37
|
+
cardBorderSize: 0,
|
38
|
+
cardBorderColor: 'purple',
|
39
|
+
dateColor: ''
|
40
|
+
}
|
41
|
+
}
|
42
42
|
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
]
|
55
|
-
},
|
56
|
-
{
|
57
|
-
title: "Card Styles",
|
58
|
-
body: [
|
59
|
-
(<Picker label="Card Background" name="customCardStyles.cardBackgroundColor" />),
|
60
|
-
(<Picker label="Hover Color" name="customCardStyles.onHoverBackgroundColor" />),
|
61
|
-
(<TextField type="number" label="Card Radius" name="customCardStyles.cardRadius" />),
|
62
|
-
(<TextField type="number" label="Title Font Size" name="customCardStyles.cardTitleFontSize" />),
|
63
|
-
(<TextField type="number" label="Title Font Weight" name="customCardStyles.cardTitleFontWeight" />),
|
64
|
-
(<Picker label="Title Color" name="customCardStyles.cardTitleColor" />),
|
65
|
-
(<TextField type="number" label="Card Image Radius" name="customCardStyles.cardImageRadius" />),
|
66
|
-
(<TextField type="number" label="Text Font Size" name="customCardStyles.cardDescriptionFontSize" />),
|
67
|
-
(<Picker label="Text Font Color" name="customCardStyles.cardDescriptionColor" />),
|
68
|
-
(<TextField type="number" label="Card Padding" name="customCardStyles.cardPadding" />),
|
69
|
-
(<TextField type="number" label="Image Size" name="customCardStyles.imgSize" />),
|
70
|
-
(<TextField type="number" label="Border Size" name="customCardStyles.cardBorderSize" />),
|
71
|
-
(<Picker label="Border Color" name="customCardStyles.cardBorderColor" />),
|
72
|
-
(<Picker label="Date Color" name="customCardStyles.dateColor" />),
|
73
|
-
]
|
74
|
-
},
|
43
|
+
const sections = [
|
44
|
+
{
|
45
|
+
title: "Header Styles",
|
46
|
+
body: [
|
47
|
+
(<Picker label="Header Background" name="headerStyles.headerBackground" />),
|
48
|
+
(<TextField type="number" label="Padding" name="headerStyles.padding" />),
|
49
|
+
(<Picker label="Title Color" name="headerStyles.titleColor" />),
|
50
|
+
(<TextField type="number" label="Title Font Size" name="headerStyles.titleFontSize" />),
|
51
|
+
(<TextField type="number" label="Title Font Weight" name="headerStyles.titleFontWeight" />),
|
52
|
+
(<TextField type="number" label="Controls Size" name="headerStyles.controlsStyles.iconSize" />),
|
53
|
+
(<Picker label="Controls Color" name="headerStyles.controlsStyles.iconColor" />),
|
75
54
|
]
|
55
|
+
},
|
56
|
+
{
|
57
|
+
title: "Card Styles",
|
58
|
+
body: [
|
59
|
+
(<Picker label="Card Background" name="customCardStyles.cardBackgroundColor" />),
|
60
|
+
(<Picker label="Hover Color" name="customCardStyles.onHoverBackgroundColor" />),
|
61
|
+
(<TextField type="number" label="Card Radius" name="customCardStyles.cardRadius" />),
|
62
|
+
(<TextField type="number" label="Title Font Size" name="customCardStyles.cardTitleFontSize" />),
|
63
|
+
(<TextField type="number" label="Title Font Weight" name="customCardStyles.cardTitleFontWeight" />),
|
64
|
+
(<Picker label="Title Color" name="customCardStyles.cardTitleColor" />),
|
65
|
+
(<TextField type="number" label="Card Image Radius" name="customCardStyles.cardImageRadius" />),
|
66
|
+
(<TextField type="number" label="Text Font Size" name="customCardStyles.cardDescriptionFontSize" />),
|
67
|
+
(<Picker label="Text Font Color" name="customCardStyles.cardDescriptionColor" />),
|
68
|
+
(<TextField type="number" label="Card Padding" name="customCardStyles.cardPadding" />),
|
69
|
+
(<TextField type="number" label="Image Size" name="customCardStyles.imgSize" />),
|
70
|
+
(<TextField type="number" label="Border Size" name="customCardStyles.cardBorderSize" />),
|
71
|
+
(<Picker label="Border Color" name="customCardStyles.cardBorderColor" />),
|
72
|
+
(<Picker label="Date Color" name="customCardStyles.dateColor" />),
|
73
|
+
]
|
74
|
+
},
|
75
|
+
]
|
76
76
|
|
77
|
-
|
78
|
-
|
79
|
-
|
80
|
-
|
81
|
-
|
82
|
-
|
83
|
-
}
|
84
|
-
|
85
|
-
const submitHandler = (values) => {
|
86
|
-
console.log(values);
|
87
|
-
}
|
88
|
-
|
89
|
-
const cancelHandler = () => {
|
90
|
-
console.log('Canceled')
|
77
|
+
const handleChange = (values) => {
|
78
|
+
if (props.formChanged) {
|
79
|
+
if (values) {
|
80
|
+
props.formChanged(values)
|
81
|
+
setChatStyles(values)
|
82
|
+
localStorage.setItem('formStyles', JSON.stringify(values))
|
91
83
|
}
|
84
|
+
}
|
85
|
+
}
|
86
|
+
|
87
|
+
const submitHandler = (values) => {
|
88
|
+
console.log(values);
|
89
|
+
}
|
90
|
+
|
91
|
+
const cancelHandler = () => {
|
92
|
+
console.log('Canceled')
|
93
|
+
}
|
92
94
|
return (
|
93
95
|
<Container>
|
94
|
-
|
95
|
-
|
96
|
-
|
97
|
-
|
98
|
-
|
99
|
-
|
100
|
-
|
101
|
-
|
102
|
-
|
103
|
-
|
104
|
-
|
105
|
-
|
106
|
-
|
107
|
-
|
108
|
-
|
109
|
-
|
110
|
-
|
111
|
-
|
112
|
-
|
113
|
-
|
114
|
-
|
115
|
-
|
116
|
-
|
117
|
-
|
118
|
-
|
119
|
-
|
120
|
-
|
121
|
-
|
122
|
-
|
96
|
+
<Left>
|
97
|
+
<ReusableForm
|
98
|
+
formTitle="Chat Styles"
|
99
|
+
initialValues={initialValues}
|
100
|
+
sections={sections}
|
101
|
+
headerStyles={{
|
102
|
+
padding: 10,
|
103
|
+
headerBackground: 'black',
|
104
|
+
titleColor: '#ffff',
|
105
|
+
}}
|
106
|
+
sectionHeaderStyles={{
|
107
|
+
padding: 6,
|
108
|
+
headerBackground: '#FE1744',
|
109
|
+
titleColor: '#ffff',
|
110
|
+
}}
|
111
|
+
bodyPadding={10}
|
112
|
+
saveBtnText="Save"
|
113
|
+
cancelBtnText="Cancel"
|
114
|
+
saveBtnHandle={submitHandler}
|
115
|
+
cancelHandler={cancelHandler}
|
116
|
+
handleChange={handleChange}
|
117
|
+
bodyRowGap={20}
|
118
|
+
bodyColumnGap={10}
|
119
|
+
/>
|
120
|
+
</Left>
|
121
|
+
<Right>
|
122
|
+
<Preview type={'Chat'} componentProps={props.componentProps} stylingProps={chatStyles} />
|
123
|
+
</Right>
|
124
|
+
</Container>
|
123
125
|
);
|
124
126
|
};
|
125
127
|
|
@@ -58,10 +58,12 @@ const EventPreview = (props) => {
|
|
58
58
|
]
|
59
59
|
|
60
60
|
const handleChange = (values) => {
|
61
|
-
if(
|
62
|
-
|
63
|
-
|
64
|
-
|
61
|
+
if (props.formChanged) {
|
62
|
+
if (values) {
|
63
|
+
props.formChanged(values)
|
64
|
+
setEventStyles(values)
|
65
|
+
localStorage.setItem('formStyles', JSON.stringify(values))
|
66
|
+
}
|
65
67
|
}
|
66
68
|
}
|
67
69
|
|