intelliwaketssveltekitv25 0.1.105 → 0.1.106

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.
@@ -1,6 +1,6 @@
1
1
  <script lang="ts">
2
2
  import { ModalPrompt } from './ModalPromptDefinition'
3
- import { Modal, Icon } from './index'
3
+ import { Icon, Modal } from './index'
4
4
 
5
5
  let width = $derived($ModalPrompt?.size === 'sm' ? '20em' : $ModalPrompt?.size === 'lg' ? '30em' : $ModalPrompt?.size === 'xl' ? '35em' : '25em')
6
6
  </script>
@@ -24,12 +24,24 @@
24
24
  <Icon
25
25
  {...$ModalPrompt.titleFAProps ?? $ModalPrompt?.faProps}
26
26
  fw />
27
+ {/if}
28
+ {#if !!$ModalPrompt.title}
29
+ {#if typeof $ModalPrompt.title === 'string'}
30
+ {$ModalPrompt.title ?? ''}
31
+ {:else}
32
+ {@render $ModalPrompt.title()}
27
33
  {/if}
28
- {$ModalPrompt.title ?? ''}
34
+ {/if}
29
35
  </span>
30
36
  {/if}
31
37
  {/snippet}
32
38
  {#snippet body()}
33
- {$ModalPrompt?.messageBody ?? ''}
39
+ {#if !!$ModalPrompt?.messageBody}
40
+ {#if typeof $ModalPrompt.messageBody === 'string'}
41
+ {$ModalPrompt.messageBody ?? ''}
42
+ {:else}
43
+ {@render $ModalPrompt.messageBody()}
44
+ {/if}
45
+ {/if}
34
46
  {/snippet}
35
47
  </Modal>
@@ -1,9 +1,10 @@
1
1
  import type { IFAProps } from './Definitions';
2
+ import type { Snippet } from 'svelte';
2
3
  export type TModalPromptProps<T = unknown> = {
3
4
  size?: 'sm' | 'lg' | 'xl';
4
- title?: string;
5
+ title?: string | Snippet;
5
6
  titleFAProps?: IFAProps;
6
- messageBody?: string;
7
+ messageBody?: string | Snippet;
7
8
  color?: string;
8
9
  okLabel?: string;
9
10
  faProps?: IFAProps;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "intelliwaketssveltekitv25",
3
- "version": "0.1.105",
3
+ "version": "0.1.106",
4
4
  "exports": {
5
5
  ".": {
6
6
  "types": "./dist/index.d.ts",