@axium/core 0.19.4 → 0.19.6

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.
@@ -7,6 +7,9 @@
7
7
  "application/pgp-signature": "file-signature",
8
8
  "application/vnd.amazon.ebook": "book",
9
9
  "application/vnd.amazon.mobi8-ebook": "book",
10
+ "application/vnd.oasis.opendocument.presentation": "file-video",
11
+ "application/vnd.oasis.opendocument.spreadsheet": "file-spreadsheet",
12
+ "application/vnd.oasis.opendocument.text": "file-contract",
10
13
  "application/vnd.openxmlformats-officedocument.presentationml.presentation": "file-video",
11
14
  "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet": "file-spreadsheet",
12
15
  "application/vnd.openxmlformats-officedocument.wordprocessingml.document": "file-contract",
@@ -28,6 +31,7 @@
28
31
  "image/svg+xml": "file-svg",
29
32
  "image/vnd.microsoft.icon": "icons",
30
33
  "inode/directory": "folder",
34
+ "text/calendar": "calendar-day",
31
35
  "text/css": "css",
32
36
  "text/csv": "file-csv",
33
37
  "text/html": "code",
package/dist/access.d.ts CHANGED
@@ -21,7 +21,7 @@ export declare const AccessControl: z.ZodObject<{
21
21
  isSuspended: z.ZodOptional<z.ZodBoolean>;
22
22
  }, z.core.$strip>>>;
23
23
  createdAt: z.ZodCoercedDate<unknown>;
24
- }, z.core.$loose>;
24
+ }, z.core.$catchall<z.ZodBoolean>>;
25
25
  export interface AccessControl extends z.infer<typeof AccessControl> {
26
26
  }
27
27
  export declare function getTarget(ac: AccessControl): AccessTarget;
package/dist/access.js CHANGED
@@ -1,14 +1,16 @@
1
1
  import * as z from 'zod';
2
2
  import { UserPublic } from './user.js';
3
3
  import { omit } from 'utilium';
4
- export const AccessControl = z.looseObject({
4
+ export const AccessControl = z
5
+ .object({
5
6
  itemId: z.uuid(),
6
7
  userId: z.uuid().nullish(),
7
8
  role: z.string().nullish(),
8
9
  tag: z.string().nullish(),
9
10
  user: UserPublic.nullish(),
10
11
  createdAt: z.coerce.date(),
11
- });
12
+ })
13
+ .catchall(z.boolean());
12
14
  export function getTarget(ac) {
13
15
  if (ac.userId)
14
16
  return ac.userId;
package/dist/api.d.ts CHANGED
@@ -426,7 +426,7 @@ declare const _API: {
426
426
  isSuspended: z.ZodOptional<z.ZodBoolean>;
427
427
  }, z.core.$strip>>>;
428
428
  createdAt: z.ZodCoercedDate<unknown>;
429
- }, z.core.$loose>>;
429
+ }, z.core.$catchall<z.ZodBoolean>>>;
430
430
  readonly PATCH: [z.ZodObject<{
431
431
  target: z.ZodUnion<readonly [z.ZodUUID, z.ZodTemplateLiteral<`@${string}`>, z.ZodTemplateLiteral<`#${string}`>, z.ZodLiteral<"public">]>;
432
432
  permissions: z.ZodRecord<z.ZodString, z.ZodAny>;
@@ -451,7 +451,7 @@ declare const _API: {
451
451
  isSuspended: z.ZodOptional<z.ZodBoolean>;
452
452
  }, z.core.$strip>>>;
453
453
  createdAt: z.ZodCoercedDate<unknown>;
454
- }, z.core.$loose>];
454
+ }, z.core.$catchall<z.ZodBoolean>>];
455
455
  readonly PUT: [z.ZodUnion<readonly [z.ZodUUID, z.ZodTemplateLiteral<`@${string}`>, z.ZodTemplateLiteral<`#${string}`>, z.ZodLiteral<"public">]>, z.ZodObject<{
456
456
  itemId: z.ZodUUID;
457
457
  userId: z.ZodOptional<z.ZodNullable<z.ZodUUID>>;
@@ -473,7 +473,7 @@ declare const _API: {
473
473
  isSuspended: z.ZodOptional<z.ZodBoolean>;
474
474
  }, z.core.$strip>>>;
475
475
  createdAt: z.ZodCoercedDate<unknown>;
476
- }, z.core.$loose>];
476
+ }, z.core.$catchall<z.ZodBoolean>>];
477
477
  readonly DELETE: [z.ZodUnion<readonly [z.ZodUUID, z.ZodTemplateLiteral<`@${string}`>, z.ZodTemplateLiteral<`#${string}`>, z.ZodLiteral<"public">]>, z.ZodObject<{
478
478
  itemId: z.ZodUUID;
479
479
  userId: z.ZodOptional<z.ZodNullable<z.ZodUUID>>;
@@ -495,7 +495,7 @@ declare const _API: {
495
495
  isSuspended: z.ZodOptional<z.ZodBoolean>;
496
496
  }, z.core.$strip>>>;
497
497
  createdAt: z.ZodCoercedDate<unknown>;
498
- }, z.core.$loose>];
498
+ }, z.core.$catchall<z.ZodBoolean>>];
499
499
  };
500
500
  readonly 'admin/summary': {
501
501
  readonly GET: z.ZodObject<{
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@axium/core",
3
- "version": "0.19.4",
3
+ "version": "0.19.6",
4
4
  "author": "James Prevett <axium@jamespre.dev>",
5
5
  "funding": {
6
6
  "type": "individual",