@mohamed-karawia/library 0.1.14 → 0.1.18

Sign up to get free protection for your applications and to get access to all the features.
Files changed (83) hide show
  1. package/dist/stories/Chat/Chat.js +11 -34
  2. package/dist/stories/Common Inputs/EditorComponent/EditorComponent.js +4 -2
  3. package/dist/stories/Enrollment/Admin/CreateForm/CreateForm.js +1 -1
  4. package/dist/stories/Enrollment/Admin/DetailedForm/DetailedForm.js +11 -23
  5. package/dist/stories/Enrollment/Admin/ViewForms/ViewForms.js +4 -19
  6. package/dist/stories/Enrollment/Guest/FillForm/FillForm.js +4 -17
  7. package/dist/stories/Events/Event/Event.js +1 -1
  8. package/dist/stories/Events/EventsList/EventsList.js +3 -3
  9. package/dist/stories/Library/Folders/Folders.js +2 -6
  10. package/dist/stories/Library/Notes/Notes.js +3 -3
  11. package/dist/stories/Library/ViewNote/ViewNote.js +7 -10
  12. package/dist/stories/Music Album/ViewAlbum/ViewAlbum.js +5 -14
  13. package/dist/stories/Music Album/ViewAlbums/ViewAlbums.js +6 -12
  14. package/dist/stories/Navbar/Navbar.js +14 -44
  15. package/dist/stories/Pages/Chat/Chat.js +13 -1
  16. package/dist/stories/Pages/Enrollment/DetailedForm/DetailedForm.js +19 -1
  17. package/dist/stories/Pages/Enrollment/FillForm/FillForm.js +7 -1
  18. package/dist/stories/Pages/Enrollment/Forms/Forms.js +29 -2
  19. package/dist/stories/Pages/Events/Events/Events.js +6 -0
  20. package/dist/stories/Pages/Library/Folders/Library.js +7 -1
  21. package/dist/stories/Pages/Library/Notes/Notes.js +5 -0
  22. package/dist/stories/Pages/Music/MusicAlbum/Music.js +12 -5
  23. package/dist/stories/Pages/Music/MusicAlbums/MusicAlbums.js +43 -1
  24. package/dist/stories/Pages/Photos/Album/Album.js +7 -1
  25. package/dist/stories/Pages/Photos/Albums/Albums.js +38 -2
  26. package/dist/stories/Photo Album/ViewAlbum/ViewAlbum.js +4 -18
  27. package/dist/stories/Photo Album/ViewAlbums/ViewAlbums.js +5 -51
  28. package/dist/stories/Preview/Preview.js +36 -0
  29. package/dist/stories/Reusable Components/Cards/Card-style-10/CardStyle10.js +7 -3
  30. package/dist/stories/Reusable Components/Cards/Card-style-11/CardStyle11.js +7 -1
  31. package/dist/stories/Reusable Components/Cards/Card-style-3/CardStyle3.js +3 -2
  32. package/dist/stories/Reusable Components/Cards/Card-style-9/CardStyle9.js +27 -12
  33. package/dist/stories/Reusable Components/Cards/globalCardStyles.js +1 -1
  34. package/dist/stories/Reusable Components/Gallery/Gallery.js +5 -1
  35. package/dist/stories/Reusable Components/ReusableForm/ReusableForm.js +1 -1
  36. package/dist/stories/Reusable Components/ReusableList/ReusableList.js +8 -6
  37. package/dist/stories/Sections/Sections.js +61 -0
  38. package/dist/stories/VideoAlbum/ViewAlbum/ViewAlbum.js +1 -4
  39. package/dist/stories/Widgets/MusicPlayerWidget/MusicPlayerWidget.js +1 -1
  40. package/dist/stories/helpers/util.js +39 -9
  41. package/package.json +1 -1
  42. package/src/stories/Chat/Chat.jsx +10 -35
  43. package/src/stories/Common Inputs/EditorComponent/EditorComponent.jsx +3 -3
  44. package/src/stories/Enrollment/Admin/CreateForm/CreateForm.jsx +1 -0
  45. package/src/stories/Enrollment/Admin/DetailedForm/DetailedForm.jsx +8 -19
  46. package/src/stories/Enrollment/Admin/ViewForms/ViewForms.jsx +4 -17
  47. package/src/stories/Enrollment/Guest/FillForm/FillForm.jsx +6 -16
  48. package/src/stories/Events/Event/Event.jsx +1 -1
  49. package/src/stories/Events/EventsList/EventsList.jsx +11 -6
  50. package/src/stories/Library/Folders/Folders.jsx +3 -7
  51. package/src/stories/Library/Notes/Notes.jsx +8 -4
  52. package/src/stories/Library/ViewNote/ViewNote.jsx +1 -12
  53. package/src/stories/Music Album/ViewAlbum/ViewAlbum.jsx +9 -11
  54. package/src/stories/Music Album/ViewAlbums/ViewAlbums.jsx +7 -11
  55. package/src/stories/Navbar/Navbar.jsx +50 -48
  56. package/src/stories/Pages/Chat/Chat.jsx +17 -4
  57. package/src/stories/Pages/Enrollment/DetailedForm/DetailedForm.jsx +20 -1
  58. package/src/stories/Pages/Enrollment/FillForm/FillForm.jsx +6 -0
  59. package/src/stories/Pages/Enrollment/Forms/Forms.jsx +30 -2
  60. package/src/stories/Pages/Events/Events/Events.jsx +78 -72
  61. package/src/stories/Pages/Library/Folders/Library.jsx +7 -1
  62. package/src/stories/Pages/Library/Notes/Notes.jsx +5 -0
  63. package/src/stories/Pages/Music/MusicAlbum/Music.jsx +16 -8
  64. package/src/stories/Pages/Music/MusicAlbums/MusicAlbums.jsx +38 -24
  65. package/src/stories/Pages/Photos/Album/Album.jsx +7 -1
  66. package/src/stories/Pages/Photos/Albums/Albums.jsx +25 -20
  67. package/src/stories/Pages/ViewWorld/styles.json +1 -1
  68. package/src/stories/Photo Album/ViewAlbum/ViewAlbum.jsx +6 -17
  69. package/src/stories/Photo Album/ViewAlbums/ViewAlbums.jsx +6 -60
  70. package/src/stories/Preview/Preview.jsx +27 -0
  71. package/src/stories/Reusable Components/Cards/Card-style-10/CardStyle10.jsx +8 -4
  72. package/src/stories/Reusable Components/Cards/Card-style-11/CardStyle11.jsx +5 -0
  73. package/src/stories/Reusable Components/Cards/Card-style-3/CardStyle3.jsx +5 -2
  74. package/src/stories/Reusable Components/Cards/Card-style-9/CardStyle9.jsx +14 -8
  75. package/src/stories/Reusable Components/Cards/globalCardStyles.js +1 -1
  76. package/src/stories/Reusable Components/Gallery/Gallery.jsx +5 -1
  77. package/src/stories/Reusable Components/ReusableForm/ReusableForm.jsx +1 -1
  78. package/src/stories/Reusable Components/ReusableHeader/ReusableHeader.jsx +0 -2
  79. package/src/stories/Reusable Components/ReusableList/ReusableList.jsx +17 -6
  80. package/src/stories/Sections/Sections.jsx +53 -0
  81. package/src/stories/VideoAlbum/ViewAlbum/ViewAlbum.jsx +3 -5
  82. package/src/stories/Widgets/MusicPlayerWidget/MusicPlayerWidget.jsx +1 -1
  83. package/src/stories/helpers/util.js +29 -7
