@r2digisolutions/ui 0.24.7 → 0.24.8

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.
@@ -144,6 +144,10 @@
144
144
  return manager.state.items.filter((r) => ids.has(rowId(r)));
145
145
  }
146
146
 
147
+ const selectedRowsItems = $derived.by(() => {
148
+ return selectedRows();
149
+ });
150
+
147
151
  function colTrack(cId: string, measuring: boolean) {
148
152
  if (measuring) return 'max-content';
149
153
  const c = manager.getColumn(cId);
@@ -379,7 +383,7 @@
379
383
  x={rightMenu.x}
380
384
  y={rightMenu.y}
381
385
  context={rightClickContext}
382
- items={(actions?.(selectedRows(), rightClickContext) ?? []).map((a) => ({
386
+ items={(actions?.(selectedRowsItems, rightClickContext) ?? []).map((a) => ({
383
387
  ...a,
384
388
  onClick: a.onClick
385
389
  }))}
@@ -46,6 +46,7 @@
46
46
  context?: any;
47
47
  portalTarget?: HTMLElement | null;
48
48
  };
49
+
49
50
  let {
50
51
  items = [],
51
52
  x = 0,
@@ -21,11 +21,6 @@ import Checkbox from './ui/Checkbox/Checkbox.svelte';
21
21
  import Badge from './ui/Badge/Badge.svelte';
22
22
  import NoContent from './ui/NoContent/NoContent.svelte';
23
23
  import Tag from './ui/Tag/Tag.svelte';
24
- import Dialog from './ui/Dialog/Dialog.svelte';
25
- import DialogHeader from './ui/Dialog/DialogHeader.svelte';
26
- import DialogTitle from './ui/Dialog/DialogTitle.svelte';
27
- import DialogDescription from './ui/Dialog/DialogDescription.svelte';
28
- import DialogContent from './ui/Dialog/DialogContent.svelte';
29
- import DialogFooter from './ui/Dialog/DialogFooter.svelte';
24
+ export * from './ui/Dialog/index.js';
30
25
  import Selector from './ui/Selector/Selector.svelte';
31
- export { Selector, Dialog, DialogHeader, DialogTitle, DialogDescription, DialogContent, DialogFooter, Tag, NoContent, Alert, Avatar, Button, Badge, Card, CardHeader, CardTitle, CardDescription, CardContent, CardFooter, Container, Checkbox, Field, Section, Loading, TableList, Heading, Label, Input, InputRadio, Textarea, };
26
+ export { Selector, Tag, NoContent, Alert, Avatar, Button, Badge, Card, CardHeader, CardTitle, CardDescription, CardContent, CardFooter, Container, Checkbox, Field, Section, Loading, TableList, Heading, Label, Input, InputRadio, Textarea, };
@@ -21,11 +21,6 @@ import Checkbox from './ui/Checkbox/Checkbox.svelte';
21
21
  import Badge from './ui/Badge/Badge.svelte';
22
22
  import NoContent from './ui/NoContent/NoContent.svelte';
23
23
  import Tag from './ui/Tag/Tag.svelte';
24
- import Dialog from './ui/Dialog/Dialog.svelte';
25
- import DialogHeader from './ui/Dialog/DialogHeader.svelte';
26
- import DialogTitle from './ui/Dialog/DialogTitle.svelte';
27
- import DialogDescription from './ui/Dialog/DialogDescription.svelte';
28
- import DialogContent from './ui/Dialog/DialogContent.svelte';
29
- import DialogFooter from './ui/Dialog/DialogFooter.svelte';
24
+ export * from './ui/Dialog/index.js';
30
25
  import Selector from './ui/Selector/Selector.svelte';
31
- export { Selector, Dialog, DialogHeader, DialogTitle, DialogDescription, DialogContent, DialogFooter, Tag, NoContent, Alert, Avatar, Button, Badge, Card, CardHeader, CardTitle, CardDescription, CardContent, CardFooter, Container, Checkbox, Field, Section, Loading, TableList, Heading, Label, Input, InputRadio, Textarea, };
26
+ export { Selector, Tag, NoContent, Alert, Avatar, Button, Badge, Card, CardHeader, CardTitle, CardDescription, CardContent, CardFooter, Container, Checkbox, Field, Section, Loading, TableList, Heading, Label, Input, InputRadio, Textarea, };
@@ -1,7 +1,7 @@
1
1
  import { ModalContext } from './ModalContext.svelte';
2
- export declare const KEY: unique symbol;
3
- export interface DialogActions {
2
+ export declare const KEY_DIALOG: unique symbol;
3
+ export interface IDialogActions {
4
4
  onOpenChange?(open: boolean): void;
5
5
  }
6
- export declare function createDialogContext(fn_open: any, actions?: DialogActions): ModalContext;
6
+ export declare function createDialogContext(fn_open: any, actions?: IDialogActions): ModalContext;
7
7
  export declare function useDialogContext(): ModalContext;
@@ -1,9 +1,9 @@
1
1
  import { getContext, setContext } from 'svelte';
2
2
  import { ModalContext } from './ModalContext.svelte';
3
- export const KEY = Symbol('Dialog');
3
+ export const KEY_DIALOG = Symbol('Dialog');
4
4
  export function createDialogContext(fn_open, actions = {}) {
5
5
  const context = new ModalContext(fn_open());
6
- setContext(KEY, context);
6
+ setContext(KEY_DIALOG, context);
7
7
  $effect(() => {
8
8
  context.open = fn_open();
9
9
  actions.onOpenChange?.(context.open);
@@ -15,5 +15,5 @@ export function createDialogContext(fn_open, actions = {}) {
15
15
  return context;
16
16
  }
17
17
  export function useDialogContext() {
18
- return getContext(KEY);
18
+ return getContext(KEY_DIALOG);
19
19
  }
@@ -0,0 +1,8 @@
1
+ import Dialog from './Dialog.svelte';
2
+ import DialogTitle from './DialogTitle.svelte';
3
+ import DialogDescription from './DialogDescription.svelte';
4
+ import DialogContent from './DialogContent.svelte';
5
+ import DialogHeader from './DialogHeader.svelte';
6
+ import DialogFooter from './DialogFooter.svelte';
7
+ export * from './context.svelte.js';
8
+ export { Dialog, DialogTitle, DialogDescription, DialogContent, DialogHeader, DialogFooter };
@@ -0,0 +1,8 @@
1
+ import Dialog from './Dialog.svelte';
2
+ import DialogTitle from './DialogTitle.svelte';
3
+ import DialogDescription from './DialogDescription.svelte';
4
+ import DialogContent from './DialogContent.svelte';
5
+ import DialogHeader from './DialogHeader.svelte';
6
+ import DialogFooter from './DialogFooter.svelte';
7
+ export * from './context.svelte.js';
8
+ export { Dialog, DialogTitle, DialogDescription, DialogContent, DialogHeader, DialogFooter };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@r2digisolutions/ui",
3
- "version": "0.24.7",
3
+ "version": "0.24.8",
4
4
  "private": false,
5
5
  "packageManager": "bun@1.2.23",
6
6
  "publishConfig": {