@ahmetilhn/hanui 2.7.1 → 3.0.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/README.md +8 -1
- package/build/index.cjs +16 -16
- package/build/index.cjs.map +1 -1
- package/build/index.d.ts +101 -22
- package/build/index.js +3154 -2956
- package/build/index.js.map +1 -1
- package/build/styles.css +1 -1
- package/package.json +4 -3
package/build/index.d.ts
CHANGED
|
@@ -49,6 +49,12 @@ export declare type AlertTone = 'info' | 'success' | 'warning' | 'danger';
|
|
|
49
49
|
/** Duyurunun aciliyeti. */
|
|
50
50
|
export declare type AnnouncePoliteness = 'polite' | 'assertive';
|
|
51
51
|
|
|
52
|
+
/**
|
|
53
|
+
* Ezmeleri belgeye yazar. Aynı `<style>` etiketi tekrar kullanılır: her
|
|
54
|
+
* çağrıda yeni bir etiket eklemek, birbirini ezen onlarca blok bırakıyordu.
|
|
55
|
+
*/
|
|
56
|
+
export declare const applyThemeConfig: (config: HanuiThemeConfig | undefined) => void;
|
|
57
|
+
|
|
52
58
|
export declare const Avatar: typeof Avatar_2;
|
|
53
59
|
|
|
54
60
|
/** Avatar — kullanıcı madalyonu. */
|
|
@@ -529,6 +535,12 @@ export declare type DateRangeValue = {
|
|
|
529
535
|
/** Kütüphanenin varsayılan font yığınları — hepsi sistem fontlarına iner. */
|
|
530
536
|
export declare const DEFAULT_FONTS: Required<HanuiFonts>;
|
|
531
537
|
|
|
538
|
+
/**
|
|
539
|
+
* Bilgi yoğunluğunun taşındığı öznitelik.
|
|
540
|
+
* `<html data-hanui-density="compact">`.
|
|
541
|
+
*/
|
|
542
|
+
export declare const DENSITY_ATTRIBUTE = "data-hanui-density";
|
|
543
|
+
|
|
532
544
|
export declare const Directory: typeof Directory_2;
|
|
533
545
|
|
|
534
546
|
/**
|
|
@@ -707,6 +719,13 @@ export declare type HanuiFonts = Partial<{
|
|
|
707
719
|
export declare type HanuiLabels = Partial<{
|
|
708
720
|
/** Kip pencere ve alt sayfanın kapatma düğmesi. `Modal`, `BottomSheet`. */
|
|
709
721
|
close: string;
|
|
722
|
+
/**
|
|
723
|
+
* Bildirim yığınının bölge adı ("Bildirimler"). `ToastHub`.
|
|
724
|
+
*
|
|
725
|
+
* ⚠ Yığın bir `role="region"` ve `aria-live` bölgesi; adsız bir bölge
|
|
726
|
+
* ekran okuyucuda yalnızca "bölge" diye okunur.
|
|
727
|
+
*/
|
|
728
|
+
notifications: string;
|
|
710
729
|
/** Vazgeçme eylemi. `ConfirmDialog`, `PromptDialog`. */
|
|
711
730
|
cancel: string;
|
|
712
731
|
/** Kaydetme/gönderme eylemi. `PromptDialog`. */
|
|
@@ -765,6 +784,49 @@ export declare type HanuiLabels = Partial<{
|
|
|
765
784
|
copied: Formatter<[value: string]>;
|
|
766
785
|
announcement: string;
|
|
767
786
|
}>;
|
|
787
|
+
/**
|
|
788
|
+
* Dosya yukleme.
|
|
789
|
+
*
|
|
790
|
+
* ⚠ `tooLarge` bir BICIMLENDIRICI: mesaj dosya adini ve siniri TASIMALI.
|
|
791
|
+
* Sabit bir "cok buyuk" metni, on dosyalik bir listede hangisinin
|
|
792
|
+
* reddedildigini soylemiyordu.
|
|
793
|
+
*/
|
|
794
|
+
fileUpload: Partial<{
|
|
795
|
+
tooLarge: Formatter<[name: string, max: string]>;
|
|
796
|
+
/** Yukleme sirasindaki ekran okuyucu duyurusu. */
|
|
797
|
+
uploading: Formatter<[name: string]>;
|
|
798
|
+
/** Dosya secildiginde yapilan duyuru. */
|
|
799
|
+
added: Formatter<[count: number]>;
|
|
800
|
+
}>;
|
|
801
|
+
/**
|
|
802
|
+
* Sayisal gostergenin YON metni.
|
|
803
|
+
*
|
|
804
|
+
* ⚠ Uc deger de SR-ONLY: ok isareti gorsel bir sinyal ve ekran okuyucuya
|
|
805
|
+
* hicbir sey soylemiyor. Verilmezse gosterge "yuzde 12" der, artis mi
|
|
806
|
+
* azalis mi belirsiz kalir.
|
|
807
|
+
*/
|
|
808
|
+
stat: Partial<{
|
|
809
|
+
increase: string;
|
|
810
|
+
decrease: string;
|
|
811
|
+
unchanged: string;
|
|
812
|
+
}>;
|
|
813
|
+
/** Adim gostergesinin DURUM metinleri — hepsi sr-only. */
|
|
814
|
+
steps: Partial<{
|
|
815
|
+
completed: string;
|
|
816
|
+
current: string;
|
|
817
|
+
upcoming: string;
|
|
818
|
+
}>;
|
|
819
|
+
/** Zaman cizelgesinin DURUM metinleri — hepsi sr-only. */
|
|
820
|
+
timeline: Partial<{
|
|
821
|
+
completed: string;
|
|
822
|
+
current: string;
|
|
823
|
+
failed: string;
|
|
824
|
+
}>;
|
|
825
|
+
/** Etiket girisi. `removed` bir bicimlendirici: hangi etiketin kalktigi. */
|
|
826
|
+
tagInput: Partial<{
|
|
827
|
+
added: Formatter<[value: string]>;
|
|
828
|
+
removed: Formatter<[value: string]>;
|
|
829
|
+
}>;
|
|
768
830
|
rating: Partial<{
|
|
769
831
|
/** Yıldızların ekran okuyucu karşılığı ("5 üzerinden 4,5 — 12 değerlendirme"). */
|
|
770
832
|
srLabel: Formatter<[value: number, count: number | undefined]>;
|
|
@@ -868,6 +930,13 @@ export declare type HanuiToken = keyof typeof LIGHT_THEME;
|
|
|
868
930
|
declare type HubProps = {
|
|
869
931
|
/** Kapatma düğmelerinin erişilebilir adı. Verilmezse `labels.close`. */
|
|
870
932
|
closeLabel?: string;
|
|
933
|
+
/**
|
|
934
|
+
* Yığının erişilebilir adı ("Bildirimler").
|
|
935
|
+
*
|
|
936
|
+
* ⚠ Yığın artık bir `role="region"` ve canlı bölge; adsız bir bölge ekran
|
|
937
|
+
* okuyucuda yalnızca "bölge" diye okunur.
|
|
938
|
+
*/
|
|
939
|
+
regionLabel?: string;
|
|
871
940
|
className?: string;
|
|
872
941
|
};
|
|
873
942
|
|
|
@@ -933,9 +1002,6 @@ isTechnical?: boolean;
|
|
|
933
1002
|
testId?: string;
|
|
934
1003
|
} & RefAttributes<HTMLInputElement>>;
|
|
935
1004
|
|
|
936
|
-
/** Odaklanınca mobilde ekran klavyesini açacak bir öğe mi? */
|
|
937
|
-
export declare const isKeyboardOpeningElement: (element: Element | null) => boolean;
|
|
938
|
-
|
|
939
1005
|
/** AÇIK TEMA — varsayılan. */
|
|
940
1006
|
export declare const LIGHT_THEME: {
|
|
941
1007
|
readonly page: "#ffffff";
|
|
@@ -1244,12 +1310,6 @@ export declare type PositioningState = {
|
|
|
1244
1310
|
/** Yüzeyin tercih ettiği kenar. Yer yoksa karşıtına düşer. */
|
|
1245
1311
|
export declare type PositionSide = 'top' | 'bottom' | 'left' | 'right';
|
|
1246
1312
|
|
|
1247
|
-
/**
|
|
1248
|
-
* `showModal()` ÇAĞRILDIKTAN SONRA çağrılır. Odak bir metin alanına düştüyse
|
|
1249
|
-
* panelin kendisine geri alınır; düşmediyse hiçbir şey yapılmaz.
|
|
1250
|
-
*/
|
|
1251
|
-
export declare const preventAutoKeyboard: (dialog: HTMLDialogElement) => void;
|
|
1252
|
-
|
|
1253
1313
|
export declare const Price: typeof Price_2;
|
|
1254
1314
|
|
|
1255
1315
|
/** Tutar gösterimi. */
|
|
@@ -1926,6 +1986,16 @@ declare type Props_46 = TableHTMLAttributes<HTMLTableElement> & Partial<{
|
|
|
1926
1986
|
|
|
1927
1987
|
declare type Props_47 = {
|
|
1928
1988
|
columns: DataTableColumn[];
|
|
1989
|
+
/**
|
|
1990
|
+
* Tablonun erişilebilir adı ("Bekleyen siparişler").
|
|
1991
|
+
*
|
|
1992
|
+
* ⚠ ADSIZ TABLO EKRAN OKUYUCUDA YALNIZCA "tablo" DİYE OKUNUR. Panelde
|
|
1993
|
+
* aynı anda birden fazla tablo bulunabiliyor ve kullanıcı hangisinde
|
|
1994
|
+
* olduğunu ayırt edemiyordu. `<caption>` yerine `aria-label` seçildi:
|
|
1995
|
+
* başlık zaten `PageHeader`/`Panel` içinde görünür durumda, ikinci kez
|
|
1996
|
+
* çizmek görsel tekrar olurdu.
|
|
1997
|
+
*/
|
|
1998
|
+
label?: string;
|
|
1929
1999
|
/**
|
|
1930
2000
|
* Gövde satırları (`<tr>`). Ekranların özel hücreleri, bağlantıları ve satır
|
|
1931
2001
|
* tintleri burada yaşar; tablo yalnızca kabuğu ve durum satırlarını
|
|
@@ -2129,6 +2199,14 @@ declare type ScrollerProps = HTMLAttributes<HTMLDivElement> & {
|
|
|
2129
2199
|
* görünüyordu.
|
|
2130
2200
|
*/
|
|
2131
2201
|
hasFrame?: boolean;
|
|
2202
|
+
/**
|
|
2203
|
+
* Kaydırma bölgesinin erişilebilir adı ("Sipariş kalemleri").
|
|
2204
|
+
*
|
|
2205
|
+
* ⚠ ZORUNLU değil ama VERİLMELİ: kutu klavyeyle odaklanabilir bir
|
|
2206
|
+
* `region` ve adsız bir bölge ekran okuyucuda yalnızca "bölge" diye
|
|
2207
|
+
* okunur — kullanıcı neyin içinde olduğunu bilemez.
|
|
2208
|
+
*/
|
|
2209
|
+
label?: string;
|
|
2132
2210
|
};
|
|
2133
2211
|
|
|
2134
2212
|
export declare const SectionHeader: typeof SectionHeader_2;
|
|
@@ -2258,6 +2336,16 @@ declare const TableCheckbox_2: ForwardRefExoticComponent<Omit<InputHTMLAttribute
|
|
|
2258
2336
|
* okunur. Satır kutusunda kaydın kimliğini söyleyin ("SP-2026-000123 seç").
|
|
2259
2337
|
*/
|
|
2260
2338
|
label: string;
|
|
2339
|
+
/**
|
|
2340
|
+
* "Bazı satırlar seçili" — başlık kutusunun üçüncü durumu.
|
|
2341
|
+
*
|
|
2342
|
+
* ⚠ Bu prop OLMADAN o durum İFADE EDİLEMİYORDU. `indeterminate` bir HTML
|
|
2343
|
+
* niteliği değil, yalnızca DOM ÖZELLİĞİ; JSX ile yazılamaz, `ref` üzerinden
|
|
2344
|
+
* atanması gerekir. Sonuç: başlık kutusu ya "hiçbiri" ya "hepsi" diyordu,
|
|
2345
|
+
* kısmi seçimde ise sessizce YANLIŞ bilgi veriyordu — operatör "hepsi
|
|
2346
|
+
* seçili" sanıp toplu işlem yapıyordu.
|
|
2347
|
+
*/
|
|
2348
|
+
isIndeterminate?: boolean;
|
|
2261
2349
|
testId?: string;
|
|
2262
2350
|
} & RefAttributes<HTMLInputElement>>;
|
|
2263
2351
|
|
|
@@ -2299,6 +2387,9 @@ export declare const TextLink: typeof TextLink_2;
|
|
|
2299
2387
|
/** Metin bağlantısı. */
|
|
2300
2388
|
declare const TextLink_2: ({ href, children, hasArrow, tone, size, className, linkProps, ...rest }: Props_2) => JSX.Element;
|
|
2301
2389
|
|
|
2390
|
+
/** Temanın taşındığı öznitelik. `<html data-hanui-theme="dark">`. */
|
|
2391
|
+
export declare const THEME_ATTRIBUTE = "data-hanui-theme";
|
|
2392
|
+
|
|
2302
2393
|
export declare const Tile: typeof Tile_2;
|
|
2303
2394
|
|
|
2304
2395
|
/** Karo — ikon madalyonu + etiket. */
|
|
@@ -2344,7 +2435,7 @@ export declare const toast: {
|
|
|
2344
2435
|
export declare const ToastHub: typeof ToastHub_2;
|
|
2345
2436
|
|
|
2346
2437
|
/** Bildirim yığını — uygulamada <strong>BİR KEZ</strong> çizilir. */
|
|
2347
|
-
declare const ToastHub_2: ({ closeLabel, className }: HubProps) => ReactPortal | null;
|
|
2438
|
+
declare const ToastHub_2: ({ closeLabel, regionLabel, className }: HubProps) => ReactPortal | null;
|
|
2348
2439
|
|
|
2349
2440
|
export declare type ToastOptions = {
|
|
2350
2441
|
tone?: ToastTone;
|
|
@@ -2452,18 +2543,6 @@ export declare const usePositioning: (anchorRef: {
|
|
|
2452
2543
|
current: HTMLElement | null;
|
|
2453
2544
|
}, { side, align, offset, padding, isOpen }: PositioningOptions) => PositioningState;
|
|
2454
2545
|
|
|
2455
|
-
export declare const useScrollLock: (isLocked?: boolean) => void;
|
|
2456
|
-
|
|
2457
|
-
/**
|
|
2458
|
-
* Alt sayfayi <strong>gorunen</strong> alana yaslar.
|
|
2459
|
-
*
|
|
2460
|
-
* @param isActive Panel acik mi. Yalnizca acikken olculur: kendisi yalnizca
|
|
2461
|
-
* acikken cizilen bir panel varsayilani kullanir, ama sayfa boyunca DOM'da
|
|
2462
|
-
* duran bir panel bayraksiz cagirdiginda her kullanicida iki gorunum alani
|
|
2463
|
-
* dinleyicisi bos yere acik kaliyordu.
|
|
2464
|
-
*/
|
|
2465
|
-
export declare const useSheetViewport: (isActive?: boolean) => void;
|
|
2466
|
-
|
|
2467
2546
|
/** SANALLAŞTIRMA — yalnızca görünen satırları çiz. */
|
|
2468
2547
|
export declare const useVirtualList: (count: number, { rowHeight, overscan, isEnabled }?: {
|
|
2469
2548
|
rowHeight?: number | undefined;
|