@axium/notes 0.3.12 → 0.3.13

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/lib/Note.svelte CHANGED
@@ -9,7 +9,12 @@
9
9
  import type { Note } from '@axium/notes/common';
10
10
  import { download } from 'utilium/dom.js';
11
11
 
12
- let { note = $bindable(), notes = $bindable(), pageMode = false }: { note: Note; notes?: Note[]; pageMode?: boolean } = $props();
12
+ let {
13
+ note = $bindable(),
14
+ notes = $bindable(),
15
+ pageMode = false,
16
+ user,
17
+ }: { note: Note; notes?: Note[]; pageMode?: boolean; user?: UserPublic } = $props();
13
18
 
14
19
  let acl = $state<HTMLDialogElement>();
15
20
  </script>
@@ -72,7 +77,7 @@
72
77
  </div>
73
78
  {/if}
74
79
  </Popover>
75
- <AccessControlDialog bind:dialog={acl} item={note} itemType="notes" editable />
80
+ <AccessControlDialog bind:dialog={acl} item={note} itemType="notes" {user} />
76
81
  </div>
77
82
  <textarea
78
83
  bind:value={note.content}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@axium/notes",
3
- "version": "0.3.12",
3
+ "version": "0.3.13",
4
4
  "author": "James Prevett <axium@jamespre.dev>",
5
5
  "description": "Notes for Axium",
6
6
  "funding": {
@@ -36,8 +36,8 @@
36
36
  "build": "tsc"
37
37
  },
38
38
  "peerDependencies": {
39
- "@axium/client": ">=0.18.0",
40
- "@axium/core": ">=0.19.0",
39
+ "@axium/client": ">=0.20.0",
40
+ "@axium/core": ">=0.23.0",
41
41
  "@axium/server": ">=0.35.0",
42
42
  "@sveltejs/kit": "^2.27.3",
43
43
  "utilium": "^2.4.0"
@@ -1,8 +1,8 @@
1
1
  import { getCurrentSession } from '@axium/client/user';
2
- import type { Session } from '@axium/core';
2
+ import type { Session, UserPublic } from '@axium/core';
3
3
 
4
4
  export async function load({ parent }) {
5
- let { session }: { session?: Session | null } = await parent();
5
+ let { session }: { session?: (Session & { user: UserPublic }) | null } = await parent();
6
6
 
7
7
  session ||= await getCurrentSession().catch(() => null);
8
8
 
@@ -32,7 +32,7 @@
32
32
  </button>
33
33
  <div class="lists-container">
34
34
  {#each notes as note}
35
- <Note {note} bind:notes />
35
+ <Note {note} bind:notes user={data.session?.user} />
36
36
  {/each}
37
37
  </div>
38
38
  </div>
@@ -34,7 +34,7 @@
34
34
  </div>
35
35
  {/if}
36
36
 
37
- <Note note={data.note} pageMode />
37
+ <Note note={data.note} pageMode user={data.session?.user} />
38
38
  </div>
39
39
 
40
40
  <style>