tera-system-ui 0.1.13 → 0.1.15

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.
@@ -220,6 +220,9 @@ type DialogPropsCommon = {
220
220
  focusTriggerAfterClose?: boolean;
221
221
  padding?: 'none' | undefined;
222
222
  containerClass?: string;
223
+ headerClass?: string;
224
+ bodyClass?: string;
225
+ footerClass?: string;
223
226
  };
224
227
  export type DialogProps = DialogVariants & DialogPropsCommon & {
225
228
  children?: any;
@@ -4,6 +4,7 @@
4
4
  import {Button} from "../button";
5
5
  import './dialog.scss'
6
6
  import {sleep} from "../../internal/helpers/sleep";
7
+ import {cn} from "../../utils";
7
8
 
8
9
  let {
9
10
  children, open = $bindable(),
@@ -20,6 +21,9 @@
20
21
  triggerRef,
21
22
  focusTriggerAfterClose,
22
23
  containerClass,
24
+ headerClass,
25
+ bodyClass,
26
+ footerClass,
23
27
  ...props
24
28
  }: DialogProps = $props();
25
29
 
@@ -91,16 +95,16 @@
91
95
 
92
96
  <div class={"dialog-box " + dialogContainer({className: containerClass})}>
93
97
  {#if header}
94
- <header class={headerStyle()}>
98
+ <header class={cn(headerStyle(), headerClass)}>
95
99
  {@render header?.()}
96
100
  </header>
97
101
  {/if}
98
102
 
99
- <main class={body()}>
103
+ <main class={cn(body(), bodyClass)}>
100
104
  {@render children?.()}
101
105
  </main>
102
106
  {#if footer}
103
- <footer class={footerStyle()}>
107
+ <footer class={cn(footerStyle(), footerClass)}>
104
108
  {@render footer?.()}
105
109
  </footer>
106
110
  {/if}
@@ -18,5 +18,6 @@ export type DropdownMenuItemProps = {
18
18
  class?: string;
19
19
  onclick?: (e: any) => void;
20
20
  href?: string;
21
+ linkProps?: any;
21
22
  };
22
23
  export {};
@@ -3,7 +3,7 @@
3
3
  import {cn} from "../../../utils/utils";
4
4
 
5
5
 
6
- let {children, class: className, onclick, href, ...props}: DropdownMenuItemProps = $props()
6
+ let {children, class: className, onclick, href, linkProps, ...props}: DropdownMenuItemProps = $props()
7
7
  let context = getCtx()
8
8
  </script>
9
9
 
@@ -22,7 +22,7 @@
22
22
  {/snippet}
23
23
 
24
24
  {#if href}
25
- <a href={href} data-no-translate>
25
+ <a href={href} data-no-translate {...linkProps}>
26
26
  {@render button()}
27
27
  </a>
28
28
  {:else }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "tera-system-ui",
3
- "version": "0.1.13",
3
+ "version": "0.1.15",
4
4
  "scripts": {
5
5
  "dev": "vite dev",
6
6
  "build": "npm run customPrepublish && npm run generate-index && vite build && npm run package && npm run postpublish",