sprof 1.19.3 → 1.20.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.
|
@@ -4,7 +4,10 @@ type __VLS_Props = {
|
|
|
4
4
|
id?: string;
|
|
5
5
|
/** Полиморфный тип связи (file_infos.type): diet, certificates, … */
|
|
6
6
|
type?: string;
|
|
7
|
-
/**
|
|
7
|
+
/**
|
|
8
|
+
* Пропорция превью. `0` (дефолт) — «вручную»: формат не навязывается,
|
|
9
|
+
* пользователь задаёт его в кроппере сам.
|
|
10
|
+
*/
|
|
8
11
|
ratio?: number;
|
|
9
12
|
/** Показывать управление добавлением. */
|
|
10
13
|
upload?: boolean;
|
|
@@ -1,13 +1,30 @@
|
|
|
1
|
-
import { ComputedRef } from 'vue';
|
|
1
|
+
import { ComputedRef, Ref } from 'vue';
|
|
2
2
|
import { default as Button } from './Btn';
|
|
3
3
|
type f = () => string;
|
|
4
4
|
type Title = string | f | ComputedRef;
|
|
5
|
+
/** Число записей списка: строка, число, ref/computed или функция. */
|
|
6
|
+
type Count = string | number | Ref<number> | ComputedRef<number> | (() => number);
|
|
5
7
|
declare class AdminHeadC {
|
|
6
8
|
title: Title;
|
|
9
|
+
/**
|
|
10
|
+
* Счётчик списка для шапки («Работники: 2250»).
|
|
11
|
+
*
|
|
12
|
+
* ⚠️ Только для СПИСКОВ: `Set(title, buttons)` без третьего аргумента
|
|
13
|
+
* (страница сущности `/workers/:id`) сбрасывает счётчик.
|
|
14
|
+
*/
|
|
15
|
+
count: Count | undefined;
|
|
7
16
|
buttons: Button[];
|
|
8
|
-
editTitle:
|
|
9
|
-
showEdit:
|
|
10
|
-
Set(title: Title | undefined, buttons: Button[]): void;
|
|
17
|
+
editTitle: Ref<boolean, boolean>;
|
|
18
|
+
showEdit: Ref<boolean, boolean>;
|
|
19
|
+
Set(title: Title | undefined, buttons: Button[], count?: Count): void;
|
|
20
|
+
/**
|
|
21
|
+
* Заголовок со счётчиком: «Отделы: 176»; без числа — просто заголовок.
|
|
22
|
+
*
|
|
23
|
+
* ⚠️ Геттер, создающий `computed` при каждом чтении. `computed`-поле,
|
|
24
|
+
* созданное ДО `reactive()`-обёртки (`AdminUI.Head`), трекает зависимости
|
|
25
|
+
* «сырого» объекта и не пересчитывается — заголовок в шапке залипал.
|
|
26
|
+
*/
|
|
27
|
+
get Title(): string;
|
|
11
28
|
}
|
|
12
29
|
declare const _default: AdminHeadC;
|
|
13
30
|
export default _default;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -24,6 +24,7 @@ declare class AdminUI {
|
|
|
24
24
|
};
|
|
25
25
|
Head: {
|
|
26
26
|
title: any;
|
|
27
|
+
count: string | number | (() => number) | undefined;
|
|
27
28
|
buttons: {
|
|
28
29
|
text: string | undefined;
|
|
29
30
|
type?: import('../types/Statuses').default | undefined;
|
|
@@ -34,7 +35,8 @@ declare class AdminUI {
|
|
|
34
35
|
}[];
|
|
35
36
|
editTitle: boolean;
|
|
36
37
|
showEdit: boolean;
|
|
37
|
-
Set: (title: (string | (() => string) | globalThis.ComputedRef<any>) | undefined, buttons: import('./Btn').default[]) => void;
|
|
38
|
+
Set: (title: (string | (() => string) | globalThis.ComputedRef<any>) | undefined, buttons: import('./Btn').default[], count?: (string | number | globalThis.Ref<number, number> | globalThis.ComputedRef<number> | (() => number)) | undefined) => void;
|
|
39
|
+
readonly Title: string;
|
|
38
40
|
};
|
|
39
41
|
}
|
|
40
42
|
declare const _default: AdminUI;
|