@studious-lms/server 1.8.0 → 1.9.0

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 (71) hide show
  1. package/dist/middleware/security.d.ts.map +1 -1
  2. package/dist/middleware/security.js +3 -3
  3. package/dist/middleware/security.js.map +1 -1
  4. package/dist/models/agenda.d.ts +2 -2
  5. package/dist/models/announcement.d.ts +2 -2
  6. package/dist/models/assignment.d.ts +33 -33
  7. package/dist/models/class.d.ts +2 -2
  8. package/dist/models/cloudStorage.d.ts +14 -1
  9. package/dist/models/cloudStorage.d.ts.map +1 -1
  10. package/dist/models/cloudStorage.js +123 -3
  11. package/dist/models/cloudStorage.js.map +1 -1
  12. package/dist/models/event.d.ts +3 -3
  13. package/dist/models/file.d.ts +27 -26
  14. package/dist/models/file.d.ts.map +1 -1
  15. package/dist/models/file.js +4 -39
  16. package/dist/models/file.js.map +1 -1
  17. package/dist/models/labChat.d.ts +6 -6
  18. package/dist/models/section.d.ts +1 -1
  19. package/dist/routers/_app.d.ts +354 -100
  20. package/dist/routers/_app.d.ts.map +1 -1
  21. package/dist/routers/_app.js +4 -2
  22. package/dist/routers/_app.js.map +1 -1
  23. package/dist/routers/agenda.d.ts +2 -2
  24. package/dist/routers/assignment.d.ts +31 -31
  25. package/dist/routers/class.d.ts +5 -5
  26. package/dist/routers/event.d.ts +2 -2
  27. package/dist/routers/file.d.ts +2 -2
  28. package/dist/routers/folder.d.ts +24 -0
  29. package/dist/routers/folder.d.ts.map +1 -1
  30. package/dist/routers/folder.js +27 -5
  31. package/dist/routers/folder.js.map +1 -1
  32. package/dist/routers/labChat.d.ts +2 -2
  33. package/dist/routers/newtonChat.d.ts +1 -1
  34. package/dist/routers/permissions.d.ts +120 -0
  35. package/dist/routers/permissions.d.ts.map +1 -0
  36. package/dist/routers/permissions.js +50 -0
  37. package/dist/routers/permissions.js.map +1 -0
  38. package/dist/routers/tag.d.ts +5 -5
  39. package/dist/services/agenda.d.ts +2 -2
  40. package/dist/services/assignment.d.ts +31 -31
  41. package/dist/services/class.d.ts +5 -5
  42. package/dist/services/class.js +3 -3
  43. package/dist/services/class.js.map +1 -1
  44. package/dist/services/event.d.ts +2 -2
  45. package/dist/services/file.d.ts +22 -5
  46. package/dist/services/file.d.ts.map +1 -1
  47. package/dist/services/file.js +81 -45
  48. package/dist/services/file.js.map +1 -1
  49. package/dist/services/folder.d.ts +97 -2
  50. package/dist/services/folder.d.ts.map +1 -1
  51. package/dist/services/folder.js +158 -87
  52. package/dist/services/folder.js.map +1 -1
  53. package/dist/services/labChat.d.ts +2 -2
  54. package/dist/services/permissions.d.ts +188 -0
  55. package/dist/services/permissions.d.ts.map +1 -0
  56. package/dist/services/permissions.js +661 -0
  57. package/dist/services/permissions.js.map +1 -0
  58. package/package.json +1 -1
  59. package/prisma/migrations/20260510170000_add_folder_permissions/migration.sql +93 -0
  60. package/prisma/schema.prisma +74 -0
  61. package/src/middleware/security.ts +1 -1
  62. package/src/models/cloudStorage.ts +134 -1
  63. package/src/models/file.ts +2 -37
  64. package/src/routers/_app.ts +2 -0
  65. package/src/routers/folder.ts +32 -2
  66. package/src/routers/permissions.ts +71 -0
  67. package/src/services/class.ts +1 -1
  68. package/src/services/file.ts +76 -47
  69. package/src/services/folder.ts +180 -91
  70. package/src/services/permissions.ts +778 -0
  71. package/tests/unit/services/permissions.test.ts +463 -0
@@ -682,8 +682,8 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
682
682
  type: import(".prisma/client").$Enums.AssignmentType;
683
683
  id: string;
684
684
  createdAt: Date | null;
685
- modifiedAt: Date | null;
686
685
  classId: string;
686
+ modifiedAt: Date | null;
687
687
  title: string;
688
688
  instructions: string;
689
689
  dueDate: Date;
@@ -725,8 +725,8 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
725
725
  type: import(".prisma/client").$Enums.AssignmentType;
726
726
  id: string;
727
727
  createdAt: Date | null;
728
- modifiedAt: Date | null;
729
728
  classId: string;
729
+ modifiedAt: Date | null;
730
730
  title: string;
731
731
  instructions: string;
732
732
  dueDate: Date;
@@ -768,8 +768,8 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
768
768
  type: import(".prisma/client").$Enums.AssignmentType;
769
769
  id: string;
770
770
  createdAt: Date | null;
771
- modifiedAt: Date | null;
772
771
  classId: string;
772
+ modifiedAt: Date | null;
773
773
  title: string;
774
774
  instructions: string;
775
775
  dueDate: Date;
@@ -802,8 +802,8 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
802
802
  type: import(".prisma/client").$Enums.AssignmentType;
803
803
  id: string;
804
804
  createdAt: Date | null;
805
- modifiedAt: Date | null;
806
805
  classId: string;
806
+ modifiedAt: Date | null;
807
807
  title: string;
808
808
  instructions: string;
809
809
  dueDate: Date;
@@ -840,8 +840,8 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
840
840
  type: import(".prisma/client").$Enums.AssignmentType;
841
841
  id: string;
842
842
  createdAt: Date | null;
843
- modifiedAt: Date | null;
844
843
  classId: string;
844
+ modifiedAt: Date | null;
845
845
  title: string;
846
846
  instructions: string;
847
847
  dueDate: Date;
@@ -1454,8 +1454,8 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
1454
1454
  type: import(".prisma/client").$Enums.AssignmentType;
1455
1455
  id: string;
1456
1456
  createdAt: Date | null;
1457
- modifiedAt: Date | null;
1458
1457
  classId: string;
1458
+ modifiedAt: Date | null;
1459
1459
  title: string;
1460
1460
  instructions: string;
1461
1461
  dueDate: Date;
@@ -1498,8 +1498,8 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
1498
1498
  type: import(".prisma/client").$Enums.AssignmentType;
1499
1499
  id: string;
1500
1500
  createdAt: Date | null;
1501
- modifiedAt: Date | null;
1502
1501
  classId: string;
1502
+ modifiedAt: Date | null;
1503
1503
  title: string;
1504
1504
  instructions: string;
1505
1505
  dueDate: Date;
@@ -1593,8 +1593,8 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
1593
1593
  type: import(".prisma/client").$Enums.AssignmentType;
1594
1594
  id: string;
1595
1595
  createdAt: Date | null;
1596
- modifiedAt: Date | null;
1597
1596
  classId: string;
1597
+ modifiedAt: Date | null;
1598
1598
  title: string;
1599
1599
  instructions: string;
1600
1600
  dueDate: Date;
@@ -1702,6 +1702,7 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
1702
1702
  name: string;
1703
1703
  id: string;
1704
1704
  userId: string | null;
1705
+ folderId: string | null;
1705
1706
  size: number | null;
1706
1707
  uploadedAt: Date | null;
1707
1708
  uploadStatus: import(".prisma/client").$Enums.UploadStatus;
@@ -1718,7 +1719,6 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
1718
1719
  submissionId: string | null;
1719
1720
  annotationId: string | null;
1720
1721
  classDraftId: string | null;
1721
- folderId: string | null;
1722
1722
  conversationId: string | null;
1723
1723
  messageId: string | null;
1724
1724
  announcementId: string | null;
@@ -1800,8 +1800,8 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
1800
1800
  type: import(".prisma/client").$Enums.AssignmentType;
