@selfcommunity/react-theme-default 0.4.2-courses.159 → 0.4.2-courses.161

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (38) hide show
  1. package/lib/cjs/components/SCAccordionLessons.d.ts +3 -0
  2. package/lib/cjs/components/SCAccordionLessons.js +3 -0
  3. package/lib/cjs/components/SCCommentObjectReply.d.ts +7 -0
  4. package/lib/cjs/components/SCCommentObjectReply.js +8 -1
  5. package/lib/cjs/components/SCComposer.d.ts +13 -0
  6. package/lib/cjs/components/SCComposer.js +14 -22
  7. package/lib/cjs/components/SCEditCourse.d.ts +3 -0
  8. package/lib/cjs/components/SCEditCourse.js +3 -0
  9. package/lib/cjs/components/SCEditor.d.ts +0 -20
  10. package/lib/cjs/components/SCEditor.js +0 -20
  11. package/lib/cjs/components/SCLessonCommentObject.d.ts +3 -0
  12. package/lib/cjs/components/SCLessonCommentObject.js +3 -0
  13. package/lib/cjs/components/SCLessonFilePreview.d.ts +31 -0
  14. package/lib/cjs/components/SCLessonFilePreview.js +33 -0
  15. package/lib/cjs/components/SCLessonObject.d.ts +19 -3
  16. package/lib/cjs/components/SCLessonObject.js +19 -4
  17. package/lib/cjs/index.d.ts +79 -29
  18. package/lib/cjs/index.js +2 -0
  19. package/lib/esm/components/SCAccordionLessons.d.ts +3 -0
  20. package/lib/esm/components/SCAccordionLessons.js +3 -0
  21. package/lib/esm/components/SCCommentObjectReply.d.ts +7 -0
  22. package/lib/esm/components/SCCommentObjectReply.js +8 -1
  23. package/lib/esm/components/SCComposer.d.ts +13 -0
  24. package/lib/esm/components/SCComposer.js +14 -22
  25. package/lib/esm/components/SCEditCourse.d.ts +3 -0
  26. package/lib/esm/components/SCEditCourse.js +3 -0
  27. package/lib/esm/components/SCEditor.d.ts +0 -20
  28. package/lib/esm/components/SCEditor.js +0 -20
  29. package/lib/esm/components/SCLessonCommentObject.d.ts +3 -0
  30. package/lib/esm/components/SCLessonCommentObject.js +3 -0
  31. package/lib/esm/components/SCLessonFilePreview.d.ts +31 -0
  32. package/lib/esm/components/SCLessonFilePreview.js +31 -0
  33. package/lib/esm/components/SCLessonObject.d.ts +19 -3
  34. package/lib/esm/components/SCLessonObject.js +19 -4
  35. package/lib/esm/index.d.ts +79 -29
  36. package/lib/esm/index.js +2 -0
  37. package/lib/umd/react-theme-default.js +1 -1
  38. package/package.json +2 -2
@@ -171,31 +171,23 @@ const Component = {
171
171
  }
172
172
  }),
173
173
  contentLessonRoot: ({ theme }) => ({
174
- // '& .SCComposer-content-lesson-editor': {
174
+ padding: theme.spacing(2),
175
175
  '& .SCEditor-root': {
176
176
  '& .SCEditor-content': {
177
- paddingTop: theme.spacing(1)
177
+ paddingTop: theme.spacing(1.5)
178
+ }
179
+ },
180
+ '& .SCComposer-content-lesson-medias': {
181
+ '& .SCMediaFile-preview-root': {
182
+ marginBottom: theme.spacing(1),
183
+ '& .SCMediaFile-media': {
184
+ height: '60px !important',
185
+ maxWidth: 140
186
+ }
187
+ },
188
+ '& .SCMediaLink-preview-root': {
189
+ marginBottom: theme.spacing(1)
178
190
  }
179
- // paddingBottom: theme.spacing(2),
180
- // '& .MuiInputBase-root': {
181
- // paddingLeft: 0,
182
- // paddingRight: 0,
183
- // paddingBottom: 0,
184
- // fontSize: '1.429rem',
185
- // fontWeight: theme.typography.fontWeightBold,
186
- // '& fieldset': {
187
- // display: 'none'
188
- // },
189
- // '&.MuiInputBase-adornedEnd .MuiTypography-root': {
190
- // alignSelf: 'end'
191
- // },
192
- // '&.Mui-error': {
193
- // color: theme.palette.error.main
194
- // }
195
- // },
196
- // '& .MuiFormHelperText-root': {
197
- // marginLeft: 0
198
- // }
199
191
  }
200
192
  }),