@@ -83,6 +83,14 @@ var Forms = function Forms(props) {
83
83
  forms = _useState2[0],
84
84
  setForms = _useState2[1];
85
85
 
86
+ var cardClicked = function cardClicked(index, cardProps) {
87
+ console.log(cardProps);
88
+ };
89
+
90
+ var onAction = function onAction(action, index) {
91
+ console.log(action);
92
+ };
93
+
86
94
  return /*#__PURE__*/_react.default.createElement(_BaseMaterial.default, Object.assign({}, _styles.default.containerStyle, props), /*#__PURE__*/_react.default.createElement(_Navbar.default, null), /*#__PURE__*/_react.default.createElement(_Body.default, _styles.default.bodyStyle, /*#__PURE__*/_react.default.createElement(_Left.default, null, /*#__PURE__*/_react.default.createElement(_WidgetContainer.default, {
87
95
  widgetType: "logo",
88
96
  widgetProps: {
@@ -113,11 +121,30 @@ var Forms = function Forms(props) {
113
121
  }
114
122
  }
115
123
  })), /*#__PURE__*/_react.default.createElement(_Center.default, null, /*#__PURE__*/_react.default.createElement(_SpaceContainer.default, {
116
- title: "Music Album",
117
124
  discription: "Lorem ipsum dolor sit amet consectetur.",
118
125
  hideTitle: true
119
126
  }, /*#__PURE__*/_react.default.createElement(_ViewForms.default, {
120
- data: forms
127
+ data: forms,
128
+ cardClicked: cardClicked,
129
+ cardIconClicked: onAction,
130
+ headerStyles: {
131
+ padding: 10,
132
+ headerBackground: '#FE1744',
133
+ titleColor: '#ffff',
134
+ controlsStyles: {
135
+ dropdownBackground: 'black',
136
+ dropdownFontColor: 'white',
137
+ dropdownItemHoverColor: '#FE1744'
138
+ }
139
+ },
140
+ sectionHeaderStyles: {
141
+ cardTitleColor: 'white',
142
+ cardBackgroundColor: 'black',
143
+ cardPadding: 10
144
+ },
145
+ customCardStyles: {
146
+ cardBackgroundColor: 'white'
147
+ }
121
148
  }))), /*#__PURE__*/_react.default.createElement(_Right.default, null)));
122
149
  };
123
150
 
@@ -79,6 +79,10 @@ var Events = function Events(props) {
79
79
  setEvents((0, _util.deleteFromArrayByIndex)(events, index));
80
80
  };
81
81
 