1801
1801
  id: string;
1802
1802
  createdAt: Date | null;
1803
- modifiedAt: Date | null;
1804
1803
  classId: string;
1804
+ modifiedAt: Date | null;
1805
1805
  title: string;
1806
1806
  instructions: string;
1807
1807
  dueDate: Date;
@@ -1859,8 +1859,8 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
1859
1859
  type: import(".prisma/client").$Enums.AssignmentType;
1860
1860
  id: string;
1861
1861
  createdAt: Date | null;
1862
- modifiedAt: Date | null;
1863
1862
  classId: string;
1863
+ modifiedAt: Date | null;
1864
1864
  title: string;
1865
1865
  instructions: string;
1866
1866
  dueDate: Date;
@@ -1887,6 +1887,7 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
1887
1887
  name: string;
1888
1888
  id: string;
1889
1889
  userId: string | null;
1890
+ folderId: string | null;
1890
1891
  size: number | null;
1891
1892
  uploadedAt: Date | null;
1892
1893
  uploadStatus: import(".prisma/client").$Enums.UploadStatus;
@@ -1903,7 +1904,6 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
1903
1904
  submissionId: string | null;
1904
1905
  annotationId: string | null;
1905
1906
  classDraftId: string | null;
1906
- folderId: string | null;
1907
1907
  conversationId: string | null;
1908
1908
  messageId: string | null;
1909
1909
  announcementId: string | null;
@@ -1915,6 +1915,7 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
1915
1915
  name: string;
1916
1916
  id: string;
1917
1917
  userId: string | null;
1918
+ folderId: string | null;
1918
1919
  size: number | null;
1919
1920
  uploadedAt: Date | null;
1920
1921
  uploadStatus: import(".prisma/client").$Enums.UploadStatus;
@@ -1931,7 +1932,6 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
1931
1932
  submissionId: string | null;
1932
1933
  annotationId: string | null;
1933
1934
  classDraftId: string | null;
1934
- folderId: string | null;
1935
1935
  conversationId: string | null;
1936
1936
  messageId: string | null;
1937
1937
  announcementId: string | null;
@@ -1994,8 +1994,8 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
1994
1994
  type: import(".prisma/client").$Enums.AssignmentType;
1995
1995
  id: string;
1996
1996
  createdAt: Date | null;
1997
- modifiedAt: Date | null;
1998
1997
  classId: string;
1998
+ modifiedAt: Date | null;
1999
1999
  title: string;
2000
2000
  instructions: string;
2001
2001
  dueDate: Date;
@@ -2022,6 +2022,7 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
2022
2022
  name: string;
2023
2023
  id: string;
2024
2024
  userId: string | null;
2025
+ folderId: string | null;
2025
2026
  size: number | null;
2026
2027
  uploadedAt: Date | null;
2027
2028
  uploadStatus: import(".prisma/client").$Enums.UploadStatus;
@@ -2038,7 +2039,6 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
2038
2039
  submissionId: string | null;
2039
2040
  annotationId: string | null;
2040
2041
  classDraftId: string | null;
2041
- folderId: string | null;
2042
2042
  conversationId: string | null;
2043
2043
  messageId: string | null;
2044
2044
  announcementId: string | null;
@@ -2050,6 +2050,7 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
2050
2050
  name: string;
2051
2051
  id: string;
2052
2052
  userId: string | null;
2053
+ folderId: string | null;
2053
2054
  size: number | null;
2054
2055
  uploadedAt: Date | null;
2055
2056
  uploadStatus: import(".prisma/client").$Enums.UploadStatus;
@@ -2066,7 +2067,6 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
2066
2067
  submissionId: string | null;
2067
2068
  annotationId: string | null;
2068
2069
  classDraftId: string | null;
2069
- folderId: string | null;
2070
2070
  conversationId: string | null;
2071
2071
  messageId: string | null;
2072
2072
  announcementId: string | null;
@@ -2146,8 +2146,8 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
2146
2146
  type: import(".prisma/client").$Enums.AssignmentType;
2147
2147
  id: string;
2148
2148
  createdAt: Date | null;
2149
- modifiedAt: Date | null;
2150
2149
  classId: string;
2150
+ modifiedAt: Date | null;
2151
2151
  title: string;
2152
2152
  instructions: string;
2153
2153
  dueDate: Date;
@@ -2174,6 +2174,7 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
2174
2174
  name: string;
2175
2175
  id: string;
2176
2176
  userId: string | null;
2177
+ folderId: string | null;
2177
2178
  size: number | null;
2178
2179
  uploadedAt: Date | null;
2179
2180
  uploadStatus: import(".prisma/client").$Enums.UploadStatus;
@@ -2190,7 +2191,6 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
2190
2191
  submissionId: string | null;
2191
2192
  annotationId: string | null;
2192
2193
  classDraftId: string | null;
2193
- folderId: string | null;
2194
2194
  conversationId: string | null;
2195
2195
  messageId: string | null;
2196
2196
  announcementId: string | null;
@@ -2250,8 +2250,8 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
2250
2250
  type: import(".prisma/client").$Enums.AssignmentType;
2251
2251
  id: string;
2252
2252
  createdAt: Date | null;
2253
- modifiedAt: Date | null;
2254
2253
  classId: string;
2254
+ modifiedAt: Date | null;
2255
2255
  title: string;
2256
2256
  instructions: string;
2257
2257
  dueDate: Date;
@@ -2279,6 +2279,7 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
2279
2279
  name: string;
2280
2280
  id: string;
2281
2281
  userId: string | null;
2282
+ folderId: string | null;
2282
2283
  size: number | null;
2283
2284
  uploadedAt: Date | null;
2284
2285
  uploadStatus: import(".prisma/client").$Enums.UploadStatus;
@@ -2295,7 +2296,6 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
2295
2296
  submissionId: string | null;
2296
2297
  annotationId: string | null;
2297
2298
  classDraftId: string | null;
2298
- folderId: string | null;
2299
2299
  conversationId: string | null;
2300
2300
  messageId: string | null;
2301
2301
  announcementId: string | null;
@@ -2307,6 +2307,7 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
2307
2307
  name: string;
2308
2308
  id: string;
2309
2309
  userId: string | null;
2310
+ folderId: string | null;
2310
2311
  size: number | null;
2311
2312
  uploadedAt: Date | null;
2312
2313
  uploadStatus: import(".prisma/client").$Enums.UploadStatus;
@@ -2323,7 +2324,6 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
2323
2324
  submissionId: string | null;
2324
2325
  annotationId: string | null;
2325
2326
  classDraftId: string | null;
2326
- folderId: string | null;
2327
2327
  conversationId: string | null;
2328
2328
  messageId: string | null;
2329
2329
  announcementId: string | null;
@@ -2625,8 +2625,8 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
2625
2625
  type: import(".prisma/client").$Enums.AssignmentType;
2626
2626
  id: string;
2627
2627
  createdAt: Date | null;
2628
- modifiedAt: Date | null;
2629
2628
  classId: string;
2629
+ modifiedAt: Date | null;
2630
2630
  title: string;
2631
2631
  instructions: string;
2632
2632
  dueDate: Date;
@@ -2654,6 +2654,7 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
2654
2654
  name: string;
2655
2655
  id: string;
2656
2656
  userId: string | null;
2657
+ folderId: string | null;
2657
2658
  size: number | null;
2658
2659
  uploadedAt: Date | null;
2659
2660
  uploadStatus: import(".prisma/client").$Enums.UploadStatus;
@@ -2670,7 +2671,6 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
2670
2671
  submissionId: string | null;
2671
2672
  annotationId: string | null;
2672
2673
  classDraftId: string | null;
2673
- folderId: string | null;
2674
2674
  conversationId: string | null;
2675
2675
  messageId: string | null;
2676
2676
  announcementId: string | null;
@@ -2682,6 +2682,7 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
2682
2682
  name: string;
2683
2683
  id: string;
2684
2684
  userId: string | null;
2685
+ folderId: string | null;
2685
2686
  size: number | null;
2686
2687
  uploadedAt: Date | null;
