@ihabdevteam/core 0.456.0 → 0.458.0

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 (30) hide show
  1. package/CHANGELOG.md +31 -0
  2. package/dist/components.cjs.js +183 -183
  3. package/dist/components.esm.css +1 -1
  4. package/dist/hooks.cjs.js +1 -1
  5. package/dist/i18n.cjs.js +1 -1
  6. package/dist/ihabdevteam-core.cjs.js +188 -188
  7. package/dist/ihabdevteam-core.d.ts +58 -4
  8. package/dist/packages/core/src/components/BarChart.js +1 -1
  9. package/dist/packages/core/src/components/BottomNav.js +4 -3
  10. package/dist/packages/core/src/components/ChartSection.js +3 -2
  11. package/dist/packages/core/src/components/FolderGrid.css +2 -0
  12. package/dist/packages/core/src/components/FolderGrid.d.ts +17 -2
  13. package/dist/packages/core/src/components/FolderGrid.js +4 -4
  14. package/dist/packages/core/src/components/FolderHead.d.ts +4 -1
  15. package/dist/packages/core/src/components/FolderHead.js +2 -2
  16. package/dist/packages/core/src/components/Header.js +3 -2
  17. package/dist/packages/core/src/components/PassCard/PassCard.js +3 -3
  18. package/dist/packages/core/src/components/Popup/Popup.css +3 -0
  19. package/dist/packages/core/src/components/Tooltip/MenuTooltip.css +18 -0
  20. package/dist/packages/core/src/components/Tooltip/MenuTooltip.d.ts +29 -0
  21. package/dist/packages/core/src/components/Tooltip/MenuTooltip.js +74 -1
  22. package/dist/packages/core/src/components/Training/TrainingCard.d.ts +2 -0
  23. package/dist/packages/core/src/components/Training/TrainingCard.js +2 -2
  24. package/dist/packages/core/src/components.d.ts +1 -1
  25. package/dist/packages/core/src/utils/folderMenu.d.ts +1 -0
  26. package/dist/packages/core/src/utils/folderMenu.js +6 -5
  27. package/dist/packages/core/src/version.d.ts +1 -1
  28. package/dist/packages/core/src/version.js +1 -1
  29. package/dist/utils.cjs.js +2 -2
  30. package/package.json +1 -1
@@ -2245,7 +2245,7 @@ export declare function copyText(text: string): Promise<boolean>;
2245
2245
  *
2246
2246
  * 값은 손으로 적고 `test/coreVersion.test.ts` 가 package.json 과 어긋나면 운다.
2247
2247
  */
2248
- export declare const CORE_VERSION = "0.456.0";
2248
+ export declare const CORE_VERSION = "0.458.0";
2249
2249
 
2250
2250
  /** @public */
2251
2251
  declare const coreDefault: Record<string, unknown>;
