herum-shared 0.1.25
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +63 -0
- package/animations/index.d.ts +5 -0
- package/assets/feed/exercise/exerciseAchivment.svg +11 -0
- package/assets/feed/icons/active/audio.svg +5 -0
- package/assets/feed/icons/active/collection.svg +15 -0
- package/assets/feed/icons/active/exercise.svg +13 -0
- package/assets/feed/icons/active/generic-file.svg +8 -0
- package/assets/feed/icons/active/image.svg +11 -0
- package/assets/feed/icons/active/link.svg +6 -0
- package/assets/feed/icons/active/pdf.svg +14 -0
- package/assets/feed/icons/active/presentation.svg +11 -0
- package/assets/feed/icons/active/quiz.svg +17 -0
- package/assets/feed/icons/active/story.svg +7 -0
- package/assets/feed/icons/active/video.svg +11 -0
- package/assets/feed/icons/comment.svg +12 -0
- package/assets/feed/icons/error/audio.svg +5 -0
- package/assets/feed/icons/error/collection.svg +15 -0
- package/assets/feed/icons/error/exercise.svg +13 -0
- package/assets/feed/icons/error/generic-file.svg +8 -0
- package/assets/feed/icons/error/image.svg +11 -0
- package/assets/feed/icons/error/pdf.svg +14 -0
- package/assets/feed/icons/error/presentation.svg +11 -0
- package/assets/feed/icons/error/quiz.svg +17 -0
- package/assets/feed/icons/error/story.svg +7 -0
- package/assets/feed/icons/error/video.svg +11 -0
- package/assets/feed/icons/eye.svg +13 -0
- package/assets/feed/icons/garbage-secondary.svg +14 -0
- package/assets/feed/icons/garbage.svg +14 -0
- package/assets/feed/icons/green-x.svg +165 -0
- package/assets/feed/icons/hamburger.svg +2 -0
- package/assets/feed/icons/inactive/audio.svg +5 -0
- package/assets/feed/icons/inactive/exercise.svg +17 -0
- package/assets/feed/icons/inactive/link.svg +6 -0
- package/assets/feed/icons/inactive/pdf.svg +19 -0
- package/assets/feed/icons/inactive/presentation.svg +13 -0
- package/assets/feed/icons/inactive/quiz.svg +25 -0
- package/assets/feed/icons/inactive/story.svg +7 -0
- package/assets/feed/icons/inactive/video.svg +13 -0
- package/assets/feed/icons/status/Group 856.svg +11 -0
- package/assets/feed/icons/status/almostDone.svg +11 -0
- package/assets/feed/icons/status/done.svg +11 -0
- package/assets/feed/icons/status/inProgress.svg +13 -0
- package/assets/feed/icons/white-chevron.svg +3 -0
- package/assets/feed/icons/wide-mode.png +0 -0
- package/assets/feed/icons/wide-mode.svg +7 -0
- package/assets/feed/icons/wide-mode2.svg +8 -0
- package/assets/files-icons/.image.svg +11 -0
- package/assets/files-icons/.mp4.png +0 -0
- package/assets/files-icons/.mp4.svg +12 -0
- package/assets/files-icons/.pdf.png +0 -0
- package/assets/files-icons/.pdf.svg +16 -0
- package/assets/files-icons/.pptx.png +0 -0
- package/assets/files-icons/.pptx.svg +12 -0
- package/assets/files-icons/.video.svg +12 -0
- package/assets/files-icons/default-file.png +0 -0
- package/assets/files-icons/generic-file.svg +8 -0
- package/assets/files-icons/story.png +0 -0
- package/assets/files-icons/story.svg +3 -0
- package/assets/files-icons/upload-file.svg +4 -0
- package/assets/general/calendar.svg +12 -0
- package/assets/general/chevron.svg +3 -0
- package/assets/general/clock.svg +4 -0
- package/assets/general/closed-chevron.png +0 -0
- package/assets/general/college-calendar.svg +12 -0
- package/assets/general/comment-icon.svg +12 -0
- package/assets/general/dialogX.png +0 -0
- package/assets/general/errorOwl.png +0 -0
- package/assets/general/green-x.svg +4 -0
- package/assets/general/grey-chevron.svg +3 -0
- package/assets/general/keyboardLink.svg +15 -0
- package/assets/general/logo.png +0 -0
- package/assets/general/noCollectionsMessage.svg +59 -0
- package/assets/general/open-chevron.png +0 -0
- package/assets/general/owl-logo.svg +98 -0
- package/assets/general/secondary-x.svg +3 -0
- package/assets/general/user.svg +15 -0
- package/assets/general/white-chevron.svg +3 -0
- package/assets/quiz/greenHeaderArrow.svg +12 -0
- package/assets/quiz/greyHeaderArrow.svg +12 -0
- package/assets/quiz/happyOwl.svg +126 -0
- package/assets/quiz/sadOwl.svg +94 -0
- package/assets/quiz/skip.svg +5 -0
- package/assets/shared/atoms/inputs/herum-inputs.component.scss +56 -0
- package/assets/shared/atoms/selects/herum-selects.component.scss +141 -0
- package/assets/shared/atoms/uploadingStatuses/error.svg +8 -0
- package/assets/shared/atoms/uploadingStatuses/information.svg +6 -0
- package/assets/shared/atoms/uploadingStatuses/success.svg +9 -0
- package/assets/shared/audio-images/gray-pause.svg +4 -0
- package/assets/shared/audio-images/gray-play.svg +3 -0
- package/assets/shared/audio-images/next15.svg +7 -0
- package/assets/shared/audio-images/pause.svg +4 -0
- package/assets/shared/audio-images/play.svg +3 -0
- package/assets/shared/audio-images/previous15.svg +7 -0
- package/assets/shared/background/cubes.png +0 -0
- package/assets/shared/background/cubes.svg +1900 -0
- package/assets/shared/icons/V.svg +3 -0
- package/assets/shared/icons/X.svg +3 -0
- package/assets/shared/icons/active-clipboard.svg +7 -0
- package/assets/shared/icons/active-drag.svg +44 -0
- package/assets/shared/icons/active-upload.svg +3 -0
- package/assets/shared/icons/add.svg +3 -0
- package/assets/shared/icons/attachUsers.png +0 -0
- package/assets/shared/icons/big-no-result-owl.png +0 -0
- package/assets/shared/icons/bigV.svg +3 -0
- package/assets/shared/icons/celeb-owl.png +0 -0
- package/assets/shared/icons/clock.svg +3 -0
- package/assets/shared/icons/drag.svg +44 -0
- package/assets/shared/icons/edit.svg +3 -0
- package/assets/shared/icons/editCollection.png +0 -0
- package/assets/shared/icons/femaleAvatar.svg +80 -0
- package/assets/shared/icons/inactive-clipboard.svg +7 -0
- package/assets/shared/icons/input/X.png +0 -0
- package/assets/shared/icons/input/X.svg +3 -0
- package/assets/shared/icons/input/drag.svg +6 -0
- package/assets/shared/icons/input/green-search.png +0 -0
- package/assets/shared/icons/input/grey-search.png +0 -0
- package/assets/shared/icons/input/search.svg +4 -0
- package/assets/shared/icons/maleAvatar.svg +55 -0
- package/assets/shared/icons/no-result-owl.png +0 -0
- package/assets/shared/icons/resources.svg +6 -0
- package/assets/shared/icons/secondary-x.svg +3 -0
- package/assets/shared/icons/settings.png +0 -0
- package/assets/shared/icons/stepper/white-v.svg +3 -0
- package/assets/shared/icons/table/edit.svg +3 -0
- package/assets/shared/icons/target.png +0 -0
- package/assets/shared/icons/upload.png +0 -0
- package/assets/shared/icons/upload.svg +7 -0
- package/assets/shared/icons/user.svg +8 -0
- package/assets/shared/icons/video/Play.PNG +0 -0
- package/assets/shared/icons/video/back10.PNG +0 -0
- package/assets/shared/icons/video/back10.svg +7 -0
- package/assets/shared/icons/video/download.PNG +0 -0
- package/assets/shared/icons/video/download.svg +4 -0
- package/assets/shared/icons/video/fullScreen.PNG +0 -0
- package/assets/shared/icons/video/fullScreen.svg +7 -0
- package/assets/shared/icons/video/minimize.png +0 -0
- package/assets/shared/icons/video/mute.png +0 -0
- package/assets/shared/icons/video/mute.svg +7 -0
- package/assets/shared/icons/video/next10.PNG +0 -0
- package/assets/shared/icons/video/next10.svg +7 -0
- package/assets/shared/icons/video/pause.PNG +0 -0
- package/assets/shared/icons/video/pause.svg +5 -0
- package/assets/shared/icons/video/pictureInPicture.png +0 -0
- package/assets/shared/icons/video/pictureInPicture.svg +5 -0
- package/assets/shared/icons/video/pictureInPictureOff.svg +7 -0
- package/assets/shared/icons/video/play.svg +4 -0
- package/assets/shared/icons/video/primary-play.png +0 -0
- package/assets/shared/icons/video/primaryPlay.svg +22 -0
- package/assets/shared/icons/video/sound.svg +8 -0
- package/assets/shared/icons/video/speaker.PNG +0 -0
- package/assets/shared/trackChanges/edit.svg +11 -0
- package/assets/shared/trackChanges/message-plus.svg +14 -0
- package/assets/shared/trackChanges/show-comments.svg +5 -0
- package/assets/shared/trackChanges/text-reference.svg +3 -0
- package/assets/shared/trackChanges/trash.svg +9 -0
- package/atoms/index.d.ts +836 -0
- package/constants/index.d.ts +795 -0
- package/decorators/index.d.ts +3 -0
- package/dialogs/index.d.ts +41 -0
- package/directives/index.d.ts +55 -0
- package/environment/index.d.ts +129 -0
- package/errors/index.d.ts +26 -0
- package/fesm2022/herum-shared-animations.mjs +41 -0
- package/fesm2022/herum-shared-animations.mjs.map +1 -0
- package/fesm2022/herum-shared-atoms.mjs +2919 -0
- package/fesm2022/herum-shared-atoms.mjs.map +1 -0
- package/fesm2022/herum-shared-constants.mjs +711 -0
- package/fesm2022/herum-shared-constants.mjs.map +1 -0
- package/fesm2022/herum-shared-decorators.mjs +12 -0
- package/fesm2022/herum-shared-decorators.mjs.map +1 -0
- package/fesm2022/herum-shared-dialogs.mjs +113 -0
- package/fesm2022/herum-shared-dialogs.mjs.map +1 -0
- package/fesm2022/herum-shared-directives.mjs +226 -0
- package/fesm2022/herum-shared-directives.mjs.map +1 -0
- package/fesm2022/herum-shared-environment.mjs +10 -0
- package/fesm2022/herum-shared-environment.mjs.map +1 -0
- package/fesm2022/herum-shared-errors.mjs +71 -0
- package/fesm2022/herum-shared-errors.mjs.map +1 -0
- package/fesm2022/herum-shared-fetched-message.mjs +118 -0
- package/fesm2022/herum-shared-fetched-message.mjs.map +1 -0
- package/fesm2022/herum-shared-herum-types.mjs +106 -0
- package/fesm2022/herum-shared-herum-types.mjs.map +1 -0
- package/fesm2022/herum-shared-molecules.mjs +1530 -0
- package/fesm2022/herum-shared-molecules.mjs.map +1 -0
- package/fesm2022/herum-shared-mongo-molecules.mjs +269 -0
- package/fesm2022/herum-shared-mongo-molecules.mjs.map +1 -0
- package/fesm2022/herum-shared-mongo-services.mjs +441 -0
- package/fesm2022/herum-shared-mongo-services.mjs.map +1 -0
- package/fesm2022/herum-shared-mongo.mjs +729 -0
- package/fesm2022/herum-shared-mongo.mjs.map +1 -0
- package/fesm2022/herum-shared-objectsExample.mjs +190 -0
- package/fesm2022/herum-shared-objectsExample.mjs.map +1 -0
- package/fesm2022/herum-shared-pipes.mjs +406 -0
- package/fesm2022/herum-shared-pipes.mjs.map +1 -0
- package/fesm2022/herum-shared-services.mjs +1107 -0
- package/fesm2022/herum-shared-services.mjs.map +1 -0
- package/fesm2022/herum-shared-static-services.mjs +140 -0
- package/fesm2022/herum-shared-static-services.mjs.map +1 -0
- package/fesm2022/herum-shared-table.mjs +837 -0
- package/fesm2022/herum-shared-table.mjs.map +1 -0
- package/fesm2022/herum-shared-testsObjects.mjs +5722 -0
- package/fesm2022/herum-shared-testsObjects.mjs.map +1 -0
- package/fesm2022/herum-shared-tokens.mjs +13 -0
- package/fesm2022/herum-shared-tokens.mjs.map +1 -0
- package/fesm2022/herum-shared-utils.mjs +380 -0
- package/fesm2022/herum-shared-utils.mjs.map +1 -0
- package/fesm2022/herum-shared-validators.mjs +76 -0
- package/fesm2022/herum-shared-validators.mjs.map +1 -0
- package/fesm2022/herum-shared.mjs +11709 -0
- package/fesm2022/herum-shared.mjs.map +1 -0
- package/fetched-message/index.d.ts +49 -0
- package/herum-types/index.d.ts +198 -0
- package/index.d.ts +2946 -0
- package/molecules/index.d.ts +458 -0
- package/mongo/index.d.ts +175 -0
- package/mongo/molecules/index.d.ts +76 -0
- package/mongo/services/index.d.ts +98 -0
- package/objectsExample/index.d.ts +11 -0
- package/package.json +128 -0
- package/pipes/index.d.ts +93 -0
- package/services/index.d.ts +266 -0
- package/static-services/index.d.ts +25 -0
- package/styles/_mixin.scss +86 -0
- package/styles/collection-wizard-layout.component.scss +70 -0
- package/styles/dialogs.scss +49 -0
- package/styles/forms.scss +18 -0
- package/styles/overView.scss +115 -0
- package/styles/variables/_colors.college.scss +65 -0
- package/styles/variables/_colors.scss +161 -0
- package/styles/variables/_sizes.scss +73 -0
- package/styles/wizard-steps-layout.scss +21 -0
- package/table/index.d.ts +233 -0
- package/testsObjects/index.d.ts +91 -0
- package/tokens/index.d.ts +8 -0
- package/utils/index.d.ts +92 -0
- package/validators/index.d.ts +20 -0
|
@@ -0,0 +1,406 @@
|
|
|
1
|
+
import * as i0 from '@angular/core';
|
|
2
|
+
import { Pipe, NgModule } from '@angular/core';
|
|
3
|
+
import * as i1 from '@angular/platform-browser';
|
|
4
|
+
import { signUpFormKeys } from 'herum-shared/constants';
|
|
5
|
+
|
|
6
|
+
class AnswerNotesToTextChangesPipe {
|
|
7
|
+
transform(answerNotes) {
|
|
8
|
+
return answerNotes?.map(answerNote => ({
|
|
9
|
+
type: answerNote.type,
|
|
10
|
+
creatingUser: answerNote.creatingUser,
|
|
11
|
+
id: answerNote.id,
|
|
12
|
+
note: answerNote.note,
|
|
13
|
+
timeStamp: answerNote.timeStamp,
|
|
14
|
+
startOffset: answerNote.startIndex,
|
|
15
|
+
endOffset: answerNote.endIndex,
|
|
16
|
+
commentText: answerNote.commentText
|
|
17
|
+
}))
|
|
18
|
+
.sort((a, b) => new Date(a.startOffset).getTime() - new Date(b.startOffset).getTime());
|
|
19
|
+
}
|
|
20
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.17", ngImport: i0, type: AnswerNotesToTextChangesPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe });
|
|
21
|
+
static ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "20.3.17", ngImport: i0, type: AnswerNotesToTextChangesPipe, isStandalone: false, name: "answerNotesToTextChanges" });
|
|
22
|
+
}
|
|
23
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.17", ngImport: i0, type: AnswerNotesToTextChangesPipe, decorators: [{
|
|
24
|
+
type: Pipe,
|
|
25
|
+
args: [{
|
|
26
|
+
standalone: false,
|
|
27
|
+
name: 'answerNotesToTextChanges'
|
|
28
|
+
}]
|
|
29
|
+
}] });
|
|
30
|
+
|
|
31
|
+
class CollectionSubscriptionToCollectionBasePipe {
|
|
32
|
+
transform(collectionSubscription, ...args) {
|
|
33
|
+
let collectionBase = {
|
|
34
|
+
...collectionSubscription.collectionPreview,
|
|
35
|
+
resources: collectionSubscription.resourceSubscriptions.map(resourceSubscription => resourceSubscription.resourcePreview),
|
|
36
|
+
grade: collectionSubscription.grade,
|
|
37
|
+
};
|
|
38
|
+
return collectionBase;
|
|
39
|
+
}
|
|
40
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.17", ngImport: i0, type: CollectionSubscriptionToCollectionBasePipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe });
|
|
41
|
+
static ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "20.3.17", ngImport: i0, type: CollectionSubscriptionToCollectionBasePipe, isStandalone: false, name: "collectionSubscriptionToCollectionBase" });
|
|
42
|
+
}
|
|
43
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.17", ngImport: i0, type: CollectionSubscriptionToCollectionBasePipe, decorators: [{
|
|
44
|
+
type: Pipe,
|
|
45
|
+
args: [{
|
|
46
|
+
standalone: false,
|
|
47
|
+
name: 'collectionSubscriptionToCollectionBase'
|
|
48
|
+
}]
|
|
49
|
+
}] });
|
|
50
|
+
|
|
51
|
+
class CollectionToCollectionBasePipe {
|
|
52
|
+
transform(collection, ...args) {
|
|
53
|
+
let collectionBase = {
|
|
54
|
+
...collection,
|
|
55
|
+
resources: collection.resources.map(resource => resource.resourcePreview)
|
|
56
|
+
};
|
|
57
|
+
return collectionBase;
|
|
58
|
+
}
|
|
59
|
+
transformMulti(collections) {
|
|
60
|
+
let collectionsBase = collections.map(collection => this.transform(collection));
|
|
61
|
+
return collectionsBase;
|
|
62
|
+
}
|
|
63
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.17", ngImport: i0, type: CollectionToCollectionBasePipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe });
|
|
64
|
+
static ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "20.3.17", ngImport: i0, type: CollectionToCollectionBasePipe, isStandalone: false, name: "collectionToCollectionBase" });
|
|
65
|
+
}
|
|
66
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.17", ngImport: i0, type: CollectionToCollectionBasePipe, decorators: [{
|
|
67
|
+
type: Pipe,
|
|
68
|
+
args: [{
|
|
69
|
+
standalone: false,
|
|
70
|
+
name: 'collectionToCollectionBase'
|
|
71
|
+
}]
|
|
72
|
+
}] });
|
|
73
|
+
|
|
74
|
+
class DisplayedSubmissionsCounterPipe {
|
|
75
|
+
transform(resource, quizData, areAnswersBlocked) {
|
|
76
|
+
let submissionsCounter = quizData.submissionsCounter;
|
|
77
|
+
if (!resource.quiz.maxSubmissions)
|
|
78
|
+
return ++submissionsCounter;
|
|
79
|
+
if (quizData.isSubmitted || areAnswersBlocked)
|
|
80
|
+
return submissionsCounter || ++submissionsCounter;
|
|
81
|
+
return submissionsCounter < resource.quiz.maxSubmissions ? ++submissionsCounter : submissionsCounter;
|
|
82
|
+
}
|
|
83
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.17", ngImport: i0, type: DisplayedSubmissionsCounterPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe });
|
|
84
|
+
static ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "20.3.17", ngImport: i0, type: DisplayedSubmissionsCounterPipe, isStandalone: false, name: "displayedSubmissionsCounter" });
|
|
85
|
+
}
|
|
86
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.17", ngImport: i0, type: DisplayedSubmissionsCounterPipe, decorators: [{
|
|
87
|
+
type: Pipe,
|
|
88
|
+
args: [{
|
|
89
|
+
name: 'displayedSubmissionsCounter',
|
|
90
|
+
standalone: false
|
|
91
|
+
}]
|
|
92
|
+
}] });
|
|
93
|
+
|
|
94
|
+
class EllipsisPipe {
|
|
95
|
+
transform(value, element, numberOfRows = 1) {
|
|
96
|
+
if (!value || !element || numberOfRows < 1)
|
|
97
|
+
return '';
|
|
98
|
+
if (!element.clientWidth)
|
|
99
|
+
return value;
|
|
100
|
+
const style = window.getComputedStyle(element);
|
|
101
|
+
const fontSize = parseFloat(style.fontSize);
|
|
102
|
+
const fontFamily = style.fontFamily;
|
|
103
|
+
const availableWidth = element.clientWidth - this.getElementWidth(fontSize, fontFamily, '...');
|
|
104
|
+
return numberOfRows > 1 ?
|
|
105
|
+
this.handleMultiRows(value, fontSize, fontFamily, numberOfRows, element.clientWidth, availableWidth)
|
|
106
|
+
:
|
|
107
|
+
this.ellipsis(value, fontSize, fontFamily, availableWidth);
|
|
108
|
+
}
|
|
109
|
+
handleMultiRows(value, fontSize, fontFamily, numberOfRows, maxRowWidth, availableWidth) {
|
|
110
|
+
const words = value.split(' ');
|
|
111
|
+
let text = '';
|
|
112
|
+
let rowWidthCounter = 0;
|
|
113
|
+
let rowsCounter = 1;
|
|
114
|
+
let isLastRow = false;
|
|
115
|
+
for (let index = 0; index < words.length; index++) {
|
|
116
|
+
const word = words[index];
|
|
117
|
+
const wordWidth = this.getElementWidth(fontSize, fontFamily, word) + this.getElementWidth(fontSize, fontFamily, ' ');
|
|
118
|
+
if ((rowWidthCounter + wordWidth >= maxRowWidth)) {
|
|
119
|
+
rowsCounter = rowsCounter + 1;
|
|
120
|
+
rowWidthCounter = 0;
|
|
121
|
+
}
|
|
122
|
+
isLastRow = rowsCounter === numberOfRows;
|
|
123
|
+
if ((Math.ceil(rowWidthCounter + wordWidth) < maxRowWidth) && !isLastRow) {
|
|
124
|
+
rowWidthCounter += wordWidth;
|
|
125
|
+
text += words[index] + ' ';
|
|
126
|
+
}
|
|
127
|
+
if (isLastRow && index < words.length) {
|
|
128
|
+
const leftText = words.slice(index).join(' ');
|
|
129
|
+
text += this.ellipsis(leftText, fontSize, fontFamily, availableWidth);
|
|
130
|
+
break;
|
|
131
|
+
}
|
|
132
|
+
}
|
|
133
|
+
return text;
|
|
134
|
+
}
|
|
135
|
+
ellipsis(text, fontSize, fontFamily, availableWidth) {
|
|
136
|
+
let totalWidth = 0;
|
|
137
|
+
let newText = '';
|
|
138
|
+
for (let index = 0; index < text.length; index++) {
|
|
139
|
+
const char = text[index];
|
|
140
|
+
const charWidth = this.getElementWidth(fontSize, fontFamily, char);
|
|
141
|
+
totalWidth += charWidth;
|
|
142
|
+
if (Math.ceil(totalWidth) >= availableWidth)
|
|
143
|
+
return newText + '...';
|
|
144
|
+
newText += char;
|
|
145
|
+
}
|
|
146
|
+
return newText;
|
|
147
|
+
}
|
|
148
|
+
getElementWidth(fontSize, fontFamily, element) {
|
|
149
|
+
const canvas = document.createElement('canvas');
|
|
150
|
+
const context = canvas.getContext('2d');
|
|
151
|
+
context.font = `${fontSize}px ${fontFamily}`;
|
|
152
|
+
const metrics = context.measureText(element);
|
|
153
|
+
return metrics.width;
|
|
154
|
+
}
|
|
155
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.17", ngImport: i0, type: EllipsisPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe });
|
|
156
|
+
static ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "20.3.17", ngImport: i0, type: EllipsisPipe, isStandalone: false, name: "ellipsis" });
|
|
157
|
+
}
|
|
158
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.17", ngImport: i0, type: EllipsisPipe, decorators: [{
|
|
159
|
+
type: Pipe,
|
|
160
|
+
args: [{
|
|
161
|
+
standalone: false,
|
|
162
|
+
name: 'ellipsis'
|
|
163
|
+
}]
|
|
164
|
+
}] });
|
|
165
|
+
|
|
166
|
+
class ResourceSubscriptionToResourcePipe {
|
|
167
|
+
transform(resourceSubscription, ...args) {
|
|
168
|
+
let resource = {
|
|
169
|
+
positionInCollection: resourceSubscription.positionInCollection,
|
|
170
|
+
description: resourceSubscription.resourcePreview.description,
|
|
171
|
+
title: resourceSubscription.resourcePreview.title,
|
|
172
|
+
resourceType: resourceSubscription.resourcePreview.resourceType,
|
|
173
|
+
files: resourceSubscription.resourcePreview.files
|
|
174
|
+
};
|
|
175
|
+
return resource;
|
|
176
|
+
}
|
|
177
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.17", ngImport: i0, type: ResourceSubscriptionToResourcePipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe });
|
|
178
|
+
static ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "20.3.17", ngImport: i0, type: ResourceSubscriptionToResourcePipe, isStandalone: false, name: "resourceSubscriptionToResource" });
|
|
179
|
+
}
|
|
180
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.17", ngImport: i0, type: ResourceSubscriptionToResourcePipe, decorators: [{
|
|
181
|
+
type: Pipe,
|
|
182
|
+
args: [{
|
|
183
|
+
standalone: false,
|
|
184
|
+
name: 'resourceSubscriptionToResource'
|
|
185
|
+
}]
|
|
186
|
+
}] });
|
|
187
|
+
|
|
188
|
+
class ResourceToResourceSubscriptionPipe {
|
|
189
|
+
transform(resource, ...args) {
|
|
190
|
+
let resourceSubscription = {
|
|
191
|
+
subscriptionStatus: 0,
|
|
192
|
+
positionInCollection: resource.positionInCollection,
|
|
193
|
+
resourcePreview: {
|
|
194
|
+
...resource
|
|
195
|
+
}
|
|
196
|
+
};
|
|
197
|
+
return resourceSubscription;
|
|
198
|
+
}
|
|
199
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.17", ngImport: i0, type: ResourceToResourceSubscriptionPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe });
|
|
200
|
+
static ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "20.3.17", ngImport: i0, type: ResourceToResourceSubscriptionPipe, isStandalone: false, name: "resourceToResourceSubscription" });
|
|
201
|
+
}
|
|
202
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.17", ngImport: i0, type: ResourceToResourceSubscriptionPipe, decorators: [{
|
|
203
|
+
type: Pipe,
|
|
204
|
+
args: [{
|
|
205
|
+
standalone: false,
|
|
206
|
+
name: 'resourceToResourceSubscription'
|
|
207
|
+
}]
|
|
208
|
+
}] });
|
|
209
|
+
|
|
210
|
+
class SafeHtmlPipe {
|
|
211
|
+
sanitized;
|
|
212
|
+
constructor(sanitized) {
|
|
213
|
+
this.sanitized = sanitized;
|
|
214
|
+
}
|
|
215
|
+
transform(value) {
|
|
216
|
+
return this.sanitized.bypassSecurityTrustHtml(value);
|
|
217
|
+
}
|
|
218
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.17", ngImport: i0, type: SafeHtmlPipe, deps: [{ token: i1.DomSanitizer }], target: i0.ɵɵFactoryTarget.Pipe });
|
|
219
|
+
static ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "20.3.17", ngImport: i0, type: SafeHtmlPipe, isStandalone: false, name: "safeHtml" });
|
|
220
|
+
}
|
|
221
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.17", ngImport: i0, type: SafeHtmlPipe, decorators: [{
|
|
222
|
+
type: Pipe,
|
|
223
|
+
args: [{
|
|
224
|
+
standalone: false,
|
|
225
|
+
name: 'safeHtml'
|
|
226
|
+
}]
|
|
227
|
+
}], ctorParameters: () => [{ type: i1.DomSanitizer }] });
|
|
228
|
+
|
|
229
|
+
class SafePipe {
|
|
230
|
+
sanitizer;
|
|
231
|
+
constructor(sanitizer) {
|
|
232
|
+
this.sanitizer = sanitizer;
|
|
233
|
+
}
|
|
234
|
+
transform(url) {
|
|
235
|
+
return this.sanitizer.bypassSecurityTrustResourceUrl(url);
|
|
236
|
+
}
|
|
237
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.17", ngImport: i0, type: SafePipe, deps: [{ token: i1.DomSanitizer }], target: i0.ɵɵFactoryTarget.Pipe });
|
|
238
|
+
static ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "20.3.17", ngImport: i0, type: SafePipe, isStandalone: false, name: "safe" });
|
|
239
|
+
}
|
|
240
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.17", ngImport: i0, type: SafePipe, decorators: [{
|
|
241
|
+
type: Pipe,
|
|
242
|
+
args: [{
|
|
243
|
+
standalone: false,
|
|
244
|
+
name: 'safe'
|
|
245
|
+
}]
|
|
246
|
+
}], ctorParameters: () => [{ type: i1.DomSanitizer }] });
|
|
247
|
+
|
|
248
|
+
class StringArrayToSignUpFieldArrayPipe {
|
|
249
|
+
transform(fields) {
|
|
250
|
+
if (!Array.isArray(fields))
|
|
251
|
+
return [];
|
|
252
|
+
return fields.map((field) => ({
|
|
253
|
+
field,
|
|
254
|
+
showSeparator: false
|
|
255
|
+
}));
|
|
256
|
+
}
|
|
257
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.17", ngImport: i0, type: StringArrayToSignUpFieldArrayPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe });
|
|
258
|
+
static ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "20.3.17", ngImport: i0, type: StringArrayToSignUpFieldArrayPipe, isStandalone: false, name: "stringArrayToSignUpFieldArray" });
|
|
259
|
+
}
|
|
260
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.17", ngImport: i0, type: StringArrayToSignUpFieldArrayPipe, decorators: [{
|
|
261
|
+
type: Pipe,
|
|
262
|
+
args: [{
|
|
263
|
+
standalone: false,
|
|
264
|
+
name: 'stringArrayToSignUpFieldArray'
|
|
265
|
+
}]
|
|
266
|
+
}] });
|
|
267
|
+
|
|
268
|
+
class ToIntegerPipe {
|
|
269
|
+
transform(number) {
|
|
270
|
+
return Number.isInteger(number) ? number : Number(number.toFixed(0));
|
|
271
|
+
}
|
|
272
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.17", ngImport: i0, type: ToIntegerPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe });
|
|
273
|
+
static ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "20.3.17", ngImport: i0, type: ToIntegerPipe, isStandalone: false, name: "toInteger" });
|
|
274
|
+
}
|
|
275
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.17", ngImport: i0, type: ToIntegerPipe, decorators: [{
|
|
276
|
+
type: Pipe,
|
|
277
|
+
args: [{
|
|
278
|
+
name: 'toInteger',
|
|
279
|
+
standalone: false
|
|
280
|
+
}]
|
|
281
|
+
}] });
|
|
282
|
+
|
|
283
|
+
const userFieldsToValueFormatters = {
|
|
284
|
+
[signUpFormKeys.sections]: { valueFormatter: (sections) => identifiedEntityToSectionListItem(sections) },
|
|
285
|
+
[signUpFormKeys.sagahs]: { valueFormatter: (sagahs) => identifiedEntityToDbListItem(sagahs) },
|
|
286
|
+
[signUpFormKeys.subjectAreas]: { valueFormatter: (subjectAreas) => identifiedEntityToDbListItem(subjectAreas) }
|
|
287
|
+
};
|
|
288
|
+
function identifiedEntityToDbListItem(items) {
|
|
289
|
+
return items.map(item => ({ id: item.id, value: item.name }));
|
|
290
|
+
}
|
|
291
|
+
function identifiedEntityToSectionListItem(items) {
|
|
292
|
+
return items.map(item => ({ id: item.id, section: item.name }));
|
|
293
|
+
}
|
|
294
|
+
class UserIdentifiedEntitiesToBackendModelsPipe {
|
|
295
|
+
transform(user) {
|
|
296
|
+
Object.keys(userFieldsToValueFormatters).forEach(key => {
|
|
297
|
+
if (user[key])
|
|
298
|
+
user[key] = userFieldsToValueFormatters[key].valueFormatter(user[key]);
|
|
299
|
+
});
|
|
300
|
+
return user;
|
|
301
|
+
}
|
|
302
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.17", ngImport: i0, type: UserIdentifiedEntitiesToBackendModelsPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe });
|
|
303
|
+
static ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "20.3.17", ngImport: i0, type: UserIdentifiedEntitiesToBackendModelsPipe, isStandalone: false, name: "userIdentifiedEntitiesToBackendModels" });
|
|
304
|
+
}
|
|
305
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.17", ngImport: i0, type: UserIdentifiedEntitiesToBackendModelsPipe, decorators: [{
|
|
306
|
+
type: Pipe,
|
|
307
|
+
args: [{
|
|
308
|
+
standalone: false,
|
|
309
|
+
name: 'userIdentifiedEntitiesToBackendModels'
|
|
310
|
+
}]
|
|
311
|
+
}] });
|
|
312
|
+
|
|
313
|
+
class PipesModule {
|
|
314
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.17", ngImport: i0, type: PipesModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
315
|
+
static ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "20.3.17", ngImport: i0, type: PipesModule, declarations: [SafePipe,
|
|
316
|
+
CollectionSubscriptionToCollectionBasePipe,
|
|
317
|
+
CollectionToCollectionBasePipe,
|
|
318
|
+
SafeHtmlPipe,
|
|
319
|
+
ResourceSubscriptionToResourcePipe,
|
|
320
|
+
ResourceToResourceSubscriptionPipe,
|
|
321
|
+
EllipsisPipe,
|
|
322
|
+
UserIdentifiedEntitiesToBackendModelsPipe,
|
|
323
|
+
AnswerNotesToTextChangesPipe,
|
|
324
|
+
StringArrayToSignUpFieldArrayPipe,
|
|
325
|
+
ToIntegerPipe,
|
|
326
|
+
DisplayedSubmissionsCounterPipe], exports: [SafePipe,
|
|
327
|
+
CollectionSubscriptionToCollectionBasePipe,
|
|
328
|
+
CollectionToCollectionBasePipe,
|
|
329
|
+
SafeHtmlPipe,
|
|
330
|
+
ResourceSubscriptionToResourcePipe,
|
|
331
|
+
ResourceToResourceSubscriptionPipe,
|
|
332
|
+
EllipsisPipe,
|
|
333
|
+
UserIdentifiedEntitiesToBackendModelsPipe,
|
|
334
|
+
AnswerNotesToTextChangesPipe,
|
|
335
|
+
StringArrayToSignUpFieldArrayPipe,
|
|
336
|
+
ToIntegerPipe,
|
|
337
|
+
DisplayedSubmissionsCounterPipe] });
|
|
338
|
+
static ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "20.3.17", ngImport: i0, type: PipesModule, providers: [
|
|
339
|
+
SafePipe,
|
|
340
|
+
CollectionSubscriptionToCollectionBasePipe,
|
|
341
|
+
CollectionToCollectionBasePipe,
|
|
342
|
+
SafeHtmlPipe,
|
|
343
|
+
ResourceSubscriptionToResourcePipe,
|
|
344
|
+
ResourceToResourceSubscriptionPipe,
|
|
345
|
+
EllipsisPipe,
|
|
346
|
+
UserIdentifiedEntitiesToBackendModelsPipe,
|
|
347
|
+
AnswerNotesToTextChangesPipe,
|
|
348
|
+
StringArrayToSignUpFieldArrayPipe,
|
|
349
|
+
ToIntegerPipe,
|
|
350
|
+
DisplayedSubmissionsCounterPipe,
|
|
351
|
+
] });
|
|
352
|
+
}
|
|
353
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.17", ngImport: i0, type: PipesModule, decorators: [{
|
|
354
|
+
type: NgModule,
|
|
355
|
+
args: [{
|
|
356
|
+
declarations: [
|
|
357
|
+
SafePipe,
|
|
358
|
+
CollectionSubscriptionToCollectionBasePipe,
|
|
359
|
+
CollectionToCollectionBasePipe,
|
|
360
|
+
SafeHtmlPipe,
|
|
361
|
+
ResourceSubscriptionToResourcePipe,
|
|
362
|
+
ResourceToResourceSubscriptionPipe,
|
|
363
|
+
EllipsisPipe,
|
|
364
|
+
UserIdentifiedEntitiesToBackendModelsPipe,
|
|
365
|
+
AnswerNotesToTextChangesPipe,
|
|
366
|
+
StringArrayToSignUpFieldArrayPipe,
|
|
367
|
+
ToIntegerPipe,
|
|
368
|
+
DisplayedSubmissionsCounterPipe,
|
|
369
|
+
],
|
|
370
|
+
exports: [
|
|
371
|
+
SafePipe,
|
|
372
|
+
CollectionSubscriptionToCollectionBasePipe,
|
|
373
|
+
CollectionToCollectionBasePipe,
|
|
374
|
+
SafeHtmlPipe,
|
|
375
|
+
ResourceSubscriptionToResourcePipe,
|
|
376
|
+
ResourceToResourceSubscriptionPipe,
|
|
377
|
+
EllipsisPipe,
|
|
378
|
+
UserIdentifiedEntitiesToBackendModelsPipe,
|
|
379
|
+
AnswerNotesToTextChangesPipe,
|
|
380
|
+
StringArrayToSignUpFieldArrayPipe,
|
|
381
|
+
ToIntegerPipe,
|
|
382
|
+
DisplayedSubmissionsCounterPipe,
|
|
383
|
+
],
|
|
384
|
+
providers: [
|
|
385
|
+
SafePipe,
|
|
386
|
+
CollectionSubscriptionToCollectionBasePipe,
|
|
387
|
+
CollectionToCollectionBasePipe,
|
|
388
|
+
SafeHtmlPipe,
|
|
389
|
+
ResourceSubscriptionToResourcePipe,
|
|
390
|
+
ResourceToResourceSubscriptionPipe,
|
|
391
|
+
EllipsisPipe,
|
|
392
|
+
UserIdentifiedEntitiesToBackendModelsPipe,
|
|
393
|
+
AnswerNotesToTextChangesPipe,
|
|
394
|
+
StringArrayToSignUpFieldArrayPipe,
|
|
395
|
+
ToIntegerPipe,
|
|
396
|
+
DisplayedSubmissionsCounterPipe,
|
|
397
|
+
]
|
|
398
|
+
}]
|
|
399
|
+
}] });
|
|
400
|
+
|
|
401
|
+
/**
|
|
402
|
+
* Generated bundle index. Do not edit.
|
|
403
|
+
*/
|
|
404
|
+
|
|
405
|
+
export { AnswerNotesToTextChangesPipe, CollectionSubscriptionToCollectionBasePipe, CollectionToCollectionBasePipe, DisplayedSubmissionsCounterPipe, EllipsisPipe, PipesModule, ResourceSubscriptionToResourcePipe, ResourceToResourceSubscriptionPipe, SafeHtmlPipe, SafePipe, StringArrayToSignUpFieldArrayPipe, ToIntegerPipe, UserIdentifiedEntitiesToBackendModelsPipe };
|
|
406
|
+
//# sourceMappingURL=herum-shared-pipes.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"herum-shared-pipes.mjs","sources":["../../../projects/herum-shared/pipes/answer-notes-to-text-changes.pipe.ts","../../../projects/herum-shared/pipes/collection-subscription-to-collection-base.pipe.ts","../../../projects/herum-shared/pipes/collection-to-collection-base.pipe.ts","../../../projects/herum-shared/pipes/displayed-submissions-counter-pipe.ts","../../../projects/herum-shared/pipes/ellipsis.pipe.ts","../../../projects/herum-shared/pipes/resource-subscription-to-resource.pipe.ts","../../../projects/herum-shared/pipes/resource-to-resource-subscription.pipe.ts","../../../projects/herum-shared/pipes/safe-html.pipe.ts","../../../projects/herum-shared/pipes/safe.pipe.ts","../../../projects/herum-shared/pipes/sign-up-fields-to-sign-up-field-config.pipe.ts","../../../projects/herum-shared/pipes/to-integer.pipe.ts","../../../projects/herum-shared/pipes/user-identified-entities-to-backend-models.pipe.ts","../../../projects/herum-shared/pipes/pipes-module.ts","../../../projects/herum-shared/pipes/herum-shared-pipes.ts"],"sourcesContent":["import { Pipe, PipeTransform } from '@angular/core';\r\nimport { TextChange } from 'herum-shared/herum-types';\r\nimport { AnswerNote } from 'herum-shared/herum-types';\r\n\r\n@Pipe({\r\n standalone: false,\r\n name: 'answerNotesToTextChanges'\r\n})\r\nexport class AnswerNotesToTextChangesPipe implements PipeTransform {\r\n\r\n transform(answerNotes: AnswerNote[]): TextChange[] {\r\n return answerNotes?.map(answerNote =>\r\n ({\r\n type: answerNote.type,\r\n creatingUser: answerNote.creatingUser,\r\n id: answerNote.id,\r\n note: answerNote.note,\r\n timeStamp: answerNote.timeStamp,\r\n startOffset: answerNote.startIndex,\r\n endOffset: answerNote.endIndex,\r\n commentText: answerNote.commentText\r\n })\r\n )\r\n .sort((a, b) => new Date(a.startOffset).getTime() - new Date(b.startOffset).getTime());\r\n }\r\n}","import { Pipe, PipeTransform } from '@angular/core';\r\nimport { CollectionBase } from 'herum-shared/herum-types';\r\nimport { CollectionSubscription } from 'herum-shared/herum-types';\r\n\r\n@Pipe({\r\n standalone: false,\r\n name: 'collectionSubscriptionToCollectionBase'\r\n})\r\nexport class CollectionSubscriptionToCollectionBasePipe implements PipeTransform {\r\n\r\n transform(collectionSubscription: CollectionSubscription, ...args: unknown[]): CollectionBase {\r\n let collectionBase: CollectionBase = {\r\n ...collectionSubscription.collectionPreview,\r\n resources: collectionSubscription.resourceSubscriptions.map(resourceSubscription => resourceSubscription.resourcePreview),\r\n grade: collectionSubscription.grade,\r\n };\r\n\r\n return collectionBase;\r\n }\r\n}","import { Pipe, PipeTransform } from '@angular/core';\r\nimport { Collection, CollectionBase } from 'herum-shared/herum-types';\r\n\r\n@Pipe({\r\n standalone: false,\r\n name: 'collectionToCollectionBase'\r\n})\r\nexport class CollectionToCollectionBasePipe implements PipeTransform {\r\n\r\n transform(collection: Collection, ...args: unknown[]): CollectionBase {\r\n let collectionBase: CollectionBase = {\r\n ...collection,\r\n resources: collection.resources.map(resource => resource.resourcePreview)\r\n }\r\n\r\n return collectionBase;\r\n }\r\n\r\n transformMulti(collections: Collection[]): CollectionBase[] {\r\n let collectionsBase: CollectionBase[] = collections.map(collection => this.transform(collection))\r\n return collectionsBase;\r\n }\r\n}\r\n","import { Pipe, PipeTransform } from '@angular/core';\r\nimport { QuizData, Resource } from 'herum-shared/herum-types';\r\n\r\n@Pipe({\r\n name: 'displayedSubmissionsCounter',\r\n standalone: false\r\n})\r\nexport class DisplayedSubmissionsCounterPipe implements PipeTransform {\r\n\r\n transform(resource: Resource, quizData: QuizData, areAnswersBlocked?: boolean): number {\r\n let submissionsCounter = quizData.submissionsCounter;\r\n\r\n if (!resource.quiz.maxSubmissions)\r\n return ++submissionsCounter;\r\n\r\n if (quizData.isSubmitted || areAnswersBlocked)\r\n return submissionsCounter || ++submissionsCounter;\r\n\r\n return submissionsCounter < resource.quiz.maxSubmissions ? ++submissionsCounter : submissionsCounter;\r\n }\r\n}","import { Pipe, PipeTransform } from '@angular/core';\r\n\r\n@Pipe({\r\n standalone: false,\r\n name: 'ellipsis'\r\n})\r\nexport class EllipsisPipe implements PipeTransform {\r\n transform(value: string, element: HTMLElement, numberOfRows: number = 1): string {\r\n if (!value || !element || numberOfRows < 1)\r\n return '';\r\n\r\n if (!element.clientWidth)\r\n return value;\r\n\r\n const style: CSSStyleDeclaration = window.getComputedStyle(element);\r\n const fontSize: number = parseFloat(style.fontSize);\r\n const fontFamily: string = style.fontFamily;\r\n const availableWidth: number = element.clientWidth - this.getElementWidth(fontSize, fontFamily, '...');\r\n\r\n return numberOfRows > 1 ?\r\n this.handleMultiRows(value, fontSize, fontFamily, numberOfRows, element.clientWidth, availableWidth)\r\n :\r\n this.ellipsis(value, fontSize, fontFamily, availableWidth);\r\n }\r\n\r\n private handleMultiRows(value: string, fontSize: number, fontFamily: string, numberOfRows: number, maxRowWidth: number, availableWidth: number) {\r\n const words: string[] = value.split(' ');\r\n let text: string = '';\r\n let rowWidthCounter: number = 0;\r\n let rowsCounter: number = 1\r\n let isLastRow: boolean = false\r\n\r\n for (let index = 0; index < words.length; index++) {\r\n const word = words[index];\r\n const wordWidth = this.getElementWidth(fontSize, fontFamily, word) + this.getElementWidth(fontSize, fontFamily, ' ');\r\n\r\n if ((rowWidthCounter + wordWidth >= maxRowWidth)) {\r\n rowsCounter = rowsCounter + 1;\r\n rowWidthCounter = 0;\r\n }\r\n\r\n isLastRow = rowsCounter === numberOfRows;\r\n\r\n if ((Math.ceil(rowWidthCounter + wordWidth) < maxRowWidth) && !isLastRow) {\r\n rowWidthCounter += wordWidth;\r\n text += words[index] + ' ';\r\n }\r\n\r\n if (isLastRow && index < words.length) {\r\n const leftText = words.slice(index).join(' ');\r\n text += this.ellipsis(leftText, fontSize, fontFamily, availableWidth);\r\n break;\r\n }\r\n }\r\n return text;\r\n }\r\n\r\n private ellipsis(text: string, fontSize: number, fontFamily: string, availableWidth: number): string {\r\n let totalWidth: number = 0;\r\n let newText: string = '';\r\n\r\n for (let index = 0; index < text.length; index++) {\r\n const char = text[index];\r\n const charWidth = this.getElementWidth(fontSize, fontFamily, char);\r\n\r\n totalWidth += charWidth;\r\n\r\n if (Math.ceil(totalWidth) >= availableWidth)\r\n return newText + '...';\r\n\r\n newText += char;\r\n }\r\n\r\n return newText;\r\n }\r\n\r\n private getElementWidth(fontSize: number, fontFamily: string, element: string): number {\r\n const canvas: HTMLCanvasElement = document.createElement('canvas');\r\n const context: CanvasRenderingContext2D = canvas.getContext('2d');\r\n context.font = `${fontSize}px ${fontFamily}`;\r\n const metrics: TextMetrics = context.measureText(element);\r\n\r\n return metrics.width;\r\n }\r\n}","import { Pipe, PipeTransform } from '@angular/core';\r\nimport { ModifiedResource } from 'herum-shared/herum-types';\r\n\r\n@Pipe({\r\n standalone: false,\r\n name: 'resourceSubscriptionToResource'\r\n})\r\nexport class ResourceSubscriptionToResourcePipe implements PipeTransform {\r\n transform(resourceSubscription: any, ...args: unknown[]): ModifiedResource {\r\n let resource: ModifiedResource = {\r\n positionInCollection: resourceSubscription.positionInCollection,\r\n description: resourceSubscription.resourcePreview.description,\r\n title: resourceSubscription.resourcePreview.title,\r\n resourceType: resourceSubscription.resourcePreview.resourceType,\r\n files: resourceSubscription.resourcePreview.files\r\n };\r\n\r\n return resource;\r\n }\r\n}","import { Pipe, PipeTransform } from '@angular/core';\r\nimport { ModifiedResource } from 'herum-shared/herum-types';\r\nimport { ResourceSubscription } from 'herum-shared/herum-types';\r\n\r\n@Pipe({\r\n standalone: false,\r\n name: 'resourceToResourceSubscription'\r\n})\r\nexport class ResourceToResourceSubscriptionPipe implements PipeTransform {\r\n\r\n transform(resource: ModifiedResource, ...args: unknown[]): ResourceSubscription {\r\n let resourceSubscription: ResourceSubscription = {\r\n subscriptionStatus: 0,\r\n positionInCollection: resource.positionInCollection,\r\n resourcePreview: {\r\n ...resource\r\n }\r\n };\r\n\r\n return resourceSubscription;\r\n }\r\n}","import { Pipe, PipeTransform } from '@angular/core';\r\nimport { DomSanitizer } from '@angular/platform-browser';\r\n\r\n@Pipe({\r\n standalone: false,\r\n name: 'safeHtml'\r\n})\r\nexport class SafeHtmlPipe implements PipeTransform {\r\n constructor(private sanitized: DomSanitizer) { }\r\n\r\n transform(value: any): any {\r\n return this.sanitized.bypassSecurityTrustHtml(value);\r\n }\r\n}","import { Pipe, PipeTransform } from '@angular/core';\r\nimport { DomSanitizer } from '@angular/platform-browser';\r\n\r\n@Pipe({\r\n standalone: false,\r\n name: 'safe'\r\n})\r\nexport class SafePipe implements PipeTransform {\r\n constructor(private sanitizer: DomSanitizer) { }\r\n\r\n transform(url) {\r\n return this.sanitizer.bypassSecurityTrustResourceUrl(url);\r\n }\r\n}","import { Pipe, PipeTransform } from '@angular/core';\r\nimport { SignUpField } from 'herum-shared/herum-types';\r\n\r\n@Pipe({\r\n standalone: false,\r\n name: 'stringArrayToSignUpFieldArray'\r\n})\r\nexport class StringArrayToSignUpFieldArrayPipe implements PipeTransform {\r\n\r\n transform(fields: string[] | null | undefined): SignUpField[] {\r\n if (!Array.isArray(fields)) return [];\r\n\r\n return fields.map((field) => ({\r\n field, \r\n showSeparator: false\r\n }));\r\n }\r\n}\r\n","import { Pipe, PipeTransform } from '@angular/core';\r\n\r\n@Pipe({\r\n name: 'toInteger',\r\n standalone: false\r\n})\r\nexport class ToIntegerPipe implements PipeTransform {\r\n\r\n transform(number: number): number {\r\n return Number.isInteger(number) ? number : Number(number.toFixed(0));\r\n }\r\n}","import { Pipe, PipeTransform } from '@angular/core';\r\nimport { signUpFormKeys } from 'herum-shared/constants';\r\nimport { IdentifiedEntity, SectionListItem, DbListItem } from 'herum-shared/herum-types';\r\nimport { User } from 'herum-shared/herum-types';\r\n\r\nconst userFieldsToValueFormatters = {\r\n [signUpFormKeys.sections]: { valueFormatter: (sections: IdentifiedEntity[]) => identifiedEntityToSectionListItem(sections) },\r\n [signUpFormKeys.sagahs]: { valueFormatter: (sagahs: IdentifiedEntity[]) => identifiedEntityToDbListItem(sagahs) },\r\n [signUpFormKeys.subjectAreas]: { valueFormatter: (subjectAreas: IdentifiedEntity[]) => identifiedEntityToDbListItem(subjectAreas) }\r\n};\r\n\r\nfunction identifiedEntityToDbListItem(items: IdentifiedEntity[]): DbListItem<string>[] {\r\n return items.map(item => ({ id: item.id, value: item.name }));\r\n}\r\n\r\nfunction identifiedEntityToSectionListItem(items: IdentifiedEntity[]): SectionListItem[] {\r\n return items.map(item => ({ id: item.id, section: item.name }));\r\n}\r\n\r\n@Pipe({\r\n standalone: false,\r\n name: 'userIdentifiedEntitiesToBackendModels'\r\n})\r\nexport class UserIdentifiedEntitiesToBackendModelsPipe implements PipeTransform {\r\n\r\n transform(user: User) {\r\n Object.keys(userFieldsToValueFormatters).forEach(key => {\r\n if (user[key])\r\n user[key] = userFieldsToValueFormatters[key].valueFormatter(user[key]);\r\n });\r\n\r\n return user;\r\n }\r\n}","import { ModuleWithProviders, NgModule } from '@angular/core';\r\nimport { SafePipe } from './safe.pipe';\r\nimport { CollectionSubscriptionToCollectionBasePipe } from './collection-subscription-to-collection-base.pipe';\r\nimport { CollectionToCollectionBasePipe } from './collection-to-collection-base.pipe';\r\nimport { SafeHtmlPipe } from './safe-html.pipe';\r\nimport { ResourceSubscriptionToResourcePipe } from './resource-subscription-to-resource.pipe';\r\nimport { ResourceToResourceSubscriptionPipe } from './resource-to-resource-subscription.pipe';\r\nimport { EllipsisPipe } from './ellipsis.pipe';\r\nimport { UserIdentifiedEntitiesToBackendModelsPipe } from './user-identified-entities-to-backend-models.pipe';\r\nimport { AnswerNotesToTextChangesPipe } from './answer-notes-to-text-changes.pipe';\r\nimport { StringArrayToSignUpFieldArrayPipe } from './sign-up-fields-to-sign-up-field-config.pipe';\r\nimport { ToIntegerPipe } from './to-integer.pipe';\r\nimport { DisplayedSubmissionsCounterPipe } from './displayed-submissions-counter-pipe';\r\n\r\n@NgModule({\r\n declarations: [\r\n SafePipe,\r\n CollectionSubscriptionToCollectionBasePipe,\r\n CollectionToCollectionBasePipe,\r\n SafeHtmlPipe,\r\n ResourceSubscriptionToResourcePipe,\r\n ResourceToResourceSubscriptionPipe,\r\n EllipsisPipe,\r\n UserIdentifiedEntitiesToBackendModelsPipe,\r\n AnswerNotesToTextChangesPipe,\r\n StringArrayToSignUpFieldArrayPipe,\r\n ToIntegerPipe,\r\n DisplayedSubmissionsCounterPipe,\r\n ],\r\n exports: [\r\n SafePipe,\r\n CollectionSubscriptionToCollectionBasePipe,\r\n CollectionToCollectionBasePipe,\r\n SafeHtmlPipe,\r\n ResourceSubscriptionToResourcePipe,\r\n ResourceToResourceSubscriptionPipe,\r\n EllipsisPipe,\r\n UserIdentifiedEntitiesToBackendModelsPipe,\r\n AnswerNotesToTextChangesPipe,\r\n StringArrayToSignUpFieldArrayPipe,\r\n ToIntegerPipe,\r\n DisplayedSubmissionsCounterPipe,\r\n ],\r\n providers: [\r\n SafePipe,\r\n CollectionSubscriptionToCollectionBasePipe,\r\n CollectionToCollectionBasePipe,\r\n SafeHtmlPipe,\r\n ResourceSubscriptionToResourcePipe,\r\n ResourceToResourceSubscriptionPipe,\r\n EllipsisPipe,\r\n UserIdentifiedEntitiesToBackendModelsPipe,\r\n AnswerNotesToTextChangesPipe,\r\n StringArrayToSignUpFieldArrayPipe,\r\n ToIntegerPipe,\r\n DisplayedSubmissionsCounterPipe,\r\n ]\r\n})\r\nexport class PipesModule { }","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;MAQa,4BAA4B,CAAA;AAEvC,IAAA,SAAS,CAAC,WAAyB,EAAA;QACjC,OAAO,WAAW,EAAE,GAAG,CAAC,UAAU,KACjC;YACC,IAAI,EAAE,UAAU,CAAC,IAAI;YACrB,YAAY,EAAE,UAAU,CAAC,YAAY;YACrC,EAAE,EAAE,UAAU,CAAC,EAAE;YACjB,IAAI,EAAE,UAAU,CAAC,IAAI;YACrB,SAAS,EAAE,UAAU,CAAC,SAAS;YAC/B,WAAW,EAAE,UAAU,CAAC,UAAU;YAClC,SAAS,EAAE,UAAU,CAAC,QAAQ;YAC9B,WAAW,EAAE,UAAU,CAAC;AACzB,SAAA,CAAC;AAEC,aAAA,IAAI,CAAC,CAAC,CAAC,EAAE,CAAC,KAAK,IAAI,IAAI,CAAC,CAAC,CAAC,WAAW,CAAC,CAAC,OAAO,EAAE,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