2687
2688
  uploadStatus: import(".prisma/client").$Enums.UploadStatus;
@@ -2698,7 +2699,6 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
2698
2699
  submissionId: string | null;
2699
2700
  annotationId: string | null;
2700
2701
  classDraftId: string | null;
2701
- folderId: string | null;
2702
2702
  conversationId: string | null;
2703
2703
  messageId: string | null;
2704
2704
  announcementId: string | null;
@@ -2711,6 +2711,7 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
2711
2711
  name: string;
2712
2712
  id: string;
2713
2713
  userId: string | null;
2714
+ folderId: string | null;
2714
2715
  size: number | null;
2715
2716
  uploadedAt: Date | null;
2716
2717
  uploadStatus: import(".prisma/client").$Enums.UploadStatus;
@@ -2727,7 +2728,6 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
2727
2728
  submissionId: string | null;
2728
2729
  annotationId: string | null;
2729
2730
  classDraftId: string | null;
2730
- folderId: string | null;
2731
2731
  conversationId: string | null;
2732
2732
  messageId: string | null;
2733
2733
  announcementId: string | null;
@@ -2739,6 +2739,7 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
2739
2739
  name: string;
2740
2740
  id: string;
2741
2741
  userId: string | null;
2742
+ folderId: string | null;
2742
2743
  size: number | null;
2743
2744
  uploadedAt: Date | null;
2744
2745
  uploadStatus: import(".prisma/client").$Enums.UploadStatus;
@@ -2755,7 +2756,6 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
2755
2756
  submissionId: string | null;
2756
2757
  annotationId: string | null;
2757
2758
  classDraftId: string | null;
2758
- folderId: string | null;
2759
2759
  conversationId: string | null;
2760
2760
  messageId: string | null;
2761
2761
  announcementId: string | null;
@@ -2822,8 +2822,8 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
2822
2822
  type: import(".prisma/client").$Enums.AssignmentType;
2823
2823
  id: string;
2824
2824
  createdAt: Date | null;
2825
- modifiedAt: Date | null;
2826
2825
  classId: string;
2826
+ modifiedAt: Date | null;
2827
2827
  title: string;
2828
2828
  instructions: string;
2829
2829
  dueDate: Date;
@@ -2879,8 +2879,8 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
2879
2879
  type: import(".prisma/client").$Enums.AssignmentType;
2880
2880
  id: string;
2881
2881
  createdAt: Date | null;
2882
- modifiedAt: Date | null;
2883
2882
  classId: string;
2883
+ modifiedAt: Date | null;
2884
2884
  title: string;
2885
2885
  instructions: string;
2886
2886
  dueDate: Date;
@@ -2975,6 +2975,7 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
2975
2975
  name: string;
2976
2976
  id: string;
2977
2977
  userId: string | null;
2978
+ folderId: string | null;
2978
2979
  size: number | null;
2979
2980
  uploadedAt: Date | null;
2980
2981
  uploadStatus: import(".prisma/client").$Enums.UploadStatus;
@@ -2991,7 +2992,6 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
2991
2992
  submissionId: string | null;
2992
2993
  annotationId: string | null;
2993
2994
  classDraftId: string | null;
2994
- folderId: string | null;
2995
2995
  conversationId: string | null;
2996
2996
  messageId: string | null;
2997
2997
  announcementId: string | null;
@@ -3012,8 +3012,8 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
3012
3012
  type: import(".prisma/client").$Enums.AssignmentType;
3013
3013
  id: string;
3014
3014
  createdAt: Date | null;
3015
- modifiedAt: Date | null;
3016
3015
  classId: string;
3016
+ modifiedAt: Date | null;
3017
3017
  title: string;
3018
3018
  instructions: string;
3019
3019
  dueDate: Date;
@@ -3071,6 +3071,7 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
3071
3071
  name: string;
3072
3072
  id: string;
3073
3073
  userId: string | null;
3074
+ folderId: string | null;
3074
3075
  size: number | null;
3075
3076
  uploadedAt: Date | null;
3076
3077
  uploadStatus: import(".prisma/client").$Enums.UploadStatus;
@@ -3087,7 +3088,6 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
3087
3088
  submissionId: string | null;
3088
3089
  annotationId: string | null;
3089
3090
  classDraftId: string | null;
3090
- folderId: string | null;
3091
3091
  conversationId: string | null;
3092
3092
  messageId: string | null;
3093
3093
  announcementId: string | null;
@@ -3108,8 +3108,8 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
3108
3108
  type: import(".prisma/client").$Enums.AssignmentType;
3109
3109
  id: string;
3110
3110
  createdAt: Date | null;
3111
- modifiedAt: Date | null;
3112
3111
  classId: string;
3112
+ modifiedAt: Date | null;
3113
3113
  title: string;
3114
3114
  instructions: string;
3115
3115
  dueDate: Date;
@@ -3168,6 +3168,7 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
3168
3168
  name: string;
3169
3169
  id: string;
3170
3170
  userId: string | null;
3171
+ folderId: string | null;
3171
3172
  size: number | null;
3172
3173
  uploadedAt: Date | null;
3173
3174
  uploadStatus: import(".prisma/client").$Enums.UploadStatus;
@@ -3184,7 +3185,6 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
3184
3185
  submissionId: string | null;
3185
3186
  annotationId: string | null;
3186
3187
  classDraftId: string | null;
3187
- folderId: string | null;
3188
3188
  conversationId: string | null;
3189
3189
  messageId: string | null;
3190
3190
  announcementId: string | null;
@@ -3205,8 +3205,8 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
3205
3205
  type: import(".prisma/client").$Enums.AssignmentType;
3206
3206
  id: string;
3207
3207
  createdAt: Date | null;
3208
- modifiedAt: Date | null;
3209
3208
  classId: string;
3209
+ modifiedAt: Date | null;
3210
3210
  title: string;
3211
3211
  instructions: string;
3212
3212
  dueDate: Date;
@@ -3264,6 +3264,7 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
3264
3264
  name: string;
3265
3265
  id: string;
3266
3266
  userId: string | null;
3267
+ folderId: string | null;
3267
3268
  size: number | null;
3268
3269
  uploadedAt: Date | null;
3269
3270
  uploadStatus: import(".prisma/client").$Enums.UploadStatus;
@@ -3280,7 +3281,6 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
3280
3281
  submissionId: string | null;
3281
3282
  annotationId: string | null;
3282
3283
  classDraftId: string | null;
3283
- folderId: string | null;
3284
3284
  conversationId: string | null;
3285
3285
  messageId: string | null;
3286
3286
  announcementId: string | null;
@@ -3301,8 +3301,8 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
3301
3301
  type: import(".prisma/client").$Enums.AssignmentType;
3302
3302
  id: string;
3303
3303
  createdAt: Date | null;
3304
- modifiedAt: Date | null;
3305
3304
  classId: string;
3305
+ modifiedAt: Date | null;
3306
3306
  title: string;
3307
3307
  instructions: string;
3308
3308
  dueDate: Date;
@@ -3923,8 +3923,8 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
3923
3923
  type: import(".prisma/client").$Enums.AssignmentType;
3924
3924
  id: string;
3925
3925
  createdAt: Date | null;
3926
- modifiedAt: Date | null;
3927
3926
  classId: string;
3927
+ modifiedAt: Date | null;
3928
3928
  title: string;
3929
3929
  instructions: string;
3930
3930
  dueDate: Date;
@@ -3972,8 +3972,8 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
3972
3972
  type: import(".prisma/client").$Enums.AssignmentType;
3973
3973
  id: string;
3974
3974
  createdAt: Date | null;
3975
- modifiedAt: Date | null;
3976
3975
  classId: string;
3976
+ modifiedAt: Date | null;
3977
3977
  title: string;
3978
3978
  instructions: string;
3979
3979
  dueDate: Date;
@@ -4188,8 +4188,8 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
4188
4188
  type: import(".prisma/client").$Enums.AssignmentType;
4189
4189
  id: string;
4190
4190
  createdAt: Date | null;
4191
- modifiedAt: Date | null;
4192
4191
  classId: string;
