@mohamed-karawia/library 0.1.17 → 0.1.21

Sign up to get free protection for your applications and to get access to all the features.
Files changed (132) hide show
  1. package/dist/stories/Chat/Chat.js +129 -14
  2. package/dist/stories/Common Inputs/Picker/Picker.js +61 -0
  3. package/dist/stories/Common Inputs/TextField/TextField.js +3 -1
  4. package/dist/stories/Community/Community.js +137 -0
  5. package/dist/stories/Enrollment/Admin/DetailedForm/DetailedForm.js +10 -12
  6. package/dist/stories/Enrollment/Admin/ViewForms/ViewForms.js +1 -1
  7. package/dist/stories/Enrollment/Guest/FillForm/FillForm.js +4 -17
  8. package/dist/stories/Events/Event/Event.js +116 -5
  9. package/dist/stories/Events/EventsList/EventsList.js +94 -19
  10. package/dist/stories/Forms/CreateSpace/CreateSpace.js +75 -0
  11. package/dist/stories/Library/Folders/Folders.js +77 -5
  12. package/dist/stories/Library/Notes/Notes.js +78 -4
  13. package/dist/stories/Modals/NavbarPreviewModal/NavbarPreviewModal.js +54 -0
  14. package/dist/stories/Music Album/ViewAlbum/ViewAlbum.js +137 -15
  15. package/dist/stories/Music Album/ViewAlbums/ViewAlbums.js +67 -28
  16. package/dist/stories/Navbar/Navbar.js +1 -1
  17. package/dist/stories/Pages/Enrollment/DetailedForm/DetailedForm.js +8 -0
  18. package/dist/stories/Pages/Enrollment/FillForm/FillForm.js +7 -1
  19. package/dist/stories/Pages/Enrollment/Forms/Forms.js +3 -1
  20. package/dist/stories/Pages/Events/Event/Event.js +14 -5
  21. package/dist/stories/Pages/Events/Events/Events.js +1 -0
  22. package/dist/stories/Pages/Music/MusicAlbum/Music.js +8 -6
  23. package/dist/stories/Pages/Music/MusicAlbums/MusicAlbums.js +2 -15
  24. package/dist/stories/Pages/Photos/Albums/Albums.js +4 -1
  25. package/dist/stories/Photo Album/ViewAlbum/ViewAlbum.js +80 -19
  26. package/dist/stories/Photo Album/ViewAlbums/ViewAlbums.js +83 -25
  27. package/dist/stories/Preview/Preview.js +37 -0
  28. package/dist/stories/PreviewComponents/ChatPreview/ChatPreview.js +193 -0
  29. package/dist/stories/PreviewComponents/EventPreview/EventPreview.js +158 -0
  30. package/dist/stories/PreviewComponents/EventsPreview/EventsPreview.js +192 -0
  31. package/dist/stories/PreviewComponents/FoldersPreview/FoldersPreview.js +182 -0
  32. package/dist/stories/PreviewComponents/MusicAlbumPreview/MusicAlbumPreview.js +177 -0
  33. package/dist/stories/PreviewComponents/MusicAlbumsPreview/MusicAlbumsPreview.js +181 -0
  34. package/dist/stories/PreviewComponents/MusicPlayerPreview/MusicPlayerPreview.js +153 -0
  35. package/dist/stories/PreviewComponents/NavbarPreview/NavbarPreview.js +112 -0
  36. package/dist/stories/PreviewComponents/NotesPreview/NotesPreview.js +173 -0
  37. package/dist/stories/PreviewComponents/PhotoAlbumPreview/PhotoAlbumPreview.js +189 -0
  38. package/dist/stories/PreviewComponents/PhotoAlbumsPreview/PhotoAlbumsPreview.js +189 -0
  39. package/dist/stories/PreviewComponents/SpacesListPreview/SpacesListPreview.js +197 -0
  40. package/dist/stories/PreviewComponents/VideoAlbumPreview/VideoAlbumPreview.js +189 -0
  41. package/dist/stories/PreviewComponents/VideoAlbumsPreview/VideoAlbumsPreview.js +175 -0
  42. package/dist/stories/PreviewComponents/VideoPreview/VideoPreview.js +172 -0
  43. package/dist/stories/PreviewComponents/globalStyles.js +26 -0
  44. package/dist/stories/Reusable Components/Cards/Card-style-10/CardStyle10.js +4 -3
  45. package/dist/stories/Reusable Components/Cards/Card-style-11/CardStyle11.js +8 -4
  46. package/dist/stories/Reusable Components/Cards/Card-style-6/CardStyle6.js +10 -4
  47. package/dist/stories/Reusable Components/Cards/Card-style-8/CardStyle8.js +4 -2
  48. package/dist/stories/Reusable Components/Cards/globalCardStyles.js +2 -2
  49. package/dist/stories/Reusable Components/Community/Community.js +75 -0
  50. package/dist/stories/Reusable Components/Gallery/Gallery.js +17 -18
  51. package/dist/stories/Reusable Components/ReactModal/ReactModal.js +11 -30
  52. package/dist/stories/Reusable Components/ReusableForm/ReusableForm.js +20 -3
  53. package/dist/stories/Reusable Components/ReusableList/ReusableList.js +9 -5
  54. package/dist/stories/Reusable Components/Tabs/Tabs.js +68 -0
  55. package/dist/stories/Sections/Sections.js +8 -2
  56. package/dist/stories/VideoAlbum/AlbumsGallery/AlbumsGallery.js +77 -18
  57. package/dist/stories/VideoAlbum/VideoSpace/VideoSpace.js +96 -3
  58. package/dist/stories/VideoAlbum/ViewAlbum/ViewAlbum.js +78 -5
  59. package/dist/stories/Widgets/MusicPlayerWidget/MusicPlayerWidget.js +17 -11
  60. package/dist/stories/Widgets/SpacesListWidget/SpacesListWidget.js +115 -0
  61. package/dist/stories/Widgets/UsersWidget/UsersWidget.js +30 -0
  62. package/dist/stories/helpers/util.js +60 -3
  63. package/dist/stories/store/communities.js +943 -0
  64. package/dist/stories/store/store.js +44 -0
  65. package/package.json +5 -2
  66. package/src/stories/Chat/Chat.jsx +109 -13
  67. package/src/stories/Common Inputs/Picker/Picker.jsx +47 -0
  68. package/src/stories/Common Inputs/TextField/TextField.jsx +1 -1
  69. package/src/stories/Community/Community.jsx +110 -0
  70. package/src/stories/Enrollment/Admin/DetailedForm/DetailedForm.jsx +7 -9
  71. package/src/stories/Enrollment/Admin/ViewForms/ViewForms.jsx +3 -2
  72. package/src/stories/Enrollment/Guest/FillForm/FillForm.jsx +6 -16
  73. package/src/stories/Events/Event/Event.jsx +98 -5
  74. package/src/stories/Events/EventsList/EventsList.jsx +101 -22
  75. package/src/stories/Forms/CreateSpace/CreateSpace.jsx +73 -0
  76. package/src/stories/Library/Folders/Folders.jsx +81 -5
  77. package/src/stories/Library/Notes/Notes.jsx +65 -5
  78. package/src/stories/Modals/NavbarPreviewModal/NavbarPreviewModal.jsx +31 -0
  79. package/src/stories/Music Album/ViewAlbum/ViewAlbum.jsx +133 -14
  80. package/src/stories/Music Album/ViewAlbums/ViewAlbums.jsx +61 -32
  81. package/src/stories/Navbar/Navbar.jsx +1 -1
  82. package/src/stories/Pages/Enrollment/DetailedForm/DetailedForm.jsx +10 -1
  83. package/src/stories/Pages/Enrollment/FillForm/FillForm.jsx +6 -0
  84. package/src/stories/Pages/Enrollment/Forms/Forms.jsx +3 -1
  85. package/src/stories/Pages/Events/Event/Event.jsx +12 -4
  86. package/src/stories/Pages/Events/Events/Events.jsx +75 -74
  87. package/src/stories/Pages/Library/Folders/Library.jsx +1 -1
  88. package/src/stories/Pages/Music/MusicAlbum/Music.jsx +8 -6
  89. package/src/stories/Pages/Music/MusicAlbums/MusicAlbums.jsx +0 -13
  90. package/src/stories/Pages/Photos/Albums/Albums.jsx +3 -0
  91. package/src/stories/Photo Album/ViewAlbum/ViewAlbum.jsx +63 -13
  92. package/src/stories/Photo Album/ViewAlbums/ViewAlbums.jsx +66 -33
  93. package/src/stories/Preview/Preview.jsx +35 -0
  94. package/src/stories/PreviewComponents/ChatPreview/ChatPreview.jsx +132 -0
  95. package/src/stories/PreviewComponents/EventPreview/EventPreview.jsx +116 -0
  96. package/src/stories/PreviewComponents/EventsPreview/EventsPreview.jsx +132 -0
  97. package/src/stories/PreviewComponents/FoldersPreview/FoldersPreview.jsx +127 -0
  98. package/src/stories/PreviewComponents/MusicAlbumPreview/MusicAlbumPreview.jsx +124 -0
  99. package/src/stories/PreviewComponents/MusicAlbumsPreview/MusicAlbumsPreview.jsx +126 -0
  100. package/src/stories/PreviewComponents/MusicPlayerPreview/MusicPlayerPreview.jsx +113 -0
  101. package/src/stories/PreviewComponents/NavbarPreview/NavbarPreview.jsx +93 -0
  102. package/src/stories/PreviewComponents/NotesPreview/NotesPreview.jsx +122 -0
  103. package/src/stories/PreviewComponents/PhotoAlbumPreview/PhotoAlbumPreview.jsx +129 -0
  104. package/src/stories/PreviewComponents/PhotoAlbumsPreview/PhotoAlbumsPreview.jsx +129 -0
  105. package/src/stories/PreviewComponents/SpacesListPreview/SpacesListPreview.jsx +138 -0
  106. package/src/stories/PreviewComponents/VideoAlbumPreview/VideoAlbumPreview.jsx +129 -0
  107. package/src/stories/PreviewComponents/VideoAlbumsPreview/VideoAlbumsPreview.jsx +124 -0
  108. package/src/stories/PreviewComponents/VideoPreview/VideoPreview.jsx +125 -0
  109. package/src/stories/PreviewComponents/globalStyles.js +20 -0
  110. package/src/stories/Reusable Components/Cards/Card-style-10/CardStyle10.jsx +5 -2
  111. package/src/stories/Reusable Components/Cards/Card-style-11/CardStyle11.jsx +5 -5
  112. package/src/stories/Reusable Components/Cards/Card-style-6/CardStyle6.jsx +12 -6
  113. package/src/stories/Reusable Components/Cards/Card-style-8/CardStyle8.jsx +2 -2
  114. package/src/stories/Reusable Components/Cards/globalCardStyles.js +2 -1
  115. package/src/stories/Reusable Components/Community/Community.jsx +70 -0
  116. package/src/stories/Reusable Components/Gallery/Gallery.jsx +15 -10
  117. package/src/stories/Reusable Components/ReactModal/ReactModal.jsx +3 -25
  118. package/src/stories/Reusable Components/ReusableForm/ReusableForm.jsx +19 -7
  119. package/src/stories/Reusable Components/ReusableHeader/ReusableHeader.jsx +0 -2
  120. package/src/stories/Reusable Components/ReusableList/ReusableList.jsx +9 -4
  121. package/src/stories/Reusable Components/Tabs/Tabs.jsx +67 -0
  122. package/src/stories/Sections/Sections.jsx +5 -2
  123. package/src/stories/VideoAlbum/AlbumsGallery/AlbumsGallery.jsx +57 -16
  124. package/src/stories/VideoAlbum/VideoSpace/VideoSpace.jsx +70 -1
  125. package/src/stories/VideoAlbum/ViewAlbum/ViewAlbum.jsx +65 -8
  126. package/src/stories/Widgets/MusicPlayerWidget/MusicPlayerWidget.jsx +14 -7
  127. package/src/stories/Widgets/SpacesListWidget/SpacesListWidget.jsx +78 -0
  128. package/src/stories/Widgets/UsersWidget/UsersWidget.jsx +20 -0
  129. package/src/stories/helpers/util.js +42 -2
  130. package/src/stories/store/communities.js +705 -0
  131. package/src/stories/store/store.js +33 -0
  132. package/src/stories/styling.json +92 -0
