@nomos-ui/layout 0.0.2 → 0.0.3

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 +1 @@
1
- {"version":3,"file":"item.d.ts","sourceRoot":"","sources":["../../../../src/components/dashboard/sidebar/item.tsx"],"names":[],"mappings":"AACA,OAAO,EAAE,WAAW,EAAE,MAAM,cAAc,CAAC;AAE3C,OAAO,EACL,yBAAyB,EACzB,cAAc,EACd,aAAa,EACd,MAAM,OAAO,CAAC;AAGf,MAAM,MAAM,gBAAgB,GAAG;IAC7B,IAAI,EAAE,yBAAyB,CAC7B,IAAI,CAAC,WAAW,EAAE,KAAK,CAAC,GAAG,aAAa,CAAC,aAAa,CAAC,CACxD,CAAC;IACF,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,MAAM,CAAC;IACb,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,MAAM,CAAC,EAAE,OAAO,CAAC;CAClB,CAAC;AAEF,MAAM,CAAC,OAAO,UAAU,WAAW,CAAC,EAClC,IAAI,EACJ,IAAI,EACJ,IAAU,EACV,SAAS,EACT,MAAM,EACN,GAAG,KAAK,EACT,EAAE,gBAAgB,GAAG,cAAc,CAAC,aAAa,CAAC,2CA0BlD"}
1
+ {"version":3,"file":"item.d.ts","sourceRoot":"","sources":["../../../../src/components/dashboard/sidebar/item.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,cAAc,CAAC;AAE3C,OAAO,EACL,yBAAyB,EACzB,cAAc,EACd,aAAa,EACd,MAAM,OAAO,CAAC;AAGf,MAAM,MAAM,gBAAgB,GAAG;IAC7B,IAAI,EAAE,yBAAyB,CAC7B,IAAI,CAAC,WAAW,EAAE,KAAK,CAAC,GAAG,aAAa,CAAC,aAAa,CAAC,CACxD,CAAC;IACF,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,MAAM,CAAC;IACb,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,MAAM,CAAC,EAAE,OAAO,CAAC;CAClB,CAAC;AAEF,MAAM,CAAC,OAAO,UAAU,WAAW,CAAC,EAClC,IAAI,EACJ,IAAI,EACJ,IAAU,EACV,SAAS,EACT,MAAM,EACN,GAAG,KAAK,EACT,EAAE,gBAAgB,GAAG,cAAc,CAAC,aAAa,CAAC,2CA6BlD"}
@@ -1,13 +1,12 @@
1
1
  "use strict";
2
- var __importDefault = (this && this.__importDefault) || function (mod) {
3
- return (mod && mod.__esModule) ? mod : { "default": mod };
4
- };
5
2
  Object.defineProperty(exports, "__esModule", { value: true });
6
3
  exports.default = SidebarItem;
7
4
  const jsx_runtime_1 = require("react/jsx-runtime");
8
- const link_1 = __importDefault(require("next/link"));
5
+ const core_1 = require("@nomos-ui/core");
9
6
  const tailwind_merge_1 = require("tailwind-merge");
10
7
  function SidebarItem({ Icon, text, href = "/", className, active, ...props }) {
11
- return ((0, jsx_runtime_1.jsxs)("li", { "data-selected": active, ...props, className: (0, tailwind_merge_1.twMerge)("pr-0 ml-0 relative group/sidebar-item z-50 group", className), children: [(0, jsx_runtime_1.jsx)("div", { className: "h-full absolute w-[3px] bg-primary-300 rounded-l-md hidden group-data-[selected=true]:block" }), (0, jsx_runtime_1.jsxs)(link_1.default, { href: href, "aria-label": text, className: "flex items-center py-[4px] px-3 text-primary-500 rounded-md hover:bg-primary-50 group transition-all w-full group-data-[selected=true]:bg-primary-50 group-data-[selected=true]:text-primary-500 mb-1", children: [(0, jsx_runtime_1.jsx)(Icon, { strokeWidth: 2.5, width: 20, absoluteStrokeWidth: true }), (0, jsx_runtime_1.jsx)("span", { className: "ms-2 text-zinc-800 group-data-[selected=true]:text-primary-600 group-data-[hide-details=true]:hidden", children: text }), (0, jsx_runtime_1.jsx)("span", { className: "ms-3 group-data-[hide-details=false]:hidden group-hover/sidebar-item:block hidden fixed left-[52px] z-50 bg-white text-zinc-800 text-sm p-1 px-2 rounded-md w-fit text-nowrap card", children: text })] })] }));
8
+ const { components } = (0, core_1.useProvider)();
9
+ const Link = components?.Link?.component || components?.Link || "a";
10
+ return ((0, jsx_runtime_1.jsxs)("li", { "data-selected": active, ...props, className: (0, tailwind_merge_1.twMerge)("pr-0 ml-0 relative group/sidebar-item z-50 group", className), children: [(0, jsx_runtime_1.jsx)("div", { className: "h-full absolute w-[3px] bg-primary-300 rounded-l-md hidden group-data-[selected=true]:block" }), (0, jsx_runtime_1.jsxs)(Link, { [components?.Link?.hrefKey || "href"]: href, "aria-label": text, className: "flex items-center py-[4px] px-3 text-primary-500 rounded-md hover:bg-primary-50 group transition-all w-full group-data-[selected=true]:bg-primary-50 group-data-[selected=true]:text-primary-500 mb-1", children: [(0, jsx_runtime_1.jsx)(Icon, { strokeWidth: 2.5, width: 20, absoluteStrokeWidth: true }), (0, jsx_runtime_1.jsx)("span", { className: "ms-2 text-zinc-800 group-data-[selected=true]:text-primary-600 group-data-[hide-details=true]:hidden", children: text }), (0, jsx_runtime_1.jsx)("span", { className: "ms-3 group-data-[hide-details=false]:hidden group-hover/sidebar-item:block hidden fixed left-[52px] z-50 bg-white text-zinc-800 text-sm p-1 px-2 rounded-md w-fit text-nowrap card", children: text })] })] }));
12
11
  }
13
12
  //# sourceMappingURL=item.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"item.js","sourceRoot":"","sources":["../../../../src/components/dashboard/sidebar/item.tsx"],"names":[],"mappings":";;;;;AAoBA,8BAiCC;;AAnDD,qDAA6B;AAM7B,mDAAyC;AAYzC,SAAwB,WAAW,CAAC,EAClC,IAAI,EACJ,IAAI,EACJ,IAAI,GAAG,GAAG,EACV,SAAS,EACT,MAAM,EACN,GAAG,KAAK,EACyC;IACjD,OAAO,CACL,iDACiB,MAAM,KACjB,KAAK,EACT,SAAS,EAAE,IAAA,wBAAO,EAChB,kDAAkD,EAClD,SAAS,CACV,aAED,gCAAK,SAAS,EAAC,6FAA6F,GAAO,EACnH,wBAAC,cAAI,IACH,IAAI,EAAE,IAAI,gBACE,IAAI,EAChB,SAAS,EAAC,wMAAwM,aAElN,uBAAC,IAAI,IAAC,WAAW,EAAE,GAAG,EAAE,KAAK,EAAE,EAAE,EAAE,mBAAmB,SAAG,EACzD,iCAAM,SAAS,EAAC,sGAAsG,YACnH,IAAI,GACA,EACP,iCAAM,SAAS,EAAC,qLAAqL,YAClM,IAAI,GACA,IACF,IACJ,CACN,CAAC;AACJ,CAAC"}
1
+ {"version":3,"file":"item.js","sourceRoot":"","sources":["../../../../src/components/dashboard/sidebar/item.tsx"],"names":[],"mappings":";;AAmBA,8BAoCC;;AAtDD,yCAA6C;AAM7C,mDAAyC;AAYzC,SAAwB,WAAW,CAAC,EAClC,IAAI,EACJ,IAAI,EACJ,IAAI,GAAG,GAAG,EACV,SAAS,EACT,MAAM,EACN,GAAG,KAAK,EACyC;IACjD,MAAM,EAAE,UAAU,EAAE,GAAG,IAAA,kBAAW,GAAE,CAAC;IACrC,MAAM,IAAI,GAAG,UAAU,EAAE,IAAI,EAAE,SAAS,IAAI,UAAU,EAAE,IAAI,IAAI,GAAG,CAAC;IAEpE,OAAO,CACL,iDACiB,MAAM,KACjB,KAAK,EACT,SAAS,EAAE,IAAA,wBAAO,EAChB,kDAAkD,EAClD,SAAS,CACV,aAED,gCAAK,SAAS,EAAC,6FAA6F,GAAO,EACnH,wBAAC,IAAI,IACG,CAAC,UAAU,EAAE,IAAI,EAAE,OAAO,IAAI,MAAM,CAAC,EAAE,IAAI,gBACrC,IAAI,EAChB,SAAS,EAAC,wMAAwM,aAElN,uBAAC,IAAI,IAAC,WAAW,EAAE,GAAG,EAAE,KAAK,EAAE,EAAE,EAAE,mBAAmB,SAAG,EACzD,iCAAM,SAAS,EAAC,sGAAsG,YACnH,IAAI,GACA,EACP,iCAAM,SAAS,EAAC,qLAAqL,YAClM,IAAI,GACA,IACF,IACJ,CACN,CAAC;AACJ,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@nomos-ui/layout",
3
- "version": "0.0.2",
3
+ "version": "0.0.3",
4
4
  "description": "The Shadcn library for building robust React layouts",
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/exports/index.js",
@@ -79,7 +79,9 @@
79
79
  ],
80
80
  "sideEffects": false,
81
81
  "packageManager": "pnpm@10.13.1",
82
- "dependencies": {},
82
+ "dependencies": {
83
+ "@nomos-ui/core": "^0.0.5"
84
+ },
83
85
  "devDependencies": {
84
86
  "@types/node": "^24.9.1",
85
87
  "@types/react": "^19.2.2",
@@ -96,9 +98,6 @@
96
98
  "vitest": "^4.0.3"
97
99
  },
98
100
  "peerDependencies": {
99
- "react": "^18.0.0 || ^19.0.0",
100
- "react-dom": "^18.0.0 || ^19.0.0",
101
- "react-hook-form": "^7.0.0",
102
101
  "@nomos-ui/form": "^0.0.17",
103
102
  "@radix-ui/react-slot": "^1.2.3",
104
103
  "@tailwindcss/postcss": "^4.1.16",
@@ -106,6 +105,9 @@
106
105
  "class-variance-authority": "^0.7.1",
107
106
  "clsx": "^2.1.1",
108
107
  "lucide-react": "^0.548.0",
108
+ "react": "^18.0.0 || ^19.0.0",
109
+ "react-dom": "^18.0.0 || ^19.0.0",
110
+ "react-hook-form": "^7.0.0",
109
111
  "tailwind-merge": "^3.5.0"
110
112
  },
111
113
  "peerDependenciesMeta": {