4192
+ modifiedAt: Date | null;
4193
4193
  title: string;
4194
4194
  instructions: string;
4195
4195
  dueDate: Date;
@@ -4236,8 +4236,8 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
4236
4236
  type: import(".prisma/client").$Enums.AssignmentType;
4237
4237
  id: string;
4238
4238
  createdAt: Date | null;
4239
- modifiedAt: Date | null;
4240
4239
  classId: string;
4240
+ modifiedAt: Date | null;
4241
4241
  title: string;
4242
4242
  instructions: string;
4243
4243
  dueDate: Date;
@@ -4316,6 +4316,7 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
4316
4316
  name: string;
4317
4317
  id: string;
4318
4318
  userId: string | null;
4319
+ folderId: string | null;
4319
4320
  size: number | null;
4320
4321
  uploadedAt: Date | null;
4321
4322
  uploadStatus: import(".prisma/client").$Enums.UploadStatus;
@@ -4332,7 +4333,6 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
4332
4333
  submissionId: string | null;
4333
4334
  annotationId: string | null;
4334
4335
  classDraftId: string | null;
4335
- folderId: string | null;
4336
4336
  conversationId: string | null;
4337
4337
  messageId: string | null;
4338
4338
  announcementId: string | null;
@@ -4356,6 +4356,7 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
4356
4356
  name: string;
4357
4357
  id: string;
4358
4358
  userId: string | null;
4359
+ folderId: string | null;
4359
4360
  size: number | null;
4360
4361
  uploadedAt: Date | null;
4361
4362
  uploadStatus: import(".prisma/client").$Enums.UploadStatus;
@@ -4372,7 +4373,6 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
4372
4373
  submissionId: string | null;
4373
4374
  annotationId: string | null;
4374
4375
  classDraftId: string | null;
4375
- folderId: string | null;
4376
4376
  conversationId: string | null;
4377
4377
  messageId: string | null;
4378
4378
  announcementId: string | null;
@@ -4420,6 +4420,8 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
4420
4420
  } | {
4421
4421
  userId: string;
4422
4422
  kind: "PERSONAL";
4423
+ } | {
4424
+ kind: "SHARED_WITH_ME";
4423
4425
  };
4424
4426
  };
4425
4427
  output: {
@@ -4465,6 +4467,22 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
4465
4467
  }[];
4466
4468
  canWrite: boolean;
4467
4469
  scope: import("../models/cloudStorage.js").CloudScope;
4470
+ displayRoot: {
4471
+ kind: "SHARED_WITH_ME";
4472
+ name: string;
4473
+ } | null;
4474
+ };
4475
+ meta: object;
4476
+ }>;
4477
+ listSharedWithMe: import("@trpc/server").TRPCQueryProcedure<{
4478
+ input: void;
4479
+ output: {
4480
+ folders: {
4481
+ id: string;
4482
+ name: string;
4483
+ color: string | null;
4484
+ }[];
4485
+ files: never[];
4468
4486
  };
4469
4487
  meta: object;
4470
4488
  }>;
@@ -4489,6 +4507,11 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
4489
4507
  color: string | null;
4490
4508
  section: string;
4491
4509
  }[];
4510
+ sharedWithMe: {
4511
+ kind: "SHARED_WITH_ME";
4512
+ folderCount: number;
4513
+ fileCount: number;
4514
+ };
4492
4515
  };
4493
4516
  meta: object;
4494
4517
  }>;
@@ -5313,8 +5336,8 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
5313
5336
  id: string;
5314
5337
  createdAt: Date;
5315
5338
  updatedAt: Date;
5316
- conversationId: string;
5317
5339
  classId: string;
5340
+ conversationId: string;
5318
5341
  title: string;
5319
5342
  createdById: string;
5320
5343
  };
@@ -5372,8 +5395,8 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
5372
5395
  id: string;
5373
5396
  createdAt: Date;
5374
5397
  updatedAt: Date;
5375
- conversationId: string;
5376
5398
  classId: string;
5399
+ conversationId: string;
5377
5400
  title: string;
5378
5401
  createdById: string;
5379
5402
  };
