@ncds/ui-admin 1.8.26-alpha.5 → 1.8.26-alpha.7

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.
Files changed (43) hide show
  1. package/dist/cjs/assets/scripts/notification/MessageNotification.js +6 -9
  2. package/dist/cjs/assets/scripts/notification/const/icons.js +17 -8
  3. package/dist/cjs/assets/scripts/notification/const/index.js +6 -0
  4. package/dist/cjs/constant/notification.js +0 -1
  5. package/dist/cjs/src/components/overlays/notification/FloatingNotification.js +1 -1
  6. package/dist/cjs/src/components/overlays/notification/MessageNotification.js +13 -9
  7. package/dist/cjs/src/components/overlays/notification/__tests__/MessageNotification.test.js +55 -13
  8. package/dist/cjs/src/generated/scoped-css.js +1 -1
  9. package/dist/cjs/vitest.config.js +12 -1
  10. package/dist/esm/assets/scripts/notification/MessageNotification.js +7 -10
  11. package/dist/esm/assets/scripts/notification/const/icons.js +16 -7
  12. package/dist/esm/assets/scripts/notification/const/index.js +1 -1
  13. package/dist/esm/constant/notification.js +0 -1
  14. package/dist/esm/src/components/overlays/notification/FloatingNotification.js +1 -1
  15. package/dist/esm/src/components/overlays/notification/MessageNotification.js +13 -9
  16. package/dist/esm/src/components/overlays/notification/__tests__/MessageNotification.test.js +55 -13
  17. package/dist/esm/src/generated/scoped-css.js +1 -1
  18. package/dist/esm/vitest.config.js +12 -1
  19. package/dist/temp/assets/scripts/notification/MessageNotification.d.ts +1 -1
  20. package/dist/temp/assets/scripts/notification/MessageNotification.js +7 -11
  21. package/dist/temp/assets/scripts/notification/const/icons.d.ts +6 -6
  22. package/dist/temp/assets/scripts/notification/const/icons.js +16 -7
  23. package/dist/temp/assets/scripts/notification/const/index.d.ts +1 -1
  24. package/dist/temp/assets/scripts/notification/const/index.js +1 -1
  25. package/dist/temp/assets/scripts/notification/const/types.d.ts +1 -1
  26. package/dist/temp/constant/notification.d.ts +0 -1
  27. package/dist/temp/constant/notification.js +0 -1
  28. package/dist/temp/src/components/overlays/notification/FloatingNotification.js +1 -1
  29. package/dist/temp/src/components/overlays/notification/MessageNotification.d.ts +1 -1
  30. package/dist/temp/src/components/overlays/notification/MessageNotification.js +9 -8
  31. package/dist/temp/src/components/overlays/notification/Notification.d.ts +2 -2
  32. package/dist/temp/src/components/overlays/notification/__tests__/MessageNotification.test.js +44 -9
  33. package/dist/temp/src/generated/scoped-css.js +1 -1
  34. package/dist/temp/vitest.config.js +11 -0
  35. package/dist/types/assets/scripts/notification/MessageNotification.d.ts +1 -1
  36. package/dist/types/assets/scripts/notification/const/icons.d.ts +6 -6
  37. package/dist/types/assets/scripts/notification/const/index.d.ts +1 -1
  38. package/dist/types/assets/scripts/notification/const/types.d.ts +1 -1
  39. package/dist/types/constant/notification.d.ts +0 -1
  40. package/dist/types/src/components/overlays/notification/MessageNotification.d.ts +1 -1
  41. package/dist/types/src/components/overlays/notification/Notification.d.ts +2 -2
  42. package/dist/ui-admin/assets/styles/style.css +17 -11
  43. package/package.json +2 -2
@@ -30,6 +30,17 @@ export default defineConfig({
30
30
  // 'text' 미포함 — 미커버 파일이 수백 개라 파일별 상세 출력이 CI 로그를 덮는다.
31
31
  // 'lcov' 대신 'lcovonly' — 'lcov' 는 HTML 리포트까지 생성한다.
32
32
  reporter: ['text-summary', ['lcovonly', { projectRoot: REPO_ROOT }]],
33
+ // 회귀 방지 하한선 — 실측에서 약 2%p 낮춘 값 (ui-admin-mcp 와 같은 여유폭).
34
+ // 실측 기준: 2026-10-12, 25cb4d96 — stmts 54.91 / branch 44.63 / funcs 55.20 / lines 55.80
35
+ // 최종 목표: 93 / 88 (lines 95 · branches 90). 테스트 보강 단계마다 실측 −2 로 인상한다.
36
+ // autoUpdate: false — 값은 실측을 확인하고 사람이 직접 올린다.
37
+ thresholds: {
38
+ autoUpdate: false,
39
+ statements: 53,
40
+ branches: 43,
41
+ functions: 53,
42
+ lines: 54,
43
+ },
33
44
  },
34
45
  },