@@ -0,0 +1,129 @@
1
+ import React, { useState } from 'react';
2
+ import PropTypes from 'prop-types';
3
+ import Preview from '../../Preview/Preview';
4
+ import ReusableForm from '../../Reusable Components/ReusableForm/ReusableForm';
5
+
6
+ import { Container, Left, Right } from '../globalStyles';
7
+ import Picker from '../../Common Inputs/Picker/Picker';
8
+ import TextField from '../../Common Inputs/TextField/TextField';
9
+
10
+ const VideoAlbumPreview = (props) => {
11
+ const [videoAlbumStyles, setVideoAlbumStyles] = useState({});
12
+ const initialValues = {
13
+ headerStyles: {
14
+ headerBackground: '',
15
+ padding: 0,
16
+ titleColor: '',
17
+ titleFontSize: '',
18
+ titleFontWeight: '',
19
+ controlsStyles: {
20
+ iconSize: '',
21
+ iconColor: ''
22
+ }
23
+ },
24
+ customCardStyles: {
25
+ cardBackgroundColor: '',
26
+ onHoverBackgroundColor: '',
27
+ cardRadius: '',
28
+ cardTitleFontSize: '',
29
+ cardTitleFontWeight: '',
30
+ cardTitleColor: '',
31
+ cardImageRadius: '',
32
+ cardDescriptionFontSize: '',
33
+ cardDescriptionColor: '',
34
+ cardPadding: 0,
35
+ imgSize: 0,
36
+ cardBorderSize: 0,
37
+ cardBorderColor: 'purple'
38
+ }
39
+ }
40
+
41
+ const sections = [
42
+ {
43
+ title: "Header Styles",
44
+ body: [
45
+ (<Picker label="Header Background" name="headerStyles.headerBackground" />),
46
+ (<TextField type="number" label="Padding" name="headerStyles.padding" />),
47
+ (<Picker label="Title Color" name="headerStyles.titleColor" />),
48
+ (<TextField type="number" label="Title Font Size" name="headerStyles.titleFontSize" />),
49
+ (<TextField type="number" label="Title Font Weight" name="headerStyles.titleFontWeight" />),
50
+ (<TextField type="number" label="Controls Size" name="headerStyles.controlsStyles.iconSize" />),
51
+ (<Picker label="Controls Color" name="headerStyles.controlsStyles.iconColor" />),
52
+ ]
53
+ },
54
+ {
55
+ title: "Card Styles",
56
+ body: [
57
+ (<Picker label="Card Background" name="customCardStyles.cardBackgroundColor" />),
58
+ (<Picker label="Hover Color" name="customCardStyles.onHoverBackgroundColor" />),
59
+ (<TextField type="number" label="Card Radius" name="customCardStyles.cardRadius" />),
60
+ (<TextField type="number" label="Title Font Size" name="customCardStyles.cardTitleFontSize" />),
61
+ (<TextField type="number" label="Title Font Weight" name="customCardStyles.cardTitleFontWeight" />),
62
+ (<Picker label="Title Color" name="customCardStyles.cardTitleColor" />),
63
+ (<TextField type="number" label="Card Image Radius" name="customCardStyles.cardImageRadius" />),
64
+ (<TextField type="number" label="Artist Font Size" name="customCardStyles.cardDescriptionFontSize" />),
65
+ (<Picker label="Artist Font Color" name="customCardStyles.cardDescriptionColor" />),
66
+ (<TextField type="number" label="Card Padding" name="customCardStyles.cardPadding" />),
67
+ (<TextField type="number" label="Image Size" name="customCardStyles.imgSize" />),
68
+ (<TextField type="number" label="Border Size" name="customCardStyles.cardBorderSize" />),
69
+ (<Picker label="Border Color" name="customCardStyles.cardBorderColor" />),
70
+ ]
71
+ },
72
+ ]
73
+
74
+ const handleChange = (values) => {
75
+ if(values){
76
+ props.formChanged(values)
77
+ setVideoAlbumStyles(values)
78
+ localStorage.setItem('formStyles', JSON.stringify(values))
79
+ }
80
+ }
81
+
82
+ const submitHandler = (values) => {
83
+ console.log(values);
84
+ }
85
+
86
+ const cancelHandler = () => {
87
+ console.log('Canceled')
88
+ }
89
+ return (
90
+ <Container>
91
+ <Left>
92
+ <ReusableForm
93
+ formTitle="Video Albums Styles"
94
+ initialValues={initialValues}
95
+ sections={sections}
96
+ headerStyles={{
97
+ padding: 10,
98
+ headerBackground: 'black',
99
+ titleColor: '#ffff',
100
+ }}
101
+ sectionHeaderStyles={{
102
+ padding: 6,
103
+ headerBackground: '#FE1744',
104
+ titleColor: '#ffff',
105
+ }}
106
+ bodyPadding={10}
107
+ saveBtnText="Save"
108
+ cancelBtnText="Cancel"
109
+ saveBtnHandle={submitHandler}
110
+ cancelHandler={cancelHandler}
111
+ handleChange={handleChange}
112
+ bodyRowGap={20}
113
+ bodyColumnGap={10}
114
+ />
115
+ </Left>
116
+ <Right>
117
+ <Preview type={'Video-Album'} componentProps={props.componentProps} stylingProps={videoAlbumStyles} />
118
+ </Right>
119
+ </Container>
120
+ );
121
+ };
122
+
123
+ VideoAlbumPreview.defaultProps = {};
124
+
125
+ VideoAlbumPreview.propTypes = {
126
+ componentProps: PropTypes.object
127
+ }
128
+
129
+ export default VideoAlbumPreview;
@@ -0,0 +1,124 @@
1
+ import React, { useState } from 'react';
2
+ import PropTypes from 'prop-types';
3
+ import Preview from '../../Preview/Preview';
4
+ import ReusableForm from '../../Reusable Components/ReusableForm/ReusableForm';
5
+
6
+ import { Container, Left, Right } from '../globalStyles';
7
+ import Picker from '../../Common Inputs/Picker/Picker';
8
+ import TextField from '../../Common Inputs/TextField/TextField';
9
+
10
+
11
+ const VideoAlbumsPreview = (props) => {
12
+ const [videoAlbumsStyles, setVideoAlbumsStyles] = useState({});
13
+ const initialValues = {
14
+ headerStyles: {
15
+ headerBackground: '',
16
+ padding: 0,
17
+ titleColor: '',
18
+ titleFontSize: '',
19
+ titleFontWeight: '',
20
+ controlsStyles: {
21
+ iconSize: '',
22
+ iconColor: ''
23
+ }
24
+ },
25
+ customCardStyles: {
26
+ cardBackgroundColor: '',
27
+ onHoverBackgroundColor: '',
28
+ cardRadius: '',
29
+ cardTitleFontSize: '',
30
+ cardTitleFontWeight: '',
31
+ cardTitleColor: '',
32
+ cardImageRadius: '',
33
+ cardPadding: 0,
34
+ cardBorderSize: 0,
35
+ cardBorderColor: 'purple'
36
+ }
37
+ }
38
+
39
+ const sections = [
40
+ {
41
+ title: "Header Styles",
42
+ body: [
43
+ (<Picker label="Header Background" name="headerStyles.headerBackground" />),
44
+ (<TextField type="number" label="Padding" name="headerStyles.padding" />),
45
+ (<Picker label="Title Color" name="headerStyles.titleColor" />),
46
+ (<TextField type="number" label="Title Font Size" name="headerStyles.titleFontSize" />),
47
+ (<TextField type="number" label="Title Font Weight" name="headerStyles.titleFontWeight" />),
48
+ (<TextField type="number" label="Controls Size" name="headerStyles.controlsStyles.iconSize" />),
49
+ (<Picker label="Controls Color" name="headerStyles.controlsStyles.iconColor" />),
50
+ ]
51
+ },
52
+ {
53
+ title: "Card Styles",
54
+ body: [
55
+ (<Picker label="Card Background" name="customCardStyles.cardBackgroundColor" />),
56
+ (<Picker label="Hover Color" name="customCardStyles.onHoverBackgroundColor" />),
57
+ (<TextField type="number" label="Card Radius" name="customCardStyles.cardRadius" />),
58
+ (<TextField type="number" label="Title Font Size" name="customCardStyles.cardTitleFontSize" />),
59
+ (<TextField type="number" label="Title Font Weight" name="customCardStyles.cardTitleFontWeight" />),
60
+ (<Picker label="Title Color" name="customCardStyles.cardTitleColor" />),
61
+ (<TextField type="number" label="Card Image Radius" name="customCardStyles.cardImageRadius" />),
62
+ (<TextField type="number" label="Card Padding" name="customCardStyles.cardPadding" />),
63
+ (<TextField type="number" label="Border Size" name="customCardStyles.cardBorderSize" />),
64
+ (<Picker label="Border Color" name="customCardStyles.cardBorderColor" />),
65
+ ]
66
+ },
67
+ ]
68
+
69
+ const handleChange = (values) => {
70
+ if(values){
71
+ props.formChanged(values)
72
+ setVideoAlbumsStyles(values)
73
+ localStorage.setItem('formStyles', JSON.stringify(values))
74
+ }
75
+ }
76
+
77
+ const submitHandler = (values) => {
78
+ console.log(values);
79
+ }
80
+
81
+ const cancelHandler = () => {
82
+ console.log('Canceled')
83
+ }
84
+ return (
85
+ <Container>
86
+ <Left>
87
+ <ReusableForm
88
+ formTitle="Video Albums Styles"
89
+ initialValues={initialValues}
90
+ sections={sections}
91
+ headerStyles={{
92
+ padding: 10,
93
+ headerBackground: 'black',
94
+ titleColor: '#ffff',
95
+ }}
96
+ sectionHeaderStyles={{
97
+ padding: 6,
98
+ headerBackground: '#FE1744',
99
+ titleColor: '#ffff',
100
+ }}
101
+ bodyPadding={10}
102
+ saveBtnText="Save"
103
+ cancelBtnText="Cancel"
104
+ saveBtnHandle={submitHandler}
105
+ cancelHandler={cancelHandler}
106
+ handleChange={handleChange}
107
+ bodyRowGap={20}
108
+ bodyColumnGap={10}
109
+ />
110
+ </Left>
111
+ <Right>
112
+ <Preview type={'Video-Albums'} componentProps={props.componentProps} stylingProps={videoAlbumsStyles} />
113
+ </Right>
114
+ </Container>
115
+ );
116
+ };
117
+
118
+ VideoAlbumsPreview.defaultProps = {};
119
+
120
+ VideoAlbumsPreview.propTypes = {
121
+ componentProps: PropTypes.object
122
+ }
123
+
124
+ export default VideoAlbumsPreview;
@@ -0,0 +1,125 @@
1
+ import React, { useState } from 'react';
2
+ import PropTypes from 'prop-types';
3
+ import Preview from '../../Preview/Preview';
4
+ import ReusableForm from '../../Reusable Components/ReusableForm/ReusableForm';
5
+
6
+ import { Container, Left, Right } from '../globalStyles';
7
+ import Picker from '../../Common Inputs/Picker/Picker';
8
+ import TextField from '../../Common Inputs/TextField/TextField';
9
+
10
+ const VideoPreview = (props) => {
11
+ const [videoStyles, setVideoStyles] = useState({});
12
+ const initialValues = {
13
+ headerStyles: {
14
+ headerBackground: '',
15
+ padding: 0,
16
+ titleColor: '',
17
+ titleFontSize: '',
18
+ titleFontWeight: '',
19
+ },
20
+ iconsColor: '',
21
+ backgroundColor: '',
22
+ detailsPadding: '',
23
+ titleFontSize: '',
24
+ titleColor: '',
25
+ discFontSize: '',
26
+ discColor: '',
27
+ dateFontSize: '',
28
+ dateColor: '',
29
+ commentBackgroundColor: '',
30
+ commentTitleColor: '',
31
+ commentTitleFontSize: ''
32
+ }
33
+
34
+ const sections = [
35
+ {
36
+ title: "Header Styles",
37
+ body: [
38
+ (<Picker label="Header Background" name="headerStyles.headerBackground" />),
39
+ (<TextField type="number" label="Padding" name="headerStyles.padding" />),
40
+ (<Picker label="Title Color" name="headerStyles.titleColor" />),
41
+ (<TextField type="number" label="Title Font Size" name="headerStyles.titleFontSize" />),
42
+ (<TextField type="number" label="Title Font Weight" name="headerStyles.titleFontWeight" />)
43
+ ]
44
+ },
45
+ {
46
+ title: "Player Styles",
47
+ body: [
48
+ (<Picker label="Icons Color" name="iconsColor" />),
49
+ ]
50
+ },
51
+ {
52
+ title: "Space Styles",
53
+ body: [
54
+ (<Picker label="Background Color" name="backgroundColor" />),
55
+ (<TextField type="number" label="Details Padding" name="detailsPadding" />),
56
+ (<TextField type="number" label="Title Font Size" name="titleFontSize" />),
57
+ (<Picker label="Title Color" name="titleColor" />),
58
+ (<TextField type="number" label="Discription Font Size" name="discFontSize" />),
59
+ (<Picker label="Discription Color" name="discColor" />),
60
+ (<TextField type="number" label="Date Font Size" name="dateFontSize" />),
61
+ (<Picker label="Date Color" name="dateColor" />),
62
+ (<Picker label="Comment Background Color" name="commentBackgroundColor" />),
63
+ (<Picker label="Comment Title Color" name="commentTitleColor" />),
64
+ (<TextField type="number" label="Comment title Font Size" name="commentTitleFontSize" />),
65
+ ]
66
+ },
67
+ ]
68
+
69
+ const handleChange = (values) => {
70
+ if(values){
71
+ props.formChanged(values)
72
+ setVideoStyles(values)
73
+ localStorage.setItem('formStyles', JSON.stringify(values))
74
+ }
75
+ }
76
+
77
+ const submitHandler = (values) => {
78
+ console.log(values);
79
+ }
80
+
81
+ const cancelHandler = () => {
82
+ console.log('Canceled')
83
+ }
84
+
85
+ return (
86
+ <Container>
87
+ <Left>
88
+ <ReusableForm
89
+ formTitle="Video Styles"
90
+ initialValues={initialValues}
91
+ sections={sections}
92
+ headerStyles={{
93
+ padding: 10,
94
+ headerBackground: 'black',
95
+ titleColor: '#ffff',
96
+ }}
97
+ sectionHeaderStyles={{
98
+ padding: 6,
99
+ headerBackground: '#FE1744',
100
+ titleColor: '#ffff',
101
+ }}
102
+ bodyPadding={10}
103
+ saveBtnText="Save"
104
+ cancelBtnText="Cancel"
105
+ saveBtnHandle={submitHandler}
106
+ cancelHandler={cancelHandler}
107
+ handleChange={handleChange}
108
+ bodyRowGap={20}
109
+ bodyColumnGap={10}
110
+ />
111
+ </Left>
112
+ <Right>
113
+ <Preview type={'Video-Space'} componentProps={props.componentProps} stylingProps={videoStyles} />
114
+ </Right>
115
+ </Container>
116
+ );
117
+ };
118
+
119
+ VideoPreview.defaultProps = {};
120
+
121
+ VideoPreview.propTypes = {
122
+ componentProps: PropTypes.object
123
+ }
124
+
125
+ export default VideoPreview;
@@ -0,0 +1,20 @@
1
+ import styled from 'styled-components';
2
+
3
+
4
+ export const Container = styled.div`
5
+ width: 100%;
6
+ display: flex;
7
+ background-color: 'transparent';
8
+ align-items: flex-start;
9
+ `
10
+
11
+ export const Left = styled.div`
12
+ flex: 1;
13
+ `
14
+
15
+ export const Right = styled.div`
16
+ flex: 2;
17
+ position: sticky;
18
+ top: 0;
19
+ bottom: 0;
20
+ `
@@ -35,7 +35,7 @@ const CardStyle10 = ({
35
35
  </SvgWrapper>
36
36
  <Content {...props}>
37
37
  <Title {...props}>{title}</Title>
38
- <Description {...props}>{description}</Description>
38
+ <CardDescription {...props}>{description}</CardDescription>
39
39
  </Content>
40
40
  <Controls
41
41
  controls={cardControls}
@@ -62,7 +62,6 @@ const Card = styled(MainCard)`
62
62
 
63
63
  const Content = styled(globalContent)`
64
64
  align-items: center;
65
- justify-content: space-between;
66
65
 
67
66
  `
68
67
 
@@ -75,6 +74,10 @@ const SvgWrapper = styled.div`
75
74
  }
76
75
  `
77
76
 
77
+ const CardDescription = styled(Description)`
78
+ text-align: center;
79
+ `
80
+
78
81
  CardStyle10.defaultProps = {}
79
82
 
80
83
  CardStyle10.propTypes = {
@@ -21,13 +21,13 @@ const CardStyle11 = ({ title, date, ...props }) => {
21
21
 
22
22
  return (
23
23
  <Card
24
- onClick={cardClicked}
24
+
25
25
  {...props}>
26
- <SvgWrapper {...props}>
26
+ <SvgWrapper onClick={cardClicked} {...props}>
27
27
  <BiNotepad />
28
28
  </SvgWrapper>
29
29
  <Content {...props}>
30
- <Title {...props}>{title}</Title>
30
+ <Title onClick={cardClicked} {...props}>{title}</Title>
31
31
  <Date {...props}>{date}</Date>
32
32
  </Content>
33
33
  {props.cardControls
@@ -46,7 +46,7 @@ const Card = styled(MainCard)`
46
46
  `
47
47
 
48
48
  const Date = styled.h5`
49
- color: gray;
49
+ color: ${props => props.dateColor || 'gray'};
50
50
  font-weight: 300;
51
51
  `
52
52
 
@@ -57,7 +57,7 @@ const Content = styled(globalContent)`
57
57
  `
58
58
 
59
59
  const SvgWrapper = styled.div`
60
-
60
+ cursor: pointer;
61
61
  svg{
62
62
  width: 50px;
63
63
  height: 50px;
@@ -24,9 +24,9 @@ const CardStyle6 = ({ title, description, img, date, ...props }) => {
24
24
  onMouseEnter={e => setShowIcons(true)}
25
25
  onMouseLeave={e => setShowIcons(false)}
26
26
  {...props}>
27
- <ImgWrapper
28
- onClick={() => props.cardClicked()}
29
- {...props}>
27
+ <ImgWrapper
28
+ onClick={() => props.cardClicked()}
29
+ {...props}>
30
30
  <Img src={img} />
31
31
  </ImgWrapper>
32
32
  <Content {...props}>
@@ -43,6 +43,12 @@ const CardStyle6 = ({ title, description, img, date, ...props }) => {
43
43
  controls={props.cardControls}
44
44
  show={showIcons}
45
45
  onIconClicked={iconCliked}
46
+ showOnHover={true}
47
+ position='center'
48
+ dropdownFontColor="white"
49
+ iconBorderRadius={100}
50
+ iconSize={40}
51
+ iconsGap={10}
46
52
  {...props.controlsStyles} />}
47
53
  </Card>
48
54
  )
@@ -51,12 +57,12 @@ const CardStyle6 = ({ title, description, img, date, ...props }) => {
51
57
  const Card = styled(MainCard)`
52
58
  flex-direction: column;
53
59
  cursor: pointer;
54
- height: 100%;
60
+ overflow-y: scroll;
55
61
  `
56
62
 
57
63
  const ImgWrapper = styled.div`
58
64
  width: 100%;
59
- height: 80%;
65
+ min-height: 90%;
60
66
  border-radius: ${props => props.cardRadius + 'px ' + props.cardRadius + 'px ' + '0 0'};
61
67
  `
62
68
 
@@ -92,7 +98,7 @@ const Date = styled.p`
92
98
 
93
99
  const Desc = styled(Description)`
94
100
  padding: 2px 20px;
95
- color: ${props => props.descColor || '#5f5f5f'};
101
+ color: ${props => props.cardDiscriptionColor};
96
102
  `
97
103
 
98
104
  CardStyle6.defaultProps = {}
@@ -29,7 +29,7 @@ const CardStyle8 = ({ username, date, text, img, media, ...props }) => {
29
29
  <Content {...props}>
30
30
  <Header>
31
31
  <Title {...props}>{username}</Title>
32
- <Date>{date}</Date>
32
+ <Date {...props}>{date}</Date>
33
33
  </Header>
34
34
  <Description {...props}>{text}</Description>
35
35
  {media && <Media>
@@ -73,7 +73,7 @@ const Header = styled.div`
73
73
 
74
74
  const Date = styled.p`
75
75
  font-size: 14px;
76
- color: gray;
76
+ color: ${props => props.dateColor || 'gray'};
77
77
  `
78
78
 
79
79
  const Media = styled.div`
@@ -24,7 +24,7 @@ export const globalContent = styled.div`
24
24
  display: flex;
25
25
  flex-direction: column;
26
26
  flex-grow: 1;
27
- gap: ${props => props.contentGap}px;
27
+ gap: ${props => props.contentGap || 10}px;
28
28
  `
29
29
 
30
30
  export const Title = styled.h3`
@@ -32,6 +32,7 @@ export const Title = styled.h3`
32
32
  color: ${props => props.cardTitleColor || 'black'};
33
33
  font-size: ${props => props.cardTitleFontSize}px;
34
34
  font-weight: ${props => props.cardTitleFontWeight || 300};
35
+ cursor: pointer;
35
36
  `
36
37
 
37
38
  export const Description = styled.h5`
@@ -0,0 +1,70 @@
1
+ import React from 'react'
2
+
3
+ import styled from 'styled-components'
4
+
5
+ // import Head from '../../Layout/Head/Head'
6
+ import Navbar from '../../Navbar/Navbar'
7
+ import Body from '../../Layout/Body/Body'
8
+ import Left from '../../Layout/Left/Left'
9
+ import Center from '../../Layout/Center/Center'
10
+ import Right from '../../Layout/Right/Right'
11
+ import WidgetContainer from "../../Reusable Components/WidgetContainer/WidgetContainer";
12
+ // import styles from '../../styling.json'
13
+
14
+
15
+
16
+ const Community = ({
17
+ context,
18
+ ...props
19
+ }) => {
20
+
21
+ const spaces = [
22
+ {
23
+ title: 'Main List',
24
+ data: [
25
+ { title: 'Cargo Sprint', path: 'cago' },
26
+ { title: 'Movies', path: 'movies' }
27
+ ],
28
+ },
29
+ {
30
+ title: 'Entertainment',
31
+ data: [
32
+ { title: 'Gaming', path: 'games' },
33
+ { title: 'Music', path: 'music' }
34
+ ]
35
+ }
36
+ ]
37
+
38
+ return (
39
+ <Container>
40
+ <Navbar />
41
+ <Body>
42
+ <Left>
43
+ <WidgetContainer
44
+ widgetType='spaces-list'
45
+ widgetProps={{
46
+ listTitle: 'Your Spaces',
47
+ spaces: spaces,
48
+ cardClicked: () => alert('clicked'),
49
+ // headerStyles: styles.widgetContainer.header,
50
+ // sectionHeaderStyles: styles.widgetContainer.body.sectionHeaderStyles,
51
+ // customCardStyles: styles.widgetContainer.body.customCardStyles,
52
+ }}
53
+ />
54
+ </Left>
55
+ <Center>{props.center}</Center>
56
+ <Right>{props.right}</Right>
57
+ </Body>
58
+ </Container>
59
+ );
60
+ };
61
+
62
+ const Container = styled.div`
63
+ width: 100%;
64
+ height: auto;
65
+ display: flex;
66
+ min-height: 100vh;
67
+ flex-direction: column;
68
+ `
69
+
70
+ export default Community;
@@ -11,15 +11,21 @@ const Gallery = ({ data, cardStyle, customCardStyles, type, cardControls = null,
11
11
  let child;
12
12
 
13
13
  const iconCliked = (action) => {
14
- props.iconClicked(action)
14
+ if (!props.preview) {
15
+ props.iconClicked(action)
16
+ }
15
17
  }
16
18
 
17
19
  const clicked = (index, cardProps) => {
20
+ if (!props.preview) {
18
21
  props.cardClicked(index, cardProps)
22
+ }
19
23
  }
20
24
 
21
25
  const cardIconClicked = (action, index) => {
26
+ if (!props.preview) {
22
27
  props.cardIconClicked(action, index)
28
+ }
23
29
  }
24
30
 
25
31
  const mapOverCardsData = (data) => {
@@ -69,8 +75,7 @@ const GalleryBody = styled.div`
69
75
  display: ${({ type }) => type === 'flat' ? 'grid' : 'flex'};
70
76
  flex-direction: column;
71
77
  grid-template-columns: ${props => 'repeat(' + props.columnsNumber + ', 1fr)'};
72
- grid-auto-rows: ${props => props.rowsHeight || 400}px;
73
- /* grid-auto-rows: ${props => props.rowsHeight + 'px' || 'minmax(min-content, 400px)'}; */
78
+ grid-auto-rows: ${props => props.rowsHeight ? `${props.rowsHeight}px` : '1fr'};
74
79
  column-gap: ${props => props.galleryColumnGap}px;
75
80
  row-gap: ${props => props.galleryRowGap}px;
76
81
  `
@@ -83,15 +88,15 @@ const Section = styled.div`
83
88
  row-gap: ${props => props.galleryRowGap}px;
84
89
  `
85
90
 
86
- const SectionBody = styled.div`
87
- padding: ${props => props.galleryBodyPadding}px;
91
+ const SectionBody = styled(GalleryBody)`
88
92
  display: grid;
89
- grid-template-columns: ${props => 'repeat(' + props.columnsNumber + ', 1fr)'};
90
- column-gap: ${props => props.galleryColumnGap}px;
91
- row-gap: ${props => props.galleryRowGap}px;
92
93
  `
93
94
 
94
- Gallery.defaultProps = {};
95
+ Gallery.defaultProps = {
96
+ columnsNumber: 3,
97
+ galleryColumnGap: 10,
98
+ galleryRowGap: 20
99
+ };
95
100
 
96
101
  Gallery.propTypes = {
97
102
  data: PropTypes.array.isRequired,
@@ -104,7 +109,7 @@ Gallery.propTypes = {
104
109
  galleryColumnGap: PropTypes.number,
105
110
  galleryRowGap: PropTypes.number,
106
111
  rowsHeight: PropTypes.number
107
-
112
+
108
113
  };
109
114
 
110
115
  export default Gallery