ar-design 0.2.62 → 0.2.63
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/components/data-display/table/IProps.d.ts +113 -0
- package/dist/components/data-display/tabs/IProps.d.ts +43 -4
- package/dist/components/feedback/notification/IProps.d.ts +63 -2
- package/dist/components/feedback/popover/IProps.d.ts +68 -0
- package/dist/components/feedback/progress/IProps.d.ts +30 -0
- package/dist/components/feedback/tooltip/IProps.d.ts +25 -0
- package/dist/components/navigation/pagination/IProps.d.ts +1 -0
- package/package.json +1 -1
|
@@ -4,52 +4,165 @@ import { IChildren } from "../../../libs/types/IGlobalProps";
|
|
|
4
4
|
import { FilterOperator } from "../../../libs/infrastructure/shared/Enums";
|
|
5
5
|
export type Operator = "Contains" | "DoesNotContains" | "Equals" | "DoesNotEquals" | "BeginsWith" | "EndsWith" | "Blank" | "NotBlank";
|
|
6
6
|
export type FilterValue = {
|
|
7
|
+
/**
|
|
8
|
+
* Filtre değeri olabilir: string, number veya boolean.
|
|
9
|
+
*/
|
|
7
10
|
value: string | number | boolean;
|
|
11
|
+
/**
|
|
12
|
+
* Uygulanacak filtre operatörü.
|
|
13
|
+
*/
|
|
8
14
|
operator: FilterOperator;
|
|
9
15
|
};
|
|
10
16
|
export type SearchedParam = {
|
|
11
17
|
[key: string]: FilterValue | FilterValue[];
|
|
12
18
|
};
|
|
13
19
|
export type Config = {
|
|
20
|
+
/**
|
|
21
|
+
* Verilerin sunucu tarafında mı işlendiğini belirtir.
|
|
22
|
+
*/
|
|
14
23
|
isServerSide?: boolean;
|
|
24
|
+
/**
|
|
25
|
+
* Tablo içinde arama özelliğinin aktif olup olmadığı.
|
|
26
|
+
*/
|
|
15
27
|
isSearchable?: boolean;
|
|
28
|
+
/**
|
|
29
|
+
* Kaydırma özelliği ve maksimum yüksekliği.
|
|
30
|
+
*/
|
|
16
31
|
scroll?: {
|
|
32
|
+
/**
|
|
33
|
+
* Maksimum tablo yüksekliği (piksel cinsinden).
|
|
34
|
+
*/
|
|
17
35
|
maxHeight: number;
|
|
18
36
|
};
|
|
37
|
+
/**
|
|
38
|
+
* Alt satır (subrow) özellikleri.
|
|
39
|
+
*/
|
|
19
40
|
subrow?: {
|
|
41
|
+
/**
|
|
42
|
+
* Alt satırın otomatik açılıp açılmayacağı.
|
|
43
|
+
*/
|
|
20
44
|
openAutomatically?: boolean;
|
|
45
|
+
/**
|
|
46
|
+
* Alt satırı açmak için seçici (CSS selector) tanımı.
|
|
47
|
+
*/
|
|
21
48
|
selector?: string;
|
|
49
|
+
/**
|
|
50
|
+
* Alt satır açma butonunun gösterilip gösterilmeyeceği.
|
|
51
|
+
*/
|
|
22
52
|
button?: boolean;
|
|
23
53
|
};
|
|
24
54
|
};
|
|
25
55
|
type ImportActionType = {
|
|
56
|
+
/**
|
|
57
|
+
* Import butonunun üzerine gelindiğinde gösterilecek açıklayıcı metin.
|
|
58
|
+
*/
|
|
26
59
|
tooltip: string;
|
|
60
|
+
/**
|
|
61
|
+
* Kabul edilen dosya türleri.
|
|
62
|
+
*/
|
|
27
63
|
allowedTypes?: AllowedTypes[];
|
|
64
|
+
/**
|
|
65
|
+
* Butonun önünde gösterilecek içerik.
|
|
66
|
+
*/
|
|
28
67
|
prefixItem?: React.ReactNode;
|
|
68
|
+
/**
|
|
69
|
+
* Butonun arkasında gösterilecek içerik.
|
|
70
|
+
*/
|
|
29
71
|
suffixItem?: React.ReactNode;
|
|
72
|
+
/**
|
|
73
|
+
* Dosya import işlemi tetiklendiğinde çağrılan fonksiyon.
|
|
74
|
+
*
|
|
75
|
+
* @param formData - Dosyaları içeren FormData nesnesi (undefined olabilir).
|
|
76
|
+
* @param files - Seçilen dosyalar dizisi.
|
|
77
|
+
*/
|
|
30
78
|
onClick: (formData: FormData | undefined, files: File[]) => void;
|
|
31
79
|
};
|
|
32
80
|
type CreateActionType = {
|
|
81
|
+
/**
|
|
82
|
+
* Create butonunun üzerine gelindiğinde gösterilecek açıklayıcı metin.
|
|
83
|
+
*/
|
|
33
84
|
tooltip: string;
|
|
85
|
+
/**
|
|
86
|
+
* Butona tıklanıldığında tetiklenen fonksiyon.
|
|
87
|
+
*/
|
|
34
88
|
onClick: (event: React.MouseEvent<HTMLButtonElement, MouseEvent>) => void;
|
|
35
89
|
};
|
|
36
90
|
interface IProps<T> extends IChildren {
|
|
91
|
+
/**
|
|
92
|
+
* Tablo başlığı.
|
|
93
|
+
*
|
|
94
|
+
* Örneğin;
|
|
95
|
+
*
|
|
96
|
+
* ```jsx
|
|
97
|
+
* <Table title="..." />
|
|
98
|
+
* ```
|
|
99
|
+
*/
|
|
37
100
|
title?: string;
|
|
101
|
+
/**
|
|
102
|
+
* Tabloya ait açıklama veya alt metin.
|
|
103
|
+
*/
|
|
38
104
|
description?: string;
|
|
105
|
+
/**
|
|
106
|
+
* Tabloya verilecek veri dizisi.
|
|
107
|
+
*/
|
|
39
108
|
data: T[];
|
|
109
|
+
/**
|
|
110
|
+
* Tablo kolonlarının tanımı.
|
|
111
|
+
*/
|
|
40
112
|
columns: TableColumnType<T>[];
|
|
113
|
+
/**
|
|
114
|
+
* Tablo üzerindeki eylem butonları.
|
|
115
|
+
*/
|
|
41
116
|
actions?: {
|
|
117
|
+
/**
|
|
118
|
+
* Dosya import işlemi için buton ayarları.
|
|
119
|
+
*/
|
|
42
120
|
import?: ImportActionType;
|
|
121
|
+
/**
|
|
122
|
+
* Yeni kayıt oluşturma butonu ayarları.
|
|
123
|
+
*/
|
|
43
124
|
create?: CreateActionType;
|
|
44
125
|
};
|
|
126
|
+
/**
|
|
127
|
+
* Seçili satırlar değiştiğinde çağrılan fonksiyon.
|
|
128
|
+
*
|
|
129
|
+
* @param selectionItems - Seçilen satırların dizisi.
|
|
130
|
+
*/
|
|
45
131
|
selections?: (selectionItems: T[]) => void;
|
|
132
|
+
/**
|
|
133
|
+
* Daha önce seçilmiş satırlar.
|
|
134
|
+
*/
|
|
46
135
|
previousSelections?: T[];
|
|
136
|
+
/**
|
|
137
|
+
* Arama parametreleri ve sorgu değiştiğinde çağrılan fonksiyon.
|
|
138
|
+
*
|
|
139
|
+
* @param params - Arama parametreleri veya null.
|
|
140
|
+
* @param query - Arama sorgu metni.
|
|
141
|
+
* @param operator - Kullanılan filtre operatörü.
|
|
142
|
+
*/
|
|
47
143
|
searchedParams?: (params: SearchedParam | null, query: string, operator: FilterOperator) => void;
|
|
144
|
+
/**
|
|
145
|
+
* Sayfalama ayarları.
|
|
146
|
+
*/
|
|
48
147
|
pagination?: {
|
|
148
|
+
/**
|
|
149
|
+
* Toplam kayıt sayısı.
|
|
150
|
+
*/
|
|
49
151
|
totalRecords: number;
|
|
152
|
+
/**
|
|
153
|
+
* Sayfa başına gösterilecek kayıt sayısı.
|
|
154
|
+
*/
|
|
50
155
|
perPage: number;
|
|
156
|
+
/**
|
|
157
|
+
* Sayfa değiştirildiğinde tetiklenen fonksiyon.
|
|
158
|
+
*
|
|
159
|
+
* @param currentPage - Yeni sayfa numarası.
|
|
160
|
+
*/
|
|
51
161
|
onChange?: (currentPage: number) => void;
|
|
52
162
|
};
|
|
163
|
+
/**
|
|
164
|
+
* Tablo yapılandırma ayarları.
|
|
165
|
+
*/
|
|
53
166
|
config?: Config;
|
|
54
167
|
}
|
|
55
168
|
export default IProps;
|
|
@@ -1,15 +1,54 @@
|
|
|
1
1
|
import { TabProps } from "../../../libs/types";
|
|
2
|
-
/**
|
|
3
|
-
* Stepper component props
|
|
4
|
-
*/
|
|
5
2
|
interface IProps {
|
|
6
3
|
/**
|
|
7
4
|
* Tab'ları temsil eden dizi.
|
|
8
|
-
* Her bir
|
|
5
|
+
* Her bir eleman `TabProps` tipinde olmalıdır.
|
|
6
|
+
*
|
|
7
|
+
* Örneğin;
|
|
8
|
+
*
|
|
9
|
+
* ```jsx
|
|
10
|
+
* <Component
|
|
11
|
+
* tabs={[
|
|
12
|
+
* { title: "Ana Sayfa", content: <HomePage />, config: { canBeClosed: false } },
|
|
13
|
+
* { title: "Profil", content: <Profile />, config: { canBeClosed: true } },
|
|
14
|
+
* ]}
|
|
15
|
+
* />
|
|
16
|
+
* ```
|
|
9
17
|
*/
|
|
10
18
|
tabs: TabProps[];
|
|
19
|
+
/**
|
|
20
|
+
* Aktif olarak seçili olan tab'ın indeksi.
|
|
21
|
+
*
|
|
22
|
+
* Örneğin;
|
|
23
|
+
*
|
|
24
|
+
* ```jsx
|
|
25
|
+
* <Tabs activeTab={0} />
|
|
26
|
+
* ```
|
|
27
|
+
*/
|
|
11
28
|
activeTab?: number;
|
|
29
|
+
/**
|
|
30
|
+
* Tab değiştirildiğinde çağrılan fonksiyon.
|
|
31
|
+
*
|
|
32
|
+
* @param currentTab - Yeni seçilen tab'ın indeksi.
|
|
33
|
+
*
|
|
34
|
+
* Örneğin;
|
|
35
|
+
*
|
|
36
|
+
* ```jsx
|
|
37
|
+
* <Tabs onChange={(currentTab) => console.log(currentTab)} />
|
|
38
|
+
* ```
|
|
39
|
+
*/
|
|
12
40
|
onChange?: (currentTab: number) => void;
|
|
41
|
+
/**
|
|
42
|
+
* Tab kapatıldığında çağrılan fonksiyon.
|
|
43
|
+
*
|
|
44
|
+
* @param closeTab - Kapatılan tab'ın indeksi.
|
|
45
|
+
*
|
|
46
|
+
* Örneğin;
|
|
47
|
+
*
|
|
48
|
+
* ```jsx
|
|
49
|
+
* <Tabs onClose={(closeTab) => console.log(closeTab)} />
|
|
50
|
+
* ```
|
|
51
|
+
*/
|
|
13
52
|
onClose?: (closeTab: number) => void;
|
|
14
53
|
}
|
|
15
54
|
export default IProps;
|
|
@@ -1,9 +1,70 @@
|
|
|
1
|
-
import { Direction } from "../../../libs/core/application/contexts/Notification";
|
|
1
|
+
import { Direction, Status } from "../../../libs/core/application/contexts/Notification";
|
|
2
2
|
interface IProps {
|
|
3
|
+
/**
|
|
4
|
+
* Bildirim başlığı.
|
|
5
|
+
*
|
|
6
|
+
* Örneğin;
|
|
7
|
+
*
|
|
8
|
+
* ```jsx
|
|
9
|
+
* <Notification title="Başarılı" />
|
|
10
|
+
* ```
|
|
11
|
+
*/
|
|
3
12
|
title: string;
|
|
13
|
+
/**
|
|
14
|
+
* Bildirimin içeriğinde gösterilecek opsiyonel mesaj.
|
|
15
|
+
*
|
|
16
|
+
* Örneğin;
|
|
17
|
+
*
|
|
18
|
+
* ```jsx
|
|
19
|
+
* <Notification message="İşlem başarıyla tamamlandı." />
|
|
20
|
+
* ```
|
|
21
|
+
*/
|
|
4
22
|
message?: string;
|
|
5
|
-
|
|
23
|
+
/**
|
|
24
|
+
* Bildirimin durumu.
|
|
25
|
+
*
|
|
26
|
+
* `Status` tipinde olmalıdır.
|
|
27
|
+
*
|
|
28
|
+
* Kabul edilen değerler:
|
|
29
|
+
* - `success`: Başarılı durum bildirimi.
|
|
30
|
+
* - `warning`: Uyarı durumu bildirimi.
|
|
31
|
+
* - `information`: Bilgilendirme durumu.
|
|
32
|
+
* - `error`: Hata durumu bildirimi.
|
|
33
|
+
*
|
|
34
|
+
* Örneğin;
|
|
35
|
+
*
|
|
36
|
+
* ```jsx
|
|
37
|
+
* <Notification status="success" />
|
|
38
|
+
* ```
|
|
39
|
+
*/
|
|
40
|
+
status: Status | number;
|
|
41
|
+
/**
|
|
42
|
+
* Bildirimin ekranda hangi köşede görüneceği.
|
|
43
|
+
*
|
|
44
|
+
* `Direction` tipinden olmalıdır.
|
|
45
|
+
*
|
|
46
|
+
* Geçerli değerler:
|
|
47
|
+
* - `top-left`: Sol üst köşe
|
|
48
|
+
* - `top-right`: Sağ üst köşe
|
|
49
|
+
* - `bottom-left`: Sol alt köşe
|
|
50
|
+
* - `bottom-right`: Sağ alt köşe
|
|
51
|
+
*
|
|
52
|
+
* Örneğin;
|
|
53
|
+
*
|
|
54
|
+
* ```jsx
|
|
55
|
+
* <Notification direction="top-right" />
|
|
56
|
+
* ```
|
|
57
|
+
*/
|
|
6
58
|
direction: Direction;
|
|
59
|
+
/**
|
|
60
|
+
* Bildirimin tetiklenip tetiklenmediğini belirten boolean değer.
|
|
61
|
+
*
|
|
62
|
+
* Örneğin;
|
|
63
|
+
*
|
|
64
|
+
* ```jsx
|
|
65
|
+
* <Notification trigger={true} />
|
|
66
|
+
* ```
|
|
67
|
+
*/
|
|
7
68
|
trigger: boolean;
|
|
8
69
|
}
|
|
9
70
|
export default IProps;
|
|
@@ -1,11 +1,79 @@
|
|
|
1
1
|
import { IChildren } from "../../../libs/types/IGlobalProps";
|
|
2
2
|
interface IProps extends IChildren {
|
|
3
|
+
/**
|
|
4
|
+
* Popover başlığı.
|
|
5
|
+
*
|
|
6
|
+
* Örneğin;
|
|
7
|
+
*
|
|
8
|
+
* ```jsx
|
|
9
|
+
* <Popover title="Onay Gerekiyor" />
|
|
10
|
+
* ```
|
|
11
|
+
*/
|
|
3
12
|
title?: string;
|
|
13
|
+
/**
|
|
14
|
+
* Popover içinde gösterilecek mesaj metni.
|
|
15
|
+
*
|
|
16
|
+
* Örneğin;
|
|
17
|
+
*
|
|
18
|
+
* ```jsx
|
|
19
|
+
* <Popover message="İşlemi onaylıyor musunuz?" />
|
|
20
|
+
* ```
|
|
21
|
+
*/
|
|
4
22
|
message?: string;
|
|
23
|
+
/**
|
|
24
|
+
* Popover içeriği olarak gösterilecek özel React JSX elementi.
|
|
25
|
+
*
|
|
26
|
+
* Örneğin;
|
|
27
|
+
*
|
|
28
|
+
* ```jsx
|
|
29
|
+
* <Popover content={<CustomContent />} />
|
|
30
|
+
* ```
|
|
31
|
+
*/
|
|
5
32
|
content?: React.JSX.Element;
|
|
33
|
+
/**
|
|
34
|
+
* Onay veya iptal durumunda tetiklenen geri çağırma fonksiyonu.
|
|
35
|
+
*
|
|
36
|
+
* @param confirm - Kullanıcı onay verdiyse true, iptal ettiyse false.
|
|
37
|
+
*
|
|
38
|
+
* Örneğin;
|
|
39
|
+
*
|
|
40
|
+
* ```jsx
|
|
41
|
+
* <Popover onConfirm={(confirm) => console.log(confirm)} />
|
|
42
|
+
* ```
|
|
43
|
+
*/
|
|
6
44
|
onConfirm?: (confirm: boolean) => void;
|
|
45
|
+
/**
|
|
46
|
+
* Popover açıkken sayfa dışında bir yere tıklandığında açık kalsın mı?
|
|
47
|
+
*
|
|
48
|
+
* Örneğin;
|
|
49
|
+
*
|
|
50
|
+
* ```jsx
|
|
51
|
+
* <Popover windowBlur={true} />
|
|
52
|
+
* ```
|
|
53
|
+
*/
|
|
7
54
|
windowBlur?: boolean;
|
|
55
|
+
/**
|
|
56
|
+
* Popover genişliği tam genişlikte mi olacak?
|
|
57
|
+
*
|
|
58
|
+
* Örneğin;
|
|
59
|
+
*
|
|
60
|
+
* ```jsx
|
|
61
|
+
* <Popover fullWidth={true} />
|
|
62
|
+
* ```
|
|
63
|
+
*/
|
|
8
64
|
fullWidth?: boolean;
|
|
65
|
+
/**
|
|
66
|
+
* Buton yapılandırmaları.
|
|
67
|
+
*
|
|
68
|
+
* - `okButton`: Onay butonunda gösterilecek metin.
|
|
69
|
+
* - `cancelButton`: (Opsiyonel) İptal butonunda gösterilecek metin.
|
|
70
|
+
*
|
|
71
|
+
* Örneğin;
|
|
72
|
+
*
|
|
73
|
+
* ```jsx
|
|
74
|
+
* <Popover config={{ buttons: { okButton: "...", cancelButton: "..." } }} />
|
|
75
|
+
* ```
|
|
76
|
+
*/
|
|
9
77
|
config?: {
|
|
10
78
|
buttons: {
|
|
11
79
|
okButton: string;
|
|
@@ -1,6 +1,36 @@
|
|
|
1
1
|
interface IProps {
|
|
2
|
+
/**
|
|
3
|
+
* İlerleme çubuğunun mevcut değeri.
|
|
4
|
+
* Genellikle 0 ile 100 arasında bir sayı olmalıdır.
|
|
5
|
+
*
|
|
6
|
+
* Örneğin;
|
|
7
|
+
*
|
|
8
|
+
* ```jsx
|
|
9
|
+
* <Progress value={75} />
|
|
10
|
+
* ```
|
|
11
|
+
*/
|
|
2
12
|
value: number;
|
|
13
|
+
/**
|
|
14
|
+
* İlerleme çubuğunun ters yönde dolmasını sağlar.
|
|
15
|
+
* Varsayılan olarak false'tur.
|
|
16
|
+
*
|
|
17
|
+
* Örneğin;
|
|
18
|
+
*
|
|
19
|
+
* ```jsx
|
|
20
|
+
* <Progress value={50} reverse={true} />
|
|
21
|
+
* ```
|
|
22
|
+
*/
|
|
3
23
|
reverse?: boolean;
|
|
24
|
+
/**
|
|
25
|
+
* İlerleme değerinin görünür olup olmadığını belirler.
|
|
26
|
+
* Varsayılan olarak true olabilir.
|
|
27
|
+
*
|
|
28
|
+
* Örneğin;
|
|
29
|
+
*
|
|
30
|
+
* ```jsx
|
|
31
|
+
* <Progress value={30} isVisibleValue={false} />
|
|
32
|
+
* ```
|
|
33
|
+
*/
|
|
4
34
|
isVisibleValue?: boolean;
|
|
5
35
|
}
|
|
6
36
|
export default IProps;
|
|
@@ -1,6 +1,31 @@
|
|
|
1
1
|
import { IChildren } from "../../../libs/types/IGlobalProps";
|
|
2
2
|
interface IProps extends IChildren {
|
|
3
|
+
/**
|
|
4
|
+
* Gösterilecek metin veya metinler.
|
|
5
|
+
*
|
|
6
|
+
* Örneğin;
|
|
7
|
+
*
|
|
8
|
+
* ```jsx
|
|
9
|
+
* <Tooltip text="..."><Component>...</Component></Tooltip>
|
|
10
|
+
* <Tooltip text={["...", "..."]}><Component>...</Component></Tooltip>
|
|
11
|
+
* ```
|
|
12
|
+
*/
|
|
3
13
|
text: string | string[];
|
|
14
|
+
/**
|
|
15
|
+
* Tooltip'in hangi yönde görüneceği.
|
|
16
|
+
*
|
|
17
|
+
* Geçerli değerler:
|
|
18
|
+
* - `top`: Üstte
|
|
19
|
+
* - `right`: Sağda
|
|
20
|
+
* - `left`: Solda
|
|
21
|
+
* - `bottom`: Altta
|
|
22
|
+
*
|
|
23
|
+
* Örneğin;
|
|
24
|
+
*
|
|
25
|
+
* ```jsx
|
|
26
|
+
* <Tooltip text="Bilgi" direction="right"><Component>...</Component></Tooltip>
|
|
27
|
+
* ```
|
|
28
|
+
*/
|
|
4
29
|
direction?: "top" | "right" | "left" | "bottom";
|
|
5
30
|
}
|
|
6
31
|
export default IProps;
|