@nanahoshi/mona-ui 0.40.0 → 0.41.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.
- package/docs/api/common.md +1 -1
- package/docs/api/i18n.md +34 -0
- package/docs/api/kanban.md +222 -0
- package/docs/api/locales.md +14 -14
- package/docs/api/sortable.md +189 -0
- package/docs/api/tabs.md +20 -0
- package/docs/kanban.md +293 -0
- package/docs/sortable.md +320 -0
- package/docs/tabs.md +59 -10
- package/fesm2022/nanahoshi-mona-ui-i18n-icu.mjs +48 -0
- package/fesm2022/nanahoshi-mona-ui-kanban.mjs +660 -0
- package/fesm2022/nanahoshi-mona-ui-locales-ar-sa.mjs +9 -0
- package/fesm2022/nanahoshi-mona-ui-locales-de-de.mjs +9 -0
- package/fesm2022/nanahoshi-mona-ui-locales-es-es.mjs +9 -0
- package/fesm2022/nanahoshi-mona-ui-locales-fr-fr.mjs +9 -0
- package/fesm2022/nanahoshi-mona-ui-locales-id-id.mjs +9 -0
- package/fesm2022/nanahoshi-mona-ui-locales-it-it.mjs +9 -0
- package/fesm2022/nanahoshi-mona-ui-locales-ja-jp.mjs +9 -0
- package/fesm2022/nanahoshi-mona-ui-locales-ko-kr.mjs +9 -0
- package/fesm2022/nanahoshi-mona-ui-locales-pl-pl.mjs +19 -0
- package/fesm2022/nanahoshi-mona-ui-locales-pt-br.mjs +9 -0
- package/fesm2022/nanahoshi-mona-ui-locales-ru-ru.mjs +19 -0
- package/fesm2022/nanahoshi-mona-ui-locales-tr-tr.mjs +9 -0
- package/fesm2022/nanahoshi-mona-ui-locales-zh-cn.mjs +9 -0
- package/fesm2022/nanahoshi-mona-ui-locales-zh-tw.mjs +9 -0
- package/fesm2022/nanahoshi-mona-ui-sortable.mjs +733 -0
- package/fesm2022/nanahoshi-mona-ui-tabs.mjs +112 -5
- package/i18n/catalogs/en-US.messages.json +9 -0
- package/kanban/package.json +4 -0
- package/llms.txt +6 -2
- package/locales/ar-sa/ar-sa.messages.json +9 -0
- package/locales/de-de/de-de.messages.json +9 -0
- package/locales/es-es/es-es.messages.json +9 -0
- package/locales/fr-fr/fr-fr.messages.json +9 -0
- package/locales/id-id/id-id.messages.json +9 -0
- package/locales/it-it/it-it.messages.json +9 -0
- package/locales/ja-jp/ja-jp.messages.json +9 -0
- package/locales/ko-kr/ko-kr.messages.json +9 -0
- package/locales/pl-pl/pl-pl.messages.json +9 -0
- package/locales/pt-br/pt-br.messages.json +9 -0
- package/locales/ru-ru/ru-ru.messages.json +9 -0
- package/locales/tr-tr/tr-tr.messages.json +9 -0
- package/locales/zh-cn/zh-cn.messages.json +9 -0
- package/locales/zh-tw/zh-tw.messages.json +9 -0
- package/package.json +9 -1
- package/sortable/package.json +4 -0
- package/types/nanahoshi-mona-ui-i18n.d.ts +19 -0
- package/types/nanahoshi-mona-ui-kanban.d.ts +270 -0
- package/types/nanahoshi-mona-ui-locales-ar-sa.d.ts +9 -0
- package/types/nanahoshi-mona-ui-locales-de-de.d.ts +9 -0
- package/types/nanahoshi-mona-ui-locales-es-es.d.ts +9 -0
- package/types/nanahoshi-mona-ui-locales-fr-fr.d.ts +9 -0
- package/types/nanahoshi-mona-ui-locales-id-id.d.ts +9 -0
- package/types/nanahoshi-mona-ui-locales-it-it.d.ts +9 -0
- package/types/nanahoshi-mona-ui-locales-ja-jp.d.ts +9 -0
- package/types/nanahoshi-mona-ui-locales-ko-kr.d.ts +9 -0
- package/types/nanahoshi-mona-ui-locales-pl-pl.d.ts +9 -0
- package/types/nanahoshi-mona-ui-locales-pt-br.d.ts +9 -0
- package/types/nanahoshi-mona-ui-locales-ru-ru.d.ts +9 -0
- package/types/nanahoshi-mona-ui-locales-tr-tr.d.ts +9 -0
- package/types/nanahoshi-mona-ui-locales-zh-cn.d.ts +9 -0
- package/types/nanahoshi-mona-ui-locales-zh-tw.d.ts +9 -0
- package/types/nanahoshi-mona-ui-sortable.d.ts +245 -0
- package/types/nanahoshi-mona-ui-tabs.d.ts +46 -0
|
@@ -438,6 +438,11 @@
|
|
|
438
438
|
"sortOrder": "Порядок сортировки {position}",
|
|
439
439
|
"toolbar": "Панель инструментов таблицы"
|
|
440
440
|
},
|
|
441
|
+
"kanban": {
|
|
442
|
+
"cardCount": "{count, plural, one {# карточка} few {# карточки} many {# карточек} other {# карточки}}",
|
|
443
|
+
"cardCountWithLimit": "{count} из {limit, plural, one {# карточки} few {# карточек} many {# карточек} other {# карточки}}",
|
|
444
|
+
"emptyColumn": "Нет карточек"
|
|
445
|
+
},
|
|
441
446
|
"label": {
|
|
442
447
|
"optional": "Необязательно"
|
|
443
448
|
},
|
|
@@ -553,6 +558,10 @@
|
|
|
553
558
|
"minimumValue": "Минимальное значение",
|
|
554
559
|
"sliderValue": "Значение ползунка"
|
|
555
560
|
},
|
|
561
|
+
"sortable": {
|
|
562
|
+
"itemMoved": "«{item}» теперь на позиции {position} из {total}",
|
|
563
|
+
"itemMovedToList": "«{item}» теперь в списке «{list}», позиция {position} из {total}"
|
|
564
|
+
},
|
|
556
565
|
"spinner": {
|
|
557
566
|
"cancel": "Отмена",
|
|
558
567
|
"loading": "Загрузка"
|
|
@@ -438,6 +438,11 @@
|
|
|
438
438
|
"sortOrder": "Sıralama düzeni {position}",
|
|
439
439
|
"toolbar": "Tablo araç çubuğu"
|
|
440
440
|
},
|
|
441
|
+
"kanban": {
|
|
442
|
+
"cardCount": "{count} kart",
|
|
443
|
+
"cardCountWithLimit": "{count}/{limit} kart",
|
|
444
|
+
"emptyColumn": "Kart yok"
|
|
445
|
+
},
|
|
441
446
|
"label": {
|
|
442
447
|
"optional": "İsteğe bağlı"
|
|
443
448
|
},
|
|
@@ -553,6 +558,10 @@
|
|
|
553
558
|
"minimumValue": "Minimum değer",
|
|
554
559
|
"sliderValue": "Kaydırıcı değeri"
|
|
555
560
|
},
|
|
561
|
+
"sortable": {
|
|
562
|
+
"itemMoved": "{item}, {total} içinde {position}. konuma taşındı",
|
|
563
|
+
"itemMovedToList": "{item}, {list} listesine taşındı; {total} içinde {position}. konum"
|
|
564
|
+
},
|
|
556
565
|
"spinner": {
|
|
557
566
|
"cancel": "İptal",
|
|
558
567
|
"loading": "Yükleniyor"
|
|
@@ -438,6 +438,11 @@
|
|
|
438
438
|
"sortOrder": "排序顺序 {position}",
|
|
439
439
|
"toolbar": "表格工具栏"
|
|
440
440
|
},
|
|
441
|
+
"kanban": {
|
|
442
|
+
"cardCount": "{count} 张卡片",
|
|
443
|
+
"cardCountWithLimit": "{count}/{limit} 张卡片",
|
|
444
|
+
"emptyColumn": "暂无卡片"
|
|
445
|
+
},
|
|
441
446
|
"label": {
|
|
442
447
|
"optional": "可选"
|
|
443
448
|
},
|
|
@@ -553,6 +558,10 @@
|
|
|
553
558
|
"minimumValue": "最小值",
|
|
554
559
|
"sliderValue": "滑块数值"
|
|
555
560
|
},
|
|
561
|
+
"sortable": {
|
|
562
|
+
"itemMoved": "{item} 已移至第 {position} 位,共 {total} 位",
|
|
563
|
+
"itemMovedToList": "{item} 已移至{list},第 {position} 位,共 {total} 位"
|
|
564
|
+
},
|
|
556
565
|
"spinner": {
|
|
557
566
|
"cancel": "取消",
|
|
558
567
|
"loading": "加载中"
|
|
@@ -438,6 +438,11 @@
|
|
|
438
438
|
"sortOrder": "排序順序 {position}",
|
|
439
439
|
"toolbar": "表格工具列"
|
|
440
440
|
},
|
|
441
|
+
"kanban": {
|
|
442
|
+
"cardCount": "{count} 張卡片",
|
|
443
|
+
"cardCountWithLimit": "{count}/{limit} 張卡片",
|
|
444
|
+
"emptyColumn": "沒有卡片"
|
|
445
|
+
},
|
|
441
446
|
"label": {
|
|
442
447
|
"optional": "選填"
|
|
443
448
|
},
|
|
@@ -553,6 +558,10 @@
|
|
|
553
558
|
"minimumValue": "最小值",
|
|
554
559
|
"sliderValue": "滑桿數值"
|
|
555
560
|
},
|
|
561
|
+
"sortable": {
|
|
562
|
+
"itemMoved": "{item} 已移至第 {position} 位,共 {total} 位",
|
|
563
|
+
"itemMovedToList": "{item} 已移至{list},第 {position} 位,共 {total} 位"
|
|
564
|
+
},
|
|
556
565
|
"spinner": {
|
|
557
566
|
"cancel": "取消",
|
|
558
567
|
"loading": "載入中"
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@nanahoshi/mona-ui",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.41.0",
|
|
4
4
|
"description": "A very light Angular UI framework",
|
|
5
5
|
"author": "Nanahoshi",
|
|
6
6
|
"repository": {
|
|
@@ -202,6 +202,10 @@
|
|
|
202
202
|
"types": "./types/nanahoshi-mona-ui-internal-tree.d.ts",
|
|
203
203
|
"default": "./fesm2022/nanahoshi-mona-ui-internal-tree.mjs"
|
|
204
204
|
},
|
|
205
|
+
"./kanban": {
|
|
206
|
+
"types": "./types/nanahoshi-mona-ui-kanban.d.ts",
|
|
207
|
+
"default": "./fesm2022/nanahoshi-mona-ui-kanban.mjs"
|
|
208
|
+
},
|
|
205
209
|
"./label": {
|
|
206
210
|
"types": "./types/nanahoshi-mona-ui-label.d.ts",
|
|
207
211
|
"default": "./fesm2022/nanahoshi-mona-ui-label.mjs"
|
|
@@ -374,6 +378,10 @@
|
|
|
374
378
|
"types": "./types/nanahoshi-mona-ui-slider.d.ts",
|
|
375
379
|
"default": "./fesm2022/nanahoshi-mona-ui-slider.mjs"
|
|
376
380
|
},
|
|
381
|
+
"./sortable": {
|
|
382
|
+
"types": "./types/nanahoshi-mona-ui-sortable.d.ts",
|
|
383
|
+
"default": "./fesm2022/nanahoshi-mona-ui-sortable.mjs"
|
|
384
|
+
},
|
|
377
385
|
"./spinner": {
|
|
378
386
|
"types": "./types/nanahoshi-mona-ui-spinner.d.ts",
|
|
379
387
|
"default": "./fesm2022/nanahoshi-mona-ui-spinner.mjs"
|
|
@@ -694,6 +694,14 @@ export interface MonaGridMessages {
|
|
|
694
694
|
/** The accessible name of the toolbar above the grid. */
|
|
695
695
|
readonly toolbar: string;
|
|
696
696
|
}
|
|
697
|
+
export interface MonaKanbanMessages {
|
|
698
|
+
/** How many cards a column holds, read after its title ("3 cards"). */
|
|
699
|
+
cardCount(count: number): string;
|
|
700
|
+
/** How many cards a column with a limit holds, read after its title ("3 of 5 cards"). */
|
|
701
|
+
cardCountWithLimit(count: number, limit: number): string;
|
|
702
|
+
/** Shown in a column with no cards. */
|
|
703
|
+
readonly emptyColumn: string;
|
|
704
|
+
}
|
|
697
705
|
export interface MonaLabelMessages {
|
|
698
706
|
readonly optional: string;
|
|
699
707
|
}
|
|
@@ -858,6 +866,15 @@ export interface MonaSliderMessages {
|
|
|
858
866
|
readonly minimumValue: string;
|
|
859
867
|
readonly sliderValue: string;
|
|
860
868
|
}
|
|
869
|
+
export interface MonaSortableMessages {
|
|
870
|
+
/** Announced after an item moves within its list, with its name and new position ("Draft moved to position 2 of 5"). */
|
|
871
|
+
itemMoved(item: string, position: number, total: number): string;
|
|
872
|
+
/**
|
|
873
|
+
* Announced after an item moves to another list, with its name, the list's name and its position there ("Draft moved
|
|
874
|
+
* to Done, position 1 of 3").
|
|
875
|
+
*/
|
|
876
|
+
itemMovedToList(item: string, list: string, position: number, total: number): string;
|
|
877
|
+
}
|
|
861
878
|
export interface MonaSpinnerMessages {
|
|
862
879
|
readonly cancel: string;
|
|
863
880
|
readonly loading: string;
|
|
@@ -1011,6 +1028,7 @@ export interface MonaLocaleMessages {
|
|
|
1011
1028
|
filter: MonaFilterMessages;
|
|
1012
1029
|
formField: MonaFormFieldMessages;
|
|
1013
1030
|
grid: MonaGridMessages;
|
|
1031
|
+
kanban: MonaKanbanMessages;
|
|
1014
1032
|
label: MonaLabelMessages;
|
|
1015
1033
|
list: MonaListMessages;
|
|
1016
1034
|
listBox: MonaListBoxMessages;
|
|
@@ -1028,6 +1046,7 @@ export interface MonaLocaleMessages {
|
|
|
1028
1046
|
sheet: MonaSheetMessages;
|
|
1029
1047
|
sidebar: MonaSidebarMessages;
|
|
1030
1048
|
slider: MonaSliderMessages;
|
|
1049
|
+
sortable: MonaSortableMessages;
|
|
1031
1050
|
spinner: MonaSpinnerMessages;
|
|
1032
1051
|
splitButton: MonaSplitButtonMessages;
|
|
1033
1052
|
splitter: MonaSplitterMessages;
|
|
@@ -0,0 +1,270 @@
|
|
|
1
|
+
import * as i0 from "@angular/core";
|
|
2
|
+
import { TemplateRef } from "@angular/core";
|
|
3
|
+
import * as i2 from "@nanahoshi/mona-ui/sortable";
|
|
4
|
+
import { SortableMoveEvent } from "@nanahoshi/mona-ui/sortable";
|
|
5
|
+
import { PreventableEvent } from "@nanahoshi/mona-ui/common";
|
|
6
|
+
import * as i1 from "@angular/cdk/scrolling";
|
|
7
|
+
import { MonaKanbanMessages } from "@nanahoshi/mona-ui/i18n";
|
|
8
|
+
/**
|
|
9
|
+
* A card dragged, or moved with Control+Shift and the arrow keys, to a new place on a Kanban board: within its column
|
|
10
|
+
* or into another. Call `preventDefault()` to refuse the move: the board then doesn't emit its new data, and the card
|
|
11
|
+
* goes back where it was.
|
|
12
|
+
*/
|
|
13
|
+
export declare class KanbanCardMoveEvent<T = unknown> extends PreventableEvent {
|
|
14
|
+
#private;
|
|
15
|
+
constructor(options: KanbanCardMoveEventOptions<T>, originalEvent?: Event);
|
|
16
|
+
/** The card as it was before the move. */
|
|
17
|
+
get card(): T;
|
|
18
|
+
/** The card's index in its column after the move. */
|
|
19
|
+
get currentIndex(): number;
|
|
20
|
+
/** The board's cards after the move: what `dataChange` emits unless the move is refused. */
|
|
21
|
+
get data(): readonly T[];
|
|
22
|
+
/**
|
|
23
|
+
* The card after the move. A card that changes column is a copy with its status field set to the new column's
|
|
24
|
+
* status; one that stays in its column is the same object as `card`.
|
|
25
|
+
*/
|
|
26
|
+
get movedCard(): T;
|
|
27
|
+
/** The card's index in its column before the move. */
|
|
28
|
+
get previousIndex(): number;
|
|
29
|
+
/** The status of the column the card comes from. */
|
|
30
|
+
get previousStatus(): unknown;
|
|
31
|
+
/** The status of the column the card moves to. */
|
|
32
|
+
get status(): unknown;
|
|
33
|
+
}
|
|
34
|
+
interface KanbanCardMoveEventOptions<T> {
|
|
35
|
+
readonly card: T;
|
|
36
|
+
readonly currentIndex: number;
|
|
37
|
+
readonly data: readonly T[];
|
|
38
|
+
readonly movedCard: T;
|
|
39
|
+
readonly previousIndex: number;
|
|
40
|
+
readonly previousStatus: unknown;
|
|
41
|
+
readonly status: unknown;
|
|
42
|
+
}
|
|
43
|
+
/** A column of a Kanban board: the cards whose status field holds its `status`. */
|
|
44
|
+
interface KanbanColumn {
|
|
45
|
+
/**
|
|
46
|
+
* The most cards the column takes. Once it holds that many, cards from other columns can't move into it, and its
|
|
47
|
+
* count is highlighted. Without it, the column takes any number.
|
|
48
|
+
*/
|
|
49
|
+
readonly limit?: number;
|
|
50
|
+
/** The value of a card's status field that puts the card in this column. */
|
|
51
|
+
readonly status: unknown;
|
|
52
|
+
/** The column's title, which also names it in announcements. */
|
|
53
|
+
readonly title: string;
|
|
54
|
+
}
|
|
55
|
+
/** The context of a `monaKanbanCardTemplate`: the card, as `let-card`. */
|
|
56
|
+
interface KanbanCardTemplateContext<T = unknown> {
|
|
57
|
+
/** The card (`let-card`). */
|
|
58
|
+
readonly $implicit: T;
|
|
59
|
+
/** The column the card is in (`let-column="column"`). */
|
|
60
|
+
readonly column: KanbanColumn;
|
|
61
|
+
/** The card's index in its column (`let-index="index"`). */
|
|
62
|
+
readonly index: number;
|
|
63
|
+
}
|
|
64
|
+
/** The context of a `monaKanbanColumnHeaderTemplate` or `monaKanbanColumnFooterTemplate`: the column, as `let-column`. */
|
|
65
|
+
interface KanbanColumnTemplateContext<T = unknown> {
|
|
66
|
+
/** The column (`let-column`). */
|
|
67
|
+
readonly $implicit: KanbanColumn;
|
|
68
|
+
/** The column's cards, in order (`let-cards="cards"`). */
|
|
69
|
+
readonly cards: readonly T[];
|
|
70
|
+
/** How many cards the column holds (`let-count="count"`). */
|
|
71
|
+
readonly count: number;
|
|
72
|
+
}
|
|
73
|
+
/** A card's place on the board: its column's index, and its index in the column. */
|
|
74
|
+
interface CardPosition {
|
|
75
|
+
readonly column: number;
|
|
76
|
+
readonly index: number;
|
|
77
|
+
}
|
|
78
|
+
/**
|
|
79
|
+
* @description
|
|
80
|
+
* A board of columns that cards move between, by dragging or with Control+Shift and the arrow keys (Command+Shift on
|
|
81
|
+
* macOS). Each card goes in the column whose `status` its status field holds, in the order of `data`. A move emits
|
|
82
|
+
* `cardMove`, then the new data through `dataChange`, so bind `[(data)]`. The arrow keys move focus between cards.
|
|
83
|
+
*/
|
|
84
|
+
export declare class KanbanComponent<T extends object = Record<string, unknown>> {
|
|
85
|
+
#private;
|
|
86
|
+
/** The card that holds the board's Tab stop: the one last focused, else the first card. */
|
|
87
|
+
protected readonly activeCard: import("@angular/core").Signal<CardPosition | null>;
|
|
88
|
+
protected readonly baseClass: import("@angular/core").Signal<string>;
|
|
89
|
+
protected readonly bodyClass: string;
|
|
90
|
+
protected readonly cardClass: string;
|
|
91
|
+
protected readonly cardTemplate: import("@angular/core").Signal<TemplateRef<any> | undefined>;
|
|
92
|
+
/** Each column's cards, in the order of `data`. */
|
|
93
|
+
protected readonly columnCards: import("@angular/core").Signal<T[][]>;
|
|
94
|
+
protected readonly columnClass: string;
|
|
95
|
+
protected readonly columnFooterTemplate: import("@angular/core").Signal<TemplateRef<any> | undefined>;
|
|
96
|
+
protected readonly columnHeaderTemplate: import("@angular/core").Signal<TemplateRef<any> | undefined>;
|
|
97
|
+
protected readonly emptyClass: string;
|
|
98
|
+
/** Whether each column takes a card from another column: always, or while it's under its limit. */
|
|
99
|
+
protected readonly enterChecks: import("@angular/core").Signal<(() => boolean)[]>;
|
|
100
|
+
protected readonly footerClass: string;
|
|
101
|
+
protected readonly headerClass: string;
|
|
102
|
+
protected readonly id: string;
|
|
103
|
+
protected readonly listClass: string;
|
|
104
|
+
protected readonly messages: import("@angular/core").Signal<import("@nanahoshi/mona-ui/i18n").MonaKanbanMessages>;
|
|
105
|
+
protected readonly titleClass: string;
|
|
106
|
+
/**
|
|
107
|
+
* @description Emitted with a {@link KanbanCardMoveEvent} when a card moves within its column or into another,
|
|
108
|
+
* before `dataChange`. This event is preventable.
|
|
109
|
+
*/
|
|
110
|
+
readonly cardMove: import("@angular/core").OutputEmitterRef<KanbanCardMoveEvent<T>>;
|
|
111
|
+
/**
|
|
112
|
+
* @description The board's columns, in order. A card whose status matches no column isn't shown.
|
|
113
|
+
*/
|
|
114
|
+
readonly columns: import("@angular/core").InputSignal<readonly KanbanColumn[]>;
|
|
115
|
+
/**
|
|
116
|
+
* @description The cards. Each goes in the column whose `status` its status field holds, in the order of this
|
|
117
|
+
* array. Bind it two-way, `[(data)]`, to take each move.
|
|
118
|
+
*/
|
|
119
|
+
readonly data: import("@angular/core").InputSignal<readonly T[]>;
|
|
120
|
+
/**
|
|
121
|
+
* @description Emitted with the board's new cards after a move, unless the move was refused. A card that changes
|
|
122
|
+
* column is a copy with its status field set to the column's status.
|
|
123
|
+
*/
|
|
124
|
+
readonly dataChange: import("@angular/core").OutputEmitterRef<T[]>;
|
|
125
|
+
/**
|
|
126
|
+
* @description Stops cards from moving, by pointer or keyboard. Focus still moves between them, and what their
|
|
127
|
+
* template holds still works.
|
|
128
|
+
* @default false
|
|
129
|
+
*/
|
|
130
|
+
readonly disabled: import("@angular/core").InputSignalWithTransform<boolean, unknown>;
|
|
131
|
+
/**
|
|
132
|
+
* @description The field of each card that holds its column's `status`.
|
|
133
|
+
* @default "status"
|
|
134
|
+
*/
|
|
135
|
+
readonly statusField: import("@angular/core").InputSignal<string>;
|
|
136
|
+
/**
|
|
137
|
+
* @description The field of each card shown as its text when there's no card template, and used as its name in
|
|
138
|
+
* announcements of its moves.
|
|
139
|
+
* @default "title"
|
|
140
|
+
*/
|
|
141
|
+
readonly textField: import("@angular/core").InputSignal<string>;
|
|
142
|
+
/**
|
|
143
|
+
* @description Additional CSS classes merged onto the host element via `tailwind-merge`.
|
|
144
|
+
* @default ""
|
|
145
|
+
*/
|
|
146
|
+
readonly userClass: import("@angular/core").InputSignal<string>;
|
|
147
|
+
protected cardContext(card: T, column: KanbanColumn, index: number): KanbanCardTemplateContext<T>;
|
|
148
|
+
protected cardText(card: T): string;
|
|
149
|
+
protected columnContext(column: KanbanColumn, cards: readonly T[]): KanbanColumnTemplateContext<T>;
|
|
150
|
+
/** The count as the header shows it: "3", or "3 / 5" for a column with a limit. */
|
|
151
|
+
protected countBadge(count: number, column: KanbanColumn): string;
|
|
152
|
+
protected countClass(count: number, column: KanbanColumn): string;
|
|
153
|
+
protected countText(count: number, column: KanbanColumn): string;
|
|
154
|
+
protected onCardFocus(column: number, index: number): void;
|
|
155
|
+
/** Arrow keys move focus: Up and Down within a column, Left and Right to the next column with cards. */
|
|
156
|
+
protected onCardKeydown(event: KeyboardEvent, column: number, index: number): void;
|
|
157
|
+
/** Turns a list's move into the board's new data: the card in its new place, with its new status. */
|
|
158
|
+
protected onCardMove(event: SortableMoveEvent<T>, columnIndex: number): void;
|
|
159
|
+
private findAdjacentColumn;
|
|
160
|
+
private focusCard;
|
|
161
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<KanbanComponent<any>, never>;
|
|
162
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<KanbanComponent<any>, "mona-kanban", never, {
|
|
163
|
+
"columns": {
|
|
164
|
+
"alias": "columns";
|
|
165
|
+
"required": true;
|
|
166
|
+
"isSignal": true;
|
|
167
|
+
};
|
|
168
|
+
"data": {
|
|
169
|
+
"alias": "data";
|
|
170
|
+
"required": true;
|
|
171
|
+
"isSignal": true;
|
|
172
|
+
};
|
|
173
|
+
"disabled": {
|
|
174
|
+
"alias": "disabled";
|
|
175
|
+
"required": false;
|
|
176
|
+
"isSignal": true;
|
|
177
|
+
};
|
|
178
|
+
"statusField": {
|
|
179
|
+
"alias": "statusField";
|
|
180
|
+
"required": false;
|
|
181
|
+
"isSignal": true;
|
|
182
|
+
};
|
|
183
|
+
"textField": {
|
|
184
|
+
"alias": "textField";
|
|
185
|
+
"required": false;
|
|
186
|
+
"isSignal": true;
|
|
187
|
+
};
|
|
188
|
+
"userClass": {
|
|
189
|
+
"alias": "class";
|
|
190
|
+
"required": false;
|
|
191
|
+
"isSignal": true;
|
|
192
|
+
};
|
|
193
|
+
}, {
|
|
194
|
+
"cardMove": "cardMove";
|
|
195
|
+
"dataChange": "dataChange";
|
|
196
|
+
}, ["cardTemplate", "columnFooterTemplate", "columnHeaderTemplate"], never, true, [{
|
|
197
|
+
directive: typeof i1.CdkScrollable;
|
|
198
|
+
inputs: {};
|
|
199
|
+
outputs: {};
|
|
200
|
+
}, {
|
|
201
|
+
directive: typeof i2.SortableGroupDirective;
|
|
202
|
+
inputs: {};
|
|
203
|
+
outputs: {};
|
|
204
|
+
}]>;
|
|
205
|
+
}
|
|
206
|
+
/**
|
|
207
|
+
* Template for each card of a Kanban board. The card is the template's implicit value (`let-card`), with its column
|
|
208
|
+
* (`let-column="column"`) and its index in the column (`let-index="index"`). Bind the board's data to
|
|
209
|
+
* `monaKanbanCardTemplateOf` to type the card; without it, the card is `any` in templates.
|
|
210
|
+
*/
|
|
211
|
+
export declare class KanbanCardTemplateDirective<T = any> {
|
|
212
|
+
/**
|
|
213
|
+
* @description The board's data, used only to type the template's card. Optional.
|
|
214
|
+
* @default null
|
|
215
|
+
*/
|
|
216
|
+
readonly monaKanbanCardTemplateOf: import("@angular/core").InputSignal<Iterable<T> | null | undefined>;
|
|
217
|
+
static ngTemplateContextGuard<T>(_directive: KanbanCardTemplateDirective<T>, _context: unknown): _context is KanbanCardTemplateContext<T>;
|
|
218
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<KanbanCardTemplateDirective<any>, never>;
|
|
219
|
+
static ɵdir: i0.ɵɵDirectiveDeclaration<KanbanCardTemplateDirective<any>, "ng-template[monaKanbanCardTemplate]", never, {
|
|
220
|
+
"monaKanbanCardTemplateOf": {
|
|
221
|
+
"alias": "monaKanbanCardTemplateOf";
|
|
222
|
+
"required": false;
|
|
223
|
+
"isSignal": true;
|
|
224
|
+
};
|
|
225
|
+
}, {}, never, never, true, never>;
|
|
226
|
+
}
|
|
227
|
+
/**
|
|
228
|
+
* Template for the foot of each column of a Kanban board, below its cards, such as for an Add card button. The column
|
|
229
|
+
* is the template's implicit value (`let-column`), with its cards (`let-cards="cards"`) and how many there are
|
|
230
|
+
* (`let-count="count"`).
|
|
231
|
+
*/
|
|
232
|
+
export declare class KanbanColumnFooterTemplateDirective<T = any> {
|
|
233
|
+
/**
|
|
234
|
+
* @description The board's data, used only to type the template's cards. Optional.
|
|
235
|
+
* @default null
|
|
236
|
+
*/
|
|
237
|
+
readonly monaKanbanColumnFooterTemplateOf: import("@angular/core").InputSignal<Iterable<T> | null | undefined>;
|
|
238
|
+
static ngTemplateContextGuard<T>(_directive: KanbanColumnFooterTemplateDirective<T>, _context: unknown): _context is KanbanColumnTemplateContext<T>;
|
|
239
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<KanbanColumnFooterTemplateDirective<any>, never>;
|
|
240
|
+
static ɵdir: i0.ɵɵDirectiveDeclaration<KanbanColumnFooterTemplateDirective<any>, "ng-template[monaKanbanColumnFooterTemplate]", never, {
|
|
241
|
+
"monaKanbanColumnFooterTemplateOf": {
|
|
242
|
+
"alias": "monaKanbanColumnFooterTemplateOf";
|
|
243
|
+
"required": false;
|
|
244
|
+
"isSignal": true;
|
|
245
|
+
};
|
|
246
|
+
}, {}, never, never, true, never>;
|
|
247
|
+
}
|
|
248
|
+
/**
|
|
249
|
+
* Template for the header of each column of a Kanban board, in place of its title and count. The column is the
|
|
250
|
+
* template's implicit value (`let-column`), with its cards (`let-cards="cards"`) and how many there are
|
|
251
|
+
* (`let-count="count"`). The header names the column's list, so keep the title in it.
|
|
252
|
+
*/
|
|
253
|
+
export declare class KanbanColumnHeaderTemplateDirective<T = any> {
|
|
254
|
+
/**
|
|
255
|
+
* @description The board's data, used only to type the template's cards. Optional.
|
|
256
|
+
* @default null
|
|
257
|
+
*/
|
|
258
|
+
readonly monaKanbanColumnHeaderTemplateOf: import("@angular/core").InputSignal<Iterable<T> | null | undefined>;
|
|
259
|
+
static ngTemplateContextGuard<T>(_directive: KanbanColumnHeaderTemplateDirective<T>, _context: unknown): _context is KanbanColumnTemplateContext<T>;
|
|
260
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<KanbanColumnHeaderTemplateDirective<any>, never>;
|
|
261
|
+
static ɵdir: i0.ɵɵDirectiveDeclaration<KanbanColumnHeaderTemplateDirective<any>, "ng-template[monaKanbanColumnHeaderTemplate]", never, {
|
|
262
|
+
"monaKanbanColumnHeaderTemplateOf": {
|
|
263
|
+
"alias": "monaKanbanColumnHeaderTemplateOf";
|
|
264
|
+
"required": false;
|
|
265
|
+
"isSignal": true;
|
|
266
|
+
};
|
|
267
|
+
}, {}, never, never, true, never>;
|
|
268
|
+
}
|
|
269
|
+
export declare const KANBAN_DEFAULT_MESSAGES: MonaKanbanMessages;
|
|
270
|
+
export type { KanbanCardMoveEventOptions, KanbanCardTemplateContext, KanbanColumn, KanbanColumnTemplateContext };
|
|
@@ -441,6 +441,11 @@ export declare const MONA_AR_SA_LOCALE: {
|
|
|
441
441
|
sortOrder: (position: number) => string;
|
|
442
442
|
toolbar: string;
|
|
443
443
|
};
|
|
444
|
+
kanban: {
|
|
445
|
+
cardCount: (count: number) => string;
|
|
446
|
+
cardCountWithLimit: (count: number, limit: number) => string;
|
|
447
|
+
emptyColumn: string;
|
|
448
|
+
};
|
|
444
449
|
label: {
|
|
445
450
|
optional: string;
|
|
446
451
|
};
|
|
@@ -556,6 +561,10 @@ export declare const MONA_AR_SA_LOCALE: {
|
|
|
556
561
|
minimumValue: string;
|
|
557
562
|
sliderValue: string;
|
|
558
563
|
};
|
|
564
|
+
sortable: {
|
|
565
|
+
itemMoved: (item: string, position: number, total: number) => string;
|
|
566
|
+
itemMovedToList: (item: string, list: string, position: number, total: number) => string;
|
|
567
|
+
};
|
|
559
568
|
spinner: {
|
|
560
569
|
cancel: string;
|
|
561
570
|
loading: string;
|
|
@@ -441,6 +441,11 @@ export declare const MONA_DE_DE_LOCALE: {
|
|
|
441
441
|
sortOrder: (position: number) => string;
|
|
442
442
|
toolbar: string;
|
|
443
443
|
};
|
|
444
|
+
kanban: {
|
|
445
|
+
cardCount: (count: number) => string;
|
|
446
|
+
cardCountWithLimit: (count: number, limit: number) => string;
|
|
447
|
+
emptyColumn: string;
|
|
448
|
+
};
|
|
444
449
|
label: {
|
|
445
450
|
optional: string;
|
|
446
451
|
};
|
|
@@ -556,6 +561,10 @@ export declare const MONA_DE_DE_LOCALE: {
|
|
|
556
561
|
minimumValue: string;
|
|
557
562
|
sliderValue: string;
|
|
558
563
|
};
|
|
564
|
+
sortable: {
|
|
565
|
+
itemMoved: (item: string, position: number, total: number) => string;
|
|
566
|
+
itemMovedToList: (item: string, list: string, position: number, total: number) => string;
|
|
567
|
+
};
|
|
559
568
|
spinner: {
|
|
560
569
|
cancel: string;
|
|
561
570
|
loading: string;
|
|
@@ -441,6 +441,11 @@ export declare const MONA_ES_ES_LOCALE: {
|
|
|
441
441
|
sortOrder: (position: number) => string;
|
|
442
442
|
toolbar: string;
|
|
443
443
|
};
|
|
444
|
+
kanban: {
|
|
445
|
+
cardCount: (count: number) => string;
|
|
446
|
+
cardCountWithLimit: (count: number, limit: number) => string;
|
|
447
|
+
emptyColumn: string;
|
|
448
|
+
};
|
|
444
449
|
label: {
|
|
445
450
|
optional: string;
|
|
446
451
|
};
|
|
@@ -556,6 +561,10 @@ export declare const MONA_ES_ES_LOCALE: {
|
|
|
556
561
|
minimumValue: string;
|
|
557
562
|
sliderValue: string;
|
|
558
563
|
};
|
|
564
|
+
sortable: {
|
|
565
|
+
itemMoved: (item: string, position: number, total: number) => string;
|
|
566
|
+
itemMovedToList: (item: string, list: string, position: number, total: number) => string;
|
|
567
|
+
};
|
|
559
568
|
spinner: {
|
|
560
569
|
cancel: string;
|
|
561
570
|
loading: string;
|
|
@@ -441,6 +441,11 @@ export declare const MONA_FR_FR_LOCALE: {
|
|
|
441
441
|
sortOrder: (position: number) => string;
|
|
442
442
|
toolbar: string;
|
|
443
443
|
};
|
|
444
|
+
kanban: {
|
|
445
|
+
cardCount: (count: number) => string;
|
|
446
|
+
cardCountWithLimit: (count: number, limit: number) => string;
|
|
447
|
+
emptyColumn: string;
|
|
448
|
+
};
|
|
444
449
|
label: {
|
|
445
450
|
optional: string;
|
|
446
451
|
};
|
|
@@ -556,6 +561,10 @@ export declare const MONA_FR_FR_LOCALE: {
|
|
|
556
561
|
minimumValue: string;
|
|
557
562
|
sliderValue: string;
|
|
558
563
|
};
|
|
564
|
+
sortable: {
|
|
565
|
+
itemMoved: (item: string, position: number, total: number) => string;
|
|
566
|
+
itemMovedToList: (item: string, list: string, position: number, total: number) => string;
|
|
567
|
+
};
|
|
559
568
|
spinner: {
|
|
560
569
|
cancel: string;
|
|
561
570
|
loading: string;
|
|
@@ -441,6 +441,11 @@ export declare const MONA_ID_ID_LOCALE: {
|
|
|
441
441
|
sortOrder: (position: number) => string;
|
|
442
442
|
toolbar: string;
|
|
443
443
|
};
|
|
444
|
+
kanban: {
|
|
445
|
+
cardCount: (count: number) => string;
|
|
446
|
+
cardCountWithLimit: (count: number, limit: number) => string;
|
|
447
|
+
emptyColumn: string;
|
|
448
|
+
};
|
|
444
449
|
label: {
|
|
445
450
|
optional: string;
|
|
446
451
|
};
|
|
@@ -556,6 +561,10 @@ export declare const MONA_ID_ID_LOCALE: {
|
|
|
556
561
|
minimumValue: string;
|
|
557
562
|
sliderValue: string;
|
|
558
563
|
};
|
|
564
|
+
sortable: {
|
|
565
|
+
itemMoved: (item: string, position: number, total: number) => string;
|
|
566
|
+
itemMovedToList: (item: string, list: string, position: number, total: number) => string;
|
|
567
|
+
};
|
|
559
568
|
spinner: {
|
|
560
569
|
cancel: string;
|
|
561
570
|
loading: string;
|
|
@@ -441,6 +441,11 @@ export declare const MONA_IT_IT_LOCALE: {
|
|
|
441
441
|
sortOrder: (position: number) => string;
|
|
442
442
|
toolbar: string;
|
|
443
443
|
};
|
|
444
|
+
kanban: {
|
|
445
|
+
cardCount: (count: number) => string;
|
|
446
|
+
cardCountWithLimit: (count: number, limit: number) => string;
|
|
447
|
+
emptyColumn: string;
|
|
448
|
+
};
|
|
444
449
|
label: {
|
|
445
450
|
optional: string;
|
|
446
451
|
};
|
|
@@ -556,6 +561,10 @@ export declare const MONA_IT_IT_LOCALE: {
|
|
|
556
561
|
minimumValue: string;
|
|
557
562
|
sliderValue: string;
|
|
558
563
|
};
|
|
564
|
+
sortable: {
|
|
565
|
+
itemMoved: (item: string, position: number, total: number) => string;
|
|
566
|
+
itemMovedToList: (item: string, list: string, position: number, total: number) => string;
|
|
567
|
+
};
|
|
559
568
|
spinner: {
|
|
560
569
|
cancel: string;
|
|
561
570
|
loading: string;
|
|
@@ -441,6 +441,11 @@ export declare const MONA_JA_JP_LOCALE: {
|
|
|
441
441
|
sortOrder: (position: number) => string;
|
|
442
442
|
toolbar: string;
|
|
443
443
|
};
|
|
444
|
+
kanban: {
|
|
445
|
+
cardCount: (count: number) => string;
|
|
446
|
+
cardCountWithLimit: (count: number, limit: number) => string;
|
|
447
|
+
emptyColumn: string;
|
|
448
|
+
};
|
|
444
449
|
label: {
|
|
445
450
|
optional: string;
|
|
446
451
|
};
|
|
@@ -556,6 +561,10 @@ export declare const MONA_JA_JP_LOCALE: {
|
|
|
556
561
|
minimumValue: string;
|
|
557
562
|
sliderValue: string;
|
|
558
563
|
};
|
|
564
|
+
sortable: {
|
|
565
|
+
itemMoved: (item: string, position: number, total: number) => string;
|
|
566
|
+
itemMovedToList: (item: string, list: string, position: number, total: number) => string;
|
|
567
|
+
};
|
|
559
568
|
spinner: {
|
|
560
569
|
cancel: string;
|
|
561
570
|
loading: string;
|
|
@@ -441,6 +441,11 @@ export declare const MONA_KO_KR_LOCALE: {
|
|
|
441
441
|
sortOrder: (position: number) => string;
|
|
442
442
|
toolbar: string;
|
|
443
443
|
};
|
|
444
|
+
kanban: {
|
|
445
|
+
cardCount: (count: number) => string;
|
|
446
|
+
cardCountWithLimit: (count: number, limit: number) => string;
|
|
447
|
+
emptyColumn: string;
|
|
448
|
+
};
|
|
444
449
|
label: {
|
|
445
450
|
optional: string;
|
|
446
451
|
};
|
|
@@ -556,6 +561,10 @@ export declare const MONA_KO_KR_LOCALE: {
|
|
|
556
561
|
minimumValue: string;
|
|
557
562
|
sliderValue: string;
|
|
558
563
|
};
|
|
564
|
+
sortable: {
|
|
565
|
+
itemMoved: (item: string, position: number, total: number) => string;
|
|
566
|
+
itemMovedToList: (item: string, list: string, position: number, total: number) => string;
|
|
567
|
+
};
|
|
559
568
|
spinner: {
|
|
560
569
|
cancel: string;
|
|
561
570
|
loading: string;
|
|
@@ -441,6 +441,11 @@ export declare const MONA_PL_PL_LOCALE: {
|
|
|
441
441
|
sortOrder: (position: number) => string;
|
|
442
442
|
toolbar: string;
|
|
443
443
|
};
|
|
444
|
+
kanban: {
|
|
445
|
+
cardCount: (count: number) => string;
|
|
446
|
+
cardCountWithLimit: (count: number, limit: number) => string;
|
|
447
|
+
emptyColumn: string;
|
|
448
|
+
};
|
|
444
449
|
label: {
|
|
445
450
|
optional: string;
|
|
446
451
|
};
|
|
@@ -556,6 +561,10 @@ export declare const MONA_PL_PL_LOCALE: {
|
|
|
556
561
|
minimumValue: string;
|
|
557
562
|
sliderValue: string;
|
|
558
563
|
};
|
|
564
|
+
sortable: {
|
|
565
|
+
itemMoved: (item: string, position: number, total: number) => string;
|
|
566
|
+
itemMovedToList: (item: string, list: string, position: number, total: number) => string;
|
|
567
|
+
};
|
|
559
568
|
spinner: {
|
|
560
569
|
cancel: string;
|
|
561
570
|
loading: string;
|