201
193
  layerTransitionRoot: ({ theme }) => ({
@@ -105,6 +105,9 @@ declare const Component: {
105
105
  '& .SCEditCourse-cell-padding': {
106
106
  paddingRight: number;
107
107
  };
108
+ '& .MuiTableCell-root': {
109
+ textWrapMode: string;
110
+ };
108
111
  '& .SCEditCourse-table-header': {
109
112
  '& .SCEditCourse-table-header-typography': {
110
113
  textTransform: string;
@@ -103,6 +103,9 @@ const Component = {
103
103
  '& .SCEditCourse-cell-padding': {
104
104
  paddingRight: 0
105
105
  },
106
+ '& .MuiTableCell-root': {
107
+ textWrapMode: 'nowrap'
108
+ },
106
109
  '& .SCEditCourse-table-header': {
107
110
  '& .SCEditCourse-table-header-typography': {
108
111
  textTransform: 'uppercase'
@@ -154,26 +154,6 @@ declare const Component: {
154
154
  '& .SCEditor-listItem': {
155
155
  margin: string;
156
156
  };
157
- '& .SCEditor-document': {
158
- '& .selected': {
159
- border: string;
160
- };
161
- '& .MuiBox-root': {
162
- padding: any;
163
- borderRadius: string;
164
- background: any;
165
- '& a': {
166
- display: string;
167
- alignItems: string;
168
- width: string;
169
- '& img': {
170
- height: any;
171
- width: any;
172
- marginRight: any;
173
- };
174
- };
175
- };
176
- };
177
157
  };
178
158
  toolbar: ({ theme }: any) => {
179
159
  '& .SCEditor-placeholder': {
@@ -154,26 +154,6 @@ const Component = {
154
154
  },
155
155
  '& .SCEditor-listItem': {
156
156
  margin: '0 32px'
157
- },
158
- '& .SCEditor-document': {
159
- '& .selected': {
160
- border: `2px solid ${theme.palette.secondary.main}`
161
- },
162
- '& .MuiBox-root': {
163
- padding: theme.spacing(1),
164
- borderRadius: '5px',
165
- background: theme.palette.grey[300],
166
- '& a': {
167
- display: 'flex',
168
- alignItems: 'center',
169
- width: 'fit-content',
170
- '& img': {
171
- height: theme.spacing(3),
172
- width: theme.spacing(3),
173
- marginRight: theme.spacing(1)
174
- }
175
- }
176
- }
177
157
  }
178
158
  }),
179
159
  toolbar: ({ theme }) => ({
@@ -65,6 +65,9 @@ declare const Component: {
65
65
  maxWidth: string;
66
66
  };
67
67
  };
68
+ '& .SCLessonCommentObject-media-content': {
69
+ marginBottom: any;
70
+ };
68
71
  };
69
72
  '& .SCLessonCommentObject-avatar': {
70
73
  top: any;
@@ -64,6 +64,9 @@ const Component = {
64
64
  '& img': {
65
65
  maxWidth: '100%'
66
66
  }
67
+ },
68
+ '& .SCLessonCommentObject-media-content': {
69
+ marginBottom: theme.spacing(1)
67
70
  }
68
71
  },
69
72
  '& .SCLessonCommentObject-avatar': {
@@ -0,0 +1,31 @@
1
+ declare const Component: {
2
+ styleOverrides: {
3
+ root: ({ theme }: any) => {
4
+ backgroundSize: string;
5
+ backgroundPosition: string;
6
+ position: string;
7
+ borderRadius: number;
8
+ margin: any;
9
+ width: string;
10
+ height: string;
11
+ flexBasis: number;
12
+ flexGrow: number;
13
+ flexShrink: number;
14
+ '& .SCLessonFilePreview-title': {
15
+ position: string;
16
+ left: any;
17
+ top: any;
18
+ borderRadius: any;
19
+ background: string;
20
+ color: any;
21
+ fontSize: string;
22
+ padding: any;
23
+ maxWidth: number;
24
+ textOverflow: string;
25
+ overflow: string;
26
+ whiteSpace: string;
27
+ };
28
+ };
29
+ };
30
+ };
31
+ export default Component;
@@ -0,0 +1,31 @@
1
+ const Component = {
2
+ styleOverrides: {
3
+ root: ({ theme }) => ({
4
+ backgroundSize: 'cover',
5
+ backgroundPosition: 'center',
6
+ position: 'relative',
7
+ borderRadius: theme.shape.borderRadius * 0.5,
8
+ margin: theme.spacing(0.5),
9
+ width: '100%',
10
+ height: '60px',
11
+ flexBasis: 120,
12
+ flexGrow: 0,
13
+ flexShrink: 0,
14
+ '& .SCLessonFilePreview-title': {
15
+ position: 'absolute',
16
+ left: theme.spacing(1),
17
+ top: theme.spacing(1),
18
+ borderRadius: theme.shape.borderRadius,
19
+ background: '#33333380 0% 0% no-repeat padding-box',
20
+ color: theme.palette.common.white,
21
+ fontSize: '0.875rem',
22
+ padding: theme.spacing(0.5, 1),
23
+ maxWidth: 80,
24
+ textOverflow: 'ellipsis',
25
+ overflow: 'hidden',
26
+ whiteSpace: 'nowrap'
27
+ }
28
+ })
29
+ }
30
+ };
31
+ export default Component;
@@ -10,10 +10,12 @@ declare const Component: {
10
10
  padding: string;
11
11
  '& .SCLessonObject-text': {
12
12
  '& > div:first-of-type': {
13
- height: string;
14
13
  img: {
15
- height: string;
16
- objectFit: string;
14
+ display: string;
15
+ margin: string;
16
+ width: string;
17
+ maxWidth: string;
18
+ position: string;
17
19
  };
18
20
  padding: string;
19
21
  };
@@ -27,6 +29,20 @@ declare const Component: {
27
29
  color: string;
28
30
  };
29
31
  };
32
+ '& .SCLessonObject-medias-section': {
33
+ display: string;
34
+ '& .SCLessonFilePreview-root': {
35
+ marginBottom: any;
36
+ };
37
+ '& .SCMediaLink-display-root': {
38
+ marginBottom: any;
39
+ '& > div > div': {
40
+ [x: number]: {
41
+ height: string;
42
+ };
43
+ };
44
+ };
45
+ };
30
46
  };
31
47
  '& .SCLessonObject-content-edit': {
32
48
  padding: string;
@@ -10,14 +10,15 @@ const Component = {
10
10
  padding: `${theme.spacing(2)} !important`,
11
11
  '& .SCLessonObject-text': {
12
12
  '& > div:first-of-type': {
13
- height: '240px',
14
13
  img: {
15
- height: '240px',
16
- objectFit: 'cover'
14
+ display: 'block',
15
+ margin: '0 auto',
16
+ width: 'auto !important',
17
+ maxWidth: '100% !important',
18
+ position: 'relative !important'
17
19
  },
18
20
  padding: '0 !important'
19
21
  },
20
- // '& .SCEditor-paragraph': {}
21
22
  '& > div:has(> a)': {
22
23
  borderRadius: '5px',
23
24
  padding: theme.spacing(1),
@@ -27,6 +28,20 @@ const Component = {
27
28
  textDecoration: 'none',
28
29
  color: 'inherit'
29
30
  }
31
+ },
32
+ '& .SCLessonObject-medias-section': {
33
+ display: 'flex',
34
+ '& .SCLessonFilePreview-root': {
35
+ marginBottom: theme.spacing(1)
36
+ },
37
+ '& .SCMediaLink-display-root': {
38
+ marginBottom: theme.spacing(1),
39
+ '& > div > div': {
40
+ [theme.breakpoints.down('md')]: {
41
+ height: '240px !important'
42
+ }
43
+ }
44
+ }
30
45
  }
31
46
  },
32
47
  '& .SCLessonObject-content-edit': {
@@ -240,6 +240,9 @@ declare const theme: {
240
240
  }) => {
241
241
  border: string;
242
242
  borderRadius: string;
243
+ '& .SCAccordionLessons-empty': {
244
+ padding: any;
245
+ };
243
246
  '& .SCAccordionLessons-accordion': {
244
247
  '& .SCAccordionLessons-summary': {
245
248
  flexDirection: string;
@@ -1182,6 +1185,13 @@ declare const theme: {
1182
1185
  '& .SCCommentObjectReply-comment': {
1183
1186
  overflow: string;
1184
1187
  borderRadius: number;
1188
+ '& .SCCommentObjectReply-media': {
1189
+ maxWidth: number;
1190
+ padding: any;
1191
+ '& .SCMediaFile-media': {
1192
+ height: string;
1193
+ };
1194
+ };
1185
1195
  };
1186
1196
  '& .SCCommentObjectReply-actions': {
1187
1197
  marginLeft: any;
@@ -1445,11 +1455,24 @@ declare const theme: {
1445
1455
  };
1446
1456
  };
1447
1457
  contentLessonRoot: ({ theme }: any) => {
1458
+ padding: any;
1448
1459
  '& .SCEditor-root': {
1449
1460
  '& .SCEditor-content': {
1450
1461
  paddingTop: any;
1451
1462
  };
1452
1463
  };
1464
+ '& .SCComposer-content-lesson-medias': {
1465
+ '& .SCMediaFile-preview-root': {
1466
+ marginBottom: any;
1467
+ '& .SCMediaFile-media': {
1468
+ height: string;
1469
+ maxWidth: number;
1470
+ };
1471
+ };
1472
+ '& .SCMediaLink-preview-root': {
1473
+ marginBottom: any;
1474
+ };
1475
+ };
1453
1476
  };
1454
1477
  layerTransitionRoot: ({ theme }: any) => {
1455
1478
  position: string;
@@ -3112,26 +3135,6 @@ declare const theme: {
3112
3135
  '& .SCEditor-listItem': {
3113
3136
  margin: string;
3114
3137
  };
3115
- '& .SCEditor-document': {
3116
- '& .selected': {
3117
- border: string;
3118
- };
3119
- '& .MuiBox-root': {
3120
- padding: any;
3121
- borderRadius: string;
3122
- background: any;
3123
- '& a': {
3124
- display: string;
3125
- alignItems: string;
3126
- width: string;
3127
- '& img': {
3128
- height: any;
3129
- width: any;
3130
- marginRight: any;
3131
- };
3132
- };
3133
- };
3134
- };
3135
3138
  };
3136
3139
  toolbar: ({ theme }: any) => {
3137
3140
  '& .SCEditor-placeholder': {
@@ -3379,6 +3382,9 @@ declare const theme: {
3379
3382
  '& .SCEditCourse-cell-padding': {
3380
3383
  paddingRight: number;
3381
3384
  };
3385
+ '& .MuiTableCell-root': {
3386
+ textWrapMode: string;
3387
+ };
3382
3388
  '& .SCEditCourse-table-header': {
3383
3389
  '& .SCEditCourse-table-header-typography': {
3384
3390
  textTransform: string;
@@ -4069,9 +4075,7 @@ declare const theme: {
4069
4075
  fontSize: string;
4070
4076
  fontWeight: any;
4071
4077
  padding: any;
4072
- }; /**
4073
- * Style assets - Imports - End
4074
- */
4078
+ };
4075
4079
  };
4076
4080
  '& .SCCommentObject-root': {
4077
4081
  marginTop: number;
@@ -4273,9 +4277,6 @@ declare const theme: {
4273
4277
  };
4274
4278
  '& .MuiCardHeader-root': {
4275
4279
  textAlign: string;
4276
- /**
4277
- * Style assets - Exports - Start
4278
- */
4279
4280
  padding: any;
4280
4281
  '& .SCFeedObject-poll-object-toggle-button': {
4281
4282
  fontSize: string;
@@ -5406,6 +5407,9 @@ declare const theme: {
5406
5407
  maxWidth: string;
5407
5408
  };
5408
5409
  };
5410
+ '& .SCLessonCommentObject-media-content': {
5411
+ marginBottom: any;
5412
+ };
5409
5413
  };
5410
5414
  '& .SCLessonCommentObject-avatar': {
5411
5415
  top: any;
@@ -5554,6 +5558,36 @@ declare const theme: {
5554
5558
  };
5555
5559
  };
5556
5560
  };
5561
+ SCLessonFilePreview: {
5562
+ styleOverrides: {
5563
+ root: ({ theme }: any) => {
5564
+ backgroundSize: string;
5565
+ backgroundPosition: string;
5566
+ position: string;
5567
+ borderRadius: number;
5568
+ margin: any;
5569
+ width: string;
5570
+ height: string;
5571
+ flexBasis: number;
5572
+ flexGrow: number;
5573
+ flexShrink: number;
5574
+ '& .SCLessonFilePreview-title': {
5575
+ position: string;
5576
+ left: any;
5577
+ top: any;
5578
+ borderRadius: any;
5579
+ background: string;
5580
+ color: any;
5581
+ fontSize: string;
5582
+ padding: any;
5583
+ maxWidth: number;
5584
+ textOverflow: string;
5585
+ overflow: string;
5586
+ whiteSpace: string;
5587
+ };
5588
+ };
5589
+ };
5590
+ };
5557
5591
  SCLessonTemplate: {
5558
5592
  styleOverrides: {
5559
5593
  root: () => {};
@@ -5589,10 +5623,12 @@ declare const theme: {
5589
5623
  padding: string;
5590
5624
  '& .SCLessonObject-text': {
5591
5625
  '& > div:first-of-type': {
5592
- height: string;
5593
5626
  img: {
5594
- height: string;
5595
- objectFit: string;
5627
+ display: string;
5628
+ margin: string;
5629
+ width: string;
5630
+ maxWidth: string;
5631
+ position: string;
5596
5632
  };
5597
5633
  padding: string;
5598
5634
  };
@@ -5606,6 +5642,20 @@ declare const theme: {
5606
5642
  color: string;
5607
5643
  };
5608
5644
  };
5645
+ '& .SCLessonObject-medias-section': {
5646
+ display: string;
5647
+ '& .SCLessonFilePreview-root': {
5648
+ marginBottom: any;
5649
+ };
5650
+ '& .SCMediaLink-display-root': {
5651
+ marginBottom: any;
5652
+ '& > div > div': {
5653
+ [x: number]: {
5654
+ height: string;
5655
+ };
5656
+ };
5657
+ };
5658
+ };
5609
5659
  };
5610
5660
  '& .SCLessonObject-content-edit': {
5611
5661
  padding: string;
package/lib/esm/index.js CHANGED
@@ -125,6 +125,7 @@ import SCLessonCommentObject from './components/SCLessonCommentObject';
125
125
  import SCLessonCommentObjects from './components/SCLessonCommentObjects';
126
126
  import SCCourseCompletedDialog from './components/SCCourseCompletedDialog';
127
127
  import SCLessonEditForm from './components/SCLessonEditForm';
128
+ import SCLessonFilePreview from './components/SCLessonFilePreview';
128
129
  import SCLessonTemplate from './components/SCLessonTemplate';
129
130
  import SCLessonObject from './components/SCLessonObject';
130
131
  import SCLessonReleaseMenu from './components/SCLessonReleaseMenu';
@@ -383,6 +384,7 @@ const theme = {
383
384
  SCLessonCommentObjects,
384
385
  SCCourseCompletedDialog,
385
386
  SCLessonEditForm,
387
+ SCLessonFilePreview,
386
388
  SCLessonTemplate,
387
389
  SCLessonObject,
388
390
  SCLessonReleaseMenu,