@kayord/ui 1.0.0 → 1.0.1

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.
@@ -0,0 +1,17 @@
1
+ <script lang="ts">
2
+ import { cn } from "../../../utils";
3
+ import type { AvatarGroupEtcProps } from "./types";
4
+
5
+ let { ref = $bindable(null), plus, class: className, ...rest }: AvatarGroupEtcProps = $props();
6
+ </script>
7
+
8
+ <div
9
+ {...rest}
10
+ bind:this={ref}
11
+ class={cn(
12
+ "bg-accent ring-background relative flex size-8 items-center justify-center rounded-full text-xs ring-2",
13
+ className
14
+ )}
15
+ >
16
+ <span>+{plus}</span>
17
+ </div>
@@ -0,0 +1,4 @@
1
+ import type { AvatarGroupEtcProps } from "./types";
2
+ declare const AvatarGroupEtc: import("svelte").Component<AvatarGroupEtcProps, {}, "ref">;
3
+ type AvatarGroupEtc = ReturnType<typeof AvatarGroupEtc>;
4
+ export default AvatarGroupEtc;
@@ -0,0 +1,9 @@
1
+ <script lang="ts">
2
+ import { Avatar } from "../../..";
3
+ import { Avatar as AvatarPrimitive } from "bits-ui";
4
+ import { cn } from "../../../utils";
5
+
6
+ let { ref = $bindable(null), class: className, ...restProps }: AvatarPrimitive.RootProps = $props();
7
+ </script>
8
+
9
+ <Avatar.Root bind:ref class={cn("bg-accent ring-background ring-2", className)} {...restProps} />
@@ -0,0 +1,4 @@
1
+ import { Avatar as AvatarPrimitive } from "bits-ui";
2
+ declare const AvatarGroupMember: import("svelte").Component<AvatarPrimitive.RootProps, {}, "ref">;
3
+ type AvatarGroupMember = ReturnType<typeof AvatarGroupMember>;
4
+ export default AvatarGroupMember;
@@ -0,0 +1,24 @@
1
+ <script lang="ts">
2
+ import { cn } from "../../../utils";
3
+ import type { AvatarGroupRootProps } from "./types";
4
+
5
+ let {
6
+ ref = $bindable(null),
7
+ orientation = "horizontal",
8
+ class: className,
9
+ children,
10
+ ...rest
11
+ }: AvatarGroupRootProps = $props();
12
+ </script>
13
+
14
+ <div
15
+ bind:this={ref}
16
+ data-orientation={orientation}
17
+ class={cn(
18
+ 'group/avatar-group flex items-center data-[orientation="horizontal"]:flex-row data-[orientation="horizontal"]:-space-x-2 data-[orientation="vertical"]:flex-col data-[orientation="vertical"]:-space-y-2',
19
+ className
20
+ )}
21
+ {...rest}
22
+ >
23
+ {@render children?.()}
24
+ </div>
@@ -0,0 +1,4 @@
1
+ import type { AvatarGroupRootProps } from "./types";
2
+ declare const AvatarGroup: import("svelte").Component<AvatarGroupRootProps, {}, "ref">;
3
+ type AvatarGroup = ReturnType<typeof AvatarGroup>;
4
+ export default AvatarGroup;
@@ -0,0 +1,6 @@
1
+ import Root from "./avatar-group.svelte";
2
+ import Member from "./avatar-group-member.svelte";
3
+ import Etc from "./avatar-group-etc.svelte";
4
+ import { Fallback, Image } from "../../ui/avatar";
5
+ export { Root, Member, Etc, Image as MemberImage, Fallback as MemberFallback };
6
+ export type * from "./types";
@@ -0,0 +1,5 @@
1
+ import Root from "./avatar-group.svelte";
2
+ import Member from "./avatar-group-member.svelte";
3
+ import Etc from "./avatar-group-etc.svelte";
4
+ import { Fallback, Image } from "../../ui/avatar";
5
+ export { Root, Member, Etc, Image as MemberImage, Fallback as MemberFallback };
@@ -0,0 +1,13 @@
1
+ import type { Avatar as AvatarPrimitive, WithChildren, WithoutChildren } from "bits-ui";
2
+ import type { HTMLAttributes } from "svelte/elements";
3
+ export type AvatarGroupRootPropsWithoutHTML = WithChildren<{
4
+ ref?: HTMLElement | null;
5
+ orientation?: "vertical" | "horizontal";
6
+ }>;
7
+ export type AvatarGroupRootProps = AvatarGroupRootPropsWithoutHTML & WithoutChildren<HTMLAttributes<HTMLDivElement>>;
8
+ export type AvatarGroupMemberProps = AvatarPrimitive.RootProps;
9
+ export type AvatarGroupEtcPropsWithoutHTML = WithChildren<{
10
+ ref?: HTMLElement | null;
11
+ plus: number;
12
+ }>;
13
+ export type AvatarGroupEtcProps = AvatarGroupEtcPropsWithoutHTML & WithoutChildren<HTMLAttributes<HTMLDivElement>>;
@@ -0,0 +1 @@
1
+ export {};
@@ -8,3 +8,4 @@ export * as TreeView from "./tree-view/index.js";
8
8
  export { ThemeSelector } from "./theme-selector/index.js";
9
9
  export { LightSwitch } from "./light-switch.svelte/index.js";
10
10
  export * from "./animations/index.js";
11
+ export * as AvatarGroup from "./avatar-group/index.js";
@@ -8,3 +8,4 @@ export * as TreeView from "./tree-view/index.js";
8
8
  export { ThemeSelector } from "./theme-selector/index.js";
9
9
  export { LightSwitch } from "./light-switch.svelte/index.js";
10
10
  export * from "./animations/index.js";
11
+ export * as AvatarGroup from "./avatar-group/index.js";
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@kayord/ui",
3
3
  "private": false,
4
- "version": "1.0.0",
4
+ "version": "1.0.1",
5
5
  "exports": {
6
6
  ".": {
7
7
  "types": "./dist/index.d.ts",
@@ -58,13 +58,13 @@
58
58
  "@testing-library/user-event": "^14.6.1",
59
59
  "@types/d3-scale": "^4.0.9",
60
60
  "@types/d3-shape": "^3.1.7",
61
- "@typescript-eslint/eslint-plugin": "^8.33.1",
62
- "@typescript-eslint/parser": "^8.33.1",
61
+ "@typescript-eslint/eslint-plugin": "^8.34.0",
62
+ "@typescript-eslint/parser": "^8.34.0",
63
63
  "d3-scale": "^4.0.2",
64
64
  "d3-shape": "^3.2.0",
65
65
  "eslint": "^9.28.0",
66
66
  "eslint-config-prettier": "^10.1.5",
67
- "eslint-plugin-svelte": "^3.9.1",
67
+ "eslint-plugin-svelte": "^3.9.2",
68
68
  "happy-dom": "^17.6.3",
69
69
  "layerchart": "2.0.0-next.6",
70
70
  "prettier": "^3.5.3",
@@ -79,7 +79,7 @@
79
79
  "typescript": "^5.8.3",
80
80
  "vite": "^6.3.5",
81
81
  "vitest": "^3.2.3",
82
- "zod": "^3.25.56"
82
+ "zod": "^3.25.57"
83
83
  },
84
84
  "svelte": "./dist/index.js",
85
85
  "types": "./dist/index.d.ts",