@@ -5497,8 +5520,8 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
5497
5520
  }, import("@trpc/server").TRPCDecorateCreateRouterOptions<{
5498
5521
  getTutorConversation: import("@trpc/server").TRPCQueryProcedure<{
5499
5522
  input: {
5500
- assignmentId: string;
5501
5523
  classId: string;
5524
+ assignmentId: string;
5502
5525
  };
5503
5526
  output: {
5504
5527
  conversationId: string;
@@ -7390,9 +7413,9 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
7390
7413
  }>;
7391
7414
  attach: import("@trpc/server").TRPCMutationProcedure<{
7392
7415
  input: {
7393
- target: "CLASS" | "USER" | "RUBRIC" | "BOUNDARY";
7394
- targetId: string;
7395
7416
  tagId: string;
7417
+ target: "USER" | "CLASS" | "RUBRIC" | "BOUNDARY";
7418
+ targetId: string;
7396
7419
  };
7397
7420
  output: {
7398
7421
  id: string;
@@ -7401,9 +7424,9 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
7401
7424
  }>;
7402
7425
  detach: import("@trpc/server").TRPCMutationProcedure<{
7403
7426
  input: {
7404
- target: "CLASS" | "USER" | "RUBRIC" | "BOUNDARY";
7405
- targetId: string;
7406
7427
  tagId: string;
7428
+ target: "USER" | "CLASS" | "RUBRIC" | "BOUNDARY";
7429
+ targetId: string;
7407
7430
  };
7408
7431
  output: {
7409
7432
  id: string;
@@ -7412,7 +7435,7 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
7412
7435
  }>;
7413
7436
  getAttached: import("@trpc/server").TRPCQueryProcedure<{
7414
7437
  input: {
7415
- target: "CLASS" | "USER" | "RUBRIC" | "BOUNDARY";
7438
+ target: "USER" | "CLASS" | "RUBRIC" | "BOUNDARY";
7416
7439
  targetId: string;
7417
7440
  };
7418
7441
  output: {
@@ -7427,6 +7450,110 @@ export declare const appRouter: import("@trpc/server").TRPCBuiltRouter<{
7427
7450
  meta: object;
7428
7451
  }>;
7429
7452
  }>>;
7453
+ permissions: import("@trpc/server").TRPCBuiltRouter<{
7454
+ ctx: import("../trpc.js").Context;
7455
+ meta: object;
7456
+ errorShape: {
7457
+ data: {
7458
+ zodError: import("zod").typeToFlattenedError<any, string> | null;
7459
+ prismaError: import("../utils/prismaErrorHandler.js").PrismaErrorInfo | null;
7460
+ code: import("@trpc/server").TRPC_ERROR_CODE_KEY;
7461
+ httpStatus: number;
7462
+ path?: string;
7463
+ stack?: string;
7464
+ };
7465
+ message: string;
7466
+ code: import("@trpc/server").TRPC_ERROR_CODE_NUMBER;
7467
+ };
7468
+ transformer: false;
7469
+ }, import("@trpc/server").TRPCDecorateCreateRouterOptions<{
7470
+ list: import("@trpc/server").TRPCQueryProcedure<{
7471
+ input: {
7472
+ folderId: string;
7473
+ };
7474
+ output: ({
7475
+ school: {
7476
+ name: string;
7477
+ id: string;
7478
+ } | null;
7479
+ user: {
7480
+ id: string;
7481
+ username: string;
7482
+ email: string;
7483
+ } | null;
7484
+ class: {
7485
+ name: string;
7486
+ id: string;
7487
+ section: string;
7488
+ } | null;
7489
+ department: {
7490
+ name: string;
7491
+ id: string;
7492
+ color: string | null;
7493
+ } | null;
7494
+ tag: {
7495
+ name: string;
7496
+ id: string;
7497
+ color: string;
7498
+ } | null;
7499
+ } & {
7500
+ level: import(".prisma/client").$Enums.PermissionLevel;
7501
+ id: string;
7502
+ createdAt: Date;
7503
+ schoolId: string | null;
7504
+ userId: string | null;
7505
+ departmentId: string | null;
7506
+ folderId: string;
7507
+ principalType: import(".prisma/client").$Enums.PermissionPrincipalType;
7508
+ tagId: string | null;
7509
+ classId: string | null;
7510
+ grantedById: string;
7511
+ })[];
7512
+ meta: object;
7513
+ }>;
7514
+ grant: import("@trpc/server").TRPCMutationProcedure<{
7515
+ input: {
7516
+ level: "READ" | "WRITE";
7517
+ folderId: string;
7518
+ principal: import("../services/permissions.js").PermissionPrincipalInput;
7519
+ };
7520
+ output: {
7521
+ level: import(".prisma/client").$Enums.PermissionLevel;
7522
+ id: string;
7523
+ createdAt: Date;
7524
+ schoolId: string | null;
7525
+ userId: string | null;
7526
+ departmentId: string | null;
7527
+ folderId: string;
7528
+ principalType: import(".prisma/client").$Enums.PermissionPrincipalType;
7529
+ tagId: string | null;
7530
+ classId: string | null;
7531
+ grantedById: string;
7532
+ };
7533
+ meta: object;
7534
+ }>;
7535
+ revoke: import("@trpc/server").TRPCMutationProcedure<{
7536
+ input: {
7537
+ permissionId: string;
7538
+ };
7539
+ output: {
7540
+ success: boolean;
7541
+ };
7542
+ meta: object;
7543
+ }>;
7544
+ listSharedWithMe: import("@trpc/server").TRPCQueryProcedure<{
7545
+ input: void;
7546
+ output: {
7547
+ folders: {
7548
+ id: string;
7549
+ name: string;
7550
+ color: string | null;
7551
+ }[];
7552
+ files: never[];
7553
+ };
7554
+ meta: object;
7555
+ }>;
7556
+ }>>;
7430
7557
  }>>;
7431
7558
  export type AppRouter = typeof appRouter;
7432
7559
  export type RouterInputs = inferRouterInputs<AppRouter>;
@@ -8114,8 +8241,8 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
8114
8241
  type: import(".prisma/client").$Enums.AssignmentType;
8115
8242
  id: string;
8116
8243
  createdAt: Date | null;
8117
- modifiedAt: Date | null;
8118
8244
  classId: string;
8245
+ modifiedAt: Date | null;
8119
8246
  title: string;
8120
8247
  instructions: string;
8121
8248
  dueDate: Date;
@@ -8157,8 +8284,8 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
8157
8284
  type: import(".prisma/client").$Enums.AssignmentType;
8158
8285
  id: string;
8159
8286
  createdAt: Date | null;
8160
- modifiedAt: Date | null;
8161
8287
  classId: string;
8288
+ modifiedAt: Date | null;
8162
8289
  title: string;
8163
8290
  instructions: string;
8164
8291
  dueDate: Date;
@@ -8200,8 +8327,8 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
8200
8327
  type: import(".prisma/client").$Enums.AssignmentType;
8201
8328
  id: string;
8202
8329
  createdAt: Date | null;
8203
- modifiedAt: Date | null;
8204
8330
  classId: string;
8331
+ modifiedAt: Date | null;
8205
8332
  title: string;
8206
8333
  instructions: string;
8207
8334
  dueDate: Date;
@@ -8234,8 +8361,8 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
8234
8361
  type: import(".prisma/client").$Enums.AssignmentType;
8235
8362
  id: string;
8236
8363
  createdAt: Date | null;
8237
- modifiedAt: Date | null;
8238
8364
  classId: string;
8365
+ modifiedAt: Date | null;
8239
8366
  title: string;
8240
8367
  instructions: string;
8241
8368
  dueDate: Date;
@@ -8272,8 +8399,8 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
8272
8399
  type: import(".prisma/client").$Enums.AssignmentType;
8273
8400
  id: string;
8274
8401
  createdAt: Date | null;
8275
- modifiedAt: Date | null;
8276
8402
  classId: string;
8403
+ modifiedAt: Date | null;
8277
8404
  title: string;
8278
8405
  instructions: string;
8279
8406
  dueDate: Date;
@@ -8886,8 +9013,8 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
8886
9013
  type: import(".prisma/client").$Enums.AssignmentType;
8887
9014
  id: string;
8888
9015
  createdAt: Date | null;
8889
- modifiedAt: Date | null;
8890
9016
  classId: string;
9017
+ modifiedAt: Date | null;
8891
9018
  title: string;
8892
9019
  instructions: string;
8893
9020
  dueDate: Date;
@@ -8930,8 +9057,8 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
8930
9057
  type: import(".prisma/client").$Enums.AssignmentType;
8931
9058
  id: string;
8932
9059
  createdAt: Date | null;
8933
- modifiedAt: Date | null;
8934
9060
  classId: string;
9061
+ modifiedAt: Date | null;
8935
9062
  title: string;
8936
9063
  instructions: string;
8937
9064
  dueDate: Date;
@@ -9025,8 +9152,8 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
9025
9152
  type: import(".prisma/client").$Enums.AssignmentType;
9026
9153
  id: string;
9027
9154
  createdAt: Date | null;
9028
- modifiedAt: Date | null;
9029
9155
  classId: string;
9156
+ modifiedAt: Date | null;
9030
9157
  title: string;
9031
9158
  instructions: string;
9032
9159
  dueDate: Date;
@@ -9134,6 +9261,7 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
9134
9261
  name: string;
9135
9262
  id: string;
9136
9263
  userId: string | null;
9264
+ folderId: string | null;
9137
9265
  size: number | null;
9138
9266
  uploadedAt: Date | null;
9139
9267
  uploadStatus: import(".prisma/client").$Enums.UploadStatus;
@@ -9150,7 +9278,6 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
9150
9278
  submissionId: string | null;
9151
9279
  annotationId: string | null;
9152
9280
  classDraftId: string | null;
9153
- folderId: string | null;
9154
9281
  conversationId: string | null;
9155
9282
  messageId: string | null;
9156
9283
  announcementId: string | null;
@@ -9232,8 +9359,8 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
9232
9359
  type: import(".prisma/client").$Enums.AssignmentType;
9233
9360
  id: string;
9234
9361
  createdAt: Date | null;
9235
- modifiedAt: Date | null;
9236
9362
  classId: string;
9363
+ modifiedAt: Date | null;
9237
9364
  title: string;
9238
9365
  instructions: string;
9239
9366
  dueDate: Date;
@@ -9291,8 +9418,8 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
9291
9418
  type: import(".prisma/client").$Enums.AssignmentType;
9292
9419
  id: string;
9293
9420
  createdAt: Date | null;
9294
- modifiedAt: Date | null;
9295
9421
  classId: string;
9422
+ modifiedAt: Date | null;
9296
9423
  title: string;
9297
9424
  instructions: string;
9298
9425
  dueDate: Date;
@@ -9319,6 +9446,7 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
9319
9446
  name: string;
9320
9447
  id: string;
9321
9448
  userId: string | null;
9449
+ folderId: string | null;
9322
9450
  size: number | null;
9323
9451
  uploadedAt: Date | null;
9324
9452
  uploadStatus: import(".prisma/client").$Enums.UploadStatus;
@@ -9335,7 +9463,6 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
9335
9463
  submissionId: string | null;
9336
9464
  annotationId: string | null;
9337
9465
  classDraftId: string | null;
9338
- folderId: string | null;
9339
9466
  conversationId: string | null;
9340
9467
  messageId: string | null;
9341
9468
  announcementId: string | null;
@@ -9347,6 +9474,7 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
9347
9474
  name: string;
9348
9475
  id: string;
9349
9476
  userId: string | null;
9477
+ folderId: string | null;
9350
9478
  size: number | null;
9351
9479
  uploadedAt: Date | null;
9352
9480
  uploadStatus: import(".prisma/client").$Enums.UploadStatus;
@@ -9363,7 +9491,6 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
9363
9491
  submissionId: string | null;
9364
9492
  annotationId: string | null;
9365
9493
  classDraftId: string | null;
9366
- folderId: string | null;
9367
9494
  conversationId: string | null;
9368
9495
  messageId: string | null;
9369
9496
  announcementId: string | null;
@@ -9426,8 +9553,8 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
9426
9553
  type: import(".prisma/client").$Enums.AssignmentType;
9427
9554
  id: string;
9428
9555
  createdAt: Date | null;
9429
- modifiedAt: Date | null;
9430
9556
  classId: string;
9557
+ modifiedAt: Date | null;
9431
9558
  title: string;
9432
9559
  instructions: string;
9433
9560
  dueDate: Date;
@@ -9454,6 +9581,7 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
9454
9581
  name: string;
9455
9582
  id: string;
9456
9583
  userId: string | null;
9584
+ folderId: string | null;
9457
9585
  size: number | null;
9458
9586
  uploadedAt: Date | null;
9459
9587
  uploadStatus: import(".prisma/client").$Enums.UploadStatus;
@@ -9470,7 +9598,6 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
9470
9598
  submissionId: string | null;
9471
9599
  annotationId: string | null;
9472
9600
  classDraftId: string | null;
9473
- folderId: string | null;
9474
9601
  conversationId: string | null;
9475
9602
  messageId: string | null;
9476
9603
  announcementId: string | null;
@@ -9482,6 +9609,7 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
9482
9609
  name: string;
9483
9610
  id: string;
9484
9611
  userId: string | null;
9612
+ folderId: string | null;
9485
9613
  size: number | null;
9486
9614
  uploadedAt: Date | null;
9487
9615
  uploadStatus: import(".prisma/client").$Enums.UploadStatus;
@@ -9498,7 +9626,6 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
9498
9626
  submissionId: string | null;
9499
9627
  annotationId: string | null;
9500
9628
  classDraftId: string | null;
9501
- folderId: string | null;
9502
9629
  conversationId: string | null;
9503
9630
  messageId: string | null;
9504
9631
  announcementId: string | null;
@@ -9578,8 +9705,8 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
9578
9705
  type: import(".prisma/client").$Enums.AssignmentType;
9579
9706
  id: string;
9580
9707
  createdAt: Date | null;
9581
- modifiedAt: Date | null;
9582
9708
  classId: string;
9709
+ modifiedAt: Date | null;
9583
9710
  title: string;
9584
9711
  instructions: string;
9585
9712
  dueDate: Date;
@@ -9606,6 +9733,7 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
9606
9733
  name: string;
9607
9734
  id: string;
9608
9735
  userId: string | null;
9736
+ folderId: string | null;
9609
9737
  size: number | null;
9610
9738
  uploadedAt: Date | null;
9611
9739
  uploadStatus: import(".prisma/client").$Enums.UploadStatus;
@@ -9622,7 +9750,6 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
9622
9750
  submissionId: string | null;
9623
9751
  annotationId: string | null;
9624
9752
  classDraftId: string | null;
9625
- folderId: string | null;
9626
9753
  conversationId: string | null;
9627
9754
  messageId: string | null;
9628
9755
  announcementId: string | null;
@@ -9682,8 +9809,8 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
9682
9809
  type: import(".prisma/client").$Enums.AssignmentType;
9683
9810
  id: string;
9684
9811
  createdAt: Date | null;
9685
- modifiedAt: Date | null;
9686
9812
  classId: string;
9813
+ modifiedAt: Date | null;
9687
9814
  title: string;
9688
9815
  instructions: string;
9689
9816
  dueDate: Date;
@@ -9711,6 +9838,7 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
9711
9838
  name: string;
9712
9839
  id: string;
9713
9840
  userId: string | null;
9841
+ folderId: string | null;
9714
9842
  size: number | null;
9715
9843
  uploadedAt: Date | null;
9716
9844
  uploadStatus: import(".prisma/client").$Enums.UploadStatus;
@@ -9727,7 +9855,6 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
9727
9855
  submissionId: string | null;
9728
9856
  annotationId: string | null;
9729
9857
  classDraftId: string | null;
9730
- folderId: string | null;
9731
9858
  conversationId: string | null;
9732
9859
  messageId: string | null;
9733
9860
  announcementId: string | null;
@@ -9739,6 +9866,7 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
9739
9866
  name: string;
9740
9867
  id: string;
9741
9868
  userId: string | null;
9869
+ folderId: string | null;
9742
9870
  size: number | null;
9743
9871
  uploadedAt: Date | null;
9744
9872
  uploadStatus: import(".prisma/client").$Enums.UploadStatus;
@@ -9755,7 +9883,6 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
9755
9883
  submissionId: string | null;
9756
9884
  annotationId: string | null;
9757
9885
  classDraftId: string | null;
9758
- folderId: string | null;
9759
9886
  conversationId: string | null;
9760
9887
  messageId: string | null;
9761
9888
  announcementId: string | null;
@@ -10057,8 +10184,8 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
10057
10184
  type: import(".prisma/client").$Enums.AssignmentType;
10058
10185
  id: string;
10059
10186
  createdAt: Date | null;
10060
- modifiedAt: Date | null;
10061
10187
  classId: string;
10188
+ modifiedAt: Date | null;
10062
10189
  title: string;
10063
10190
  instructions: string;
10064
10191
  dueDate: Date;
@@ -10086,6 +10213,7 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
10086
10213
  name: string;
10087
10214
  id: string;
10088
10215
  userId: string | null;
10216
+ folderId: string | null;
10089
10217
  size: number | null;
10090
10218
  uploadedAt: Date | null;
10091
10219
  uploadStatus: import(".prisma/client").$Enums.UploadStatus;
@@ -10102,7 +10230,6 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
10102
10230
  submissionId: string | null;
10103
10231
  annotationId: string | null;
10104
10232
  classDraftId: string | null;
10105
- folderId: string | null;
10106
10233
  conversationId: string | null;
10107
10234
  messageId: string | null;
10108
10235
  announcementId: string | null;
@@ -10114,6 +10241,7 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
10114
10241
  name: string;
10115
10242
  id: string;
10116
10243
  userId: string | null;
10244
+ folderId: string | null;
10117
10245
  size: number | null;
10118
10246
  uploadedAt: Date | null;
10119
10247
  uploadStatus: import(".prisma/client").$Enums.UploadStatus;
@@ -10130,7 +10258,6 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
10130
10258
  submissionId: string | null;
10131
10259
  annotationId: string | null;
10132
10260
  classDraftId: string | null;
10133
- folderId: string | null;
10134
10261
  conversationId: string | null;
10135
10262
  messageId: string | null;
10136
10263
  announcementId: string | null;
@@ -10143,6 +10270,7 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
10143
10270
  name: string;
10144
10271
  id: string;
10145
10272
  userId: string | null;
10273
+ folderId: string | null;
10146
10274
  size: number | null;
10147
10275
  uploadedAt: Date | null;
10148
10276
  uploadStatus: import(".prisma/client").$Enums.UploadStatus;
@@ -10159,7 +10287,6 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
10159
10287
  submissionId: string | null;
10160
10288
  annotationId: string | null;
10161
10289
  classDraftId: string | null;
10162
- folderId: string | null;
10163
10290
  conversationId: string | null;
10164
10291
  messageId: string | null;
10165
10292
  announcementId: string | null;
@@ -10171,6 +10298,7 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
10171
10298
  name: string;
10172
10299
  id: string;
10173
10300
  userId: string | null;
10301
+ folderId: string | null;
10174
10302
  size: number | null;
10175
10303
  uploadedAt: Date | null;
10176
10304
  uploadStatus: import(".prisma/client").$Enums.UploadStatus;
@@ -10187,7 +10315,6 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
10187
10315
  submissionId: string | null;
10188
10316
  annotationId: string | null;
10189
10317
  classDraftId: string | null;
10190
- folderId: string | null;
10191
10318
  conversationId: string | null;
10192
10319
  messageId: string | null;
10193
10320
  announcementId: string | null;
@@ -10254,8 +10381,8 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
10254
10381
  type: import(".prisma/client").$Enums.AssignmentType;
10255
10382
  id: string;
10256
10383
  createdAt: Date | null;
10257
- modifiedAt: Date | null;
10258
10384
  classId: string;
10385
+ modifiedAt: Date | null;
10259
10386
  title: string;
10260
10387
  instructions: string;
10261
10388
  dueDate: Date;
@@ -10311,8 +10438,8 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
10311
10438
  type: import(".prisma/client").$Enums.AssignmentType;
10312
10439
  id: string;
10313
10440
  createdAt: Date | null;
10314
- modifiedAt: Date | null;
10315
10441
  classId: string;
10442
+ modifiedAt: Date | null;
10316
10443
  title: string;
10317
10444
  instructions: string;
10318
10445
  dueDate: Date;
@@ -10407,6 +10534,7 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
10407
10534
  name: string;
10408
10535
  id: string;
10409
10536
  userId: string | null;
10537
+ folderId: string | null;
10410
10538
  size: number | null;
10411
10539
  uploadedAt: Date | null;
10412
10540
  uploadStatus: import(".prisma/client").$Enums.UploadStatus;
@@ -10423,7 +10551,6 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
10423
10551
  submissionId: string | null;
10424
10552
  annotationId: string | null;
10425
10553
  classDraftId: string | null;
10426
- folderId: string | null;
10427
10554
  conversationId: string | null;
10428
10555
  messageId: string | null;
10429
10556
  announcementId: string | null;
@@ -10444,8 +10571,8 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
10444
10571
  type: import(".prisma/client").$Enums.AssignmentType;
10445
10572
  id: string;
10446
10573
  createdAt: Date | null;
10447
- modifiedAt: Date | null;
10448
10574
  classId: string;
10575
+ modifiedAt: Date | null;
10449
10576
  title: string;
10450
10577
  instructions: string;
10451
10578
  dueDate: Date;
@@ -10503,6 +10630,7 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
10503
10630
  name: string;
10504
10631
  id: string;
10505
10632
  userId: string | null;
10633
+ folderId: string | null;
10506
10634
  size: number | null;
10507
10635
  uploadedAt: Date | null;
10508
10636
  uploadStatus: import(".prisma/client").$Enums.UploadStatus;
@@ -10519,7 +10647,6 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
10519
10647
  submissionId: string | null;
10520
10648
  annotationId: string | null;
10521
10649
  classDraftId: string | null;
10522
- folderId: string | null;
10523
10650
  conversationId: string | null;
10524
10651
  messageId: string | null;
10525
10652
  announcementId: string | null;
@@ -10540,8 +10667,8 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
10540
10667
  type: import(".prisma/client").$Enums.AssignmentType;
10541
10668
  id: string;
10542
10669
  createdAt: Date | null;
10543
- modifiedAt: Date | null;
10544
10670
  classId: string;
10671
+ modifiedAt: Date | null;
10545
10672
  title: string;
10546
10673
  instructions: string;
10547
10674
  dueDate: Date;
@@ -10600,6 +10727,7 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
10600
10727
  name: string;
10601
10728
  id: string;
10602
10729
  userId: string | null;
10730
+ folderId: string | null;
10603
10731
  size: number | null;
10604
10732
  uploadedAt: Date | null;
10605
10733
  uploadStatus: import(".prisma/client").$Enums.UploadStatus;
@@ -10616,7 +10744,6 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
10616
10744
  submissionId: string | null;
10617
10745
  annotationId: string | null;
10618
10746
  classDraftId: string | null;
10619
- folderId: string | null;
10620
10747
  conversationId: string | null;
10621
10748
  messageId: string | null;
10622
10749
  announcementId: string | null;
@@ -10637,8 +10764,8 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
10637
10764
  type: import(".prisma/client").$Enums.AssignmentType;
10638
10765
  id: string;
10639
10766
  createdAt: Date | null;
10640
- modifiedAt: Date | null;
10641
10767
  classId: string;
10768
+ modifiedAt: Date | null;
10642
10769
  title: string;
10643
10770
  instructions: string;
10644
10771
  dueDate: Date;
@@ -10696,6 +10823,7 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
10696
10823
  name: string;
10697
10824
  id: string;
10698
10825
  userId: string | null;
10826
+ folderId: string | null;
10699
10827
  size: number | null;
10700
10828
  uploadedAt: Date | null;
10701
10829
  uploadStatus: import(".prisma/client").$Enums.UploadStatus;
@@ -10712,7 +10840,6 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
10712
10840
  submissionId: string | null;
10713
10841
  annotationId: string | null;
10714
10842
  classDraftId: string | null;
10715
- folderId: string | null;
10716
10843
  conversationId: string | null;
10717
10844
  messageId: string | null;
10718
10845
  announcementId: string | null;
@@ -10733,8 +10860,8 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
10733
10860
  type: import(".prisma/client").$Enums.AssignmentType;
10734
10861
  id: string;
10735
10862
  createdAt: Date | null;
10736
- modifiedAt: Date | null;
10737
10863
  classId: string;
10864
+ modifiedAt: Date | null;
10738
10865
  title: string;
10739
10866
  instructions: string;
10740
10867
  dueDate: Date;
@@ -11355,8 +11482,8 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
11355
11482
  type: import(".prisma/client").$Enums.AssignmentType;
11356
11483
  id: string;
11357
11484
  createdAt: Date | null;
11358
- modifiedAt: Date | null;
11359
11485
  classId: string;
11486
+ modifiedAt: Date | null;
11360
11487
  title: string;
11361
11488
  instructions: string;
11362
11489
  dueDate: Date;
@@ -11404,8 +11531,8 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
11404
11531
  type: import(".prisma/client").$Enums.AssignmentType;
11405
11532
  id: string;
11406
11533
  createdAt: Date | null;
11407
- modifiedAt: Date | null;
11408
11534
  classId: string;
11535
+ modifiedAt: Date | null;
11409
11536
  title: string;
11410
11537
  instructions: string;
11411
11538
  dueDate: Date;
@@ -11620,8 +11747,8 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
11620
11747
  type: import(".prisma/client").$Enums.AssignmentType;
11621
11748
  id: string;
11622
11749
  createdAt: Date | null;
11623
- modifiedAt: Date | null;
11624
11750
  classId: string;
11751
+ modifiedAt: Date | null;
11625
11752
  title: string;
11626
11753
  instructions: string;
11627
11754
  dueDate: Date;
@@ -11668,8 +11795,8 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
11668
11795
  type: import(".prisma/client").$Enums.AssignmentType;
11669
11796
  id: string;
11670
11797
  createdAt: Date | null;
11671
- modifiedAt: Date | null;
11672
11798
  classId: string;
11799
+ modifiedAt: Date | null;
11673
11800
  title: string;
11674
11801
  instructions: string;
11675
11802
  dueDate: Date;
@@ -11748,6 +11875,7 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
11748
11875
  name: string;
11749
11876
  id: string;
11750
11877
  userId: string | null;
11878
+ folderId: string | null;
11751
11879
  size: number | null;
11752
11880
  uploadedAt: Date | null;
11753
11881
  uploadStatus: import(".prisma/client").$Enums.UploadStatus;
@@ -11764,7 +11892,6 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
11764
11892
  submissionId: string | null;
11765
11893
  annotationId: string | null;
11766
11894
  classDraftId: string | null;
11767
- folderId: string | null;
11768
11895
  conversationId: string | null;
11769
11896
  messageId: string | null;
11770
11897
  announcementId: string | null;
@@ -11788,6 +11915,7 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
11788
11915
  name: string;
11789
11916
  id: string;
11790
11917
  userId: string | null;
11918
+ folderId: string | null;
11791
11919
  size: number | null;
11792
11920
  uploadedAt: Date | null;
11793
11921
  uploadStatus: import(".prisma/client").$Enums.UploadStatus;
@@ -11804,7 +11932,6 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
11804
11932
  submissionId: string | null;
11805
11933
  annotationId: string | null;
11806
11934
  classDraftId: string | null;
11807
- folderId: string | null;
11808
11935
  conversationId: string | null;
11809
11936
  messageId: string | null;
11810
11937
  announcementId: string | null;
@@ -11852,6 +11979,8 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
11852
11979
  } | {
11853
11980
  userId: string;
11854
11981
  kind: "PERSONAL";
11982
+ } | {
11983
+ kind: "SHARED_WITH_ME";
11855
11984
  };
11856
11985
  };
11857
11986
  output: {
@@ -11897,6 +12026,22 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
11897
12026
  }[];
11898
12027
  canWrite: boolean;
11899
12028
  scope: import("../models/cloudStorage.js").CloudScope;
12029
+ displayRoot: {
12030
+ kind: "SHARED_WITH_ME";
12031
+ name: string;
12032
+ } | null;
12033
+ };
12034
+ meta: object;
12035
+ }>;
12036
+ listSharedWithMe: import("@trpc/server").TRPCQueryProcedure<{
12037
+ input: void;
12038
+ output: {
12039
+ folders: {
12040
+ id: string;
12041
+ name: string;
12042
+ color: string | null;
12043
+ }[];
12044
+ files: never[];
11900
12045
  };
11901
12046
  meta: object;
11902
12047
  }>;
