@ichaingo/header 1.4.41 → 1.4.43

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/dist/lib/Nav.js CHANGED
@@ -73,7 +73,7 @@ function G({ onClick: s = () => {
73
73
  {
74
74
  className: i(
75
75
  "flex flex-col justify-start items-start md:px-3",
76
- "md:flex-row md:justify-end md:items-start md:px-0",
76
+ "md:flex-row md:justify-end md:items-center md:px-0",
77
77
  "md:gap-6"
78
78
  ),
79
79
  children: [
@@ -1,30 +1,27 @@
1
1
  'use client';
2
- import { jsxs as a, jsx as e } from "react/jsx-runtime";
3
- import { DropdownMenu as d, DropdownMenuTrigger as i, DropdownMenuContent as c, DropdownMenuGroup as t, DropdownMenuItem as m } from "@ichaingo/ui/dropdown-menu";
4
- import s from "@ichaingo/link";
5
- import p from "@ichaingo/translation";
6
- import x from "./MainTrigger.js";
7
- import g from "./Logout.js";
8
- import u from "@ichaingo/avatar";
9
- function M({
10
- list: o,
11
- userInfo: l,
12
- onClick: n
2
+ import { jsx as l, jsxs as a } from "react/jsx-runtime";
3
+ import d from "@ichaingo/link";
4
+ import i from "@ichaingo/translation";
5
+ import m from "./MainTrigger.js";
6
+ import c from "./Logout.js";
7
+ import n from "@ichaingo/avatar";
8
+ import s from "@ichaingo/tooltip";
9
+ function u({
10
+ list: t,
11
+ userInfo: e,
12
+ onClick: o
13
13
  }) {
14
- return /* @__PURE__ */ a(d, { children: [
15
- /* @__PURE__ */ e(i, { className: "outline-none cursor-pointer", children: /* @__PURE__ */ e(x, { userInfo: l }) }),
16
- /* @__PURE__ */ e(c, { align: "end", className: "z-2000 w-75 p-0 border-transparent outline-none border border-stroke", children: /* @__PURE__ */ a(t, { className: "flex flex-col gap-2 p-3 bg-module rounded-md", children: [
17
- /* @__PURE__ */ e("div", { className: "flex flex-col gap-3 w-full bg-background rounded-lg p-2", children: /* @__PURE__ */ a("div", { className: "flex items-center gap-2", children: [
18
- /* @__PURE__ */ e(u, { userInfo: l, className: "w-8 h-8" }),
19
- /* @__PURE__ */ a("div", { className: "flex flex-col overflow-hidden", children: [
20
- /* @__PURE__ */ e("div", { className: "text-sm font-medium", children: (l == null ? void 0 : l.username) || "--" }),
21
- /* @__PURE__ */ e("div", { className: "text-xs text-muted-foreground w-full truncate", children: (l == null ? void 0 : l.email) || (l == null ? void 0 : l.walletAddress) })
22
- ] })
23
- ] }) }),
24
- o.map((r) => /* @__PURE__ */ e(m, { className: "px-0 py-0 focus-visible:border-none focus-visible:outline-none", children: /* @__PURE__ */ e("div", { className: "flex items-center gap-2 w-full", children: r.name === "logout" ? /* @__PURE__ */ e(g, { className: "flex-1 flex py-3 border-t border-stroke w-full px-2 hover:bg-background" }) : /* @__PURE__ */ e(s, { href: `/${r.href}`, baseUrl: process.env.NEXT_PUBLIC_AUTH_URL, className: "flex-1 flex py-3 h-full w-full px-2 hover:bg-background rounded-lg ", onClick: n, children: /* @__PURE__ */ e(p, { value: r.name, parentKey: "account" }) }) }) }, r.name))
25
- ] }) })
26
- ] });
14
+ return /* @__PURE__ */ l(s, { trigger: /* @__PURE__ */ l(m, { userInfo: e }), arrowClassName: "fill-module", contentClassName: "text-title w-75 p-0 border-transparent outline-none border border-stroke", children: /* @__PURE__ */ a("div", { className: "flex flex-col gap-2 p-3 bg-module rounded-md", children: [
15
+ /* @__PURE__ */ l("div", { className: "flex flex-col gap-3 w-full bg-background rounded-lg p-2", children: /* @__PURE__ */ a("div", { className: "flex items-center gap-2", children: [
16
+ /* @__PURE__ */ l(n, { userInfo: e, className: "w-8 h-8" }),
17
+ /* @__PURE__ */ a("div", { className: "flex flex-col overflow-hidden", children: [
18
+ /* @__PURE__ */ l("div", { className: "text-sm font-medium", children: (e == null ? void 0 : e.username) || "--" }),
19
+ /* @__PURE__ */ l("div", { className: "text-xs text-muted-foreground w-full truncate", children: (e == null ? void 0 : e.email) || (e == null ? void 0 : e.walletAddress) })
20
+ ] })
21
+ ] }) }),
22
+ t.map((r) => /* @__PURE__ */ l("div", { className: "px-0 py-0 focus-visible:border-none focus-visible:outline-none", children: /* @__PURE__ */ l("div", { className: "flex items-center gap-2 w-full", children: r.name === "logout" ? /* @__PURE__ */ l(c, { className: "flex-1 flex py-3 border-t border-stroke w-full px-2 hover:bg-background" }) : /* @__PURE__ */ l(d, { href: `/${r.href}`, baseUrl: process.env.NEXT_PUBLIC_AUTH_URL, className: "flex-1 flex py-3 h-full w-full px-2 hover:bg-background hover:text-primary rounded-lg ", onClick: o, children: /* @__PURE__ */ l(i, { value: r.name, parentKey: "account" }) }) }) }, r.name))
23
+ ] }) });
27
24
  }
28
25
  export {
29
- M as default
26
+ u as default
30
27
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ichaingo/header",
3
- "version": "1.4.41",
3
+ "version": "1.4.43",
4
4
  "type": "module",
5
5
  "main": "./dist/index.js",
6
6
  "module": "./dist/index.js",
@@ -29,20 +29,20 @@
29
29
  "rollup-plugin-preserve-use-client": "^1.0.0",
30
30
  "tailwind-merge": "^2.5.5",
31
31
  "next": "15.1.6",
32
- "@ichaingo/auth": "1.4.41",
33
- "@ichaingo/avatar": "1.4.41",
34
- "@ichaingo/better-link": "1.4.41",
35
- "@ichaingo/translation": "1.4.41",
36
- "@ichaingo/image": "1.4.41",
37
- "@ichaingo/link": "1.4.41",
38
- "@ichaingo/theme-toggle": "1.4.41",
39
- "@ichaingo/providers": "1.4.41",
40
- "@ichaingo/ui": "1.4.41",
41
- "@ichaingo/with-login": "1.4.41",
42
- "@ichaingo/iconfont": "1.4.41",
43
- "@ichaingo/request": "1.4.41",
44
- "@ichaingo/i18n": "1.4.41",
45
- "@ichaingo/tooltip": "1.4.41"
32
+ "@ichaingo/auth": "1.4.43",
33
+ "@ichaingo/avatar": "1.4.43",
34
+ "@ichaingo/better-link": "1.4.43",
35
+ "@ichaingo/image": "1.4.43",
36
+ "@ichaingo/theme-toggle": "1.4.43",
37
+ "@ichaingo/i18n": "1.4.43",
38
+ "@ichaingo/request": "1.4.43",
39
+ "@ichaingo/ui": "1.4.43",
40
+ "@ichaingo/with-login": "1.4.43",
41
+ "@ichaingo/link": "1.4.43",
42
+ "@ichaingo/translation": "1.4.43",
43
+ "@ichaingo/iconfont": "1.4.43",
44
+ "@ichaingo/tooltip": "1.4.43",
45
+ "@ichaingo/providers": "1.4.43"
46
46
  },
47
47
  "devDependencies": {
48
48
  "@types/js-cookie": "^3.0.6"