@raketa-builder/builder 1.6.0 → 1.6.2

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.
@@ -161,7 +161,12 @@ const AdminSidebar = ({
161
161
  tooltip: button.label,
162
162
  className: button.className,
163
163
  icon,
164
- onClick: () => button.onClick(),
164
+ link: button.link || {},
165
+ onClick: () => {
166
+ if (button.onClick) {
167
+ button.onClick();
168
+ }
169
+ },
165
170
  children: icon ? "" : button.label
166
171
  }
167
172
  ) }, button.id);
@@ -101,7 +101,13 @@ const Tooltip = (_k) => {
101
101
  );
102
102
  };
103
103
  const NavButton = (_m) => {
104
- var _n = _m, { tooltip, hasChanges = true } = _n, props = __objRest(_n, ["tooltip", "hasChanges"]);
104
+ var _n = _m, { tooltip, link = {}, hasChanges = true } = _n, props = __objRest(_n, ["tooltip", "link", "hasChanges"]);
105
+ if (link.link) {
106
+ return /* @__PURE__ */ jsx("a", { href: link.link, target: link.target || "_self", children: /* @__PURE__ */ jsxs(TooltipWrapper, { children: [
107
+ /* @__PURE__ */ jsx(NavButtonStyle, __spreadProps(__spreadValues({}, props), { hasChanges })),
108
+ tooltip && /* @__PURE__ */ jsx(Tooltip, { className: "cms-tooltip", children: tooltip })
109
+ ] }) });
110
+ }
105
111
  return /* @__PURE__ */ jsxs(TooltipWrapper, { children: [
106
112
  /* @__PURE__ */ jsx(NavButtonStyle, __spreadProps(__spreadValues({}, props), { hasChanges })),
107
113
  tooltip && /* @__PURE__ */ jsx(Tooltip, { className: "cms-tooltip", children: tooltip })
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@raketa-builder/builder",
3
- "version": "1.6.0",
3
+ "version": "1.6.2",
4
4
  "type": "module",
5
5
  "main": "./dist/index.js",
6
6
  "module": "./dist/index.mjs",
@@ -31,8 +31,8 @@
31
31
  },
32
32
  "dependencies": {
33
33
  "react-sortablejs": "6.1.4",
34
- "@raketa-builder/support": "1.6.0",
35
- "@raketa-builder/ui": "1.6.0"
34
+ "@raketa-builder/support": "1.6.1",
35
+ "@raketa-builder/ui": "1.6.1"
36
36
  },
37
37
  "devDependencies": {
38
38
  "@biomejs/biome": "2.1.2",