@@ -11921,6 +12066,11 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
11921
12066
  color: string | null;
11922
12067
  section: string;
11923
12068
  }[];
12069
+ sharedWithMe: {
12070
+ kind: "SHARED_WITH_ME";
12071
+ folderCount: number;
12072
+ fileCount: number;
12073
+ };
11924
12074
  };
11925
12075
  meta: object;
11926
12076
  }>;
@@ -12745,8 +12895,8 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
12745
12895
  id: string;
12746
12896
  createdAt: Date;
12747
12897
  updatedAt: Date;
12748
- conversationId: string;
12749
12898
  classId: string;
12899
+ conversationId: string;
12750
12900
  title: string;
12751
12901
  createdById: string;
12752
12902
  };
@@ -12804,8 +12954,8 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
12804
12954
  id: string;
12805
12955
  createdAt: Date;
12806
12956
  updatedAt: Date;
12807
- conversationId: string;
12808
12957
  classId: string;
12958
+ conversationId: string;
12809
12959
  title: string;
12810
12960
  createdById: string;
12811
12961
  };
@@ -12929,8 +13079,8 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
12929
13079
  }, import("@trpc/server").TRPCDecorateCreateRouterOptions<{
12930
13080
  getTutorConversation: import("@trpc/server").TRPCQueryProcedure<{
12931
13081
  input: {
12932
- assignmentId: string;
12933
13082
  classId: string;
13083
+ assignmentId: string;
12934
13084
  };
12935
13085
  output: {
12936
13086
  conversationId: string;
@@ -14822,9 +14972,9 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
14822
14972
  }>;
14823
14973
  attach: import("@trpc/server").TRPCMutationProcedure<{
14824
14974
  input: {
14825
- target: "CLASS" | "USER" | "RUBRIC" | "BOUNDARY";
14826
- targetId: string;
14827
14975
  tagId: string;
14976
+ target: "USER" | "CLASS" | "RUBRIC" | "BOUNDARY";
14977
+ targetId: string;
14828
14978
  };
14829
14979
  output: {
14830
14980
  id: string;
@@ -14833,9 +14983,9 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
14833
14983
  }>;
14834
14984
  detach: import("@trpc/server").TRPCMutationProcedure<{
14835
14985
  input: {
14836
- target: "CLASS" | "USER" | "RUBRIC" | "BOUNDARY";
14837
- targetId: string;
14838
14986
  tagId: string;
14987
+ target: "USER" | "CLASS" | "RUBRIC" | "BOUNDARY";
14988
+ targetId: string;
14839
14989
  };
14840
14990
  output: {
14841
14991
  id: string;
@@ -14844,7 +14994,7 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
14844
14994
  }>;
14845
14995
  getAttached: import("@trpc/server").TRPCQueryProcedure<{
14846
14996
  input: {
14847
- target: "CLASS" | "USER" | "RUBRIC" | "BOUNDARY";
14997
+ target: "USER" | "CLASS" | "RUBRIC" | "BOUNDARY";
14848
14998
  targetId: string;
14849
14999
  };
14850
15000
  output: {
@@ -14859,5 +15009,109 @@ export declare const createCaller: import("@trpc/server").TRPCRouterCaller<{
14859
15009
  meta: object;
14860
15010
  }>;
14861
15011
  }>>;
15012
+ permissions: import("@trpc/server").TRPCBuiltRouter<{
15013
+ ctx: import("../trpc.js").Context;
15014
+ meta: object;
15015
+ errorShape: {
15016
+ data: {
15017
+ zodError: import("zod").typeToFlattenedError<any, string> | null;
15018
+ prismaError: import("../utils/prismaErrorHandler.js").PrismaErrorInfo | null;
15019
+ code: import("@trpc/server").TRPC_ERROR_CODE_KEY;
15020
+ httpStatus: number;
15021
+ path?: string;
15022
+ stack?: string;
15023
+ };
15024
+ message: string;
15025
+ code: import("@trpc/server").TRPC_ERROR_CODE_NUMBER;
15026
+ };
15027
+ transformer: false;
15028
+ }, import("@trpc/server").TRPCDecorateCreateRouterOptions<{
15029
+ list: import("@trpc/server").TRPCQueryProcedure<{
15030
+ input: {
15031
+ folderId: string;
15032
+ };
15033
+ output: ({
15034
+ school: {
15035
+ name: string;
15036
+ id: string;
15037
+ } | null;
15038
+ user: {
15039
+ id: string;
15040
+ username: string;
15041
+ email: string;
15042
+ } | null;
15043
+ class: {
15044
+ name: string;
15045
+ id: string;
15046
+ section: string;
15047
+ } | null;
15048
+ department: {
15049
+ name: string;
15050
+ id: string;
15051
+ color: string | null;
15052
+ } | null;
15053
+ tag: {
15054
+ name: string;
15055
+ id: string;
15056
+ color: string;
15057
+ } | null;
15058
+ } & {
15059
+ level: import(".prisma/client").$Enums.PermissionLevel;
15060
+ id: string;
15061
+ createdAt: Date;
15062
+ schoolId: string | null;
15063
+ userId: string | null;
15064
+ departmentId: string | null;
15065
+ folderId: string;
15066
+ principalType: import(".prisma/client").$Enums.PermissionPrincipalType;
15067
+ tagId: string | null;
15068
+ classId: string | null;
15069
+ grantedById: string;
15070
+ })[];
15071
+ meta: object;
15072
+ }>;
15073
+ grant: import("@trpc/server").TRPCMutationProcedure<{
15074
+ input: {
15075
+ level: "READ" | "WRITE";
15076
+ folderId: string;
15077
+ principal: import("../services/permissions.js").PermissionPrincipalInput;
15078
+ };
15079
+ output: {
15080
+ level: import(".prisma/client").$Enums.PermissionLevel;
15081
+ id: string;
15082
+ createdAt: Date;
15083
+ schoolId: string | null;
15084
+ userId: string | null;
15085
+ departmentId: string | null;
15086
+ folderId: string;
15087
+ principalType: import(".prisma/client").$Enums.PermissionPrincipalType;
15088
+ tagId: string | null;
15089
+ classId: string | null;
15090
+ grantedById: string;
15091
+ };
15092
+ meta: object;
15093
+ }>;
15094
+ revoke: import("@trpc/server").TRPCMutationProcedure<{
15095
+ input: {
15096
+ permissionId: string;
15097
+ };
15098
+ output: {
15099
+ success: boolean;
15100
+ };
15101
+ meta: object;
15102
+ }>;
15103
+ listSharedWithMe: import("@trpc/server").TRPCQueryProcedure<{
15104
+ input: void;
15105
+ output: {
15106
+ folders: {
15107
+ id: string;
15108
+ name: string;
15109
+ color: string | null;
15110
+ }[];
15111
+ files: never[];
15112
+ };
15113
+ meta: object;
15114
+ }>;
15115
+ }>>;
14862
15116
  }>>;
14863
15117
  //# sourceMappingURL=_app.d.ts.map