@local-civics/mgmt-ui 0.1.231 → 0.1.232
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/dist/index.d.ts +134 -1
- package/dist/index.js +669 -343
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +669 -345
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -879,6 +879,38 @@ interface SubmissionItem {
|
|
|
879
879
|
pathwayId?: string;
|
|
880
880
|
}
|
|
881
881
|
|
|
882
|
+
/**
|
|
883
|
+
* LeaveCommentStudentOption
|
|
884
|
+
*/
|
|
885
|
+
type LeaveCommentStudentOption = {
|
|
886
|
+
userId: string;
|
|
887
|
+
name: string;
|
|
888
|
+
};
|
|
889
|
+
/**
|
|
890
|
+
* LeaveCommentBadgeOption
|
|
891
|
+
*/
|
|
892
|
+
type LeaveCommentBadgeOption = {
|
|
893
|
+
badgeId: string;
|
|
894
|
+
displayName: string;
|
|
895
|
+
};
|
|
896
|
+
/**
|
|
897
|
+
* LeaveCommentLessonOption
|
|
898
|
+
*/
|
|
899
|
+
type LeaveCommentLessonOption = {
|
|
900
|
+
lessonId: string;
|
|
901
|
+
displayName: string;
|
|
902
|
+
};
|
|
903
|
+
/**
|
|
904
|
+
* LeaveCommentPayload
|
|
905
|
+
*/
|
|
906
|
+
type LeaveCommentPayload = {
|
|
907
|
+
userId: string;
|
|
908
|
+
commentText: string;
|
|
909
|
+
requireValidation: boolean;
|
|
910
|
+
badgeId?: string;
|
|
911
|
+
lessonId?: string;
|
|
912
|
+
};
|
|
913
|
+
|
|
882
914
|
/**
|
|
883
915
|
* FileLockerUserItem
|
|
884
916
|
*/
|
|
@@ -926,6 +958,7 @@ type FileLockerProps = {
|
|
|
926
958
|
onBadgeClick?: (badgeId: string) => void;
|
|
927
959
|
onLessonClick?: (lessonId: string) => void;
|
|
928
960
|
onPathwayClick?: (pathwayId: string) => void;
|
|
961
|
+
onComment?: (comment: LeaveCommentPayload) => void;
|
|
929
962
|
};
|
|
930
963
|
/**
|
|
931
964
|
* FileLocker
|
|
@@ -934,4 +967,104 @@ type FileLockerProps = {
|
|
|
934
967
|
*/
|
|
935
968
|
declare const FileLocker: (props: FileLockerProps) => JSX.Element;
|
|
936
969
|
|
|
937
|
-
|
|
970
|
+
/**
|
|
971
|
+
* CommentCenterClass
|
|
972
|
+
*/
|
|
973
|
+
type CommentCenterClass = {
|
|
974
|
+
classId: string;
|
|
975
|
+
name: string;
|
|
976
|
+
active: boolean;
|
|
977
|
+
};
|
|
978
|
+
/**
|
|
979
|
+
* CommentCenterItem
|
|
980
|
+
*/
|
|
981
|
+
type CommentCenterItem = {
|
|
982
|
+
commentId: string;
|
|
983
|
+
recipientId: string;
|
|
984
|
+
recipientName: string;
|
|
985
|
+
authorId: string;
|
|
986
|
+
authorName?: string;
|
|
987
|
+
badgeId?: string;
|
|
988
|
+
badgeName?: string;
|
|
989
|
+
lessonId?: string;
|
|
990
|
+
lessonName?: string;
|
|
991
|
+
commentText: string;
|
|
992
|
+
requireValidation: boolean;
|
|
993
|
+
resolvedAt?: string;
|
|
994
|
+
createdAt: string;
|
|
995
|
+
};
|
|
996
|
+
/**
|
|
997
|
+
* CommentCenterProps
|
|
998
|
+
*/
|
|
999
|
+
type CommentCenterProps = {
|
|
1000
|
+
loading: boolean;
|
|
1001
|
+
classes: CommentCenterClass[];
|
|
1002
|
+
classId: string;
|
|
1003
|
+
comments: CommentCenterItem[];
|
|
1004
|
+
students: LeaveCommentStudentOption[];
|
|
1005
|
+
badges: LeaveCommentBadgeOption[];
|
|
1006
|
+
lessons: LeaveCommentLessonOption[];
|
|
1007
|
+
onClassChange: (classId: string) => void;
|
|
1008
|
+
onResolve: (commentId: string) => void;
|
|
1009
|
+
onLeaveComment: (comment: LeaveCommentPayload) => void;
|
|
1010
|
+
};
|
|
1011
|
+
/**
|
|
1012
|
+
* CommentCenter. Org-wide view of every comment left across the organization - grouped by student,
|
|
1013
|
+
* badge, or lesson via the same pill-tab selector and class dropdown FileLocker uses - with the
|
|
1014
|
+
* ability to resolve any comment that requires validation (see Comment.RequireValidation on the
|
|
1015
|
+
* backend) and to leave a brand new comment for any student via LeaveCommentModal.
|
|
1016
|
+
* @param props
|
|
1017
|
+
* @constructor
|
|
1018
|
+
*/
|
|
1019
|
+
declare const CommentCenter: (props: CommentCenterProps) => JSX.Element;
|
|
1020
|
+
|
|
1021
|
+
/**
|
|
1022
|
+
* ValidationCenterClass
|
|
1023
|
+
*/
|
|
1024
|
+
type ValidationCenterClass = {
|
|
1025
|
+
classId: string;
|
|
1026
|
+
name: string;
|
|
1027
|
+
active: boolean;
|
|
1028
|
+
};
|
|
1029
|
+
/**
|
|
1030
|
+
* ValidationCenterBadge
|
|
1031
|
+
*/
|
|
1032
|
+
type ValidationCenterBadge = {
|
|
1033
|
+
badgeId: string;
|
|
1034
|
+
displayName: string;
|
|
1035
|
+
};
|
|
1036
|
+
/**
|
|
1037
|
+
* ValidationCenterStudent
|
|
1038
|
+
*/
|
|
1039
|
+
type ValidationCenterStudent = {
|
|
1040
|
+
userId: string;
|
|
1041
|
+
name: string;
|
|
1042
|
+
avatar?: string;
|
|
1043
|
+
hasCredit: boolean;
|
|
1044
|
+
};
|
|
1045
|
+
/**
|
|
1046
|
+
* ValidationCenterProps
|
|
1047
|
+
*/
|
|
1048
|
+
type ValidationCenterProps = {
|
|
1049
|
+
loading: boolean;
|
|
1050
|
+
classes: ValidationCenterClass[];
|
|
1051
|
+
classId: string;
|
|
1052
|
+
badges: ValidationCenterBadge[];
|
|
1053
|
+
badgeId: string;
|
|
1054
|
+
students: ValidationCenterStudent[];
|
|
1055
|
+
onClassChange: (classId: string) => void;
|
|
1056
|
+
onBadgeChange: (badgeId: string) => void;
|
|
1057
|
+
onSubmit: (userIds: string[]) => void;
|
|
1058
|
+
};
|
|
1059
|
+
/**
|
|
1060
|
+
* ValidationCenter. Lets an educator directly credit one or more students for a badge - superseding
|
|
1061
|
+
* lesson/criteria requirements and any outstanding comments, exactly like study's
|
|
1062
|
+
* BadgeActivity.Validate() (used via the bulk :validate endpoint). A student who already has credit
|
|
1063
|
+
* shows a checkmark instead of a checkbox, since re-validating an already-finished badge is a no-op
|
|
1064
|
+
* on the backend (Validate guards on FinishedAt != nil just like Submit).
|
|
1065
|
+
* @param props
|
|
1066
|
+
* @constructor
|
|
1067
|
+
*/
|
|
1068
|
+
declare const ValidationCenter: (props: ValidationCenterProps) => JSX.Element;
|
|
1069
|
+
|
|
1070
|
+
export { AccountItem, AdminProvider, AdminProviderProps, App, AppProps, Badge, BadgeClass, BadgeItem, BadgeProps, BadgeUserItem, Badges, BadgesProps, Class, ClassItem, ClassProps, Classes, ClassesProps, CommentCenter, CommentCenterClass, CommentCenterItem, CommentCenterProps, Dashboard, DashboardClass, DashboardProps, FileLocker, FileLockerClass, FileLockerProps, FileLockerUserItem, GettingStarted, GettingStartedProps, Home, HomeProps, Lesson, LessonClass, LessonItem, LessonProps, LessonUserItem, Lessons, LessonsProps, MemberItem, Navbar, NavbarProps, NewTrialRegistration, Organization, OrganizationProps, Pathway, PathwayClass, PathwayProps, PathwayUserItem, Pathways, PathwaysItem, PathwaysProps, People, PeopleProps, StartAnonymousLesson, StartAnonymousLessonProps, Student, StudentProps, SwitchAccount, SwitchAccountProps, TrialHome, TrialHomeProps, TrialRegistration, TrialRegistrationProps, UserItem, ValidationCenter, ValidationCenterBadge, ValidationCenterClass, ValidationCenterProps, ValidationCenterStudent };
|