82
+ var cardClicked = function cardClicked(index, cardProps) {
83
+ console.log(cardProps);
84
+ };
85
+
82
86
  return /*#__PURE__*/_react.default.createElement(_BaseMaterial.default, Object.assign({}, _styles.default.containerStyle, props), /*#__PURE__*/_react.default.createElement(_Navbar.default, null), /*#__PURE__*/_react.default.createElement(_Body.default, _styles.default.bodyStyle, /*#__PURE__*/_react.default.createElement(_Left.default, null, /*#__PURE__*/_react.default.createElement(_WidgetContainer.default, {
83
87
  widgetType: "logo",
84
88
  widgetProps: {
@@ -118,6 +122,7 @@ var Events = function Events(props) {
118
122
  cardTitleFontSize: 15,
119
123
  onAddEvent: onAddEvent,
120
124
  cardIconClicked: cardIconClicked,
125
+ cardClicked: cardClicked,
121
126
  headerStyles: {
122
127
  padding: 10,
123
128
  headerBackground: '#FE1744',
@@ -127,6 +132,7 @@ var Events = function Events(props) {
127
132
  }
128
133
  },
129
134
  customCardStyles: {
135
+ cardBackgroundColor: 'white',
130
136
  controlsStyles: {
131
137
  iconColor: '#FE1744'
132
138
  }
@@ -82,6 +82,10 @@ var Library = function Library(props) {
82
82
  setFolders((0, _util.deleteFromArrayByIndex)(folders, index));
83
83
  };
84
84
 
85
+ var cardClicked = function cardClicked(index, cardProps) {
86
+ console.log(cardProps);
87
+ };
88
+
85
89
  return /*#__PURE__*/_react.default.createElement(_BaseMaterial.default, Object.assign({}, _styles.default.containerStyle, props), /*#__PURE__*/_react.default.createElement(_Navbar.default, null), /*#__PURE__*/_react.default.createElement(_Body.default, _styles.default.bodyStyle, /*#__PURE__*/_react.default.createElement(_Left.default, null, /*#__PURE__*/_react.default.createElement(_WidgetContainer.default, {
86
90
  widgetType: "logo",
87
91
  widgetProps: {
@@ -109,7 +113,8 @@ var Library = function Library(props) {
109
113
  controlsStyles: {
110
114
  showOnHover: true
111
115
  }
112
- }
116
+ },
117
+ cardClicked: cardClicked
113
118
  }
114
119
  })), /*#__PURE__*/_react.default.createElement(_Center.default, null, /*#__PURE__*/_react.default.createElement(_SpaceContainer.default, {
115
120
  title: "Music Album",
@@ -121,6 +126,7 @@ var Library = function Library(props) {
121
126
  columnsNumber: 3,
122
127
  onAddFolder: onAddFolder,
123
128
  cardIconClicked: cardIconClicked,
129
+ cardClicked: cardClicked,
124
130
  headerStyles: {
125
131
  padding: 10,
126
132
  headerBackground: '#ff2d2d',
@@ -79,6 +79,10 @@ var Notes = function Notes(props) {
79
79
  setNotes((0, _util.deleteFromArrayByIndex)(notes, index));
80
80
  };
81
81
 
82
+ var cardClicked = function cardClicked(index, cardProps) {
83
+ console.log(cardProps);
84
+ };
85
+
82
86
  return /*#__PURE__*/_react.default.createElement(_BaseMaterial.default, Object.assign({}, _styles.default.containerStyle, props), /*#__PURE__*/_react.default.createElement(_Navbar.default, null), /*#__PURE__*/_react.default.createElement(_Body.default, _styles.default.bodyStyle, /*#__PURE__*/_react.default.createElement(_Left.default, null, /*#__PURE__*/_react.default.createElement(_WidgetContainer.default, {
83
87
  widgetType: "logo",
84
88
  widgetProps: {
@@ -116,6 +120,7 @@ var Notes = function Notes(props) {
116
120
  onAddNote: onAddNote,
117
121
  cardIconClicked: cardIconClicked,
118
122
  notes: notes,
123
+ cardClicked: cardClicked,
119
124
  headerStyles: {
120
125
  padding: 10,
121
126
  headerBackground: '#FE1744',
@@ -60,7 +60,7 @@ var Music = function Music(props) {
60
60
  var _useState3 = (0, _react.useState)([{
61
61
  index: 0,
62
62
  cover: _music4.default,
63
- musicSrc: 'https://www.pacdv.com/sounds/free-music/kickstarter.mp3',
63
+ musicSrc: 'https://www.pacdv.com/sounds/free-music/gentle-thoughts-1.mp3',
64
64
  title: 'Plans We Made',
65
65
  description: 'Son Lux',
66
66
  time: '5:20'
@@ -74,7 +74,7 @@ var Music = function Music(props) {
74
74
  }, {
75
75
  index: 1,
76
76
  cover: _music5.default,
77
- musicSrc: 'https://www.pacdv.com/sounds/free-music/kickstarter.mp3',
77
+ musicSrc: 'https://www.pacdv.com/sounds/free-music/glow-in-the-dark.mp3',
78
78
  title: 'Night',
79
79
  description: 'Frank Ocean',
80
80
  time: '5:20'
@@ -88,14 +88,14 @@ var Music = function Music(props) {
88
88
  }, {
89
89
  index: 4,
90
90
  cover: _music3.default,
91
- musicSrc: 'https://www.pacdv.com/sounds/free-music/kickstarter.mp3',
91
+ musicSrc: 'https://www.pacdv.com/sounds/free-music/gentle-thoughts-1.mp3',
92
92
  title: 'Enter Sandman',
93
93
  description: 'Metallica',
94
94
  time: '5:20'
95
95
  }, {
96
96
  index: 5,
97
97
  cover: _music2.default,
98
- musicSrc: 'https://www.pacdv.com/sounds/free-music/kickstarter.mp3',
98
+ musicSrc: 'https://www.pacdv.com/sounds/free-music/glow-in-the-dark.mp3',
99
99
  title: 'November Rain',
100
100
  description: "Guns N' Roses",
101
101
  time: '5:20'
@@ -191,6 +191,12 @@ var Music = function Music(props) {
191
191
  controlsStyles: {
192
192
  iconSize: 25
193
193
  }
194
+ },
195
+ customCardStyles: {
196
+ cardBackgroundColor: 'white',
197
+ controlsStyles: {
198
+ iconColor: 'black'
199
+ }
194
200
  }
195
201
  }))), /*#__PURE__*/_react.default.createElement(_Right.default, null, /*#__PURE__*/_react.default.createElement(_WidgetContainer.default, {
196
202
  widgetType: "music player",
@@ -205,7 +211,8 @@ var Music = function Music(props) {
205
211
  prevSong: prevSong,
206
212
  currentSong: currentSong,
207
213
  borderRadius: '10',
208
- primaryColor: 'black'
214
+ primaryColor: 'black',
215
+ backgroundColor: 'white'
209
216
  },
210
217
  headerStyles: {
211
218
  controlsStyles: {
@@ -115,6 +115,22 @@ var MusicAlbums = function MusicAlbums(props) {
115
115
  console.log(cardProps);
116
116
  };
117
117
 
118
+ var notes = [{
119
+ title: 'Study notes',
120
+ date: '15/11/2020'
121
+ }, {
122
+ title: 'Music notes',
123
+ date: '14/12/2020'
124
+ }, {
125
+ title: 'Workout notes',
126
+ date: '5/8/2021'
127
+ }, {
128
+ title: 'Gaming notes',
129
+ date: '14/4/2023'
130
+ }, {
131
+ title: 'Working notes',
132
+ date: '5/6/2021'
133
+ }];
118
134
  return /*#__PURE__*/_react.default.createElement(_BaseMaterial.default, Object.assign({}, _styles.default.containerStyle, props), /*#__PURE__*/_react.default.createElement(_Navbar.default, null), /*#__PURE__*/_react.default.createElement(_Body.default, _styles.default.bodyStyle, /*#__PURE__*/_react.default.createElement(_Left.default, null, /*#__PURE__*/_react.default.createElement(_WidgetContainer.default, {
119
135
  widgetType: "logo",
120
136
  widgetProps: {
@@ -161,8 +177,34 @@ var MusicAlbums = function MusicAlbums(props) {
161
177
  iconSize: 25
162
178
  }
163
179
  },
180
+ customCardStyles: {
181
+ darkOnHover: true,
182
+ controlsStyles: {
183
+ showOnHover: true,
184
+ position: 'center',
185
+ dropdownFontColor: "white",
186
+ iconBorderRadius: 100,
187
+ iconSize: 40,
188
+ iconsGap: 10,
189
+ iconColor: 'white',
190
+ containerPadding: 20
191
+ }
192
+ },
164
193
  cardClicked: cardClicked
165
- }))), /*#__PURE__*/_react.default.createElement(_Right.default, null)));
194
+ }))), /*#__PURE__*/_react.default.createElement(_Right.default, null, /*#__PURE__*/_react.default.createElement(_WidgetContainer.default, {
195
+ widgetType: "notes",
196
+ widgetProps: {
197
+ notes: notes,
198
+ headerStyles: {
199
+ padding: 10,
200
+ headerBackground: 'black',
201
+ titleColor: '#ffff',
202
+ controlsStyles: {
203
+ iconSize: 25
204
+ }
205
+ }
206
+ }
207
+ }))));
166
208
  };
167
209
 
168
210
  var _default = MusicAlbums;
@@ -156,7 +156,13 @@ var Album = function Album(props) {
156
156
  addPhoto: onAddPhoto,
157
157
  deletePhoto: onDeletePhoto,
158
158
  cardIconClicked: cardIconClicked,
159
- columnsNumber: 2
159
+ columnsNumber: 2,
160
+ headerStyles: {
161
+ padding: 10,
162
+ controlsStyles: {
163
+ iconSize: 25
164
+ }
165
+ }
160
166
  }))), /*#__PURE__*/_react.default.createElement(_Right.default, null)));
161
167
  };
162
168
 
@@ -81,6 +81,26 @@ var Albums = function Albums(props) {
81
81
  albums = _useState2[0],
82
82
  setAlbums = _useState2[1];
83
83
 
84
+ var folders = [{
85
+ title: 'Folder one',
86
+ description: 'Discription for folder one'
87
+ }, {
88
+ title: 'Folder two',
89
+ description: 'Discription for folder two'
90
+ }, {
91
+ title: 'Folder three',
92
+ description: 'Discription for folder three'
93
+ }, {
94
+ title: 'Folder four',
95
+ description: 'Discription for folder four'
96
+ }, {
97
+ title: 'Folder five',
98
+ description: 'Discription for folder five'
99
+ }, {
100
+ title: 'Folder six',
101
+ description: 'Discription for folder six'
102
+ }];
103
+
84
104
  var cardIconClicked = function cardIconClicked(action, index) {
85
105
  switch (action) {
86
106
  case 'delete':
@@ -148,8 +168,24 @@ var Albums = function Albums(props) {
148
168
  onDeleteAlbum: onDeleteAlbum,
149
169
  onAddAlbum: onAddAlbum,
150
170
  columnsNumber: 2,
151
- cardClicked: cardClicked
152
- }))), /*#__PURE__*/_react.default.createElement(_Right.default, null)));
171
+ cardClicked: cardClicked,
172
+ customCardStyles: {
173
+ cardBackgroundColor: 'white'
174
+ }
175
+ }))), /*#__PURE__*/_react.default.createElement(_Right.default, null, /*#__PURE__*/_react.default.createElement(_WidgetContainer.default, {
176
+ widgetType: "folders",
177
+ widgetProps: {
178
+ folders: folders,
179
+ columnsNumber: 3,
180
+ customCardStyles: {
181
+ cardPadding: 10,
182
+ iconColor: '#ff2d2d',
183
+ controlsStyles: {
184
+ iconColor: '#FE1744'
185
+ }
186
+ }
187
+ }
188
+ }))));
153
189
  };
154
190
 
155
191
  var _default = Albums;
@@ -29,7 +29,7 @@ var _ai = require("react-icons/ai");
29
29
 
30
30
  var _templateObject, _templateObject2, _templateObject3, _templateObject4, _templateObject5;
31
31
 
32
- var _excluded = ["album", "cardBackgroundColor", "imgTitleColor", "columnsNumber", "columnGap", "rowGap", "descColor"];
32
+ var _excluded = ["album", "cardBackgroundColor", "imgTitleColor", "descColor"];
33
33
 
34
34
  function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
35
35
 
@@ -50,9 +50,6 @@ var ViewAlbum = function ViewAlbum(_ref) {
50
50
  var album = _ref.album,
51
51
  cardBackgroundColor = _ref.cardBackgroundColor,
52
52
  imgTitleColor = _ref.imgTitleColor,
53
- columnsNumber = _ref.columnsNumber,
54
- columnGap = _ref.columnGap,
55
- rowGap = _ref.rowGap,
56
53
  descColor = _ref.descColor,
57
54
  props = (0, _objectWithoutProperties2.default)(_ref, _excluded);
58
55
  var cardStyles = {
@@ -157,21 +154,10 @@ var ViewAlbum = function ViewAlbum(_ref) {
157
154
  };
158
155
 
159
156
  return /*#__PURE__*/_react.default.createElement(Container, null, /*#__PURE__*/_react.default.createElement(_Gallery.default, Object.assign({
160
- galleryTitle: "Photo Album",
157
+ galleryTitle: props.title || "Photo Album",
161
158
  data: album,
162
159
  type: "flat",
163
160
  cardStyle: "card-style-6",
164
- headerStyles: {
165
- padding: 10,
166
- headerBackground: props.headerBackground,
167
- titleColor: props.titleColor,
168
- controlsStyles: {
169
- iconSize: 25
170
- }
171
- },
172
- columnsNumber: columnsNumber,
173
- galleryColumnGap: columnGap,
174
- galleryRowGap: rowGap,
175
161
  galleryControls: galleryControls,
176
162
  iconClicked: onIconClicked,
177
163
  cardClicked: cardClicked,
@@ -189,8 +175,8 @@ var ViewAlbum = function ViewAlbum(_ref) {
189
175
  }, /*#__PURE__*/_react.default.createElement(_AddPhoto.default, {
190
176
  saveHandler: onAddPhoto,
191
177
  cancelHandler: cancelHandler,
192
- saveBtnText: 'Add',
193
- cancelBtnText: 'Cancel'
178
+ saveBtnText: props.saveBtnText || 'Add',
179
+ cancelBtnText: props.saveBtnText || 'Cancel'
194
180
  })), /*#__PURE__*/_react.default.createElement(_ReactModal.default, {
195
181
  modalIsOpen: showImgModal,
196
182
  closeModal: function closeModal() {
@@ -27,7 +27,7 @@ var _ai = require("react-icons/ai");
27
27
 
28
28
  var _templateObject;
29
29
 
30
- var _excluded = ["albums", "cardBackgroundColor", "cardTitleColor", "cardTitleFontSize", "albumTitleColor", "countColor", "countFontSize", "columnsNumber", "columnGap", "rowGap"];
30
+ var _excluded = ["albums"];
31
31
 
32
32
  function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
33
33
 
@@ -46,34 +46,7 @@ var galleryControls = [{
46
46
 
47
47
  var ViewAlbums = function ViewAlbums(_ref) {
48
48
  var albums = _ref.albums,
49
- cardBackgroundColor = _ref.cardBackgroundColor,
50
- cardTitleColor = _ref.cardTitleColor,
51
- cardTitleFontSize = _ref.cardTitleFontSize,
52
- albumTitleColor = _ref.albumTitleColor,
53
- countColor = _ref.countColor,
54
- countFontSize = _ref.countFontSize,
55
- columnsNumber = _ref.columnsNumber,
56
- columnGap = _ref.columnGap,
57
- rowGap = _ref.rowGap,
58
49
  props = (0, _objectWithoutProperties2.default)(_ref, _excluded);
59
- var cardStyles = {
60
- darkOnHover: true,
61
- cardBackgroundColor: cardBackgroundColor,
62
- cardTitleColor: cardTitleColor,
63
- cardTitleFontSize: cardTitleFontSize,
64
- countColor: countColor,
65
- countFontSize: countFontSize,
66
- controlsStyles: {
67
- showOnHover: true,
68
- position: 'center',
69
- dropdownFontColor: "white",
70
- iconBorderRadius: 100,
71
- iconSize: 40,
72
- iconsGap: 10,
73
- iconColor: 'white',
74
- containerPadding: 20
75
- }
76
- };
77
50
 
78
51
  var _useState = (0, _react.useState)(false),
79
52
  _useState2 = (0, _slicedToArray2.default)(_useState, 2),
@@ -105,26 +78,14 @@ var ViewAlbums = function ViewAlbums(_ref) {
105
78
  };
106
79
 
107
80
  return /*#__PURE__*/_react.default.createElement(Container, null, /*#__PURE__*/_react.default.createElement(_Gallery.default, Object.assign({
108
- galleryTitle: "Photo Albums",
81
+ galleryTitle: props.title || "Photo Albums",
109
82
  data: albums,
110
83
  type: "flat",
111
84
  cardStyle: "card-style-6",
112
- headerStyles: {
113
- padding: 10,
114
- headerBackground: props.headerBackground,
115
- titleColor: props.titleColor,
116
- controlsStyles: {
117
- iconSize: 25
118
- }
119
- },
120
- columnsNumber: columnsNumber,
121
- galleryColumnGap: columnGap,
122
- galleryRowGap: rowGap,
123
85
  galleryControls: galleryControls,
124
86
  iconClicked: onIconClicked,
125
87
  cardControls: cardControls,
126
- cardIconClicked: cardIconClicked,
127
- customCardStyles: cardStyles
88
+ cardIconClicked: cardIconClicked
128
89
  }, props)), /*#__PURE__*/_react.default.createElement(_ReactModal.default, {
129
90
  modalIsOpen: showModal,
130
91
  closeModal: function closeModal() {
@@ -139,15 +100,8 @@ var ViewAlbums = function ViewAlbums(_ref) {
139
100
  })));
140
101
  };
141
102
 
142
- var Container = _styledComponents.default.div(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2.default)(["\n\n"])));
103
+ var Container = _styledComponents.default.div(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2.default)(["\n width: 100%;\n"])));
143
104
 
144
- ViewAlbums.defaultProps = {
145
- columnsNumber: 3,
146
- headerBackground: '#FE1744',
147
- titleColor: 'white',
148
- cardBackgroundColor: 'white',
149
- columnGap: 10,
150
- rowGap: 20
151
- };
105
+ ViewAlbums.defaultProps = {};
152
106
  var _default = ViewAlbums;
153
107
  exports.default = _default;
@@ -0,0 +1,36 @@
1
+ "use strict";
2
+
3
+ var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
4
+
5
+ Object.defineProperty(exports, "__esModule", {
6
+ value: true
7
+ });
8
+ exports.default = void 0;
9
+
10
+ var _taggedTemplateLiteral2 = _interopRequireDefault(require("@babel/runtime/helpers/esm/taggedTemplateLiteral"));
11
+
12
+ var _objectWithoutProperties2 = _interopRequireDefault(require("@babel/runtime/helpers/esm/objectWithoutProperties"));
13
+
14
+ var _react = _interopRequireDefault(require("react"));
15
+
16
+ var _styledComponents = _interopRequireDefault(require("styled-components"));
17
+
18
+ var _util = require("../helpers/util");
19
+
20
+ var _templateObject;
21
+
22
+ var _excluded = ["type", "componentProps", "stylingProps"];
23
+
24
+ var Preview = function Preview(_ref) {
25
+ var type = _ref.type,
26
+ componentProps = _ref.componentProps,
27
+ stylingProps = _ref.stylingProps,
28
+ props = (0, _objectWithoutProperties2.default)(_ref, _excluded);
29
+ var child = (0, _util.getComponentType)(type, componentProps, stylingProps);
30
+ return /*#__PURE__*/_react.default.createElement(Container, null, child);
31
+ };
32
+
33
+ var Container = _styledComponents.default.div(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2.default)(["\n width: 100%;\n"])));
34
+
35
+ var _default = Preview;
36
+ exports.default = _default;
@@ -47,14 +47,19 @@ var CardStyle10 = function CardStyle10(_ref) {
47
47
  props.iconClicked(action, props.index);
48
48
  };
49
49
 
50
+ var cardClicked = function cardClicked() {
51
+ props.cardClicked();
52
+ };
53
+
50
54
  return /*#__PURE__*/_react.default.createElement(Card, Object.assign({
55
+ onClick: cardClicked,
51
56
  onMouseEnter: function onMouseEnter(e) {
52
57
  return setShowIcons(true);
53
58
  },
54
59
  onMouseLeave: function onMouseLeave(e) {
55
60
  return setShowIcons(false);
56
61
  }
57
- }, props), /*#__PURE__*/_react.default.createElement(SvgWrapper, props, /*#__PURE__*/_react.default.createElement(_ai.AiFillFolderOpen, null)), /*#__PURE__*/_react.default.createElement(Content, props, /*#__PURE__*/_react.default.createElement(_globalCardStyles.Title, props, title), /*#__PURE__*/_react.default.createElement(_globalCardStyles.Description, props, description)), /*#__PURE__*/_react.default.createElement(_Controls.default, Object.assign({
62
+ }, props), /*#__PURE__*/_react.default.createElement(SvgWrapper, props, /*#__PURE__*/_react.default.createElement(_ai.AiFillFolderOpen, props)), /*#__PURE__*/_react.default.createElement(Content, props, /*#__PURE__*/_react.default.createElement(_globalCardStyles.Title, props, title), /*#__PURE__*/_react.default.createElement(_globalCardStyles.Description, props, description)), /*#__PURE__*/_react.default.createElement(_Controls.default, Object.assign({
58
63
  controls: cardControls,
59
64
  show: showIcons,
60
65
  onIconClicked: iconCliked,
@@ -64,7 +69,6 @@ var CardStyle10 = function CardStyle10(_ref) {
64
69
  iconSize: 20,
65
70
  iconsGap: 10,
66
71
  maxIcons: 0,
67
- iconColor: "#FE1744",
68
72
  dropdownFontSize: 10
69
73
  }, props.controlsStyles)));
70
74
  };
@@ -72,7 +76,7 @@ var CardStyle10 = function CardStyle10(_ref) {
72
76
  var Card = (0, _styledComponents.default)(_globalCardStyles.MainCard)(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2.default)(["\n flex-direction: column;\n row-gap: 10px;\n"])));
73
77
  var Content = (0, _styledComponents.default)(_globalCardStyles.globalContent)(_templateObject2 || (_templateObject2 = (0, _taggedTemplateLiteral2.default)(["\n align-items: center;\n justify-content: space-between;\n\n"])));
74
78
 
75
- var SvgWrapper = _styledComponents.default.div(_templateObject3 || (_templateObject3 = (0, _taggedTemplateLiteral2.default)(["\n\n svg{\n width: 70px;\n height: 70px;\n fill: ", "\n }\n"])), function (props) {
79
+ var SvgWrapper = _styledComponents.default.div(_templateObject3 || (_templateObject3 = (0, _taggedTemplateLiteral2.default)(["\n\n & svg{\n width: 70px;\n height: 70px;\n fill: ", "\n }\n"])), function (props) {
76
80
  return props.iconColor;
77
81
  });
78
82
 
@@ -45,7 +45,13 @@ var CardStyle11 = function CardStyle11(_ref) {
45
45
  props.iconClicked(action, props.index);
46
46
  };
47
47
 
48
- return /*#__PURE__*/_react.default.createElement(Card, props, /*#__PURE__*/_react.default.createElement(SvgWrapper, props, /*#__PURE__*/_react.default.createElement(_bi.BiNotepad, null)), /*#__PURE__*/_react.default.createElement(Content, props, /*#__PURE__*/_react.default.createElement(_globalCardStyles.Title, props, title), /*#__PURE__*/_react.default.createElement(Date, props, date)), props.cardControls && /*#__PURE__*/_react.default.createElement(_Controls.default, Object.assign({
48
+ var cardClicked = function cardClicked() {
49
+ props.cardClicked();
50
+ };
51
+
52
+ return /*#__PURE__*/_react.default.createElement(Card, Object.assign({
53
+ onClick: cardClicked
54
+ }, props), /*#__PURE__*/_react.default.createElement(SvgWrapper, props, /*#__PURE__*/_react.default.createElement(_bi.BiNotepad, null)), /*#__PURE__*/_react.default.createElement(Content, props, /*#__PURE__*/_react.default.createElement(_globalCardStyles.Title, props, title), /*#__PURE__*/_react.default.createElement(Date, props, date)), props.cardControls && /*#__PURE__*/_react.default.createElement(_Controls.default, Object.assign({
49
55
  controls: props.cardControls,
50
56
  show: showIcons,
51
57
  onIconClicked: iconClicked
@@ -21,7 +21,7 @@ var _Controls = _interopRequireDefault(require("../../Controls/Controls"));
21
21
 
22
22
  var _globalCardStyles = require("../globalCardStyles");
23
23
 
24
- var _templateObject;
24
+ var _templateObject, _templateObject2;
25
25
 
26
26
  var _excluded = ["title", "description", "path"];
27
27
 
@@ -48,7 +48,7 @@ var CardStyle3 = function CardStyle3(_ref) {
48
48
  props.cardClicked(path);
49
49
  };
50
50
 
51
- return /*#__PURE__*/_react.default.createElement(_globalCardStyles.MainCard, Object.assign({
51
+ return /*#__PURE__*/_react.default.createElement(Card, Object.assign({
52
52
  onClick: cardClicked,
53
53
  onMouseEnter: function onMouseEnter(e) {
54
54
  return setShowIcons(true);
@@ -66,6 +66,7 @@ var CardStyle3 = function CardStyle3(_ref) {
66
66
  var Content = (0, _styledComponents.default)(_globalCardStyles.globalContent)(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2.default)(["\n row-gap: ", "px;\n"])), function (props) {
67
67
  return props.rowGap;
68
68
  });
69
+ var Card = (0, _styledComponents.default)(_globalCardStyles.MainCard)(_templateObject2 || (_templateObject2 = (0, _taggedTemplateLiteral2.default)(["\n cursor: pointer;\n"])));
69
70
  CardStyle3.defaultProps = {};
70
71
  var _default = CardStyle3;
71
72
  exports.default = _default;
@@ -17,7 +17,7 @@ var _styledComponents = _interopRequireDefault(require("styled-components"));
17
17
 
18
18
  var _globalCardStyles = require("../globalCardStyles");
19
19
 
20
- var _templateObject, _templateObject2, _templateObject3, _templateObject4, _templateObject5, _templateObject6, _templateObject7, _templateObject8, _templateObject9;
20
+ var _templateObject, _templateObject2, _templateObject3, _templateObject4, _templateObject5, _templateObject6, _templateObject7, _templateObject8, _templateObject9, _templateObject10;
21
21
 
22
22
  var _excluded = ["username", "answered", "img", "status"];
23
23
 
@@ -33,15 +33,29 @@ var CardStyle9 = function CardStyle9(_ref) {
33
33
  props = (0, _objectWithoutProperties2.default)(_ref, _excluded);
34
34
  console.log(props);
35
35
 
36
- var onAccept = function onAccept() {
37
- alert(props.index);
36
+ var onAction = function onAction(action) {
37
+ props.iconClicked(action);
38
38
  };
39
39
 
40
40
  return /*#__PURE__*/_react.default.createElement(Card, props, /*#__PURE__*/_react.default.createElement(ImgWrapper, props, /*#__PURE__*/_react.default.createElement(_globalCardStyles.Img, {
41
41
  src: img
42
- })), /*#__PURE__*/_react.default.createElement(Content, props, /*#__PURE__*/_react.default.createElement(_globalCardStyles.Title, props, username), /*#__PURE__*/_react.default.createElement(Answered, null, "Questions Answered: ", answered), /*#__PURE__*/_react.default.createElement(Buttons, null, /*#__PURE__*/_react.default.createElement(Accept, {
43
- onClick: onAccept
44
- }, "Accept"), /*#__PURE__*/_react.default.createElement(Decline, null, "Decline"), status === 'pending' && /*#__PURE__*/_react.default.createElement(Review, null, "In Review"))));
42
+ })), /*#__PURE__*/_react.default.createElement(Content, props, /*#__PURE__*/_react.default.createElement(Title, Object.assign({
43
+ onClick: function onClick() {
44
+ return props.cardClicked();
45
+ }
46
+ }, props), username), /*#__PURE__*/_react.default.createElement(Answered, null, "Questions Answered: ", answered), /*#__PURE__*/_react.default.createElement(Buttons, null, /*#__PURE__*/_react.default.createElement(Accept, {
47
+ onClick: function onClick() {
48
+ return onAction('accept');
49
+ }
50
+ }, "Accept"), /*#__PURE__*/_react.default.createElement(Decline, {
51
+ onClick: function onClick() {
52
+ return onAction('decline');
53
+ }
54
+ }, "Decline"), status === 'pending' && /*#__PURE__*/_react.default.createElement(Review, {
55
+ onClick: function onClick() {
56
+ return onAction('review');
57
+ }
58
+ }, "In Review"))));
45
59
  };
46
60
 
47
61
  var Card = (0, _styledComponents.default)(_globalCardStyles.MainCard)(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2.default)(["\n align-items: center;\n gap: 20px;\n padding: 10px;\n"])));
@@ -53,15 +67,16 @@ var ImgWrapper = _styledComponents.default.div(_templateObject2 || (_templateObj
53
67
  });
54
68
 
55
69
  var Content = (0, _styledComponents.default)(_globalCardStyles.globalContent)(_templateObject3 || (_templateObject3 = (0, _taggedTemplateLiteral2.default)(["\n height: 100%;\n flex-direction: row;\n align-items: center;\n justify-content: space-between;\n"])));
70
+ var Title = (0, _styledComponents.default)(_globalCardStyles.Title)(_templateObject4 || (_templateObject4 = (0, _taggedTemplateLiteral2.default)(["\n cursor: pointer;\n"])));
56
71
 
57
- var Answered = _styledComponents.default.h5(_templateObject4 || (_templateObject4 = (0, _taggedTemplateLiteral2.default)(["\n font-weight: 300;\n"])));
72
+ var Answered = _styledComponents.default.h5(_templateObject5 || (_templateObject5 = (0, _taggedTemplateLiteral2.default)(["\n font-weight: 300;\n"])));
58
73
 
59
- var Buttons = _styledComponents.default.div(_templateObject5 || (_templateObject5 = (0, _taggedTemplateLiteral2.default)(["\n display: flex;\n gap: 10px;\n"])));
74
+ var Buttons = _styledComponents.default.div(_templateObject6 || (_templateObject6 = (0, _taggedTemplateLiteral2.default)(["\n display: flex;\n gap: 10px;\n"])));
60
75
 
61
- var Button = _styledComponents.default.button(_templateObject6 || (_templateObject6 = (0, _taggedTemplateLiteral2.default)(["\n padding: 7px 20px;\n border: none;\n color: white;\n cursor: pointer;\n"])));
76
+ var Button = _styledComponents.default.button(_templateObject7 || (_templateObject7 = (0, _taggedTemplateLiteral2.default)(["\n padding: 7px 20px;\n border: none;\n color: white;\n cursor: pointer;\n"])));
62
77
 
63
- var Accept = (0, _styledComponents.default)(Button)(_templateObject7 || (_templateObject7 = (0, _taggedTemplateLiteral2.default)(["\n background-color: #69d869;\n"])));
64
- var Decline = (0, _styledComponents.default)(Button)(_templateObject8 || (_templateObject8 = (0, _taggedTemplateLiteral2.default)(["\n background-color: #e24848;\n"])));
65
- var Review = (0, _styledComponents.default)(Button)(_templateObject9 || (_templateObject9 = (0, _taggedTemplateLiteral2.default)(["\n background-color: #18b8e9;\n"])));
78
+ var Accept = (0, _styledComponents.default)(Button)(_templateObject8 || (_templateObject8 = (0, _taggedTemplateLiteral2.default)(["\n background-color: #69d869;\n"])));
79
+ var Decline = (0, _styledComponents.default)(Button)(_templateObject9 || (_templateObject9 = (0, _taggedTemplateLiteral2.default)(["\n background-color: #e24848;\n"])));
80
+ var Review = (0, _styledComponents.default)(Button)(_templateObject10 || (_templateObject10 = (0, _taggedTemplateLiteral2.default)(["\n background-color: #18b8e9;\n"])));
66
81
  var _default = CardStyle9;
67
82
  exports.default = _default;
@@ -14,7 +14,7 @@ var _styledComponents = _interopRequireDefault(require("styled-components"));
14
14
  var _templateObject, _templateObject2, _templateObject3, _templateObject4, _templateObject5, _templateObject6;
15
15
 
16
16
  var MainCard = _styledComponents.default.div(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2.default)(["\n* {\n margin: 0;\n padding: 0;\n }\n font-family: sans-serif;\n display: flex;\n background-color: ", ";\n border-radius: ", "px;\n border: ", ";\n align-items: center;\n padding: ", " !important;\n order: ", ";\n &:hover {\n box-shadow: 0 8px 16px 0 rgba(0,0,0,0.2);\n -webkit-filter: ", ";\n transition: all .2s ease;\n background-color: ", ";\n }\n"])), function (props) {
17
- return props.cardBackgroundColor || 'white';
17
+ return props.cardBackgroundColor || 'transparent';
18
18
  }, function (props) {
19
19
  return props.cardRadius;
20
20
  }, function (props) {