@camped-ui/breadcrumb 2.0.1 → 2.0.2
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/index.d.ts +31 -17
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +172 -53
- package/dist/index.js.map +1 -1
- package/package.json +4 -1
package/dist/index.d.ts
CHANGED
@@ -1,20 +1,34 @@
|
|
1
|
-
|
2
|
-
|
3
|
-
|
4
|
-
}
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
}
|
10
|
-
declare const BreadcrumbPage: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, "ref"> & React.RefAttributes<HTMLSpanElement>>;
|
11
|
-
declare const BreadcrumbSeparator: {
|
12
|
-
({ children, className, ...props }: React.ComponentProps<"li">): import("react/jsx-runtime").JSX.Element;
|
13
|
-
displayName: string;
|
14
|
-
};
|
15
|
-
declare const BreadcrumbEllipsis: {
|
16
|
-
({ className, ...props }: React.ComponentProps<"span">): import("react/jsx-runtime").JSX.Element;
|
1
|
+
/// <reference types="react" />
|
2
|
+
import { buttonVariants } from "@camped-ui/button";
|
3
|
+
import * as PopoverPrimitive from "@radix-ui/react-popover";
|
4
|
+
import { VariantProps } from "class-variance-authority";
|
5
|
+
interface BreadCrumbProps extends React.HTMLAttributes<HTMLDivElement>, VariantProps<typeof buttonVariants> {
|
6
|
+
orientation?: "horizontal" | "vertical";
|
7
|
+
}
|
8
|
+
declare const Breadcrumb: {
|
9
|
+
({ className, orientation, variant, dir, size, children, ...props }: BreadCrumbProps): import("react/jsx-runtime").JSX.Element;
|
17
10
|
displayName: string;
|
18
11
|
};
|
19
|
-
|
12
|
+
declare const BreadcrumbItem: import("react").ForwardRefExoticComponent<(import("react").HTMLAttributes<HTMLDivElement> & ({
|
13
|
+
index: number;
|
14
|
+
} & ({
|
15
|
+
isActive: boolean;
|
16
|
+
activeVariant?: VariantProps<typeof buttonVariants>;
|
17
|
+
} | {
|
18
|
+
isActive?: undefined;
|
19
|
+
activeVariant?: undefined;
|
20
|
+
}))) & import("react").RefAttributes<HTMLDivElement>>;
|
21
|
+
declare const BreadcrumbLink: import("react").ForwardRefExoticComponent<Omit<import("react").DetailedHTMLProps<import("react").AnchorHTMLAttributes<HTMLAnchorElement>, HTMLAnchorElement>, "ref"> & {
|
22
|
+
asChild?: boolean;
|
23
|
+
} & import("react").RefAttributes<HTMLAnchorElement>>;
|
24
|
+
declare const BreadcrumbSeparator: import("react").ForwardRefExoticComponent<import("react").HTMLAttributes<HTMLSpanElement> & import("react").RefAttributes<HTMLSpanElement>>;
|
25
|
+
declare const BreadcrumbList: import("react").ForwardRefExoticComponent<Omit<import("react").DetailedHTMLProps<import("react").OlHTMLAttributes<HTMLOListElement>, HTMLOListElement>, "ref"> & import("react").RefAttributes<HTMLOListElement>>;
|
26
|
+
declare const BreadcrumbPage: import("react").ForwardRefExoticComponent<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, "ref"> & import("react").RefAttributes<HTMLSpanElement>>;
|
27
|
+
declare const BreadcrumbEllipsis: import("react").ForwardRefExoticComponent<{
|
28
|
+
index: number;
|
29
|
+
} & import("react").HTMLAttributes<HTMLSpanElement> & import("react").RefAttributes<HTMLSpanElement>>;
|
30
|
+
declare const BreadcrumbPopover: import("react").ForwardRefExoticComponent<import("react").HTMLAttributes<HTMLDivElement> & import("react").RefAttributes<PopoverPrimitive.PopoverProps>>;
|
31
|
+
declare const BreadcrumbTrigger: import("react").ForwardRefExoticComponent<PopoverPrimitive.PopoverTriggerProps & import("react").RefAttributes<HTMLButtonElement>>;
|
32
|
+
declare const BreadcrumbContent: import("react").ForwardRefExoticComponent<Omit<PopoverPrimitive.PopoverContentProps & import("react").RefAttributes<HTMLDivElement>, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
|
33
|
+
export { Breadcrumb, BreadcrumbLink, BreadcrumbEllipsis, BreadcrumbSeparator, BreadcrumbList, BreadcrumbPage, BreadcrumbItem, BreadcrumbPopover, BreadcrumbTrigger, BreadcrumbContent, };
|
20
34
|
//# sourceMappingURL=index.d.ts.map
|
package/dist/index.d.ts.map
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.tsx"],"names":[],"mappings":"
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.tsx"],"names":[],"mappings":";AAEA,OAAO,EAAE,cAAc,EAAE,MAAM,mBAAmB,CAAC;AAInD,OAAO,KAAK,gBAAgB,MAAM,yBAAyB,CAAC;AAE5D,OAAO,EAAE,YAAY,EAAE,MAAM,0BAA0B,CAAC;AAaxD,UAAU,eACR,SAAQ,KAAK,CAAC,cAAc,CAAC,cAAc,CAAC,EAC1C,YAAY,CAAC,OAAO,cAAc,CAAC;IACrC,WAAW,CAAC,EAAE,YAAY,GAAG,UAAU,CAAC;CACzC;AAwBD,QAAA,MAAM,UAAU;yEAQb,eAAe;;CA8GjB,CAAC;AAkBF,QAAA,MAAM,cAAc;WAZP,MAAM;;cAGC,OAAO;oBACD,aAAa,qBAAqB,CAAC;;eAGxC,SAAS;oBACJ,SAAS;qDAsDjC,CAAC;AAIH,QAAA,MAAM,cAAc;cAGN,OAAO;qDAYnB,CAAC;AAGH,QAAA,MAAM,mBAAmB,6IAuBvB,CAAC;AAIH,QAAA,MAAM,cAAc,mNAYlB,CAAC;AAGH,QAAA,MAAM,cAAc,8MAYlB,CAAC;AAEH,QAAA,MAAM,kBAAkB;WAEb,MAAM;qGA6Bf,CAAC;AAIH,QAAA,MAAM,iBAAiB,0JAUrB,CAAC;AAIH,QAAA,MAAM,iBAAiB,oIAAiB,CAAC;AAIzC,QAAA,MAAM,iBAAiB,8LAerB,CAAC;AAIH,OAAO,EACL,UAAU,EACV,cAAc,EACd,kBAAkB,EAClB,mBAAmB,EACnB,cAAc,EACd,cAAc,EACd,cAAc,EACd,iBAAiB,EACjB,iBAAiB,EACjB,iBAAiB,GAClB,CAAC"}
|
package/dist/index.js
CHANGED
@@ -1,27 +1,5 @@
|
|
1
|
+
"use client";
|
1
2
|
"use strict";
|
2
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
3
|
-
if (k2 === undefined) k2 = k;
|
4
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
5
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
6
|
-
desc = { enumerable: true, get: function() { return m[k]; } };
|
7
|
-
}
|
8
|
-
Object.defineProperty(o, k2, desc);
|
9
|
-
}) : (function(o, m, k, k2) {
|
10
|
-
if (k2 === undefined) k2 = k;
|
11
|
-
o[k2] = m[k];
|
12
|
-
}));
|
13
|
-
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
14
|
-
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
15
|
-
}) : function(o, v) {
|
16
|
-
o["default"] = v;
|
17
|
-
});
|
18
|
-
var __importStar = (this && this.__importStar) || function (mod) {
|
19
|
-
if (mod && mod.__esModule) return mod;
|
20
|
-
var result = {};
|
21
|
-
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
22
|
-
__setModuleDefault(result, mod);
|
23
|
-
return result;
|
24
|
-
};
|
25
3
|
var __rest = (this && this.__rest) || function (s, e) {
|
26
4
|
var t = {};
|
27
5
|
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
|
@@ -34,53 +12,194 @@ var __rest = (this && this.__rest) || function (s, e) {
|
|
34
12
|
return t;
|
35
13
|
};
|
36
14
|
Object.defineProperty(exports, "__esModule", { value: true });
|
37
|
-
exports.
|
15
|
+
exports.BreadcrumbContent = exports.BreadcrumbTrigger = exports.BreadcrumbPopover = exports.BreadcrumbItem = exports.BreadcrumbPage = exports.BreadcrumbList = exports.BreadcrumbSeparator = exports.BreadcrumbEllipsis = exports.BreadcrumbLink = exports.Breadcrumb = void 0;
|
38
16
|
const jsx_runtime_1 = require("react/jsx-runtime");
|
39
|
-
const
|
40
|
-
const react_slot_1 = require("@radix-ui/react-slot");
|
41
|
-
const react_icons_1 = require("@radix-ui/react-icons");
|
17
|
+
const button_1 = require("@camped-ui/button");
|
42
18
|
const lib_1 = require("@camped-ui/lib");
|
43
|
-
const
|
44
|
-
|
45
|
-
|
46
|
-
|
19
|
+
const popover_1 = require("@camped-ui/popover");
|
20
|
+
const react_icons_1 = require("@radix-ui/react-icons");
|
21
|
+
const react_slot_1 = require("@radix-ui/react-slot");
|
22
|
+
const react_1 = require("react");
|
23
|
+
const BreadCrumbContext = (0, react_1.createContext)(null);
|
24
|
+
const useBreadcrumb = () => {
|
25
|
+
const context = (0, react_1.useContext)(BreadCrumbContext);
|
26
|
+
if (!context) {
|
27
|
+
throw new Error("useBreadcrumb must be used within a BreadCrumb");
|
28
|
+
}
|
29
|
+
return context;
|
30
|
+
};
|
31
|
+
const Breadcrumb = (_a) => {
|
32
|
+
var { className, orientation = "horizontal", variant, dir, size, children } = _a, props = __rest(_a, ["className", "orientation", "variant", "dir", "size", "children"]);
|
33
|
+
const [value, setValue] = (0, react_1.useState)([]);
|
34
|
+
const [prevValue, setPrevValue] = (0, react_1.useState)([]);
|
35
|
+
const [activeIndex, setActiveIndex] = (0, react_1.useState)(-1);
|
36
|
+
const [open, setOpen] = (0, react_1.useState)(false);
|
37
|
+
const [target, setTarget] = (0, react_1.useState)(0);
|
38
|
+
const handleKeyDown = (0, react_1.useCallback)((e) => {
|
39
|
+
e.preventDefault();
|
40
|
+
const length = value.length - 1;
|
41
|
+
const moveNext = () => {
|
42
|
+
const nextIndex = activeIndex + 1 > length ? 0 : activeIndex + 1;
|
43
|
+
setActiveIndex(value[nextIndex]);
|
44
|
+
};
|
45
|
+
const movePrev = () => {
|
46
|
+
const currentIndex = value.indexOf(activeIndex) - 1;
|
47
|
+
const prevIndex = currentIndex < 0 ? length : currentIndex;
|
48
|
+
setActiveIndex(value[prevIndex]);
|
49
|
+
};
|
50
|
+
switch (e.key) {
|
51
|
+
case "ArrowDown":
|
52
|
+
if (orientation === "vertical") {
|
53
|
+
moveNext();
|
54
|
+
}
|
55
|
+
break;
|
56
|
+
case "ArrowUp":
|
57
|
+
if (orientation === "vertical") {
|
58
|
+
movePrev();
|
59
|
+
}
|
60
|
+
break;
|
61
|
+
case "ArrowRight":
|
62
|
+
if (orientation === "horizontal") {
|
63
|
+
if (dir === "rtl") {
|
64
|
+
movePrev();
|
65
|
+
return;
|
66
|
+
}
|
67
|
+
moveNext();
|
68
|
+
}
|
69
|
+
break;
|
70
|
+
case "ArrowLeft":
|
71
|
+
if (orientation === "horizontal") {
|
72
|
+
if (dir === "rtl") {
|
73
|
+
moveNext();
|
74
|
+
return;
|
75
|
+
}
|
76
|
+
movePrev();
|
77
|
+
}
|
78
|
+
break;
|
79
|
+
}
|
80
|
+
if (e.key === "Escape") {
|
81
|
+
if (activeIndex !== -1) {
|
82
|
+
if (prevValue.length > 0)
|
83
|
+
setValue(prevValue);
|
84
|
+
setOpen(false);
|
85
|
+
if (value.includes(activeIndex) &&
|
86
|
+
!prevValue.includes(activeIndex) &&
|
87
|
+
prevValue.length > 0) {
|
88
|
+
setActiveIndex(target);
|
89
|
+
return;
|
90
|
+
}
|
91
|
+
setActiveIndex(-1);
|
92
|
+
}
|
93
|
+
}
|
94
|
+
else if (e.key === "Enter" && activeIndex === target) {
|
95
|
+
if (prevValue.length > 0)
|
96
|
+
setValue(prevValue);
|
97
|
+
setOpen(!open);
|
98
|
+
}
|
99
|
+
}, [activeIndex, value, prevValue]);
|
100
|
+
return ((0, jsx_runtime_1.jsx)(BreadCrumbContext.Provider, { value: {
|
101
|
+
variant,
|
102
|
+
size,
|
103
|
+
orientation,
|
104
|
+
activeIndex,
|
105
|
+
value,
|
106
|
+
onValueChange: setValue,
|
107
|
+
onPrevValueChange: setPrevValue,
|
108
|
+
setActiveIndex,
|
109
|
+
open,
|
110
|
+
onOpenChange: setOpen,
|
111
|
+
setTarget,
|
112
|
+
}, children: (0, jsx_runtime_1.jsx)("div", Object.assign({ tabIndex: 0, onKeyDownCapture: handleKeyDown, className: (0, lib_1.cn)("flex items-center justify-center flex-wrap gap-2", {
|
113
|
+
"flex-row": orientation === "horizontal",
|
114
|
+
"flex-col": orientation === "vertical",
|
115
|
+
}, className), dir: dir }, props, { children: children })) }));
|
116
|
+
};
|
47
117
|
exports.Breadcrumb = Breadcrumb;
|
48
118
|
Breadcrumb.displayName = "Breadcrumb";
|
49
|
-
const
|
50
|
-
var { className } = _a, props = __rest(_a, ["className"]);
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
|
56
|
-
|
57
|
-
|
119
|
+
const BreadcrumbItem = (0, react_1.forwardRef)((_a, ref) => {
|
120
|
+
var { className, isActive, activeVariant, index, children } = _a, props = __rest(_a, ["className", "isActive", "activeVariant", "index", "children"]);
|
121
|
+
const { variant, size, activeIndex, value, onValueChange, setActiveIndex, onPrevValueChange, } = useBreadcrumb();
|
122
|
+
const variants = {
|
123
|
+
variant,
|
124
|
+
size,
|
125
|
+
};
|
126
|
+
const activeVariants = activeVariant !== null && activeVariant !== void 0 ? activeVariant : variants;
|
127
|
+
const Variants = isActive ? activeVariants : variants;
|
128
|
+
const isSelected = activeIndex === index;
|
129
|
+
(0, react_1.useEffect)(() => {
|
130
|
+
onValueChange((prev) => {
|
131
|
+
if (prev.includes(index)) {
|
132
|
+
return prev;
|
133
|
+
}
|
134
|
+
const arr = [...prev, index];
|
135
|
+
return arr.sort((a, b) => Number(a) - Number(b));
|
136
|
+
});
|
137
|
+
return () => {
|
138
|
+
onPrevValueChange(value);
|
139
|
+
};
|
140
|
+
}, [index, onValueChange]);
|
141
|
+
return ((0, jsx_runtime_1.jsx)("div", Object.assign({ ref: ref, className: (0, lib_1.cn)((0, button_1.buttonVariants)(Variants), className, isSelected ? "bg-muted focus-visible:ring-0 ring-0" : ""), onClick: () => setActiveIndex(index) }, props, { children: children })));
|
58
142
|
});
|
59
143
|
exports.BreadcrumbItem = BreadcrumbItem;
|
60
144
|
BreadcrumbItem.displayName = "BreadcrumbItem";
|
61
|
-
const BreadcrumbLink =
|
145
|
+
const BreadcrumbLink = (0, react_1.forwardRef)((_a, ref) => {
|
62
146
|
var { asChild, className } = _a, props = __rest(_a, ["asChild", "className"]);
|
63
147
|
const Comp = asChild ? react_slot_1.Slot : "a";
|
64
148
|
return ((0, jsx_runtime_1.jsx)(Comp, Object.assign({ ref: ref, className: (0, lib_1.cn)("transition-colors hover:text-foreground", className) }, props)));
|
65
149
|
});
|
66
150
|
exports.BreadcrumbLink = BreadcrumbLink;
|
67
151
|
BreadcrumbLink.displayName = "BreadcrumbLink";
|
68
|
-
const
|
152
|
+
const BreadcrumbSeparator = (0, react_1.forwardRef)((_a, ref) => {
|
153
|
+
var { className, children } = _a, props = __rest(_a, ["className", "children"]);
|
154
|
+
const { orientation, dir } = useBreadcrumb();
|
155
|
+
return ((0, jsx_runtime_1.jsxs)("span", Object.assign({ ref: ref }, props, { dir: dir, "data-orientation": orientation, className: (0, lib_1.cn)("flex items-center justify-center size-4 data-[orientation='horizontal']:rotate-0 rtl:data-[orientation='horizontal']:rotate-180 data-[orientation='vertical']:rotate-90 "), children: [children ? (children) : ((0, jsx_runtime_1.jsx)(react_icons_1.ChevronRightIcon, { className: (0, lib_1.cn)("h-4 w-4 ", className) })), (0, jsx_runtime_1.jsx)("span", { className: "sr-only", children: "next page" })] })));
|
156
|
+
});
|
157
|
+
exports.BreadcrumbSeparator = BreadcrumbSeparator;
|
158
|
+
BreadcrumbSeparator.displayName = "BreadcrumbSeparator";
|
159
|
+
const BreadcrumbList = (0, react_1.forwardRef)((_a, ref) => {
|
160
|
+
var { className } = _a, props = __rest(_a, ["className"]);
|
161
|
+
return ((0, jsx_runtime_1.jsx)("ol", Object.assign({ ref: ref, className: (0, lib_1.cn)("flex flex-wrap items-center gap-1.5 break-words text-sm text-muted-foreground sm:gap-2.5", className) }, props)));
|
162
|
+
});
|
163
|
+
exports.BreadcrumbList = BreadcrumbList;
|
164
|
+
BreadcrumbList.displayName = "BreadcrumbList";
|
165
|
+
const BreadcrumbPage = (0, react_1.forwardRef)((_a, ref) => {
|
69
166
|
var { className } = _a, props = __rest(_a, ["className"]);
|
70
167
|
return ((0, jsx_runtime_1.jsx)("span", Object.assign({ ref: ref, role: "link", "aria-disabled": "true", "aria-current": "page", className: (0, lib_1.cn)("font-normal text-foreground", className) }, props)));
|
71
168
|
});
|
72
169
|
exports.BreadcrumbPage = BreadcrumbPage;
|
73
170
|
BreadcrumbPage.displayName = "BreadcrumbPage";
|
74
|
-
const
|
75
|
-
var {
|
76
|
-
|
77
|
-
|
78
|
-
|
79
|
-
|
80
|
-
|
81
|
-
|
82
|
-
|
83
|
-
}
|
171
|
+
const BreadcrumbEllipsis = (0, react_1.forwardRef)((_a, ref) => {
|
172
|
+
var { className, index } = _a, props = __rest(_a, ["className", "index"]);
|
173
|
+
const { activeIndex, onValueChange, setTarget } = useBreadcrumb();
|
174
|
+
const isSelected = activeIndex === index;
|
175
|
+
(0, react_1.useEffect)(() => {
|
176
|
+
setTarget(index);
|
177
|
+
onValueChange((prev) => {
|
178
|
+
if (prev.includes(index)) {
|
179
|
+
return prev;
|
180
|
+
}
|
181
|
+
const arr = [...prev, index];
|
182
|
+
return arr.sort((a, b) => Number(a) - Number(b));
|
183
|
+
});
|
184
|
+
}, [index, onValueChange]);
|
185
|
+
return ((0, jsx_runtime_1.jsxs)("span", Object.assign({ ref: ref, "aria-hidden": true, className: (0, lib_1.cn)("focus-visible:ring-0 focus-visible:ring-opacity-0", className, isSelected ? "bg-muted" : "") }, props, { children: [(0, jsx_runtime_1.jsx)(react_icons_1.DotsHorizontalIcon, { className: "h-4 w-4 " }), (0, jsx_runtime_1.jsx)("span", { className: "sr-only", children: "More pages" })] })));
|
186
|
+
});
|
84
187
|
exports.BreadcrumbEllipsis = BreadcrumbEllipsis;
|
85
|
-
BreadcrumbEllipsis.displayName = "
|
188
|
+
BreadcrumbEllipsis.displayName = "BreadcrumbEllipsis";
|
189
|
+
const BreadcrumbPopover = (0, react_1.forwardRef)(({ children }, ref) => {
|
190
|
+
const { open, onOpenChange } = useBreadcrumb();
|
191
|
+
return ((0, jsx_runtime_1.jsx)(popover_1.Popover, { open: open, onOpenChange: onOpenChange, children: children }));
|
192
|
+
});
|
193
|
+
exports.BreadcrumbPopover = BreadcrumbPopover;
|
194
|
+
BreadcrumbPopover.displayName = "BreadcrumbPopover";
|
195
|
+
const BreadcrumbTrigger = popover_1.PopoverTrigger;
|
196
|
+
exports.BreadcrumbTrigger = BreadcrumbTrigger;
|
197
|
+
BreadcrumbTrigger.displayName = "BreadcrumbTrigger";
|
198
|
+
const BreadcrumbContent = (0, react_1.forwardRef)((_a, ref) => {
|
199
|
+
var { children } = _a, props = __rest(_a, ["children"]);
|
200
|
+
const { orientation } = useBreadcrumb();
|
201
|
+
return ((0, jsx_runtime_1.jsx)(popover_1.PopoverContent, Object.assign({}, props, { side: orientation === "horizontal" ? "bottom" : "right", ref: ref, children: children })));
|
202
|
+
});
|
203
|
+
exports.BreadcrumbContent = BreadcrumbContent;
|
204
|
+
BreadcrumbContent.displayName = "BreadcrumbContent";
|
86
205
|
//# sourceMappingURL=index.js.map
|
package/dist/index.js.map
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.tsx"],"names":[],"mappings":"
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.tsx"],"names":[],"mappings":"AAAA,YAAY,CAAC;;;;;;;;;;;;;;;;AAEb,8CAAmD;AACnD,wCAAoC;AACpC,gDAA6E;AAC7E,uDAA6E;AAE7E,qDAA4C;AAE5C,iCAUe;AAoBf,MAAM,iBAAiB,GAAG,IAAA,qBAAa,EAAgC,IAAI,CAAC,CAAC;AAE7E,MAAM,aAAa,GAAG,GAAG,EAAE;IACzB,MAAM,O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,EAAE,EAAE;QAA/B,EAAE,QAAQ,OAAY,EAAP,KAAK,cAApB,YAAsB,CAAF;IACrB,MAAM,EAAE,WAAW,EAAE,GAAG,aAAa,EAAE,CAAC;IAExC,OAAO,CACL,uBAAC,wBAAc,oBACT,KAAK,IACT,IAAI,EAAE,WAAW,KAAK,YAAY,CAAC,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC,OAAO,EACvD,GAAG,EAAE,GAAG,YAEP,QAAQ,IACM,CAClB,CAAC;AACJ,CAAC,CAAC,CAAC;AAcD,8CAAiB;AAZnB,iBAAiB,CAAC,WAAW,GAAG,mBAAmB,CAAC"}
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@camped-ui/breadcrumb",
|
3
|
-
"version": "2.0.
|
3
|
+
"version": "2.0.2",
|
4
4
|
"main": "dist/index.js",
|
5
5
|
"scripts": {
|
6
6
|
"publish-package": "npm publish --access public",
|
@@ -8,8 +8,11 @@
|
|
8
8
|
"clean": "rimraf dist"
|
9
9
|
},
|
10
10
|
"dependencies": {
|
11
|
+
"@camped-ui/button": "^2.1.1",
|
11
12
|
"@camped-ui/lib": "^2.0.2",
|
13
|
+
"@camped-ui/popover": "^2.1.0",
|
12
14
|
"@radix-ui/react-icons": "^1.3.0",
|
15
|
+
"@radix-ui/react-popover": "^1.0.7",
|
13
16
|
"@radix-ui/react-slot": "^1.0.2",
|
14
17
|
"class-variance-authority": "^0.4.0"
|
15
18
|
},
|