@ncds/ui-admin 1.8.23-alpha.1 → 1.8.24
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/cjs/src/components/feedback-and-status/badge/Badge.js +1 -1
- package/dist/cjs/src/components/navigation/bread-crumb/BreadCrumb.js +6 -14
- package/dist/cjs/src/generated/scoped-css.js +1 -1
- package/dist/esm/src/components/feedback-and-status/badge/Badge.js +1 -1
- package/dist/esm/src/components/navigation/bread-crumb/BreadCrumb.js +6 -14
- package/dist/esm/src/generated/scoped-css.js +1 -1
- package/dist/temp/src/components/feedback-and-status/badge/Badge.d.ts +1 -1
- package/dist/temp/src/components/feedback-and-status/badge/Badge.js +1 -1
- package/dist/temp/src/components/navigation/bread-crumb/BreadCrumb.d.ts +1 -3
- package/dist/temp/src/components/navigation/bread-crumb/BreadCrumb.js +5 -9
- package/dist/temp/src/generated/scoped-css.js +1 -1
- package/dist/types/src/components/feedback-and-status/badge/Badge.d.ts +1 -1
- package/dist/types/src/components/navigation/bread-crumb/BreadCrumb.d.ts +1 -3
- package/dist/ui-admin/assets/styles/style.css +15 -13
- package/package.json +2 -2
- package/dist/cjs/src/components/navigation/bread-crumb/__tests__/BreadCrumb.test.js +0 -207
- package/dist/esm/src/components/navigation/bread-crumb/__tests__/BreadCrumb.test.js +0 -204
- package/dist/temp/src/components/navigation/bread-crumb/__tests__/BreadCrumb.test.d.ts +0 -1
- package/dist/temp/src/components/navigation/bread-crumb/__tests__/BreadCrumb.test.js +0 -161
- package/dist/types/src/components/navigation/bread-crumb/__tests__/BreadCrumb.test.d.ts +0 -1
|
@@ -4,15 +4,11 @@ import classNames from 'classnames';
|
|
|
4
4
|
const BreadcrumbItem = _ref => {
|
|
5
5
|
let {
|
|
6
6
|
href,
|
|
7
|
-
ariaLabel,
|
|
8
7
|
children
|
|
9
8
|
} = _ref;
|
|
10
9
|
const ElementType = href ? 'a' : 'span';
|
|
11
10
|
return _jsx(ElementType, {
|
|
12
11
|
href: href,
|
|
13
|
-
// <span> 은 generic role 이라 aria-label 이 무시될 수 있다. 링크는 이미 이름을 지원하므로 그대로 둔다
|
|
14
|
-
role: !href && ariaLabel ? 'img' : undefined,
|
|
15
|
-
"aria-label": ariaLabel,
|
|
16
12
|
className: "ncua-breadcrumb__item",
|
|
17
13
|
children: children
|
|
18
14
|
});
|
|
@@ -20,27 +16,23 @@ const BreadcrumbItem = _ref => {
|
|
|
20
16
|
const BreadCrumb = _ref2 => {
|
|
21
17
|
let {
|
|
22
18
|
items,
|
|
23
|
-
showHomeIcon = true,
|
|
24
19
|
className
|
|
25
20
|
} = _ref2;
|
|
26
21
|
if (!items || items.length === 0) return null;
|
|
27
22
|
const renderItem = (item, index) => {
|
|
28
23
|
const isLast = index === items.length - 1;
|
|
29
|
-
|
|
30
|
-
|
|
24
|
+
const content = index === 0 ? _jsx(Home01, {
|
|
25
|
+
width: 16,
|
|
26
|
+
height: 16,
|
|
27
|
+
color: "gray500"
|
|
28
|
+
}) : item.label;
|
|
31
29
|
return _jsx("li", {
|
|
32
30
|
className: classNames('ncua-breadcrumb__list-item', {
|
|
33
|
-
'ncua-breadcrumb__list-item--home': isHome,
|
|
34
31
|
'ncua-breadcrumb__list-item--active': isLast
|
|
35
32
|
}),
|
|
36
33
|
children: _jsx(BreadcrumbItem, {
|
|
37
34
|
href: isLast ? undefined : item.href,
|
|
38
|
-
|
|
39
|
-
children: isHome ? _jsx(Home01, {
|
|
40
|
-
width: 16,
|
|
41
|
-
height: 16,
|
|
42
|
-
color: "gray500"
|
|
43
|
-
}) : item.label
|
|
35
|
+
children: content
|
|
44
36
|
})
|
|
45
37
|
}, index);
|
|
46
38
|
};
|