@@ -3236,6 +3236,12 @@ declare interface FilterSectionInfoProps {
3236
3236
  /** 종성 글자 → 음소(대표음) 변환. 매핑에 없으면 원본 유지. */
3237
3237
  export declare function finalToPhoneme(jong: string): string;
3238
3238
 
3239
+ /**
3240
+ * **한 목록 안에서 겹친 단축키**(청 (447)) — 꺼지지 않은 줄끼리 같은 자판 자리면 그 키를 돌려준다(`'E'`). 시험에서 메뉴마다 불러 겹침을 잡는다.
3241
+ * @public
3242
+ */
3243
+ export declare function findDuplicateShortcuts(columns: TooltipMenuColumn[]): string[];
3244
+
3239
3245
  /** @public 단어의 초성 자모 ('가구' → 'ㄱ') */
3240
3246
  export declare function firstChoseongOf(word: string): string;
3241
3247
 
@@ -3259,6 +3265,16 @@ export declare type FlowState = {
3259
3265
 
3260
3266
  export declare function fmtBytes(n: number): string;
3261
3267
 
3268
+ /**
3269
+ * 「새 폴더」 칸 — 누르면 화면이 폴더 추가 창(`FolderAddPopup`)을 연다.
3270
+ * @public
3271
+ */
3272
+ export declare interface FolderAddEntry {
3273
+ /** 칸 이름 — 낭독기도 이 글자를 그대로 읽는다 */
3274
+ label: string;
3275
+ onClick: () => void;
3276
+ }
3277
+
3262
3278
  /**
3263
3279
  * **폴더 추가 창**(말귀 청 (438) ㉴ — 말귀 앱에서 옮겨 왔다, 2026-11-14). `FolderHead` · `FolderGrid` · `FolderList` 와 한 벌이다.
3264
3280
  *
@@ -3337,10 +3353,10 @@ export declare interface FolderEntry {
3337
3353
  *
3338
3354
  * · 칸은 `Button`(bar · 48 · default · 왼쪽 맞춤)이고 폭은 200 으로 고정이다 — 긴 이름은 단추가 줄인다.
3339
3355
  * · **놓을 자리이기도 하다** — 카드든 폴더든 끌고 그 위에 오면 단추가 기본 호버 꼴(`is-hover`)이 된다. 따로 테를 두르지 않는다.
3340
- * · 폴더가 없으면 아무것도 안 그린다(빈 격자가 자리를 먹지 않는다). 「위로」 칸(`up`)을 주면 그 칸만으로 선다.
3356
+ * · 폴더가 없으면 아무것도 안 그린다(빈 격자가 자리를 먹지 않는다). 「위로」 칸(`up`) · 「새 폴더」 칸(`add`)을 주면 그 칸만으로 선다.
3341
3357
  * @public
3342
3358
  */
3343
- export declare function FolderGrid({ folders, onOpen, dropProps, dropOver, menuItems, onMove, up }: FolderGridProps): JSX.Element | null;
3359
+ export declare function FolderGrid({ folders, onOpen, dropProps, dropOver, menuItems, onMove, up, add }: FolderGridProps): JSX.Element | null;
3344
3360
 
3345
3361
  /** @public */
3346
3362
  export declare interface FolderGridProps {
@@ -3366,6 +3382,12 @@ export declare interface FolderGridProps {
3366
3382
  * 폴더가 하나도 없어도 이 칸만으로 격자가 선다. `FolderHead` 는 폴더 안에 있는 동안 늘 준다.
3367
3383
  */
3368
3384
  up?: FolderUpEntry;
3385
+ /**
3386
+ * **맨 끝의 「새 폴더」 칸**(말귀 청 (448), 사장님 결정 2026-11-16) — 주면 폴더 칸과 같은 크기의 칸이 맨 끝에 선다(「위로」 · 폴더들 ·
3387
+ * 「새 폴더」 차례). 폴더가 하나도 없어도 이 칸만으로 격자가 서서, 맨 위에서 폴더 줄이 통째로 빠져 아래 목록이 튀지 않는다.
3388
+ * 폴더 칸과 갈리게 테두리가 점선이다. 안 주면 전과 같다(고르기만 하는 창).
3389
+ */
3390
+ add?: FolderAddEntry;
3369
3391
  }
3370
3392
 
3371
3393
  /**
@@ -3381,7 +3403,7 @@ export declare interface FolderGridProps {
3381
3403
  * · 길 줄의 키는 40 으로 고정이다(`Breadcrumb size="medium"`) — 폴더를 드나들 때 아래가 안 튄다.
3382
3404
  * @public
3383
3405
  */
3384
- export declare function FolderHead({ rootLabel, opened, onOpen, paths, countOf, folderMenu, rootMenu, dropProps, dropOver, onMoveFolder, itemDragging, rootDropKey, }: FolderHeadProps): JSX.Element;
3406
+ export declare function FolderHead({ rootLabel, opened, onOpen, paths, countOf, folderMenu, rootMenu, dropProps, dropOver, onMoveFolder, itemDragging, rootDropKey, add, }: FolderHeadProps): JSX.Element;
3385
3407
 
3386
3408
  /** @public */
3387
3409
  export declare interface FolderHeadProps {
@@ -3408,6 +3430,8 @@ export declare interface FolderHeadProps {
3408
3430
  itemDragging?: boolean;
3409
3431
  /** 맨 위(폴더 밖)로 놓을 때의 열쇠 — `dropProps` · `dropOver` 가 맨 위를 가리키는 그 값. 안 주면 나무의 맨 위 줄에는 못 놓는다 */
3410
3432
  rootDropKey?: string;
3433
+ /** 폴더 칸 줄 맨 끝의 「새 폴더」 칸(말귀 청 (448)) — 주면 맨 위 · 폴더 안 어디서나 선다. `FolderGrid` 의 `add` 그대로 */
3434
+ add?: FolderAddEntry;
3411
3435
  }
3412
3436
 
3413
3437
  /** @public 폴더 안에 새 폴더의 길을 짓는다 — `parent` 가 없으면 맨 위에 선다 */
@@ -3454,6 +3478,7 @@ export declare function folderMenuItems(lines: {
3454
3478
  }): {
3455
3479
  label: string;
3456
3480
  icon: string;
3481
+ shortcut: string;
3457
3482
  onClick: () => void;
3458
3483
  closeOnSelect: true;
3459
3484
  }[];
@@ -5827,6 +5852,9 @@ export declare const ORDER_SETS: unknown[];
5827
5852
  /** @public */
5828
5853
  export declare function OrderListStep({ _stepIndex, _totalSteps, ...rest }: StepWrapperProps): JSX.Element;
5829
5854
 
5855
+ /** 차례 단축키 — 0 번째 → `'1'` … 8 번째 → `'9'`, 그 뒤는 `null`(청 (447)) */
5856
+ export declare function orderShortcut(index: number): string | null;
5857
+
5830
5858
  /** @public */
5831
5859
  export declare function Page(_props: PageProps): null;
5832
5860
 
@@ -8604,6 +8632,9 @@ export declare interface ShortcutBadgeProps {
8604
8632
  className?: string;
8605
8633
  }
8606
8634
 
8635
+ /** 단축키 글자 → 자판 자리(`KeyE` · `Digit1`). 글자 · 숫자 하나가 아니면 `null` */
8636
+ export declare function shortcutCode(shortcut: string | null | undefined): string | null;
8637
+
8607
8638
  /**
8608
8639
  * 채점 화면을 떠나려 할 때 **물어봐야 하는가.**
8609
8640
  *
@@ -10278,6 +10309,18 @@ export declare type TooltipMenuColumnItem = {
10278
10309
  /** 우측 원형 배지 숫자(알림 개수 등). 라벨에 "(5)"를 붙이는 대신 SideNav와 같은
10279
10310
  * Badge type="dot"으로 표시한다 — 두 메뉴가 같은 항목을 다르게 보여주지 않도록. */
10280
10311
  badgeCount?: number;
10312
+ /**
10313
+ * **단축키 — 필수**(말귀 청 (447), 사장님 지시 2026-11-16 *"쇼컷을 이름에 붙이지 말고 우측에 보이도록"* → *"tooltip menu 는 단축키를
10314
+ * 전체적으로 필수로 받아서 모두 사용할 수 있도록"*). 글자 하나(`'E'`) 또는 숫자 하나(`'1'`). 빠뜨리면 tsc 가 운다.
10315
+ * 앱 자료로 짓는 긴 목록처럼 키를 정할 수 없는 줄은 **`null` 로 밝힌다**(아홉째까지는 `withOrderShortcuts` 가 1~9 를 준다).
10316
+ * · 보이기: 항목 오른쪽 끝에 키캡으로 따로 선다. 이름이 길면 이름이 줄고 키캡은 안 잘린다. 하위 메뉴(`children`) · 배지가 있으면 그쪽이 선다
10317
+ * (누르는 것은 된다).
10318
+ * · 누르기: 메뉴가 떠 있는 동안 그 키를 누르면 이 항목을 누른 것과 같다(하위 메뉴면 들어간다, `closeOnSelect` 그대로). **자판 자리(`event.code`)로
10319
+ * 맞춰** 한글 입력 상태에서도 먹는다. 꺼진 항목 · 입력칸에 초점이 있을 때 · Ctrl/⌘/Alt 와 함께 누를 때는 안 먹는다. 지금 보이는 목록만 본다.
10320
+ * · 한 목록 안에서 겹치면 개발 중 콘솔에 한 번 알린다(`findDuplicateShortcuts`). 겹치면 앞의 것이 먹는다.
10321
+ * · 낭독기: `aria-keyshortcuts` 로 알린다.
10322
+ */
10323
+ shortcut: string | null;
10281
10324
  };
10282
10325
 
10283
10326
  /** @public */
@@ -10690,6 +10733,8 @@ declare type TrainingCardAction = {
10690
10733
  disabled?: boolean;
10691
10734
  /** 단추 하나일 때의 색 꼴 — 기본 `default`(테두리 있음, 청 (443) ㉪). 좋아요가 켜졌을 때 `danger` 처럼 바꾼다(메뉴 꼴에서는 안 쓴다). */
10692
10735
  variant?: ButtonProps['variant'];
10736
+ /** 둘 이상이라 ⋯ 메뉴로 설 때의 단축키(말귀 청 (447)) — 안 주면 차례대로 1~9. 하나뿐이라 단추로 설 때는 안 쓴다 */
10737
+ shortcut?: string | null;
10693
10738
  };
10694
10739
 
10695
10740
  /** @public */
@@ -12945,6 +12990,15 @@ export declare function withEuRo(text: string): string;
12945
12990
  /** text 뒤에 문맥에 맞는 이/가를 붙여 반환한다. */
12946
12991
  export declare function withIga(text: string): string;
12947
12992
 
12993
+ /**
12994
+ * **앱 자료로 짓는 줄에 차례 단축키를 준다**(청 (447)) — 위에서부터 1~9, 열째부터는 `null`. 키를 이미 쥔 줄은 그대로 둔다.
12995
+ * 코어 안에서는 내비 더보기 · 차트 고르개처럼 무엇이 몇 개 올지 모르는 목록에 쓴다.
12996
+ * @public
12997
+ */
12998
+ export declare function withOrderShortcuts<T extends object>(items: T[]): (T & {
12999
+ shortcut: string | null;
13000
+ })[];
13001
+
12948
13002
  /**
12949
13003
  * @public 스텝 payload 에 **때 둘을 얹는다** — 보인 때 · 답한 때(말귀 요청 (68) 후속, 2026-10-02).
12950
13004
  *
@@ -506,7 +506,7 @@ export default function BarChart({ canvasHeight, fitHeight, focusableBars, size
506
506
  : t('trainingStatus.detail', '상세보기');
507
507
  return (_jsx(ChartSection, { className: sectionClassName, size: sectionSize, inGrid: inGrid, icon: icon, disc: disc, onClick: onClick, ariaLabel: cardAriaLabel, tooltip: cardTooltip, headSegment: headSegment,
508
508
  /* 좁아 고르개가 '⋯' 로 접히면 상세보기도 그 메뉴로 들어간다 — 머리에 단추 둘이 남지 않게 */
509
- headMenuItems: onDetail ? [{ label: detailTitle, icon: 'list', onClick: onDetail, closeOnSelect: true }] : undefined, title: t(titleKey), titleLevel: titleLevel, headRight: isSmall ? (headExtra ?? undefined) : ({ collapsed }) => _jsxs(_Fragment, { children: [!hideControls && _jsx(BarChartControls, { control: control }), headExtra, onDetail && !collapsed && (_jsx("span", { className: withLegacy("bar-chart__detail-btn"), children: _jsx(Button, { htmlType: "button", size: detailSize, type: "dot", icon: "list", ariaLabel: detailTitle, showTooltipInfo: detailTitle, onClick: onDetail }) }))] }),
509
+ headMenuItems: onDetail ? [{ label: detailTitle, icon: 'list', shortcut: 'D', onClick: onDetail, closeOnSelect: true }] : undefined, title: t(titleKey), titleLevel: titleLevel, headRight: isSmall ? (headExtra ?? undefined) : ({ collapsed }) => _jsxs(_Fragment, { children: [!hideControls && _jsx(BarChartControls, { control: control }), headExtra, onDetail && !collapsed && (_jsx("span", { className: withLegacy("bar-chart__detail-btn"), children: _jsx(Button, { htmlType: "button", size: detailSize, type: "dot", icon: "list", ariaLabel: detailTitle, showTooltipInfo: detailTitle, onClick: onDetail }) }))] }),
510
510
  /* 범례는 서브로우 밖 제 자리(`legend`)에 — 사장님 지시 2026-11-02, 수의 줄상자에서 푼다 */
511
511
  legend: _jsx(ChartLegend, { items: legendItems, className: "caption-1" }),
512
512
  /* 속을 카드 키에 맞출 때만 카드가 키를 박는다 — 안 맞추는 카드를 박으면 x축이 흘러나온다 */
@@ -5,7 +5,7 @@ import { createPortal } from 'react-dom';
5
5
  import './BottomNav.css';
6
6
  import Button from './Button';
7
7
  import CircleBadge from './CircleBadge';
8
- import MenuTooltip from './Tooltip/MenuTooltip';
8
+ import MenuTooltip, { withOrderShortcuts } from './Tooltip/MenuTooltip';
9
9
  // .tooltip__content(메뉴 표면)를 직접 쓰므로 정의 파일을 명시적으로 가져온다.
10
10
  // Tooltip.tsx만 이 CSS를 import하는데 BottomNav는 그 컴포넌트를 거치지 않아,
11
11
  // 프로덕션에서 청크가 갈리면 스타일 없이 렌더될 수 있다.
@@ -113,7 +113,8 @@ export default function BottomNav({ items = [], activeKey, onChange, appMode, on
113
113
  const activeMore = useMemo(() => hiddenItems.find(it => !!it.key && it.key === activeKey) ?? moreItems.find(it => it.selected || (it.key && it.key === activeKey)), [hiddenItems, activeKey, moreItems]);
114
114
  // 넘친 nav 항목 + 유틸 항목을 한 컬럼으로 합쳐 더보기 메뉴에 노출(각자 아이콘으로 구분)
115
115
  const moreColumns = useMemo(() => [{
116
- items: [
116
+ /* 단축키는 위에서부터 1~9(청 (447)) — 넘친 항목 · 유틸 항목은 앱 자료라 키를 정할 수 없다 */
117
+ items: withOrderShortcuts([
117
118
  ...hiddenItems.map(it => ({
118
119
  label: it.label,
119
120
  icon: it.icon,
@@ -143,7 +144,7 @@ export default function BottomNav({ items = [], activeKey, onChange, appMode, on
143
144
  handleCloseMore();
144
145
  },
145
146
  })),
146
- ]
147
+ ]),
147
148
  }], [hiddenItems, moreItems, activeKey, onChange, handleCloseMore]);
148
149
  // "…" 단추 배지 — 메뉴 안에서만 보이는 개수(넘친 항목 + 유틸)를 닫힌 채로도 알린다.
149
150
  const moreBadge = [...hiddenItems, ...moreItems].reduce((sum, it) => sum + badgeOf(it.badgeCount), 0);
@@ -11,7 +11,7 @@ import Tooltip from './Tooltip/Tooltip';
11
11
  import TooltipInfo from './Tooltip/InfoTooltip';
12
12
  import { useHoverAnchor } from '../hooks/useHoverAnchor';
13
13
  import { useIsoLayoutEffect } from '../hooks/useIsoLayoutEffect';
14
- import MenuTooltip from './Tooltip/MenuTooltip';
14
+ import MenuTooltip, { orderShortcut } from './Tooltip/MenuTooltip';
15
15
  import { CHART_HEAD_SIZE } from './controlSize';
16
16
  import { withLegacy } from '../utils/legacyBlocks';
17
17
  /** 차트 범례 — 색상 점 + 라벨 목록. BarChart/RingChart 섹션이 공유. @public */
@@ -188,8 +188,9 @@ export default function ChartSection({ type = 'chart', title, titleClassName, ti
188
188
  setMenuRect(null); }, [collapsed]);
189
189
  const menuItems = headSegment
190
190
  ? [
191
- ...headSegment.options.map(o => ({
191
+ ...headSegment.options.map((o, i) => ({
192
192
  label: o.label,
193
+ shortcut: orderShortcut(i),
193
194
  icon: o.icon,
194
195
  selected: o.key === headSegment.value,
195
196
  disabled: o.disabled,
@@ -11,6 +11,8 @@
11
11
  list-style: none;
12
12
  }
13
13
  .folder-grid__cell { position: relative; min-width: 0; }
14
+ /* 「새 폴더」 칸(청 (448)) — 폴더와 같은 크기, 테두리만 점선으로 갈린다(색은 단추 제 테두리 그대로) */
15
+ .folder-grid__cell--add .button { border-style: dashed; }
14
16
  /* 칸 오른쪽의 ⋯ — 폴더 단추 위에 얹는다(세로 가운데). 단추 안에는 같은 폭의 빈자리를 둔다 */
15
17
  .folder-grid__more {
16
18
  position: absolute;
@@ -36,6 +36,21 @@ export interface FolderGridProps {
36
36
  * 폴더가 하나도 없어도 이 칸만으로 격자가 선다. `FolderHead` 는 폴더 안에 있는 동안 늘 준다.
37
37
  */
38
38
  up?: FolderUpEntry;
39
+ /**
40
+ * **맨 끝의 「새 폴더」 칸**(말귀 청 (448), 사장님 결정 2026-11-16) — 주면 폴더 칸과 같은 크기의 칸이 맨 끝에 선다(「위로」 · 폴더들 ·
41
+ * 「새 폴더」 차례). 폴더가 하나도 없어도 이 칸만으로 격자가 서서, 맨 위에서 폴더 줄이 통째로 빠져 아래 목록이 튀지 않는다.
42
+ * 폴더 칸과 갈리게 테두리가 점선이다. 안 주면 전과 같다(고르기만 하는 창).
43
+ */
44
+ add?: FolderAddEntry;
45
+ }
46
+ /**
47
+ * 「새 폴더」 칸 — 누르면 화면이 폴더 추가 창(`FolderAddPopup`)을 연다.
48
+ * @public
49
+ */
50
+ export interface FolderAddEntry {
51
+ /** 칸 이름 — 낭독기도 이 글자를 그대로 읽는다 */
52
+ label: string;
53
+ onClick: () => void;
39
54
  }
40
55
  /**
41
56
  * 「위로」 칸 — 누르면 한 층 위로. 끌어다 놓는 화면에서는 **한 층 위로 옮기는 놓을 자리**도 된다.
@@ -59,7 +74,7 @@ export interface FolderUpEntry {
59
74
  *
60
75
  * · 칸은 `Button`(bar · 48 · default · 왼쪽 맞춤)이고 폭은 200 으로 고정이다 — 긴 이름은 단추가 줄인다.
61
76
  * · **놓을 자리이기도 하다** — 카드든 폴더든 끌고 그 위에 오면 단추가 기본 호버 꼴(`is-hover`)이 된다. 따로 테를 두르지 않는다.
62
- * · 폴더가 없으면 아무것도 안 그린다(빈 격자가 자리를 먹지 않는다). 「위로」 칸(`up`)을 주면 그 칸만으로 선다.
77
+ * · 폴더가 없으면 아무것도 안 그린다(빈 격자가 자리를 먹지 않는다). 「위로」 칸(`up`) · 「새 폴더」 칸(`add`)을 주면 그 칸만으로 선다.
63
78
  * @public
64
79
  */
65
- export default function FolderGrid({ folders, onOpen, dropProps, dropOver, menuItems, onMove, up }: FolderGridProps): import("react").JSX.Element | null;
80
+ export default function FolderGrid({ folders, onOpen, dropProps, dropOver, menuItems, onMove, up, add }: FolderGridProps): import("react").JSX.Element | null;
@@ -18,10 +18,10 @@ const UP_KEY = '\u0000up';
18
18
  *
19
19
  * · 칸은 `Button`(bar · 48 · default · 왼쪽 맞춤)이고 폭은 200 으로 고정이다 — 긴 이름은 단추가 줄인다.
20
20
  * · **놓을 자리이기도 하다** — 카드든 폴더든 끌고 그 위에 오면 단추가 기본 호버 꼴(`is-hover`)이 된다. 따로 테를 두르지 않는다.
21
- * · 폴더가 없으면 아무것도 안 그린다(빈 격자가 자리를 먹지 않는다). 「위로」 칸(`up`)을 주면 그 칸만으로 선다.
21
+ * · 폴더가 없으면 아무것도 안 그린다(빈 격자가 자리를 먹지 않는다). 「위로」 칸(`up`) · 「새 폴더」 칸(`add`)을 주면 그 칸만으로 선다.
22
22
  * @public
23
23
  */
24
- export default function FolderGrid({ folders, onOpen, dropProps, dropOver, menuItems, onMove, up }) {
24
+ export default function FolderGrid({ folders, onOpen, dropProps, dropOver, menuItems, onMove, up, add }) {
25
25
  const { t } = useTranslation();
26
26
  /** 메뉴가 열린 폴더와 그 단추 */
27
27
  const [menu, setMenu] = useState(null);
@@ -59,7 +59,7 @@ export default function FolderGrid({ folders, onOpen, dropProps, dropOver, menuI
59
59
  const upOver = !!up && (draggingFolder === null
60
60
  ? up.cardDropKey != null && dropOver === up.cardDropKey
61
61
  : !!up.onFolderDrop && folderDrag.dragOverKey === UP_KEY);
62
- if (folders.length === 0 && !up)
62
+ if (folders.length === 0 && !up && !add)
63
63
  return null;
64
64
  return (_jsxs("ul", { className: "folder-grid", "aria-label": t('folder.list', '폴더'), children: [up && (_jsx("li", { className: ['folder-grid__cell', 'folder-grid__cell--up', upOver && 'folder-grid__cell--over'].filter(Boolean).join(' '), ...upDrag(), children: _jsx(Button, { htmlType: "button", type: "bar", size: 48, variant: "default", align: "left", width: "100%", ellipsis: true, className: upOver ? 'is-hover' : undefined, icon: "arrow-up", label: t('folder.up', '위로'), ariaLabel: t('folder.upTo', { name: up.targetLabel, defaultValue: '한 층 위로 — {{name}}' }), onClick: up.onOpen }) }, UP_KEY)), folders.map(folder => {
65
65
  const label = folder.label ?? folder.name;
@@ -77,5 +77,5 @@ export default function FolderGrid({ folders, onOpen, dropProps, dropOver, menuI
77
77
  const anchor = e.currentTarget;
78
78
  setMenu(now => (now?.name === folder.name ? null : { name: folder.name, label, anchor }));
79
79
  } }) }))] }, folder.name));
80
- }), menu && menuItems && (_jsx(Tooltip, { anchorEl: menu.anchor, onClose: closeMenu, closeOnOutsideClick: true, offset: 4, prefer: "bottom", ariaLabel: t('folder.menu', { name: menu.label, defaultValue: '{{name}} 폴더 메뉴' }), children: _jsx(MenuTooltip, { columns: [{ items: menuItems(menu.name) }], size: "small", onClose: closeMenu }) }))] }));
80
+ }), add && (_jsx("li", { className: "folder-grid__cell folder-grid__cell--add", children: _jsx(Button, { htmlType: "button", type: "bar", size: 48, variant: "default", align: "left", width: "100%", ellipsis: true, icon: "folder-plus", label: add.label, onClick: add.onClick }) }, "__add")), menu && menuItems && (_jsx(Tooltip, { anchorEl: menu.anchor, onClose: closeMenu, closeOnOutsideClick: true, offset: 4, prefer: "bottom", ariaLabel: t('folder.menu', { name: menu.label, defaultValue: '{{name}} 폴더 메뉴' }), children: _jsx(MenuTooltip, { columns: [{ items: menuItems(menu.name) }], size: "small", onClose: closeMenu }) }))] }));
81
81
  }
@@ -1,4 +1,5 @@
1
1
  import { type TooltipMenuColumnItem } from './Tooltip/MenuTooltip';
2
+ import { type FolderAddEntry } from './FolderGrid';
2
3
  import './FolderHead.css';
3
4
  /** @public */
4
5
  export interface FolderHeadProps {
@@ -25,6 +26,8 @@ export interface FolderHeadProps {
25
26
  itemDragging?: boolean;
26
27
  /** 맨 위(폴더 밖)로 놓을 때의 열쇠 — `dropProps` · `dropOver` 가 맨 위를 가리키는 그 값. 안 주면 나무의 맨 위 줄에는 못 놓는다 */
27
28
  rootDropKey?: string;
29
+ /** 폴더 칸 줄 맨 끝의 「새 폴더」 칸(말귀 청 (448)) — 주면 맨 위 · 폴더 안 어디서나 선다. `FolderGrid` 의 `add` 그대로 */
30
+ add?: FolderAddEntry;
28
31
  }
29
32
  /**
30
33
  * **폴더로 보는 화면의 머리** — 구조 단추 · 길(브레드크럼) · 지금 자리의 폴더 칸들. 도구줄 **위**에 선다(말귀 청 (435)).
@@ -39,4 +42,4 @@ export interface FolderHeadProps {
39
42
  * · 길 줄의 키는 40 으로 고정이다(`Breadcrumb size="medium"`) — 폴더를 드나들 때 아래가 안 튄다.
40
43
  * @public
41
44
  */
42
- export default function FolderHead({ rootLabel, opened, onOpen, paths, countOf, folderMenu, rootMenu, dropProps, dropOver, onMoveFolder, itemDragging, rootDropKey, }: FolderHeadProps): import("react").JSX.Element;
45
+ export default function FolderHead({ rootLabel, opened, onOpen, paths, countOf, folderMenu, rootMenu, dropProps, dropOver, onMoveFolder, itemDragging, rootDropKey, add, }: FolderHeadProps): import("react").JSX.Element;
@@ -22,7 +22,7 @@ import './FolderHead.css';
22
22
  * · 길 줄의 키는 40 으로 고정이다(`Breadcrumb size="medium"`) — 폴더를 드나들 때 아래가 안 튄다.
23
23
  * @public
24
24
  */
25
- export default function FolderHead({ rootLabel, opened, onOpen, paths, countOf, folderMenu, rootMenu, dropProps, dropOver, onMoveFolder, itemDragging, rootDropKey, }) {
25
+ export default function FolderHead({ rootLabel, opened, onOpen, paths, countOf, folderMenu, rootMenu, dropProps, dropOver, onMoveFolder, itemDragging, rootDropKey, add, }) {
26
26
  const { t } = useTranslation();
27
27
  /** 길의 메뉴가 붙을 단추 — 열려 있으면 그 단추 */
28
28
  const [menuAnchor, setMenuAnchor] = useState(null);
@@ -65,5 +65,5 @@ export default function FolderHead({ rootLabel, opened, onOpen, paths, countOf,
65
65
  onOpen: () => onOpen(parent),
66
66
  cardDropKey: parent ?? rootDropKey,
67
67
  onFolderDrop: onMoveFolder ? path => onMoveFolder(path, parent) : undefined,
68
- } : undefined }), menuAnchor && hasMenu && (_jsx(Tooltip, { anchorEl: menuAnchor, onClose: closeMenu, closeOnOutsideClick: true, offset: 4, prefer: "bottom", ariaLabel: menuLabel, children: _jsx(MenuTooltip, { columns: [{ items: (opened ? folderMenu?.(opened) : rootMenu) ?? [] }], size: "small", onClose: closeMenu }) }))] }));
68
+ } : undefined, add: add }), menuAnchor && hasMenu && (_jsx(Tooltip, { anchorEl: menuAnchor, onClose: closeMenu, closeOnOutsideClick: true, offset: 4, prefer: "bottom", ariaLabel: menuLabel, children: _jsx(MenuTooltip, { columns: [{ items: (opened ? folderMenu?.(opened) : rootMenu) ?? [] }], size: "small", onClose: closeMenu }) }))] }));
69
69
  }
