@webitel/ui-sdk 26.8.52 → 26.8.53
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.
|
@@ -1,5 +1,7 @@
|
|
|
1
|
-
import { type MaybeRefOrGetter } from 'vue';
|
|
2
1
|
import { EmptyCause } from '../../../enums/index';
|
|
2
|
+
type DeepPartial<T> = T extends object ? {
|
|
3
|
+
[K in keyof T]?: DeepPartial<T[K]>;
|
|
4
|
+
} : T;
|
|
3
5
|
interface EmptyImageSet {
|
|
4
6
|
dark: string;
|
|
5
7
|
light: string;
|
|
@@ -27,7 +29,13 @@ export interface UseTableEmptySource {
|
|
|
27
29
|
error?: Readable<unknown>;
|
|
28
30
|
isLoading?: Readable<boolean | undefined>;
|
|
29
31
|
}
|
|
30
|
-
|
|
32
|
+
type MaybeOverridesGetter = DeepPartial<EmptyStateConfig> | Readable<DeepPartial<EmptyStateConfig>> | (() => DeepPartial<EmptyStateConfig>);
|
|
33
|
+
/**
|
|
34
|
+
* @param overrides plain object, ref, computed, or getter — use a reactive
|
|
35
|
+
* source (not a plain object literal) if any value inside depends on
|
|
36
|
+
* locale/dark mode, so it re-evaluates instead of freezing at first render
|
|
37
|
+
*/
|
|
38
|
+
export declare const useTableEmpty: ({ dataList, filters, error, isLoading }?: UseTableEmptySource, overrides?: MaybeOverridesGetter) => {
|
|
31
39
|
showEmpty: import("vue").ComputedRef<boolean>;
|
|
32
40
|
emptyCause: import("vue").ComputedRef<EmptyCause | null>;
|
|
33
41
|
image: import("vue").ComputedRef<string | null>;
|