35
46
  });
@@ -9,7 +9,7 @@ export declare class MessageNotification {
9
9
  private featuredIcon?;
10
10
  constructor(options: MessageNotificationOptions);
11
11
  private createElement;
12
- /** 색상별 FeaturedIcon. default 는 md(40/20), block 은 sm(32/16). */
12
+ /** 색상별 FeaturedIcon. default 는 md(40/20), block 은 sm(32/16). info 아이콘만 variant 별로 다르다. */
13
13
  private createFeaturedIcon;
14
14
  private bindEvents;
15
15
  private setupAutoClose;
@@ -1,4 +1,5 @@
1
1
  import type { NotificationColor } from './types';
2
+ type IconFunction = (size: string) => string;
2
3
  export declare const SVG_ICONS: {
3
4
  readonly 'pin-02': (size: string) => string;
4
5
  readonly 'alert-triangle': (size: string) => string;
@@ -23,9 +24,8 @@ export declare const ICON_MAP: {
23
24
  readonly success: (size: string) => string;
24
25
  readonly info: (size: string) => string;
25
26
  };
26
- /**
27
- * message 타입 아이콘. floating 과 같은 4색에 block 변형 전용 info 를 더한다.
28
- * `SVG_ICONS['info-circle']`은 full-width 전용 class·color 가 박혀 있어 쓰지 않는다
29
- * (`.ncua-full-width-notification__icon`은 모바일에서 숨겨진다).
30
- */
31
- export declare const MESSAGE_ICON_MAP: Partial<Record<NotificationColor, (size: string) => string>>;
27
+ /** message 기본 타입 아이콘. floating 과 같은 4색에 info(neutral 과 같은 핀)를 더한다. */
28
+ export declare const MESSAGE_ICON_MAP: Record<NotificationColor, IconFunction>;
29
+ /** block 변형 아이콘. info 만 InfoCircle 로 다르다 (#536 유지). */
30
+ export declare const MESSAGE_BLOCK_ICON_MAP: Record<NotificationColor, IconFunction>;
31
+ export {};
@@ -1,4 +1,4 @@
1
1
  export { CLASS_NAMES } from './classNames';
2
- export { FLOATING_ICON_MAP, FULL_WIDTH_ICON_MAP, ICON_MAP, MESSAGE_ICON_MAP, SVG_ICONS } from './icons';
2
+ export { FLOATING_ICON_MAP, FULL_WIDTH_ICON_MAP, ICON_MAP, MESSAGE_BLOCK_ICON_MAP, MESSAGE_ICON_MAP, SVG_ICONS, } from './icons';
3
3
  export { CLOSE_BUTTON_SIZES, CLOSE_BUTTON_SVG_SIZES, FEATURED_ICON_SIZES, FULL_WIDTH_SIZES, getSizes, ICON_PIXEL_SIZES, MESSAGE_BLOCK_SIZES, MESSAGE_SIZES, } from './sizes';
4
4
  export type { BaseNotificationOptions, LegacyNotificationHierarchy, NotificationAction, NotificationActionButtonSize, NotificationColor, NotificationHierarchy, NotificationLinkTarget, NotificationVariant, } from './types';
@@ -2,7 +2,7 @@ export type NotificationColor = 'neutral' | 'error' | 'warning' | 'success' | 'i
2
2
  /**
3
3
  * message 타입의 표시 변형. React `NotificationVariant`와 같은 어휘다.
4
4
  * - `'default'`: 기존 message
5
- * - `'block'`: 서브 페이지 공지용 (흰 배경, FeaturedIcon sm, 제목 + 텍스트 링크 1행, info 유지)
5
+ * - `'block'`: 서브 페이지 공지용 (흰 배경, FeaturedIcon sm, 제목 + 텍스트 링크 1행, info 아이콘 InfoCircle)
6
6
  */
7
7
  export type NotificationVariant = 'default' | 'block';
8
8
  /**
@@ -17,7 +17,6 @@ export declare const HIDE_PERMANENTLY_LABEL: {
17
17
  * message 타입 닫기(X) 아이콘의 color 별 색.
18
18
  *
19
19
  * React(`MessageNotification.tsx`)와 Vanilla(`messageTemplate.ts`)가 함께 참조하는 단일 출처다.
20
- * `info`는 `variant: 'block'`에서만 렌더된다(default 는 neutral 로 폴백).
21
20
  */
22
21
  export declare const MESSAGE_CLOSE_ICON_COLOR: {
23
22
  readonly neutral: string;
@@ -54,7 +54,7 @@ interface MessageNotificationProps extends Omit<ComponentPropsWithoutRef<'div'>,
54
54
  */
55
55
  hidePermanentlyLabel?: ReactNode;
56
56
  /**
57
- * 표시 변형. `'block'`은 서브 페이지 공지용(흰 배경, FeaturedIcon sm, 제목 + 텍스트 링크 1행, info 유지)
57
+ * 표시 변형. `'block'`은 서브 페이지 공지용(흰 배경, FeaturedIcon sm, 제목 + 텍스트 링크 1행)
58
58
  * @default 'default'
59
59
  */
60
60
  variant?: NotificationVariant;
@@ -107,10 +107,10 @@ interface NotificationProps extends Omit<ComponentPropsWithoutRef<'div'>, 'title
107
107
  /**
108
108
  * message 타입의 표시 변형 (선택사항). message 타입에서만 동작한다.
109
109
  *
110
- * - `'default'`: 기존 message (color 별 배경·테두리, 제목 + 본문 2행, info → neutral 폴백)
110
+ * - `'default'`: 기존 message (color 별 배경·테두리, 제목 + 본문 2행)
111
111
  * - `'block'`: 서브 페이지 공지용. 흰 배경·gray-100 테두리·shadow-sm, FeaturedIcon sm,
112
112
  * 제목 + 텍스트 링크 1행(`supportingText` 가 링크 텍스트, `supportTextLink` 가 href).
113
- * `color="info"` 를 그대로 렌더한다.
113
+ * info 아이콘은 InfoCircle.
114
114
  *
115
115
  * @default 'default'
116
116
  */
@@ -3060,6 +3060,22 @@ button {
3060
3060
  .ncua-message-notification--success .ncua-notification__action-button {
3061
3061
  color: var(--green-500);
3062
3062
  }
3063
+ .ncua-message-notification--info {
3064
+ color: var(--violet-600);
3065
+ background-color: var(--violet-50);
3066
+ border-radius: 12px;
3067
+ border: 1px solid var(--violet-300);
3068
+ box-shadow: var(--shadow-md);
3069
+ }
3070
+ .ncua-message-notification--info .ncua-message-notification__title {
3071
+ color: var(--violet-600);
3072
+ }
3073
+ .ncua-message-notification--info .ncua-message-notification__supporting-text {
3074
+ color: var(--gray-500);
3075
+ }
3076
+ .ncua-message-notification--info .ncua-notification__action-button {
3077
+ color: var(--violet-500);
3078
+ }
3063
3079
  .ncua-message-notification .ncua-notification__action-button {
3064
3080
  background: transparent;
3065
3081
  border: none;
@@ -3072,12 +3088,8 @@ button {
3072
3088
  .ncua-message-notification.ncua-message-notification--block {
3073
3089
  background-color: var(--base-white);
3074
3090
  border: 1px solid var(--gray-100);
3075
- border-radius: 12px;
3076
3091
  box-shadow: var(--shadow-sm);
3077
3092
  }
3078
- .ncua-message-notification.ncua-message-notification--block .ncua-message-notification__supporting-text {
3079
- color: var(--gray-500);
3080
- }
3081
3093
  .ncua-message-notification.ncua-message-notification--block .ncua-message-notification__text-container {
3082
3094
  flex-direction: row;
3083
3095
  flex-wrap: wrap;
@@ -3087,13 +3099,7 @@ button {
3087
3099
  .ncua-message-notification.ncua-message-notification--block .ncua-message-notification__link .ncua-message-notification__supporting-text {
3088
3100
  color: inherit;
3089
3101
  }
3090
- .ncua-message-notification.ncua-message-notification--block.ncua-message-notification--info {
3091
- color: var(--violet-600);
3092
- }
3093
- .ncua-message-notification.ncua-message-notification--block.ncua-message-notification--info .ncua-message-notification__title {
3094
- color: var(--violet-600);
3095
- }
3096
- .ncua-message-notification.ncua-message-notification--block.ncua-message-notification--info .ncua-message-notification__icon {
3102
+ .ncua-message-notification.ncua-message-notification--info .ncua-message-notification__icon {
3097
3103
  color: var(--violet-600);
3098
3104
  background-color: var(--violet-100);
3099
3105
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ncds/ui-admin",
3
- "version": "1.8.26-alpha.5",
3
+ "version": "1.8.26-alpha.7",
4
4
  "description": "nhn-commerce의 어드민 디자인 시스템입니다.",
5
5
  "scripts": {
6
6
  "barrel": "node barrel.js",
@@ -78,7 +78,7 @@
78
78
  "@atlaskit/pragmatic-drag-and-drop-auto-scroll": "2.1.0",
79
79
  "@atlaskit/pragmatic-drag-and-drop-hitbox": "1.1.0",
80
80
  "@atlaskit/pragmatic-drag-and-drop-react-accessibility": "1.1.4",
81
- "@ncds/ui-admin-icon": "0.1.13",
81
+ "@ncds/ui-admin-icon": "0.1.14",
82
82
  "classnames": "2.5.1",
83
83
  "dompurify": "3.4.12",
84
84
  "flatpickr": "4.6.13",