@@ -6,7 +6,7 @@ import { useMediaQuery } from '../hooks';
6
6
  import BottomNav from './BottomNav';
7
7
  import Button from './Button';
8
8
  import CircleBadge from './CircleBadge';
9
- import MenuTooltip from './Tooltip/MenuTooltip';
9
+ import MenuTooltip, { orderShortcut } from './Tooltip/MenuTooltip';
10
10
  import { useAnchoredMenu, anchoredMenuZIndex } from '../hooks/useAnchoredMenu';
11
11
  import { createPortal } from 'react-dom';
12
12
  // 메뉴 표면(.tooltip__content) 정의 — Tooltip.tsx를 거치지 않고 클래스만 쓰므로 명시적으로.
@@ -117,8 +117,9 @@ export default function Header({ activeKey, onChange, items, malgwiItems: _malgw
117
117
  const utilMenuId = useId();
118
118
  const { open: utilOpen, toggle: toggleUtilMenu, close: closeUtilMenu, style: utilMenuStyle, triggerRef: utilTriggerRef, menuRef: utilMenuRef } = useAnchoredMenu({ computeStyle: computeUtilMenuStyle, onScroll: 'ignore', onResize: 'reposition' /* 회전하면 옛 좌표에 남았다 — 다시 잰다 */ });
119
119
  const utilColumns = useMemo(() => [{
120
- items: bottomMoreItems.map(it => ({
120
+ items: bottomMoreItems.map((it, i) => ({
121
121
  label: it.label,
122
+ shortcut: orderShortcut(i),
122
123
  icon: it.icon,
123
124
  badgeCount: it.badgeCount,
124
125
  selected: it.selected ?? (!!it.key && it.key === activeKey),
@@ -352,9 +352,9 @@ export default function PassCard({ ariaLabel, product, showPrice = false, plan,
352
352
  }, [hasMenu, handleCardClick]);
353
353
  const menuColumns = [{
354
354
  items: [
355
- ...(onUse ? [{ label: t('passCard.menu.use', '사용하기'), icon: 'play', onClick: () => { onUse(); setMenuAnchor(null); }, closeOnSelect: true }] : []),
356
- ...(onRefund ? [{ label: t('passCard.menu.refund', '환불하기'), icon: 'rotate-ccw', onClick: () => { onRefund(); setMenuAnchor(null); }, closeOnSelect: true }] : []),
357
- ...(onDelete ? [{ label: t('passCard.menu.delete', '삭제하기'), icon: 'trash-2', onClick: () => { onDelete(); setMenuAnchor(null); }, closeOnSelect: true }] : []),
355
+ ...(onUse ? [{ label: t('passCard.menu.use', '사용하기'), icon: 'play', shortcut: 'U', onClick: () => { onUse(); setMenuAnchor(null); }, closeOnSelect: true }] : []),
356
+ ...(onRefund ? [{ label: t('passCard.menu.refund', '환불하기'), icon: 'rotate-ccw', shortcut: 'R', onClick: () => { onRefund(); setMenuAnchor(null); }, closeOnSelect: true }] : []),
357
+ ...(onDelete ? [{ label: t('passCard.menu.delete', '삭제하기'), icon: 'trash-2', shortcut: 'D', onClick: () => { onDelete(); setMenuAnchor(null); }, closeOnSelect: true }] : []),
358
358
  ],
359
359
  }];
360
360
  return (_jsxs(_Fragment, { children: [_jsx("div", { className: "pass-card-frame", children: _jsxs("div", { ref: cardRef, className: `pass-card pass-card--${state}${hasMenu ? ' pass-card--clickable' : ''}`, style: cardStyle, onMouseEnter: handleMouseEnter, onMouseMove: handleMouseMove, onMouseLeave: handleMouseLeave,
@@ -257,6 +257,9 @@
257
257
  (처음에 "표(`panel-row`)와 선을 맞춘다" 로 읽어 20px 들여쓰기로 올렸다가 사장님께
258
258
  바로잡혔다. 눈에 보인 어긋남과 말씀하신 것이 달랐다.) */
259
259
  .confirm-popup__message {
260
+ /* **제목보다 한 단계 옅게**(말귀 청 (446-1), 사장님 지시 2026-11-16 *"색상이 너무 진한데"*, 색은 사장님이 골랐다) — 색이 없어 제목과
261
+ 같은 --color-black 을 물려받았다 */
262
+ color: var(--color-darkGray);
260
263
  padding: 8px 0;
261
264
  margin: 0 auto;
262
265
  width: fit-content;
@@ -90,3 +90,21 @@
90
90
  flex-direction: column;
91
91
  }
92
92
  }
93
+
94
+ /* **단축키 키캡**(말귀 청 (447)) — 항목 오른쪽 끝, 이름과 따로. 이름이 길면 이름이 줄고 키캡은 안 잘린다.
95
+ 색은 이 메뉴에 있던 값 그대로 — 글자는 열 머리글(lightGray), 테두리는 구분선(whiteLine). */
96
+ .menu-tooltip__shortcut {
97
+ flex-shrink: 0;
98
+ min-width: 22px;
99
+ height: 22px;
100
+ padding: 0 6px;
101
+ display: inline-flex;
102
+ align-items: center;
103
+ justify-content: center;
104
+ box-sizing: border-box;
105
+ border: 1px solid var(--color-whiteLine);
106
+ border-radius: var(--radius-xs);
107
+ color: var(--color-lightGray);
108
+ font-family: inherit;
109
+ line-height: 1;
110
+ }
@@ -19,7 +19,36 @@ export type TooltipMenuColumnItem = {
19
19
  /** 우측 원형 배지 숫자(알림 개수 등). 라벨에 "(5)"를 붙이는 대신 SideNav와 같은
20
20
  * Badge type="dot"으로 표시한다 — 두 메뉴가 같은 항목을 다르게 보여주지 않도록. */
21
21
  badgeCount?: number;
22
+ /**
23
+ * **단축키 — 필수**(말귀 청 (447), 사장님 지시 2026-11-16 *"쇼컷을 이름에 붙이지 말고 우측에 보이도록"* → *"tooltip menu 는 단축키를
24
+ * 전체적으로 필수로 받아서 모두 사용할 수 있도록"*). 글자 하나(`'E'`) 또는 숫자 하나(`'1'`). 빠뜨리면 tsc 가 운다.
25
+ * 앱 자료로 짓는 긴 목록처럼 키를 정할 수 없는 줄은 **`null` 로 밝힌다**(아홉째까지는 `withOrderShortcuts` 가 1~9 를 준다).
26
+ * · 보이기: 항목 오른쪽 끝에 키캡으로 따로 선다. 이름이 길면 이름이 줄고 키캡은 안 잘린다. 하위 메뉴(`children`) · 배지가 있으면 그쪽이 선다
27
+ * (누르는 것은 된다).
28
+ * · 누르기: 메뉴가 떠 있는 동안 그 키를 누르면 이 항목을 누른 것과 같다(하위 메뉴면 들어간다, `closeOnSelect` 그대로). **자판 자리(`event.code`)로
29
+ * 맞춰** 한글 입력 상태에서도 먹는다. 꺼진 항목 · 입력칸에 초점이 있을 때 · Ctrl/⌘/Alt 와 함께 누를 때는 안 먹는다. 지금 보이는 목록만 본다.
30
+ * · 한 목록 안에서 겹치면 개발 중 콘솔에 한 번 알린다(`findDuplicateShortcuts`). 겹치면 앞의 것이 먹는다.
31
+ * · 낭독기: `aria-keyshortcuts` 로 알린다.
32
+ */
33
+ shortcut: string | null;
22
34
  };
35
+ /** 단축키 글자 → 자판 자리(`KeyE` · `Digit1`). 글자 · 숫자 하나가 아니면 `null` */
36
+ export declare function shortcutCode(shortcut: string | null | undefined): string | null;
37
+ /** 차례 단축키 — 0 번째 → `'1'` … 8 번째 → `'9'`, 그 뒤는 `null`(청 (447)) */
38
+ export declare function orderShortcut(index: number): string | null;
39
+ /**
40
+ * **앱 자료로 짓는 줄에 차례 단축키를 준다**(청 (447)) — 위에서부터 1~9, 열째부터는 `null`. 키를 이미 쥔 줄은 그대로 둔다.
41
+ * 코어 안에서는 내비 더보기 · 차트 고르개처럼 무엇이 몇 개 올지 모르는 목록에 쓴다.
42
+ * @public
43
+ */
44
+ export declare function withOrderShortcuts<T extends object>(items: T[]): (T & {
45
+ shortcut: string | null;
46
+ })[];
47
+ /**
48
+ * **한 목록 안에서 겹친 단축키**(청 (447)) — 꺼지지 않은 줄끼리 같은 자판 자리면 그 키를 돌려준다(`'E'`). 시험에서 메뉴마다 불러 겹침을 잡는다.
49
+ * @public
50
+ */
51
+ export declare function findDuplicateShortcuts(columns: TooltipMenuColumn[]): string[];
23
52
  /** @public */
24
53
  export type TooltipMenuColumn = {
25
54
  /**
@@ -6,6 +6,45 @@ import Button from '../Button';
6
6
  import CircleBadge from '../CircleBadge';
7
7
  import './MenuTooltip.css';
8
8
  import { withLegacy } from '../../utils/legacyBlocks';
9
+ import { devWarnOnce } from '../../utils/devWarn';
10
+ /** 단축키 글자 → 자판 자리(`KeyE` · `Digit1`). 글자 · 숫자 하나가 아니면 `null` */
11
+ export function shortcutCode(shortcut) {
12
+ const k = (shortcut ?? '').trim().toUpperCase();
13
+ if (/^[A-Z]$/.test(k))
14
+ return `Key${k}`;
15
+ if (/^[0-9]$/.test(k))
16
+ return `Digit${k}`;
17
+ return null;
18
+ }
19
+ /** 차례 단축키 — 0 번째 → `'1'` … 8 번째 → `'9'`, 그 뒤는 `null`(청 (447)) */
20
+ export function orderShortcut(index) {
21
+ return index >= 0 && index < 9 ? String(index + 1) : null;
22
+ }
23
+ /**
24
+ * **앱 자료로 짓는 줄에 차례 단축키를 준다**(청 (447)) — 위에서부터 1~9, 열째부터는 `null`. 키를 이미 쥔 줄은 그대로 둔다.
25
+ * 코어 안에서는 내비 더보기 · 차트 고르개처럼 무엇이 몇 개 올지 모르는 목록에 쓴다.
26
+ * @public
27
+ */
28
+ export function withOrderShortcuts(items) {
29
+ return items.map((it, i) => {
30
+ const own = it.shortcut;
31
+ return { ...it, shortcut: own !== undefined ? own : orderShortcut(i) };
32
+ });
33
+ }
34
+ /**
35
+ * **한 목록 안에서 겹친 단축키**(청 (447)) — 꺼지지 않은 줄끼리 같은 자판 자리면 그 키를 돌려준다(`'E'`). 시험에서 메뉴마다 불러 겹침을 잡는다.
36
+ * @public
37
+ */
38
+ export function findDuplicateShortcuts(columns) {
39
+ const seen = new Map();
40
+ for (const col of columns ?? [])
41
+ for (const it of col?.items ?? []) {
42
+ const code = it && !it.disabled ? shortcutCode(it.shortcut) : null;
43
+ if (code)
44
+ seen.set(code, (seen.get(code) ?? 0) + 1);
45
+ }
46
+ return [...seen].filter(([, n]) => n > 1).map(([code]) => code.replace(/^Key|^Digit/, ''));
47
+ }
9
48
  /** @public */
10
49
  export default function MenuTooltip({ columns = [], onClose, className = '', size = 'medium' }) {
11
50
  const { t } = useTranslation();
@@ -82,6 +121,38 @@ export default function MenuTooltip({ columns = [], onClose, className = '', siz
82
121
  }
83
122
  catch (err) { }
84
123
  }, [onClose, visibleDepth]);
124
+ /* 한 목록 안에서 키가 겹치면 개발 중 한 번 알린다(청 (447)) */
125
+ useEffect(() => {
126
+ const dup = findDuplicateShortcuts(current.columns);
127
+ if (dup.length)
128
+ devWarnOnce(`menu-shortcut-dup:${dup.join(',')}:${current.columns.flatMap(c => c.items.map(i => i.label)).join('|')}`, `[MenuTooltip] 한 메뉴 안에서 단축키가 겹칩니다: ${dup.join(', ')} — 앞의 항목만 먹습니다.`);
129
+ }, [current.columns]);
130
+ /* **단축키**(청 (447)) — 떠 있는 동안 지금 보이는 목록의 항목을 자판 자리로 누른다. 최신 목록 · 손은 ref 로 읽어 듣개를 한 번만 건다 */
131
+ const shortcutRef = useRef({ columns: current.columns, handleClick });
132
+ shortcutRef.current = { columns: current.columns, handleClick };
133
+ useEffect(() => {
134
+ const onKey = (e) => {
135
+ if (e.defaultPrevented || e.ctrlKey || e.metaKey || e.altKey)
136
+ return;
137
+ const target = e.target;
138
+ if (target && (target.closest?.('input, textarea, select, [contenteditable=""], [contenteditable="true"]')))
139
+ return;
140
+ const { columns: cols, handleClick: press } = shortcutRef.current;
141
+ for (let ci = 0; ci < (cols?.length ?? 0); ci++) {
142
+ const items = cols[ci]?.items ?? [];
143
+ for (let ii = 0; ii < items.length; ii++) {
144
+ const it = items[ii];
145
+ if (!it || it.disabled || shortcutCode(it.shortcut) !== e.code)
146
+ continue;
147
+ e.preventDefault();
148
+ press(it, ci, ii);
149
+ return;
150
+ }
151
+ }
152
+ };
153
+ window.addEventListener('keydown', onKey);
154
+ return () => window.removeEventListener('keydown', onKey);
155
+ }, []);
85
156
  return (_jsxs("div", { className: withLegacy(`menu-tooltip menu-tooltip--${size} ${className}`), children: [(stack.length > 1 || current.title) && (_jsxs("div", { className: withLegacy("menu-tooltip__header"), children: [stack.length > 1 ? (_jsx(Button, { htmlType: "button", size: itemSize, type: "dot", icon: "chevron-left", ariaLabel: t('common.back', '뒤로'), onClick: goBack, variant: "transparent-gray", useBorder: false })) : null, _jsx("div", { className: withLegacy("menu-tooltip__title button-1"), children: current.title })] })), _jsx("div", { className: withLegacy("menu-tooltip__columns"), ref: itemsWrapRef, children: current.columns && current.columns.map((col, ci) => {
86
157
  /**
87
158
  * **아무도 안 쓰는 왼쪽 자리는 안 세운다**(말귀 청 (349), 2026-10-29).
@@ -111,7 +182,9 @@ export default function MenuTooltip({ columns = [], onClose, className = '', siz
111
182
  ? 'chevron-right'
112
183
  : item.badgeCount
113
184
  ? _jsx(CircleBadge, { position: "inline", number: Math.min(item.badgeCount, 99), size: 24, "aria-hidden": true })
114
- : undefined, label: item.label,
185
+ : shortcutCode(item.shortcut)
186
+ ? _jsx("kbd", { className: withLegacy('menu-tooltip__shortcut caption-1'), "aria-hidden": "true", children: item.shortcut.trim().toUpperCase() })
187
+ : undefined, "aria-keyshortcuts": shortcutCode(item.shortcut) ? item.shortcut.trim().toUpperCase() : undefined, ellipsis: shortcutCode(item.shortcut) ? true : undefined, label: item.label,
115
188
  /* 개수는 이름에 붙인다 — ariaLabel 이 글자뿐이라 배지 수가 이름에서 빠져 "알림" 으로만 읽혔다
116
189
  (SideNav·BottomNav 와 같은 nav.badgeLabel "알림, 5개"). */
117
190
  ariaLabel: item.label && item.badgeCount && item.badgeCount > 0
@@ -13,6 +13,8 @@ export type TrainingCardAction = {
13
13
  disabled?: boolean;
14
14
  /** 단추 하나일 때의 색 꼴 — 기본 `default`(테두리 있음, 청 (443) ㉪). 좋아요가 켜졌을 때 `danger` 처럼 바꾼다(메뉴 꼴에서는 안 쓴다). */
15
15
  variant?: ButtonProps['variant'];
16
+ /** 둘 이상이라 ⋯ 메뉴로 설 때의 단축키(말귀 청 (447)) — 안 주면 차례대로 1~9. 하나뿐이라 단추로 설 때는 안 쓴다 */
17
+ shortcut?: string | null;
16
18
  };
17
19
  /** @public */
18
20
  export type TrainingCardProps = {
@@ -6,7 +6,7 @@ import { useCallback, useState } from 'react';
6
6
  import { useTranslation } from 'react-i18next';
7
7
  import Button from '../Button';
8
8
  import Tooltip from '../Tooltip/Tooltip';
9
- import MenuTooltip from '../Tooltip/MenuTooltip';
9
+ import MenuTooltip, { withOrderShortcuts } from '../Tooltip/MenuTooltip';
10
10
  /** @public */
11
11
  export default function TrainingCard({ title, titleLevel = 3, category, categoryVariant = 'main', description, topActions, actions, children, footerLeft, footerRight, ariaLabel, onClick, draggable, onDragStart, onDragEnd, className, }) {
12
12
  const TitleTag = titleLevel ? `h${titleLevel}` : 'div';
@@ -50,5 +50,5 @@ export default function TrainingCard({ title, titleLevel = 3, category, category
50
50
  ? _jsx("div", { className: "training-card__body", children: children })
51
51
  : _jsx("div", { className: "training-card__body training-card__body--empty", "aria-hidden": "true" }), hasFooter ? (_jsxs("div", { className: "training-card__footer", children: [footerLeft != null && _jsx("div", { className: "training-card__footer-left", children: footerLeft }), footerRight != null && _jsx("div", { className: "training-card__meta", children: footerRight })] })) : _jsx("div", { className: "training-card__footer training-card__footer--empty", "aria-hidden": "true" }), menuRect && actionList.length > 1 && (
52
52
  /* 메뉴의 누름은 카드로 올라가지 않는다 — 고르는 것이 카드를 여는 것이 되면 안 된다 */
53
- _jsx("div", { className: "training-card__menu-host", onClick: (e) => e.stopPropagation(), children: _jsx(Tooltip, { anchorRect: menuRect, onClose: closeMenu, ariaLabel: t('tooltip.menu', '메뉴'), children: _jsx(MenuTooltip, { columns: [{ items: actionList.map(a => ({ label: a.label, icon: a.icon, selected: a.selected, disabled: a.disabled, onClick: a.onClick })) }], onClose: closeMenu, size: "small" }) }) }))] }));
53
+ _jsx("div", { className: "training-card__menu-host", onClick: (e) => e.stopPropagation(), children: _jsx(Tooltip, { anchorRect: menuRect, onClose: closeMenu, ariaLabel: t('tooltip.menu', '메뉴'), children: _jsx(MenuTooltip, { columns: [{ items: withOrderShortcuts(actionList.map(a => ({ label: a.label, icon: a.icon, selected: a.selected, disabled: a.disabled, onClick: a.onClick, shortcut: a.shortcut }))) }], onClose: closeMenu, size: "small" }) }) }))] }));
54
54
  }
@@ -106,7 +106,7 @@ export type { BreadcrumbProps, BreadcrumbItem } from './components/Breadcrumb';
106
106
  export { default as FolderHead } from './components/FolderHead';
107
107
  export type { FolderHeadProps } from './components/FolderHead';
108
108
  export { default as FolderGrid } from './components/FolderGrid';
109
- export type { FolderGridProps, FolderEntry, FolderUpEntry } from './components/FolderGrid';
109
+ export type { FolderGridProps, FolderEntry, FolderUpEntry, FolderAddEntry } from './components/FolderGrid';
110
110
  export { default as FolderList } from './components/FolderList';
111
111
  export type { FolderListProps } from './components/FolderList';
112
112
  export { default as FolderAddPopup } from './components/FolderAddPopup';
@@ -22,6 +22,7 @@ export declare function folderMenuItems(lines: {
22
22
  }): {
23
23
  label: string;
24
24
  icon: string;
25
+ shortcut: string;
25
26
  onClick: () => void;
26
27
  closeOnSelect: true;
27
28
  }[];
@@ -9,11 +9,12 @@
9
9
  */
10
10
  /** @public 폴더 메뉴의 줄을 정해진 차례 · 아이콘으로 짓는다 */
11
11
  export function folderMenuItems(lines) {
12
- const row = (line, icon) => ({ ...line, icon, closeOnSelect: true });
12
+ /* 단축키도 차례와 함께 코어가 정한다(말귀 청 (447) — 메뉴 단축키 필수): 더하기 A · 폴더 추가 F · 이름 바꾸기 R · 삭제 D */
13
+ const row = (line, icon, shortcut) => ({ ...line, icon, shortcut, closeOnSelect: true });
13
14
  return [
14
- row(lines.add, 'plus'),
15
- row(lines.addFolder, 'folder-plus'),
16
- ...(lines.rename ? [row(lines.rename, 'edit-2')] : []),
17
- ...(lines.remove ? [row(lines.remove, 'trash-2')] : []),
15
+ row(lines.add, 'plus', 'A'),
16
+ row(lines.addFolder, 'folder-plus', 'F'),
17
+ ...(lines.rename ? [row(lines.rename, 'edit-2', 'R')] : []),
18
+ ...(lines.remove ? [row(lines.remove, 'trash-2', 'D')] : []),
18
19
  ];
19
20
  }
@@ -46,4 +46,4 @@
46
46
  *
47
47
  * 값은 손으로 적고 `test/coreVersion.test.ts` 가 package.json 과 어긋나면 운다.
48
48
  */
49
- export declare const CORE_VERSION = "0.456.0";
49
+ export declare const CORE_VERSION = "0.458.0";
@@ -46,4 +46,4 @@
46
46
  *
47
47
  * 값은 손으로 적고 `test/coreVersion.test.ts` 가 package.json 과 어긋나면 운다.
48
48
  */
49
- export const CORE_VERSION = '0.456.0';
49
+ export const CORE_VERSION = '0.458.0';